|
|
|
@ -60,6 +60,12 @@ |
|
|
|
},{ |
|
|
|
label: '规格', |
|
|
|
key: 'spec' |
|
|
|
},{ |
|
|
|
label: '单位', |
|
|
|
key: 'unit' |
|
|
|
},{ |
|
|
|
label: '分类', |
|
|
|
key: 'category' |
|
|
|
},{ |
|
|
|
label: '品牌', |
|
|
|
key: 'brand' |
|
|
|
@ -154,7 +160,9 @@ |
|
|
|
purchase_limit: {edit: true, value: 1}, |
|
|
|
tax_price: {edit: true, value: ''}, |
|
|
|
non_tax_price: {edit: true, value: ''}, |
|
|
|
operation: {button: true, key: 'delete', value: '删除'} |
|
|
|
operation: {button: true, key: 'delete', value: '删除'}, |
|
|
|
unit: item?.material?.unit?.unit_name || '', |
|
|
|
category: item?.material?.category?.m_cate_name || '' |
|
|
|
} |
|
|
|
}) |
|
|
|
this.contents = contents; |
|
|
|
@ -182,7 +190,9 @@ |
|
|
|
tax_price: {edit: true, value: item?.quotation?.tax_price || ''}, |
|
|
|
non_tax_price: {edit: true, value: item?.quotation?.non_tax_price || ''}, |
|
|
|
quotation_id: item?.quotation?.id || 0, |
|
|
|
operation: {button: true, key: 'delete', value: '删除'} |
|
|
|
operation: {button: true, key: 'delete', value: '删除'}, |
|
|
|
unit: item?.material?.unit?.unit_name || '', |
|
|
|
category: item?.material?.category?.m_cate_name || '' |
|
|
|
} |
|
|
|
if(item?.material?.state && item?.material?.state != '启用'){ |
|
|
|
obj.disabled = true; |
|
|
|
@ -241,8 +251,19 @@ |
|
|
|
// table操作按钮被点击 |
|
|
|
onButtonClick(event){ |
|
|
|
if(event.content.key == 'delete'){ |
|
|
|
let contentIndex = event.lineData.contentIndex; |
|
|
|
this.contents.splice(contentIndex, 1); |
|
|
|
let contentIndex = event.contentIndex; |
|
|
|
let name = event.lineData.name; |
|
|
|
let spec = event.lineData.spec; |
|
|
|
uni.showModal({ |
|
|
|
title: '温馨提示', |
|
|
|
content: `确定删除 ${name}-${spec} 吗?`, |
|
|
|
confirmColor: '#1833F2', |
|
|
|
success: result => { |
|
|
|
if(result.confirm){ |
|
|
|
this.contents.splice(contentIndex, 1); |
|
|
|
} |
|
|
|
} |
|
|
|
}) |
|
|
|
} |
|
|
|
}, |
|
|
|
// 切换显示关联食堂modal |
|
|
|
|