TranslateTrait (class)

Trait TranslateTrait

Contains a translation method aimed to help managing multiple translations for an entity.

Method Summary

  • translation() public

    Returns the entity containing the translated fields for this object and for the specified language. If the translation for the passed language is not present, a new empty entity will be created so that values can be added to it.

Method Detail

translation()source public

translation( string $language )

Returns the entity containing the translated fields for this object and for the specified language. If the translation for the passed language is not present, a new empty entity will be created so that values can be added to it.

Parameters

string $language
Language to return entity for.

Returns


$this|\Cake\ORM\Entity

© 2005–2017 The Cake Software Foundation, Inc.
Licensed under the MIT License.
CakePHP is a registered trademark of Cake Software Foundation, Inc.
We are not endorsed by or affiliated with CakePHP.
https://api.cakephp.org/3.3/class-Cake.ORM.Behavior.Translate.TranslateTrait.html

在线笔记
App下载
App下载

扫描二维码

下载编程狮App

公众号
微信公众号

编程狮公众号

意见反馈
返回顶部