Translate in model or in view

I want your opinion about translation models

Which is the best way to make the translation for models ? in the model attributeLabels() method or in the view directly?

Each one has prons and cons, so which one you use often ?

Model translation in attributeLabels() method is the best way By this we will get translation changes in all views and don’t have to call in every views.

This is prons and cons in few cases

Using in model you have translation globally

Using in view you have specialization

So it depends!, maybe is good to have globally translation and in few cases using Yii::t translation on the view.

But in this way you slow down the performance of webapp

Any other opinion ?

I would say go with models keeps your code dry, you could always override views if you need

attributesLabels is not called that often so there is no real performance issue.

I generate my models with translated labels automatically:

If you worry about performance, profile your code:

You may find some astonishing results, [size=2]I found that overriding some methods to empty methods helps for speed - attributesLabels did not appear as a time consumer[/size][size=2]:[/size]