Typo3 updates: Unterschied zwischen den Versionen

Aus Vosp.info
Wechseln zu:Navigation, Suche
(Die Seite wurde neu angelegt: „== Version 6 == === No converter found which can be used to convert from "array" to "string". === <source lang="php"> class Tx_extname_Domain_Model_Class extends …“)
 
(No converter found which can be used to convert from "array" to "string".)
 
Zeile 1: Zeile 1:
 
== Version 6 ==
 
== Version 6 ==
 
=== No converter found which can be used to convert from "array" to "string". ===
 
=== No converter found which can be used to convert from "array" to "string". ===
 +
 +
wichtig ist die initializeAction Funktion im Controller
 +
mit print_r($this->arguments->getArgumentNames()); läßt sich rausfinden wie denn noch mal der richtige Argument war
 +
 
<source lang="php">
 
<source lang="php">
 
class Tx_extname_Domain_Model_Class extends Tx_Extbase_DomainObject_AbstractEntity {
 
class Tx_extname_Domain_Model_Class extends Tx_Extbase_DomainObject_AbstractEntity {

Aktuelle Version vom 23. Juli 2013, 13:09 Uhr

Version 6

No converter found which can be used to convert from "array" to "string".

wichtig ist die initializeAction Funktion im Controller mit print_r($this->arguments->getArgumentNames()); läßt sich rausfinden wie denn noch mal der richtige Argument war

class Tx_extname_Domain_Model_Class extends Tx_Extbase_DomainObject_AbstractEntity {

	/* ... */
	/**
	 * image
	 *
	 * @var \string
	 */
	protected $image;
	/* ... */

}

class Tx_Nccontact_Controller_ClassController extends Tx_Extbase_MVC_Controller_ActionController {
	/**
	 * initialize create action
	 * allow creation of submodel company
	 */
	public function initializeAction() {
//		print_r($this->arguments->getArgumentNames());
		if ($this->arguments->hasArgument('newClassFormName')) {
			$this->arguments->getArgument('newClassFormName')->getPropertyMappingConfiguration()->setTargetTypeForSubProperty('image', 'array');
		}
	}	
}