/** * Get information on the field translations * * @return array of fields sourceName => targetName * @throws \MUtil_Model_ModelException */ public function getFieldsTranslations() { if (!$this->_targetModel instanceof \MUtil_Model_ModelAbstract) { throw new \MUtil_Model_ModelTranslateException(sprintf('Called %s without a set target model.', __FUNCTION__)); } $this->_targetModel->set('gto_id_token', 'label', $this->_('Token'), 'import_descr', $this->loader->getTracker()->getTokenLibrary()->getFormat(), 'required', true, 'order', 2); return array('token' => 'gto_id_token') + parent::getFieldsTranslations(); }
/** * Get information on the field translations * * @return array of fields sourceName => targetName * @throws \MUtil_Model_ModelException */ public function getFieldsTranslations() { if (!$this->_targetModel instanceof \MUtil_Model_ModelAbstract) { throw new \MUtil_Model_ModelTranslateException(sprintf('Called %s without a set target model.', __FUNCTION__)); } // \MUtil_Echo::track($this->_targetModel->getItemNames()); return $this->getRespondentAnswerTranslations() + parent::getFieldsTranslations(); }