Merge lp:~romaindeheele/account-invoice-report/add-account_draft_invoice_print into lp:~account-core-editors/account-invoice-report/7.0

Proposed by Romain Deheele - Camptocamp
Status: Merged
Approved by: Alexandre Fayolle - camptocamp
Approved revision: 36
Merged at revision: 36
Proposed branch: lp:~romaindeheele/account-invoice-report/add-account_draft_invoice_print
Merge into: lp:~account-core-editors/account-invoice-report/7.0
Diff against target: 82 lines (+67/-0)
3 files modified
account_draft_invoice_print/__init__.py (+20/-0)
account_draft_invoice_print/__openerp__.py (+32/-0)
account_draft_invoice_print/invoice_view.xml (+15/-0)
To merge this branch: bzr merge lp:~romaindeheele/account-invoice-report/add-account_draft_invoice_print
Reviewer Review Type Date Requested Status
Guewen Baconnier @ Camptocamp code review, no test Approve
Alexandre Fayolle - camptocamp code review, no test Approve
Review via email: mp+177105@code.launchpad.net

Description of the change

add account_draft_invoice_print addon : set visible button "invoice_print" to print draft invoices

To post a comment you must log in.
Revision history for this message
Alexandre Fayolle - camptocamp (alexandre-fayolle-c2c) wrote :

in __openerp__.py,

* remove empty entries 'demo_xml' and 'data'
* change the category to "Accounting & Finance"

review: Needs Fixing (code review, no test)
36. By Romain Deheele - Camptocamp

[IMP] remove empty entries and change category to "Accounting & Finance"

Revision history for this message
Alexandre Fayolle - camptocamp (alexandre-fayolle-c2c) wrote :

LGTM

review: Approve (code review, no test)
Revision history for this message
Guewen Baconnier @ Camptocamp (gbaconnier-c2c) wrote :

LGTM

review: Approve (code review, no test)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== added directory 'account_draft_invoice_print'
2=== added file 'account_draft_invoice_print/__init__.py'
3--- account_draft_invoice_print/__init__.py 1970-01-01 00:00:00 +0000
4+++ account_draft_invoice_print/__init__.py 2013-07-26 08:17:30 +0000
5@@ -0,0 +1,20 @@
6+# -*- coding: utf-8 -*-
7+##############################################################################
8+#
9+# Copyright (c) 2013 Camptocamp SA (http://www.camptocamp.com)
10+# @author Romain Deheele
11+#
12+# This program is free software: you can redistribute it and/or modify
13+# it under the terms of the GNU Affero General Public License as
14+# published by the Free Software Foundation, either version 3 of the
15+# License, or (at your option) any later version.
16+#
17+# This program is distributed in the hope that it will be useful,
18+# but WITHOUT ANY WARRANTY; without even the implied warranty of
19+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20+# GNU Affero General Public License for more details.
21+#
22+# You should have received a copy of the GNU Affero General Public License
23+# along with this program. If not, see <http://www.gnu.org/licenses/>.
24+#
25+##############################################################################
26
27=== added file 'account_draft_invoice_print/__openerp__.py'
28--- account_draft_invoice_print/__openerp__.py 1970-01-01 00:00:00 +0000
29+++ account_draft_invoice_print/__openerp__.py 2013-07-26 08:17:30 +0000
30@@ -0,0 +1,32 @@
31+# -*- coding: utf-8 -*-
32+##############################################################################
33+#
34+# Copyright (c) 2013 Camptocamp SA (http://www.camptocamp.com)
35+# @author Romain Deheele
36+#
37+# This program is free software: you can redistribute it and/or modify
38+# it under the terms of the GNU Affero General Public License as
39+# published by the Free Software Foundation, either version 3 of the
40+# License, or (at your option) any later version.
41+#
42+# This program is distributed in the hope that it will be useful,
43+# but WITHOUT ANY WARRANTY; without even the implied warranty of
44+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
45+# GNU Affero General Public License for more details.
46+#
47+# You should have received a copy of the GNU Affero General Public License
48+# along with this program. If not, see <http://www.gnu.org/licenses/>.
49+#
50+##############################################################################
51+
52+{'name': 'Account Draft Invoice Print',
53+ 'version': '1.0.0',
54+ 'category': 'Accounting & Finance',
55+ 'description': """Allows to print invoices in draft state""",
56+ 'author': 'Camptocamp',
57+ 'website': 'http://www.camptocamp.com',
58+ 'depends': ['account'],
59+ 'data': ['invoice_view.xml'],
60+ 'installable': True,
61+ 'active': False,
62+ }
63
64=== added file 'account_draft_invoice_print/invoice_view.xml'
65--- account_draft_invoice_print/invoice_view.xml 1970-01-01 00:00:00 +0000
66+++ account_draft_invoice_print/invoice_view.xml 2013-07-26 08:17:30 +0000
67@@ -0,0 +1,15 @@
68+<openerp>
69+ <data>
70+ <record id="invoice_form_print_cancel" model="ir.ui.view">
71+ <field name="name">account.invoice.form.print.cancel</field>
72+ <field name="model">account.invoice</field>
73+ <field name="inherit_id" ref="account.invoice_form" />
74+ <field name="arch" type="xml">
75+ <button name="invoice_print" position="attributes">
76+ <attribute name="attrs">{'invisible':['|',('sent','=',True), ('state', 'not in', ['open','draft'])]}</attribute>
77+ </button>
78+ </field>
79+ </record>
80+
81+ </data>
82+</openerp>

Subscribers

People subscribed via source and target branches