Commit c1da8356 authored by limengyang's avatar limengyang

feat(lmy):上传

parent 20ebfd87
......@@ -393,14 +393,20 @@
const confirmImport = async () => {
if (!productExcelList.value.length) return message.error('请上传文件');
if (!impotrCheckboxValue.value.length) return message.error('请选择现货区域');
const param: FormData = new FormData();
param.append('ghsCode', ghsCode);
param.append('ghsName', ghsName);
param.append('file', productExcelList.value[0]);
param.append('areaIds', impotrCheckboxValue.value.join(',') as any);
// const param: FormData = new FormData();
// param.append('ghsCode', ghsCode);
// param.append('ghsName', ghsName);
// param.append('file', productExcelList.value[0]);
// param.append('areaIds', impotrCheckboxValue.value.join(',') as any);
importLoading.value = true;
const res: any = await regionalSpotManageUploadOpsProductApi(param, productExcelList.value[0]);
console.log(res);
const res: any = await regionalSpotManageUploadOpsProductApi(
{
ghsCode: ghsCode,
ghsName: ghsName,
areaIds: impotrCheckboxValue.value,
},
productExcelList.value[0],
);
if (res.data.success) {
message.success('批量导入成功');
importCancel();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment