From 39597fe39bcc9564817564344412a491fd197b09 Mon Sep 17 00:00:00 2001 From: chenxf Date: Tue, 6 Jan 2026 15:37:26 +0800 Subject: [PATCH] =?UTF-8?q?refactor(api):=20=E6=9B=B4=E6=96=B0API=E6=8E=A5?= =?UTF-8?q?=E5=8F=A3URL=E8=B7=AF=E5=BE=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 统一调整API接口路径命名规范,将带有xr前缀的路径更改为标准路径: - /xrBaseCode/list -> /constant/list - /xrAttachment/delLawFile -> /attachment/delLawFile - /xrAttachment/listByBizSepNo -> /attachment/listByBizSepNo feat(main): 添加全局console对象 在Vue原型链上添加console对象,便于全局调试使用 refactor(handle): 优化组件中的事件处理逻辑 - 修复radio组件change事件处理函数,使用箭头函数并修正参数引用 - 为flowModel添加默认空数组返回,避免undefined错误 - 修正API响应数据结构,从data.data获取实际数据 --- src/api/force.js | 6 +++--- src/main.js | 1 + src/views/forceNotice/inclusion/handle.vue | 10 +++++----- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/src/api/force.js b/src/api/force.js index 25db417..8155c1b 100644 --- a/src/api/force.js +++ b/src/api/force.js @@ -236,7 +236,7 @@ export function isTaskCreater(params) { export function xrBaseCodeList(data) { return request({ useResponseData: true, - url: '/xrBaseCode/list', + url: '/constant/list', method: 'post', data }).then((data) => { @@ -253,7 +253,7 @@ export function xrBaseCodeList(data) { export function xrAttachmentDelLawFile(params) { return request({ useResponseData: true, - url: '/xrAttachment/delLawFile', + url: '/attachment/delLawFile', method: 'post', params }) @@ -262,7 +262,7 @@ export function xrAttachmentDelLawFile(params) { export function xrAttachmentListByBizSepNo(data) { return request({ useResponseData: true, - url: '/xrAttachment/listByBizSepNo', + url: '/attachment/listByBizSepNo', method: 'post', data }) diff --git a/src/main.js b/src/main.js index 9485925..7fc5296 100644 --- a/src/main.js +++ b/src/main.js @@ -49,6 +49,7 @@ Vue.prototype.$moment = moment // 工具类 Vue.prototype.$util = util Vue.prototype.$utils = utils +Vue.prototype.console = console Vue.component('paper-swiper', () => import ('@/components/PaperSwiper')) Vue.component('paper', () => import ('@/components/Paper')) Vue.component('CommonTitle', () => import ('@/components/CommonTitle')) diff --git a/src/views/forceNotice/inclusion/handle.vue b/src/views/forceNotice/inclusion/handle.vue index e440d24..2716849 100644 --- a/src/views/forceNotice/inclusion/handle.vue +++ b/src/views/forceNotice/inclusion/handle.vue @@ -109,9 +109,9 @@
{ // 调用方法并传入 isUpper 参数 - getUsersWithPermission(val === '上级部门处理人' ? 1 : 0); + getUsersWithPermission(localSelection === '上级部门处理人' ? 1 : 0); scope.easyFormItemBindData.componentScope.formInstance.clearValidate(scope.field.prop); }" > @@ -396,7 +396,7 @@ export default { required: true, span: 24, options: ({ formData }) => { - return this.flowModel + return this.flowModel || [] }, showInForm: () => { return !this.readonly @@ -601,7 +601,7 @@ export default { permission, this.$store.getters.orgId ).then((data) => { - this.nextPerformerMap = data + this.nextPerformerMap = data.data })) } return Promise.all(ps) @@ -677,7 +677,7 @@ export default { this.$store.getters.orgId, isUpper ).then((data) => { - this.nextPerformerMap = data + this.nextPerformerMap = data.data })) } return Promise.all(ps)