chat.freenode.net #tryton log beginning Thu Sep 12 00:00:02 CEST 2013 | ||
2013-09-12 07:51 <WUD> Hi, If I set a field with default_ static method, can I access it using the self.fieldName method in my code? | ||
2013-09-12 08:15 -!- priyankarani(~priyanka@122.177.31.229) has left #tryton | ||
2013-09-12 08:38 <WUD> Is there no way in Tryton's API to set a field on a Model at the time it's initialising, i.e. showing in the view, | ||
2013-09-12 08:39 <WUD> even before it's stored in the db, when I'm using the self | ||
2013-09-12 08:45 <nicoe> WUD: it's default_<field name> | ||
2013-09-12 08:48 <WUD> It doesn't work. | ||
2013-09-12 08:49 <WUD> say I have set a field with default_field_name and I try to use self.field_name to access it, it just comes as None | ||
2013-09-12 08:49 <WUD> nicoe: | ||
2013-09-12 08:50 <nicoe> default_ is to set the default value when presenting it in the client | ||
2013-09-12 08:51 <nicoe> WUD: But also when saving the object | ||
2013-09-12 08:51 <nicoe> Before it is not set | ||
2013-09-12 08:51 <WUD> yeah, but i want to use the default field before I have saved | ||
2013-09-12 08:51 <WUD> as self.field | ||
2013-09-12 08:58 <nicoe> WUD: why ? | ||
2013-09-12 09:03 <WUD> I want to set the _parent_sale field on pos | ||
2013-09-12 09:03 <WUD> sorry | ||
2013-09-12 09:03 <WUD> _parent_sale field on sale.line | ||
2013-09-12 09:05 <nicoe> There is no _parent_sale field on sale.line but there is a sale field | ||
2013-09-12 09:08 <WUD> yeah, it's not a field, but on the on_change product, there is something called _parent_sale | ||
2013-09-12 09:08 <WUD> and I'm assuming it's the parent of the current sale.line | ||
2013-09-12 09:09 <WUD> https://github.com/tryton/sale/blob/develop/sale.py#L959 | ||
2013-09-12 09:26 <nicoe> WUD: yes it's the sale | ||
2013-09-12 09:26 <nicoe> WUD: so the sale field I'm talking about | ||
2013-09-12 09:27 <nicoe> WUD: The on_change field is an indication for the client of which field he should send when the field change | ||
2013-09-12 09:28 <nicoe> the _parent prefix allows to send information about a specific parent (many2one field) | ||
2013-09-12 09:28 <nicoe> in this case 'sale' | ||
2013-09-12 09:28 <nicoe> because it is named _parent_sale | ||
2013-09-12 09:29 <WUD> so any fields on the parent, I can use in my child ? | ||
2013-09-12 09:29 <WUD> modules are a mess without inherits | ||
2013-09-12 09:33 <nicoe> WUD: cleaner IMOH | ||
2013-09-12 09:34 <WUD> nicoe: sure, but then I can't get my 2.6 module to work in 2.8 | ||
2013-09-12 10:07 <WUD> is there a way to set the _parent_ field explicitly? | ||
2013-09-12 10:26 -!- WUD(~WUD@122.177.31.229) has left #tryton | ||
2013-09-12 11:04 <jvblasco> morning everyone | ||
2013-09-12 11:06 -!- priyankarani(~priyanka@122.177.31.229) has left #tryton | ||
2013-09-12 17:03 <prusglajotemis> Hello. How can I programmatically delete the action keyword ? | ||
2013-09-12 17:06 <cedk> prusglajotemis: what do you mean? | ||
2013-09-12 17:11 <prusglajotemis> for example i want delete a lot of "form print" (sale, purchase, ...) and i want do that from my own module | ||
2013-09-12 17:13 <cedk> prusglajotemis: action can be inactivate using the active field | ||
2013-09-12 17:13 <zodman> cedk: i submit a patch for vatnumber for supporting vat_mx on the issue http://code.google.com/p/vatnumber/issues/detail?id=16 | ||
2013-09-12 17:35 <cedk> zodman: ok but I'm also thinking about mergin vatnumber with stdnum | ||
2013-09-12 17:40 <prusglajotemis> cedk: but when I inactivate action the action keyword still exist (in toolbar). | ||
2013-09-12 17:40 <cedk> prusglajotemis: restart the client | ||
2013-09-12 17:51 <prusglajotemis> cedk: yes I restart client. I inactivate report so what has changed is that when I click on keyword and get error: 'Report (purchase.purchase) not find!') | ||
2013-09-12 19:10 <oscar> how can I to do this in windows: trytond -d MYDB -u my_module? | ||
2013-09-12 19:10 <oscar> with neso | ||
2013-09-12 19:11 <cedk> oscar: you can not | ||
2013-09-12 19:11 <nicoe> oscar: you can not | ||
2013-09-12 19:12 <cedk> oscar: but you can export the DB and import it with the update flag | ||
2013-09-12 19:14 <oscar> cedk and nicoe: Thanks I will try to export and import method | ||
2013-09-12 19:16 <cedk> zodman: also you better update review than delete older and create new | ||
2013-09-12 19:19 <oscar> cedk: where I put the flag "update" for import database | ||
2013-09-12 19:20 <oscar_> cedk and nicoe: Thanks I will try to export and import method? | ||
2013-09-12 19:21 <cedk> oscar_: in the popup that asks for new DB name | ||
2013-09-12 19:25 <oscar_> cedk: Ok, but Popup field database name don't let me put spaces or flags (in Windows) | ||
2013-09-12 19:28 <cedk> oscar_: what are you talking about? | ||
2013-09-12 19:28 <cedk> oscar_: check the checkbox! | ||
2013-09-12 19:35 <oscar_> cedk: thank you is solved! | ||
2013-09-12 20:12 -!- dcormier(~dcormier@2607:fad8:4:6:f2de:f1ff:fe70:193f) has left #tryton | ||
2013-09-12 21:09 <motaro> When you change something on the xml for a view how do you make tryton reload the module? | ||
2013-09-12 21:18 <cedk> motaro: if you change in view/ it is done automaticaly if auto_reload is set | ||
2013-09-12 21:23 <motaro> is not set, thank you. |
Generated by irclog2html.py 2.17.3 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!