From 4bc12189dc36d707400be8da761b788a58e31044 Mon Sep 17 00:00:00 2001 From: Teo <2642673902@qq.com> Date: Mon, 14 Apr 2025 18:08:27 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=89=E5=85=A8=E4=BC=9A=E8=AE=AE=E7=BA=AA?= =?UTF-8?q?=E8=A6=81,=E7=AB=99=E7=8F=AD=E4=BC=9A,=E5=AE=89=E5=85=A8?= =?UTF-8?q?=E5=B7=A1=E6=A3=80=E5=B7=A5=E5=8D=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 2 + src/App.vue | 1 - src/api/safety/documentSafetyMeeting/index.ts | 87 +++ src/api/safety/documentSafetyMeeting/type.ts | 61 ++ src/api/safety/safetyLog/types.ts | 2 + src/api/safety/teamMeeting/types.ts | 6 +- src/assets/icons/svg/file.png | Bin 0 -> 1612 bytes src/assets/icons/svg/file1.png | Bin 0 -> 1152 bytes src/main.ts | 5 + src/store/modules/bigUpload.ts | 12 + .../RecyclingStation/index.vue | 135 +++++ .../safety/documentSafetyMeeting/index.vue | 524 ++++++++++++++++++ .../SafetyInspectionDetailDialog.vue | 4 +- src/views/safety/safetyInspection/index.vue | 19 +- src/views/safety/safetyLog/index.vue | 9 +- .../component/TeamMeetingDetailDrawer.vue | 6 +- src/views/safety/teamMeeting/index.vue | 23 +- 17 files changed, 867 insertions(+), 29 deletions(-) create mode 100644 src/api/safety/documentSafetyMeeting/index.ts create mode 100644 src/api/safety/documentSafetyMeeting/type.ts create mode 100644 src/assets/icons/svg/file.png create mode 100644 src/assets/icons/svg/file1.png create mode 100644 src/store/modules/bigUpload.ts create mode 100644 src/views/safety/documentSafetyMeeting/RecyclingStation/index.vue create mode 100644 src/views/safety/documentSafetyMeeting/index.vue diff --git a/package.json b/package.json index 2f57a34..8f79aa2 100644 --- a/package.json +++ b/package.json @@ -39,9 +39,11 @@ "image-conversion": "2.1.1", "js-cookie": "3.0.5", "jsencrypt": "3.3.2", + "mitt": "^3.0.1", "nprogress": "0.2.0", "pinia": "2.2.6", "screenfull": "6.0.2", + "spark-md5": "^3.0.2", "vue": "3.5.13", "vue-cropper": "1.1.1", "vue-i18n": "10.0.5", diff --git a/src/App.vue b/src/App.vue index 3c662b1..3bd9f2e 100644 --- a/src/App.vue +++ b/src/App.vue @@ -9,7 +9,6 @@ import useSettingsStore from '@/store/modules/settings'; import { handleThemeStyle } from '@/utils/theme'; import useAppStore from '@/store/modules/app'; import { getProjectTeam } from './utils/projectTeam'; -import { useUserStore } from '@/store/modules/user'; const appStore = useAppStore(); onMounted(() => { diff --git a/src/api/safety/documentSafetyMeeting/index.ts b/src/api/safety/documentSafetyMeeting/index.ts new file mode 100644 index 0000000..8ed5baf --- /dev/null +++ b/src/api/safety/documentSafetyMeeting/index.ts @@ -0,0 +1,87 @@ +import request from '@/utils/request'; +import { + documentSafetyMeetingListFile, + documentSafetyMeetingListFolder, + documentSafetyMeetingListQuery, + documentSafetyMeetingListVo, + documentRecycleBinListQuery, + documentRecycleBinListVO +} from './type'; +import { AxiosPromise } from 'axios'; +// 查询安全会议结构 +export function documentCompletionTreeStructure(query: object) { + return request({ + url: '/safety/documentSafetyMeeting/list', + method: 'get', + params: query + }); +} +// 查询安全会议文件列表 +export function documentCompletionList(query: documentSafetyMeetingListQuery): AxiosPromise { + return request({ + url: '/safety/documentSafetyMeeting/list', + method: 'get', + params: query + }); +} +// 安全会议添加 +export function documentCompletionAdd(data: documentSafetyMeetingListFile) { + return request({ + url: '/safety/documentSafetyMeeting/file', + method: 'post', + data + }); +} +// 安全会议修改文件名 +export function documentCompletionEdit(query: object) { + return request({ + url: '/api/v1/system/documentSafetyMeeting/edit', + method: 'put', + params: query + }); +} +// 安全会议删除文件 +export function documentCompletionDelete(id: string) { + return request({ + url: '/safety/documentSafetyMeeting/' + id, + method: 'delete' + }); +} +// 安全会议获取指定id信息 +export function documentCompletionGet(id: string) { + return request({ + url: '/safety/documentSafetyMeeting/' + id, + method: 'get' + }); +} +// 新建文件夹 +export function newFolder(data: documentSafetyMeetingListFolder): AxiosPromise { + return request({ + url: '/safety/documentSafetyMeeting/folder', + method: 'post', + data + }); +} +// 单文件下载 +export function uniFileDownload(query: object) { + return request({ + url: '/api/v1/system/documentSafetyMeeting/safetyDataUniFileDownload', + method: 'get', + params: query + }); +} +// 回收站恢复 +export function completionDataRecyclingStation(id: string[]) { + return request({ + url: '/safety/documentSafetyMeeting/recovery/' + id, + method: 'put' + }); +} +// 回收站列表数据 +export function documentRecycleBinList(query: documentRecycleBinListQuery): AxiosPromise { + return request({ + url: '/safety/documentSafetyMeeting/recycleBin/list', + method: 'get', + params: { ...query, fileType: '2' } + }); +} diff --git a/src/api/safety/documentSafetyMeeting/type.ts b/src/api/safety/documentSafetyMeeting/type.ts new file mode 100644 index 0000000..0ea3ca9 --- /dev/null +++ b/src/api/safety/documentSafetyMeeting/type.ts @@ -0,0 +1,61 @@ +export interface documentSafetyMeetingListFolder { + //新增文件夹 + projectId: string; + pid?: string; + fileName: string; + remark?: string; +} + +export interface documentSafetyMeetingListFile { + //新增文件 + file: any; + req?: reqQuery; +} + +export interface reqQuery { + projectId: string; + pid?: string; +} + +export interface documentSafetyMeetingListQuery { + projectId: string; + pid?: string; + //1文件 2文件夹 3图片 + fileType?: string; +} + +export interface documentSafetyMeetingListVo { + projectId: string; + id: string; + pid: string; + fileName: string; + fileStatus?: string; + filePath: string; + fileSuffix: string; + originalName: string; + remark?: string; + //1文件 2文件夹 3图片 + fileType?: string; +} + +export interface documentRecycleBinListQuery { + projectId: string; + pid?: string; + fileType?: string; + pageSize?: number; + pageNum?: number; + orderByColumn?: string; + isAsc?: string; +} + +export interface documentRecycleBinListVO { + id: string; + projectId: string; + pid?: string; + fileName?: string; + filePath?: number; + fileSuffix?: number; + fileStatus?: string; + originalName?: string; + remark?: string; +} diff --git a/src/api/safety/safetyLog/types.ts b/src/api/safety/safetyLog/types.ts index ae9da3f..3eb029e 100644 --- a/src/api/safety/safetyLog/types.ts +++ b/src/api/safety/safetyLog/types.ts @@ -102,6 +102,7 @@ export interface SafetyLogForm extends BaseEntity { * 主键id */ id?: string | number; + creatorName?: string; /** * 项目id @@ -189,6 +190,7 @@ export interface SafetyLogQuery extends PageQuery { * 项目id */ projectId?: string | number; + creatorName?: string; /** * 发生日期 diff --git a/src/api/safety/teamMeeting/types.ts b/src/api/safety/teamMeeting/types.ts index 8678f63..9ef3523 100644 --- a/src/api/safety/teamMeeting/types.ts +++ b/src/api/safety/teamMeeting/types.ts @@ -14,12 +14,12 @@ export interface TeamMeetingVO { /** * 班组 */ - team: IdAndNameVO; + teamName: IdAndNameVO; /** * 分包公司 */ - contractor: IdAndNameVO; + contractorName: IdAndNameVO; /** * 开会时间 @@ -29,7 +29,7 @@ export interface TeamMeetingVO { /** * 宣讲人 */ - compere: IdAndNameVO; + compereName: IdAndNameVO; /** * 参与人列表 diff --git a/src/assets/icons/svg/file.png b/src/assets/icons/svg/file.png new file mode 100644 index 0000000000000000000000000000000000000000..cf70ecf3c868490eb58176cb425b9be9fdaa2a3e GIT binary patch literal 1612 zcmV-S2DABzP)Px*21!IgRCr$PolSDvMihh_EN`&P4WuLZ1eTW$D`$vx5?dz`b%qp^rI?e1IR#U$ zGU>u^0B}gc7(nl5T5DqFz3#6bAhH2ui2OVJfd{Pc4B#$ushGp}$gnRLIAMn){?32H zE@nX9eZ*j9MSKh^Lpwiy?`q(B^C)%1E*FK+?ccRb-8 z_Jr+i-HHQji_buLdbIIZO|=)Sup?-1V_8~&^)=mKg(rfxENCeMRw>KV=c0rWutr{< zJ{JLvfQ4n<;E0#vpMphHH?ZhjmktEXfY~A?7855-|TBi*`uBMCJFtIRW$Uv1o?`OjLgV zn-ehq9*cHJz(nQuzc~T(@3Cly1WZ(Z|CVux=<4t%UU9<1G97YN zQ3a0p7<+eC)K5iC^YyK3A4J9A=5s3WFOJy9!c`PB3t)40#3D~xL z#%l2cH~*->tO_*WgAuSXeJl|vt^+6Y6pNZ)vDbvYx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^eK$hP>Fwagp#BYhV>mTgHlkel24l!PzaSYjx!}ivdS0UHn!XBI_16p5Ikh~ zB!Y{L4oXtzX7J>jK)U50I+qgV`Mnz)k-uTU(a#Iw4(+090Vf z?zo{q>60qBr_r|lj@*1hKrU&oqqCm!wD}y!s4Og59ctyg?4!*yAcfqB+*IB&G!@xu zNuC59`x9h4Bjm5uMgU@K{5ryc6m<$FQR)K3?-Bd~M~QY#EB`fKx8yZmhW~H)dh#ZR zJs>+WA7BgPbYXi7slW7o?dtYA!(CKQ`~2LJ84R#pPLS`tFjd)@C#-LeMYDM^F1!UI zX0Xlsf(Bu+`78q#m4lbwf3p6*UK>f!kK%%vu9xiY#i&R+N$jcDK2It0x374f-c0i; zQh8w2MiU#8i|l1XJ4cM^)-8{knA7Zy(G#oA*8gbGXn4Jk$tzR1GIq+r!<`)xqy3P^ zhVc9i6wm+uiM~E48q24 ({ + panelShow: false + }), + actions: { + async setPanelShow(bool: boolean) { + this.panelShow = bool; + } + } +}); diff --git a/src/views/safety/documentSafetyMeeting/RecyclingStation/index.vue b/src/views/safety/documentSafetyMeeting/RecyclingStation/index.vue new file mode 100644 index 0000000..e8f9c27 --- /dev/null +++ b/src/views/safety/documentSafetyMeeting/RecyclingStation/index.vue @@ -0,0 +1,135 @@ + + + diff --git a/src/views/safety/documentSafetyMeeting/index.vue b/src/views/safety/documentSafetyMeeting/index.vue new file mode 100644 index 0000000..f14998c --- /dev/null +++ b/src/views/safety/documentSafetyMeeting/index.vue @@ -0,0 +1,524 @@ + + + diff --git a/src/views/safety/safetyInspection/component/SafetyInspectionDetailDialog.vue b/src/views/safety/safetyInspection/component/SafetyInspectionDetailDialog.vue index aa8dacb..7004a8b 100644 --- a/src/views/safety/safetyInspection/component/SafetyInspectionDetailDialog.vue +++ b/src/views/safety/safetyInspection/component/SafetyInspectionDetailDialog.vue @@ -14,7 +14,7 @@ {{ safetyInspectionDetail?.checkTime }} - {{ safetyInspectionDetail?.creatorName }} + {{ safetyInspectionDetail?.correctorName }} {{ safetyInspectionDetail?.correctorName }} {{ dayjs(safetyInspectionDetail?.rectificationDeadline).format('YYYY 年 MM 月 DD 日') }} @@ -104,6 +104,7 @@ const get = async () => { const res = await getSafetyInspection(props.safetyInspectionId); if (res.data && res.code === 200) { safetyInspectionDetail.value = res.data; + if (res.data.checkFile) { const checkFileRes = await listByIds(res.data.checkFile.split(',')); checkFileList.value = checkFileRes.data; @@ -117,6 +118,7 @@ const get = async () => { }; onMounted(() => { + console.log('🚀 ~ onMounted ~ props.safetyInspectionId:', props.safetyInspectionId); get(); }); diff --git a/src/views/safety/safetyInspection/index.vue b/src/views/safety/safetyInspection/index.vue index 1a5d85d..b949050 100644 --- a/src/views/safety/safetyInspection/index.vue +++ b/src/views/safety/safetyInspection/index.vue @@ -5,17 +5,17 @@ - + - + - + @@ -36,7 +36,7 @@ - 批量删除 + 删除 @@ -54,10 +54,10 @@ - - + + @@ -84,9 +84,7 @@ 详情 - - 修改 - + 修改 @@ -287,6 +285,7 @@ const currentSafetyInspectionId = ref(); const showDetailDialog = ref(false); const handleShowDialog = (row?: SafetyInspectionVO) => { currentSafetyInspectionId.value = row.id; + showDetailDialog.value = true; }; diff --git a/src/views/safety/safetyLog/index.vue b/src/views/safety/safetyLog/index.vue index ac94e5d..64a9e5c 100644 --- a/src/views/safety/safetyLog/index.vue +++ b/src/views/safety/safetyLog/index.vue @@ -7,6 +7,9 @@ + + + 搜索 重置 @@ -48,7 +51,7 @@ - + @@ -176,6 +179,7 @@ const initFormData: SafetyLogForm = { stoppageOrOvertime: undefined, otherCondition: undefined, fileId: undefined, + creatorName: undefined, remark: undefined }; const data = reactive>({ @@ -198,6 +202,7 @@ const data = reactive>({ stoppageOrOvertime: undefined, otherCondition: undefined, remark: undefined, + creatorName: undefined, params: {} }, rules: { diff --git a/src/views/safety/teamMeeting/component/TeamMeetingDetailDrawer.vue b/src/views/safety/teamMeeting/component/TeamMeetingDetailDrawer.vue index bac7665..ae5c13d 100644 --- a/src/views/safety/teamMeeting/component/TeamMeetingDetailDrawer.vue +++ b/src/views/safety/teamMeeting/component/TeamMeetingDetailDrawer.vue @@ -1,12 +1,12 @@