diff --git a/src/views/services/appraisal/appraisal.api.ts b/src/views/services/appraisal/appraisal.api.ts index 3045350..3b5b206 100644 --- a/src/views/services/appraisal/appraisal.api.ts +++ b/src/views/services/appraisal/appraisal.api.ts @@ -5,6 +5,7 @@ const { createConfirm } = useMessage(); enum Api { list = '/service/appraisal/list', + approval='/service/appraisal/approval', save='/service/appraisal/add', edit='/service/appraisal/edit', deleteOne = '/service/appraisal/delete', @@ -38,6 +39,14 @@ export const queryAppraisalSubByMainId = (id) => defHttp.get({url: Api.subList, export const list = (params) => defHttp.get({url: Api.list, params}); +/** + * 审核 + * @param params + */ +export const approval = (params,) => { + return defHttp.post({url: Api.approval, params}); +} + /** * 删除单个 */ diff --git a/src/views/services/appraisal/appraisal.data.ts b/src/views/services/appraisal/appraisal.data.ts index 4a43111..a4c1c3e 100644 --- a/src/views/services/appraisal/appraisal.data.ts +++ b/src/views/services/appraisal/appraisal.data.ts @@ -159,8 +159,67 @@ export const columns: BasicColumn[] = [ }, ]; -//子表表格配置 -export const subColumns: JVxeColumn[] = [ +//子表列表数据 +export const subColumns: BasicColumn[] = [ + { + title: '单号', + align:"center", + dataIndex: 'orderNo' + }, + { + title: '手动拍照', + align:"center", + dataIndex: 'manuallyPicPath' + }, + { + title: '手动录制', + align:"center", + dataIndex: 'manuallyMp4Path' + }, + { + title: '摄像头录制', + align:"center", + dataIndex: 'tplinkPath' + }, + { + title: '分类标签', + align:"center", + dataIndex: 'instructionTagName' + }, + { + title: '服务类别', + align:"center", + dataIndex: 'categoryName' + }, + { + title: '服务类型', + align:"center", + dataIndex: 'typeName' + }, + { + title: '指令名称', + align:"center", + dataIndex: 'directiveName' + }, + { + title: '服务时长(分钟)', + align:"center", + dataIndex: 'serviceDuration' + }, + // { + // title: '收费价格', + // align:"center", + // dataIndex: 'tollPrice' + // }, + // { + // title: '提成价格', + // align:"center", + // dataIndex: 'comPrice' + // }, +]; + +//表单配置 +export const jVxeSubColumns: JVxeColumn[] = [ { title: '单号', key: 'orderNo', diff --git a/src/views/services/appraisal/components/AppraisalForm.vue b/src/views/services/appraisal/components/AppraisalForm.vue index 6317cfe..d44dfe3 100644 --- a/src/views/services/appraisal/components/AppraisalForm.vue +++ b/src/views/services/appraisal/components/AppraisalForm.vue @@ -1,518 +1,161 @@ - - diff --git a/src/views/services/appraisal/components/AppraisalModal.vue b/src/views/services/appraisal/components/AppraisalModal.vue index 983a9f4..7e57c04 100644 --- a/src/views/services/appraisal/components/AppraisalModal.vue +++ b/src/views/services/appraisal/components/AppraisalModal.vue @@ -1,67 +1,82 @@ - - + diff --git a/src/views/services/appraisal/index.vue b/src/views/services/appraisal/index.vue index c394181..0eae59d 100644 --- a/src/views/services/appraisal/index.vue +++ b/src/views/services/appraisal/index.vue @@ -58,7 +58,7 @@ - @@ -141,9 +141,14 @@ + - + @@ -153,7 +158,7 @@ import {BasicTable, useTable, TableAction} from '/@/components/Table'; import { useListPage } from '/@/hooks/system/useListPage' import {useModal} from '/@/components/Modal'; import AppraisalModal from './components/AppraisalModal.vue' -import {columns, superQuerySchema} from './appraisal.data'; +import {columns,subColumns,superQuerySchema} from './appraisal.data'; import {list, deleteOne, batchDelete, getImportUrl,getExportUrl} from './appraisal.api'; import {downloadFile} from '/@/utils/common/renderUtils'; import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue'; @@ -165,7 +170,7 @@ const formRef = ref(); const queryParam = reactive({}); const checkedKeys = ref>([]); //注册model -const [registerModal, {openModal}] = useModal(); +const registerModal = ref(); const userStore = useUserStore(); //注册table数据 const { prefixCls,tableContext,onExportXls,onImportXls } = useListPage({ @@ -226,21 +231,18 @@ const [registerTable, {reload},{ rowSelection, selectedRowKeys }] = tableContext * 编辑事件 */ function handleEdit(record: Recordable) { - openModal(true, { - record, - isUpdate: true, - showFooter: true, - }); + registerModal.value.disableSubmit = false; + registerModal.value.edit(record); } /** * 详情 */ function handleDetail(record: Recordable) { - openModal(true, { - record, - isUpdate: true, - showFooter: false, - }); + // openModal(true, { + // record, + // isUpdate: true, + // showFooter: false, + // }); } /** * 删除事件 @@ -264,16 +266,20 @@ function handleSuccess() { * 操作栏 */ function getTableAction(record){ - return [ - { + let action = []; + if(record.appraisalStatus == '0'){ + action.push({ label: '考核', onClick: handleEdit.bind(null, record) - }, - { + }) + } + if(record.orderType != '1'){ + action.push({ label: '业务数据', onClick: handleDetail.bind(null, record), - }, - ] + },) + } + return action; } /** * 下拉操作栏