Tryton - Issues

 

Issue8109

Title Allow to use javascript properties in sao
Priority feature Status resolved
Superseder Nosy List ced, nicoe, reviewbot, roundup-bot
Type performance Components sao
Assigned To nicoe Keywords review
Reviews 60561002, 47811003
View: 60561002, 47811003

Created on 2019-02-13.11:06:53 by nicoe, last changed by roundup-bot.

Messages
New changeset 20389aa096d4 by Cédric Krier in branch 'default':
Replace remaining set_current_record by assignation
https://hg.tryton.org/tryton-env/rev/20389aa096d4
New changeset e1ffa6204644 by Cédric Krier in branch 'default':
Replace remaining set_current_record by assignation
https://hg.tryton.org/sao/rev/e1ffa6204644
New changeset 19f7d935c093 by Nicolas ?vrard in branch 'default':
Use properties
https://hg.tryton.org/tryton-env/rev/19f7d935c093
New changeset 584be2585d2a by Nicolas ?vrard in branch 'default':
Use properties
https://hg.tryton.org/sao/rev/584be2585d2a
review47811003 updated at https://codereview.tryton.org/47811003/#ps20001
New changeset 949d7aadb628 by Nicolas ?vrard in branch 'default':
Allow sao classes to use javascript properties
https://hg.tryton.org/tryton-env/rev/949d7aadb628
New changeset 1c4f97a23a8f by Nicolas ?vrard in branch 'default':
Allow sao classes to use javascript properties
https://hg.tryton.org/sao/rev/1c4f97a23a8f
msg47015 (view) Author: [hidden] (nicoe) (Tryton committer) Date: 2019-02-13.18:58:55
Here's such a patch
msg47008 (view) Author: [hidden] (ced) (Tryton committer) (Tryton translator) Date: 2019-02-13.11:57:44
I think we must have another patch which replace the function by property based on tryton implementation.
review60561002 updated at https://codereview.tryton.org/60561002/#ps20001
msg47000 (view) Author: [hidden] (nicoe) (Tryton committer) Date: 2019-02-13.11:06:53
Javascript allows for python like properties: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Working_with_Objects#Defining_getters_and_setters

This feature is supported by all major browsers: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/get#Browser_compatibility

Sao's inheritance mechanism (Sao.class_) is not compatible with those, yet it requires a simple patch to do so.
History
Date User Action Args
2019-02-15 23:07:27roundup-botsetmessages: + msg47072
2019-02-15 23:07:24roundup-botsetmessages: + msg47071
2019-02-14 16:31:40roundup-botsetmessages: + msg47048
2019-02-14 16:31:37roundup-botsetstatus: in-progress -> resolved
messages: + msg47047
2019-02-13 19:07:36reviewbotsetmessages: + msg47018
2019-02-13 19:01:09nicoesetstatus: resolved -> in-progress
2019-02-13 19:00:03roundup-botsetmessages: + msg47017
2019-02-13 19:00:00roundup-botsetstatus: chatting -> resolved
nosy: + roundup-bot
messages: + msg47016
2019-02-13 18:58:55nicoesetreviews: 60561002 -> 60561002, 47811003
messages: + msg47015
2019-02-13 11:57:44cedsetnosy: + ced
messages: + msg47008

Showing 10 items. Show all history (warning: this could be VERY long)