Minor fixes

This commit is contained in:
Oscar Alvarez 2020-12-23 09:31:58 -05:00
parent d2b8f83327
commit ed4f1c97a1
3 changed files with 79 additions and 51 deletions

29
.gitignore vendored Normal file
View File

@ -0,0 +1,29 @@
# See https://help.github.com/ignore-files/ for more about ignoring files.
# dependencies
/build
/dist
*egg-info
/node_modules
# testing
/coverage
# production
/build
# misc
.DS_Store
npm-debug.log*
yarn-debug.log*
yarn-error.log*
package-lock*
/__pycache__
/app/__pycache__
/app/commons/__pycache__

View File

@ -52,6 +52,7 @@ TYPE_INVOICE = [
('92', 'Nota Débito Eléctronica'),
]
class TypeContract(ModelSQL, ModelView):
"Type Sale Contract"
__name__ = 'sale.contract.type'
@ -479,7 +480,6 @@ class ContractProductLine(ModelSQL, ModelView):
], 'Type', select=True, required=True
)
@fields.depends('product')
def on_change_with_unit_price(self):
if self.product:
@ -587,7 +587,6 @@ class CreateInvoicesFromContractStart(ModelView):
])
invoice_type = fields.Selection(TYPE_INVOICE, 'Type Invoice')
@staticmethod
def default_company():
return Transaction().context.get('company')
@ -616,7 +615,6 @@ class CreateInvoicesFromContract(Wizard):
def transition_accept(self):
pool = Pool()
Contract = pool.get('sale.contract')
Sale = pool.get('sale.sale')
Line = Pool().get('sale.contract.line')
lines = Line.search([
('contract.state', '=', 'confirmed'),
@ -684,6 +682,7 @@ class CreateInvoicesFromContract(Wizard):
contract_line._process_sale(self.start.invoice_type, self.start.period)
return 'end'
class SaleContractFromPartyStart(ModelView):
'Create Sale Contract From Parties Start'
__name__ = 'sale.create_contract_from_party.start'

View File

@ -1,5 +1,5 @@
[tryton]
version=5.0.0
version=5.0.1
depends:
party
company