|
|
@@ -80,7 +80,7 @@
|
|
|
|
|
|
<!-- 颜色资料列表、工艺资料列表、BOM资料列表 -->
|
|
|
<el-tabs v-model="activeName" @tab-click="handleClick">
|
|
|
- <el-tab-pane label="颜色资料" @click="showTable('颜色资料')" name="first">
|
|
|
+ <el-tab-pane label="颜色资料" name="first">
|
|
|
<el-table ref="multipleTable"
|
|
|
:row-style="{ height: '20px' }"
|
|
|
:cell-style="{ padding: '0px' }" :header-row-style="{ height: '20px' }"
|
|
|
@@ -109,7 +109,7 @@
|
|
|
</el-table>
|
|
|
</el-tab-pane>
|
|
|
|
|
|
- <el-tab-pane label="工艺资料" @click="showTable('工艺资料')" name="second">
|
|
|
+ <el-tab-pane label="工艺资料" name="second">
|
|
|
<el-table ref="multipleTable"
|
|
|
:row-style="{ height: '20px' }"
|
|
|
:cell-style="{ padding: '0px' }" :header-row-style="{ height: '20px' }"
|
|
|
@@ -158,7 +158,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
- <el-tab-pane label="技术附件" @click="showTable('技术附件')" name="fourth">
|
|
|
+ <el-tab-pane label="技术附件" name="fourth">
|
|
|
<el-table ref="multipleTable"
|
|
|
:row-style="{ height: '30px' }"
|
|
|
:cell-style="{ padding: '0px' }" :header-row-style="{ height: '30px' }"
|
|
|
@@ -181,7 +181,7 @@
|
|
|
</el-table>
|
|
|
</el-tab-pane>
|
|
|
|
|
|
- <el-tab-pane label="BOM资料" @click="showTable('BOM资料')" name="six">
|
|
|
+ <el-tab-pane label="BOM资料" name="six">
|
|
|
<el-table ref="multipleTable"
|
|
|
:row-style="{ height: '20px' }"
|
|
|
:cell-style="{ padding: '0px' }" :header-row-style="{ height: '20px' }"
|
|
|
@@ -208,7 +208,7 @@
|
|
|
</el-table>
|
|
|
</el-tab-pane>
|
|
|
|
|
|
- <el-tab-pane label="面料库存" @click="showTable('面料库存')" name="seven">
|
|
|
+ <el-tab-pane label="面料库存" name="seven">
|
|
|
<el-table ref="multipleTable"
|
|
|
:row-style="{ height: '20px' }"
|
|
|
:cell-style="{ padding: '0px' }" :header-row-style="{ height: '20px' }"
|
|
|
@@ -243,7 +243,6 @@
|
|
|
</el-tab-pane>
|
|
|
</el-tabs>
|
|
|
|
|
|
-
|
|
|
|
|
|
<!-- 修改颜色资料弹窗 -->
|
|
|
<el-dialog v-model="dialogFormVisible" :before-close="edit_closeDialog"
|
|
|
@@ -1484,16 +1483,20 @@ const edit_cyChange = async (value) => {
|
|
|
|
|
|
//修改颜色资料确认
|
|
|
const ys_edit_Dialog = async () => {
|
|
|
-if (!edit_formData.value) return;
|
|
|
-
|
|
|
-function buildSizeQuantitiesMap(sizes, formData) {
|
|
|
- const sizeQuantitiesMap = {};
|
|
|
- sizes.forEach(size => {
|
|
|
- const quantity = formData[size] || 0; // 使用逻辑或操作符确保所有尺码的数量
|
|
|
- sizeQuantitiesMap[size] = quantity;
|
|
|
- });
|
|
|
- return sizeQuantitiesMap;
|
|
|
- }
|
|
|
+ if (!edit_formData.value) return;
|
|
|
+ //颜色id
|
|
|
+ // console.log(edit_formData.value.color_id)
|
|
|
+
|
|
|
+ function buildSizeQuantitiesMap(sizes, formData) {
|
|
|
+ const sizeQuantitiesMap = {};
|
|
|
+ sizes.forEach(size => {
|
|
|
+ // 使用逻辑或操作符确保所有尺码的数量
|
|
|
+ const quantity = formData[size] || 0;
|
|
|
+ sizeQuantitiesMap[size] = quantity;
|
|
|
+ });
|
|
|
+ return sizeQuantitiesMap;
|
|
|
+ }
|
|
|
+
|
|
|
// 使用函数构建映射
|
|
|
const sizeQuantitiesMap = buildSizeQuantitiesMap(sizeDatas, edit_formData.value);
|
|
|
let index = 1;
|
|
|
@@ -1514,16 +1517,15 @@ function buildSizeQuantitiesMap(sizes, formData) {
|
|
|
const cmslValue = +edit_zdsformdata[`zds${index}`]; // 获取对应的数量
|
|
|
params[`cmsl${index++}`] = cmslValue === 0 ? "" : cmslValue; // 如果为0,赋值为空字符串
|
|
|
}
|
|
|
+ //颜色资料修改接口
|
|
|
const PrintDataEdit_list = await PrintDataEdit(params);
|
|
|
if(PrintDataEdit_list.code === 0){
|
|
|
dialogFormVisible.value = false;
|
|
|
ElMessage({type: 'success',message: '修改成功'})
|
|
|
-
|
|
|
//数据列表显示
|
|
|
const PrintListDatas = await PrintListData({order:_Gd_gdbh.value})
|
|
|
const jsOrderAttachments = await OrderAttachments({order:_Gd_gdbh.value,desc:'技术附件'})
|
|
|
const ddOrderAttachments = await OrderAttachments({order:_Gd_gdbh.value,desc:'订单资料附件'})
|
|
|
-
|
|
|
//颜色资料
|
|
|
if(PrintListDatas.data.列表.length === 0 ){
|
|
|
ystableData.length = 0
|
|
|
@@ -1544,10 +1546,12 @@ function buildSizeQuantitiesMap(sizes, formData) {
|
|
|
ElMessage({type: 'error',message: '修改失败'})
|
|
|
}
|
|
|
};
|
|
|
+
|
|
|
//颜色资料修改取消
|
|
|
const ys_edit_closeDialog = async (row) => {
|
|
|
dialogFormVisible.value = false;
|
|
|
};
|
|
|
+
|
|
|
const mlinventoryVisible = ref(false)
|
|
|
const historytableData = ref([])
|
|
|
// //双击面料库存
|
|
|
@@ -1890,8 +1894,8 @@ const addgdyj_onclick = async () => {
|
|
|
const child_order = ref('')
|
|
|
//单机颜色资料表格
|
|
|
const ystableclick = async (row) => {
|
|
|
- console.log(row.子订单编号)
|
|
|
- child_order.value = row.子订单编号
|
|
|
+ // console.log(row.子订单编号)
|
|
|
+ // child_order.value = row.子订单编号
|
|
|
}
|
|
|
|
|
|
|