Remove OSV and WizardOSV
This commit is contained in:
1 parent
aeaa6008ef
commit
97d7c5850d
5 files changed
+28
-30
No files matched your search
+5
-6
@@ -1,16 +1,15 @@
|
||||
#This file is part of Tryton. The COPYRIGHT file at the top level
|
||||
#of this repository contains the full copyright notices and license terms.
|
||||
'Inventory'
|
||||
from trytond.model import ModelWorkflow
|
||||
from trytond.osv import fields, OSV
|
||||
from trytond.wizard import Wizard, WizardOSV
|
||||
from trytond.model import ModelWorkflow, ModelView, ModelSQL, fields
|
||||
from trytond.wizard import Wizard
|
||||
|
||||
STATES = {
|
||||
'readonly': "state != 'draft'",
|
||||
}
|
||||
|
||||
|
||||
class Inventory(ModelWorkflow, OSV):
|
||||
class Inventory(ModelWorkflow, ModelSQL, ModelView):
|
||||
'Stock Inventory'
|
||||
_name = 'stock.inventory'
|
||||
_description = __doc__
|
||||
@@ -215,7 +214,7 @@ class Inventory(ModelWorkflow, OSV):
|
||||
Inventory()
|
||||
|
||||
|
||||
class InventoryLine(OSV):
|
||||
class InventoryLine(ModelSQL, ModelView):
|
||||
'Stock Inventory Line'
|
||||
_name = 'stock.inventory.line'
|
||||
_description = __doc__
|
||||
@@ -308,7 +307,7 @@ class InventoryLine(OSV):
|
||||
InventoryLine()
|
||||
|
||||
|
||||
class CompleteInventoryInit(WizardOSV):
|
||||
class CompleteInventoryInit(ModelView):
|
||||
'Complete Inventory Init'
|
||||
_name = 'stock.inventory.complete.init'
|
||||
_description = __doc__
|
||||
|
||||
+5
-5
@@ -1,8 +1,8 @@
|
||||
#This file is part of Tryton. The COPYRIGHT file at the top level
|
||||
#of this repository contains the full copyright notices and license terms.
|
||||
"Wharehouse"
|
||||
from trytond.osv import fields, OSV
|
||||
from trytond.wizard import Wizard, WizardOSV
|
||||
from trytond.model import ModelView, ModelSQL, fields
|
||||
from trytond.wizard import Wizard
|
||||
import datetime
|
||||
|
||||
STATES = {
|
||||
@@ -10,7 +10,7 @@ STATES = {
|
||||
}
|
||||
|
||||
|
||||
class Location(OSV):
|
||||
class Location(ModelSQL, ModelView):
|
||||
"Stock Location"
|
||||
_name = 'stock.location'
|
||||
_description = __doc__
|
||||
@@ -231,7 +231,7 @@ class Location(OSV):
|
||||
Location()
|
||||
|
||||
|
||||
class Party(OSV):
|
||||
class Party(ModelSQL, ModelView):
|
||||
_name = 'party.party'
|
||||
supplier_location = fields.Property(type='many2one',
|
||||
relation='stock.location', string='Supplier Location',
|
||||
@@ -247,7 +247,7 @@ class Party(OSV):
|
||||
Party()
|
||||
|
||||
|
||||
class ChooseStockDateInit(WizardOSV):
|
||||
class ChooseStockDateInit(ModelView):
|
||||
_name = 'stock.location_stock_date.init'
|
||||
_description = "Compute stock quantities"
|
||||
forecast_date = fields.Date(
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#This file is part of Tryton. The COPYRIGHT file at the top level of
|
||||
#this repository contains the full copyright notices and license terms.
|
||||
"Move"
|
||||
from trytond.osv import fields, OSV
|
||||
from trytond.model import ModelView, ModelSQL, fields
|
||||
from decimal import Decimal
|
||||
import datetime
|
||||
|
||||
@@ -10,7 +10,7 @@ STATES = {
|
||||
}
|
||||
|
||||
|
||||
class Move(OSV):
|
||||
class Move(ModelSQL, ModelView):
|
||||
"Stock Move"
|
||||
_name = 'stock.move'
|
||||
_description = __doc__
|
||||
|
||||
+11
-12
@@ -1,10 +1,9 @@
|
||||
#This file is part of Tryton. The COPYRIGHT file at the top level of
|
||||
#this repository contains the full copyright notices and license terms.
|
||||
"Packing"
|
||||
from trytond.model import ModelWorkflow
|
||||
from trytond.osv import fields, OSV
|
||||
from trytond.model import ModelWorkflow, ModelView, ModelSQL, fields
|
||||
from trytond.report import CompanyReport
|
||||
from trytond.wizard import Wizard, WizardOSV
|
||||
from trytond.wizard import Wizard
|
||||
from trytond.backend import TableHandler
|
||||
import datetime
|
||||
|
||||
@@ -13,7 +12,7 @@ STATES = {
|
||||
}
|
||||
|
||||
|
||||
class PackingIn(ModelWorkflow, OSV):
|
||||
class PackingIn(ModelWorkflow, ModelSQL, ModelView):
|
||||
"Supplier Packing"
|
||||
_name = 'stock.packing.in'
|
||||
_description = __doc__
|
||||
@@ -292,7 +291,7 @@ class PackingIn(ModelWorkflow, OSV):
|
||||
PackingIn()
|
||||
|
||||
|
||||
class PackingInReturn(ModelWorkflow, OSV):
|
||||
class PackingInReturn(ModelWorkflow, ModelSQL, ModelView):
|
||||
"Supplier Return Packing"
|
||||
_name = 'stock.packing.in.return'
|
||||
_description = __doc__
|
||||
@@ -444,7 +443,7 @@ class PackingInReturn(ModelWorkflow, OSV):
|
||||
PackingInReturn()
|
||||
|
||||
|
||||
class PackingOut(ModelWorkflow, OSV):
|
||||
class PackingOut(ModelWorkflow, ModelSQL, ModelView):
|
||||
"Customer Packing"
|
||||
_name = 'stock.packing.out'
|
||||
_description = __doc__
|
||||
@@ -832,7 +831,7 @@ PackingOut()
|
||||
|
||||
|
||||
|
||||
class PackingOutReturn(ModelWorkflow, OSV):
|
||||
class PackingOutReturn(ModelWorkflow, ModelSQL, ModelView):
|
||||
"Customer Return Packing"
|
||||
_name = 'stock.packing.out.return'
|
||||
_description = __doc__
|
||||
@@ -1109,7 +1108,7 @@ class PackingOutReturn(ModelWorkflow, OSV):
|
||||
PackingOutReturn()
|
||||
|
||||
|
||||
class AssignPackingOutAskForce(WizardOSV):
|
||||
class AssignPackingOutAskForce(ModelView):
|
||||
'Assign Packing Out Ask Force'
|
||||
_name = 'stock.packing.out.assign.ask_force'
|
||||
_description = __doc__
|
||||
@@ -1179,7 +1178,7 @@ class AssignPackingOut(Wizard):
|
||||
AssignPackingOut()
|
||||
|
||||
|
||||
class PackingInternal(ModelWorkflow, OSV):
|
||||
class PackingInternal(ModelWorkflow, ModelSQL, ModelView):
|
||||
"Internal Packing"
|
||||
_name = 'stock.packing.internal'
|
||||
_description = __doc__
|
||||
@@ -1301,14 +1300,14 @@ class PackingInternal(ModelWorkflow, OSV):
|
||||
PackingInternal()
|
||||
|
||||
|
||||
class Address(OSV):
|
||||
class Address(ModelSQL, ModelView):
|
||||
_name = 'party.address'
|
||||
delivery = fields.Boolean('Delivery')
|
||||
|
||||
Address()
|
||||
|
||||
|
||||
class AssignPackingInternalAskForce(WizardOSV):
|
||||
class AssignPackingInternalAskForce(ModelView):
|
||||
'Assign Packing Internal Ask Force'
|
||||
_name = 'stock.packing.internal.assign.ask_force'
|
||||
_description = __doc__
|
||||
@@ -1377,7 +1376,7 @@ class AssignPackingInternal(Wizard):
|
||||
AssignPackingInternal()
|
||||
|
||||
|
||||
class AssignPackingInReturnAskForce(WizardOSV):
|
||||
class AssignPackingInReturnAskForce(ModelView):
|
||||
'Assign Supplier Return Packing Ask Force'
|
||||
_name = 'stock.packing.in.return.assign.ask_force'
|
||||
_description = __doc__
|
||||
|
||||
+5
-5
@@ -1,11 +1,11 @@
|
||||
#This file is part of Tryton. The COPYRIGHT file at the top level of
|
||||
#this repository contains the full copyright notices and license terms.
|
||||
from trytond.osv import fields, OSV
|
||||
from trytond.wizard import Wizard, WizardOSV
|
||||
from trytond.model import ModelView, ModelSQL, fields
|
||||
from trytond.wizard import Wizard
|
||||
import datetime
|
||||
|
||||
|
||||
class Template(OSV):
|
||||
class Template(ModelSQL, ModelView):
|
||||
_name = "product.template"
|
||||
|
||||
quantity = fields.Function('get_quantity', type='float', string='Quantity')
|
||||
@@ -25,7 +25,7 @@ class Template(OSV):
|
||||
|
||||
Template()
|
||||
|
||||
class Product(OSV):
|
||||
class Product(ModelSQL, ModelView):
|
||||
_name = "product.product"
|
||||
|
||||
quantity = fields.Function('get_quantity', type='float', string='Quantity',
|
||||
@@ -477,7 +477,7 @@ class Product(OSV):
|
||||
Product()
|
||||
|
||||
|
||||
class ChooseStockDateInit(WizardOSV):
|
||||
class ChooseStockDateInit(ModelView):
|
||||
_name = 'stock.product_stock_date.init'
|
||||
_description = "Compute stock quantities"
|
||||
forecast_date = fields.Date(
|
||||
|
||||
Reference in new issue
Block a user