Skip to content

Commit df1485f

Browse files
committed
Merge pull request OCA#53 from damdam-s/8.0-sales_team_automatic_wkf
[IMP] add relation to sales team
2 parents 3c92adb + b26d193 commit df1485f

File tree

7 files changed

+52
-24
lines changed

7 files changed

+52
-24
lines changed

sale_automatic_workflow/README.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ A workflow can:
1111
* Shipping Policy (prepaid, manual, postpaid, picking)
1212
* Invoice On (ordered quantities, shipped quantities)
1313
* Set the invoice's date to the sale order's date
14+
* Set a sales team
1415

1516
- Apply automatic actions:
1617
* Validate the order (only if paid, always, never)

sale_automatic_workflow/__openerp__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
'license': 'AGPL-3',
2828
'author': "Akretion,Camptocamp,Odoo Community Association (OCA)",
2929
'website': 'http://www.akretion.com/',
30-
'depends': ['sale_stock',
30+
'depends': ['sale_stock', 'sales_team',
3131
],
3232
'data': ['sale_view.xml',
3333
'sale_workflow.xml',

sale_automatic_workflow/i18n/fr.po

Lines changed: 26 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,15 @@
1-
# Translation of OpenERP Server.
1+
# Translation of Odoo Server.
22
# This file contains the translation of the following modules:
3-
# * sale_automatic_workflow
3+
# * sale_automatic_workflow
44
#
55
msgid ""
66
msgstr ""
7-
"Project-Id-Version: OpenERP Server 7.0\n"
7+
"Project-Id-Version: Odoo Server 8.0\n"
88
"Report-Msgid-Bugs-To: \n"
9-
"POT-Creation-Date: 2014-11-24 14:16+0000\n"
10-
"PO-Revision-Date: 2013-05-02 07:15+0000\n"
9+
"POT-Creation-Date: 2015-08-31 09:38+0000\n"
10+
"PO-Revision-Date: 2015-08-31 09:38+0000\n"
1111
"Last-Translator: <>\n"
1212
"Language-Team: \n"
13-
"Language: \n"
1413
"MIME-Version: 1.0\n"
1514
"Content-Type: text/plain; charset=UTF-8\n"
1615
"Content-Transfer-Encoding: \n"
@@ -35,6 +34,11 @@ msgstr "Flux automatique"
3534
msgid "Automation Information"
3635
msgstr "Informations d'automatisation"
3736

37+
#. module: sale_automatic_workflow
38+
#: model:sale.workflow.process,warning:sale_automatic_workflow.automatic_validation
39+
msgid "Be careful, if you save the order with this setting, it could be auto-confirmed, even if you are editing it."
40+
msgstr ""
41+
3842
#. module: sale_automatic_workflow
3943
#: selection:sale.workflow.process,order_policy:0
4044
msgid "Before Delivery"
@@ -78,8 +82,14 @@ msgid "Force Invoice Date"
7882
msgstr "Forcer la date de facturation"
7983

8084
#. module: sale_automatic_workflow
81-
#: field:automatic.workflow.job,id:0 field:sale.workflow.process,id:0
85+
#: field:automatic.workflow.job,id:0
86+
#: field:sale.workflow.process,id:0
8287
msgid "ID"
88+
msgstr "ID"
89+
90+
#. module: sale_automatic_workflow
91+
#: help:sale.workflow.process,warning:0
92+
msgid "If set, display the message when a user selects the process on a sale order"
8393
msgstr ""
8494

8595
#. module: sale_automatic_workflow
@@ -152,7 +162,7 @@ msgstr "Autres informations"
152162
#. module: sale_automatic_workflow
153163
#: model:ir.model,name:sale_automatic_workflow.model_stock_picking
154164
msgid "Picking List"
155-
msgstr "Liste de colisage"
165+
msgstr "Opération de manutention"
156166

157167
#. module: sale_automatic_workflow
158168
#: field:account.invoice,sale_ids:0
@@ -171,6 +181,11 @@ msgstr "Flux automatique de vente"
171181
msgid "Sales Order"
172182
msgstr "Bon de commande"
173183

184+
#. module: sale_automatic_workflow
185+
#: field:sale.workflow.process,section_id:0
186+
msgid "Sales Team"
187+
msgstr "Équipe commerciale"
188+
174189
#. module: sale_automatic_workflow
175190
#: selection:sale.workflow.process,invoice_quantity:0
176191
msgid "Shipped Quantities"
@@ -204,21 +219,16 @@ msgstr "Message d'avertissement"
204219
#. module: sale_automatic_workflow
205220
#: help:sale.workflow.process,invoice_date_is_order_date:0
206221
msgid "When checked, the invoice date will be the same than the order's date"
207-
msgstr ""
208-
"Si activé, la date de facturation sera identique à la date de la commande."
222+
msgstr "Si activé, la date de facturation sera identique à la date de la commande."
209223

210224
#. module: sale_automatic_workflow
211225
#: view:sale.workflow.process:sale_automatic_workflow.sale_workflow_process_view_form
212226
msgid "Workflow Options"
213227
msgstr "Options du flux automatique"
214228

215229
#. module: sale_automatic_workflow
216-
#: code:addons/sale_automatic_workflow/sale.py:62
230+
#: code:addons/sale_automatic_workflow/sale.py:64
231+
#, python-format
217232
msgid "Workflow Warning"
218233
msgstr "Message d'avertissement"
219234

220-
#. module: sale_automatic_workflow
221-
#: help:sale.workflow.process,warning:0
222-
msgid ""
223-
"if set, display the message when a user selects the process on a sale order"
224-
msgstr "Ce message sera affiché aux utilisateurs quand ils sélectionnent ce flux sur une commande."

sale_automatic_workflow/i18n/sale_automatic_workflow.pot

Lines changed: 18 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ msgid ""
66
msgstr ""
77
"Project-Id-Version: Odoo Server 8.0\n"
88
"Report-Msgid-Bugs-To: \n"
9-
"POT-Creation-Date: 2014-11-24 14:16+0000\n"
10-
"PO-Revision-Date: 2014-11-24 14:16+0000\n"
9+
"POT-Creation-Date: 2015-08-31 09:38+0000\n"
10+
"PO-Revision-Date: 2015-08-31 09:38+0000\n"
1111
"Last-Translator: <>\n"
1212
"Language-Team: \n"
1313
"MIME-Version: 1.0\n"
@@ -34,6 +34,11 @@ msgstr ""
3434
msgid "Automation Information"
3535
msgstr ""
3636

37+
#. module: sale_automatic_workflow
38+
#: model:sale.workflow.process,warning:sale_automatic_workflow.automatic_validation
39+
msgid "Be careful, if you save the order with this setting, it could be auto-confirmed, even if you are editing it."
40+
msgstr ""
41+
3742
#. module: sale_automatic_workflow
3843
#: selection:sale.workflow.process,order_policy:0
3944
msgid "Before Delivery"
@@ -82,6 +87,11 @@ msgstr ""
8287
msgid "ID"
8388
msgstr ""
8489

90+
#. module: sale_automatic_workflow
91+
#: help:sale.workflow.process,warning:0
92+
msgid "If set, display the message when a user selects the process on a sale order"
93+
msgstr ""
94+
8595
#. module: sale_automatic_workflow
8696
#: model:ir.model,name:sale_automatic_workflow.model_account_invoice
8797
msgid "Invoice"
@@ -171,6 +181,11 @@ msgstr ""
171181
msgid "Sales Order"
172182
msgstr ""
173183

184+
#. module: sale_automatic_workflow
185+
#: field:sale.workflow.process,section_id:0
186+
msgid "Sales Team"
187+
msgstr ""
188+
174189
#. module: sale_automatic_workflow
175190
#: selection:sale.workflow.process,invoice_quantity:0
176191
msgid "Shipped Quantities"
@@ -212,12 +227,8 @@ msgid "Workflow Options"
212227
msgstr ""
213228

214229
#. module: sale_automatic_workflow
215-
#: code:addons/sale_automatic_workflow/sale.py:62
230+
#: code:addons/sale_automatic_workflow/sale.py:64
216231
#, python-format
217232
msgid "Workflow Warning"
218233
msgstr ""
219234

220-
#. module: sale_automatic_workflow
221-
#: help:sale.workflow.process,warning:0
222-
msgid "if set, display the message when a user selects the process on a sale order"
223-
msgstr ""

sale_automatic_workflow/sale.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,8 @@ def onchange_workflow_process_id(self):
5858
self.order_policy = workflow.order_policy
5959
if workflow.invoice_quantity:
6060
self.invoice_quantity = workflow.invoice_quantity
61+
if workflow.section_id:
62+
self.section_id = workflow.section_id.id
6163
if workflow.warning:
6264
warning = {'title': _('Workflow Warning'),
6365
'message': workflow.warning}

sale_automatic_workflow/sale_workflow_process.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,3 +76,5 @@ class SaleWorkflowProcess(models.Model):
7676
warning = fields.Text('Warning Message', translate=True,
7777
help='If set, display the message when a '
7878
'user selects the process on a sale order')
79+
section_id = fields.Many2one(comodel_name='crm.case.section',
80+
string='Sales Team')

sale_automatic_workflow/sale_workflow_process_view.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
<field name="picking_policy"/>
2222
<field name="order_policy"/>
2323
<field name="invoice_quantity"/>
24+
<field name="section_id" groups="base.group_multi_salesteams"/>
2425
</group>
2526
<group string="Workflow Options">
2627
<field name="validate_order"/>
@@ -43,6 +44,7 @@
4344
<field name="picking_policy"/>
4445
<field name="order_policy"/>
4546
<field name="invoice_quantity"/>
47+
<field name="section_id" groups="base.group_multi_salesteams"/>
4648
<field name="validate_order"/>
4749
<field name="validate_picking"/>
4850
<field name="create_invoice_on" />

0 commit comments

Comments
 (0)