Tryton Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(16)

Issue 45241002: account_es: Allow to export tax reports as file

Can't Edit
Can't Publish+Mail
Start Review
Created:
1 month, 2 weeks ago by pokoli
Modified:
4 days, 7 hours ago
Reviewers:
ced, reviewbot
Visibility:
Public.

Description

Patch Set 1 #

Patch Set 2 : Include all keys in reports and add computations on report #

Patch Set 3 : Include more keys on aditional record #

Patch Set 4 : Complete aeat 303 file #

Total comments: 27

Patch Set 5 : Fix comments and do not use sum_keys on reports #

Total comments: 7

Patch Set 6 : Add menu entry, scenario and fix comments #

Patch Set 7 : Validate data on wizard #

Total comments: 11
Unified diffs Side-by-side diffs Delta from patch set Stats (+566 lines, -0 lines) Patch
M CHANGELOG View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
M __init__.py View 1 2 3 4 5 1 chunk +17 lines, -0 lines 1 comment Download
A aeat111.txt View 1 2 3 4 1 chunk +1 line, -0 lines 0 comments Download
A aeat115.txt View 1 2 3 4 1 chunk +1 line, -0 lines 0 comments Download
A aeat303.txt View 1 2 3 1 chunk +1 line, -0 lines 0 comments Download
A reporting.py View 1 2 3 4 5 6 1 chunk +327 lines, -0 lines 7 comments Download
A reporting.xml View 1 2 3 4 5 1 chunk +45 lines, -0 lines 2 comments Download
A tests/scenario_reporting.rst View 1 2 3 4 5 1 chunk +156 lines, -0 lines 1 comment Download
M tests/test_account_es.py View 1 2 3 4 5 2 chunks +8 lines, -0 lines 0 comments Download
M tryton.cfg View 1 chunk +1 line, -0 lines 0 comments Download
A view/print_aeat_report_start_form.xml View 1 2 3 4 5 1 chunk +8 lines, -0 lines 0 comments Download

Messages

Total messages: 24
pokoli
1 month, 2 weeks ago (2018-05-31 15:55:02 UTC) #1
reviewbot
flake8 OK URL: https://codereview.tryton.org/45241002
1 month, 2 weeks ago (2018-05-31 16:24:44 UTC) #2
pokoli
Include all keys in reports and add computations on report
1 month, 2 weeks ago (2018-06-01 13:09:42 UTC) #3
reviewbot
flake8 OK URL: https://codereview.tryton.org/45241002
1 month, 2 weeks ago (2018-06-01 13:28:45 UTC) #4
pokoli
Include more keys on aditional record
1 month ago (2018-06-15 12:13:36 UTC) #5
reviewbot
flake8 OK URL: https://codereview.tryton.org/45241002
1 month ago (2018-06-15 12:30:36 UTC) #6
pokoli
Complete aeat 303 file
3 weeks, 5 days ago (2018-06-19 11:22:36 UTC) #7
reviewbot
flake8 OK URL: https://codereview.tryton.org/45241002
3 weeks, 5 days ago (2018-06-19 11:28:13 UTC) #8
ced
It will be good to have tests. https://codereview.tryton.org/45241002/diff/60001/reporting.py File reporting.py (right): https://codereview.tryton.org/45241002/diff/60001/reporting.py#newcode43 reporting.py:43: periods = ...
3 weeks, 5 days ago (2018-06-19 13:05:16 UTC) #9
pokoli
https://codereview.tryton.org/45241002/diff/60001/tax.xml File tax.xml (right): https://codereview.tryton.org/45241002/diff/60001/tax.xml#newcode855 tax.xml:855: <field name="code">32</field> On 2018/06/19 13:05:16, ced wrote: > Why ...
3 weeks, 3 days ago (2018-06-21 16:04:29 UTC) #10
ced
https://codereview.tryton.org/45241002/diff/60001/tax.xml File tax.xml (right): https://codereview.tryton.org/45241002/diff/60001/tax.xml#newcode855 tax.xml:855: <field name="code">32</field> On 2018/06/21 16:04:29, pokoli wrote: > On ...
3 weeks, 3 days ago (2018-06-21 16:31:08 UTC) #11
ced
https://codereview.tryton.org/45241002/diff/60001/tax.xml File tax.xml (right): https://codereview.tryton.org/45241002/diff/60001/tax.xml#newcode855 tax.xml:855: <field name="code">32</field> On 2018/06/21 16:31:08, ced wrote: > On ...
3 weeks, 3 days ago (2018-06-21 20:37:38 UTC) #12
pokoli
About adding test I understand that you are asking for a test scenario that executes ...
3 weeks, 2 days ago (2018-06-22 09:21:02 UTC) #13
pokoli
Fix comments and do not use sum_keys on reports
3 weeks, 2 days ago (2018-06-22 09:21:23 UTC) #14
reviewbot
flake8 OK URL: https://codereview.tryton.org/45241002
3 weeks, 2 days ago (2018-06-22 09:34:40 UTC) #15
ced
On 2018/06/22 09:21:02, pokoli wrote: > About adding test I understand that you are asking ...
3 weeks, 2 days ago (2018-06-22 10:16:41 UTC) #16
ced
https://codereview.tryton.org/45241002/diff/60001/reporting.py File reporting.py (right): https://codereview.tryton.org/45241002/diff/60001/reporting.py#newcode43 reporting.py:43: periods = Period.browse(Transaction().context['periods']) On 2018/06/22 09:21:01, pokoli wrote: > ...
3 weeks, 2 days ago (2018-06-22 10:26:03 UTC) #17
pokoli
Add menu entry, scenario and fix comments
1 week, 6 days ago (2018-07-02 15:57:37 UTC) #18
pokoli
https://codereview.tryton.org/45241002/diff/80001/reporting.py File reporting.py (right): https://codereview.tryton.org/45241002/diff/80001/reporting.py#newcode53 reporting.py:53: if end_month - start_month > 0: On 2018/06/22 10:26:03, ...
1 week, 6 days ago (2018-07-02 15:57:40 UTC) #19
ced
https://codereview.tryton.org/45241002/diff/80001/reporting.py File reporting.py (right): https://codereview.tryton.org/45241002/diff/80001/reporting.py#newcode198 reporting.py:198: assert len(set(p.fiscalyear for p in periods)) == 1, ( ...
1 week, 6 days ago (2018-07-02 16:19:24 UTC) #20
reviewbot
flake8 OK URL: https://codereview.tryton.org/45241002
1 week, 6 days ago (2018-07-02 16:29:02 UTC) #21
pokoli
Validate data on wizard
1 week, 5 days ago (2018-07-03 09:07:01 UTC) #22
reviewbot
flake8 OK URL: https://codereview.tryton.org/45241002
1 week, 5 days ago (2018-07-03 09:13:09 UTC) #23
ced
4 days, 7 hours ago (2018-07-11 13:13:19 UTC) #24
https://codereview.tryton.org/45241002/diff/120001/__init__.py
File __init__.py (right):

