瀏覽代碼

修改发票管理

tangning 3 年之前
父節點
當前提交
53534b4809

+ 4 - 1
src/api/model/baseModel.ts

@@ -1,6 +1,9 @@
-export interface BasicPageParams {
+export interface BasicPageParams<T> {
   page: number;
+  list: T[];
   pageSize: number;
+  pageNum?: number;
+  total?: number;
 }
 
 export interface BasicFetchResult<T> {

+ 12 - 10
src/api/order/index.ts

@@ -1,5 +1,5 @@
 import { defHttp } from '/@/utils/http/axios';
-import { PageParams, RentListGetResultModel, addCameraParams, updateParams,getItemParams } from './model';
+import { PageParams, RentListGetResultModel,InvoiceListResul, addCameraParams, updateParams,getItemParams } from './model';
 import { Result } from '/#/axios';
 
 enum Api {
@@ -10,6 +10,8 @@ enum Api {
   incrementExport = '/newV4/service/manage/order/increment/export',
   downList = '/newV4//service/manage/order/down/list',
   downExport = '/newV4/service/manage/order/down/export',
+  pageInvoice = '/newV4/service/manage/invoice/pageInvoice',
+  
 }
 
 /**
@@ -107,15 +109,15 @@ defHttp.post<Result>({
     ignoreCancelToken: true,
   },
 });
-// export const unDeviceApi = (params: PageParams) =>
-//   defHttp.post<RentListGetResultModel>({
-//     url: Api.unbindDevice,
-//     params,
-//     headers: {
-//       // @ts-ignore
-//       ignoreCancelToken: true,
-//     },
-//   });
+export const InvoiceList = (params: PageParams) =>
+  defHttp.post<InvoiceListResul>({
+    url: Api.pageInvoice,
+    params,
+    headers: {
+      // @ts-ignore
+      ignoreCancelToken: true,
+    },
+  });
 // export const allCompanyApi = (params: PageParams) =>
 //   defHttp.post<RentListGetResultModel>({
 //     url: Api.allCompany,

+ 14 - 0
src/api/order/model.ts

@@ -72,6 +72,20 @@ export interface DeviceListItem {
   wifiName: string;
 }
 
+export interface InvoiceList {
+  orderSn: string;
+  payTimeStart	: string;
+  payTimeEnd: string;
+  invoiceTimeStart: string;
+  invoiceTimeEnd: string;
+  orderBy: string;
+  sortBy: string;
+  pageSize: number;
+  pageNum: number;
+}
+
+
+export type InvoiceListResul = BasicPageParams<InvoiceList>
 /**
  * @description: Request list return value
  */

+ 1 - 0
src/router/routes/modules/dashboard.ts

@@ -12,6 +12,7 @@ const dashboard: AppRouteModule = {
     orderNo: 10,
     icon: 'ion:grid-outline',
     title: t('routes.dashboard.dashboard'),
+    hideChildrenInMenu: true,
   },
   children: [
     {

+ 15 - 2
src/router/routes/modules/invoice.ts

@@ -1,15 +1,28 @@
 import type { AppRouteRecordRaw } from '/@/router/types';
 import { t } from '/@/hooks/web/useI18n';
+import { LAYOUT } from '/@/router/constant';
 
 export const InvoiceRoute: AppRouteRecordRaw = {
   path: '/invoice',
   name: 'Invoice',
-  component: () => import('/@/views/invoice/index.vue'),
+  redirect: '/invoice/index',
+  component: LAYOUT,
   meta: {
     title: t('routes.dashboard.invoice'),
     icon: 'la:file-invoice-dollar',
-    hideChildrenInMenu: true,
+    orderNo: 10,
+    // hideChildrenInMenu: true,
   },
+  children: [
+    {
+      path: 'index',
+      name: 'index',
+      component: () => import('/@/views/invoice/index.vue'),
+      meta: {
+        title: t('routes.dashboard.invoice'),
+      },
+    },
+  ],
 };
 
 

+ 10 - 20
src/views/invoice/index.vue

@@ -100,7 +100,7 @@
         schemas: [
           {
             field: 'sceneName',
-            label: '下单时间',
+            label: '开票申请时间',
             component: 'RangePicker',
             componentProps: {
               maxLength: 100,
@@ -109,31 +109,21 @@
               xl: 7,
               xxl: 7,
             },
-          },{
-            field: 'sceneName',
-            label: '订单号',
-            component: 'Input',
-            componentProps: {
-              maxLength: 100,
-            },
-            colProps: {
-              xl: 6,
-              xxl: 6,
-            },
-          },{
+          },
+          {
             field: 'sceneName',
-            label: '手机号',
-            component: 'Input',
+            label: '支付时间',
+            component: 'RangePicker',
             componentProps: {
               maxLength: 100,
             },
             colProps: {
-              xl: 5,
-              xxl: 5,
+              xl: 7,
+              xxl: 7,
             },
           },{
             field: 'sceneName',
-            label: '支付平台交易号',
+            label: '订单号',
             component: 'Input',
             componentProps: {
               maxLength: 100,
@@ -142,12 +132,12 @@
               xl: 6,
               xxl: 6,
             },
-          },
+          }
         ],
       };
       const [registerTable] = useTable({
         api: DownList,
-        title: '下载列表',
+        title: '发票列表',
         // titleHelpMessage: ['已启用expandRowByClick', '已启用stopButtonPropagation'],
         columns: columns,
         useSearchForm: true,