institut-de-genomique / Ultimate-DataTable

This AngularJS directive generate a HTML table with build-in fonctionnality like save, edit, remove, pagination etc...
http://institut-de-genomique.github.io/Ultimate-DataTable/
45 stars 26 forks source link

Two messages services are declare in datatable #5

Closed galbini closed 8 years ago

galbini commented 8 years ago

Two differents messages service variable are are used in udt.

Remove one of them.

ex : with config.messages and messages

ydeshayes commented 8 years ago

There is two vars messages, but I think we need to keep it this way.

The config.messages is only used for the transformKey function, and I've done it this way because I want the user to be able to override this function with his own I18n service because he can override the errorKey and successKey. By default it use the default udtI18n service.

The other var is used for the internal i18n needs only.

Tell me if you want to refactor this anyway.

galbini commented 8 years ago

Hi Yann,

Ok, i agree with you but in this case we have a bug because to display column header we use the function udtTableFunctions.messages.Messages(header.label) that's call the internal messageService. In this case we need to call the external service provide by the developer. I already resolve this bug in NGL. I push it the next week.

Thanks for your feedback. Guillaume