[TYPO3-commerce] process markers question

Michiel Roos michiel at netcreators.com
Fri Oct 19 08:49:38 CEST 2007


Hi Jordan,

I feel your pain. I made an entry in the bugtracker about this a while 
ago so that it will not be forgotten: http://bugs.typo3.org/view.php?id=6406

If you like, please +1 the report in a comment to the bug or something.

One way to distinguish between the billing and the other thingie is to 
check the 'step' variable from the session in a switch statement. 
something along the lines of:

   /**
    * @param [type]    $$markerArray: ...
    * @param [type]    $parentObject: ...
    * @return  [type]    ...
    */
   function ProcessMarker (&$markerArray, &$parentObject) {
     if(!is_object($this->parentObject)) {
       $this->parentObject = $parentObject;
     }
     $basePath = 
t3lib_extMgm::extPath('nc_commerce_ideal').'lib/locallang.xml';
     $this->LOCAL_LANG = t3lib_div::readLLfile($basePath, 
$this->parentObject->LLkey);
     if ($this->parentObject->altLLkey)    {
       $tempLOCAL_LANG = 
t3lib_div::readLLfile($basePath,$this->parentObject->altLLkey);
       $this->LOCAL_LANG = array_merge(is_array($this->LOCAL_LANG) ? 
$this->LOCAL_LANG : array(),$tempLOCAL_LANG);
     }

     switch ($this->parentObject->currentStep) {
       case 'payment':
         $this->formError[$name] = $this->pi_getLL('error_field_alpha');
         $markerArray['###PAYMENT_TITLE###'] = 
$this->pi_getLL('payment_title');
         $markerArray['###PAYMENT_DESCRIPTION###'] = 
$this->pi_getLL('payment_description');
         $markerArray['###PAYMENT_DISCLAIMER###'] = 
$this->pi_getLL('general_disclaimer') .'<br />' 
.$this->pi_getLL('payment_disclaimer');
         debug ($markerArray, 'payment->ProcessMarker', 746, 
'pi3/class.tx_commerce_pi3.php');
         break;
       case 'listing':
         $markerArray['###PAYMENT_METHOD###'] = 
$this->parentObject->MYSESSION['payment']['issuer'];
         debug ($markerArray, 'listing->ProcessMarker', 746, 
'pi3/class.tx_commerce_pi3.php');
         break;
     }

     return $markerArray;
   }

Happy hacking,


Michiel Roos

-- 
Netcreators BV :: creation and innovation
www.netcreators.com

Interesse in werken bij Netcreators?
http://www.netcreators.com/bedrijf/vacatures/


More information about the TYPO3-project-commerce mailing list