Bläddra i källkod

feat(product): 更新产品价格字段并优化请求超时配置

- 将产品表格中的平档价、供应价、第三方售价字段更新为官网价、最低售价、协议价
- 在产品分类页面中添加当前项目ID到表单数据的赋值逻辑
- 将HTTP请求超时时间从50秒延长至100秒以提高稳定性
肖路 3 veckor sedan
förälder
incheckning
4706647ff1

+ 1 - 1
src/utils/request.ts

@@ -29,7 +29,7 @@ axios.defaults.headers['clientid'] = import.meta.env.VITE_APP_CLIENT_ID;
 // 创建 axios 实例
 const service = axios.create({
   baseURL: import.meta.env.VITE_APP_BASE_API,
-  timeout: 50000
+  timeout: 100000
 });
 
 // 请求拦截器

+ 3 - 3
src/views/external/product/index.vue

@@ -54,9 +54,9 @@
         <el-table-column label="品牌" align="center" prop="brandName" width="120" />
         <el-table-column label="单位" align="center" prop="unitName" width="80" />
         <el-table-column label="市场价" align="center" prop="marketPrice" width="100" />
-        <el-table-column label="平档价" align="center" prop="standardPrice" width="100" />
-        <el-table-column label="供应价" align="center" prop="purchasePrice" width="100" />
-        <el-table-column label="第三方售价" align="center" prop="externalPrice" width="100" />
+        <el-table-column label="官网价" align="center" prop="memberPrice" width="100" />
+        <el-table-column label="最低售价" align="center" prop="minSellingPrice" width="100" />
+        <el-table-column label="协议价" align="center" prop="externalPrice" width="100" />
         <el-table-column label="总库存" align="center" prop="totalInventory" width="100" />
 
         <el-table-column label="上架状态" align="center" prop="productStatus" width="100">

+ 2 - 0
src/views/external/productCategory/index.vue

@@ -171,6 +171,7 @@ const initProjectKey = () => {
   const currentProject = cache.local.getJSON('currentProject');
   if (currentProject && currentProject.id) {
     queryParams.value.itemId = currentProject.id;
+    form.value.itemId = currentProject.id;
   }
 }
 
@@ -263,6 +264,7 @@ const handleUpdate = async (row: ProductCategoryVO) => {
 const submitForm = () => {
   productCategoryFormRef.value?.validate(async (valid: boolean) => {
     if (valid) {
+      form.value.itemId = cache.local.getJSON('currentProject').id;
       form.value.id ? await updateProductCategory(form.value) : await addProductCategory(form.value);
       proxy?.$modal.msgSuccess('操作成功');
       dialog.visible = false;