From bf92a5b2fa852ed8d9c94e002e5999210ca1bc95 Mon Sep 17 00:00:00 2001 From: Mahendra barad Date: Mon, 28 Jul 2014 17:43:11 +0530 Subject: [PATCH] [IMP] website_quote: onboarding Views and labels improvements --- addons/sale/sale_view.xml | 14 ++--- .../data/website_quotation_demo.xml | 4 +- addons/website_quote/models/order.py | 12 ++-- .../static/src/css/website_quotation.css | 7 +++ .../views/website_quotation_backend.xml | 55 ++++++++++++++++--- 5 files changed, 70 insertions(+), 22 deletions(-) diff --git a/addons/sale/sale_view.xml b/addons/sale/sale_view.xml index 9adb02b691f..1849d0f836c 100644 --- a/addons/sale/sale_view.xml +++ b/addons/sale/sale_view.xml @@ -334,13 +334,12 @@

Click to create a quotation, the first step of a new sale.

- Odoo will help you handle efficiently the complete sale flow: + Odoo will help you handling efficiently the complete sale flow: from the quotation to the sales order, the delivery, the invoicing and the payment collection.

- The social feature helps you organize discussions on each sales - order, and allow your customers to keep track of the evolution - of the sales order. + The social feature helps you organizing discussions on each sales + order, and allows your customers to keep track of the sales orders' evolution.

@@ -631,13 +630,12 @@

Click to create a quotation, the first step of a new sale.

- Odoo will help you handle efficiently the complete sale flow: + Odoo will help you handling efficiently the complete sale flow: from the quotation to the sales order, the delivery, the invoicing and the payment collection.

- The social feature helps you organize discussions on each sales - order, and allow your customers to keep track of the evolution - of the sales order. + The social feature helps you organizing discussions on each sales + order, and allows your customers to keep track of the sales orders' evolution.

diff --git a/addons/website_quote/data/website_quotation_demo.xml b/addons/website_quote/data/website_quotation_demo.xml index 4038fcd926e..ed7eeb97555 100644 --- a/addons/website_quote/data/website_quotation_demo.xml +++ b/addons/website_quote/data/website_quotation_demo.xml @@ -235,7 +235,7 @@ through our 2000+ automated unit tests.

Our automated testing server software is called Runbot, - and you can try it out here: http://runbot.openerp.com. + and you can try it out here: http://runbot.odoo.com. A dedicated runbot server is available for every partner.

@@ -275,7 +275,7 @@

Structure of the Training

- +

There are three components to the training

diff --git a/addons/website_quote/models/order.py b/addons/website_quote/models/order.py index fe9d3f527d2..0df04707595 100644 --- a/addons/website_quote/models/order.py +++ b/addons/website_quote/models/order.py @@ -32,10 +32,10 @@ class sale_quote_template(osv.osv): _columns = { 'name': fields.char('Quotation Template', required=True), 'website_description': fields.html('Description', translate=True), - 'quote_line': fields.one2many('sale.quote.line', 'quote_id', 'Quote Template Lines', copy=True), + 'quote_line': fields.one2many('sale.quote.line', 'quote_id', 'Quotation Template Lines', copy=True), 'note': fields.text('Terms and conditions'), 'options': fields.one2many('sale.quote.option', 'template_id', 'Optional Products Lines', copy=True), - 'number_of_days': fields.integer('Quote Duration', help='Number of days for the validaty date computation of the quotation'), + 'number_of_days': fields.integer('Quotation Duration', help='Number of days for the validity date computation of the quotation'), } def open_template(self, cr, uid, quote_id, context=None): return { @@ -140,11 +140,12 @@ class sale_order(osv.osv): _columns = { 'access_token': fields.char('Security Token', required=True, copy=False), - 'template_id': fields.many2one('sale.quote.template', 'Quote Template', readonly=True, states={'draft': [('readonly', False)], 'sent': [('readonly', False)]}), + 'template_id': fields.many2one('sale.quote.template', 'Quotation Template', readonly=True, states={'draft': [('readonly', False)], 'sent': [('readonly', False)]}), 'website_description': fields.html('Description'), 'options' : fields.one2many('sale.order.option', 'order_id', 'Optional Products Lines', readonly=True, states={'draft': [('readonly', False)], 'sent': [('readonly', False)]}), 'amount_undiscounted': fields.function(_get_total, string='Amount Before Discount', type="float", - digits_compute=dp.get_precision('Account')) + digits_compute=dp.get_precision('Account')), + 'quote_viewed': fields.boolean('Quotation Viewed') } def _get_template_id(self, cr, uid, context=None): @@ -161,6 +162,7 @@ class sale_order(osv.osv): def open_quotation(self, cr, uid, quote_id, context=None): quote = self.browse(cr, uid, quote_id[0], context=context) + self.write(cr, uid, quote_id[0], {'quote_viewed': True}, context=context) return { 'type': 'ir.actions.act_url', 'target': 'self', @@ -238,7 +240,7 @@ class sale_order(osv.osv): class sale_quote_option(osv.osv): _name = "sale.quote.option" - _description = "Quote Option" + _description = "Quotation Option" _columns = { 'template_id': fields.many2one('sale.quote.template', 'Quotation Template Reference', ondelete='cascade', select=True, required=True), 'name': fields.text('Description', required=True, translate=True), diff --git a/addons/website_quote/static/src/css/website_quotation.css b/addons/website_quote/static/src/css/website_quotation.css index 28bcf38efc1..6fa917b7621 100644 --- a/addons/website_quote/static/src/css/website_quotation.css +++ b/addons/website_quote/static/src/css/website_quotation.css @@ -5,6 +5,13 @@ border-radius: 5px; } +/* mobile preview: the left menu overlaps the quote */ +@media (max-width: 768px) { + .o_website_quote .bs-sidebar { + position: relative; + } +} + .o_website_quote .bs-sidenav { padding-top: 10px; padding-bottom: 10px; diff --git a/addons/website_quote/views/website_quotation_backend.xml b/addons/website_quote/views/website_quotation_backend.xml index 8341dea667b..ac206c99891 100644 --- a/addons/website_quote/views/website_quotation_backend.xml +++ b/addons/website_quote/views/website_quotation_backend.xml @@ -7,14 +7,29 @@ -