diff --git a/src/api/customer/overtime.ts b/src/api/customer/overtime.ts new file mode 100644 index 0000000..9f349d6 --- /dev/null +++ b/src/api/customer/overtime.ts @@ -0,0 +1,25 @@ +/** + * 到期样品接口 + */ +import request from '../index' +import type { IOvertimeListQuery } from '@/views/customer/sample/overTime/overtime_list_interface' +const prefix = '/meter' + +// 列表查询 +export function getOverTimeList(data: IOvertimeListQuery) { + return request({ + url: `${prefix}/sample/overtime/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出列表 +export function exportOverTimeList(data: Omit) { + return request({ + url: `${prefix}/sample/overtime/listExport`, + method: 'post', + responseType: 'blob', + data, + }) +} diff --git a/src/api/customer/overtime.ts b/src/api/customer/overtime.ts new file mode 100644 index 0000000..9f349d6 --- /dev/null +++ b/src/api/customer/overtime.ts @@ -0,0 +1,25 @@ +/** + * 到期样品接口 + */ +import request from '../index' +import type { IOvertimeListQuery } from '@/views/customer/sample/overTime/overtime_list_interface' +const prefix = '/meter' + +// 列表查询 +export function getOverTimeList(data: IOvertimeListQuery) { + return request({ + url: `${prefix}/sample/overtime/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出列表 +export function exportOverTimeList(data: Omit) { + return request({ + url: `${prefix}/sample/overtime/listExport`, + method: 'post', + responseType: 'blob', + data, + }) +} diff --git a/src/api/customer/sampleList.ts b/src/api/customer/sampleList.ts index 5ba0a6d..fb50c25 100644 --- a/src/api/customer/sampleList.ts +++ b/src/api/customer/sampleList.ts @@ -58,3 +58,4 @@ data, }) } + diff --git a/src/api/customer/overtime.ts b/src/api/customer/overtime.ts new file mode 100644 index 0000000..9f349d6 --- /dev/null +++ b/src/api/customer/overtime.ts @@ -0,0 +1,25 @@ +/** + * 到期样品接口 + */ +import request from '../index' +import type { IOvertimeListQuery } from '@/views/customer/sample/overTime/overtime_list_interface' +const prefix = '/meter' + +// 列表查询 +export function getOverTimeList(data: IOvertimeListQuery) { + return request({ + url: `${prefix}/sample/overtime/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出列表 +export function exportOverTimeList(data: Omit) { + return request({ + url: `${prefix}/sample/overtime/listExport`, + method: 'post', + responseType: 'blob', + data, + }) +} diff --git a/src/api/customer/sampleList.ts b/src/api/customer/sampleList.ts index 5ba0a6d..fb50c25 100644 --- a/src/api/customer/sampleList.ts +++ b/src/api/customer/sampleList.ts @@ -58,3 +58,4 @@ data, }) } + diff --git a/src/api/system/process.ts b/src/api/system/process.ts index e459424..c2d4419 100644 --- a/src/api/system/process.ts +++ b/src/api/system/process.ts @@ -112,7 +112,7 @@ beginTime: string endTime: string status: string - // ids: string[] + ids: string[] }) { return request({ url: `${prefix}/listExport`, diff --git a/src/api/customer/overtime.ts b/src/api/customer/overtime.ts new file mode 100644 index 0000000..9f349d6 --- /dev/null +++ b/src/api/customer/overtime.ts @@ -0,0 +1,25 @@ +/** + * 到期样品接口 + */ +import request from '../index' +import type { IOvertimeListQuery } from '@/views/customer/sample/overTime/overtime_list_interface' +const prefix = '/meter' + +// 列表查询 +export function getOverTimeList(data: IOvertimeListQuery) { + return request({ + url: `${prefix}/sample/overtime/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出列表 +export function exportOverTimeList(data: Omit) { + return request({ + url: `${prefix}/sample/overtime/listExport`, + method: 'post', + responseType: 'blob', + data, + }) +} diff --git a/src/api/customer/sampleList.ts b/src/api/customer/sampleList.ts index 5ba0a6d..fb50c25 100644 --- a/src/api/customer/sampleList.ts +++ b/src/api/customer/sampleList.ts @@ -58,3 +58,4 @@ data, }) } + diff --git a/src/api/system/process.ts b/src/api/system/process.ts index e459424..c2d4419 100644 --- a/src/api/system/process.ts +++ b/src/api/system/process.ts @@ -112,7 +112,7 @@ beginTime: string endTime: string status: string - // ids: string[] + ids: string[] }) { return request({ url: `${prefix}/listExport`, diff --git a/src/css/workflow.css b/src/css/workflow.css index eee3dec..f922b27 100644 --- a/src/css/workflow.css +++ b/src/css/workflow.css @@ -1395,7 +1395,8 @@ justify-content: center; flex-wrap: wrap; min-width: min-content; - background-color: #f5f8ff; + + /* background-color: #f5f8ff; */ transform-origin: 50% 0 0; } diff --git a/src/api/customer/overtime.ts b/src/api/customer/overtime.ts new file mode 100644 index 0000000..9f349d6 --- /dev/null +++ b/src/api/customer/overtime.ts @@ -0,0 +1,25 @@ +/** + * 到期样品接口 + */ +import request from '../index' +import type { IOvertimeListQuery } from '@/views/customer/sample/overTime/overtime_list_interface' +const prefix = '/meter' + +// 列表查询 +export function getOverTimeList(data: IOvertimeListQuery) { + return request({ + url: `${prefix}/sample/overtime/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出列表 +export function exportOverTimeList(data: Omit) { + return request({ + url: `${prefix}/sample/overtime/listExport`, + method: 'post', + responseType: 'blob', + data, + }) +} diff --git a/src/api/customer/sampleList.ts b/src/api/customer/sampleList.ts index 5ba0a6d..fb50c25 100644 --- a/src/api/customer/sampleList.ts +++ b/src/api/customer/sampleList.ts @@ -58,3 +58,4 @@ data, }) } + diff --git a/src/api/system/process.ts b/src/api/system/process.ts index e459424..c2d4419 100644 --- a/src/api/system/process.ts +++ b/src/api/system/process.ts @@ -112,7 +112,7 @@ beginTime: string endTime: string status: string - // ids: string[] + ids: string[] }) { return request({ url: `${prefix}/listExport`, diff --git a/src/css/workflow.css b/src/css/workflow.css index eee3dec..f922b27 100644 --- a/src/css/workflow.css +++ b/src/css/workflow.css @@ -1395,7 +1395,8 @@ justify-content: center; flex-wrap: wrap; min-width: min-content; - background-color: #f5f8ff; + + /* background-color: #f5f8ff; */ transform-origin: 50% 0 0; } diff --git a/src/router/modules/customer.ts b/src/router/modules/customer.ts index 4d133d0..f5280fa 100644 --- a/src/router/modules/customer.ts +++ b/src/router/modules/customer.ts @@ -71,6 +71,18 @@ auth: '/sample/overtime', }, }, + { + path: 'overtime/:type/:id?', + name: 'OverTimeDetail', + component: () => import('@/views/customer/sample/overTime/detail.vue'), + meta: { + title: '样品详情', + icon: 'ep:key', + sidebar: false, + breadcrumb: true, + activeMenu: '/sample/overtime', + }, + }, ], }, { diff --git a/src/api/customer/overtime.ts b/src/api/customer/overtime.ts new file mode 100644 index 0000000..9f349d6 --- /dev/null +++ b/src/api/customer/overtime.ts @@ -0,0 +1,25 @@ +/** + * 到期样品接口 + */ +import request from '../index' +import type { IOvertimeListQuery } from '@/views/customer/sample/overTime/overtime_list_interface' +const prefix = '/meter' + +// 列表查询 +export function getOverTimeList(data: IOvertimeListQuery) { + return request({ + url: `${prefix}/sample/overtime/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出列表 +export function exportOverTimeList(data: Omit) { + return request({ + url: `${prefix}/sample/overtime/listExport`, + method: 'post', + responseType: 'blob', + data, + }) +} diff --git a/src/api/customer/sampleList.ts b/src/api/customer/sampleList.ts index 5ba0a6d..fb50c25 100644 --- a/src/api/customer/sampleList.ts +++ b/src/api/customer/sampleList.ts @@ -58,3 +58,4 @@ data, }) } + diff --git a/src/api/system/process.ts b/src/api/system/process.ts index e459424..c2d4419 100644 --- a/src/api/system/process.ts +++ b/src/api/system/process.ts @@ -112,7 +112,7 @@ beginTime: string endTime: string status: string - // ids: string[] + ids: string[] }) { return request({ url: `${prefix}/listExport`, diff --git a/src/css/workflow.css b/src/css/workflow.css index eee3dec..f922b27 100644 --- a/src/css/workflow.css +++ b/src/css/workflow.css @@ -1395,7 +1395,8 @@ justify-content: center; flex-wrap: wrap; min-width: min-content; - background-color: #f5f8ff; + + /* background-color: #f5f8ff; */ transform-origin: 50% 0 0; } diff --git a/src/router/modules/customer.ts b/src/router/modules/customer.ts index 4d133d0..f5280fa 100644 --- a/src/router/modules/customer.ts +++ b/src/router/modules/customer.ts @@ -71,6 +71,18 @@ auth: '/sample/overtime', }, }, + { + path: 'overtime/:type/:id?', + name: 'OverTimeDetail', + component: () => import('@/views/customer/sample/overTime/detail.vue'), + meta: { + title: '样品详情', + icon: 'ep:key', + sidebar: false, + breadcrumb: true, + activeMenu: '/sample/overtime', + }, + }, ], }, { diff --git a/src/views/customer/sample/list/edit.vue b/src/views/customer/sample/list/edit.vue index 5758df9..153b66e 100644 --- a/src/views/customer/sample/list/edit.vue +++ b/src/views/customer/sample/list/edit.vue @@ -5,7 +5,7 @@ import type { FormInstance, UploadUserFile } from 'element-plus' import { ref } from 'vue' import { Calendar, Search } from '@element-plus/icons-vue' -import type { ISampleEdit, SimpleCertification, SimpleMeasureRecord } from './sample_list_interface' +import type { ISampleEdit, Menu, SimpleCertification, SimpleMeasureRecord } from './sample_list_interface' import sampleDialog from './sampleDialog.vue' import showPhoto from '@/views/system/tool/showPhoto.vue' import { SCHEDULE } from '@/utils/scheduleDict' @@ -14,6 +14,7 @@ import countries from '@/components/AddressSelect/country-code.json' import { UploadFile } from '@/api/measure/file' import type { TableColumn } from '@/components/NormalTable/table_interface' +import type { ICustomer } from '@/views/customer/customerInfo/customer_interface' const textMap: { [key: string]: string } = { edit: '编辑', @@ -177,13 +178,7 @@ const fetchCertifications = function (query = null) { dataList.value.certificationRecords = [] } -interface Menu { - name: string - columns: TableColumn[] - pagination: boolean - list: 'measureRecords' | 'certificationRecords' - searchFunc: Function -} + // 菜单 const menu: Menu[] = [ { @@ -275,12 +270,15 @@ } // 选好委托方 -const confirmCheckout = (val: any) => { - dataForm.value.customerNo = val[0].customerNo - dataForm.value.customerName = val[0].customerName - dataForm.value.phone = val[0].phone - dataForm.value.postalCode = val[0].postalCode - dataForm.value.companyAddress = val[0].briefName +const confirmCheckout = (val: Array) => { + if (val && val.length) { + const getValue = val[0] + dataForm.value.customerNo = getValue.customerNo + dataForm.value.customerName = getValue.customerName + dataForm.value.phone = getValue.phone + dataForm.value.postalCode = getValue.postalCode + dataForm.value.companyAddress = getValue.briefName + } } // 控制选择委托方对话框显隐 @@ -346,35 +344,35 @@ const getInfo = () => { getSapmleDetail({ id: infoId.value }).then((res) => { - // res.data = { - // ABC: 'A', - // companyAddress: '北京/北京市', - // customerName: '京东集团', - // customerNo: 'sygf202211290001', - // id: '', - // labelBind: '11222', - // manufacturer: '北京某厂家', - // manufacturerCountry: 'CN', - // manufacturingDate: '2023-03', - // manufacturingNo: '123121', - // mesureCategory: 'jd', - // mesureContent: '项目1', - // mesurePeriod: '1', - // mesureType: 'zj', - // minioFileName: '小程序工期表-1117_1674961769128.xlsx', - // phone: '950618', - // postalCode: 'test', - // remark: '无备注', - // sampleModel: '型号1', - // sampleName: '样品1', - // sampleNo: '', - // measureResultCode: 'bhg', - // } - dataForm.value = res.data - dataForm.value.measureResult = mesureResultMap[dataForm.value.measureResultCode] - for (const item of menu) { - item.searchFunc() + res.data = { + ABC: 'A', + companyAddress: '北京/北京市', + customerName: '京东集团', + customerNo: 'sygf202211290001', + id: '', + labelBind: '11222', + manufacturer: '北京某厂家', + manufacturerCountry: 'CN', + manufacturingDate: '2023-03', + manufacturingNo: '123121', + mesureCategory: 'jd', + mesureContent: '项目1', + mesurePeriod: '1', + mesureType: 'zj', + minioFileName: '小程序工期表-1117_1674961769128.xlsx', + phone: '950618', + postalCode: 'test', + remark: '无备注', + sampleModel: '型号1', + sampleName: '样品1', + sampleNo: '', + measureResultCode: 'bhg', } + // dataForm.value = res.data + // dataForm.value.measureResult = mesureResultMap[dataForm.value.measureResultCode] + // for (const item of menu) { + // item.searchFunc() + // } }) } @@ -456,12 +454,9 @@ @focus="customerNoFocus" > @@ -568,7 +563,47 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -704,7 +647,34 @@ - + + + + + + + + + + + + + + + + diff --git a/src/api/customer/overtime.ts b/src/api/customer/overtime.ts new file mode 100644 index 0000000..9f349d6 --- /dev/null +++ b/src/api/customer/overtime.ts @@ -0,0 +1,25 @@ +/** + * 到期样品接口 + */ +import request from '../index' +import type { IOvertimeListQuery } from '@/views/customer/sample/overTime/overtime_list_interface' +const prefix = '/meter' + +// 列表查询 +export function getOverTimeList(data: IOvertimeListQuery) { + return request({ + url: `${prefix}/sample/overtime/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出列表 +export function exportOverTimeList(data: Omit) { + return request({ + url: `${prefix}/sample/overtime/listExport`, + method: 'post', + responseType: 'blob', + data, + }) +} diff --git a/src/api/customer/sampleList.ts b/src/api/customer/sampleList.ts index 5ba0a6d..fb50c25 100644 --- a/src/api/customer/sampleList.ts +++ b/src/api/customer/sampleList.ts @@ -58,3 +58,4 @@ data, }) } + diff --git a/src/api/system/process.ts b/src/api/system/process.ts index e459424..c2d4419 100644 --- a/src/api/system/process.ts +++ b/src/api/system/process.ts @@ -112,7 +112,7 @@ beginTime: string endTime: string status: string - // ids: string[] + ids: string[] }) { return request({ url: `${prefix}/listExport`, diff --git a/src/css/workflow.css b/src/css/workflow.css index eee3dec..f922b27 100644 --- a/src/css/workflow.css +++ b/src/css/workflow.css @@ -1395,7 +1395,8 @@ justify-content: center; flex-wrap: wrap; min-width: min-content; - background-color: #f5f8ff; + + /* background-color: #f5f8ff; */ transform-origin: 50% 0 0; } diff --git a/src/router/modules/customer.ts b/src/router/modules/customer.ts index 4d133d0..f5280fa 100644 --- a/src/router/modules/customer.ts +++ b/src/router/modules/customer.ts @@ -71,6 +71,18 @@ auth: '/sample/overtime', }, }, + { + path: 'overtime/:type/:id?', + name: 'OverTimeDetail', + component: () => import('@/views/customer/sample/overTime/detail.vue'), + meta: { + title: '样品详情', + icon: 'ep:key', + sidebar: false, + breadcrumb: true, + activeMenu: '/sample/overtime', + }, + }, ], }, { diff --git a/src/views/customer/sample/list/edit.vue b/src/views/customer/sample/list/edit.vue index 5758df9..153b66e 100644 --- a/src/views/customer/sample/list/edit.vue +++ b/src/views/customer/sample/list/edit.vue @@ -5,7 +5,7 @@ import type { FormInstance, UploadUserFile } from 'element-plus' import { ref } from 'vue' import { Calendar, Search } from '@element-plus/icons-vue' -import type { ISampleEdit, SimpleCertification, SimpleMeasureRecord } from './sample_list_interface' +import type { ISampleEdit, Menu, SimpleCertification, SimpleMeasureRecord } from './sample_list_interface' import sampleDialog from './sampleDialog.vue' import showPhoto from '@/views/system/tool/showPhoto.vue' import { SCHEDULE } from '@/utils/scheduleDict' @@ -14,6 +14,7 @@ import countries from '@/components/AddressSelect/country-code.json' import { UploadFile } from '@/api/measure/file' import type { TableColumn } from '@/components/NormalTable/table_interface' +import type { ICustomer } from '@/views/customer/customerInfo/customer_interface' const textMap: { [key: string]: string } = { edit: '编辑', @@ -177,13 +178,7 @@ const fetchCertifications = function (query = null) { dataList.value.certificationRecords = [] } -interface Menu { - name: string - columns: TableColumn[] - pagination: boolean - list: 'measureRecords' | 'certificationRecords' - searchFunc: Function -} + // 菜单 const menu: Menu[] = [ { @@ -275,12 +270,15 @@ } // 选好委托方 -const confirmCheckout = (val: any) => { - dataForm.value.customerNo = val[0].customerNo - dataForm.value.customerName = val[0].customerName - dataForm.value.phone = val[0].phone - dataForm.value.postalCode = val[0].postalCode - dataForm.value.companyAddress = val[0].briefName +const confirmCheckout = (val: Array) => { + if (val && val.length) { + const getValue = val[0] + dataForm.value.customerNo = getValue.customerNo + dataForm.value.customerName = getValue.customerName + dataForm.value.phone = getValue.phone + dataForm.value.postalCode = getValue.postalCode + dataForm.value.companyAddress = getValue.briefName + } } // 控制选择委托方对话框显隐 @@ -346,35 +344,35 @@ const getInfo = () => { getSapmleDetail({ id: infoId.value }).then((res) => { - // res.data = { - // ABC: 'A', - // companyAddress: '北京/北京市', - // customerName: '京东集团', - // customerNo: 'sygf202211290001', - // id: '', - // labelBind: '11222', - // manufacturer: '北京某厂家', - // manufacturerCountry: 'CN', - // manufacturingDate: '2023-03', - // manufacturingNo: '123121', - // mesureCategory: 'jd', - // mesureContent: '项目1', - // mesurePeriod: '1', - // mesureType: 'zj', - // minioFileName: '小程序工期表-1117_1674961769128.xlsx', - // phone: '950618', - // postalCode: 'test', - // remark: '无备注', - // sampleModel: '型号1', - // sampleName: '样品1', - // sampleNo: '', - // measureResultCode: 'bhg', - // } - dataForm.value = res.data - dataForm.value.measureResult = mesureResultMap[dataForm.value.measureResultCode] - for (const item of menu) { - item.searchFunc() + res.data = { + ABC: 'A', + companyAddress: '北京/北京市', + customerName: '京东集团', + customerNo: 'sygf202211290001', + id: '', + labelBind: '11222', + manufacturer: '北京某厂家', + manufacturerCountry: 'CN', + manufacturingDate: '2023-03', + manufacturingNo: '123121', + mesureCategory: 'jd', + mesureContent: '项目1', + mesurePeriod: '1', + mesureType: 'zj', + minioFileName: '小程序工期表-1117_1674961769128.xlsx', + phone: '950618', + postalCode: 'test', + remark: '无备注', + sampleModel: '型号1', + sampleName: '样品1', + sampleNo: '', + measureResultCode: 'bhg', } + // dataForm.value = res.data + // dataForm.value.measureResult = mesureResultMap[dataForm.value.measureResultCode] + // for (const item of menu) { + // item.searchFunc() + // } }) } @@ -456,12 +454,9 @@ @focus="customerNoFocus" > @@ -568,7 +563,47 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -704,7 +647,34 @@ - + + + + + + + + + + + + + + + + diff --git a/src/views/customer/sample/list/list.vue b/src/views/customer/sample/list/list.vue index 08dc008..4086b48 100644 --- a/src/views/customer/sample/list/list.vue +++ b/src/views/customer/sample/list/list.vue @@ -132,8 +132,8 @@ sampleModel: '', // 型号 customerId: '', // 委托方代码 customerName: '', // 委托方名称 - startTime: '', // 投诉开始时间 - endTime: '', // 投诉结束时间 + startTime: '', // 检定开始时间 + endTime: '', // 检定结束时间 offset: 1, limit: 20, } @@ -226,7 +226,7 @@ printJSON(list.value, properties, '样品列表') } else if (checkoutList.value.length > 0) { - const printList = list.value.filter((item: any) => checkoutList.value.includes(item.id)) + const printList = list.value.filter((item: ISampleList) => checkoutList.value.includes(item.id)) printJSON(printList, properties, '样品列表') } else { diff --git a/src/api/customer/overtime.ts b/src/api/customer/overtime.ts new file mode 100644 index 0000000..9f349d6 --- /dev/null +++ b/src/api/customer/overtime.ts @@ -0,0 +1,25 @@ +/** + * 到期样品接口 + */ +import request from '../index' +import type { IOvertimeListQuery } from '@/views/customer/sample/overTime/overtime_list_interface' +const prefix = '/meter' + +// 列表查询 +export function getOverTimeList(data: IOvertimeListQuery) { + return request({ + url: `${prefix}/sample/overtime/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出列表 +export function exportOverTimeList(data: Omit) { + return request({ + url: `${prefix}/sample/overtime/listExport`, + method: 'post', + responseType: 'blob', + data, + }) +} diff --git a/src/api/customer/sampleList.ts b/src/api/customer/sampleList.ts index 5ba0a6d..fb50c25 100644 --- a/src/api/customer/sampleList.ts +++ b/src/api/customer/sampleList.ts @@ -58,3 +58,4 @@ data, }) } + diff --git a/src/api/system/process.ts b/src/api/system/process.ts index e459424..c2d4419 100644 --- a/src/api/system/process.ts +++ b/src/api/system/process.ts @@ -112,7 +112,7 @@ beginTime: string endTime: string status: string - // ids: string[] + ids: string[] }) { return request({ url: `${prefix}/listExport`, diff --git a/src/css/workflow.css b/src/css/workflow.css index eee3dec..f922b27 100644 --- a/src/css/workflow.css +++ b/src/css/workflow.css @@ -1395,7 +1395,8 @@ justify-content: center; flex-wrap: wrap; min-width: min-content; - background-color: #f5f8ff; + + /* background-color: #f5f8ff; */ transform-origin: 50% 0 0; } diff --git a/src/router/modules/customer.ts b/src/router/modules/customer.ts index 4d133d0..f5280fa 100644 --- a/src/router/modules/customer.ts +++ b/src/router/modules/customer.ts @@ -71,6 +71,18 @@ auth: '/sample/overtime', }, }, + { + path: 'overtime/:type/:id?', + name: 'OverTimeDetail', + component: () => import('@/views/customer/sample/overTime/detail.vue'), + meta: { + title: '样品详情', + icon: 'ep:key', + sidebar: false, + breadcrumb: true, + activeMenu: '/sample/overtime', + }, + }, ], }, { diff --git a/src/views/customer/sample/list/edit.vue b/src/views/customer/sample/list/edit.vue index 5758df9..153b66e 100644 --- a/src/views/customer/sample/list/edit.vue +++ b/src/views/customer/sample/list/edit.vue @@ -5,7 +5,7 @@ import type { FormInstance, UploadUserFile } from 'element-plus' import { ref } from 'vue' import { Calendar, Search } from '@element-plus/icons-vue' -import type { ISampleEdit, SimpleCertification, SimpleMeasureRecord } from './sample_list_interface' +import type { ISampleEdit, Menu, SimpleCertification, SimpleMeasureRecord } from './sample_list_interface' import sampleDialog from './sampleDialog.vue' import showPhoto from '@/views/system/tool/showPhoto.vue' import { SCHEDULE } from '@/utils/scheduleDict' @@ -14,6 +14,7 @@ import countries from '@/components/AddressSelect/country-code.json' import { UploadFile } from '@/api/measure/file' import type { TableColumn } from '@/components/NormalTable/table_interface' +import type { ICustomer } from '@/views/customer/customerInfo/customer_interface' const textMap: { [key: string]: string } = { edit: '编辑', @@ -177,13 +178,7 @@ const fetchCertifications = function (query = null) { dataList.value.certificationRecords = [] } -interface Menu { - name: string - columns: TableColumn[] - pagination: boolean - list: 'measureRecords' | 'certificationRecords' - searchFunc: Function -} + // 菜单 const menu: Menu[] = [ { @@ -275,12 +270,15 @@ } // 选好委托方 -const confirmCheckout = (val: any) => { - dataForm.value.customerNo = val[0].customerNo - dataForm.value.customerName = val[0].customerName - dataForm.value.phone = val[0].phone - dataForm.value.postalCode = val[0].postalCode - dataForm.value.companyAddress = val[0].briefName +const confirmCheckout = (val: Array) => { + if (val && val.length) { + const getValue = val[0] + dataForm.value.customerNo = getValue.customerNo + dataForm.value.customerName = getValue.customerName + dataForm.value.phone = getValue.phone + dataForm.value.postalCode = getValue.postalCode + dataForm.value.companyAddress = getValue.briefName + } } // 控制选择委托方对话框显隐 @@ -346,35 +344,35 @@ const getInfo = () => { getSapmleDetail({ id: infoId.value }).then((res) => { - // res.data = { - // ABC: 'A', - // companyAddress: '北京/北京市', - // customerName: '京东集团', - // customerNo: 'sygf202211290001', - // id: '', - // labelBind: '11222', - // manufacturer: '北京某厂家', - // manufacturerCountry: 'CN', - // manufacturingDate: '2023-03', - // manufacturingNo: '123121', - // mesureCategory: 'jd', - // mesureContent: '项目1', - // mesurePeriod: '1', - // mesureType: 'zj', - // minioFileName: '小程序工期表-1117_1674961769128.xlsx', - // phone: '950618', - // postalCode: 'test', - // remark: '无备注', - // sampleModel: '型号1', - // sampleName: '样品1', - // sampleNo: '', - // measureResultCode: 'bhg', - // } - dataForm.value = res.data - dataForm.value.measureResult = mesureResultMap[dataForm.value.measureResultCode] - for (const item of menu) { - item.searchFunc() + res.data = { + ABC: 'A', + companyAddress: '北京/北京市', + customerName: '京东集团', + customerNo: 'sygf202211290001', + id: '', + labelBind: '11222', + manufacturer: '北京某厂家', + manufacturerCountry: 'CN', + manufacturingDate: '2023-03', + manufacturingNo: '123121', + mesureCategory: 'jd', + mesureContent: '项目1', + mesurePeriod: '1', + mesureType: 'zj', + minioFileName: '小程序工期表-1117_1674961769128.xlsx', + phone: '950618', + postalCode: 'test', + remark: '无备注', + sampleModel: '型号1', + sampleName: '样品1', + sampleNo: '', + measureResultCode: 'bhg', } + // dataForm.value = res.data + // dataForm.value.measureResult = mesureResultMap[dataForm.value.measureResultCode] + // for (const item of menu) { + // item.searchFunc() + // } }) } @@ -456,12 +454,9 @@ @focus="customerNoFocus" > @@ -568,7 +563,47 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -704,7 +647,34 @@ - + + + + + + + + + + + + + + + + diff --git a/src/views/customer/sample/list/list.vue b/src/views/customer/sample/list/list.vue index 08dc008..4086b48 100644 --- a/src/views/customer/sample/list/list.vue +++ b/src/views/customer/sample/list/list.vue @@ -132,8 +132,8 @@ sampleModel: '', // 型号 customerId: '', // 委托方代码 customerName: '', // 委托方名称 - startTime: '', // 投诉开始时间 - endTime: '', // 投诉结束时间 + startTime: '', // 检定开始时间 + endTime: '', // 检定结束时间 offset: 1, limit: 20, } @@ -226,7 +226,7 @@ printJSON(list.value, properties, '样品列表') } else if (checkoutList.value.length > 0) { - const printList = list.value.filter((item: any) => checkoutList.value.includes(item.id)) + const printList = list.value.filter((item: ISampleList) => checkoutList.value.includes(item.id)) printJSON(printList, properties, '样品列表') } else { diff --git a/src/views/customer/sample/list/sampleDialog.vue b/src/views/customer/sample/list/sampleDialog.vue index ea2d652..a5a371b 100644 --- a/src/views/customer/sample/list/sampleDialog.vue +++ b/src/views/customer/sample/list/sampleDialog.vue @@ -88,37 +88,37 @@ // 是否显示当前页,否则跳转第一页 listQuery.value.offset = 1 } - // getCustomerList(listQuery.value).then((response) => { - // // 模拟数据 - // response.data.rows = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] - // list.value = response.data.rows.map((item: ICustomer) => { - // if (item.companyProvinceName && item.companyCityName) { - // item.briefName = `${item.companyProvinceName}/${item.companyCityName}` - // } - // else { - // item.briefName = item.companyProvinceName || item.companyCityName - // } - // return item - // }) - // total.value = parseInt(response.data.total) - // loadingTable.value = false - // }) + getCustomerList(listQuery.value).then((response) => { + // 模拟数据 + response.data.rows = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] + list.value = response.data.rows.map((item: ICustomer) => { + if (item.companyProvinceName && item.companyCityName) { + item.briefName = `${item.companyProvinceName}/${item.companyCityName}` + } + else { + item.briefName = item.companyProvinceName || item.companyCityName + } + return item + }) + total.value = parseInt(response.data.total) + loadingTable.value = false + }) // 模拟数据 - const response = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, - { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '2集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, - { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '3集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] - list.value = response.map((item: ICustomer) => { - if (item.companyProvinceName && item.companyCityName) { - item.briefName = `${item.companyProvinceName}/${item.companyCityName}` - } - else { - item.briefName = item.companyProvinceName || item.companyCityName - } - return item - }) - total.value = 50 - loadingTable.value = false + // const response = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, + // { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '2集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, + // { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '3集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] + // list.value = response.map((item: ICustomer) => { + // if (item.companyProvinceName && item.companyCityName) { + // item.briefName = `${item.companyProvinceName}/${item.companyCityName}` + // } + // else { + // item.briefName = item.companyProvinceName || item.companyCityName + // } + // return item + // }) + // total.value = 50 + // loadingTable.value = false } // 多选发生改变时 function handleSelectionChange(e: any) { diff --git a/src/api/customer/overtime.ts b/src/api/customer/overtime.ts new file mode 100644 index 0000000..9f349d6 --- /dev/null +++ b/src/api/customer/overtime.ts @@ -0,0 +1,25 @@ +/** + * 到期样品接口 + */ +import request from '../index' +import type { IOvertimeListQuery } from '@/views/customer/sample/overTime/overtime_list_interface' +const prefix = '/meter' + +// 列表查询 +export function getOverTimeList(data: IOvertimeListQuery) { + return request({ + url: `${prefix}/sample/overtime/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出列表 +export function exportOverTimeList(data: Omit) { + return request({ + url: `${prefix}/sample/overtime/listExport`, + method: 'post', + responseType: 'blob', + data, + }) +} diff --git a/src/api/customer/sampleList.ts b/src/api/customer/sampleList.ts index 5ba0a6d..fb50c25 100644 --- a/src/api/customer/sampleList.ts +++ b/src/api/customer/sampleList.ts @@ -58,3 +58,4 @@ data, }) } + diff --git a/src/api/system/process.ts b/src/api/system/process.ts index e459424..c2d4419 100644 --- a/src/api/system/process.ts +++ b/src/api/system/process.ts @@ -112,7 +112,7 @@ beginTime: string endTime: string status: string - // ids: string[] + ids: string[] }) { return request({ url: `${prefix}/listExport`, diff --git a/src/css/workflow.css b/src/css/workflow.css index eee3dec..f922b27 100644 --- a/src/css/workflow.css +++ b/src/css/workflow.css @@ -1395,7 +1395,8 @@ justify-content: center; flex-wrap: wrap; min-width: min-content; - background-color: #f5f8ff; + + /* background-color: #f5f8ff; */ transform-origin: 50% 0 0; } diff --git a/src/router/modules/customer.ts b/src/router/modules/customer.ts index 4d133d0..f5280fa 100644 --- a/src/router/modules/customer.ts +++ b/src/router/modules/customer.ts @@ -71,6 +71,18 @@ auth: '/sample/overtime', }, }, + { + path: 'overtime/:type/:id?', + name: 'OverTimeDetail', + component: () => import('@/views/customer/sample/overTime/detail.vue'), + meta: { + title: '样品详情', + icon: 'ep:key', + sidebar: false, + breadcrumb: true, + activeMenu: '/sample/overtime', + }, + }, ], }, { diff --git a/src/views/customer/sample/list/edit.vue b/src/views/customer/sample/list/edit.vue index 5758df9..153b66e 100644 --- a/src/views/customer/sample/list/edit.vue +++ b/src/views/customer/sample/list/edit.vue @@ -5,7 +5,7 @@ import type { FormInstance, UploadUserFile } from 'element-plus' import { ref } from 'vue' import { Calendar, Search } from '@element-plus/icons-vue' -import type { ISampleEdit, SimpleCertification, SimpleMeasureRecord } from './sample_list_interface' +import type { ISampleEdit, Menu, SimpleCertification, SimpleMeasureRecord } from './sample_list_interface' import sampleDialog from './sampleDialog.vue' import showPhoto from '@/views/system/tool/showPhoto.vue' import { SCHEDULE } from '@/utils/scheduleDict' @@ -14,6 +14,7 @@ import countries from '@/components/AddressSelect/country-code.json' import { UploadFile } from '@/api/measure/file' import type { TableColumn } from '@/components/NormalTable/table_interface' +import type { ICustomer } from '@/views/customer/customerInfo/customer_interface' const textMap: { [key: string]: string } = { edit: '编辑', @@ -177,13 +178,7 @@ const fetchCertifications = function (query = null) { dataList.value.certificationRecords = [] } -interface Menu { - name: string - columns: TableColumn[] - pagination: boolean - list: 'measureRecords' | 'certificationRecords' - searchFunc: Function -} + // 菜单 const menu: Menu[] = [ { @@ -275,12 +270,15 @@ } // 选好委托方 -const confirmCheckout = (val: any) => { - dataForm.value.customerNo = val[0].customerNo - dataForm.value.customerName = val[0].customerName - dataForm.value.phone = val[0].phone - dataForm.value.postalCode = val[0].postalCode - dataForm.value.companyAddress = val[0].briefName +const confirmCheckout = (val: Array) => { + if (val && val.length) { + const getValue = val[0] + dataForm.value.customerNo = getValue.customerNo + dataForm.value.customerName = getValue.customerName + dataForm.value.phone = getValue.phone + dataForm.value.postalCode = getValue.postalCode + dataForm.value.companyAddress = getValue.briefName + } } // 控制选择委托方对话框显隐 @@ -346,35 +344,35 @@ const getInfo = () => { getSapmleDetail({ id: infoId.value }).then((res) => { - // res.data = { - // ABC: 'A', - // companyAddress: '北京/北京市', - // customerName: '京东集团', - // customerNo: 'sygf202211290001', - // id: '', - // labelBind: '11222', - // manufacturer: '北京某厂家', - // manufacturerCountry: 'CN', - // manufacturingDate: '2023-03', - // manufacturingNo: '123121', - // mesureCategory: 'jd', - // mesureContent: '项目1', - // mesurePeriod: '1', - // mesureType: 'zj', - // minioFileName: '小程序工期表-1117_1674961769128.xlsx', - // phone: '950618', - // postalCode: 'test', - // remark: '无备注', - // sampleModel: '型号1', - // sampleName: '样品1', - // sampleNo: '', - // measureResultCode: 'bhg', - // } - dataForm.value = res.data - dataForm.value.measureResult = mesureResultMap[dataForm.value.measureResultCode] - for (const item of menu) { - item.searchFunc() + res.data = { + ABC: 'A', + companyAddress: '北京/北京市', + customerName: '京东集团', + customerNo: 'sygf202211290001', + id: '', + labelBind: '11222', + manufacturer: '北京某厂家', + manufacturerCountry: 'CN', + manufacturingDate: '2023-03', + manufacturingNo: '123121', + mesureCategory: 'jd', + mesureContent: '项目1', + mesurePeriod: '1', + mesureType: 'zj', + minioFileName: '小程序工期表-1117_1674961769128.xlsx', + phone: '950618', + postalCode: 'test', + remark: '无备注', + sampleModel: '型号1', + sampleName: '样品1', + sampleNo: '', + measureResultCode: 'bhg', } + // dataForm.value = res.data + // dataForm.value.measureResult = mesureResultMap[dataForm.value.measureResultCode] + // for (const item of menu) { + // item.searchFunc() + // } }) } @@ -456,12 +454,9 @@ @focus="customerNoFocus" > @@ -568,7 +563,47 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -704,7 +647,34 @@ - + + + + + + + + + + + + + + + + diff --git a/src/views/customer/sample/list/list.vue b/src/views/customer/sample/list/list.vue index 08dc008..4086b48 100644 --- a/src/views/customer/sample/list/list.vue +++ b/src/views/customer/sample/list/list.vue @@ -132,8 +132,8 @@ sampleModel: '', // 型号 customerId: '', // 委托方代码 customerName: '', // 委托方名称 - startTime: '', // 投诉开始时间 - endTime: '', // 投诉结束时间 + startTime: '', // 检定开始时间 + endTime: '', // 检定结束时间 offset: 1, limit: 20, } @@ -226,7 +226,7 @@ printJSON(list.value, properties, '样品列表') } else if (checkoutList.value.length > 0) { - const printList = list.value.filter((item: any) => checkoutList.value.includes(item.id)) + const printList = list.value.filter((item: ISampleList) => checkoutList.value.includes(item.id)) printJSON(printList, properties, '样品列表') } else { diff --git a/src/views/customer/sample/list/sampleDialog.vue b/src/views/customer/sample/list/sampleDialog.vue index ea2d652..a5a371b 100644 --- a/src/views/customer/sample/list/sampleDialog.vue +++ b/src/views/customer/sample/list/sampleDialog.vue @@ -88,37 +88,37 @@ // 是否显示当前页,否则跳转第一页 listQuery.value.offset = 1 } - // getCustomerList(listQuery.value).then((response) => { - // // 模拟数据 - // response.data.rows = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] - // list.value = response.data.rows.map((item: ICustomer) => { - // if (item.companyProvinceName && item.companyCityName) { - // item.briefName = `${item.companyProvinceName}/${item.companyCityName}` - // } - // else { - // item.briefName = item.companyProvinceName || item.companyCityName - // } - // return item - // }) - // total.value = parseInt(response.data.total) - // loadingTable.value = false - // }) + getCustomerList(listQuery.value).then((response) => { + // 模拟数据 + response.data.rows = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] + list.value = response.data.rows.map((item: ICustomer) => { + if (item.companyProvinceName && item.companyCityName) { + item.briefName = `${item.companyProvinceName}/${item.companyCityName}` + } + else { + item.briefName = item.companyProvinceName || item.companyCityName + } + return item + }) + total.value = parseInt(response.data.total) + loadingTable.value = false + }) // 模拟数据 - const response = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, - { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '2集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, - { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '3集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] - list.value = response.map((item: ICustomer) => { - if (item.companyProvinceName && item.companyCityName) { - item.briefName = `${item.companyProvinceName}/${item.companyCityName}` - } - else { - item.briefName = item.companyProvinceName || item.companyCityName - } - return item - }) - total.value = 50 - loadingTable.value = false + // const response = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, + // { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '2集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, + // { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '3集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] + // list.value = response.map((item: ICustomer) => { + // if (item.companyProvinceName && item.companyCityName) { + // item.briefName = `${item.companyProvinceName}/${item.companyCityName}` + // } + // else { + // item.briefName = item.companyProvinceName || item.companyCityName + // } + // return item + // }) + // total.value = 50 + // loadingTable.value = false } // 多选发生改变时 function handleSelectionChange(e: any) { diff --git a/src/views/customer/sample/list/sample_list_interface.ts b/src/views/customer/sample/list/sample_list_interface.ts index f5d0514..26638ce 100644 --- a/src/views/customer/sample/list/sample_list_interface.ts +++ b/src/views/customer/sample/list/sample_list_interface.ts @@ -1,3 +1,5 @@ +import type { TableColumn } from '@/components/NormalTable/table_interface' + export interface ISampleListQuery { sampleNo: string // 样品编号 sampleName: string // 样品名称 @@ -11,7 +13,7 @@ } export interface ISampleList { - id?: string // 样品唯一标识 + id: string // 样品唯一标识 sampleNo: string // 样品编号 sampleName: string // 样品名称 sampleModel: string // 型号 @@ -71,3 +73,11 @@ effectiveDate: string // 证书出具日期 expirationDate: string // 证书有效期 } + +export interface Menu { + name: string + columns: TableColumn[] + pagination: boolean + list: 'measureRecords' | 'certificationRecords' + searchFunc: Function +} diff --git a/src/api/customer/overtime.ts b/src/api/customer/overtime.ts new file mode 100644 index 0000000..9f349d6 --- /dev/null +++ b/src/api/customer/overtime.ts @@ -0,0 +1,25 @@ +/** + * 到期样品接口 + */ +import request from '../index' +import type { IOvertimeListQuery } from '@/views/customer/sample/overTime/overtime_list_interface' +const prefix = '/meter' + +// 列表查询 +export function getOverTimeList(data: IOvertimeListQuery) { + return request({ + url: `${prefix}/sample/overtime/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出列表 +export function exportOverTimeList(data: Omit) { + return request({ + url: `${prefix}/sample/overtime/listExport`, + method: 'post', + responseType: 'blob', + data, + }) +} diff --git a/src/api/customer/sampleList.ts b/src/api/customer/sampleList.ts index 5ba0a6d..fb50c25 100644 --- a/src/api/customer/sampleList.ts +++ b/src/api/customer/sampleList.ts @@ -58,3 +58,4 @@ data, }) } + diff --git a/src/api/system/process.ts b/src/api/system/process.ts index e459424..c2d4419 100644 --- a/src/api/system/process.ts +++ b/src/api/system/process.ts @@ -112,7 +112,7 @@ beginTime: string endTime: string status: string - // ids: string[] + ids: string[] }) { return request({ url: `${prefix}/listExport`, diff --git a/src/css/workflow.css b/src/css/workflow.css index eee3dec..f922b27 100644 --- a/src/css/workflow.css +++ b/src/css/workflow.css @@ -1395,7 +1395,8 @@ justify-content: center; flex-wrap: wrap; min-width: min-content; - background-color: #f5f8ff; + + /* background-color: #f5f8ff; */ transform-origin: 50% 0 0; } diff --git a/src/router/modules/customer.ts b/src/router/modules/customer.ts index 4d133d0..f5280fa 100644 --- a/src/router/modules/customer.ts +++ b/src/router/modules/customer.ts @@ -71,6 +71,18 @@ auth: '/sample/overtime', }, }, + { + path: 'overtime/:type/:id?', + name: 'OverTimeDetail', + component: () => import('@/views/customer/sample/overTime/detail.vue'), + meta: { + title: '样品详情', + icon: 'ep:key', + sidebar: false, + breadcrumb: true, + activeMenu: '/sample/overtime', + }, + }, ], }, { diff --git a/src/views/customer/sample/list/edit.vue b/src/views/customer/sample/list/edit.vue index 5758df9..153b66e 100644 --- a/src/views/customer/sample/list/edit.vue +++ b/src/views/customer/sample/list/edit.vue @@ -5,7 +5,7 @@ import type { FormInstance, UploadUserFile } from 'element-plus' import { ref } from 'vue' import { Calendar, Search } from '@element-plus/icons-vue' -import type { ISampleEdit, SimpleCertification, SimpleMeasureRecord } from './sample_list_interface' +import type { ISampleEdit, Menu, SimpleCertification, SimpleMeasureRecord } from './sample_list_interface' import sampleDialog from './sampleDialog.vue' import showPhoto from '@/views/system/tool/showPhoto.vue' import { SCHEDULE } from '@/utils/scheduleDict' @@ -14,6 +14,7 @@ import countries from '@/components/AddressSelect/country-code.json' import { UploadFile } from '@/api/measure/file' import type { TableColumn } from '@/components/NormalTable/table_interface' +import type { ICustomer } from '@/views/customer/customerInfo/customer_interface' const textMap: { [key: string]: string } = { edit: '编辑', @@ -177,13 +178,7 @@ const fetchCertifications = function (query = null) { dataList.value.certificationRecords = [] } -interface Menu { - name: string - columns: TableColumn[] - pagination: boolean - list: 'measureRecords' | 'certificationRecords' - searchFunc: Function -} + // 菜单 const menu: Menu[] = [ { @@ -275,12 +270,15 @@ } // 选好委托方 -const confirmCheckout = (val: any) => { - dataForm.value.customerNo = val[0].customerNo - dataForm.value.customerName = val[0].customerName - dataForm.value.phone = val[0].phone - dataForm.value.postalCode = val[0].postalCode - dataForm.value.companyAddress = val[0].briefName +const confirmCheckout = (val: Array) => { + if (val && val.length) { + const getValue = val[0] + dataForm.value.customerNo = getValue.customerNo + dataForm.value.customerName = getValue.customerName + dataForm.value.phone = getValue.phone + dataForm.value.postalCode = getValue.postalCode + dataForm.value.companyAddress = getValue.briefName + } } // 控制选择委托方对话框显隐 @@ -346,35 +344,35 @@ const getInfo = () => { getSapmleDetail({ id: infoId.value }).then((res) => { - // res.data = { - // ABC: 'A', - // companyAddress: '北京/北京市', - // customerName: '京东集团', - // customerNo: 'sygf202211290001', - // id: '', - // labelBind: '11222', - // manufacturer: '北京某厂家', - // manufacturerCountry: 'CN', - // manufacturingDate: '2023-03', - // manufacturingNo: '123121', - // mesureCategory: 'jd', - // mesureContent: '项目1', - // mesurePeriod: '1', - // mesureType: 'zj', - // minioFileName: '小程序工期表-1117_1674961769128.xlsx', - // phone: '950618', - // postalCode: 'test', - // remark: '无备注', - // sampleModel: '型号1', - // sampleName: '样品1', - // sampleNo: '', - // measureResultCode: 'bhg', - // } - dataForm.value = res.data - dataForm.value.measureResult = mesureResultMap[dataForm.value.measureResultCode] - for (const item of menu) { - item.searchFunc() + res.data = { + ABC: 'A', + companyAddress: '北京/北京市', + customerName: '京东集团', + customerNo: 'sygf202211290001', + id: '', + labelBind: '11222', + manufacturer: '北京某厂家', + manufacturerCountry: 'CN', + manufacturingDate: '2023-03', + manufacturingNo: '123121', + mesureCategory: 'jd', + mesureContent: '项目1', + mesurePeriod: '1', + mesureType: 'zj', + minioFileName: '小程序工期表-1117_1674961769128.xlsx', + phone: '950618', + postalCode: 'test', + remark: '无备注', + sampleModel: '型号1', + sampleName: '样品1', + sampleNo: '', + measureResultCode: 'bhg', } + // dataForm.value = res.data + // dataForm.value.measureResult = mesureResultMap[dataForm.value.measureResultCode] + // for (const item of menu) { + // item.searchFunc() + // } }) } @@ -456,12 +454,9 @@ @focus="customerNoFocus" > @@ -568,7 +563,47 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -704,7 +647,34 @@ - + + + + + + + + + + + + + + + + diff --git a/src/views/customer/sample/list/list.vue b/src/views/customer/sample/list/list.vue index 08dc008..4086b48 100644 --- a/src/views/customer/sample/list/list.vue +++ b/src/views/customer/sample/list/list.vue @@ -132,8 +132,8 @@ sampleModel: '', // 型号 customerId: '', // 委托方代码 customerName: '', // 委托方名称 - startTime: '', // 投诉开始时间 - endTime: '', // 投诉结束时间 + startTime: '', // 检定开始时间 + endTime: '', // 检定结束时间 offset: 1, limit: 20, } @@ -226,7 +226,7 @@ printJSON(list.value, properties, '样品列表') } else if (checkoutList.value.length > 0) { - const printList = list.value.filter((item: any) => checkoutList.value.includes(item.id)) + const printList = list.value.filter((item: ISampleList) => checkoutList.value.includes(item.id)) printJSON(printList, properties, '样品列表') } else { diff --git a/src/views/customer/sample/list/sampleDialog.vue b/src/views/customer/sample/list/sampleDialog.vue index ea2d652..a5a371b 100644 --- a/src/views/customer/sample/list/sampleDialog.vue +++ b/src/views/customer/sample/list/sampleDialog.vue @@ -88,37 +88,37 @@ // 是否显示当前页,否则跳转第一页 listQuery.value.offset = 1 } - // getCustomerList(listQuery.value).then((response) => { - // // 模拟数据 - // response.data.rows = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] - // list.value = response.data.rows.map((item: ICustomer) => { - // if (item.companyProvinceName && item.companyCityName) { - // item.briefName = `${item.companyProvinceName}/${item.companyCityName}` - // } - // else { - // item.briefName = item.companyProvinceName || item.companyCityName - // } - // return item - // }) - // total.value = parseInt(response.data.total) - // loadingTable.value = false - // }) + getCustomerList(listQuery.value).then((response) => { + // 模拟数据 + response.data.rows = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] + list.value = response.data.rows.map((item: ICustomer) => { + if (item.companyProvinceName && item.companyCityName) { + item.briefName = `${item.companyProvinceName}/${item.companyCityName}` + } + else { + item.briefName = item.companyProvinceName || item.companyCityName + } + return item + }) + total.value = parseInt(response.data.total) + loadingTable.value = false + }) // 模拟数据 - const response = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, - { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '2集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, - { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '3集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] - list.value = response.map((item: ICustomer) => { - if (item.companyProvinceName && item.companyCityName) { - item.briefName = `${item.companyProvinceName}/${item.companyCityName}` - } - else { - item.briefName = item.companyProvinceName || item.companyCityName - } - return item - }) - total.value = 50 - loadingTable.value = false + // const response = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, + // { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '2集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, + // { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '3集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] + // list.value = response.map((item: ICustomer) => { + // if (item.companyProvinceName && item.companyCityName) { + // item.briefName = `${item.companyProvinceName}/${item.companyCityName}` + // } + // else { + // item.briefName = item.companyProvinceName || item.companyCityName + // } + // return item + // }) + // total.value = 50 + // loadingTable.value = false } // 多选发生改变时 function handleSelectionChange(e: any) { diff --git a/src/views/customer/sample/list/sample_list_interface.ts b/src/views/customer/sample/list/sample_list_interface.ts index f5d0514..26638ce 100644 --- a/src/views/customer/sample/list/sample_list_interface.ts +++ b/src/views/customer/sample/list/sample_list_interface.ts @@ -1,3 +1,5 @@ +import type { TableColumn } from '@/components/NormalTable/table_interface' + export interface ISampleListQuery { sampleNo: string // 样品编号 sampleName: string // 样品名称 @@ -11,7 +13,7 @@ } export interface ISampleList { - id?: string // 样品唯一标识 + id: string // 样品唯一标识 sampleNo: string // 样品编号 sampleName: string // 样品名称 sampleModel: string // 型号 @@ -71,3 +73,11 @@ effectiveDate: string // 证书出具日期 expirationDate: string // 证书有效期 } + +export interface Menu { + name: string + columns: TableColumn[] + pagination: boolean + list: 'measureRecords' | 'certificationRecords' + searchFunc: Function +} diff --git a/src/views/customer/sample/overTime/detail.vue b/src/views/customer/sample/overTime/detail.vue new file mode 100644 index 0000000..3541675 --- /dev/null +++ b/src/views/customer/sample/overTime/detail.vue @@ -0,0 +1,595 @@ + + + + + + + diff --git a/src/api/customer/overtime.ts b/src/api/customer/overtime.ts new file mode 100644 index 0000000..9f349d6 --- /dev/null +++ b/src/api/customer/overtime.ts @@ -0,0 +1,25 @@ +/** + * 到期样品接口 + */ +import request from '../index' +import type { IOvertimeListQuery } from '@/views/customer/sample/overTime/overtime_list_interface' +const prefix = '/meter' + +// 列表查询 +export function getOverTimeList(data: IOvertimeListQuery) { + return request({ + url: `${prefix}/sample/overtime/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出列表 +export function exportOverTimeList(data: Omit) { + return request({ + url: `${prefix}/sample/overtime/listExport`, + method: 'post', + responseType: 'blob', + data, + }) +} diff --git a/src/api/customer/sampleList.ts b/src/api/customer/sampleList.ts index 5ba0a6d..fb50c25 100644 --- a/src/api/customer/sampleList.ts +++ b/src/api/customer/sampleList.ts @@ -58,3 +58,4 @@ data, }) } + diff --git a/src/api/system/process.ts b/src/api/system/process.ts index e459424..c2d4419 100644 --- a/src/api/system/process.ts +++ b/src/api/system/process.ts @@ -112,7 +112,7 @@ beginTime: string endTime: string status: string - // ids: string[] + ids: string[] }) { return request({ url: `${prefix}/listExport`, diff --git a/src/css/workflow.css b/src/css/workflow.css index eee3dec..f922b27 100644 --- a/src/css/workflow.css +++ b/src/css/workflow.css @@ -1395,7 +1395,8 @@ justify-content: center; flex-wrap: wrap; min-width: min-content; - background-color: #f5f8ff; + + /* background-color: #f5f8ff; */ transform-origin: 50% 0 0; } diff --git a/src/router/modules/customer.ts b/src/router/modules/customer.ts index 4d133d0..f5280fa 100644 --- a/src/router/modules/customer.ts +++ b/src/router/modules/customer.ts @@ -71,6 +71,18 @@ auth: '/sample/overtime', }, }, + { + path: 'overtime/:type/:id?', + name: 'OverTimeDetail', + component: () => import('@/views/customer/sample/overTime/detail.vue'), + meta: { + title: '样品详情', + icon: 'ep:key', + sidebar: false, + breadcrumb: true, + activeMenu: '/sample/overtime', + }, + }, ], }, { diff --git a/src/views/customer/sample/list/edit.vue b/src/views/customer/sample/list/edit.vue index 5758df9..153b66e 100644 --- a/src/views/customer/sample/list/edit.vue +++ b/src/views/customer/sample/list/edit.vue @@ -5,7 +5,7 @@ import type { FormInstance, UploadUserFile } from 'element-plus' import { ref } from 'vue' import { Calendar, Search } from '@element-plus/icons-vue' -import type { ISampleEdit, SimpleCertification, SimpleMeasureRecord } from './sample_list_interface' +import type { ISampleEdit, Menu, SimpleCertification, SimpleMeasureRecord } from './sample_list_interface' import sampleDialog from './sampleDialog.vue' import showPhoto from '@/views/system/tool/showPhoto.vue' import { SCHEDULE } from '@/utils/scheduleDict' @@ -14,6 +14,7 @@ import countries from '@/components/AddressSelect/country-code.json' import { UploadFile } from '@/api/measure/file' import type { TableColumn } from '@/components/NormalTable/table_interface' +import type { ICustomer } from '@/views/customer/customerInfo/customer_interface' const textMap: { [key: string]: string } = { edit: '编辑', @@ -177,13 +178,7 @@ const fetchCertifications = function (query = null) { dataList.value.certificationRecords = [] } -interface Menu { - name: string - columns: TableColumn[] - pagination: boolean - list: 'measureRecords' | 'certificationRecords' - searchFunc: Function -} + // 菜单 const menu: Menu[] = [ { @@ -275,12 +270,15 @@ } // 选好委托方 -const confirmCheckout = (val: any) => { - dataForm.value.customerNo = val[0].customerNo - dataForm.value.customerName = val[0].customerName - dataForm.value.phone = val[0].phone - dataForm.value.postalCode = val[0].postalCode - dataForm.value.companyAddress = val[0].briefName +const confirmCheckout = (val: Array) => { + if (val && val.length) { + const getValue = val[0] + dataForm.value.customerNo = getValue.customerNo + dataForm.value.customerName = getValue.customerName + dataForm.value.phone = getValue.phone + dataForm.value.postalCode = getValue.postalCode + dataForm.value.companyAddress = getValue.briefName + } } // 控制选择委托方对话框显隐 @@ -346,35 +344,35 @@ const getInfo = () => { getSapmleDetail({ id: infoId.value }).then((res) => { - // res.data = { - // ABC: 'A', - // companyAddress: '北京/北京市', - // customerName: '京东集团', - // customerNo: 'sygf202211290001', - // id: '', - // labelBind: '11222', - // manufacturer: '北京某厂家', - // manufacturerCountry: 'CN', - // manufacturingDate: '2023-03', - // manufacturingNo: '123121', - // mesureCategory: 'jd', - // mesureContent: '项目1', - // mesurePeriod: '1', - // mesureType: 'zj', - // minioFileName: '小程序工期表-1117_1674961769128.xlsx', - // phone: '950618', - // postalCode: 'test', - // remark: '无备注', - // sampleModel: '型号1', - // sampleName: '样品1', - // sampleNo: '', - // measureResultCode: 'bhg', - // } - dataForm.value = res.data - dataForm.value.measureResult = mesureResultMap[dataForm.value.measureResultCode] - for (const item of menu) { - item.searchFunc() + res.data = { + ABC: 'A', + companyAddress: '北京/北京市', + customerName: '京东集团', + customerNo: 'sygf202211290001', + id: '', + labelBind: '11222', + manufacturer: '北京某厂家', + manufacturerCountry: 'CN', + manufacturingDate: '2023-03', + manufacturingNo: '123121', + mesureCategory: 'jd', + mesureContent: '项目1', + mesurePeriod: '1', + mesureType: 'zj', + minioFileName: '小程序工期表-1117_1674961769128.xlsx', + phone: '950618', + postalCode: 'test', + remark: '无备注', + sampleModel: '型号1', + sampleName: '样品1', + sampleNo: '', + measureResultCode: 'bhg', } + // dataForm.value = res.data + // dataForm.value.measureResult = mesureResultMap[dataForm.value.measureResultCode] + // for (const item of menu) { + // item.searchFunc() + // } }) } @@ -456,12 +454,9 @@ @focus="customerNoFocus" > @@ -568,7 +563,47 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -704,7 +647,34 @@ - + + + + + + + + + + + + + + + + diff --git a/src/views/customer/sample/list/list.vue b/src/views/customer/sample/list/list.vue index 08dc008..4086b48 100644 --- a/src/views/customer/sample/list/list.vue +++ b/src/views/customer/sample/list/list.vue @@ -132,8 +132,8 @@ sampleModel: '', // 型号 customerId: '', // 委托方代码 customerName: '', // 委托方名称 - startTime: '', // 投诉开始时间 - endTime: '', // 投诉结束时间 + startTime: '', // 检定开始时间 + endTime: '', // 检定结束时间 offset: 1, limit: 20, } @@ -226,7 +226,7 @@ printJSON(list.value, properties, '样品列表') } else if (checkoutList.value.length > 0) { - const printList = list.value.filter((item: any) => checkoutList.value.includes(item.id)) + const printList = list.value.filter((item: ISampleList) => checkoutList.value.includes(item.id)) printJSON(printList, properties, '样品列表') } else { diff --git a/src/views/customer/sample/list/sampleDialog.vue b/src/views/customer/sample/list/sampleDialog.vue index ea2d652..a5a371b 100644 --- a/src/views/customer/sample/list/sampleDialog.vue +++ b/src/views/customer/sample/list/sampleDialog.vue @@ -88,37 +88,37 @@ // 是否显示当前页,否则跳转第一页 listQuery.value.offset = 1 } - // getCustomerList(listQuery.value).then((response) => { - // // 模拟数据 - // response.data.rows = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] - // list.value = response.data.rows.map((item: ICustomer) => { - // if (item.companyProvinceName && item.companyCityName) { - // item.briefName = `${item.companyProvinceName}/${item.companyCityName}` - // } - // else { - // item.briefName = item.companyProvinceName || item.companyCityName - // } - // return item - // }) - // total.value = parseInt(response.data.total) - // loadingTable.value = false - // }) + getCustomerList(listQuery.value).then((response) => { + // 模拟数据 + response.data.rows = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] + list.value = response.data.rows.map((item: ICustomer) => { + if (item.companyProvinceName && item.companyCityName) { + item.briefName = `${item.companyProvinceName}/${item.companyCityName}` + } + else { + item.briefName = item.companyProvinceName || item.companyCityName + } + return item + }) + total.value = parseInt(response.data.total) + loadingTable.value = false + }) // 模拟数据 - const response = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, - { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '2集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, - { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '3集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] - list.value = response.map((item: ICustomer) => { - if (item.companyProvinceName && item.companyCityName) { - item.briefName = `${item.companyProvinceName}/${item.companyCityName}` - } - else { - item.briefName = item.companyProvinceName || item.companyCityName - } - return item - }) - total.value = 50 - loadingTable.value = false + // const response = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, + // { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '2集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, + // { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '3集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] + // list.value = response.map((item: ICustomer) => { + // if (item.companyProvinceName && item.companyCityName) { + // item.briefName = `${item.companyProvinceName}/${item.companyCityName}` + // } + // else { + // item.briefName = item.companyProvinceName || item.companyCityName + // } + // return item + // }) + // total.value = 50 + // loadingTable.value = false } // 多选发生改变时 function handleSelectionChange(e: any) { diff --git a/src/views/customer/sample/list/sample_list_interface.ts b/src/views/customer/sample/list/sample_list_interface.ts index f5d0514..26638ce 100644 --- a/src/views/customer/sample/list/sample_list_interface.ts +++ b/src/views/customer/sample/list/sample_list_interface.ts @@ -1,3 +1,5 @@ +import type { TableColumn } from '@/components/NormalTable/table_interface' + export interface ISampleListQuery { sampleNo: string // 样品编号 sampleName: string // 样品名称 @@ -11,7 +13,7 @@ } export interface ISampleList { - id?: string // 样品唯一标识 + id: string // 样品唯一标识 sampleNo: string // 样品编号 sampleName: string // 样品名称 sampleModel: string // 型号 @@ -71,3 +73,11 @@ effectiveDate: string // 证书出具日期 expirationDate: string // 证书有效期 } + +export interface Menu { + name: string + columns: TableColumn[] + pagination: boolean + list: 'measureRecords' | 'certificationRecords' + searchFunc: Function +} diff --git a/src/views/customer/sample/overTime/detail.vue b/src/views/customer/sample/overTime/detail.vue new file mode 100644 index 0000000..3541675 --- /dev/null +++ b/src/views/customer/sample/overTime/detail.vue @@ -0,0 +1,595 @@ + + + + + + + diff --git a/src/views/customer/sample/overTime/list.vue b/src/views/customer/sample/overTime/list.vue index 6578d12..6d3699f 100644 --- a/src/views/customer/sample/overTime/list.vue +++ b/src/views/customer/sample/overTime/list.vue @@ -1,3 +1,288 @@ + + + + + diff --git a/src/api/customer/overtime.ts b/src/api/customer/overtime.ts new file mode 100644 index 0000000..9f349d6 --- /dev/null +++ b/src/api/customer/overtime.ts @@ -0,0 +1,25 @@ +/** + * 到期样品接口 + */ +import request from '../index' +import type { IOvertimeListQuery } from '@/views/customer/sample/overTime/overtime_list_interface' +const prefix = '/meter' + +// 列表查询 +export function getOverTimeList(data: IOvertimeListQuery) { + return request({ + url: `${prefix}/sample/overtime/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出列表 +export function exportOverTimeList(data: Omit) { + return request({ + url: `${prefix}/sample/overtime/listExport`, + method: 'post', + responseType: 'blob', + data, + }) +} diff --git a/src/api/customer/sampleList.ts b/src/api/customer/sampleList.ts index 5ba0a6d..fb50c25 100644 --- a/src/api/customer/sampleList.ts +++ b/src/api/customer/sampleList.ts @@ -58,3 +58,4 @@ data, }) } + diff --git a/src/api/system/process.ts b/src/api/system/process.ts index e459424..c2d4419 100644 --- a/src/api/system/process.ts +++ b/src/api/system/process.ts @@ -112,7 +112,7 @@ beginTime: string endTime: string status: string - // ids: string[] + ids: string[] }) { return request({ url: `${prefix}/listExport`, diff --git a/src/css/workflow.css b/src/css/workflow.css index eee3dec..f922b27 100644 --- a/src/css/workflow.css +++ b/src/css/workflow.css @@ -1395,7 +1395,8 @@ justify-content: center; flex-wrap: wrap; min-width: min-content; - background-color: #f5f8ff; + + /* background-color: #f5f8ff; */ transform-origin: 50% 0 0; } diff --git a/src/router/modules/customer.ts b/src/router/modules/customer.ts index 4d133d0..f5280fa 100644 --- a/src/router/modules/customer.ts +++ b/src/router/modules/customer.ts @@ -71,6 +71,18 @@ auth: '/sample/overtime', }, }, + { + path: 'overtime/:type/:id?', + name: 'OverTimeDetail', + component: () => import('@/views/customer/sample/overTime/detail.vue'), + meta: { + title: '样品详情', + icon: 'ep:key', + sidebar: false, + breadcrumb: true, + activeMenu: '/sample/overtime', + }, + }, ], }, { diff --git a/src/views/customer/sample/list/edit.vue b/src/views/customer/sample/list/edit.vue index 5758df9..153b66e 100644 --- a/src/views/customer/sample/list/edit.vue +++ b/src/views/customer/sample/list/edit.vue @@ -5,7 +5,7 @@ import type { FormInstance, UploadUserFile } from 'element-plus' import { ref } from 'vue' import { Calendar, Search } from '@element-plus/icons-vue' -import type { ISampleEdit, SimpleCertification, SimpleMeasureRecord } from './sample_list_interface' +import type { ISampleEdit, Menu, SimpleCertification, SimpleMeasureRecord } from './sample_list_interface' import sampleDialog from './sampleDialog.vue' import showPhoto from '@/views/system/tool/showPhoto.vue' import { SCHEDULE } from '@/utils/scheduleDict' @@ -14,6 +14,7 @@ import countries from '@/components/AddressSelect/country-code.json' import { UploadFile } from '@/api/measure/file' import type { TableColumn } from '@/components/NormalTable/table_interface' +import type { ICustomer } from '@/views/customer/customerInfo/customer_interface' const textMap: { [key: string]: string } = { edit: '编辑', @@ -177,13 +178,7 @@ const fetchCertifications = function (query = null) { dataList.value.certificationRecords = [] } -interface Menu { - name: string - columns: TableColumn[] - pagination: boolean - list: 'measureRecords' | 'certificationRecords' - searchFunc: Function -} + // 菜单 const menu: Menu[] = [ { @@ -275,12 +270,15 @@ } // 选好委托方 -const confirmCheckout = (val: any) => { - dataForm.value.customerNo = val[0].customerNo - dataForm.value.customerName = val[0].customerName - dataForm.value.phone = val[0].phone - dataForm.value.postalCode = val[0].postalCode - dataForm.value.companyAddress = val[0].briefName +const confirmCheckout = (val: Array) => { + if (val && val.length) { + const getValue = val[0] + dataForm.value.customerNo = getValue.customerNo + dataForm.value.customerName = getValue.customerName + dataForm.value.phone = getValue.phone + dataForm.value.postalCode = getValue.postalCode + dataForm.value.companyAddress = getValue.briefName + } } // 控制选择委托方对话框显隐 @@ -346,35 +344,35 @@ const getInfo = () => { getSapmleDetail({ id: infoId.value }).then((res) => { - // res.data = { - // ABC: 'A', - // companyAddress: '北京/北京市', - // customerName: '京东集团', - // customerNo: 'sygf202211290001', - // id: '', - // labelBind: '11222', - // manufacturer: '北京某厂家', - // manufacturerCountry: 'CN', - // manufacturingDate: '2023-03', - // manufacturingNo: '123121', - // mesureCategory: 'jd', - // mesureContent: '项目1', - // mesurePeriod: '1', - // mesureType: 'zj', - // minioFileName: '小程序工期表-1117_1674961769128.xlsx', - // phone: '950618', - // postalCode: 'test', - // remark: '无备注', - // sampleModel: '型号1', - // sampleName: '样品1', - // sampleNo: '', - // measureResultCode: 'bhg', - // } - dataForm.value = res.data - dataForm.value.measureResult = mesureResultMap[dataForm.value.measureResultCode] - for (const item of menu) { - item.searchFunc() + res.data = { + ABC: 'A', + companyAddress: '北京/北京市', + customerName: '京东集团', + customerNo: 'sygf202211290001', + id: '', + labelBind: '11222', + manufacturer: '北京某厂家', + manufacturerCountry: 'CN', + manufacturingDate: '2023-03', + manufacturingNo: '123121', + mesureCategory: 'jd', + mesureContent: '项目1', + mesurePeriod: '1', + mesureType: 'zj', + minioFileName: '小程序工期表-1117_1674961769128.xlsx', + phone: '950618', + postalCode: 'test', + remark: '无备注', + sampleModel: '型号1', + sampleName: '样品1', + sampleNo: '', + measureResultCode: 'bhg', } + // dataForm.value = res.data + // dataForm.value.measureResult = mesureResultMap[dataForm.value.measureResultCode] + // for (const item of menu) { + // item.searchFunc() + // } }) } @@ -456,12 +454,9 @@ @focus="customerNoFocus" > @@ -568,7 +563,47 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -704,7 +647,34 @@ - + + + + + + + + + + + + + + + + diff --git a/src/views/customer/sample/list/list.vue b/src/views/customer/sample/list/list.vue index 08dc008..4086b48 100644 --- a/src/views/customer/sample/list/list.vue +++ b/src/views/customer/sample/list/list.vue @@ -132,8 +132,8 @@ sampleModel: '', // 型号 customerId: '', // 委托方代码 customerName: '', // 委托方名称 - startTime: '', // 投诉开始时间 - endTime: '', // 投诉结束时间 + startTime: '', // 检定开始时间 + endTime: '', // 检定结束时间 offset: 1, limit: 20, } @@ -226,7 +226,7 @@ printJSON(list.value, properties, '样品列表') } else if (checkoutList.value.length > 0) { - const printList = list.value.filter((item: any) => checkoutList.value.includes(item.id)) + const printList = list.value.filter((item: ISampleList) => checkoutList.value.includes(item.id)) printJSON(printList, properties, '样品列表') } else { diff --git a/src/views/customer/sample/list/sampleDialog.vue b/src/views/customer/sample/list/sampleDialog.vue index ea2d652..a5a371b 100644 --- a/src/views/customer/sample/list/sampleDialog.vue +++ b/src/views/customer/sample/list/sampleDialog.vue @@ -88,37 +88,37 @@ // 是否显示当前页,否则跳转第一页 listQuery.value.offset = 1 } - // getCustomerList(listQuery.value).then((response) => { - // // 模拟数据 - // response.data.rows = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] - // list.value = response.data.rows.map((item: ICustomer) => { - // if (item.companyProvinceName && item.companyCityName) { - // item.briefName = `${item.companyProvinceName}/${item.companyCityName}` - // } - // else { - // item.briefName = item.companyProvinceName || item.companyCityName - // } - // return item - // }) - // total.value = parseInt(response.data.total) - // loadingTable.value = false - // }) + getCustomerList(listQuery.value).then((response) => { + // 模拟数据 + response.data.rows = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] + list.value = response.data.rows.map((item: ICustomer) => { + if (item.companyProvinceName && item.companyCityName) { + item.briefName = `${item.companyProvinceName}/${item.companyCityName}` + } + else { + item.briefName = item.companyProvinceName || item.companyCityName + } + return item + }) + total.value = parseInt(response.data.total) + loadingTable.value = false + }) // 模拟数据 - const response = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, - { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '2集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, - { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '3集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] - list.value = response.map((item: ICustomer) => { - if (item.companyProvinceName && item.companyCityName) { - item.briefName = `${item.companyProvinceName}/${item.companyCityName}` - } - else { - item.briefName = item.companyProvinceName || item.companyCityName - } - return item - }) - total.value = 50 - loadingTable.value = false + // const response = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, + // { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '2集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, + // { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '3集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] + // list.value = response.map((item: ICustomer) => { + // if (item.companyProvinceName && item.companyCityName) { + // item.briefName = `${item.companyProvinceName}/${item.companyCityName}` + // } + // else { + // item.briefName = item.companyProvinceName || item.companyCityName + // } + // return item + // }) + // total.value = 50 + // loadingTable.value = false } // 多选发生改变时 function handleSelectionChange(e: any) { diff --git a/src/views/customer/sample/list/sample_list_interface.ts b/src/views/customer/sample/list/sample_list_interface.ts index f5d0514..26638ce 100644 --- a/src/views/customer/sample/list/sample_list_interface.ts +++ b/src/views/customer/sample/list/sample_list_interface.ts @@ -1,3 +1,5 @@ +import type { TableColumn } from '@/components/NormalTable/table_interface' + export interface ISampleListQuery { sampleNo: string // 样品编号 sampleName: string // 样品名称 @@ -11,7 +13,7 @@ } export interface ISampleList { - id?: string // 样品唯一标识 + id: string // 样品唯一标识 sampleNo: string // 样品编号 sampleName: string // 样品名称 sampleModel: string // 型号 @@ -71,3 +73,11 @@ effectiveDate: string // 证书出具日期 expirationDate: string // 证书有效期 } + +export interface Menu { + name: string + columns: TableColumn[] + pagination: boolean + list: 'measureRecords' | 'certificationRecords' + searchFunc: Function +} diff --git a/src/views/customer/sample/overTime/detail.vue b/src/views/customer/sample/overTime/detail.vue new file mode 100644 index 0000000..3541675 --- /dev/null +++ b/src/views/customer/sample/overTime/detail.vue @@ -0,0 +1,595 @@ + + + + + + + diff --git a/src/views/customer/sample/overTime/list.vue b/src/views/customer/sample/overTime/list.vue index 6578d12..6d3699f 100644 --- a/src/views/customer/sample/overTime/list.vue +++ b/src/views/customer/sample/overTime/list.vue @@ -1,3 +1,288 @@ + + + + + diff --git a/src/views/customer/sample/overTime/overtime_list_interface.ts b/src/views/customer/sample/overTime/overtime_list_interface.ts new file mode 100644 index 0000000..40b8e64 --- /dev/null +++ b/src/views/customer/sample/overTime/overtime_list_interface.ts @@ -0,0 +1,75 @@ +export interface IOvertimeListQuery { + sampleNo: string // 样品编号 + sampleName: string // 样品名称 + sampleModel: string // 型号 + customerId: string // 委托方代码 + customerName: string // 委托方名称 + startTime: string // 检定开始时间 + endTime: string // 检定结束时间 + offset: number + limit: number +} + +export interface IOvertimeList { + id?: string // 样品唯一标识 + sampleNo: string // 样品编号 + sampleName: string // 样品名称 + sampleModel: string // 型号 + evaluationName: string // 出厂编号 + customerId: string // 委托方代码 + customerName: string // 委托方名称 + mesurePeriod: string // 检定周期 + effectiveDate: string // 上次检定时间 + certificationStatus: string // 证书状况 +} + +export interface ISampleDetail { + id?: string + sampleNo: string // 样品编号 + sampleName: string // 样品名称 + sampleModel: string // 样品型号 + manufacturingNo: string // 出厂编号 + customerNo: string // 委托方代码 + customerName: string // 委托方名称 + phone: string // 委托方电话 + postalCode: string // 委托方邮编 + companyAddress: string // 委托方地址 + mesureCategory: string // 检校类别 + manufacturer: string // 生产厂家 + manufacturerCountry: string // 厂家国别 + manufacturingDate: string // 出厂年月 + ABC: string // ABC + deliverer?: string // 送检人 + delivererTel?: string // 送检人联系方式 + planDeliverTime?: string // 预计送达时间 + requireOverTime?: string // 要求检完时间 + mesureContent: string // 检定项目 + mesurePeriod: string // 检定周期 + remark: string // 备注 + minioFileName: string // 说明书 + labelBind: string // 标签绑定 + mesureType: string // 检定方式 + measureDate?: string // 检定日期 + effectiveDate?: string // 有效日期 + measureResultCode?: string // 检定结果代码 + measureResult?: string // 检定结果 +} + +// 检定记录 +export interface SimpleMeasureRecord { + orderCode: string // 委托单编号 + orderTime: string // 委托单日期 + customerCode: string // 委托人代码 + customerName: string // 委托人名称 + deliverer: string // 送检人 + deliverTime: string // 送检日期 +} + +// 检定证书 +export interface SimpleCertification { + certificationCode: string // 证书编号 + certificationName: string // 证书形成 + certificationType: string // 证书类型 + effectiveDate: string // 证书出具日期 + expirationDate: string // 证书有效期 +} diff --git a/src/api/customer/overtime.ts b/src/api/customer/overtime.ts new file mode 100644 index 0000000..9f349d6 --- /dev/null +++ b/src/api/customer/overtime.ts @@ -0,0 +1,25 @@ +/** + * 到期样品接口 + */ +import request from '../index' +import type { IOvertimeListQuery } from '@/views/customer/sample/overTime/overtime_list_interface' +const prefix = '/meter' + +// 列表查询 +export function getOverTimeList(data: IOvertimeListQuery) { + return request({ + url: `${prefix}/sample/overtime/listPage?offset=${data.offset}&limit=${data.limit}`, + method: 'post', + data, + }) +} + +// 导出列表 +export function exportOverTimeList(data: Omit) { + return request({ + url: `${prefix}/sample/overtime/listExport`, + method: 'post', + responseType: 'blob', + data, + }) +} diff --git a/src/api/customer/sampleList.ts b/src/api/customer/sampleList.ts index 5ba0a6d..fb50c25 100644 --- a/src/api/customer/sampleList.ts +++ b/src/api/customer/sampleList.ts @@ -58,3 +58,4 @@ data, }) } + diff --git a/src/api/system/process.ts b/src/api/system/process.ts index e459424..c2d4419 100644 --- a/src/api/system/process.ts +++ b/src/api/system/process.ts @@ -112,7 +112,7 @@ beginTime: string endTime: string status: string - // ids: string[] + ids: string[] }) { return request({ url: `${prefix}/listExport`, diff --git a/src/css/workflow.css b/src/css/workflow.css index eee3dec..f922b27 100644 --- a/src/css/workflow.css +++ b/src/css/workflow.css @@ -1395,7 +1395,8 @@ justify-content: center; flex-wrap: wrap; min-width: min-content; - background-color: #f5f8ff; + + /* background-color: #f5f8ff; */ transform-origin: 50% 0 0; } diff --git a/src/router/modules/customer.ts b/src/router/modules/customer.ts index 4d133d0..f5280fa 100644 --- a/src/router/modules/customer.ts +++ b/src/router/modules/customer.ts @@ -71,6 +71,18 @@ auth: '/sample/overtime', }, }, + { + path: 'overtime/:type/:id?', + name: 'OverTimeDetail', + component: () => import('@/views/customer/sample/overTime/detail.vue'), + meta: { + title: '样品详情', + icon: 'ep:key', + sidebar: false, + breadcrumb: true, + activeMenu: '/sample/overtime', + }, + }, ], }, { diff --git a/src/views/customer/sample/list/edit.vue b/src/views/customer/sample/list/edit.vue index 5758df9..153b66e 100644 --- a/src/views/customer/sample/list/edit.vue +++ b/src/views/customer/sample/list/edit.vue @@ -5,7 +5,7 @@ import type { FormInstance, UploadUserFile } from 'element-plus' import { ref } from 'vue' import { Calendar, Search } from '@element-plus/icons-vue' -import type { ISampleEdit, SimpleCertification, SimpleMeasureRecord } from './sample_list_interface' +import type { ISampleEdit, Menu, SimpleCertification, SimpleMeasureRecord } from './sample_list_interface' import sampleDialog from './sampleDialog.vue' import showPhoto from '@/views/system/tool/showPhoto.vue' import { SCHEDULE } from '@/utils/scheduleDict' @@ -14,6 +14,7 @@ import countries from '@/components/AddressSelect/country-code.json' import { UploadFile } from '@/api/measure/file' import type { TableColumn } from '@/components/NormalTable/table_interface' +import type { ICustomer } from '@/views/customer/customerInfo/customer_interface' const textMap: { [key: string]: string } = { edit: '编辑', @@ -177,13 +178,7 @@ const fetchCertifications = function (query = null) { dataList.value.certificationRecords = [] } -interface Menu { - name: string - columns: TableColumn[] - pagination: boolean - list: 'measureRecords' | 'certificationRecords' - searchFunc: Function -} + // 菜单 const menu: Menu[] = [ { @@ -275,12 +270,15 @@ } // 选好委托方 -const confirmCheckout = (val: any) => { - dataForm.value.customerNo = val[0].customerNo - dataForm.value.customerName = val[0].customerName - dataForm.value.phone = val[0].phone - dataForm.value.postalCode = val[0].postalCode - dataForm.value.companyAddress = val[0].briefName +const confirmCheckout = (val: Array) => { + if (val && val.length) { + const getValue = val[0] + dataForm.value.customerNo = getValue.customerNo + dataForm.value.customerName = getValue.customerName + dataForm.value.phone = getValue.phone + dataForm.value.postalCode = getValue.postalCode + dataForm.value.companyAddress = getValue.briefName + } } // 控制选择委托方对话框显隐 @@ -346,35 +344,35 @@ const getInfo = () => { getSapmleDetail({ id: infoId.value }).then((res) => { - // res.data = { - // ABC: 'A', - // companyAddress: '北京/北京市', - // customerName: '京东集团', - // customerNo: 'sygf202211290001', - // id: '', - // labelBind: '11222', - // manufacturer: '北京某厂家', - // manufacturerCountry: 'CN', - // manufacturingDate: '2023-03', - // manufacturingNo: '123121', - // mesureCategory: 'jd', - // mesureContent: '项目1', - // mesurePeriod: '1', - // mesureType: 'zj', - // minioFileName: '小程序工期表-1117_1674961769128.xlsx', - // phone: '950618', - // postalCode: 'test', - // remark: '无备注', - // sampleModel: '型号1', - // sampleName: '样品1', - // sampleNo: '', - // measureResultCode: 'bhg', - // } - dataForm.value = res.data - dataForm.value.measureResult = mesureResultMap[dataForm.value.measureResultCode] - for (const item of menu) { - item.searchFunc() + res.data = { + ABC: 'A', + companyAddress: '北京/北京市', + customerName: '京东集团', + customerNo: 'sygf202211290001', + id: '', + labelBind: '11222', + manufacturer: '北京某厂家', + manufacturerCountry: 'CN', + manufacturingDate: '2023-03', + manufacturingNo: '123121', + mesureCategory: 'jd', + mesureContent: '项目1', + mesurePeriod: '1', + mesureType: 'zj', + minioFileName: '小程序工期表-1117_1674961769128.xlsx', + phone: '950618', + postalCode: 'test', + remark: '无备注', + sampleModel: '型号1', + sampleName: '样品1', + sampleNo: '', + measureResultCode: 'bhg', } + // dataForm.value = res.data + // dataForm.value.measureResult = mesureResultMap[dataForm.value.measureResultCode] + // for (const item of menu) { + // item.searchFunc() + // } }) } @@ -456,12 +454,9 @@ @focus="customerNoFocus" > @@ -568,7 +563,47 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -704,7 +647,34 @@ - + + + + + + + + + + + + + + + + diff --git a/src/views/customer/sample/list/list.vue b/src/views/customer/sample/list/list.vue index 08dc008..4086b48 100644 --- a/src/views/customer/sample/list/list.vue +++ b/src/views/customer/sample/list/list.vue @@ -132,8 +132,8 @@ sampleModel: '', // 型号 customerId: '', // 委托方代码 customerName: '', // 委托方名称 - startTime: '', // 投诉开始时间 - endTime: '', // 投诉结束时间 + startTime: '', // 检定开始时间 + endTime: '', // 检定结束时间 offset: 1, limit: 20, } @@ -226,7 +226,7 @@ printJSON(list.value, properties, '样品列表') } else if (checkoutList.value.length > 0) { - const printList = list.value.filter((item: any) => checkoutList.value.includes(item.id)) + const printList = list.value.filter((item: ISampleList) => checkoutList.value.includes(item.id)) printJSON(printList, properties, '样品列表') } else { diff --git a/src/views/customer/sample/list/sampleDialog.vue b/src/views/customer/sample/list/sampleDialog.vue index ea2d652..a5a371b 100644 --- a/src/views/customer/sample/list/sampleDialog.vue +++ b/src/views/customer/sample/list/sampleDialog.vue @@ -88,37 +88,37 @@ // 是否显示当前页,否则跳转第一页 listQuery.value.offset = 1 } - // getCustomerList(listQuery.value).then((response) => { - // // 模拟数据 - // response.data.rows = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] - // list.value = response.data.rows.map((item: ICustomer) => { - // if (item.companyProvinceName && item.companyCityName) { - // item.briefName = `${item.companyProvinceName}/${item.companyCityName}` - // } - // else { - // item.briefName = item.companyProvinceName || item.companyCityName - // } - // return item - // }) - // total.value = parseInt(response.data.total) - // loadingTable.value = false - // }) + getCustomerList(listQuery.value).then((response) => { + // 模拟数据 + response.data.rows = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] + list.value = response.data.rows.map((item: ICustomer) => { + if (item.companyProvinceName && item.companyCityName) { + item.briefName = `${item.companyProvinceName}/${item.companyCityName}` + } + else { + item.briefName = item.companyProvinceName || item.companyCityName + } + return item + }) + total.value = parseInt(response.data.total) + loadingTable.value = false + }) // 模拟数据 - const response = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, - { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '2集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, - { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '3集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] - list.value = response.map((item: ICustomer) => { - if (item.companyProvinceName && item.companyCityName) { - item.briefName = `${item.companyProvinceName}/${item.companyCityName}` - } - else { - item.briefName = item.companyProvinceName || item.companyCityName - } - return item - }) - total.value = 50 - loadingTable.value = false + // const response = [{ bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '京东集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, + // { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '2集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }, + // { bankAccount: '银行账户', bankAccountNumber: '银行账号', bankName: '工商银行', briefName: '京东', businessContent: '电商', businessScope: 'test1', grade: '1', gradeName: 'A', companySize: '1', companySizeName: '小微企业', businessSize: '1', businessSizeName: '0-10万', evaluation: '1', evaluationName: '优质', companyAddress: '五棵松', companyAreaName: '海淀区', companyCityName: '北京市', companyCountryName: '中国', companyProvinceName: '北京', companyArea: '110007', companyCity: '110000', companyCountry: 'CN', companyProvince: '100000', createTime: '2022-11-29 21:14:50', director: '刘强东', fax: 'test1', id: '1597579843411234817', invoiceAddress: '五棵松', invoiceAreaName: '海淀区', invoiceCityName: '北京市', invoiceCountryName: '中国', invoiceProvinceName: '北京', invoiceyArea: '110007', invoiceCity: '110000', invoiceCountry: 'CN', invoiceProvince: '100000', mailbox: 'test1', minioFileName: 'test', mobile: 'test', phone: '950618', postalCode: 'test', remark: 'test', customerName: '3集团', customerNo: 'sygf202211290001', taxNumber: 'test', updateTime: '2023-01-10 09:56:57', website: 'test' }] + // list.value = response.map((item: ICustomer) => { + // if (item.companyProvinceName && item.companyCityName) { + // item.briefName = `${item.companyProvinceName}/${item.companyCityName}` + // } + // else { + // item.briefName = item.companyProvinceName || item.companyCityName + // } + // return item + // }) + // total.value = 50 + // loadingTable.value = false } // 多选发生改变时 function handleSelectionChange(e: any) { diff --git a/src/views/customer/sample/list/sample_list_interface.ts b/src/views/customer/sample/list/sample_list_interface.ts index f5d0514..26638ce 100644 --- a/src/views/customer/sample/list/sample_list_interface.ts +++ b/src/views/customer/sample/list/sample_list_interface.ts @@ -1,3 +1,5 @@ +import type { TableColumn } from '@/components/NormalTable/table_interface' + export interface ISampleListQuery { sampleNo: string // 样品编号 sampleName: string // 样品名称 @@ -11,7 +13,7 @@ } export interface ISampleList { - id?: string // 样品唯一标识 + id: string // 样品唯一标识 sampleNo: string // 样品编号 sampleName: string // 样品名称 sampleModel: string // 型号 @@ -71,3 +73,11 @@ effectiveDate: string // 证书出具日期 expirationDate: string // 证书有效期 } + +export interface Menu { + name: string + columns: TableColumn[] + pagination: boolean + list: 'measureRecords' | 'certificationRecords' + searchFunc: Function +} diff --git a/src/views/customer/sample/overTime/detail.vue b/src/views/customer/sample/overTime/detail.vue new file mode 100644 index 0000000..3541675 --- /dev/null +++ b/src/views/customer/sample/overTime/detail.vue @@ -0,0 +1,595 @@ + + + + + + + diff --git a/src/views/customer/sample/overTime/list.vue b/src/views/customer/sample/overTime/list.vue index 6578d12..6d3699f 100644 --- a/src/views/customer/sample/overTime/list.vue +++ b/src/views/customer/sample/overTime/list.vue @@ -1,3 +1,288 @@ + + + + + diff --git a/src/views/customer/sample/overTime/overtime_list_interface.ts b/src/views/customer/sample/overTime/overtime_list_interface.ts new file mode 100644 index 0000000..40b8e64 --- /dev/null +++ b/src/views/customer/sample/overTime/overtime_list_interface.ts @@ -0,0 +1,75 @@ +export interface IOvertimeListQuery { + sampleNo: string // 样品编号 + sampleName: string // 样品名称 + sampleModel: string // 型号 + customerId: string // 委托方代码 + customerName: string // 委托方名称 + startTime: string // 检定开始时间 + endTime: string // 检定结束时间 + offset: number + limit: number +} + +export interface IOvertimeList { + id?: string // 样品唯一标识 + sampleNo: string // 样品编号 + sampleName: string // 样品名称 + sampleModel: string // 型号 + evaluationName: string // 出厂编号 + customerId: string // 委托方代码 + customerName: string // 委托方名称 + mesurePeriod: string // 检定周期 + effectiveDate: string // 上次检定时间 + certificationStatus: string // 证书状况 +} + +export interface ISampleDetail { + id?: string + sampleNo: string // 样品编号 + sampleName: string // 样品名称 + sampleModel: string // 样品型号 + manufacturingNo: string // 出厂编号 + customerNo: string // 委托方代码 + customerName: string // 委托方名称 + phone: string // 委托方电话 + postalCode: string // 委托方邮编 + companyAddress: string // 委托方地址 + mesureCategory: string // 检校类别 + manufacturer: string // 生产厂家 + manufacturerCountry: string // 厂家国别 + manufacturingDate: string // 出厂年月 + ABC: string // ABC + deliverer?: string // 送检人 + delivererTel?: string // 送检人联系方式 + planDeliverTime?: string // 预计送达时间 + requireOverTime?: string // 要求检完时间 + mesureContent: string // 检定项目 + mesurePeriod: string // 检定周期 + remark: string // 备注 + minioFileName: string // 说明书 + labelBind: string // 标签绑定 + mesureType: string // 检定方式 + measureDate?: string // 检定日期 + effectiveDate?: string // 有效日期 + measureResultCode?: string // 检定结果代码 + measureResult?: string // 检定结果 +} + +// 检定记录 +export interface SimpleMeasureRecord { + orderCode: string // 委托单编号 + orderTime: string // 委托单日期 + customerCode: string // 委托人代码 + customerName: string // 委托人名称 + deliverer: string // 送检人 + deliverTime: string // 送检日期 +} + +// 检定证书 +export interface SimpleCertification { + certificationCode: string // 证书编号 + certificationName: string // 证书形成 + certificationType: string // 证书类型 + effectiveDate: string // 证书出具日期 + expirationDate: string // 证书有效期 +} diff --git a/src/views/device/receive/applyList.vue b/src/views/device/receive/applyList.vue index 4674763..975a887 100644 --- a/src/views/device/receive/applyList.vue +++ b/src/views/device/receive/applyList.vue @@ -1,12 +1,15 @@