From a4ccb445114e1dd110f964a1ecf9a7fabfca3daa Mon Sep 17 00:00:00 2001 From: X_Rian <904416525@qq.com> Date: Thu, 20 Jun 2024 15:28:59 +0800 Subject: [PATCH] =?UTF-8?q?flx=EF=BC=9A=E4=BF=AE=E6=94=B9=E9=A1=B9?= =?UTF-8?q?=E7=9B=AE=E7=9C=8B=E6=9D=BF=20=E6=80=BB=E8=A7=88=E5=A4=A7?= =?UTF-8?q?=E5=B1=8F=E6=A0=B7=E5=BC=8F=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/setVideoDialog.vue | 11 ++++++++++- src/config/config.ts | 4 ++-- src/routers/modules/staticRouter.ts | 4 ++-- .../projectOverview/rightBottom.vue | 9 +++++---- .../projectOverview/rightTop.vue | 2 +- .../commandScreen/commandCenter/centerBottom.vue | 13 ++++++++++--- .../commandScreen/commandCenter/leftBottom.vue | 2 +- src/views/commandScreen/commandCenter/rightAll.vue | 5 +++-- .../commandScreen/dialogCompnnents/data-dialog.vue | 2 +- .../commandScreen/dialogCompnnents/major-hidder.vue | 8 +++++--- 10 files changed, 40 insertions(+), 20 deletions(-) diff --git a/src/components/setVideoDialog.vue b/src/components/setVideoDialog.vue index dae6261..c0598fa 100644 --- a/src/components/setVideoDialog.vue +++ b/src/components/setVideoDialog.vue @@ -20,8 +20,9 @@ ref="upload" class="upload-demo" :action="BASEURL + '/upload/image'" - :on-success="file => handleSuccess(file, index)" + :on-success="(file: any) => handleSuccess(file, index)" :beforeUpload="handleBeforeUploadVideo" + :on-error="handleError" name="files" :show-file-list="false" > @@ -46,6 +47,7 @@ import { onMounted, reactive, ref } from "vue"; import { UploadFilled } from "@element-plus/icons-vue"; import { ElMessage } from "element-plus"; import type { UploadInstance } from "element-plus"; +import { showFullScreenLoading, tryHideFullScreenLoading } from "@/config/serviceLoading"; import { configWeekVideoSaveApi, configWeekVideoListApi } from "@/api/modules/agjtCommandApi"; import { GlobalStore } from "@/stores"; import moment from "moment"; @@ -139,6 +141,7 @@ function handleBeforeUploadVideo(file: any) { console.log(file, "上传之前"); let fileType = file.type.split("/")[0]; if (fileType == "video") { + showFullScreenLoading(); return true; } else { ElMessage({ @@ -153,11 +156,17 @@ function handleBeforeUploadVideo(file: any) { function handleSuccess(file: any, index: number) { if (file.code == 200 || file.status == "SUCCESS") { console.log(file, "上传成功"); + tryHideFullScreenLoading(); let url = file.data[0].imageUrl; // this.imgUrl = url; configWeekVideoEditFn(true, url, index); } } +// 视频上传成功 +function handleError() { + tryHideFullScreenLoading(); +} + const closeDialog = () => { dialogInfo.showDialog = false; dialogInfo.postData = {}; diff --git a/src/config/config.ts b/src/config/config.ts index 06880ef..ff2368c 100644 --- a/src/config/config.ts +++ b/src/config/config.ts @@ -29,9 +29,9 @@ export const BASE_IMAGE_URL = import.meta.env.VITE_BASE_IMAGE_URL; // export const COMPANY: string = "as"; //鞍山项目 // export const COMPANY: string = "agjt"; //鞍钢集团 // export const COMPANY: string = "agjtLive"; //鞍钢集团现场大屏 -// export const COMPANY: string = "agjtCommand"; //鞍钢集团指挥部大屏 +export const COMPANY: string = "agjtCommand"; //鞍钢集团指挥部大屏 // export const COMPANY: string = "agjtProjectKanban"; //鞍钢集团项目看板大屏 -export const COMPANY: string = "agjtOverviewScreen"; //鞍钢集团项目总览 +// export const COMPANY: string = "agjtOverviewScreen"; //鞍钢集团项目总览 // export const COMPANY: string = "zkjc"; //中科佳成项目 // export const COMPANY: string = "cqna"; //重庆南岸项目 // export const COMPANY: string = "slx"; //苏立信项目 diff --git a/src/routers/modules/staticRouter.ts b/src/routers/modules/staticRouter.ts index 644f180..550726a 100644 --- a/src/routers/modules/staticRouter.ts +++ b/src/routers/modules/staticRouter.ts @@ -25,9 +25,9 @@ export const staticRouter: RouteRecordRaw[] = [ path: "/large", name: "大屏", // component: () => import("@/views/sevenLargeScreen/indexL.vue"), //七参数标准版 - // component: () => import("@/views/commandScreen/indexCommand.vue"), //指挥部大屏 + component: () => import("@/views/commandScreen/indexCommand.vue"), //指挥部大屏 // component: () => import("@/views/agjtLiveScreen/indexLive.vue"), //鞍钢现场大屏 - component: () => import("@/views/overviewScreen/indexCommand.vue"), //总览大屏 + // component: () => import("@/views/overviewScreen/indexCommand.vue"), //总览大屏 // component: () => import("@/views/agjtProjectKanban/indexL.vue"), //鞍钢集团项目看板大屏 // component: () => import("@/views/sevenLargeScreen/indexL_syhy.vue"), // 只有一级路由(盘锦、嘉兴、鄱湖美湾医疗项目需切换至该首页) children: [ diff --git a/src/views/agjtProjectKanban/comprehensiveManage/projectOverview/rightBottom.vue b/src/views/agjtProjectKanban/comprehensiveManage/projectOverview/rightBottom.vue index 02cf778..c1beaa2 100644 --- a/src/views/agjtProjectKanban/comprehensiveManage/projectOverview/rightBottom.vue +++ b/src/views/agjtProjectKanban/comprehensiveManage/projectOverview/rightBottom.vue @@ -1,16 +1,16 @@