From 4ee77c60581e2928639cfb9ed82d31429b2e0f85 Mon Sep 17 00:00:00 2001 From: "Ravi Gadhia (OpenERP)" Date: Thu, 11 Oct 2012 17:35:34 +0530 Subject: [PATCH 01/18] [FIX]: get context value in one2many bzr revid: atp@tinyerp.com-20121011120534-bo57y7m667hshuz5 --- addons/web/static/src/js/view_form.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index afb5e258c0b..02dd5b1e0c7 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -3608,7 +3608,12 @@ instance.web.form.One2ManyDataSet = instance.web.BufferedDataSet.extend({ get_context: function() { this.context = this.o2m.build_context([this.o2m.name]); return this.context; - } + }, + default_get: function(fields, options) { + if(!options) options = {} + _.extend(options, {'context':this.get_context()}) + return this._super(fields, options).then(this.on_default_get); + }, }); instance.web.form.One2ManyListView = instance.web.ListView.extend({ From 25ac221a0f6622a13d01d9b1ad14f4827adb2603 Mon Sep 17 00:00:00 2001 From: "RGA(OpenERP)" <> Date: Fri, 12 Oct 2012 12:00:04 +0530 Subject: [PATCH 02/18] [IMP] improve code bzr revid: rgaopenerp-20121012063004-cdgbq4w4pa1io9u2 --- addons/web/static/src/js/view_form.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index 02dd5b1e0c7..d9254d2d724 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -3609,11 +3609,11 @@ instance.web.form.One2ManyDataSet = instance.web.BufferedDataSet.extend({ this.context = this.o2m.build_context([this.o2m.name]); return this.context; }, - default_get: function(fields, options) { - if(!options) options = {} - _.extend(options, {'context':this.get_context()}) - return this._super(fields, options).then(this.on_default_get); - }, + default_get: function(fields, options) { + options = options || {}; + _.extend(options, {'context':this.get_context()}); + return this._super(fields, options).then(this.on_default_get); + }, }); instance.web.form.One2ManyListView = instance.web.ListView.extend({ From a414040f8058ccc0c61312decfff12a19fc7ce56 Mon Sep 17 00:00:00 2001 From: Fabien Pinckaers Date: Fri, 26 Oct 2012 16:37:41 +0200 Subject: [PATCH 03/18] [FIX] account visible when required bzr revid: fp@tinyerp.com-20121026143741-8e46e34v2ngej39w --- addons/account_voucher/voucher_sales_purchase_view.xml | 4 ++-- addons/hr_timesheet_sheet/hr_timesheet_sheet_view.xml | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/addons/account_voucher/voucher_sales_purchase_view.xml b/addons/account_voucher/voucher_sales_purchase_view.xml index 0441424cc33..bda9b9c2532 100644 --- a/addons/account_voucher/voucher_sales_purchase_view.xml +++ b/addons/account_voucher/voucher_sales_purchase_view.xml @@ -89,7 +89,7 @@ - + @@ -243,7 +243,7 @@ - + diff --git a/addons/hr_timesheet_sheet/hr_timesheet_sheet_view.xml b/addons/hr_timesheet_sheet/hr_timesheet_sheet_view.xml index a7e7bb6d097..c41aae4c21f 100644 --- a/addons/hr_timesheet_sheet/hr_timesheet_sheet_view.xml +++ b/addons/hr_timesheet_sheet/hr_timesheet_sheet_view.xml @@ -108,7 +108,7 @@ - + @@ -153,9 +153,9 @@ - - - + + + From 0e3f06bf4e51d304e7b40cd92d353ac9a9d03ba3 Mon Sep 17 00:00:00 2001 From: Fabien Pinckaers Date: Fri, 26 Oct 2012 16:52:22 +0200 Subject: [PATCH 04/18] fix bzr revid: fp@tinyerp.com-20121026145222-q3k000saytdg9u2s --- addons/web/static/src/css/base.css | 3 --- addons/web/static/src/css/base.sass | 2 -- 2 files changed, 5 deletions(-) diff --git a/addons/web/static/src/css/base.css b/addons/web/static/src/css/base.css index c18c4d89581..c3aac6089f0 100644 --- a/addons/web/static/src/css/base.css +++ b/addons/web/static/src/css/base.css @@ -1326,9 +1326,6 @@ .openerp .oe_view_manager .oe_view_manager_body { height: inherit; } -.openerp .oe_view_manager .oe_view_manager_body .oe_view_manager_view_list { - min-height: 132px; -} .openerp .oe_view_manager .oe_view_manager_view_kanban { height: inherit; } diff --git a/addons/web/static/src/css/base.sass b/addons/web/static/src/css/base.sass index 8b24e6112ae..cf1cd38aad2 100644 --- a/addons/web/static/src/css/base.sass +++ b/addons/web/static/src/css/base.sass @@ -1070,8 +1070,6 @@ $sheet-max-width: 860px .oe_view_manager .oe_view_manager_body height: inherit - .oe_view_manager_view_list - min-height: 132px .oe_view_manager_view_kanban height: inherit From 00caf72c6c1d679935f4f1359eca83762f40adc4 Mon Sep 17 00:00:00 2001 From: Fabien Pinckaers Date: Fri, 26 Oct 2012 17:28:50 +0200 Subject: [PATCH 05/18] [IMP] CSS bzr revid: fp@tinyerp.com-20121026152850-bevh0selibxvsixm --- addons/web/static/src/css/base.css | 3 +++ addons/web/static/src/css/base.sass | 3 +++ 2 files changed, 6 insertions(+) diff --git a/addons/web/static/src/css/base.css b/addons/web/static/src/css/base.css index c3aac6089f0..cbbd8e37f6c 100644 --- a/addons/web/static/src/css/base.css +++ b/addons/web/static/src/css/base.css @@ -2519,6 +2519,9 @@ .openerp .oe_form_field_one2many > .oe_view_manager .oe_list_pager_single_page, .openerp .oe_form_field_many2many > .oe_view_manager .oe_list_pager_single_page { display: none !important; } +.openerp .oe_form_field_one2many > .oe_view_manager .oe_view_manager_view_list, .openerp .oe_form_field_many2many > .oe_view_manager .oe_view_manager_view_list { + min-height: 132px; +} .openerp .oe_form_field_one2many .oe_form_field_one2many_list_row_add, .openerp .oe_form_field_many2many .oe_form_field_one2many_list_row_add { font-weight: bold; } diff --git a/addons/web/static/src/css/base.sass b/addons/web/static/src/css/base.sass index cf1cd38aad2..2ef9a8a451d 100644 --- a/addons/web/static/src/css/base.sass +++ b/addons/web/static/src/css/base.sass @@ -1983,6 +1983,9 @@ $sheet-max-width: 860px > .oe_view_manager .oe_list_pager_single_page display: none !important + .oe_view_manager_view_list + min-height: 132px + .oe_form_field_one2many_list_row_add font-weight: bold .oe_list_content From e6159de18f912832acffb3b5cf50537766e7df1c Mon Sep 17 00:00:00 2001 From: Fabien Pinckaers Date: Fri, 26 Oct 2012 17:34:36 +0200 Subject: [PATCH 06/18] [IMP] useability bzr revid: fp@tinyerp.com-20121026153436-v3y2i49iarpoknok --- addons/sale/sale.py | 2 +- addons/sale/sale_view.xml | 5 +---- addons/sale_margin/sale_margin_view.xml | 9 +++------ 3 files changed, 5 insertions(+), 11 deletions(-) diff --git a/addons/sale/sale.py b/addons/sale/sale.py index 9c7f07edb25..7c77e239abb 100644 --- a/addons/sale/sale.py +++ b/addons/sale/sale.py @@ -202,7 +202,7 @@ class sale_order(osv.osv): - With 'Before Delivery', a draft invoice is created, and it must be paid before delivery."""), 'pricelist_id': fields.many2one('product.pricelist', 'Pricelist', required=True, readonly=True, states={'draft': [('readonly', False)], 'sent': [('readonly', False)]}, help="Pricelist for current sales order."), 'currency_id': fields.related('pricelist_id', 'currency_id', type="many2one", relation="res.currency", readonly=True, required=True), - 'project_id': fields.many2one('account.analytic.account', 'Contract/Analytic Account', readonly=True, states={'draft': [('readonly', False)], 'sent': [('readonly', False)]}, help="The analytic account related to a sales order."), + 'project_id': fields.many2one('account.analytic.account', 'Contract / Analytic', readonly=True, states={'draft': [('readonly', False)], 'sent': [('readonly', False)]}, help="The analytic account related to a sales order."), 'order_line': fields.one2many('sale.order.line', 'order_id', 'Order Lines', readonly=True, states={'draft': [('readonly', False)], 'sent': [('readonly', False)]}), 'invoice_ids': fields.many2many('account.invoice', 'sale_order_invoice_rel', 'order_id', 'invoice_id', 'Invoices', readonly=True, help="This is the list of invoices that have been generated for this sales order. The same sales order may have been invoiced in several times (by line for example)."), diff --git a/addons/sale/sale_view.xml b/addons/sale/sale_view.xml index a5d7b9d3af2..bdc687f6e87 100644 --- a/addons/sale/sale_view.xml +++ b/addons/sale/sale_view.xml @@ -286,11 +286,8 @@ - -
-