From 1d22698048dd72fb3f76a3eb8e87ff4d861f4619 Mon Sep 17 00:00:00 2001 From: X_Rian <904416525@qq.com> Date: Fri, 5 Jul 2024 15:59:01 +0800 Subject: [PATCH] =?UTF-8?q?flx=EF=BC=9A=E4=BF=AE=E6=94=B9=E7=8E=B0?= =?UTF-8?q?=E5=9C=BA=E5=A4=A7=E5=B1=8F=E6=80=BB=E5=8C=85=E5=8D=95=E4=BD=8D?= =?UTF-8?q?=E8=BD=AE=E6=92=AD=20=E5=8D=B1=E9=99=A9=E7=89=B9=E6=AE=8A?= =?UTF-8?q?=E4=BD=9C=E4=B8=9A=E5=A2=9E=E5=8A=A0=E8=BD=AE=E6=92=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/modules/agjtLiveApi.ts | 24 +- src/config/config.ts | 4 +- src/routers/modules/staticRouter.ts | 4 +- .../agjtLiveScreen/liveScreen/leftBottom.vue | 178 ++++++++--- .../agjtLiveScreen/liveScreen/leftTop.vue | 292 ++++++++++-------- 5 files changed, 318 insertions(+), 184 deletions(-) diff --git a/src/api/modules/agjtLiveApi.ts b/src/api/modules/agjtLiveApi.ts index 43d015b..1487771 100644 --- a/src/api/modules/agjtLiveApi.ts +++ b/src/api/modules/agjtLiveApi.ts @@ -3,7 +3,7 @@ import http from "@/api"; const BASEURL = import.meta.env.VITE_API_URL; //获取企业Id的API -export const getEnterpriseIdApi = ( noLoading: boolean) => { +export const getEnterpriseIdApi = (noLoading: boolean) => { return http.post(BASEURL + `/xmgl/enterpriseInfo/getXzSupplierInfo`, { headers: { noLoading: noLoading } }); }; @@ -23,7 +23,7 @@ export const countProjectEnterpriseApi = (params: {}, noLoading: boolean) => { }; //获取承包商进度列表API export const countProcessApi = (params: {}, noLoading: boolean) => { - return http.get(BASEURL + `/xmgl/xzTaskProgress/list?projectSn=`+params.projectSn+`&orderBy=`+params.orderBy, ); + return http.get(BASEURL + `/xmgl/xzTaskProgress/list?projectSn=` + params.projectSn + `&orderBy=` + params.orderBy); }; //获取企业信息API @@ -46,12 +46,16 @@ export const configWeekVideoListApi = (params: {}, noLoading: boolean) => { //获取劳务实名制信息API---上 export const selectPersonTypeAndEduStatisticsApi = (params: {}, noLoading: boolean) => { // return http.post(BASEURL + `/xmgl/workerInfo/selectPersonTypeAndEduStatistics`, params, { headers: { noLoading: noLoading } }); - return http.post(BASEURL + `/xmgl/workerAttendance/selectEnterpriseAttendanceCount`, params, { headers: { noLoading: noLoading } }); + return http.post(BASEURL + `/xmgl/workerAttendance/selectEnterpriseAttendanceCount`, params, { + headers: { noLoading: noLoading } + }); }; //获取劳务实名制信息API---下 export const selectWorkerTeamAndDepartmentStatisticsApi = (params: {}, noLoading: boolean) => { - return http.post(BASEURL + `/xmgl/workerInfo/selectWorkerTeamAndDepartmentStatistics`, params, { headers: { noLoading: noLoading } }); + return http.post(BASEURL + `/xmgl/workerInfo/selectWorkerTeamAndDepartmentStatistics`, params, { + headers: { noLoading: noLoading } + }); }; //获取质量待办信息API @@ -66,7 +70,9 @@ export const securityPageApi = (params: {}, noLoading: boolean) => { // 获取安全评分数据API export const getStatScoreApi = (params: {}, showLoading: boolean) => { - return http.get(BASEURL + `/xmgl/xzSecurityQualityInspectionRecord/getStatScore`, params, { headers: { noLoading: showLoading } }); + return http.get(BASEURL + `/xmgl/xzSecurityQualityInspectionRecord/getStatScore`, params, { + headers: { noLoading: showLoading } + }); }; //获取应急记录信息API @@ -80,3 +86,11 @@ export const getStatBySpecialApi = (params: {}, noLoading: boolean) => { // return http.get(BASEURL + `/xmgl/xzFlow/getStatBySpecial`, params, { headers: { noLoading: noLoading } }); return http.post(BASEURL + `/xmgl/xzSpecial/countSpecialByFinalStatus`, params, { headers: { noLoading: noLoading } }); }; + +//危大数据信息API +export const getcountDangerEngineerApi = (params: {}, noLoading: boolean) => { + // return http.get(BASEURL + `/xmgl/xzFlow/getStatBySpecial`, params, { headers: { noLoading: noLoading } }); + return http.post(BASEURL + `/xmgl/agjtLiveScreen/countDangerEngineerByFinalStatus`, params, { + headers: { noLoading: noLoading } + }); +}; diff --git a/src/config/config.ts b/src/config/config.ts index 8951440..5737806 100644 --- a/src/config/config.ts +++ b/src/config/config.ts @@ -28,11 +28,11 @@ export const BASE_IMAGE_URL = import.meta.env.VITE_BASE_IMAGE_URL; // export const COMPANY: string = "zsbf"; //中水北方 // export const COMPANY: string = "as"; //鞍山项目 // export const COMPANY: string = "agjt"; //鞍钢集团 -// export const COMPANY: string = "agjtLive"; //鞍钢集团现场大屏 +export const COMPANY: string = "agjtLive"; //鞍钢集团现场大屏 // export const COMPANY: string = "agjtCommand"; //鞍钢集团指挥部大屏 // export const COMPANY: string = "agjtProjectKanban"; //鞍钢集团项目看板大屏 // export const COMPANY: string = "agjtOverviewScreen"; //鞍钢集团项目总览 -export const COMPANY: string = "zkjc"; //中科佳成项目 +// export const COMPANY: string = "zkjc"; //中科佳成项目 // export const COMPANY: string = "cqna"; //重庆南岸项目 // export const COMPANY: string = "slx"; //苏立信项目 // export const COMPANY: string = "hfqc"; //合肥启程(乌丹)项目 diff --git a/src/routers/modules/staticRouter.ts b/src/routers/modules/staticRouter.ts index e5f8301..2f4fdda 100644 --- a/src/routers/modules/staticRouter.ts +++ b/src/routers/modules/staticRouter.ts @@ -24,9 +24,9 @@ export const staticRouter: RouteRecordRaw[] = [ { path: "/large", name: "大屏", - component: () => import("@/views/sevenLargeScreen/indexL.vue"), //七参数标准版 + // component: () => import("@/views/sevenLargeScreen/indexL.vue"), //七参数标准版 // component: () => import("@/views/commandScreen/indexCommand.vue"), //指挥部大屏 - // component: () => import("@/views/agjtLiveScreen/indexLive.vue"), //鞍钢现场大屏 + component: () => import("@/views/agjtLiveScreen/indexLive.vue"), //鞍钢现场大屏 // component: () => import("@/views/overviewScreen/indexCommand.vue"), //总览大屏 // component: () => import("@/views/agjtProjectKanban/indexL.vue"), //鞍钢集团项目看板大屏 // component: () => import("@/views/sevenLargeScreen/indexL_syhy.vue"), // 只有一级路由(盘锦、嘉兴、鄱湖美湾医疗项目需切换至该首页) diff --git a/src/views/agjtLiveScreen/liveScreen/leftBottom.vue b/src/views/agjtLiveScreen/liveScreen/leftBottom.vue index fbe5c9d..9fe7e12 100644 --- a/src/views/agjtLiveScreen/liveScreen/leftBottom.vue +++ b/src/views/agjtLiveScreen/liveScreen/leftBottom.vue @@ -1,25 +1,34 @@ @@ -233,4 +294,41 @@ onMounted(async () => { font-size: 14px; } } + +:deep() { + .el-carousel__indicators li { + padding-top: 6px; + padding-bottom: 2px; + } + + .el-carousel__indicator--horizontal .el-carousel__button { + width: 10px; + height: 10px; + background: #a8c3dd; + border: 1px solid #a8c3dd; + border-radius: 50%; + opacity: 0.3; + } + + .el-carousel__indicator--horizontal.is-active .el-carousel__button { + width: 10px; + height: 10px; + background: #4ac0f3; + border: 1px solid #4ac0f3; + border-radius: 50%; + opacity: 1; + } + + .el-carousel__arrow--left { + // top: 70px; + left: -12px; + font-size: 16px; + } + + .el-carousel__arrow--right { + // top: 70px; + right: -12px; + font-size: 16px; + } +} diff --git a/src/views/agjtLiveScreen/liveScreen/leftTop.vue b/src/views/agjtLiveScreen/liveScreen/leftTop.vue index c8ba41b..a9bd506 100644 --- a/src/views/agjtLiveScreen/liveScreen/leftTop.vue +++ b/src/views/agjtLiveScreen/liveScreen/leftTop.vue @@ -2,55 +2,71 @@
- - -
+ + +
- 承包商名称: - {{item.projectEnterprise.cbsName || '--'}} + 承包商名称: + {{ item.projectEnterprise.cbsName || "--" }}
项目编号: - {{item.projectEnterprise.projectNumber || '--'}}
+ {{ item.projectEnterprise.projectNumber || "--" }} +
建筑面积: - {{item.projectEnterprise.projectAcreage + '㎡'}} + {{ item.projectEnterprise.projectAcreage + "㎡" }} --
项目经理: - {{item.projectEnterprise.projectManage || '--'}}
+ {{ item.projectEnterprise.projectManage || "--" }} +
联系电话: - {{item.projectEnterprise.projectTel || '--'}}
+ {{ item.projectEnterprise.projectTel || "--" }} +
项目类型: - {{item.projectEnterprise.cbsProjectTypeName || '--'}}
+ {{ item.projectEnterprise.cbsProjectTypeName || "--" }} +
工程类别: - {{item.projectEnterprise.projectTypeName || '--'}}
+ {{ item.projectEnterprise.projectTypeName || "--" }} +
开工日期: - {{item.projectEnterprise.startWorkDate || '--'}}
+ {{ item.projectEnterprise.startWorkDate || "--" }} +
竣工日期: - {{item.projectEnterprise.completionDate || '--'}}
+ {{ item.projectEnterprise.completionDate || "--" }} +
施工阶段: - {{item.projectEnterprise.constructionStageName || '--'}}
+ {{ item.projectEnterprise.constructionStageName || "--" }} +
结构类型: - {{item.projectEnterprise.structureTypeName || '--'}}
+ {{ item.projectEnterprise.structureTypeName || "--" }} +
工程状态: - {{item.projectEnterprise.bulidStatus == 0 ? '未开工' : - item.projectEnterprise.bulidStatus == 1 ? '在建' : - item.projectEnterprise.bulidStatus == 2 ? '停工' : - item.projectEnterprise.bulidStatus == 3 ? '验收' : - item.projectEnterprise.bulidStatus == 4 ? '完工' : '--'}} + {{ + item.projectEnterprise.bulidStatus == 0 + ? "未开工" + : item.projectEnterprise.bulidStatus == 1 + ? "在建" + : item.projectEnterprise.bulidStatus == 2 + ? "停工" + : item.projectEnterprise.bulidStatus == 3 + ? "验收" + : item.projectEnterprise.bulidStatus == 4 + ? "完工" + : "--" + }}
-
+
承包商名称: - {{item.name || '--'}} + {{ item.name || "--" }}
-
- - -
-
- - Top{{ i + 1 }} - -
-
-
-
{{ item2.taskName }}
-
{{ item2.progressRatio }}%
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- -

