From 20490a39202bf88de261f4089274614a4f11f09b Mon Sep 17 00:00:00 2001 From: xiaofajia <1665375861@qq.com> Date: Fri, 25 Oct 2024 12:04:43 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9C=8D=E5=8A=A1=E9=A1=BE=E9=97=AE=E8=AE=BE?= =?UTF-8?q?=E7=BD=AE=E5=93=AA=E4=BA=9B=E7=BB=B4=E4=BF=AE=E5=9B=BE=E7=89=87?= =?UTF-8?q?=E5=8F=AF=E4=BB=A5=E7=BB=99=E5=AE=A2=E6=88=B7=E7=9C=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/repair/repairRecord/index.js | 18 ++ src/utils/dict.js | 2 + .../tickets/Components/TicketManagerItem.vue | 16 +- .../repair/tickets/form/RecordSetting.vue | 188 ++++++++++++++++++ .../tickets/form/TicketFinishManager.vue | 13 +- 5 files changed, 230 insertions(+), 7 deletions(-) create mode 100644 src/api/repair/repairRecord/index.js create mode 100644 src/views/repair/tickets/form/RecordSetting.vue diff --git a/src/api/repair/repairRecord/index.js b/src/api/repair/repairRecord/index.js new file mode 100644 index 0000000..38d7675 --- /dev/null +++ b/src/api/repair/repairRecord/index.js @@ -0,0 +1,18 @@ +import request from '@/utils/request' + +// 根据条件查询维修记录 +export function queryList(params){ + return request({ + url: '/dl/repair-records/list', + method: 'get', + params + }) +} + +// 设置图片是否开放给用户 +export function updateOpen(ids, isOpen){ + return request({ + url: '/dl/repair-records-item/updateOpen?ids=' + ids + '&isOpen=' + isOpen, + method: 'get', + }) +} diff --git a/src/utils/dict.js b/src/utils/dict.js index a5009c8..bebda61 100644 --- a/src/utils/dict.js +++ b/src/utils/dict.js @@ -220,6 +220,8 @@ export const DICT_TYPE = { TICKET_WARES_STATUS: 'ticket_wares_status', // 领料、退料配件状态 TW_ITEM_STATUS: 'tw_item_status', + // 维修记录类型 + REPAIR_RECORDS_TYPE: 'repair_records_type', // ---------会员相关---------member_coupon_type,member_coupon_out_rule,member_car,member_active //卡券类型 diff --git a/src/views/repair/tickets/Components/TicketManagerItem.vue b/src/views/repair/tickets/Components/TicketManagerItem.vue index ca74263..c898b0a 100644 --- a/src/views/repair/tickets/Components/TicketManagerItem.vue +++ b/src/views/repair/tickets/Components/TicketManagerItem.vue @@ -44,6 +44,9 @@ 查看 + + 维修记录设置 + @@ -143,6 +146,8 @@ 退料全部 + + @@ -156,10 +161,11 @@ import {updateTicketWares} from "@/api/repair/tickets/TicketWares"; import {getIfLeader} from "@/api/repair/repairworker"; import UpdateRecord from "@/views/repair/tickets/form/UpdateRecord.vue"; import {getUserProfile} from "@/api/system/user"; +import RecordSetting from "@/views/repair/tickets/form/RecordSetting.vue"; export default { name: "TicketManagerItem", - components: {UpdateRecord, TWOperate, UpdateRepair, TicketsShow}, + components: {RecordSetting, UpdateRecord, TWOperate, UpdateRepair, TicketsShow}, props: { isFinish: { type: Boolean, @@ -197,7 +203,7 @@ export default { formData: {}, remark: null, leader: false, - nowUser: null + nowUser: null, } }, mounted() { @@ -389,9 +395,9 @@ export default { this.$refs.updateRecord.open(row) }, // 设置维修图片可不可见 - async handleEditRecord(row){ - console.log(row) - } + handleEditRecord(row){ + this.$refs.recordSet.open(row.id) + }, } } diff --git a/src/views/repair/tickets/form/RecordSetting.vue b/src/views/repair/tickets/form/RecordSetting.vue new file mode 100644 index 0000000..1b3192e --- /dev/null +++ b/src/views/repair/tickets/form/RecordSetting.vue @@ -0,0 +1,188 @@ + + + + + diff --git a/src/views/repair/tickets/form/TicketFinishManager.vue b/src/views/repair/tickets/form/TicketFinishManager.vue index 9aed402..be84783 100644 --- a/src/views/repair/tickets/form/TicketFinishManager.vue +++ b/src/views/repair/tickets/form/TicketFinishManager.vue @@ -47,6 +47,9 @@ 编辑工单 + + 维修记录设置 + 处理 @@ -127,6 +130,7 @@ + @@ -136,10 +140,11 @@ import TicketsShow from "@/views/repair/tickets/Components/TicketsShow.vue"; import UpdateRepair from "@/views/repair/tickets/form/UpdateRepair.vue"; import {getUserProfile} from "@/api/system/user"; import EditTickets from "@/views/repair/tickets/form/EditTickets.vue"; +import RecordSetting from "@/views/repair/tickets/form/RecordSetting.vue"; export default { name: "TicketFinishManager", - components: {EditTickets, UpdateRepair, TicketsShow}, + components: {RecordSetting, EditTickets, UpdateRepair, TicketsShow}, props:{ userRole: String }, @@ -272,7 +277,11 @@ export default { }, handleEdit(row){ this.$refs.editTickets.open(row) - } + }, + // 设置维修图片可不可见 + handleEditRecord(row){ + this.$refs.recordSet.open(row.id) + }, } }