IRC logs of #tryton for Saturday, 2012-03-17

chat.freenode.net #tryton log beginning Sat Mar 17 00:00:02 CET 2012
2012-03-17 00:16 <cjbarnes18> hope someone can help with this, is it possible to evaluate a function within a domain declaration?
2012-03-17 00:20 <cedk> cjbarnes18: no you just have PYSON
2012-03-17 00:22 <cedk> cjbarnes18: http://doc.tryton.org/2.2/trytond/doc/topics/pyson.html
2012-03-17 00:24 <cjbarnes18> cedk: So no using functions in Eval(), ok, thanks.
2012-03-17 00:25 <cedk> cjbarnes18: the goal behind PYSON is to work with any language
2012-03-17 00:26 <cjbarnes18> I want to limit the domain based on stored records, could you suggest a way to do this?
2012-03-17 00:27 <cjbarnes18> was thinking PYSON Not(In()) but how to generate the list?
2012-03-17 00:27 <cedk> cjbarnes18: not sure to understand
2012-03-17 00:29 <cjbarnes18> I am working on a timetable model, the timetabe uses periods, only one of each period per day.
2012-03-17 00:30 <cjbarnes18> when creating the records for each day I only want to have available the periods not allready used. creating the
2012-03-17 00:31 <cedk> cjbarnes18: how do you know a period is used?
2012-03-17 00:31 <cjbarnes18> a register record links to the timetable.
2012-03-17 00:33 <cjbarnes18> so when creating a new register record can be created later so time based limitation is not useful.
2012-03-17 00:33 <cedk> cjbarnes18: looks like the relation should be the other way
2012-03-17 00:34 <cjbarnes18> cedk: sorry my client is misbehaving...
2012-03-17 00:36 <cjbarnes18> the resgister is the daily log. it is a register if timetable compliance. the register is many to one with the timetable.
2012-03-17 00:37 <cjbarnes18> * register of
2012-03-17 00:40 <cedk> cjbarnes18: so I don't understand
2012-03-17 00:41 <cjbarnes18> so when I create a new register record I only want to show timetable records not created foe the given day.
2012-03-17 00:43 <cedk> cjbarnes18: do you have the day on the timetable?
2012-03-17 00:44 <cjbarnes18> I have the day of the week and that part of the domain is allready working.
2012-03-17 00:44 <cjbarnes18> but no date value in the timetable
2012-03-17 00:45 <cjbarnes18> only in the register.
2012-03-17 00:48 <cjbarnes18> here is the sql version of what I want to do -> select name from timetable where timetable.id not in (select timetable_id from register where date = today())
2012-03-17 00:49 <cjbarnes18> I want to use this logic in the domain
2012-03-17 00:50 <cedk> cjbarnes18: don't think it is possible
2012-03-17 00:51 <cjbarnes18> cedk: thank you very much for your time. youve saved me loads.
2012-03-17 00:58 <cedk> cjbarnes18: but why not make the link the other way
2012-03-17 01:00 <cjbarnes18> cedk: do you mean open the timetable record and grate register from there?
2012-03-17 01:00 <cjbarnes18> *create
2012-03-17 01:02 <cedk> cjbarnes18: I mean store register id on timetable
2012-03-17 01:06 <cjbarnes18> cedk: I dont see how this solves the problem.
2012-03-17 01:08 <cedk> cjbarnes18: you can make register.date != today()
2012-03-17 01:18 <cjbarnes18> cedk: sorry, stil not getting it. as far as I can tell this could only work if I have 1 timetable record for each potential register record.
2012-03-17 01:18 -!- sisalp(~dominique@annecy.sisalp.net) has left #tryton
2012-03-17 01:26 <cjbarnes18> cedk: dont worry, I will leave it with SQL constraints. Thank you again for your time.
2012-03-17 07:28 -!- shalabhaggarwal(~shalabhag@110.234.18.80) has left #tryton
2012-03-17 12:08 <albertca> cedk: I don't get what your solution is with respect to http://codereview.tryton.org/195001/diff/27001/payment_term.py#newcode148
2012-03-17 12:08 <albertca> cedk: If we cannot write NULLs with integer fields and we actually write a zero, how do you intend to fix it?
2012-03-17 12:47 <cedk> albertca: soon it will be possible to have null
2012-03-17 12:49 <albertca> cedk: ok. so I wait for the patch to be commited?
2012-03-17 12:49 <cedk> albertca: no
2012-03-17 12:49 <cedk> albertca: it is just the check will not work
2012-03-17 12:51 <albertca> cedk: But if I only allow day to be between 1 and 31 and there's no way the user can store NULL he will be forced to use at least payment day 1.
2012-03-17 12:53 <cedk> albertca: there will be
2012-03-17 13:02 <albertca> cedk: ok
2012-03-17 18:00 <cce> cdek: I'm not sure why you'd use HgNested over Subrepositories
2012-03-17 18:00 <cce> cedk: ^
2012-03-17 18:03 <cce> ACTION wonders if there is a way to hg clone tryton and all modules?
2012-03-17 18:06 <albertca> cce: hg nclone http://hg.tryton.org/trytond/
2012-03-17 18:06 <cce> nclone is added by hgnested?
2012-03-17 18:08 <cce> albertca: cool, thank you
2012-03-17 18:11 <cce> albertca: you use bitbucket for your fork?
2012-03-17 18:11 <cce> (looks historical)
2012-03-17 18:22 <cedk> cce: subrepositories don't match our needs
2012-03-17 18:22 <cce> Right, that was obvious... I just don't know why.
2012-03-17 18:22 <cce> cedk: listing to your videos, thank you for making them.
2012-03-17 18:24 <cedk> cce: because subrepositories ensure you have all of them and we want the freedom to select modules
2012-03-17 18:24 <cce> ACTION nods.
2012-03-17 18:26 <cce> ACTION wonders how to "install" the trytond tables in a PostgreSQL databaase
2012-03-17 18:26 <cce> and install test data ;)
2012-03-17 18:26 <cce> The 'install.rst' file doesn't provide any direction in this regard.
2012-03-17 18:27 <cedk> cce: first there is no test data
2012-03-17 18:27 <cce> Ok.
2012-03-17 18:27 <cedk> cce: https://code.google.com/p/tryton/wiki/SetupAndStart
2012-03-17 18:28 <cce> ah, great, ty
2012-03-17 18:33 <cce> cdek: do you have a regression test database dump?
2012-03-17 18:33 <cce> er, cedk
2012-03-17 18:33 <cce> ACTION apologizes.
2012-03-17 18:33 <cce> ACTION was just looking to explore.
2012-03-17 18:34 <cedk> cce: we have tests
2012-03-17 18:34 <cedk> http://tests.tryton.org/~test/postgresql.html
2012-03-17 18:42 <cce> ACTION nods.
2012-03-17 18:43 <cce> ACTION was just hoping to find a database /w sample data.
2012-03-17 18:44 <cce> cedk: thank you for your help today

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