智能工厂去掉工厂token等信息
This commit is contained in:
@@ -10,12 +10,11 @@
|
||||
""",
|
||||
'category': 'sf',
|
||||
'website': 'https://www.sf.cs.jikimo.com',
|
||||
'depends': ['sale', 'product'],
|
||||
'depends': ['sale', 'sf_base'],
|
||||
'data': [
|
||||
'data/product_data.xml',
|
||||
'views/product_template_view.xml',
|
||||
'views/sale_order_view.xml',
|
||||
|
||||
'views/sale_order_view.xml'
|
||||
],
|
||||
'demo': [
|
||||
],
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<odoo>
|
||||
<data>
|
||||
<record id="product_template_sf" model="product.product">
|
||||
<field name="name">CNC加工產品模板</field>
|
||||
<field name="name">CNC加工产品模板</field>
|
||||
<field name="categ_id" ref="product.product_category_5"/>
|
||||
<field name="invoice_policy">delivery</field>
|
||||
<field name="detailed_type">product</field>
|
||||
|
||||
@@ -23,7 +23,7 @@ class ResProductTemplate(models.Model):
|
||||
'model_height': item['model_height'],
|
||||
'model_volume': item['model_volume'],
|
||||
'list_price': item['price'],
|
||||
'materials_id': self.env['mrs.production.materials'].sudo().search(
|
||||
'materials_id': self.env['mrs.production.materials'].search(
|
||||
[('materials_no', '=', item['texture_code'])]).id,
|
||||
'default_code': '%s-%s' % (order_number, i),
|
||||
'barcode': item['barcode'],
|
||||
|
||||
@@ -8,8 +8,6 @@ class ReSaleOrder(models.Model):
|
||||
|
||||
deadline_of_delivery = fields.Date('交货截止日期')
|
||||
|
||||
# product_line_ids = fields.One2many('product.template', 'sale_order_id')
|
||||
|
||||
# 业务平台分配工厂后在智能工厂先创建销售订单
|
||||
def sale_order_create(self, deadline_of_delivery, company_id):
|
||||
now_time = datetime.datetime.now()
|
||||
@@ -29,8 +27,7 @@ class ReSaleOrder(models.Model):
|
||||
vals = {
|
||||
'order_id': self.id,
|
||||
'product_id': product.id,
|
||||
'name': '%s/%s/%s/%s/%s' % (
|
||||
item['model_long'], item['model_width'], item['model_height'], item['model_volume'], product.materials_id.name),
|
||||
'name': '%s/%s/%s/%s/%s' % (item['model_long'], item['model_width'], item['model_height'], item['model_volume'], product.materials_id.name),
|
||||
'price_unit': item['price'],
|
||||
'product_uom_qty': item['number']
|
||||
}
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
</group>
|
||||
<group>
|
||||
<field name="model_precision"/>
|
||||
<field name="materials_id"/>
|
||||
<field name="materials_id" />
|
||||
</group>
|
||||
</group>
|
||||
</page>
|
||||
|
||||
Reference in New Issue
Block a user