1.修复销售岗位创建快速订单没有生成销售订单问题2.工件配送Tree视图默认上产线
This commit is contained in:
@@ -141,6 +141,19 @@ class ResaleOrderLine(models.Model):
|
||||
model_glb_file = fields.Binary('模型的glb文件')
|
||||
check_status = fields.Selection(related='order_id.check_status')
|
||||
|
||||
@api.onchange('product_id')
|
||||
def _compute_model_glb_file(self):
|
||||
for line in self:
|
||||
if line.product_template_id:
|
||||
if not line.model_glb_file:
|
||||
line.update({
|
||||
'model_glb_file': line.product_id.product_tmpl_id.model_file,
|
||||
})
|
||||
if not line.price_unit:
|
||||
line.update({
|
||||
'price_unit': line.product_id.product_tmpl_id.list_price,
|
||||
})
|
||||
|
||||
|
||||
class ProductTemplate(models.Model):
|
||||
_inherit = 'product.template'
|
||||
|
||||
Reference in New Issue
Block a user