暂无数据

-
-
-
+
@@ -132,10 +117,37 @@
- + +
+
+ +

暂无数据

+
- - +
@@ -154,80 +166,90 @@ import { ref, onMounted, watch } from "vue"; import { COMPANY } from "@/config/config"; import { Vue3SeamlessScroll } from "vue3-seamless-scroll"; //引入现场大屏API -import { +import { getEnterpriseIdApi, getEnterpriseInfoByIdApi, countProjectEnterpriseApi, - countProcessApi, - } from "@/api/modules/agjtLiveApi"; + countProcessApi +} from "@/api/modules/agjtLiveApi"; const store = GlobalStore(); -const BASEURL = import.meta.env.VITE_API_URL +const BASEURL = import.meta.env.VITE_API_URL; -const cbsProjectInfo = ref({} as any) +const cbsProjectInfo = ref({} as any); async function getCbsProjectInfo() { let data1 = { - page:1, - pageSize:999, - projectSn:store.sn, - isCountMainEnterprise:1 - } - let peList:any = [] - await countProjectEnterpriseApi(data1,true).then((res:any) => { - if(res.success){ - if(res.result && res.result.records){ - peList = res.result.records + page: 1, + pageSize: 999, + projectSn: store.sn, + isCountMainEnterprise: 1 + }; + let peList: any = []; + await countProjectEnterpriseApi(data1, true).then((res: any) => { + if (res.success) { + if (res.result && res.result.records) { + peList = res.result.records; peList.map((item: any) => { - item.lbType = 1 - }) + item.lbType = 1; + }); } } }); let data2 = { - projectSn:store.sn, + projectSn: store.sn, orderBy: 1 - } - let pList:any = [] - await countProcessApi(data2,true).then((res:any) => { - if(res.success){ - pList = res.result + }; + let pList: any = []; + await countProcessApi(data2, true).then((res: any) => { + if (res.success) { + pList = res.result; } - }) - cbsProjectInfo.value = [] - peList.map((item: any,i: any) => { - cbsProjectInfo.value.push(item) - let processList = pList.filter((item2: any) => item2.enterpriseId == item.id) || [] - if(processList.length>3){ - let tempList:any = [] - // cbsProjectInfo.value.map((item3:any,i:any) => { - processList.map((item3:any,i:any) => { - tempList.push(item3) - if((i+1)%3 == 0){ - cbsProjectInfo.value.push({ - id: item.id, - name: item.projectEnterprise.cbsName, - lbType: 2, - processList: tempList - }) - tempList = [] - } - }) - }else{ - cbsProjectInfo.value.push({ + }); + cbsProjectInfo.value = []; + peList.map((item: any, i: any) => { + cbsProjectInfo.value.push(item); + let processList = pList.filter((item2: any) => item2.enterpriseId == item.id) || []; + if (processList.length == 0) return; + // console.log(555555555, processList); + cbsProjectInfo.value = [ + ...cbsProjectInfo.value, + { id: item.id, name: item.projectEnterprise.cbsName, lbType: 2, - processList: processList - }) - } - }) - console.log('cbsProjectInfo',cbsProjectInfo.value) -}; + processList: processList.map((item3: any) => item3) + } + ]; + // if (processList.length > 3) { + // let tempList: any = []; + // processList.map((item3: any, i: any) => { + // tempList.push(item3); + // if ((i + 1) % 6 == 0) { + // cbsProjectInfo.value.push({ + // id: item.id, + // name: item.projectEnterprise.cbsName, + // lbType: 2, + // processList: tempList + // }); + // tempList = []; + // } + // }); + // } else { + // cbsProjectInfo.value.push({ + // id: item.id, + // name: item.projectEnterprise.cbsName, + // lbType: 2, + // processList: processList + // }); + // } + }); + console.log("cbsProjectInfo", cbsProjectInfo.value); +} // async function getCbsProjectInfo() { // //获取企业Id // await getEnterpriseIdApi().then(res => { // if(res.success){ // let data = { -// enterpriseId: res.result.id, +// enterpriseId: res.result.id, // projectSn: '', // } // if(BASEURL == 'http://182.90.224.237:51234' || BASEURL == 'http://192.168.34.221:9111') data.projectSn = 'BD3137498CB84BF0969979E0342CDBCA' @@ -241,15 +263,15 @@ async function getCbsProjectInfo() { //父组件调用需要无感刷新的方法 const leftTopMethod = async () => { - getCbsProjectInfo() -} + getCbsProjectInfo(); +}; //将方法暴露给父组件 defineExpose({ leftTopMethod -}) -onMounted( async () => { - getCbsProjectInfo() -}) +}); +onMounted(async () => { + getCbsProjectInfo(); +});