[TYPO3-dev] Re: Can i hide a translation of an inline record?

Philipp Wrann philippwrann at gmail.com
Thu Nov 27 12:55:39 CET 2014


I dont think that this is possible.

We would need an additional field for that purpose. And it would not be so easy to implement...

I wrote a viewhelper to hide objects that are fallbacks:

class IsNoFallbackObjectViewHelper extends \TYPO3\CMS\Fluid\Core\ViewHelper\AbstractConditionViewHelper {

	/**
	 * @param \TYPO3\CMS\Extbase\DomainObject\AbstractEntity $object
	 * @return string
	 */
	public function render(\TYPO3\CMS\Extbase\DomainObject\AbstractEntity $object) {
		/* @var $GLOBALS['TSFE'] \TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController */
		if ($object->_getProperty('_languageUid') == $GLOBALS['TSFE']->sys_language_uid) {
			return $this->renderThenChild();
		} else {
			return $this->renderElseChild();
		}
	}

}



More information about the TYPO3-dev mailing list