Page 1 of 1

Add/Update i18n enhancement

PostPosted: Wed May 04, 2011 10:36 am
by Karel Broer
Pressing the Add/Update button in the Servoy i18n Editor add or updates a key only in the workspace.
One thing we would REALLY like is having Servoy also add or update the key in the -solution defined- messages table.
Please can this be included in Servoy 5.2.8 :) ?
(Case 381926 created for this feature request)

Re: Add/Update i18n enhancement

PostPosted: Wed May 04, 2011 11:18 am
by Gabi Boros
in Servoy 6 there is already a feature, that you can push the
messages from the the workspace into the solution defined table,
in the context menu of the i18n node from solution explorer

Re: Add/Update i18n enhancement

PostPosted: Wed May 04, 2011 11:39 am
by Karel Broer
Thanks a bunch, that's really nice Gabi!
Does that feature overwrites all keys in the database or does it merge the current keys in the database?
My Add/Update button enhancement request would still be a nice to have feature, btw.

Re: Add/Update i18n enhancement

PostPosted: Wed May 04, 2011 1:10 pm
by Gabi Boros
it's overwrites all keys, you would use that feature when you have all
your keys in the workspace
I don't know if it would worth to update the table on each change in the developer,
as it is using the values from the workspace

Re: Add/Update i18n enhancement

PostPosted: Wed May 04, 2011 4:12 pm
by Karel Broer
Gabi Boros wrote:it's overwrites all keys, you would use that feature when you have all
your keys in the workspace

Good enough for me right now. thanks.
I don't know if it would worth to update the table on each change in the developer,
as it is using the values from the workspace

Reason why we like to have this feature is that we perform tests with smartclient, so the keys must be in the database. Now we export a module including all i18n keys > importing module into app server incl i18n keys, however this takes way too much time. Pressing a button beforehand would save us significant amount of time.

Re: Add/Update i18n enhancement

PostPosted: Wed May 04, 2011 8:55 pm
by Harjo
Karel, how are you testing with (more than one) smart-client??
In developer you can only test, with the 1 debug client, or 1 debug web-client

Re: Add/Update i18n enhancement

PostPosted: Thu May 05, 2011 9:45 am
by Karel Broer
Harjo wrote:Karel, how are you testing with (more than one) smart-client??
In developer you can only test, with the 1 debug client, or 1 debug web-client

I'll explain. We actually test with both client types, because in some cases they have different behaviour.

The developers test en debug with the debugclient, and the testers use the smart client (both debug-en smart clients are connected to the same database).
In order to test the smart client, the solution has to be imported into the application server ofcourse.
It often happens that some i18n keys need to be modified after the tests, so in that case it's nice to be able to update a -specific- key, instead of overwrite them all again.

Re: Add/Update i18n enhancement

PostPosted: Thu May 05, 2011 10:19 am
by jcompagner
then i guess what you need is a merge: (with the options we have now in 6)

write to db -> an option to only write new keys and there values, don't touch the rest.
read from db -> an option to only get the new values don't delete new keys that are in the workspace.

you could make a case for this, it could be that we only need to have the second option
because then your workspace is completely up to date and you could then write it (but the question is then what to do with keys that don't exist in the workspace anymore, i guess those can be deleted)

Re: Add/Update i18n enhancement

PostPosted: Thu May 05, 2011 3:17 pm
by Karel Broer
jcompagner wrote:then i guess what you need is a merge: (with the options we have now in 6)
write to db -> an option to only write new keys and there values, don't touch the rest.
read from db -> an option to only get the new values don't delete new keys that are in the workspace.

Hi Johan, that sounds great, but we need these functions a little bit more extended:
write to db -> an option to update existing keys and write new keys
read from db -> an option to update existing values and get the new values (don't delete new keys that are in the workspace)
You could make a case for this, it could be that we only need to have the second option
because then your workspace is completely up to date and you could then write it (but the question is then what to do with keys that don't exist in the workspace anymore, i guess those can be deleted)

Keys that don't exist in the workspace should never be deleted, because the messages table can contain custom keys that we do not have in the workspace, but use in other products (like our saas applications that run on same database).
I reopened case 381926 and added these options to it.