[TYPO3-mvc] Difference between FE and BE requests?

Robert Böttner robert at boettner.it
Wed Dec 30 18:39:46 CET 2009


Hi,

I set up a BE module pretty much similar to those in mvc_extjs_samples, also based on ExtJS components. My layout and forms are getting rendered fine, requests to populate ExtJS data stores also work fine.

Trouble is that the data manipulation actions are not working. They do in FE but not in BE and the controller action is the same for both worlds except other names and class-relations:

/**
 *
 * @param Tx_LalAppfactory_Domain_Model_App $app The app the content belogns to
 * @param Tx_LalAppfactory_Domain_Model_Content $newContent A fresh Content object which has not yet been added to the repository
 * @return void
 * @dontverifyrequesthash
 */
public function createAction(Tx_LalAppfactory_Domain_Model_App $app, Tx_LalAppfactory_Domain_Model_Content $newContent) {
	$app->addContent($newContent);
	$newContent->setApp($app);
}

This is the request in FE:
tx_lalappfactory_pi2[action] = create
tx_lalappfactory_pi2[app] = 47
tx_lalappfactory_pi2[controller] = Content
tx_lalappfactory_pi2[type] = pages
type = 1257862860

And this in BE:
M = user_LalAppfactoryAppmanager
tx_lalappfactory_user_lalappfactoryappmanager[action] = createcontent
tx_lalappfactory_user_lalappfactoryappmanager[app] = 47
tx_lalappfactory_user_lalappfactoryappmanager[controller] = Appmanager

The forms contain the same fields and follow the respective naming conventions similar to the POST array field names.

This is the configuration of my BE module in ext_tables.php:
if (TYPO3_MODE === 'BE')	{
	/**
	* Registers a Backend Module
	*/
	Tx_Extbase_Utility_Extension::registerModule(
		$_EXTKEY,
		'user',					// Make module a submodule of 'web'
		'Appmanager',	// Submodule key
		'',						// Position
		array(																			// An array holding the controller-action-combinations that are accessible
			'Appmanager' => 'index,apps,editions,content,updateapp,updatecontent,createcontent'	// The first controller and its first action will be the default
		),
		array(
			'access' => 'user,group',
			'icon'   => 'EXT:lal_appfactory/ext_icon.gif',
			'labels' => 'LLL:EXT:'.$_EXTKEY.'/Resources/Private/Language/locallang_mod.xml',
		)
	);
}

I´m getting a Tx_Extbase_MVC_Exception_InvalidArgumentValue The value must be of type "Tx_LalAppfactory_Domain_Model_App", but was of type "NULL" error when executing the createcontent action.

Does anyone have an idea?

Thanks and a Happy New Year
Robert.



More information about the TYPO3-project-typo3v4mvc mailing list