|
@@ -4,36 +4,37 @@
|
|
|
<view class="uni-list">
|
|
|
<view class="container" style="border-bottom: 1px solid #f8f8f8;">
|
|
|
<view>
|
|
|
- 工程类型
|
|
|
- </view>
|
|
|
- <view v-if="this.isEmpty(this.projectType.dictValue)" style="margin-top: 10;"
|
|
|
- @click="pickerShow('gclx',0)">
|
|
|
- <span style="color: darkgray;">请选择工程类型</span>
|
|
|
- <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
|
|
|
+ 工程名称
|
|
|
</view>
|
|
|
- <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('gclx',0)">
|
|
|
- <span style="color: black;">{{projectType.dictLabel}}</span>
|
|
|
+ <!-- <view v-if="this.isEmpty(this.projectName.id)" style="margin-top: 10;"
|
|
|
+ @click="pickerShow('gcmc',0)">
|
|
|
+ <span style="color: darkgray;">请选择工程名称</span>
|
|
|
<image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
|
|
|
+ </view> -->
|
|
|
+ <view class="uni-list-cell-db" style="margin-top: 10;">
|
|
|
+ <span style="color: black;">{{enginName}}</span>
|
|
|
+ <!-- <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image> -->
|
|
|
</view>
|
|
|
</view>
|
|
|
+
|
|
|
</view>
|
|
|
<view class="uni-list">
|
|
|
<view class="container" style="border-bottom: 1px solid #f8f8f8;">
|
|
|
<view>
|
|
|
- 工程名称
|
|
|
- </view>
|
|
|
- <view v-if="this.isEmpty(this.projectName.id)" style="margin-top: 10;"
|
|
|
- @click="pickerShow('gcmc',0)">
|
|
|
- <span style="color: darkgray;">请选择工程名称</span>
|
|
|
- <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
|
|
|
+ 工程类型
|
|
|
</view>
|
|
|
- <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('gcmc',0)">
|
|
|
- <span style="color: black;">{{projectName.name}}</span>
|
|
|
+ <!-- <view v-if="this.isEmpty(this.projectType.dictValue)" style="margin-top: 10;"
|
|
|
+ @click="pickerShow('gclx',0)">
|
|
|
+ <span style="color: darkgray;">请选择工程类型</span>
|
|
|
<image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
|
|
|
+ </view> -->
|
|
|
+ <view class="uni-list-cell-db" style="margin-top: 10;">
|
|
|
+ <span style="color: black;">{{enginType}}</span>
|
|
|
+ <!-- <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image> -->
|
|
|
</view>
|
|
|
</view>
|
|
|
-
|
|
|
</view>
|
|
|
+
|
|
|
<view class="uni-list">
|
|
|
<view class="container" style="border-bottom: 1px solid #f8f8f8;">
|
|
|
|
|
@@ -148,7 +149,7 @@
|
|
|
<view class="uni-list">
|
|
|
<view
|
|
|
style="font-size: 16px;margin-left: 10px;margin-top: 10px;display: flex; justify-content: space-between;margin-bottom: 10px;">
|
|
|
- {{objValue.Label}}
|
|
|
+ {{objValue.title}}
|
|
|
|
|
|
<span
|
|
|
style="color: blue;font-size: 14px; display: flex;justify-content:flex-end; margin-right: 10px;"
|
|
@@ -452,6 +453,10 @@
|
|
|
createTime: '',
|
|
|
infonId: '', //info id
|
|
|
|
|
|
+ enginName: '',
|
|
|
+ enginType: '',
|
|
|
+ enginTitle: '',
|
|
|
+ enginValue: '',
|
|
|
}
|
|
|
},
|
|
|
|
|
@@ -462,27 +467,50 @@
|
|
|
onLoad(options) {
|
|
|
if ('params' in options) {
|
|
|
this.objValue = JSON.parse(decodeURIComponent(options.params));
|
|
|
-
|
|
|
-
|
|
|
+ this.enginId = this.objValue.id;
|
|
|
+ this.enginTitle = this.objValue.title;
|
|
|
+ this.enginValue = this.objValue.value;
|
|
|
}
|
|
|
-
|
|
|
-
|
|
|
+ //根据工程id 获取工程信息
|
|
|
+ uni.showLoading({
|
|
|
+ title: '加载中'
|
|
|
+ })
|
|
|
+ getEngineeringDetails(this.enginId).then(
|
|
|
+ response => {
|
|
|
+ uni.hideLoading();
|
|
|
+ this.enginName=response.data.enginName;
|
|
|
+ this.enginType=response.data.enginType;
|
|
|
+ // this.enginList = response.data
|
|
|
+ this.jlPhoneValue = response.data.supervisionPhone; //监理电话
|
|
|
+ this.jlfzrValue = response.data.supervisionHead; //监理负责人
|
|
|
+ this.jldwValue = response.data.supervisionUnit; //监理单位
|
|
|
+ this.sjPhoneValue = response.data.designPhone; //设计电话
|
|
|
+ this.sjfzrValue = response.data.designHead; //设计负责人
|
|
|
+ this.sjdwValue = response.data.designUnit; //设计单位
|
|
|
+ this.xcfzrValue = response.data.sceneHead; //现场负责人
|
|
|
+ this.xmfzrValue = response.data.projectHead; //项目负责人
|
|
|
+ this.jsdwValue = response.data.constructUnit; //建设单位
|
|
|
+ this.enginId = response.data.id; //工程id
|
|
|
+ this.fileArr = response.data.pics
|
|
|
+ this.createTime = response.data.createTime;
|
|
|
+ //this.infonId = response.data.zEngineeringNodeBoList[0].zEngineeringInfoBoList[0].id
|
|
|
+ this.fileArr.forEach((list, index) => {
|
|
|
+ if (list.picUrl.substring(list.picUrl.length - 3) == 'png' || list.picUrl
|
|
|
+ .substring(list.picUrl.length - 3) == 'jpg' || list.picUrl.substring(list
|
|
|
+ .picUrl.length - 4) == 'jpeg') {
|
|
|
+ this.fileImageArr.push(list.picUrl)
|
|
|
+ }
|
|
|
+ });
|
|
|
+ });
|
|
|
},
|
|
|
methods: {
|
|
|
//判断是否选择
|
|
|
-
|
|
|
isEmpty(str) {
|
|
|
-
|
|
|
return (!str || 0 === str.length);
|
|
|
-
|
|
|
},
|
|
|
-
|
|
|
handleSubmit(e) {
|
|
|
-
|
|
|
this.time = `${e.year}-${e.month}-${e.day} ${e.hour}:${e.minute}:${e.second}`;
|
|
|
-
|
|
|
},
|
|
|
-
|
|
|
//获取当前时间
|
|
|
traversalTime(timestamp) {
|
|
|
//timestamp(时间戳)是整数,否则要parseInt转换
|
|
@@ -495,8 +523,6 @@
|
|
|
let s = time.getSeconds();
|
|
|
return y + '-' + this.addTimes(m) + '-' + this.addTimes(d) + ' ' + this.addTimes(h) + ':' + this.addTimes(
|
|
|
mm) + ':' + this.addTimes(s);
|
|
|
-
|
|
|
-
|
|
|
},
|
|
|
addTimes(m) {
|
|
|
return m < 10 ? '0' + m : m
|
|
@@ -531,22 +557,22 @@
|
|
|
}
|
|
|
|
|
|
} else if (e == 'gclx') { //工程类型
|
|
|
- this.openDict = true;
|
|
|
- getDicts("municipal_engineering").then(response => {
|
|
|
- this.dictOptions = response.data;
|
|
|
- });
|
|
|
+ // this.openDict = true;
|
|
|
+ // getDicts("municipal_engineering").then(response => {
|
|
|
+ // this.dictOptions = response.data;
|
|
|
+ // });
|
|
|
} else if (e == 'gcmc') { //工程名称
|
|
|
- if (this.isEmpty(this.projectType.dictValue)) {
|
|
|
+ // if (this.isEmpty(this.projectType.dictValue)) {
|
|
|
|
|
|
- this.$modal.msg('请选择工程类型')
|
|
|
- return
|
|
|
- }
|
|
|
- this.open = true;
|
|
|
- //请求
|
|
|
- getengineeringNameList(this.projectType.dictValue, "2", null).then(response => {
|
|
|
+ // this.$modal.msg('请选择工程类型')
|
|
|
+ // return
|
|
|
+ // }
|
|
|
+ // this.open = true;
|
|
|
+ // //请求
|
|
|
+ // getengineeringNameList(this.projectType.dictValue, "2", null).then(response => {
|
|
|
|
|
|
- this.selectList = response.data;
|
|
|
- });
|
|
|
+ // this.selectList = response.data;
|
|
|
+ // });
|
|
|
|
|
|
|
|
|
}
|
|
@@ -807,37 +833,37 @@
|
|
|
this.czggslList[this.SelectIndex].gg.id = this.specificationValue.id
|
|
|
this.czggslList[this.SelectIndex].gg.name = this.specificationValue.name
|
|
|
} else if (this.type == 'gcmc') {
|
|
|
- this.projectName = item
|
|
|
- //根据工程id 获取工程信息
|
|
|
- uni.showLoading({
|
|
|
- title: '加载中'
|
|
|
- })
|
|
|
- getEngineeringDetails(item.id).then(response => {
|
|
|
- uni.hideLoading();
|
|
|
- // this.enginList = response.data
|
|
|
- this.jlPhoneValue = response.data.supervisionPhone; //监理电话
|
|
|
- this.jlfzrValue = response.data.supervisionHead; //监理负责人
|
|
|
- this.jldwValue = response.data.supervisionUnit; //监理单位
|
|
|
- this.sjPhoneValue = response.data.designPhone; //设计电话
|
|
|
- this.sjfzrValue = response.data.designHead; //设计负责人
|
|
|
- this.sjdwValue = response.data.designUnit; //设计单位
|
|
|
- this.xcfzrValue = response.data.sceneHead; //现场负责人
|
|
|
- this.xmfzrValue = response.data.projectHead; //项目负责人
|
|
|
- this.jsdwValue = response.data.constructUnit; //建设单位
|
|
|
- this.enginId = response.data.id; //工程id
|
|
|
- this.fileArr = response.data.pics
|
|
|
- this.createTime = response.data.createTime;
|
|
|
- //this.infonId = response.data.zEngineeringNodeBoList[0].zEngineeringInfoBoList[0].id
|
|
|
- this.fileArr.forEach((list, index) => {
|
|
|
- if (list.picUrl.substring(list.picUrl.length - 3) == 'png' || list.picUrl
|
|
|
- .substring(list.picUrl.length - 3) == 'jpg' || list.picUrl.substring(list
|
|
|
- .picUrl.length - 4) == 'jpeg') {
|
|
|
- this.fileImageArr.push(list.picUrl)
|
|
|
- }
|
|
|
-
|
|
|
-
|
|
|
- });
|
|
|
- });
|
|
|
+ // this.projectName = item
|
|
|
+ // //根据工程id 获取工程信息
|
|
|
+ // uni.showLoading({
|
|
|
+ // title: '加载中'
|
|
|
+ // })
|
|
|
+ // getEngineeringDetails(item.id).then(response => {
|
|
|
+ // uni.hideLoading();
|
|
|
+ // // this.enginList = response.data
|
|
|
+ // this.jlPhoneValue = response.data.supervisionPhone; //监理电话
|
|
|
+ // this.jlfzrValue = response.data.supervisionHead; //监理负责人
|
|
|
+ // this.jldwValue = response.data.supervisionUnit; //监理单位
|
|
|
+ // this.sjPhoneValue = response.data.designPhone; //设计电话
|
|
|
+ // this.sjfzrValue = response.data.designHead; //设计负责人
|
|
|
+ // this.sjdwValue = response.data.designUnit; //设计单位
|
|
|
+ // this.xcfzrValue = response.data.sceneHead; //现场负责人
|
|
|
+ // this.xmfzrValue = response.data.projectHead; //项目负责人
|
|
|
+ // this.jsdwValue = response.data.constructUnit; //建设单位
|
|
|
+ // this.enginId = response.data.id; //工程id
|
|
|
+ // this.fileArr = response.data.pics
|
|
|
+ // this.createTime = response.data.createTime;
|
|
|
+ // //this.infonId = response.data.zEngineeringNodeBoList[0].zEngineeringInfoBoList[0].id
|
|
|
+ // this.fileArr.forEach((list, index) => {
|
|
|
+ // if (list.picUrl.substring(list.picUrl.length - 3) == 'png' || list.picUrl
|
|
|
+ // .substring(list.picUrl.length - 3) == 'jpg' || list.picUrl.substring(list
|
|
|
+ // .picUrl.length - 4) == 'jpeg') {
|
|
|
+ // this.fileImageArr.push(list.picUrl)
|
|
|
+ // }
|
|
|
+
|
|
|
+
|
|
|
+ // });
|
|
|
+ // });
|
|
|
}
|
|
|
},
|
|
|
//关闭弹窗
|
|
@@ -930,16 +956,19 @@
|
|
|
},
|
|
|
//历史
|
|
|
history() {
|
|
|
- if (this.isEmpty(this.projectType.dictValue)) {
|
|
|
- this.$modal.msg('请选择工程类型')
|
|
|
- return
|
|
|
- }
|
|
|
- if (this.isEmpty(this.projectName.id)) {
|
|
|
- this.$modal.msg('请选择工程名称')
|
|
|
+ // if (this.isEmpty(this.projectType.dictValue)) {
|
|
|
+ // this.$modal.msg('请选择工程类型')
|
|
|
+ // return
|
|
|
+ // }
|
|
|
+ // if (this.isEmpty(this.projectName.id)) {
|
|
|
+ // this.$modal.msg('请选择工程名称')
|
|
|
+ // return
|
|
|
+ // }
|
|
|
+ if (this.isEmpty(this.enginId)) {
|
|
|
+ this.$modal.msg('暂无工程信息')
|
|
|
return
|
|
|
}
|
|
|
getEngineeringHistoryList(this.enginId, this.objValue.value).then(response => {
|
|
|
-
|
|
|
this.historyList = response.data
|
|
|
if (response.data.zEngineeringNodeBo != null && response.data.zEngineeringNodeBo
|
|
|
.zEngineeringInfoBoList != '') {
|
|
@@ -952,19 +981,15 @@
|
|
|
},
|
|
|
|
|
|
submit() {
|
|
|
-
|
|
|
-
|
|
|
- if (this.isEmpty(this.projectType.dictValue)) {
|
|
|
- this.$modal.msg('请选择工程类型')
|
|
|
- return
|
|
|
- }
|
|
|
- if (this.isEmpty(this.projectName.id)) {
|
|
|
- this.$modal.msg('请选择工程名称')
|
|
|
- return
|
|
|
- }
|
|
|
-
|
|
|
-
|
|
|
- if (this.objValue.Label == '焊接、防腐' || this.objValue.Label == '下管' || this.objValue.Label == ' 沟下连头') {
|
|
|
+ // if (this.isEmpty(this.projectType.dictValue)) {
|
|
|
+ // this.$modal.msg('请选择工程类型')
|
|
|
+ // return
|
|
|
+ // }
|
|
|
+ // if (this.isEmpty(this.projectName.id)) {
|
|
|
+ // this.$modal.msg('请选择工程名称')
|
|
|
+ // return
|
|
|
+ // }
|
|
|
+ if (this.objValue.title == '焊接、防腐' || this.objValue.title == '下管' || this.objValue.title == ' 沟下连头') {
|
|
|
try {
|
|
|
this.czggslList.forEach((list) => {
|
|
|
if (this.isEmpty(list.cz.id)) {
|
|
@@ -977,16 +1002,13 @@
|
|
|
if (this.isEmpty(list.gg.id)) {
|
|
|
this.$modal.msg('规格不能为空')
|
|
|
throw new Error('End Loop')
|
|
|
-
|
|
|
}
|
|
|
|
|
|
-
|
|
|
if (this.isEmpty(list.sl.inputIntegerNumberValue)) {
|
|
|
this.$modal.msg("请输入米数")
|
|
|
throw new Error('End Loop')
|
|
|
}
|
|
|
|
|
|
-
|
|
|
})
|
|
|
} catch (e) {
|
|
|
if (e.message === 'End Loop') throw e
|
|
@@ -1005,8 +1027,7 @@
|
|
|
|
|
|
}
|
|
|
|
|
|
-
|
|
|
- if (this.objValue.Label == '回填、撤场') {
|
|
|
+ if (this.objValue.title == '回填、撤场') {
|
|
|
if (this.imgHtqArr.length <= 0 && this.imgJspsArr.length <= 0 && this.imgHthArr.length <= 0) {
|
|
|
this.$modal.msg('请上传照片')
|
|
|
return
|