Ver código fonte

修复bug:分页状态丢失筛选条件;

dodo hold 2 anos atrás
pai
commit
9ded482691

+ 1 - 1
.env.development

@@ -1,2 +1,2 @@
-VITE_API_BASE_URL= 'http://localhost:5186'
+VITE_API_BASE_URL= 'http://localhost:8186'
 VITE_API_BASE_SCOPE = 'admin'

+ 17 - 16
config/vite.config.dev.ts

@@ -3,21 +3,22 @@ import eslint from 'vite-plugin-eslint';
 import baseConfig from './vite.config.base';
 
 export default mergeConfig(
-  {
-    mode: 'development',
-    server: {
-      open: true,
-      fs: {
-        strict: true,
-      },
+    {
+        mode: 'development',
+        server: {
+            open: true,
+            port: 7173,
+            fs: {
+                strict: true,
+            },
+        },
+        plugins: [
+            eslint({
+                cache: false,
+                include: ['src/**/*.ts', 'src/**/*.tsx', 'src/**/*.vue'],
+                exclude: ['node_modules'],
+            }),
+        ],
     },
-    plugins: [
-      eslint({
-        cache: false,
-        include: ['src/**/*.ts', 'src/**/*.tsx', 'src/**/*.vue'],
-        exclude: ['node_modules'],
-      }),
-    ],
-  },
-  baseConfig
+    baseConfig
 );

+ 5 - 1
src/views/dashboard/dailyLog/index.vue

@@ -229,7 +229,11 @@ const search = () => {
   } as unknown as DailyLogParams);
 };
 const onPageChange = (current: number) => {
-  fetchData({ ...basePagination, current });
+  fetchData({
+    ...basePagination,
+    ...formModel.value,
+    current
+  });
 };
 
 fetchData();

+ 7 - 5
src/views/taobao/bill_dailys.vue

@@ -9,7 +9,7 @@
                         <a-row :gutter="16">
                             <a-col :span="8">
                                 <a-form-item field="keyword" label="账号名">
-                                    <selectAccount v-model="formModel.keyword"  @change="changeCompany" />
+                                    <selectAccount v-model="formModel.keyword" @change="changeCompany" />
                                 </a-form-item>
                             </a-col>
                             <a-col :span="8">
@@ -281,7 +281,7 @@ const toAmount = (val: any): any => {
     }
     return val;
 }
- 
+
 
 const fetchData = async (
     params: TkSettleBillsParams = {
@@ -378,11 +378,13 @@ const changeCompany = (value: any) => {
 
 
 
-
 const onPageChange = (current: number) => {
-    fetchData({ ...basePagination, current });
+    fetchData({
+        ...basePagination,
+        ...formModel.value,
+        current
+    });
 };
-
 fetchData({ ...formModel.value } as unknown as TkSettleBillsParams);
 const reset = () => {
     formModel.value = generateFormModel();

+ 5 - 1
src/views/taobao/income_report.vue

@@ -402,7 +402,11 @@ const search = () => {
     } as unknown as TkReportParams);
 };
 const onPageChange = (current: number) => {
-    fetchData({ ...basePagination, current });
+    fetchData({
+        ...basePagination,
+        ...formModel.value,
+        current
+    });
 };
 
 fetchData();

+ 5 - 1
src/views/taobao/orders.vue

@@ -332,7 +332,11 @@ const search = () => {
     } as unknown as TkOrdersParams);
 };
 const onPageChange = (current: number) => {
-    fetchData({ ...basePagination, current });
+    fetchData({
+        ...basePagination,
+        ...formModel.value,
+        current
+    });
 };
 
 fetchData();

+ 5 - 1
src/views/taobao/report_daily.vue

@@ -402,7 +402,11 @@ const search = () => {
     } as unknown as TkReportParams);
 };
 const onPageChange = (current: number) => {
-    fetchData({ ...basePagination, current });
+    fetchData({
+        ...basePagination,
+        ...formModel.value,
+        current
+    });
 };
 
 fetchData();