From 2b742f0a80b541eb7d75adc0c32041b66c460256 Mon Sep 17 00:00:00 2001
From: BianLzhaoMin <11485688+bianliangzhaomin123@user.noreply.gitee.com>
Date: Fri, 18 Oct 2024 11:25:17 +0800
Subject: [PATCH 1/4] =?UTF-8?q?=E4=BD=9C=E4=B8=9A=E8=AE=A1=E5=88=92?=
=?UTF-8?q?=E9=A1=B5=E9=9D=A2=E5=AE=8C=E5=96=84?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
pages.json | 10 ++-
pages/realName/workPlan-details/index.vue | 91 ++++++++++++++++++++++-
pages/realName/workPlan/index.vue | 14 +---
3 files changed, 102 insertions(+), 13 deletions(-)
diff --git a/pages.json b/pages.json
index 2c35a2d..5c378ca 100644
--- a/pages.json
+++ b/pages.json
@@ -254,13 +254,21 @@
"style": {
"navigationStyle": "custom"
}
- },{
+ },
+ {
//首页二级跳转页面 -- 人员列表
"path": "pages/realName/index/pages/personList",
"style": {
"navigationStyle": "custom"
}
},
+ {
+ //首页三级级跳转页面 -- 人员信息
+ "path": "pages/realName/index/pages/personDetail",
+ "style": {
+ "navigationStyle": "custom"
+ }
+ },
{
//工作台
"path": "pages/realName/workbench/index",
diff --git a/pages/realName/workPlan-details/index.vue b/pages/realName/workPlan-details/index.vue
index 25d4740..34819dc 100644
--- a/pages/realName/workPlan-details/index.vue
+++ b/pages/realName/workPlan-details/index.vue
@@ -53,7 +53,9 @@
- {{ item.name }}
+
+ {{ item.name }}
+
@@ -79,9 +81,48 @@
- 站班会照片
+
+
+
+
+
@@ -99,8 +140,10 @@ export default {
todayWorkList: [], // 今日计划
workPersonList: [], // 作业人员
holdCardList: [], // 持证信息
+ holdCardDetailsList: [], // 持证信息详情
standGuardList: [], // 站班信息
contentId: '',
+ loading: false,
commonParams: {
proName: '',
day: this.$moment().format('YYYY-MM-DD')
@@ -136,9 +179,27 @@ export default {
},
/* 查询持证信息 */
async onQueryCardDetails(name) {
+ this.$refs.popup.open()
const params = Object.assign(this.commonParams, { certificateName: name })
+
+ this.loading = true
const res = await getHoldCardInfoApi(params)
+ // uni.hideLoading()
+ this.loading = false
console.log('resresres持证信息详情--', res)
+ this.holdCardDetailsList = res.data
+ },
+ /* 关闭持证信息弹框 */
+ onClosePopup() {
+ uni.hideLoading()
+ this.$refs.popup.close()
+ },
+ /* 持证详情列表点击事件 */
+ onClickTableTr(id) {
+ console.log('id-----人员id', id)
+
+ // 跳转人员信息页面
+ uni.navigateTo({ url: `/pages/realName/index/pages/personDetail?idNumber=${id}` })
}
},
onLoad(options) {
@@ -221,4 +282,30 @@ export default {
.person-card view:nth-child(3n + 1) {
margin-left: 0;
}
+
+.popup-center {
+ width: 90vw;
+ height: 50vh;
+ background-color: #fff;
+ .popup-title {
+ position: relative;
+ background-color: #3f9dfd;
+ height: 100rpx;
+ line-height: 100rpx;
+ text-align: center;
+ color: #fff;
+ font-size: 30rpx;
+
+ .close-icon {
+ position: absolute;
+ right: 30rpx;
+ top: 0;
+ }
+ }
+
+ .scroll-container {
+ width: 100%;
+ height: calc(100% - 100rpx);
+ }
+}
diff --git a/pages/realName/workPlan/index.vue b/pages/realName/workPlan/index.vue
index 1f213f5..dbf7f77 100644
--- a/pages/realName/workPlan/index.vue
+++ b/pages/realName/workPlan/index.vue
@@ -26,12 +26,7 @@
-
+
{{ index + 1 }}
{{ item.proName }}
@@ -42,7 +37,7 @@
:style="{ color: item.isCollect == 1 ? '#f9971e' : '' }"
>
-
+
{{ item.subComName }}
可接受风险:{{ item.kjsfx }}
@@ -51,7 +46,7 @@
高风险:{{ item.gfx }}
-
+
作业人数
{{ item.personNum }}
@@ -118,7 +113,6 @@ export default {
methods: {
/* 获取作业计划列表 */
async getWorkPlantData() {
- console.log('this.queryParams参数', this.queryParams)
uni.request({
url: config.loginBaseUrl + '/bmw/homeSubPage/getAppDayPlanMsg',
method: 'POST',
@@ -128,7 +122,6 @@ export default {
// token: this.token
},
success: res => {
- console.log('res****', res)
this.recordsTotal = res.data.recordsTotal
this.companyInfoList = res.data.data
},
@@ -193,6 +186,7 @@ export default {
success: res => {
if (res.data.code === 200) {
uni.showToast({ icon: 'none', title: ` ${row.isCollect == 0 ? '收藏成功' : '已取消收藏'}` })
+ this.getWorkPlantData()
}
},
fail: err => {}
From 7bb1b1c123aba0258e30e020c3677f2bc56becc0 Mon Sep 17 00:00:00 2001
From: BianLzhaoMin <11485688+bianliangzhaomin123@user.noreply.gitee.com>
Date: Fri, 18 Oct 2024 14:06:50 +0800
Subject: [PATCH 2/4] =?UTF-8?q?=E4=BD=9C=E4=B8=9A=E8=AE=A1=E5=88=92?=
=?UTF-8?q?=E8=AF=A6=E6=83=85=E9=A1=B5=E9=9D=A2=E8=B0=83=E8=AF=95=E5=AE=8C?=
=?UTF-8?q?=E6=88=90?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.hbuilderx/launch.json | 2 +-
.../index/components/pie-charts-model.vue | 8 +-
pages/realName/workPlan-details/index.vue | 116 +++++++++++-------
3 files changed, 81 insertions(+), 45 deletions(-)
diff --git a/.hbuilderx/launch.json b/.hbuilderx/launch.json
index 9b0d791..4ccd172 100644
--- a/.hbuilderx/launch.json
+++ b/.hbuilderx/launch.json
@@ -13,7 +13,7 @@
"type" : "uniCloud"
},
{
- "playground" : "standard",
+ "playground" : "custom",
"type" : "uni-app:app-android"
}
]
diff --git a/pages/realName/index/components/pie-charts-model.vue b/pages/realName/index/components/pie-charts-model.vue
index 32b37f3..b8c2d61 100644
--- a/pages/realName/index/components/pie-charts-model.vue
+++ b/pages/realName/index/components/pie-charts-model.vue
@@ -1,6 +1,6 @@
-
+
@@ -80,6 +80,9 @@ export default {
labelBgOpacity: 0.7,
labelFontColor: '#666666'
}
+ },
+ onClick: e => {
+ console.log('eeeee图表点击了---', e)
}
}
}
@@ -133,6 +136,9 @@ export default {
this.chartData = JSON.parse(JSON.stringify(data))
}, 500)
})
+ },
+ handleChartClick() {
+ console.log('图表点击-------')
}
}
}
diff --git a/pages/realName/workPlan-details/index.vue b/pages/realName/workPlan-details/index.vue
index 34819dc..e50af56 100644
--- a/pages/realName/workPlan-details/index.vue
+++ b/pages/realName/workPlan-details/index.vue
@@ -63,12 +63,7 @@
-
+
{{ item.certificateName }}({{ item.certificateNum }})
-
- 持证名称
- 持证人姓名
- 工种
-
-
-
-
-
- {{ item.certificateName }}
-
-
+
+
+
+ {{ holdCardTitle }}
+
+
+
-
-
- {{ item.name }}
-
-
-
-
- {{ item.gz }}
-
-
-
-
-
+
+ 持证名称
+ 持证人姓名
+ 工种
+
+
+
+
+
+ {{ item.certificateName }}
+ {{ item.name }}
+ {{ item.gz }}
+
+
+
@@ -140,6 +142,7 @@ export default {
todayWorkList: [], // 今日计划
workPersonList: [], // 作业人员
holdCardList: [], // 持证信息
+ holdCardTitle: '',
holdCardDetailsList: [], // 持证信息详情
standGuardList: [], // 站班信息
contentId: '',
@@ -178,14 +181,15 @@ export default {
this.getWorkPersonnelData()
},
/* 查询持证信息 */
- async onQueryCardDetails(name) {
+ async onQueryCardDetails(item) {
+ this.holdCardTitle = `${item.certificateName}(${item.certificateNum})`
this.$refs.popup.open()
- const params = Object.assign(this.commonParams, { certificateName: name })
-
- this.loading = true
+ const params = Object.assign(this.commonParams, { certificateName: item.certificateName })
+ uni.showLoading({
+ title: '数据加载中'
+ })
const res = await getHoldCardInfoApi(params)
- // uni.hideLoading()
- this.loading = false
+ uni.hideLoading()
console.log('resresres持证信息详情--', res)
this.holdCardDetailsList = res.data
},
@@ -196,8 +200,6 @@ export default {
},
/* 持证详情列表点击事件 */
onClickTableTr(id) {
- console.log('id-----人员id', id)
-
// 跳转人员信息页面
uni.navigateTo({ url: `/pages/realName/index/pages/personDetail?idNumber=${id}` })
}
@@ -287,6 +289,7 @@ export default {
width: 90vw;
height: 50vh;
background-color: #fff;
+ overflow: hidden;
.popup-title {
position: relative;
background-color: #3f9dfd;
@@ -294,7 +297,7 @@ export default {
line-height: 100rpx;
text-align: center;
color: #fff;
- font-size: 30rpx;
+ font-size: 38rpx;
.close-icon {
position: absolute;
@@ -307,5 +310,32 @@ export default {
width: 100%;
height: calc(100% - 100rpx);
}
+
+ .table-th {
+ display: flex;
+ view {
+ padding: 5rpx 0;
+ flex: 1;
+ text-align: center;
+ font-size: 32rpx;
+ font-weight: bold;
+ }
+ }
+
+ .table-tr {
+ padding: 8rpx 0;
+ display: flex;
+ border-bottom: 1px solid #ccc;
+ view {
+ padding: 5rpx 0;
+ flex: 1;
+ font-size: 30rpx;
+ text-align: center;
+ }
+ }
+
+ .table-tr view:first-child {
+ text-align: left;
+ }
}
From 107d2455b8f2797cab7964689f20d8a731b58904 Mon Sep 17 00:00:00 2001
From: BianLzhaoMin <11485688+bianliangzhaomin123@user.noreply.gitee.com>
Date: Fri, 18 Oct 2024 15:12:22 +0800
Subject: [PATCH 3/4] =?UTF-8?q?=E5=90=84=E8=B7=B3=E8=BD=AC=E9=80=BB?=
=?UTF-8?q?=E8=BE=91=E5=88=9D=E6=AD=A5=E5=AE=8C=E5=96=84?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../index/components/bar-charts-model.vue | 11 +-
.../components/pie-charts-model-ring-two.vue | 9 +-
.../components/pie-charts-model-ring.vue | 9 +-
.../index/components/pie-charts-model.vue | 11 +-
pages/realName/index/index.vue | 324 ++++++++++++------
5 files changed, 248 insertions(+), 116 deletions(-)
diff --git a/pages/realName/index/components/bar-charts-model.vue b/pages/realName/index/components/bar-charts-model.vue
index 6509fab..db0e866 100644
--- a/pages/realName/index/components/bar-charts-model.vue
+++ b/pages/realName/index/components/bar-charts-model.vue
@@ -1,6 +1,6 @@
-
+
@@ -150,7 +150,7 @@ export default {
categories: ['基建线路', '基建变电', '生产线路', '生成变电', '配网', '其他'],
series: [
{
- name: '目标值',
+ name: '',
data: [constructionLine, infrastructureSubstation, productionLine, productionSubstation, network, other]
}
]
@@ -158,6 +158,13 @@ export default {
this.chartData = JSON.parse(JSON.stringify(data))
}, 500)
})
+ },
+ handleChartClick(index) {
+ // console.log('index', index)
+ const currentIndex = index.currentIndex.index // 获取当前点击的图表索引
+ const currenName = this.chartData.categories[currentIndex]
+ console.log('currenName选中的工程类型', currenName)
+ uni.navigateTo({ url: `/pages/realName/index/pages/project?xxx=${currenName}` })
}
}
}
diff --git a/pages/realName/index/components/pie-charts-model-ring-two.vue b/pages/realName/index/components/pie-charts-model-ring-two.vue
index 50ce55a..58dac3e 100644
--- a/pages/realName/index/components/pie-charts-model-ring-two.vue
+++ b/pages/realName/index/components/pie-charts-model-ring-two.vue
@@ -1,6 +1,6 @@
-
+
@@ -145,6 +145,13 @@ export default {
this.chartData = JSON.parse(JSON.stringify(data))
}, 500)
})
+ },
+ handleChartClick(index) {
+ const { currentIndex } = index // 获取当前点击的图表索引
+ const chartsData = this.chartData.series[0].data
+ const currenRows = chartsData[currentIndex]
+ console.log('currenRows选中的工种类型', currenRows.name)
+ uni.navigateTo({ url: `/pages/realName/index/pages/personList?xxx=${currenRows.name}` })
}
}
}
diff --git a/pages/realName/index/components/pie-charts-model-ring.vue b/pages/realName/index/components/pie-charts-model-ring.vue
index fa11c90..fdfa327 100644
--- a/pages/realName/index/components/pie-charts-model-ring.vue
+++ b/pages/realName/index/components/pie-charts-model-ring.vue
@@ -1,6 +1,6 @@
-
+
@@ -145,6 +145,13 @@ export default {
this.chartData = JSON.parse(JSON.stringify(data))
}, 500)
})
+ },
+ handleChartClick(index) {
+ const { currentIndex } = index // 获取当前点击的图表索引
+ const chartsData = this.chartData.series[0].data
+ const currenRows = chartsData[currentIndex]
+ console.log('currenRows选中的人员类型(这个应该时年龄范围)', currenRows.name)
+ uni.navigateTo({ url: `/pages/realName/index/pages/personList?xxx=${currenRows.name}` })
}
}
}
diff --git a/pages/realName/index/components/pie-charts-model.vue b/pages/realName/index/components/pie-charts-model.vue
index b8c2d61..bf8f631 100644
--- a/pages/realName/index/components/pie-charts-model.vue
+++ b/pages/realName/index/components/pie-charts-model.vue
@@ -80,9 +80,6 @@ export default {
labelBgOpacity: 0.7,
labelFontColor: '#666666'
}
- },
- onClick: e => {
- console.log('eeeee图表点击了---', e)
}
}
}
@@ -137,8 +134,12 @@ export default {
}, 500)
})
},
- handleChartClick() {
- console.log('图表点击-------')
+ handleChartClick(index) {
+ const { currentIndex } = index // 获取当前点击的图表索引
+ const chartsData = this.chartData.series[0].data
+ const currenRows = chartsData[currentIndex]
+ console.log('currenRows选中的工程类型', currenRows.name)
+ uni.navigateTo({ url: `/pages/realName/index/pages/project?xxx=${currenRows.name}` })
}
}
}
diff --git a/pages/realName/index/index.vue b/pages/realName/index/index.vue
index 6ac45df..0be49cf 100644
--- a/pages/realName/index/index.vue
+++ b/pages/realName/index/index.vue
@@ -127,7 +127,7 @@
人员考勤率
-
+
{{ item.progress_title }}
{{ item.progress_proportion }}%
@@ -146,7 +146,7 @@
工程概况
-
+
{{ item.project_title }}
{{ item.project_num }}
@@ -172,17 +172,17 @@
在场人员概况
-
+
{{ ((greenNum / colorAmount) * 100).toFixed(2) }}%
{{ greenNum }}
-
+
{{ ((yellowNum / colorAmount) * 100).toFixed(2) }}%
{{ yellowNum }}
-
+
{{ ((redNum / colorAmount) * 100).toFixed(2) }}%
{{ redNum }}
@@ -196,10 +196,18 @@
男({{ maleNum }})
-
+
-
+
{{ ((femaleNum / sexAmount) * 100).toFixed(2) }}%
女({{ femaleNum }})
@@ -210,7 +218,7 @@
固定、临时人员
-
+
{{ formalPersonNum }}
-
+
-
-
-
-
-
-
-
- 选择工程
-
-
-
- {{item.abbreviation}}
-
-
-
+
+
+
+
+
+
+ 选择工程
+
+
+
+
+
+ {{ item.abbreviation }}
+
+
+
+
@@ -293,10 +319,10 @@ export default {
return {
userId: uni.getStorageSync('userId'),
tabbar: TabbarConfig,
- type:uni.getStorageSync('realNameUser').type,
- subId:uni.getStorageSync('realNameUser').subId,
- showPopup:false,
- proList:[],
+ type: uni.getStorageSync('realNameUser').type,
+ subId: uni.getStorageSync('realNameUser').subId,
+ showPopup: false,
+ proList: [],
msgList: [],
dataOverviewList: [
{
@@ -427,7 +453,9 @@ export default {
maleNum: 0,
femaleNum: 0,
- sexAmount: 0
+ sexAmount: 0,
+
+ colorAmount: 0
// planProNum: 0,
// redPersonNum: 0,
@@ -444,17 +472,19 @@ export default {
console.log('?? ~ mounted ~ mounted-index:')
this.getLogin()
this.getHomePageListData()
- if(this.type.indexOf("4")>-1){//监督端
- this.getPro()
- }
+ if (this.type.indexOf('4') > -1) {
+ //监督端
+ this.getPro()
+ }
},
onShow() {
- if(this.type.indexOf("4")>-1){ //监督端
- let hasChosenPro=uni.getStorageSync('hasChosenPro')
- if(!hasChosenPro){
- this.showPopup=true
- }
- }
+ if (this.type.indexOf('4') > -1) {
+ //监督端
+ let hasChosenPro = uni.getStorageSync('hasChosenPro')
+ if (!hasChosenPro) {
+ this.showPopup = true
+ }
+ }
},
methods: {
getLogin() {
@@ -495,57 +525,57 @@ export default {
}
})
},
-
- //监督端获取工程列表
- getPro(){
- let param={
- id:-1,
- subId:this.subId
- }
- console.log(param)
- uni.request({
- url: config.realAppUrl + '/offLine/getPro',
- method: 'post',
- data: param,
- header: {
- 'Content-Type': 'application/x-www-form-urlencoded',
- Authorization: uni.getStorageSync('realNameToken')
- },
- success: res => {
- console.log(res)
- res = res.data;
- if(res.code==200){
- this.proList = res.data;
- }
- },
- fail: err => {
- console.log(err)
- }
- })
- },
- //展示工程选择弹窗
- leftClick() {
- console.log('返回')
- if(this.type.indexOf("4")>-1){
- this.showPopup=true;
- }
+
+ //监督端获取工程列表
+ getPro() {
+ let param = {
+ id: -1,
+ subId: this.subId
+ }
+ console.log(param)
+ uni.request({
+ url: config.realAppUrl + '/offLine/getPro',
+ method: 'post',
+ data: param,
+ header: {
+ 'Content-Type': 'application/x-www-form-urlencoded',
+ Authorization: uni.getStorageSync('realNameToken')
+ },
+ success: res => {
+ console.log(res)
+ res = res.data
+ if (res.code == 200) {
+ this.proList = res.data
+ }
+ },
+ fail: err => {
+ console.log(err)
+ }
+ })
+ },
+ //展示工程选择弹窗
+ leftClick() {
+ console.log('返回')
+ if (this.type.indexOf('4') > -1) {
+ this.showPopup = true
+ }
+ },
+ //选择工程
+ chosenPro(item) {
+ let obj = uni.getStorageSync('realNameUser')
+ obj.proId = item.id
+ uni.setStorageSync('realNameUser', obj)
+ uni.setStorageSync('hasChosenPro', '1')
+ this.showPopup = false
+ },
+ closePopup() {
+ this.showPopup = false
+ },
+ openFaceScan() {
+ face.open(['a', 'c'], function (e) {
+ face.close()
+ })
},
- //选择工程
- chosenPro(item){
- let obj = uni.getStorageSync('realNameUser')
- obj.proId=item.id
- uni.setStorageSync('realNameUser', obj)
- uni.setStorageSync('hasChosenPro', "1")
- this.showPopup=false;
- },
- closePopup() {
- this.showPopup=false;
- },
- openFaceScan() {
- face.open(['a', 'c'], function (e) {
- face.close()
- })
- },
/* 获取首页数据 */
async getHomePageListData() {
@@ -642,25 +672,105 @@ export default {
onJumpWorkPlan() {
uni.navigateTo({ url: '/pages/realName/workPlan/index' })
},
-
- //数据概览跳转
- godataView(item) {
- console.log(item)
- if(item.data_title=='在建工程'){
- uni.navigateTo({ url: '/pages/realName/index/pages/project' })
- }
- if(item.data_title=='在用分包单位'){
- uni.navigateTo({ url: '/pages/realName/index/pages/subList' })
- }
- if(item.data_title=='在用班组'){
- uni.navigateTo({ url: '/pages/realName/index/pages/teamList' })
- }
- if(item.data_title=='在场人数'){
- uni.navigateTo({ url: '/pages/realName/index/pages/personList' })
- }
-
- },
- },
+
+ //数据概览跳转
+ godataView(item) {
+ console.log(item)
+ if (item.data_title == '在建工程') {
+ uni.navigateTo({ url: '/pages/realName/index/pages/project' })
+ }
+ if (item.data_title == '在用分包单位') {
+ uni.navigateTo({ url: '/pages/realName/index/pages/subList' })
+ }
+ if (item.data_title == '在用班组') {
+ uni.navigateTo({ url: '/pages/realName/index/pages/teamList' })
+ }
+ if (item.data_title == '在场人数') {
+ uni.navigateTo({ url: '/pages/realName/index/pages/personList' })
+ }
+ },
+ /* 人员考勤等跳转 */
+ onJumpPersonList(title) {
+ let params = ''
+ // 跳转人员列表
+ switch (title) {
+ case '在场考勤率':
+ params = '在场考勤率'
+ break
+ case '作业考勤率':
+ params = '作业考勤率'
+ break
+ case '在场人员(固定)':
+ params = '在场人员(固定)'
+ break
+ case '在场人员(临时)':
+ params = '在场人员(临时)'
+ break
+ case '考勤率(固定人员)':
+ params = '考勤率(固定人员)'
+ break
+ case '考勤率(临时人员)':
+ params = '考勤率(临时人员)'
+ break
+ }
+
+ console.log('params路由参数考勤固定等··', params)
+ uni.navigateTo({ url: `/pages/realName/index/pages/personList?xxx=${params}` })
+ },
+ /* 工程概况跳转 */
+ onJumpProjectList(title) {
+ let params = ''
+ // 跳转人员列表
+ switch (title) {
+ case '在建':
+ params = '在建'
+ break
+ case '筹建':
+ params = '筹建'
+ break
+ case '停工':
+ params = '停工'
+ break
+ case '完工':
+ params = '完工'
+ break
+ }
+
+ console.log('params路由参数工程概况', params)
+ uni.navigateTo({ url: `/pages/realName/index/pages/project?xxx=${params}` })
+ },
+ /* 在场人员概况跳转人员信息 */
+ onJumpColorLight(type) {
+ let params = ''
+ // 跳转人员列表
+ switch (type) {
+ case 1:
+ params = '绿灯'
+ break
+ case 2:
+ params = '黄灯'
+ break
+ case 3:
+ params = '红灯'
+ break
+ case 4:
+ params = '男性'
+ break
+ case 5:
+ params = '女性'
+ break
+ case 6:
+ params = '固定人员'
+ break
+ case 7:
+ params = '临时人员'
+ break
+ }
+
+ console.log('params路由参数红黄灯以及性别··和固定、临时', params)
+ uni.navigateTo({ url: `/pages/realName/index/pages/personList?xxx=${params}` })
+ }
+ }
}
From 69c142c35ff8268110e75cd91f3781012d2976c9 Mon Sep 17 00:00:00 2001
From: BianLzhaoMin <11485688+bianliangzhaomin123@user.noreply.gitee.com>
Date: Fri, 18 Oct 2024 16:51:09 +0800
Subject: [PATCH 4/4] =?UTF-8?q?=E6=A0=B7=E5=BC=8F=E7=AD=89=E9=97=AE?=
=?UTF-8?q?=E9=A2=98=E4=BF=AE=E6=94=B9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
pages/realName/workPlan-details/index.vue | 114 ++++++++++++++++++++--
pages/realName/workPlan/index.vue | 11 ++-
2 files changed, 115 insertions(+), 10 deletions(-)
diff --git a/pages/realName/workPlan-details/index.vue b/pages/realName/workPlan-details/index.vue
index e50af56..1f7485a 100644
--- a/pages/realName/workPlan-details/index.vue
+++ b/pages/realName/workPlan-details/index.vue
@@ -24,7 +24,9 @@
- 全部人员
+
+ 全部人员
+
@@ -53,7 +55,12 @@
-
+
{{ item.name }}
@@ -63,7 +70,12 @@
-
+
{{ item.certificateName }}({{ item.certificateNum }})
+
+
+
+
+ {{ item.times }}
+
+
@@ -144,7 +162,10 @@ export default {
holdCardList: [], // 持证信息
holdCardTitle: '',
holdCardDetailsList: [], // 持证信息详情
- standGuardList: [], // 站班信息
+ standGuardList: [
+ { img_src: 'https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/shuijiao.jpg', times: '9:20:06' },
+ { img_src: 'https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg', times: '9:20:06' }
+ ], // 站班信息
contentId: '',
loading: false,
commonParams: {
@@ -153,6 +174,31 @@ export default {
}
}
},
+ computed: {
+ getItemClass() {
+ return index => {
+ const styleIndex = index % 3
+ switch (styleIndex) {
+ case 0:
+ return 'blue-border'
+ case 1:
+ return 'orange-border'
+ case 2:
+ return 'green-border'
+ }
+ }
+ },
+ getPersonStyle() {
+ return item => {
+ const { kqState, userState } = item
+
+ if (userState == 1 && kqState == 1) return 'style_1' // 固定人员 打卡
+ if (userState == 1 && kqState != 1) return 'style_2' // 固定人员 未打卡
+ if (userState != 1 && kqState == 1) return 'style_3' // 临时人员 打卡
+ if (userState != 1 && kqState != 1) return 'style_4' // 临时人员 未打卡
+ }
+ }
+ },
methods: {
leftClick() {
uni.navigateTo({ url: '/pages/realName/workPlan/index' })
@@ -172,6 +218,7 @@ export default {
const response = await getStandGuardImgApi(params)
this.workPersonList = res.data
+ console.log('人员信息---', res.data)
this.holdCardList = res.datac
this.standGuardList = response.data
},
@@ -190,7 +237,7 @@ export default {
})
const res = await getHoldCardInfoApi(params)
uni.hideLoading()
- console.log('resresres持证信息详情--', res)
+ // console.log('resresres持证信息详情--', res)
this.holdCardDetailsList = res.data
},
/* 关闭持证信息弹框 */
@@ -202,6 +249,22 @@ export default {
onClickTableTr(id) {
// 跳转人员信息页面
uni.navigateTo({ url: `/pages/realName/index/pages/personDetail?idNumber=${id}` })
+ },
+ /* 全部人员按钮 */
+ onSearchAllPerson() {
+ this.contentId = ''
+ this.getWorkPersonnelData()
+ },
+ /* 预览图片 */
+ onPreviewImage(index) {
+ uni.previewImage({
+ urls: [
+ 'https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/shuijiao.jpg',
+ 'https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg'
+ ],
+ current: index,
+ loop: true
+ })
}
},
onLoad(options) {
@@ -240,11 +303,27 @@ export default {
view {
width: 18%;
margin: 12rpx 0 12rpx calc(10% / 4);
+ box-sizing: border-box;
color: #fff;
text-align: center;
border-radius: 12rpx;
+ // background-color: #3f9dfd;
+ }
+
+ .style_1 {
background-color: #3f9dfd;
}
+ .style_2 {
+ border: 1px solid #3f9dfd;
+ color: #000;
+ }
+ .style_3 {
+ background-color: #fb1515;
+ }
+ .style_4 {
+ border: 1px solid #fb1515;
+ color: #000;
+ }
}
.work-person view:nth-child(5n + 1) {
@@ -338,4 +417,27 @@ export default {
text-align: left;
}
}
+
+.img-container {
+ width: 100%;
+ display: flex;
+ flex-wrap: wrap;
+
+ view {
+ width: 31%;
+ margin: 12rpx 0 12rpx calc(6% / 2);
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+
+ .image-content {
+ width: 100%;
+ height: 160rpx;
+ }
+ }
+}
+
+.img-container view:nth-child(3n + 1) {
+ margin-left: 0;
+}
diff --git a/pages/realName/workPlan/index.vue b/pages/realName/workPlan/index.vue
index dbf7f77..bdf3440 100644
--- a/pages/realName/workPlan/index.vue
+++ b/pages/realName/workPlan/index.vue
@@ -40,10 +40,11 @@
{{ item.subComName }}
- 可接受风险:{{ item.kjsfx }}
- 低风险:{{ item.dfx }}
- 中风险:{{ item.zfx }}
- 高风险:{{ item.gfx }}
+ 可接受风险:{{ item.kjsfx }}
+ 低风险:{{ item.dfx }}
+ 中风险:{{ item.zfx }}
+ 高风险:{{ item.gfx }}
+ 特高风险:{{ item.tgfx }}
@@ -124,6 +125,8 @@ export default {
success: res => {
this.recordsTotal = res.data.recordsTotal
this.companyInfoList = res.data.data
+
+ console.log('resssss作业计划列表信息', res)
},
fail: err => {}
})