Relatorio

Bug 63

classification
Title: Add script to render report from command line
Type: rfe Severity: normal
Components: core Versions:
process
Status: closed Resolution:
Dependencies: Superseder:
Assigned To: ced Nosy List: ced, nicoe, roundup-bot
Priority: normal Keywords:

Created on 2021-07-29 10:42 by ced, last changed 2021-09-10 09:42 by roundup-bot.

Messages
msg158 Author: [hidden] (ced) Date: 2021-07-29 10:42
Sometimes we just want to render an existing template against some data (e.g. for testing).
I think it will be good to have a console script that takes a template as input and a JSON data file and write the result to an output file.
msg159 Author: [hidden] (roundup-bot) Date: 2021-07-29 10:44
New changeset 19ebab52ab53 by Cédric Krier in branch 'default':
Add relatorio-render script
https://hg.tryton.org/public/relatorio/rev/19ebab52ab53
msg164 Author: [hidden] (nicoe) Date: 2021-08-09 10:41
* Cédric Krier  [2021-07-29 10:42 +0200]: 
>Sometimes we just want to render an existing template against some data (e.g. for testing).
>I think it will be good to have a console script that takes a template as
>input and a JSON data file and write the result to an output file.

That's a nice idea but I would use the stdin if args.data is not specified. And
in case it fails to read stdin then use an empty dict.

Also I think that argparse allows to specify that the type of an argument is a
file (but after reading the code they advice against using it for json data).
msg165 Author: [hidden] (roundup-bot) Date: 2021-08-12 23:05
New changeset 3e1925fdb556 by Cédric Krier in branch 'default':
Add relatorio-render script
https://hg.tryton.org/public/relatorio/rev/3e1925fdb556
msg168 Author: [hidden] (roundup-bot) Date: 2021-08-12 23:09
New changeset bf1ed916669d by Cédric Krier in branch 'default':
Add relatorio-render script
https://hg.tryton.org/public/relatorio/rev/bf1ed916669d
msg170 Author: [hidden] (roundup-bot) Date: 2021-08-20 12:52
New changeset 36db590b9a33 by Cédric Krier in branch 'default':
Add relatorio-render script
https://hg.tryton.org/public/relatorio/rev/36db590b9a33
msg171 Author: [hidden] (roundup-bot) Date: 2021-08-20 12:55
New changeset e8cd06d0551c by Cédric Krier in branch 'default':
Add relatorio-render script
https://hg.tryton.org/public/relatorio/rev/e8cd06d0551c
msg175 Author: [hidden] (roundup-bot) Date: 2021-09-10 09:42
New changeset e8cd06d0551c by Cédric Krier in branch 'default':
Add relatorio-render script
https://hg.tryton.org/relatorio/rev/e8cd06d0551c
History
Date User Action Args
2021-09-10 09:42:02roundup-botsetmessages: + msg175
status: pending -> closed
2021-08-20 12:55:13roundup-botsetmessages: + msg171
2021-08-20 12:52:00roundup-botsetmessages: + msg170
2021-08-12 23:09:29roundup-botsetmessages: + msg168
2021-08-12 23:05:49roundup-botsetmessages: + msg165
2021-08-09 10:41:48nicoesetmessages: + msg164
nosy: + nicoe
2021-07-29 10:44:11roundup-botsetmessages: + msg159
nosy: + roundup-bot
status: pending
2021-07-29 10:42:55cedcreate