|
@@ -184,13 +184,6 @@
|
|
|
<el-button type="primary" @click="submitForm()" v-if="!props.detailStatus" size="large" v-preReClick>确 定</el-button>
|
|
|
</div>
|
|
|
|
|
|
- <el-dialog title="选择BOM" v-if="openBOM" v-model="openBOM" width="84%">
|
|
|
- <SelectBOM :selectStatus="true" :bomClassifyIdList="[1]" @selectBOM="selectBOM"></SelectBOM>
|
|
|
- <template #footer>
|
|
|
- <el-button @click="openBOM = false" size="large">关 闭</el-button>
|
|
|
- </template>
|
|
|
- </el-dialog>
|
|
|
-
|
|
|
<el-dialog title="选择包材配件" v-if="openPackingFittings" v-model="openPackingFittings" width="84%">
|
|
|
<SelectBOM :selectStatus="true" :bomClassifyIdList="[2, 3]" @selectBOM="selectPackingFittings"></SelectBOM>
|
|
|
<template #footer>
|
|
@@ -379,18 +372,6 @@ const uploadFile = async (file) => {
|
|
|
const handleSuccess = (uploadFile, index) => {
|
|
|
formData.data.skuSpecList[index].specImgUrl = uploadFile.raw.fileUrl;
|
|
|
};
|
|
|
-const uploadMainData = ref({});
|
|
|
-const uploadMainFile = async (file) => {
|
|
|
- const res = await proxy.post("/fileInfo/getSing", { fileName: file.name });
|
|
|
- uploadMainData.value = res.uploadBody;
|
|
|
- file.id = res.id;
|
|
|
- file.fileName = res.fileName;
|
|
|
- file.fileUrl = res.fileUrl;
|
|
|
- return true;
|
|
|
-};
|
|
|
-const handleMainSuccess = (response, uploadFile) => {
|
|
|
- formData.data.mainImgUrl = uploadFile.raw.fileUrl;
|
|
|
-};
|
|
|
const submitForm = () => {
|
|
|
submit.value.handleSubmit(() => {
|
|
|
if (formData.data.skuSpecList && formData.data.skuSpecList.length > 0) {
|
|
@@ -435,27 +416,6 @@ const getStyle = (text) => {
|
|
|
}
|
|
|
};
|
|
|
const rowIndex = ref(null);
|
|
|
-const openBOM = ref(false);
|
|
|
-const handleOpen = (index) => {
|
|
|
- rowIndex.value = index;
|
|
|
- openBOM.value = true;
|
|
|
-};
|
|
|
-const selectBOM = (item) => {
|
|
|
- if (item.id) {
|
|
|
- formData.data.skuSpecList[rowIndex.value].bomSpecId = item.id;
|
|
|
- formData.data.skuSpecList[rowIndex.value].bomSpecName = item.name;
|
|
|
- formData.data.skuSpecList[rowIndex.value].length = item.length;
|
|
|
- formData.data.skuSpecList[rowIndex.value].width = item.width;
|
|
|
- formData.data.skuSpecList[rowIndex.value].height = item.height;
|
|
|
- formData.data.skuSpecList[rowIndex.value].netWeight = item.netWeight;
|
|
|
- ElMessage({ message: "选择完成", type: "success" });
|
|
|
- openBOM.value = false;
|
|
|
- }
|
|
|
-};
|
|
|
-const clickRemoveBOM = (index) => {
|
|
|
- formData.data.skuSpecList[index].bomSpecId = "";
|
|
|
- formData.data.skuSpecList[index].bomSpecName = "";
|
|
|
-};
|
|
|
const openPackingFittings = ref(false);
|
|
|
const clickPackingFittings = (item) => {
|
|
|
rowIndex.value = item.$index;
|