IRC logs of #tryton for Wednesday, 2010-11-17 #tryton log beginning Wed Nov 17 00:00:02 CET 2010
-!- johbo_( has joined #tryton00:12
-!- johbo( has joined #tryton00:27
-!- kwmiebach( has joined #tryton00:47
-!- rednul( has joined #tryton00:58
-!- johbo_( has joined #tryton01:14
-!- johbo__( has joined #tryton01:19
-!- tony__(~tony@ has joined #tryton01:44
-!- kwmiebach( has left #tryton01:44
-!- johbo( has joined #tryton01:45
-!- johbo_( has joined #tryton02:08
-!- ikks_(~ikks@ has joined #tryton02:20
-!- johbo( has joined #tryton02:24
-!- rednul( has joined #tryton03:18
-!- johbo_( has joined #tryton03:33
-!- plantian( has joined #tryton03:44
-!- johbo( has joined #tryton03:49
-!- johbo_( has joined #tryton04:35
-!- paepke( has joined #tryton04:38
-!- gremly(~gremly@ has joined #tryton04:43
-!- yangoon( has joined #tryton05:18
-!- johbo( has joined #tryton05:21
-!- yangoon( has joined #tryton06:15
-!- johbo_( has joined #tryton06:16
-!- johbo( has joined #tryton06:46
-!- evernichon( has joined #tryton06:48
-!- vladimir_( has joined #tryton07:11
-!- rednul( has joined #tryton07:19
-!- rednul( has joined #tryton07:29
-!- svaksha_(~svaksha@unaffiliated/svaksha) has joined #tryton07:32
-!- svaksha(~svaksha@unaffiliated/svaksha) has joined #tryton07:54
-!- johbo_( has joined #tryton08:12
-!- trifon( has joined #tryton08:28
-!- enlightx( has joined #tryton08:55
-!- Timitos(~kp@ has joined #tryton09:06
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton09:30
-!- bechamel( has joined #tryton09:59
-!- Red15(~red15@unaffiliated/red15) has joined #tryton10:25
cedksharkcz: great10:43
-!- gordon_geeko(~jeroen@ has joined #tryton10:47
cedkgordon_geeko: you could be interested in
gordon_geekocedk: i made the switch to 1.8 yesterday, rebuilt the fedora rawhide packages!10:52
gordon_geekocedk: like the improvements10:53
gordon_geekocedk: ah, i see he's also packaged the modules10:54
-!- paepke( has joined #tryton11:01
gordon_geekois it possible to set the context in an on_change?11:28
cedkgordon_geeko: no (bad practice :-)11:29
gordon_geekocedk: i'd like to set a required attribute on a field from an on_change event11:30
cedkgordon_geeko: this is not a good design because it will depend on the way the form is filled11:32
cedkbut you try this bad practice because it is the only way in OE :-)11:32
cedkgordon_geeko: there is some way to solve this depending of the data model11:33
gordon_geekocedk: yes ;-), would you suggest a function field - and if so, when is that evaluated?11:33
cedkgordon_geeko: but generaly, you must use a PYSON statement in states['required']11:33
cedkgordon_geeko: there is this example:
gordon_geekocedk: this would work for a lookup or calculation?11:34
cedkgordon_geeko: what do you mean by lookup and calculation?11:34
gordon_geekofor example, i need to set required for party move line depending on the account kind11:35
cedkgordon_geeko: so I will create a boolean function field on move that define if party is required or not11:37
cedkgordon_geeko: and put a on_change_with on it11:37
cedkgordon_geeko: it looks like
gordon_geekocedk: ah, thx for the pointers - i'll give it a try11:38
cedkgordon_geeko: one thing you should know is that in Tryton states are validated on server side11:39
cedkgordon_geeko: so the server must always be able to evaluate the PYSON statement then it can not depend on the click scenario11:40
gordon_geekocedk: seems sensible...11:40
-!- paepke( has left #tryton13:02
-!- paepke( has joined #tryton13:45
-!- pepeu(~manuel@ has joined #tryton14:54
-!- gremly(~gremly@ has joined #tryton15:12
-!- hoRn( has joined #tryton15:34
-!- trifon( has joined #tryton16:14
-!- trifon( has joined #tryton16:27
hoRncedk: ping16:55
-!- johbo__( has joined #tryton17:08
cedkhoRn: pong17:12
hoRncedk: you remember my confusion about the issue with the history and the 'you are trying to access a lost entry'? (sale_opportunity)17:14
hoRncedk: i was cleaning up my module and so the problem seems fixed. but i think, the mainproblem behind is, that a posible ROLLBACK isn't rollbacking ;) the _history of the object. Possibly, only an idea ...17:17
hoRncedk: i was manipulating the selection of a SELECTION-field in fields_view_get with wrong datatype - so the transaction was not commited. But there was an entry in the history.17:19
cedkhoRn: normally there is no commit17:28
bechamelhoRn: if there is an error in fields_view_get, the problem appear on read, while history record are created on create, write and delete17:29
hoRnyes - the error came from sale_opportunity_histories readmethod17:39
hoRnfinally - it was a error caused by a mistake of mine - but i was thinking about handling such errors17:41
hoRna similar error can occur, when a copy-action is not done right.17:42
bechamelhoRn: and you do a copy on read ?17:45
cedkhoRn: no, every requests are run in a unique transaction17:45
hoRnno - i did a write and create in a fields_view_get17:46
hoRnon a different model17:47
cedkhoRn: except if you make explicit commit17:48
hoRncedk: i was trying that by updating the _rpc of the model17:49
cedkhoRn: even, it will still stay transactional all over the request17:53
hoRncedk: ok - i will take a deeper dive in this next days - first i have to finish the modul, client ist waiting and angry17:54
-!- rednul( has joined #tryton18:05
-!- paepke( has joined #tryton18:12
-!- johbo( has joined #tryton18:21
-!- paepke( has joined #tryton18:39
-!- gordon_geeko( has joined #tryton19:08
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton19:32
-!- pepeu(~manuel@ has joined #tryton19:48
-!- johbo_( has joined #tryton19:54
-!- rednul( has joined #tryton19:57
-!- FWiesing( has joined #tryton20:06
-!- woakas(~woakas@ has joined #tryton20:12
-!- johbo( has joined #tryton20:33
-!- johbo_( has joined #tryton20:59
-!- udono( has joined #tryton21:24
gordon_geekoi notice that my function field is never called, even with depends - unless i use an on_change_with in the function field21:28
gordon_geekocould this be a bug?21:29
-!- johbo( has joined #tryton21:36
-!- vladimir_(~vladimir@ has joined #tryton21:46
-!- pjstevns( has joined #tryton21:57
-!- pjstevns( has left #tryton21:57
cedkgordon_geeko: could you re-copy/paste the code21:58
-!- vladimir_(~vladimir@ has joined #tryton21:59
gordon_geekocedk: went back to try the earlier issue i had, see:
cedkgordon_geeko: I just think. Do you know that Function field are not called on non-saved records?22:08
gordon_geekocedk: but these records are saved, and it works after manually changin the period field22:10
cedkgordon_geeko: which period field22:10
gordon_geekocedk: the original one from move22:11
gordon_geekocedk: only then is on_change_with called, the get func is never called22:12
cedkgordon_geeko: so you must have something wrong in the field definition22:13
cedkgordon_geeko: but I don't see22:13
-!- paepke( has left #tryton22:22
-!- ccomb( has joined #tryton22:38
-!- ccomb( has left #tryton22:38
-!- jbunting( has joined #tryton22:47
-!- jbunting( has joined #tryton22:49
-!- ccomb( has joined #tryton22:51
-!- ccomb( has left #tryton22:51
-!- jbunting( has joined #tryton22:55
-!- jbunting( has joined #tryton22:56
hoRnIs anybody there?22:59
hoRni have a issue with22:59
hoRnor only the computers are eatin energy ;)23:00
gordon_geekoshouldn't obj.create call default_field?23:08
hoRni think it doesn't - copy has the posibilty to apply default as dict23:12
cedkgordon_geeko: yes if you don't pass value for some fields23:13
hoRni have found a possible issue in sale_opportunity and a small patch - where to post - in issuetracker?23:14
cedkhoRn: see
hoRnto much text - i will use the tracker ;)23:18
-!- nicoe(~nicoe@ has joined #tryton23:19
gordon_geekocedk: for the default, what should i return for a boolean?23:21
gordon_geekocedk: because False isn't working23:22
gordon_geekoneither does 023:24
gordon_geekosomething is wierd23:26
-!- johbo( has joined #tryton23:28
cedkgordon_geeko: it is False normally23:35
cedkgordon_geeko: you should also verify that there is not a ir.default entry for the field23:50
cedkgordon_geeko: if you want you can send me your module, I could find time to analyze the issue23:53

Generated by 2.11.0 by Marius Gedminas - find it at!