forked from OCA/sale-workflow
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add POT file Add default value duration (in days) for validity per company (ignored if you leave the value to 0, which is the default).
- Loading branch information
Showing
7 changed files
with
191 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
# Translation of OpenERP Server. | ||
# This file contains the translation of the following modules: | ||
# * sale_validity | ||
# | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: OpenERP Server 7.0\n" | ||
"Report-Msgid-Bugs-To: \n" | ||
"POT-Creation-Date: 2014-01-15 11:51+0000\n" | ||
"PO-Revision-Date: 2014-01-15 11:51+0000\n" | ||
"Last-Translator: <>\n" | ||
"Language-Team: \n" | ||
"MIME-Version: 1.0\n" | ||
"Content-Type: text/plain; charset=UTF-8\n" | ||
"Content-Transfer-Encoding: \n" | ||
"Plural-Forms: \n" | ||
|
||
#. module: sale_validity | ||
#: view:sale.order:0 | ||
msgid "date_order_change(date_order, date_validity, company_id, context)" | ||
msgstr "" | ||
|
||
#. module: sale_validity | ||
#: help:sale.order,date_validity:0 | ||
msgid "Define date until when quotation is valid" | ||
msgstr "" | ||
|
||
#. module: sale_validity | ||
#: field:sale.order,date_validity:0 | ||
msgid "Valid Until" | ||
msgstr "" | ||
|
||
#. module: sale_validity | ||
#: model:ir.model,name:sale_validity.model_res_company | ||
msgid "Companies" | ||
msgstr "" | ||
|
||
#. module: sale_validity | ||
#: field:res.company,default_sale_order_validity_days:0 | ||
msgid "Default Validity of Sale Orders (in days)" | ||
msgstr "" | ||
|
||
#. module: sale_validity | ||
#: help:res.company,default_sale_order_validity_days:0 | ||
msgid "By default, the validity date of sale orders will be the date of the sale order plus the number of days defined in this field. If the value of this field is 0, the sale orders will not have a validity date by default." | ||
msgstr "" | ||
|
||
#. module: sale_validity | ||
#: model:ir.model,name:sale_validity.model_sale_order | ||
msgid "Sales Order" | ||
msgstr "" | ||
|
||
#. module: sale_validity | ||
#: sql_constraint:res.company:0 | ||
msgid "The value of the field 'Default Validity Duration of Sale Orders' must be positive or 0." | ||
msgstr "" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
# -*- coding: utf-8 -*- | ||
############################################################################## | ||
# | ||
# Copyright (C) 2014 Akretion (http://www.akretion.com) | ||
# @author Alexis de Lattre <[email protected]> | ||
# | ||
# This program is free software: you can redistribute it and/or modify | ||
# it under the terms of the GNU Affero General Public License as | ||
# published by the Free Software Foundation, either version 3 of the | ||
# License, or (at your option) any later version. | ||
# | ||
# This program is distributed in the hope that it will be useful, | ||
# but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
# GNU Affero General Public License for more details. | ||
# | ||
# You should have received a copy of the GNU Affero General Public License | ||
# along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
# | ||
############################################################################## | ||
|
||
from openerp.osv import fields, orm | ||
|
||
|
||
class res_company(orm.Model): | ||
_inherit = "res.company" | ||
|
||
_columns = { | ||
'default_sale_order_validity_days': fields.integer( | ||
"Default Validity of Sale Orders (in days)", | ||
help="By default, the validity date of sale orders will be " | ||
"the date of the sale order plus the number of days defined " | ||
"in this field. If the value of this field is 0, the sale orders " | ||
"will not have a validity date by default."), | ||
} | ||
|
||
_sql_constraints = [ | ||
('sale_order_validity_days_positive', | ||
'CHECK (default_sale_order_validity_days >= 0)', | ||
"The value of the field 'Default Validity Duration of Sale Orders' " | ||
"must be positive or 0."), | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
<?xml version="1.0"?> | ||
<openerp> | ||
<data> | ||
|
||
<!-- | ||
Copyright (C) 2014 Akretion (http://www.akretion.com/) | ||
@author: Alexis de Lattre <[email protected]> | ||
The licence is in the file __openerp__.py | ||
--> | ||
|
||
<record id="view_company_form" model="ir.ui.view"> | ||
<field name="name">default.sale.order.validity.company.form</field> | ||
<field name="model">res.company</field> | ||
<field name="inherit_id" ref="base.view_company_form"/> | ||
<field name="arch" type="xml"> | ||
<xpath expr="//page[@string='Configuration']/group" position="inside"> | ||
<group name="sale_validity"> | ||
<field name="default_sale_order_validity_days"/> | ||
</group> | ||
</xpath> | ||
</field> | ||
</record> | ||
|
||
</data> | ||
</openerp> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters