chat.freenode.net #tryton log beginning Fri May 28 12:00:01 AM CEST 2021 | ||
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton | 23:04 | |
-!- springwurm(~springwur@5.104.149.54) has joined #tryton | 04:56 | |
-!- mrichez(~Maxime@2a02:a03f:c2e8:f900:ed77:85ea:af2b:ba6e) has joined #tryton | 05:03 | |
-!- Timitos(~kpreisler@2001:a61:4ac:5b01:762b:62ff:fe84:ed7e) has joined #tryton | 06:00 | |
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton | 06:26 | |
-!- acaubet(~Thunderbi@194.224.31.235) has joined #tryton | 07:05 | |
cedk | pokoli: would you mind if I work on the budget modules? | 07:23 |
---|---|---|
pokoli | cedk: no, please go ahead | 07:25 |
pokoli | cedk: can we backport translation fixes if they fix a crash? | 07:25 |
pokoli | I did not test but I guess this fix produces a crash: https://hg.tryton.org/weblate?cmd=changeset&node=1e7f984fa958 | 07:25 |
cedk | pokoli: I think we manage such case and avoid crash | 07:26 |
pokoli | cedk: great, so I will do nothing unless I get a crash report. Thanks | 07:27 |
-!- ludo2(~Thunderbi@193.33.57.196) has joined #tryton | 07:27 | |
LordVan | cedk, I was trying to figure ot where I can add some extra logic (fill in some custom fields I added) when the componets of a kit are added on sale quotation .. | 07:35 |
LordVan | but to be honest I am still unsure .. is this something that'd need to be done in the OrderLineMixin? | 07:37 |
LordVan | set_components seems like it would be the correct method | 07:39 |
LordVan | but i am unsure how to best go about overwriting that | 07:39 |
-!- thaneor1(~ldlc6@r167-61-68-22.dialup.adsl.anteldata.net.uy) has joined #tryton | 07:42 | |
LordVan | or could I hook into some method in the SaleLine methods to do this? (I want to copy a field from the "parent" of the components to the components itself | 07:49 |
mrichez | hi, is it possible to use a language only for interface use, not for translation ? i mean duplicating english language with french format settings (number, date) but i don't want to have translation in this mixed language (product name, ...) just for the interface | 07:55 |
cedk | LordVan: I guess you should extend set_components | 08:14 |
cedk | mrichez: not really because the call is to have the same display everywhere | 08:14 |
cedk | mrichez: but you could extend User._get_preferences to change the locale for the user | 08:15 |
LordVan | cedk, ok thanks i will look into it more then i just didn'T want to be completely somewhere else | 08:15 |
mrichez | cedk: ok, i'll try to extend user, would be better solution... thanks | 08:16 |
-!- springwurm(~springwur@5.104.149.54) has joined #tryton | 08:37 | |
LordVan | cedk, that said to keep it simpler (for me at least) I was considering just adding some code to my on_change_product (which seems to be called as my code is executed and my custom fields filled in) .. so that if the current line is the component of a kit to just add the data needed .. or do you think that would possibly cause some issues I am not thinking of right now? | 08:57 |
LordVan | https://github.com/LordVan/tryton-modules/blob/3c7bf2d83c97644eee8053301695d5cfad42d6f4/rm_extra_data/sale.py#L281 <- that method | 08:58 |
cedk | pokoli: there was a reason to use negative value for the budget compare to the income statement? | 08:58 |
LordVan | I'd have to be able to reliably tell if it was added as a component or as an individual sale line though .. | 08:59 |
LordVan | hm | 08:59 |
cedk | LordVan: why not if it makes sense for your use case | 08:59 |
LordVan | cedk, is there a reliable way to make sure it was not added individually, but as part of a kit? | 09:00 |
cedk | LordVan: no | 09:01 |
pokoli | cedk: I do not remember but it sounds like a fix to have the same amounts due to some wrong computing of the income amount (as its reversed from the usual debit - credit) | 09:06 |
cedk | pokoli: looking at some example it seems that it is a common practice | 09:07 |
pokoli | mrichez: maybe you can a derivative language from english which sets the french formating. Something like en_FR | 09:08 |
cedk | I guess it comes from the idea that it is expense to consume and revenue to fill | 09:08 |
pokoli | cedk: yes, from the bugdet (and also income) PoV the expense consume and the revenue fills | 09:09 |
mrichez | pokoli: that was my first idea but if i click on translation (for example product name, i got now translation for English and for English_FR), it just need this language for interface | 09:10 |
pokoli | mrichez: of course, as it's a new language. So only option is to extend User._get_preferences | 09:13 |
mrichez | pokoli: :-) | 09:15 |
cedk | pokoli: I'm going to change the amount management, I think it should be based on a sum of children + the node amount (which could be empty) | 09:22 |
cedk | like that there is no need for a validation | 09:22 |
pokoli | cedk: this is the same as we do on accounting, so for me it makes sense | 09:25 |
LordVan | cedk, hmm what about adding a boolean field to the line mixin so that one can determine if it was added automatically as part of a kit or not? | 09:29 |
LordVan | or do you think this is not something that could be useful in general (not just for me) ? | 09:29 |
cedk | LordVan: I do not see use case for that | 09:31 |
LordVan | well only for "special" treatment for sale/purchase lines like in my case | 09:31 |
LordVan | I want to treat the sale lines differently if it was added as a component of a kit or individually. Like on the delivery note I want it to just list the kit, not all the components | 09:35 |
LordVan | actually I have to admit I have to read up on how I would override/extend the set_components method of the ORderMixin class which is returned by order_mxin(prefix) | 09:37 |
LordVan | [also I have no idea how the whole Mixin stuff works] | 09:38 |
cedk | LordVan: then you should use a kit product and not a goods with components | 09:43 |
LordVan | that said i could just try to figure it out by looping through the sale lines and when i find a kit added then do my custom stuff for the components | 09:43 |
LordVan | cedk, i am not sure what you mean with that | 09:44 |
LordVan | I am just thinking it might be more useful to elaborate this on discuss with examples and reasoning as to why I want to do this than trying to explain here ;) | 09:47 |
-!- dee(4fe6e7c6@p4fe6e7c6.dip0.t-ipconnect.de) has joined #tryton | 09:52 | |
pokoli | LordVan: the sale process behaves diferently if the product with components is of type kit or its a goods one | 09:56 |
LordVan | hm | 09:57 |
pokoli | LordVan: If you use a kit product, only the kit line will apear on sale but the stock moves will be created using the components | 09:57 |
LordVan | but could I "abuse" that to fill in my custom fields? | 09:57 |
LordVan | pokoli, yes i read that code | 09:57 |
pokoli | LordVan: you can use this type to diferentiate what to print on each report | 09:58 |
LordVan | ah | 10:00 |
LordVan | the line type | 10:00 |
cedk | kit vs goods is not really about the reporting but how components are invoiced and at which price | 10:32 |
LordVan | cedk, yes I understand that but for me it would be useful to have that differentiaton for the report too | 11:02 |
-!- ludo2(~Thunderbi@221.114.141.88.rev.sfr.net) has joined #tryton | 11:04 | |
-!- mariomop(~quassel@181.29.189.235) has joined #tryton | 11:04 | |
-!- ludo3(~Thunderbi@2001:912:1480:380::1) has joined #tryton | 11:11 | |
pokoli | LordVan: it seems you are building a system just to generate reports :O | 11:14 |
LordVan | pokoli, generating reports is a large part yes | 11:15 |
LordVan | -- if you consider delivery notes and invoices also reports | 11:15 |
LordVan | that is the next part | 11:15 |
pokoli | LordVan: yes they are reports but also a separate document, not just sales | 11:19 |
LordVan | yes of course | 11:20 |
LordVan | i am just doing my very last adjustments for sale reports (now that product kits are available that is all that is left before i move on to delivery notes and invoices) | 11:20 |
LordVan | pokoli, but basically i do not want to move on to replacing the next part(S) of our workflow with tryton before this one is done (ok technically speaking there is a small detail that needs to be still done, but that is related to offers & offer numbers, but that is low priority) | 11:22 |
-!- ludo2(~Thunderbi@193.33.57.196) has joined #tryton | 11:54 | |
-!- lucascastro(~lucascast@177-185-133-236.dynamic.isotelco.net.br) has joined #tryton | 12:08 | |
-!- springwurm(~springwur@5.104.149.54) has joined #tryton | 12:08 | |
-!- ludo2(~Thunderbi@193.33.57.196) has joined #tryton | 12:49 | |
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton | 13:12 | |
-!- Pilou(~Pilou@rogoth.ir5.eu) has joined #tryton | 16:55 | |
-!- Pilou(~Pilou@pdpc/supporter/active/pilou) has joined #tryton | 16:55 | |
-!- ludo2(~Thunderbi@221.114.141.88.rev.sfr.net) has joined #tryton | 19:01 | |
-!- thaneor(~ldlc6@r167-61-79-56.dialup.adsl.anteldata.net.uy) has joined #tryton | 19:44 |
Generated by irclog2html.py 2.17.3 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!