https://codereview.tryton.org/45241002/diff/120001/__init__.py#newcode4
__init__.py:4: from . import reporting
For consistency, it should be named: account_reporting

https://codereview.tryton.org/45241002/diff/120001/reporting.py
File reporting.py (right):

https://codereview.tryton.org/45241002/diff/120001/reporting.py#newcode51
reporting.py:51: context['fiscalyear'] = str(periods[0].start_date.year)
Should it not called: year

https://codereview.tryton.org/45241002/diff/120001/reporting.py#newcode170
reporting.py:170: __name__ = 'account.es.aeat.303'
I would name them: account.reporting.aeat303

https://codereview.tryton.org/45241002/diff/120001/reporting.py#newcode181
reporting.py:181: amounts['65'] = 100.0
What are those values?

https://codereview.tryton.org/45241002/diff/120001/reporting.py#newcode277
reporting.py:277: class PrintAEATReport(Wizard):
Is Report suffix needed?

https://codereview.tryton.org/45241002/diff/120001/reporting.py#newcode295
reporting.py:295: "fiscalyear to generate 303 report."),
I do not think it is really needed to name the report. It could be a generic
error message to be reused.

https://codereview.tryton.org/45241002/diff/120001/reporting.py#newcode317
reporting.py:317: __name__ = 'account.move'
Should be define in account.py

https://codereview.tryton.org/45241002/diff/120001/reporting.py#newcode324
reporting.py:324: if isinstance(self.origin, Move):
What is the use case?

https://codereview.tryton.org/45241002/diff/120001/reporting.xml
File reporting.xml (right):

https://codereview.tryton.org/45241002/diff/120001/reporting.xml#newcode9
reporting.xml:9: <field name="model">account.tax.code</field>
I do not think they requires a model.

https://codereview.tryton.org/45241002/diff/120001/reporting.xml#newcode38
reporting.xml:38: </record>
Require access rights

https://codereview.tryton.org/45241002/diff/120001/tests/scenario_reporting.rst
File tests/scenario_reporting.rst (right):

https://codereview.tryton.org/45241002/diff/120001/tests/scenario_reporting.r...
tests/scenario_reporting.rst:145: >>> aeat.execute('choice')
Maybe you could compare against a generated file if you fix the date.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld 3870a69