IRC logs of #tryton for Thursday, 2020-05-28

chat.freenode.net #tryton log beginning Thu 28 May 2020 12:00:01 AM CEST
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton00:04
-!- SimAlbertiBeltra(sim6matrix@gateway/shell/matrix.org/x-iymojqunwwjznynn) has joined #tryton00:36
-!- thaneor(~ldlc6@r186-54-245-250.dialup.adsl.anteldata.net.uy) has joined #tryton02:22
-!- springwurm(~Springwur@5.104.149.54) has joined #tryton04:57
-!- mrichez(~Maxime@2a02:a03f:467c:d500:a385:4ecf:c4ea:d8cf) has joined #tryton05:38
-!- Timitos(~kpreisler@2001:a61:5ad:c901:762b:62ff:fe84:ed7e) has joined #tryton06:21
-!- rpit(~rpit@p200300c88f094100da82d2c817b701d0.dip0.t-ipconnect.de) has joined #tryton06:22
-!- rpit(~rpit@p200300c88f094100da82d2c817b701d0.dip0.t-ipconnect.de) has joined #tryton06:26
-!- udono(~udono@048-135-067-156.ip-addr.inexio.net) has joined #tryton06:32
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton06:37
-!- nicoe(~nicoe@2a02:578:852a:c00:7e2a:31ff:fe5e:b25d) has joined #tryton08:39
mrichezhi, is there only fields that can be used in xml tree ? or could this apply to a property ? Concrete example: i'm storing density of a product material (density uom is weight and volume), so in my model i'm using 2 many2one fields to get each uom. But in treeview, i would display uom with format ("weight_uom/volume_uom"). Is the best way to use a function field to return a new string with both uoms?09:52
cedkmrichez: why not using a new category of measure density?10:08
mrichezcedk: because i'm using it to calculate a theoretical weight of the product, (volume * density = weight) so i need to know uom factor10:14
cedkmrichez: maybe you could have a cross unit conversion definition10:26
mrichezcedk: heuuu...10:27
mrichezcedk: so it implies a new model for cross unit ? and then associate this cross unit to density model ?10:29
cedkyes we could store that 1 volume * 1 density = x weight10:33
mrichezcedk: ok, but don't know if there's other example of cross unit ? 1 model for 1 case ? useful ?10:36
-!- mariomop(~quassel@190.193.24.15) has joined #tryton10:46
pokolimrichez: speed is similar: Distance / Time11:07
pokolimrichez: strengh also: Mass / Aceleration11:08
mrichezpokoli: :-)11:23
-!- cedk(~ced@gentoo/developer/cedk) has joined #tryton11:29
-!- springwurm(~Springwur@5.104.149.54) has joined #tryton11:57
mrichezback with cross unit: how would be this new model added to product.uom ? i'm lost... :-)12:02
-!- LordVan|Work(~LordVan@gentoo/developer/LordVan) has joined #tryton12:18
mrichezcedk: could it be a model like this : https://pastebin.com/9uiCGxz712:24
cedkmrichez: I think it should only be based on categories12:27
cedkbecause we need to have only one result for the product of two categories12:27
cedkso it would be: category1 * category2 = x unit12:28
cedkand anoption for category1 / category2 = x unit12:28
mrichezcedk: what would be the choice of the uom in the category then ?12:29
cedkmrichez: 112:30
mrichezcedk: so let's says i add a new cross_unit that would be "Density" category 1 is Weight, category2 is Volume... how user can get this uom in Gr/mm³  ?12:35
cedkmrichez: it will depend on the base unit of weight and volume12:36
LordVan|Workhi13:07
LordVan|Workjust trying to install newest trytond + modules on a new box to test something13:08
LordVan|Workany clue why it wants no 3.8 ?13:08
LordVan|WorkThe following USE changes are necessary to proceed:13:08
LordVan|Work (see "package.use" in the portage(5) man page for more details)13:08
LordVan|Work# required by trytond (argument)13:08
LordVan|Work>=app-office/trytond-5.6.0 -python_targets_python3_813:08
LordVan|WorkI mean i don'T mind if i use 3.7 or 3.8 just wondering13:09
LordVan|Workoh tryton 5.6 supports weasyprint.. anyone want to share experiences?13:23
cedkLordVan|Work: not all modules in Gentoo supports 3.8 because of missing dependencies declaration13:42
cedkLordVan|Work: I think 3.7 is fully supported13:43
LordVan|Workcedk, yeah i suspected that but thanks for confirming ;)13:46
cedkLordVan|Work: I find that python version management in Gentoo too much complicated13:50
cedkLordVan|Work: and too slow to update13:50
LordVan|Workcedk, hmm id on'T mind that, but sometimes too slow - especially the deps13:51
cedkI think most packages should work on new version of Python without issue13:51
LordVan|Workcedk, alternatively i could of course use virtualenv, but well13:51
LordVan|Workcedk, yeah but they need to be checked by the maintainer(s)13:51
cedkLordVan|Work: well as long as they do not require compilation, the odds is very low that they will not work on the next version13:52
LordVan|Workyeah i know13:52
cedkand now that Python release a new version every year, it is worse13:52
LordVan|Workhm i don'T have too much time for gentoo at the moment unfortunately (used to be active in the python team )13:55
LordVan|Workthat said i often just use virtualenv anyway13:55
LordVan|Workcedk, since you are here .. can weasyprint replace the opendocument reports,..?14:02
LordVan|Workor is it not that far (yet)?14:02
pokoliLordVan|Work: weasyprint is used for converting html reports into pdf14:03
LordVan|Workyes but can that with html reports  (feasibly) replace open document ones?14:04
pokoliLordVan|Work: yes, but you will need to design your own reports14:04
pokoliLordVan|Work: all the base reports are odt based14:04
LordVan|Workwell i was going to make custom reports for just about anything anyway so i might have a look at that14:04
pokoliLordVan|Work: you just need to create the report with html extensions and pdf output format14:04
pokoliLordVan|Work: and trytond will use weasyprint for conversion and fallback to libreoffice is not available14:05
cedkthe main difficult is that HTML is not really designed to make printed document14:05
pokoliACTION bbl14:05
LordVan|Worki like the idea of not needing libreoffice installed on the server14:05
LordVan|Workcedk, true14:05
LordVan|Workxml/fop would be more suitable14:05
LordVan|WorkI did some xml+ fop stuff several years ago .. very precise control from what i remember14:06
LordVan|Workdo you know if anyone tried generating reports that way before ?14:06
LordVan|Work-- to be fair libreoffice docs have the advantage they can be edited later if you need to do anything special14:07
-!- thaneor1(~ldlc6@179.26.158.99) has joined #tryton14:24
pokoliLordVan|Work: it should be doable to override the report module to generate the pdf in the format you want14:36
pokoliLordVan|Work: You can use Genshi (the template engine) to render the xml and the convert it to pdf using fop latter14:37
-!- mrichez(~Maxime@2a02:a03f:467c:d500:a385:4ecf:c4ea:d8cf) has joined #tryton17:03
-!- mrichez(~Maxime@2a02:a03f:467c:d500:a385:4ecf:c4ea:d8cf) has joined #tryton18:06

Generated by irclog2html.py 2.17.3 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!