IRC logs of #tryton for Wednesday, 2013-03-27

chat.freenode.net #tryton log beginning Wed Mar 27 00:00:01 CET 2013
Hamragreetings everyone, on the windows client, what should i do to have the buttons (like "next record" "new record" "switch view" etc..) appear in the language the user chose?10:47
-!- rpit58(~ralf@dslb-088-071-234-098.pools.arcor-ip.net) has left #tryton10:59
-!- rpit(~ralf@dslb-088-071-234-098.pools.arcor-ip.net) has left #tryton10:59
prusglajotemiscedk: yesterday i asked about BOM's tab, but today my situation is that:10:59
prusglajotemiscedk: on one tryton server I see bom's, default locations and Products, but on other tryton server I see only Variants. both tryton servers identical (cloned from trunk) but on different computers.11:00
cedkprusglajotemis: I guess they are not the same11:01
prusglajotemiscedk: maybe it depends on some python's libs or lib version ?11:06
prusglajotemiscedk: ok then what situation should de to see only Varinats in product form ?11:08
cedkprusglajotemis: if it is a service11:17
prusglajotemiscedk: but I see Variants then product type is Goods11:22
mrechteHello. Please is this type of code construction correct:11:50
mrechtejournals = Journal.browse(...)11:50
mrechtefor journal in journals11:51
mrechte.. moves = Move.browse(...)11:51
mrechte.. journal.moves = moves11:51
mrechteI wish to pass "journals" to a report11:53
coepsHi, I havent found any hint towards Attachments in the docs. Is there a way to attach files as attachment by using the API ?? For example, it would be nice to add a report directly as an attachment when it is created.12:09
cedkcoeps: attachment is just a Model like any other12:12
cedkmrechte: it is not clear what you want to do12:13
mrechtecedk: I created the following code review: http://codereview.tryton.org/747004/12:43
cedkmrechte: can read anything and more over codreview of Tryton is for Tryton dev.12:45
coepsIs it possible to use multiple inheritance, like inherit another producttype  from product.template. If yes, must the template hold a One2Many field to each childclass?14:57
coepsThe docs only require the Many2One field in the spezialized class15:07
cedkcoeps: _inherits is gone in the next release15:09
cedkcoeps: better to no more develop base on it15:09
coepscedk: Thanks for the warning. Will inheritance be removed as a feature or will it be replaced by another concept?15:11
cedkcoeps: just removed15:11
cedkcoeps: indeed it doesn't change anything to the data modeling, it is just how you can display/create record that is changed15:14
coepscedk: I am confused, do you refer to inheritance (feature) or to the One2Many field question?15:17
cedkcoeps: inheritance15:23
-!- the_ant(~asep@180.247.138.78) has left #tryton15:48
coepscdek: if inheritance is removed, will there be (or already is) another way to save coding when two models needs to be separated bur share a lot of common functionality?16:18
coepsmy plan was to implement the common stuff in a template and use 3 different children for the separation and the special functionality16:18
cedkcoeps: you can use Python oop16:19
coepscedk: but not including fields or?16:20
cedkcoeps: why?16:23
coepscedk: The moment your wrote that I had an Idea. One more detail, will there be a table for the baseclass in the db? or will the fields from the baseclass just be existent in the childtables?16:26
cedkcoeps: if you use Python oop, each Model will write in his own table16:30
cedkcoeps: but if you can have a look at product template/variant in trunk to see how you can do to share common values16:31
coepscedk: Am I correct that __getattr__ does the trick in template/variant?16:52
cedkcoeps: yes but only on server side16:55
coepscdek: I don't see how it is done on the client, but with seeing it in the client at the time will help. However, the new way of defining views, is that how it will be done from Version2.8 on?18:38
coepscedk: what I mean is the ir.ui.view part, separated and without cdata tag.18:39
cedkcoeps: yes18:41
cedkcoeps: it is already working in 2.6 but modules was not converted on time18:41
coepscdek: cool, so I know what I have todo now. The views are identified by the filename and must ly in the "view" subfolder. Anymore to consider?18:43
cedkcoeps: no18:43
coepscdek: Thanks18:43
coepscdek: You wrote that when using python oop, each model will create its own table. I created a baseclass A(Modelview,Modelsql) and created 2 subclases (sub(A), sub2(B)) in python style. Both subclasses have a custom field. In the database there is only one table module_baseclass. The fields of the subclass are just added to the baseclass. Did I totally misunderstand you?20:44
coepscdek: When marking both fields in subclass as required, I cannot add a single field to the table (I created a form for each model), since always one constraint is violated.20:45
cedkcoeps: of course a table is created for each Model you register20:50
cedkcoeps: but you can use Mixin to prevent that20:50
coepscdek: my classes are listed in __init__.py.register(), do I need to register them differently?20:53
cedkcoeps: I don't know what you want to do20:54
coepscedk: I think I found it (but I still have to test it). When adding the baseclass Base to the __ini__py.register() method, only the baseclass_table is created. The subcluass_tables are not created. When I remove it and only have the Subclasses registered, their tables will be created and (of course) not the baseclass one.21:00
coepscdek: in the first case, baseclass and subclasses are given to register() as arguments.21:01

Generated by irclog2html.py 2.11.0 by Marius Gedminas - find it at mg.pov.lt!