From afa84101cf25b9439cae3688bb5a9ceee7ae9a48 Mon Sep 17 00:00:00 2001 From: "Bharat Devnani (OpenERP)" Date: Tue, 14 Aug 2012 14:16:40 +0530 Subject: [PATCH 1/3] [REM] removed done button from Order Lines to Invoice bzr revid: bde@tinyerp.com-20120814084640-6b25ehh0s29giwsn --- addons/sale/sale.py | 7 ------- addons/sale/sale_view.xml | 3 +-- addons/sale/wizard/sale_line_invoice.py | 2 +- 3 files changed, 2 insertions(+), 10 deletions(-) diff --git a/addons/sale/sale.py b/addons/sale/sale.py index 722b22ba602..68b17149917 100644 --- a/addons/sale/sale.py +++ b/addons/sale/sale.py @@ -1260,13 +1260,6 @@ class sale_order_line(osv.osv): def button_confirm(self, cr, uid, ids, context=None): return self.write(cr, uid, ids, {'state': 'confirmed'}) - def button_done(self, cr, uid, ids, context=None): - wf_service = netsvc.LocalService("workflow") - res = self.write(cr, uid, ids, {'state': 'done'}) - for line in self.browse(cr, uid, ids, context=context): - wf_service.trg_write(uid, 'sale.order', line.order_id.id, cr) - return res - def uos_change(self, cr, uid, ids, product_uos, product_uos_qty=0, product_id=None): product_obj = self.pool.get('product.product') if not product_id: diff --git a/addons/sale/sale_view.xml b/addons/sale/sale_view.xml index 2257240dd10..cf49c154827 100644 --- a/addons/sale/sale_view.xml +++ b/addons/sale/sale_view.xml @@ -508,8 +508,7 @@
diff --git a/addons/sale/wizard/sale_line_invoice.py b/addons/sale/wizard/sale_line_invoice.py index 613b07039d5..e5b81fb5bc4 100644 --- a/addons/sale/wizard/sale_line_invoice.py +++ b/addons/sale/wizard/sale_line_invoice.py @@ -89,7 +89,7 @@ class sale_order_line_make_invoice(osv.osv_memory): for lid in line_id: invoices[line.order_id.id].append((line, lid)) sales_order_line_obj.write(cr, uid, [line.id], - {'invoiced': True}) + {'invoiced': True, 'state': 'done'}) for result in invoices.values(): order = result[0][0].order_id il = map(lambda x: x[1], result) From 7fe9ca1ed6d8017b4fb0cdb6b50fe15b0ae5aaef Mon Sep 17 00:00:00 2001 From: "Bharat Devnani(OpenERP)" <> Date: Thu, 23 Aug 2012 14:21:30 +0530 Subject: [PATCH 2/3] [IMP] Added label for sale order line selection on create invoice wizard bzr revid: pso@tinyerp.com-20120823085130-eczt22j1oozyni7v --- addons/sale/wizard/sale_make_invoice_advance.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/sale/wizard/sale_make_invoice_advance.xml b/addons/sale/wizard/sale_make_invoice_advance.xml index 5bb7d231e94..eceaadc89d0 100644 --- a/addons/sale/wizard/sale_make_invoice_advance.xml +++ b/addons/sale/wizard/sale_make_invoice_advance.xml @@ -23,6 +23,7 @@