1.夹具物料,联装类型,功能夹具类型的Tree视图去掉删除方法和删除操作;同步的方法里新增active字段
2.品牌模型新增厂家型号字段 3.修复3D模型全屏展示及不显示模型Bug
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
from odoo import models, fields, api
|
||||
from odoo.exceptions import UserError
|
||||
|
||||
|
||||
class FixtureMaterial(models.Model):
|
||||
@@ -8,12 +7,9 @@ class FixtureMaterial(models.Model):
|
||||
|
||||
code = fields.Char(string='编码')
|
||||
name = fields.Char(string="名称", size=15)
|
||||
category = fields.Selection([('零点夹具', '零点夹具')], string="类别")
|
||||
remark = fields.Char(string="备注")
|
||||
|
||||
def unlink(self):
|
||||
for record in self:
|
||||
if record:
|
||||
raise UserError('不允许删除数据!')
|
||||
active = fields.Boolean(string="有效", default=True)
|
||||
|
||||
|
||||
class Multi_MountingType(models.Model):
|
||||
@@ -23,6 +19,7 @@ class Multi_MountingType(models.Model):
|
||||
code = fields.Char(string='编码')
|
||||
name = fields.Char(string="名称", size=15)
|
||||
remark = fields.Char(string="备注")
|
||||
active = fields.Boolean(string="有效", default=True)
|
||||
|
||||
|
||||
class FixtureModel(models.Model):
|
||||
@@ -35,6 +32,7 @@ class FixtureModel(models.Model):
|
||||
fixture_material_type = fields.Char(string="夹具物料类型", related='fixture_material_id.name')
|
||||
multi_mounting_type_id = fields.Many2one('sf.multi_mounting.type', string="联装类型")
|
||||
brand_id = fields.Many2one('sf.machine.brand', string="品牌")
|
||||
manufacturer_model_number = fields.Char(string="厂家型号")
|
||||
clamping_way = fields.Char(string="装夹方式")
|
||||
port_type = fields.Char(string="接口类型")
|
||||
model_file = fields.Binary(string="3D模型图")
|
||||
|
||||
Reference in New Issue
Block a user