You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'd like to know if there is a way to return a whole translated model (API scenario). Currently returning a model will result in the translatable JSON array to be returned.
This is a follow up on this issue (#196) and I'd rather like to know if there is some sort of native way of doing what was accepted as answer in the issue. Doing the toArray function requires to edit the content of function every time the model is modified, therefore adding unnecessary work.
Is there some way to return a translated model in an elegant way ?
This discussion was converted from issue #245 on December 13, 2020 11:41.
Heading
Bold
Italic
Quote
Code
Link
Numbered list
Unordered list
Task list
Attach files
Mention
Reference
Menu
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I'd like to know if there is a way to return a whole translated model (API scenario). Currently returning a model will result in the translatable JSON array to be returned.
This is a follow up on this issue (#196) and I'd rather like to know if there is some sort of native way of doing what was accepted as answer in the issue. Doing the
toArray
function requires to edit the content of function every time the model is modified, therefore adding unnecessary work.Is there some way to return a translated model in an elegant way ?
Beta Was this translation helpful? Give feedback.
All reactions