变更
This commit is contained in:
parent
40fb1c11ae
commit
8767d7e857
|
@ -266,6 +266,7 @@ const editDialogVisible = ref(false);
|
|||
const types = ref('');
|
||||
const Region = ref('');
|
||||
let selectedProduct = ref('');
|
||||
const loading = ref(false)
|
||||
let editForm = ref({
|
||||
id: '',
|
||||
goodImg: '',
|
||||
|
@ -311,14 +312,23 @@ const handleDelete = (index: number, row: any) => {
|
|||
}
|
||||
};
|
||||
const searchParams: any = ref({})
|
||||
const getTableData = async ()=>{
|
||||
const res = await myAxios.post('/api/goods/update',{...tableData.value})
|
||||
if(res.data.code === 1){
|
||||
const getTableData = async () => {
|
||||
loading.value = true;
|
||||
try {
|
||||
const res = await myAxios.post('/api/goods/update', {...tableData.value });
|
||||
if (res.data.code === 1) {
|
||||
tableData.value = res.data.data.records;
|
||||
}else{
|
||||
} else {
|
||||
ElMessage({
|
||||
message:'获取数据失败'
|
||||
})
|
||||
message: '获取数据失败',
|
||||
});
|
||||
}
|
||||
} catch (error) {
|
||||
ElMessage({
|
||||
message: '发生错误',
|
||||
});
|
||||
} finally {
|
||||
loading.value = false;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user