IRC logs of #tryton for Monday, 2015-10-05 #tryton log beginning Mon Oct 5 00:00:01 CEST 2015
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton00:24
-!- smarro(~sebastian@ has joined #tryton01:23
-!- yangoon1( has joined #tryton07:01
-!- Telesight( has joined #tryton07:31
-!- frispete( has joined #tryton07:40
-!- rpit(~rpit@2a02:908:e670:3a80:b54d:391c:e614:8bad) has joined #tryton08:02
-!- Timitos( has joined #tryton08:17
-!- udono( has joined #tryton08:17
-!- mrichez( has joined #tryton08:57
-!- aroncero__(~aroncero@ has joined #tryton09:00
-!- albertca( has joined #tryton09:15
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton09:16
-!- vcardon( has joined #tryton09:21
-!- pokoli(~pokoli@unaffiliated/pokoli) has joined #tryton09:30
-!- jvblasco(~seba@ has joined #tryton09:32
-!- tbruyere( has joined #tryton09:47
-!- tbruyere( has joined #tryton09:51
-!- nicoe( has joined #tryton09:54
-!- tbruyere( has joined #tryton10:00
aronceroHi, I want to open a form from a button in a tree view11:00
aronceroIf the action is from the same model, i use11:00
aroncero@ModelView.button_action('model.action_id') in the function11:00
aronceroAnd it works fine11:00
aronceroBut How can I use a function with @ModelView.button to return a other model action id?11:00
aronceroAccording to documentation:11:01
aroncerobutton(cls, records)11:01
aronceroThe function may return an ir.action id ...11:01
aroncerobut if i return 'other_model.action_id' nothing happens11:01
aroncerowhat am I doing wrong?11:01
pokoliaroncero: AFAIU you should return the action id as integer, not the ModelData representation of it11:03
aronceropokoli: ahhh11:03
aronceropokoli: So i must use the pool to search it, no?11:04
pokoliSo Pool().get('').get_id('module', 'xml_id') should work :)11:04
pokoliaroncero: yes, there is the get_id function on in order to convert xml_id to database_id11:04
pokoliaroncero: and you should use the function as there is a cache for it ;)11:05
aronceropokoli: do you know any module that use it? to use an example11:09
pokoliaroncero: I don't remeber it, but a simple grep should point you to the example ;)11:11
cedkaroncero: but the button_action does it because it is syntax is '<module>.<xml id>' just like ModelData.get_id11:18
aroncerocedk: ok, I think I undertand it11:21
aronceropokoli, cedk: Thanks, it works perfect :D11:26
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton12:21
-!- mariomop(~quassel@ has joined #tryton12:45
-!- aroncero(~aroncero@ has joined #tryton13:18
-!- aroncero_(~aroncero@ has joined #tryton13:26
-!- kstenger( has joined #tryton15:11
-!- den2204(~mahon@ has joined #tryton15:13
-!- bvillasanti(~bvillasan@ has joined #tryton15:31
-!- kstenger( has joined #tryton15:35
-!- juanfe(~juanfe@ has joined #tryton16:00
-!- Telesight( has joined #tryton16:07
-!- aroncero(~cristina@ has joined #tryton16:52
aronceroI am looking for documentation about actions and keywords.17:01
aronceroI saw that there are ir.action.act_window ir.action.act_window.view ir.action.act_window.domain,17:02
aroncerowhere can i read about that?17:02
cedkpokoli: will you commit account patch?17:04
pokolicedk: yes, in 10 or 20 minutes moreless17:04
cedkaroncero: I think we don't have17:05
cedkaroncero: looking at the Models should help to understand17:09
cedkaroncero: otherwise ask here any questions17:10
pokolicedk: commited patches17:12
pokoliaroncero: a patch improving the docs will be very welcomed :)17:21
aronceropokoli: I agree, I will try to understand it and make some documentation with examples17:27
pokoliaroncero: feel free to ask whatever you don't understand here17:30
-!- michael-kohlhaas(~michael-k@unaffiliated/michael-kohlhaas) has joined #tryton17:47
-!- smarro( has joined #tryton18:11
-!- bvillasanti(~bvillasan@ has joined #tryton18:22
-!- bvillasanti(~bvillasan@ has joined #tryton18:29
aronceroA ir.action.act_window.view is related with a view and an action.act_window18:32
aronceroIs that a method to say to the action which specific view (form o tree) use?18:32
cedkaroncero: yes18:34
cedkaroncero: and the sequence define the order18:34
aroncerobut I tried using that action in a button function but i received an error18:36
aronceroYou try to read records that don't exist anymore.18:36
aroncero(Document type: ir.action)18:36
cedkaroncero: you must give the id of the ir.action not the ir.action.act_window18:37
aroncerocedk: return Pool().get('').get_id('service_email', 'act_service_email_form_view1')18:39
cedkaroncero: that's a view not an ir.action.act_window18:43
aroncerocedk: it is a ir.action.act_window.view18:45
aroncerocedk: <record model="ir.action.act_window.view" id="act_service_email_form_view1">18:45
cedkaroncero: yes it is what I said18:45
cedkaroncero: it is a view not an act_window18:46
aroncerocedk: ok, i think that a ir.action.act_window.view is a ir.action.act_window that open a specific view18:47
cedkaroncero: not it is a view18:49
aroncerocedk: ok... So an ir.action.act_window.view is the view that the action must open18:54
cedkaroncero: yes18:55
-!- mariomop(~quassel@ has joined #tryton18:56
aroncerocedk: Thanks18:57
-!- vcardon( has left #tryton19:07
-!- pablovannini(~pablo@ has joined #tryton19:50
-!- rpit(~rpit@2a02:908:e670:3a80:6e:7b6a:3e1d:61ff) has joined #tryton20:07
-!- bvillasanti(~bvillasan@ has joined #tryton20:14
-!- bvillasanti(~bvillasan@ has joined #tryton20:16
-!- bvillasanti(~bvillasan@ has joined #tryton20:46
-!- bvillasanti(~bvillasan@ has joined #tryton21:23
-!- bvillasanti(~bvillasan@ has joined #tryton22:32
-!- bechamel( has joined #tryton22:38

Generated by 2.11.0 by Marius Gedminas - find it at!