|
@@ -47,7 +47,7 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
<view class="uni-list">
|
|
|
- <view class="container">
|
|
|
+ <view class="container" style="margin-bottom: 10px;">
|
|
|
<view class="uni-list-cell-left">
|
|
|
楼栋
|
|
|
</view>
|
|
@@ -74,27 +74,7 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
- <view class="uni-list">
|
|
|
- <view class="container">
|
|
|
- <view class="uni-list-cell-left">
|
|
|
- 房间
|
|
|
- </view>
|
|
|
- <view v-if="this.isEmpty(this.FJValue.id)" class="uni-list-cell-db" style="margin-top: 10;"
|
|
|
- @click="pickerShow('fj')">
|
|
|
- <span style="color: darkgray;">请选择房间</span>
|
|
|
- </view>
|
|
|
- <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('fj')">
|
|
|
- <span style="color: black;">{{FJValue.name}}</span>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- <view class="container">
|
|
|
|
|
|
- <view class="title">是否按照施工图纸施工</view>
|
|
|
- <span style="color: black;">{{this.form}}</span>
|
|
|
- <switch style="transform: scale(0.6,0.6);" @change="switchChange" checked="isChick" />
|
|
|
-
|
|
|
- </view>
|
|
|
|
|
|
<SelectPicker :list="selectList" @change="changeSelect" v-if="open" @close="close" titleKey="name"
|
|
|
subtitleKey="id" v-model="name"></SelectPicker>
|
|
@@ -103,124 +83,62 @@
|
|
|
<SelectPicker :list="dictOptions" @change="changeSelectDict" v-if="openDict" @close="closeDict"
|
|
|
titleKey="dictLabel" subtitleKey="dictValue" v-model="dictLabel"></SelectPicker>
|
|
|
</view>
|
|
|
- <!--拆旧管-->
|
|
|
+
|
|
|
<view class="background">
|
|
|
- <view v-if="objValue.enginClassValue=='拆旧管'">
|
|
|
+ <view>
|
|
|
<view class="uni-list">
|
|
|
<view style="font-size: 16px;margin-left: 10px;margin-top: 10px;">
|
|
|
- 拆旧管
|
|
|
+ {{objValue.enginClassValue}}
|
|
|
|
|
|
<span
|
|
|
style="color: blue;font-size: 14px; display: flex;justify-content:flex-end; margin-right: 15px;"
|
|
|
@click="history">历史</span>
|
|
|
</view>
|
|
|
-
|
|
|
- <view class="container" style="margin-bottom: 20PX;">
|
|
|
+ <view class="container">
|
|
|
|
|
|
<view>
|
|
|
- 腐蚀等级
|
|
|
- </view>
|
|
|
- <view v-if="this.isEmpty(this.LevelValue.dictValue)" style="margin-top: 10;"
|
|
|
- @click="pickerShow('fsdj')">
|
|
|
- <span style="color: darkgray;">请选择腐蚀等级</span>
|
|
|
+ 施工时间
|
|
|
</view>
|
|
|
- <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('fsdj')">
|
|
|
- <span style="color: black;">{{LevelValue.dictLabel}}</span>
|
|
|
+ <view style="margin-top: 10;" @click="openDatetimePicker('sg')">
|
|
|
+ <span style="color: black;">{{time}}</span>
|
|
|
</view>
|
|
|
</view>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- <!--立杠-->
|
|
|
- <view v-else-if="objValue.enginClassValue=='立杠'">
|
|
|
- <view class="uni-list" style="margin-bottom: 20px;">
|
|
|
- <view style="font-size: 16px;margin-left: 10px;margin-top: 10px;">
|
|
|
- 立杠
|
|
|
-
|
|
|
- <span
|
|
|
- style="color: blue;font-size: 14px; display: flex;justify-content:flex-end; margin-right: 15px;"
|
|
|
- @click="history">历史</span>
|
|
|
- </view>
|
|
|
|
|
|
- <view class="container">
|
|
|
+ <view class="container" v-if="objValue.enginClassValue=='回填'">
|
|
|
|
|
|
<view>
|
|
|
- 材 质
|
|
|
+ 回填时间
|
|
|
</view>
|
|
|
- <view v-if="this.isEmpty(this.materialValue.id)" style="margin-top: 10;"
|
|
|
- @click="pickerShow('cz')">
|
|
|
- <span style="color: darkgray;">请选择材质</span>
|
|
|
- </view>
|
|
|
- <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('cz')">
|
|
|
- <span style="color: black;">{{materialValue.name}}</span>
|
|
|
+ <view style="margin-top: 10;" @click="openDatetimePicker('ht')">
|
|
|
+ <span style="color: black;">{{BackfillingTime ? BackfillingTime:'请选择回填时间'}}</span>
|
|
|
</view>
|
|
|
</view>
|
|
|
- <view class="container">
|
|
|
+ <view class="container" v-else-if="objValue.enginClassValue=='打压'">
|
|
|
|
|
|
<view>
|
|
|
- 规 格
|
|
|
+ 分段打压是否合格
|
|
|
</view>
|
|
|
- <view v-if="this.isEmpty(this.specificationValue.id)" style="margin-top: 10;"
|
|
|
- @click="pickerShow('gg')">
|
|
|
- <span style="color: darkgray;">请选择规格</span>
|
|
|
+ <view v-if="this.isEmpty(this.isOkValue)" style="margin-top: 10;" @click="showActionsheet()">
|
|
|
+ <span style="color: darkgray;">请选择分段打压是否合格</span>
|
|
|
</view>
|
|
|
- <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('gg')">
|
|
|
- <span style="color: black;">{{specificationValue.name}}</span>
|
|
|
+ <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="showActionsheet()">
|
|
|
+ <span style="color: black;">{{isOkLabel}}</span>
|
|
|
</view>
|
|
|
</view>
|
|
|
<view class="container">
|
|
|
-
|
|
|
- <text>数 量</text>
|
|
|
- <input class="uni-input" type="number" v-model="inputNumberValue" placeholder="请填写数量"
|
|
|
- maxlength="11" style="margin-left: 10px;text-align: right;"></input>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- <!--挂表-->
|
|
|
- <view v-else-if="objValue.enginClassValue=='挂表'">
|
|
|
- <view class="uni-list" style="margin-bottom: 20px;">
|
|
|
- <view style="font-size: 16px;margin-left: 10px;margin-top: 10px;">
|
|
|
- 挂表
|
|
|
-
|
|
|
- <span
|
|
|
- style="color: blue;font-size: 14px; display: flex;justify-content:flex-end; margin-right: 15px;"
|
|
|
- @click="history">历史</span>
|
|
|
- </view>
|
|
|
-
|
|
|
- <view class="container">
|
|
|
-
|
|
|
- <view>
|
|
|
- 品 牌
|
|
|
- </view>
|
|
|
- <view v-if="this.isEmpty(this.brandValue.dictValue)" style="margin-top: 10;"
|
|
|
- @click="pickerShow('brand')">
|
|
|
- <span style="color: darkgray;">请选择品牌</span>
|
|
|
- </view>
|
|
|
- <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('brand')">
|
|
|
- <span style="color: black;">{{brandValue.dictLabel}}</span>
|
|
|
+ <view class="uni-common-mt" style="width: 100%;">
|
|
|
+ <text class="uni-title uni-common-pl">施工内容</text>
|
|
|
+ <view style="width: 100%;padding-right: 20rpx;box-sizing: border-box;">
|
|
|
+ <textarea class="textarea" placeholder="请输入施工内容" maxlength="255"
|
|
|
+ placeholder-style="padding: 10rpx;"
|
|
|
+ style="width: 100%;height: 100%;border: 1rpx solid #cccccc; border-radius: 15rpx;padding: 10rpx;line-height:normal;"
|
|
|
+ auto-height v-model="projectContent"></textarea>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
</view>
|
|
|
|
|
|
<view class="container">
|
|
|
|
|
|
- <text>数 量</text>
|
|
|
- <input class="uni-input" type="number" v-model="inputNumberValue" placeholder="请填写数量"
|
|
|
- maxlength="11" style="margin-left: 10px;text-align: right;"></input>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- <!--表后管-->
|
|
|
- <view v-else-if="objValue.enginClassValue=='表后管'">
|
|
|
- <view class="uni-list" style="margin-bottom: 20px;">
|
|
|
- <view style="font-size: 16px;margin-left: 10px;margin-top: 10px;">
|
|
|
- 表后管
|
|
|
-
|
|
|
- <span
|
|
|
- style="color: blue;font-size: 14px; display: flex;justify-content:flex-end; margin-right: 15px;"
|
|
|
- @click="history">历史</span>
|
|
|
- </view>
|
|
|
-
|
|
|
- <view class="container">
|
|
|
-
|
|
|
<view>
|
|
|
材 质
|
|
|
</view>
|
|
@@ -251,100 +169,40 @@
|
|
|
<input class="uni-input" type="number" v-model="inputNumberValue" placeholder="请填写数量"
|
|
|
maxlength="11" style="margin-left: 10px;text-align: right;"></input>
|
|
|
</view>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- <!--阀管-->
|
|
|
- <view v-else-if="objValue.enginClassValue=='阀管'">
|
|
|
- <view class="uni-list" style="margin-bottom: 20px;">
|
|
|
- <view style="font-size: 16px;margin-left: 10px;margin-top: 10px;">
|
|
|
- 阀管
|
|
|
+ <!-- <view class="container">
|
|
|
|
|
|
- <span
|
|
|
- style="color: blue;font-size: 14px; display: flex;justify-content:flex-end; margin-right: 15px;"
|
|
|
- @click="history">历史</span>
|
|
|
+ <text>负责人</text>
|
|
|
+ <text>{{user.nickName}}</text>
|
|
|
</view>
|
|
|
<view class="container">
|
|
|
|
|
|
- <view>
|
|
|
- 上门类型
|
|
|
- </view>
|
|
|
- <view v-if="this.isEmpty(this.doorValue.dictValue)" style="margin-top: 10;"
|
|
|
- @click="pickerShow('door')">
|
|
|
- <span style="color: darkgray;">请选择上门类型</span>
|
|
|
- </view>
|
|
|
- <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('door')">
|
|
|
- <span style="color: black;">{{doorValue.dictLabel}}</span>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- <view class="container">
|
|
|
-
|
|
|
- <view>
|
|
|
- 自闭阀类型
|
|
|
- </view>
|
|
|
- <view v-if="this.isEmpty(this.SelfClosValve.dictValue)" style="margin-top: 10;"
|
|
|
- @click="pickerShow('zbf')">
|
|
|
- <span style="color: darkgray;">请选择自闭阀类型</span>
|
|
|
- </view>
|
|
|
- <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('zbf')">
|
|
|
- <span style="color: black;">{{SelfClosValve.dictLabel}}</span>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- <view class="container">
|
|
|
-
|
|
|
- <view>
|
|
|
- 材 质
|
|
|
- </view>
|
|
|
- <view v-if="this.isEmpty(this.materialValue.id)" style="margin-top: 10;"
|
|
|
- @click="pickerShow('cz')">
|
|
|
- <span style="color: darkgray;">请选择材质</span>
|
|
|
- </view>
|
|
|
- <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('cz')">
|
|
|
- <span style="color: black;">{{materialValue.name}}</span>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- <view class="container">
|
|
|
-
|
|
|
- <view>
|
|
|
- 规 格
|
|
|
- </view>
|
|
|
- <view v-if="this.isEmpty(this.specificationValue.id)" style="margin-top: 10;"
|
|
|
- @click="pickerShow('gg')">
|
|
|
- <span style="color: darkgray;">请选择规格</span>
|
|
|
- </view>
|
|
|
- <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('gg')">
|
|
|
- <span style="color: black;">{{specificationValue.name}}</span>
|
|
|
- </view>
|
|
|
- </view>
|
|
|
- <view class="container">
|
|
|
-
|
|
|
- <text>数 量</text>
|
|
|
- <input class="uni-input" type="number" v-model="inputNumberValue" placeholder="请填写数量"
|
|
|
- maxlength="11" style="margin-left: 10px;text-align: right;"></input>
|
|
|
- </view>
|
|
|
+ <text>负责人联系电话</text>
|
|
|
+ <text>{{user.phonenumber}}</text>
|
|
|
+ </view> -->
|
|
|
</view>
|
|
|
- </view>
|
|
|
- <view class="align-items" style="margin-top: 20px;margin-bottom: 20px;">
|
|
|
- <view class="container" style="color: gainsboro;">*请上传照片</view>
|
|
|
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px; margin-left: 10px;">
|
|
|
- <image src="/static/images/chooseimg.png" mode=""
|
|
|
- style="width: 100rpx; height: 100rpx; margin: 0 12rpx;; " @click="choose()"></image>
|
|
|
- <view v-for="(item,index) in imgArr" :key="index" style="position: relative;">
|
|
|
- <view
|
|
|
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' ">
|
|
|
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
|
|
|
- @click="showPhoto(index)">
|
|
|
- </image>
|
|
|
- </view>
|
|
|
- <view v-else>
|
|
|
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
|
|
|
- </view>
|
|
|
- <view @click="remove(index)"
|
|
|
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
|
|
|
- <uni-icons type="close" color="darkgray" size="18"></uni-icons>
|
|
|
+
|
|
|
+ <view class="align-items" style="margin-top: 20px;margin-bottom: 20px;">
|
|
|
+ <view class="container" style="color: gainsboro;">*请上传照片</view>
|
|
|
+ <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px; margin-left: 10px;">
|
|
|
+ <image src="/static/images/chooseimg.png" mode=""
|
|
|
+ style="width: 100rpx; height: 100rpx; margin: 0 12rpx;; " @click="choose()"></image>
|
|
|
+ <view v-for="(item,index) in imgArr" :key="index" style="position: relative;">
|
|
|
+ <view
|
|
|
+ v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' ">
|
|
|
+ <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
|
|
|
+ @click="showPhoto(index)">
|
|
|
+ </image>
|
|
|
+ </view>
|
|
|
+ <view v-else>
|
|
|
+ <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
|
|
|
+ </view>
|
|
|
+ <view @click="remove(index)"
|
|
|
+ style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
|
|
|
+ <uni-icons type="close" color="darkgray" size="18"></uni-icons>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
-
|
|
|
</view>
|
|
|
</view>
|
|
|
<view class="action-btn">
|
|
@@ -352,6 +210,8 @@
|
|
|
</view>
|
|
|
|
|
|
<bottom-sheet ref="refShare" :data="historyList"></bottom-sheet>
|
|
|
+ <yt-dateTimePicker ref="myPicker" @submit="handleSubmit" :start-year="2024" :end-year="2099"
|
|
|
+ :time-hide="[true, true, true, true, true, true]" :time-label="['年', '月', '日', '时', '分', '秒']" />
|
|
|
</view>
|
|
|
</template>
|
|
|
|
|
@@ -369,7 +229,6 @@
|
|
|
getAreaList,
|
|
|
getBuildingList,
|
|
|
getUnitList,
|
|
|
- getHousesList,
|
|
|
addTearOldPipe,
|
|
|
getEnginMaterialQualityList,
|
|
|
getEnginSpecificationsList,
|
|
@@ -379,12 +238,15 @@
|
|
|
import {
|
|
|
getToken
|
|
|
} from '../../../utils/auth';
|
|
|
+ import {
|
|
|
+ getUserProfile
|
|
|
+ } from "@/api/system/user"
|
|
|
|
|
|
export default {
|
|
|
components: {
|
|
|
SelectPicker,
|
|
|
uniIcons,
|
|
|
- bottomSheet
|
|
|
+ bottomSheet,
|
|
|
},
|
|
|
data() {
|
|
|
|
|
@@ -392,6 +254,15 @@
|
|
|
headers: {
|
|
|
Authorization: "Bearer " + getToken()
|
|
|
},
|
|
|
+ user: {
|
|
|
+ nickName: "",
|
|
|
+ phonenumber: "",
|
|
|
+ email: "",
|
|
|
+ sex: ""
|
|
|
+ },
|
|
|
+ startDate: '2022-02-04',
|
|
|
+ endDate: '2025-02-04',
|
|
|
+ mode: 4,
|
|
|
type: '',
|
|
|
open: false,
|
|
|
objValue: '', //上一页面传过来的值 新增接口用
|
|
@@ -403,11 +274,17 @@
|
|
|
XZQValue: {},
|
|
|
projectValue: {},
|
|
|
LevelValue: {},
|
|
|
+ isOkValue: '', //分段打压是否合格
|
|
|
+ isOkLabel: '', //分段打压是否合格label
|
|
|
LDValue: {},
|
|
|
DYValue: {},
|
|
|
FJValue: {},
|
|
|
- FSValue: {},
|
|
|
+ time: '', //施工时间
|
|
|
+ timeType: '', //时间类型
|
|
|
+ BackfillingTime: '', //回填时间
|
|
|
+ showTime: false,
|
|
|
specificationValue: {}, //规格
|
|
|
+ projectContent: '', //施工内容
|
|
|
materialValue: {}, //材质
|
|
|
brandValue: {}, //品牌
|
|
|
doorValue: {}, //上门类型
|
|
@@ -415,11 +292,8 @@
|
|
|
materialList: '', //材质list
|
|
|
XQList: '',
|
|
|
LDList: '',
|
|
|
- DYList: '',
|
|
|
- FJList: '',
|
|
|
progress: 0, //上传图片进度百分比
|
|
|
loading: false,
|
|
|
- isCheck: true, //是否按照施工图纸施工
|
|
|
inputNumberValue: '',
|
|
|
title: '',
|
|
|
historyList: {} //历史数据
|
|
@@ -428,20 +302,20 @@
|
|
|
},
|
|
|
|
|
|
created() {
|
|
|
-
|
|
|
+ this.getUser();
|
|
|
+ this.time = this.traversalTime(new Date().getTime()) //在data里定义变量-nowTime
|
|
|
},
|
|
|
|
|
|
onLoad(options) {
|
|
|
if ('params' in options) {
|
|
|
this.objValue = JSON.parse(decodeURIComponent(options.params));
|
|
|
+ if (this.objValue.enginType == `old_renovation`) {
|
|
|
+ this.title = '旧改工程-架空'
|
|
|
|
|
|
- if (this.objValue.enginType == `old_renovation` && this.objValue.enginClassification == 'indoor_engin') {
|
|
|
- this.title = '旧改工程-室内'
|
|
|
-
|
|
|
- } else {
|
|
|
- this.title = '新建工程-室内'
|
|
|
-
|
|
|
+ } else if (this.objValue.enginType == `new_built`) {
|
|
|
+ this.title = '新建工程-架空'
|
|
|
}
|
|
|
+
|
|
|
uni.setNavigationBarTitle({
|
|
|
title: this.title
|
|
|
})
|
|
@@ -450,6 +324,48 @@
|
|
|
|
|
|
},
|
|
|
methods: {
|
|
|
+ getUser() {
|
|
|
+ getUserProfile().then(response => {
|
|
|
+ this.user = response.data.user
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 打开picker
|
|
|
+ openDatetimePicker(type) {
|
|
|
+ this.timeType = type;
|
|
|
+ this.$refs.myPicker.show();
|
|
|
+ },
|
|
|
+
|
|
|
+ // 关闭picker
|
|
|
+ closeDatetimePicker() {
|
|
|
+ this.$refs.myPicker.hide();
|
|
|
+ },
|
|
|
+
|
|
|
+ handleSubmit(e) {
|
|
|
+ if (this.timeType == 'ht') {
|
|
|
+ this.BackfillingTime = `${e.year}-${e.month}-${e.day} ${e.hour}:${e.minute}:${e.second}`;
|
|
|
+ } else {
|
|
|
+ this.time = `${e.year}-${e.month}-${e.day} ${e.hour}:${e.minute}:${e.second}`;
|
|
|
+ }
|
|
|
+ },
|
|
|
+
|
|
|
+ //获取当前时间
|
|
|
+ traversalTime(timestamp) {
|
|
|
+ //timestamp(时间戳)是整数,否则要parseInt转换
|
|
|
+ let time = new Date(timestamp);
|
|
|
+ let y = time.getFullYear();
|
|
|
+ let m = time.getMonth() + 1;
|
|
|
+ let d = time.getDate();
|
|
|
+ let h = time.getHours();
|
|
|
+ let mm = time.getMinutes();
|
|
|
+ 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
|
|
|
+ },
|
|
|
//判断是否选择
|
|
|
|
|
|
isEmpty(str) {
|
|
@@ -627,26 +543,39 @@
|
|
|
|
|
|
},
|
|
|
})
|
|
|
+
|
|
|
},
|
|
|
- pickerShow(e) {
|
|
|
- this.type = e; //赋值类型
|
|
|
- if (e == 'door') { //上门类型
|
|
|
- this.openDict = true;
|
|
|
- getDicts("visit_type").then(response => {
|
|
|
- this.dictOptions = response.data;
|
|
|
- });
|
|
|
- } else if (e == 'zbf') { //自闭阀类型
|
|
|
- this.openDict = true;
|
|
|
- getDicts("self_closing_valve_type").then(response => {
|
|
|
- this.dictOptions = response.data;
|
|
|
+
|
|
|
+ showActionsheet() {
|
|
|
+ //分段打压是否合格
|
|
|
+
|
|
|
+ getDicts("sys_yes_no").then(response => {
|
|
|
+
|
|
|
+ this.dictOptions = response.data;
|
|
|
+ let array = [];
|
|
|
+ this.dictOptions.forEach((item, index) => {
|
|
|
+ array.push(item.dictLabel)
|
|
|
+
|
|
|
});
|
|
|
- } else if (e == 'brand') { //品牌
|
|
|
- this.openDict = true;
|
|
|
- getDicts("brand").then(response => {
|
|
|
- this.dictOptions = response.data;
|
|
|
+
|
|
|
+ uni.showActionSheet({
|
|
|
+ itemList: array,
|
|
|
+ success: (res) => {
|
|
|
+ // console.log('选择了第' + (res.tapIndex + 1) + '个选项');
|
|
|
+ // console.log(this.dictOptions[res.tapIndex].dictValue)
|
|
|
+ this.isOkValue = this.dictOptions[res.tapIndex].dictValue;
|
|
|
+ this.isOkLabel = this.dictOptions[res.tapIndex].dictLabel;
|
|
|
+ },
|
|
|
+ fail: (err) => {
|
|
|
+ console.log('弹窗取消');
|
|
|
+ }
|
|
|
});
|
|
|
|
|
|
- } else if (e == 'cz') { //材质
|
|
|
+ });
|
|
|
+ },
|
|
|
+ pickerShow(e) {
|
|
|
+ this.type = e; //赋值类型
|
|
|
+ if (e == 'cz') { //材质
|
|
|
this.open = true;
|
|
|
getEnginMaterialQualityList("民用工程").then(response => {
|
|
|
this.selectList = response.data;
|
|
@@ -662,14 +591,6 @@
|
|
|
|
|
|
}
|
|
|
|
|
|
- } else if (e == 'fsdj') {
|
|
|
- //腐蚀等级
|
|
|
- this.openDict = true;
|
|
|
- //腐蚀等级
|
|
|
- getDicts("corrosion_level").then(response => {
|
|
|
- this.dictOptions = response.data;
|
|
|
- });
|
|
|
-
|
|
|
} else if (e == 'gczq') { //工程周期
|
|
|
this.openDict = true;
|
|
|
getDicts("engin_cycle").then(response => {
|
|
@@ -713,33 +634,16 @@
|
|
|
this.open = true;
|
|
|
this.selectList = this.DYList;
|
|
|
}
|
|
|
- } else if (e == 'fj') { //房间
|
|
|
- if (this.isEmpty(this.DYValue.id)) {
|
|
|
- this.$modal.msg('请选择单元')
|
|
|
-
|
|
|
- } else {
|
|
|
- this.open = true;
|
|
|
- this.selectList = this.FJList;
|
|
|
- }
|
|
|
}
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
- switchChange(e) {
|
|
|
- //'switch 发生 change 事件,携带值为', e.detail.value)
|
|
|
- this.isCheck = e.detail.value;
|
|
|
- },
|
|
|
+
|
|
|
changeSelectDict(item, index) {
|
|
|
this.openDict = false;
|
|
|
- if (this.type == 'door') {
|
|
|
- this.doorValue = item
|
|
|
-
|
|
|
- } else if (this.type == 'zbf') {
|
|
|
- this.SelfClosValve = item
|
|
|
-
|
|
|
- } else if (this.type == 'brand') {
|
|
|
- this.brandValue = item
|
|
|
+ if (this.type == 'isok') {
|
|
|
+ this.isOkValue = item
|
|
|
|
|
|
} else if (this.type == 'gczq') {
|
|
|
this.projectValue = item
|
|
@@ -751,12 +655,10 @@
|
|
|
this.XQValue = ''; //重置小区数据
|
|
|
this.LDValue = ''; //重置楼栋数据
|
|
|
this.DYValue = ''; //重置单元数据
|
|
|
- this.FJValue = ''; //重置房间数据
|
|
|
+
|
|
|
getAreaList(item.dictValue).then(res => {
|
|
|
this.XQList = res.data;
|
|
|
})
|
|
|
- } else {
|
|
|
- this.LevelValue = item;
|
|
|
}
|
|
|
},
|
|
|
changeSelect(item, index) {
|
|
@@ -793,18 +695,10 @@
|
|
|
this.DYList = res.data
|
|
|
// console.log("单元=", res)
|
|
|
})
|
|
|
+
|
|
|
} else if (this.type == 'dy') {
|
|
|
this.DYValue = item;
|
|
|
- //根据单元数据 获取房间数据
|
|
|
- this.FJValue = ''; //重置房间数据
|
|
|
- getHousesList(item.id).then(res => {
|
|
|
- this.FJList = res.data
|
|
|
- // console.log("房间=", res)
|
|
|
- })
|
|
|
- } else if (this.type == 'fj') {
|
|
|
- this.FJValue = item;
|
|
|
}
|
|
|
-
|
|
|
},
|
|
|
//关闭弹窗
|
|
|
close(e) {
|
|
@@ -819,252 +713,104 @@
|
|
|
|
|
|
if (this.isEmpty(this.projectValue.dictValue)) {
|
|
|
this.$modal.msg("请选择工程周期")
|
|
|
- } else if (this.isEmpty(this.XZQValue.dictValue)) {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (this.isEmpty(this.XZQValue.dictValue)) {
|
|
|
this.$modal.msg("请选择行政区")
|
|
|
- } else if (this.isEmpty(this.XQValue.id)) {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (this.isEmpty(this.XQValue.id)) {
|
|
|
this.$modal.msg("请选择小区")
|
|
|
- } else if (this.isEmpty(this.LDValue.id)) {
|
|
|
- this.$modal.msg("请选择楼栋")
|
|
|
- } else if (this.isEmpty(this.DYValue.id)) {
|
|
|
- this.$modal.msg("请选择单元")
|
|
|
- } else if (this.isEmpty(this.FJValue.id)) {
|
|
|
- this.$modal.msg("请选择房间")
|
|
|
- } else if (this.objValue.enginClassValue == '拆旧管') {
|
|
|
-
|
|
|
- if (this.isEmpty(this.LevelValue.dictValue)) {
|
|
|
- this.$modal.msg("请选择腐蚀等级") //拆旧管 判断腐蚀等级
|
|
|
- } else {
|
|
|
- this.onsubmit();
|
|
|
- }
|
|
|
- } else if (this.objValue.enginClassValue == '立杠') {
|
|
|
- //立杠 判断 材质 规格 数量
|
|
|
- if (this.isEmpty(this.materialValue.id)) {
|
|
|
- this.$modal.msg("请选择材质")
|
|
|
- } else if (this.isEmpty(this.specificationValue.id)) {
|
|
|
- this.$modal.msg("请选择规格")
|
|
|
- } else if (this.isEmpty(this.inputNumberValue)) {
|
|
|
- this.$modal.msg("请输入数量")
|
|
|
- } else {
|
|
|
- this.onsubmit();
|
|
|
- }
|
|
|
- } else if (this.objValue.enginClassValue == '挂表') {
|
|
|
- //挂表 判断 品牌 数量
|
|
|
- if (this.isEmpty(this.brandValue.dictValue)) {
|
|
|
- this.$modal.msg("请选择品牌")
|
|
|
- } else if (this.isEmpty(this.inputNumberValue)) {
|
|
|
- this.$modal.msg("请输入数量")
|
|
|
- } else {
|
|
|
- this.onsubmit();
|
|
|
- }
|
|
|
-
|
|
|
- } else if (this.objValue.enginClassValue == '表后管') {
|
|
|
- //表后管 判断 材质 规格 数量 (为必须有一张照片和一个视频)
|
|
|
- if (this.isEmpty(this.materialValue.id)) {
|
|
|
- this.$modal.msg("请选择材质")
|
|
|
- } else if (this.isEmpty(this.specificationValue.id)) {
|
|
|
- this.$modal.msg("请选择规格")
|
|
|
- } else if (this.isEmpty(this.inputNumberValue)) {
|
|
|
- this.$modal.msg("请输入数量")
|
|
|
- } else if (this.imgArr.length <= 0) {
|
|
|
- this.$modal.msg('请上传照片或视频')
|
|
|
- } else if (this.loading == false) {
|
|
|
- this.$modal.msg('照片或视频未上传完毕,无法提交!')
|
|
|
- } else {
|
|
|
- const hasImage = this.imgArr.some(item => item.endsWith('.jpg') || item.endsWith('.png') || item
|
|
|
- .endsWith('.jpeg'));
|
|
|
- const hasVideo = this.imgArr.some(item => item.endsWith('.mp4') || item.endsWith('.avi') || item
|
|
|
- .endsWith('.mov'));
|
|
|
-
|
|
|
- if (hasImage && hasVideo) {
|
|
|
- //表后管 特殊 提交
|
|
|
- let param = {
|
|
|
- district: this.XZQValue.dictValue,
|
|
|
- areaId: this.XQValue.id,
|
|
|
- buildingId: this.LDValue.id,
|
|
|
- unitId: this.DYValue.id,
|
|
|
- houseId: this.FJValue.id,
|
|
|
- enginType: this.objValue.enginType, //写死 上一页面传过来的
|
|
|
- enginClassification: this.objValue.enginClassification, //写死 上一页面传过来的 //室内 - 庭院 - 架空
|
|
|
- enginCycle: this.projectValue.dictValue, //工程周期
|
|
|
- zEngineeringNodeBo: {
|
|
|
- type: this.objValue.enginClassValue, //写死 上一页面传过来的 (拆旧管等 字典值)
|
|
|
- zEngineeringInfoBo: {
|
|
|
- constructAccordingDrawings: this.isCheck, //是否按图纸施工
|
|
|
- zEngiineeringPhotoBoList: this.imgArr, //照片集合
|
|
|
-
|
|
|
- zEngineeringMaterialBo: [{
|
|
|
- materialQuality: this.materialValue.id, //材质
|
|
|
- specifications: this.specificationValue.id, //规格
|
|
|
- number: this.inputNumberValue //数量
|
|
|
- }]
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- }
|
|
|
- addTearOldPipe(param).then(res => {
|
|
|
- if (res.code == '200') {
|
|
|
-
|
|
|
- uni.showToast({
|
|
|
- title: res.msg,
|
|
|
- icon: 'none',
|
|
|
- //显示持续时间为 1秒
|
|
|
- duration: 1000
|
|
|
- });
|
|
|
- uni.navigateBack();
|
|
|
- }
|
|
|
- })
|
|
|
- } else {
|
|
|
- this.$modal.msg('请至少上传一张照片和一个视频')
|
|
|
- }
|
|
|
- }
|
|
|
- } else if (this.objValue.enginClassValue == '阀管') {
|
|
|
- //阀管 判断 材质 规格 数量
|
|
|
- if (this.isEmpty(this.doorValue.dictValue)) {
|
|
|
- this.$modal.msg("请选择上门类型")
|
|
|
- } else if (this.isEmpty(this.SelfClosValve.dictValue)) {
|
|
|
- this.$modal.msg("请选择自闭阀类型")
|
|
|
- } else if (this.isEmpty(this.materialValue.id)) {
|
|
|
- this.$modal.msg("请选择材质")
|
|
|
- } else if (this.isEmpty(this.specificationValue.id)) {
|
|
|
- this.$modal.msg("请选择规格")
|
|
|
- } else if (this.isEmpty(this.inputNumberValue)) {
|
|
|
- this.$modal.msg("请输入数量")
|
|
|
- } else {
|
|
|
- this.onsubmit();
|
|
|
- }
|
|
|
+ return
|
|
|
}
|
|
|
- },
|
|
|
+ // else if (this.isEmpty(this.LDValue.id)) {
|
|
|
+ // this.$modal.msg("请选择楼栋")
|
|
|
+ // }
|
|
|
|
|
|
|
|
|
- onsubmit() {
|
|
|
-
|
|
|
+ if (this.objValue.enginClassValue == '回填' && this.isEmpty(this.BackfillingTime)) {
|
|
|
+ this.$modal.msg("请选择回填时间")
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (this.objValue.enginClassValue == '打压' && this.isEmpty(this.isOkValue)) {
|
|
|
+ this.$modal.msg("请选择分段打压是否合格")
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (this.isEmpty(this.materialValue.id)) {
|
|
|
+ this.$modal.msg("请选择材质")
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (this.isEmpty(this.specificationValue.id)) {
|
|
|
+ this.$modal.msg("请选择规格")
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (this.isEmpty(this.inputNumberValue)) {
|
|
|
+ this.$modal.msg("请输入数量")
|
|
|
+ return
|
|
|
+ }
|
|
|
if (this.imgArr.length <= 0) {
|
|
|
this.$modal.msg('请上传照片或视频')
|
|
|
- } else if (this.loading == false) {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (this.loading == false) {
|
|
|
this.$modal.msg('照片或视频未上传完毕,无法提交!')
|
|
|
- } else {
|
|
|
- //提交
|
|
|
- let param = ';'
|
|
|
- if (this.objValue.enginClassValue == '拆旧管') { //拆旧管
|
|
|
- param = {
|
|
|
- district: this.XZQValue.dictValue,
|
|
|
- areaId: this.XQValue.id,
|
|
|
- buildingId: this.LDValue.id,
|
|
|
- unitId: this.DYValue.id,
|
|
|
- houseId: this.FJValue.id,
|
|
|
- enginType: this.objValue.enginType, //写死 上一页面传过来的
|
|
|
- enginClassification: this.objValue.enginClassification, //写死 上一页面传过来的 //室内 - 庭院 - 架空
|
|
|
- enginCycle: this.projectValue.dictValue, //工程周期
|
|
|
- zEngineeringNodeBo: {
|
|
|
- type: this.objValue.enginClassValue, //写死 上一页面传过来的 (拆旧管等 字典值)
|
|
|
- zEngineeringInfoBo: {
|
|
|
- constructAccordingDrawings: this.isCheck, //是否按图纸施工
|
|
|
- zEngiineeringPhotoBoList: this.imgArr, //照片集合
|
|
|
-
|
|
|
- zEngineeringMaterialBo: [{
|
|
|
- corrosionLevel: this.LevelValue.dictValue //腐蚀等级
|
|
|
- }]
|
|
|
- }
|
|
|
- }
|
|
|
+ return
|
|
|
+ }
|
|
|
+ //提交
|
|
|
+ this.onsubmit();
|
|
|
|
|
|
- }
|
|
|
- //this.onsubmit(param)
|
|
|
- } else if (this.objValue.enginClassValue == '立杠') { //立杠
|
|
|
- param = {
|
|
|
- district: this.XZQValue.dictValue,
|
|
|
- areaId: this.XQValue.id,
|
|
|
- buildingId: this.LDValue.id,
|
|
|
- unitId: this.DYValue.id,
|
|
|
- houseId: this.FJValue.id,
|
|
|
- enginType: this.objValue.enginType, //写死 上一页面传过来的
|
|
|
- enginClassification: this.objValue.enginClassification, //写死 上一页面传过来的 //室内 - 庭院 - 架空
|
|
|
- enginCycle: this.projectValue.dictValue, //工程周期
|
|
|
- zEngineeringNodeBo: {
|
|
|
- type: this.objValue.enginClassValue, //写死 上一页面传过来的 (拆旧管等 字典值)
|
|
|
- zEngineeringInfoBo: {
|
|
|
- constructAccordingDrawings: this.isCheck, //是否按图纸施工
|
|
|
- zEngiineeringPhotoBoList: this.imgArr, //照片集合
|
|
|
-
|
|
|
- zEngineeringMaterialBo: [{
|
|
|
- materialQuality: this.materialValue.id, //材质
|
|
|
- specifications: this.specificationValue.id, //规格
|
|
|
- number: this.inputNumberValue //数量
|
|
|
- }]
|
|
|
- }
|
|
|
- }
|
|
|
+ },
|
|
|
|
|
|
- }
|
|
|
|
|
|
+ onsubmit() {
|
|
|
|
|
|
- } else if (this.objValue.enginClassValue == '挂表') { //挂表
|
|
|
- param = {
|
|
|
- district: this.XZQValue.dictValue,
|
|
|
- areaId: this.XQValue.id,
|
|
|
- buildingId: this.LDValue.id,
|
|
|
- unitId: this.DYValue.id,
|
|
|
- houseId: this.FJValue.id,
|
|
|
- enginType: this.objValue.enginType, //写死 上一页面传过来的
|
|
|
- enginClassification: this.objValue.enginClassification, //写死 上一页面传过来的 //室内 - 庭院 - 架空
|
|
|
- enginCycle: this.projectValue.dictValue, //工程周期
|
|
|
- zEngineeringNodeBo: {
|
|
|
- type: this.objValue.enginClassValue, //写死 上一页面传过来的 (拆旧管等 字典值)
|
|
|
- zEngineeringInfoBo: {
|
|
|
- constructAccordingDrawings: this.isCheck, //是否按图纸施工
|
|
|
- zEngiineeringPhotoBoList: this.imgArr, //照片集合
|
|
|
-
|
|
|
- zEngineeringMaterialBo: [{
|
|
|
- brand: this.brandValue.dictValue, //品牌
|
|
|
- number: this.inputNumberValue //数量
|
|
|
- }]
|
|
|
- }
|
|
|
- }
|
|
|
|
|
|
+ //提交
|
|
|
+ let param = {
|
|
|
+ district: this.XZQValue.dictValue,
|
|
|
+ areaId: this.XQValue.id,
|
|
|
+ buildingId: this.LDValue.id,
|
|
|
+
|
|
|
+ enginType: this.objValue.enginType, //写死 上一页面传过来的
|
|
|
+ enginClassification: this.objValue.enginClassification, //写死 上一页面传过来的 //室内 - 庭院 - 架空
|
|
|
+ enginCycle: this.projectValue.dictValue, //工程周期
|
|
|
+ zEngineeringNodeBo: {
|
|
|
+ type: this.objValue.enginClassValue, //写死 上一页面传过来的 (拆旧管等 字典值)
|
|
|
+ zEngineeringInfoBo: {
|
|
|
+ //constructAccordingDrawings: this.isCheck, //是否按图纸施工
|
|
|
+ segmentedCompressionQualified: this.isOkValue, // 分段打压是否台格
|
|
|
+ zEngiineeringPhotoBoList: this.imgArr, //照片集合
|
|
|
+ constructTime: this.time, //施工时间
|
|
|
+ backfillTime: this.BackfillingTime, // 回填时间
|
|
|
+ remark: this.projectContent, //施工内容
|
|
|
+ headName: this.user.nickName, // 负责人名称
|
|
|
+ headPhone: this.user.phonenumber, // 负责人电话
|
|
|
+ zEngineeringMaterialBo: [{
|
|
|
+ materialQuality: this.materialValue.id, //材质
|
|
|
+ specifications: this.specificationValue.id, //规格
|
|
|
+ number: this.inputNumberValue //数量
|
|
|
+ }]
|
|
|
}
|
|
|
- } else if (this.objValue.enginClassValue == '阀管') { //自闭阀
|
|
|
- param = {
|
|
|
- district: this.XZQValue.dictValue,
|
|
|
- areaId: this.XQValue.id,
|
|
|
- buildingId: this.LDValue.id,
|
|
|
- unitId: this.DYValue.id,
|
|
|
- houseId: this.FJValue.id,
|
|
|
- enginType: this.objValue.enginType, //写死 上一页面传过来的
|
|
|
- enginClassification: this.objValue.enginClassification, //写死 上一页面传过来的 //室内 - 庭院 - 架空
|
|
|
- enginCycle: this.projectValue.dictValue, //工程周期
|
|
|
- zEngineeringNodeBo: {
|
|
|
- type: this.objValue.enginClassValue, //写死 上一页面传过来的 (拆旧管等 字典值)
|
|
|
- zEngineeringInfoBo: {
|
|
|
- constructAccordingDrawings: this.isCheck, //是否按图纸施工
|
|
|
- zEngiineeringPhotoBoList: this.imgArr, //照片集合
|
|
|
-
|
|
|
- zEngineeringMaterialBo: [{
|
|
|
- visitType: this.doorValue.dictValue, //上门类型
|
|
|
- selfClosingValveType: this.SelfClosValve.dictValue, //自闭阀类型
|
|
|
- materialQuality: this.materialValue.id, //材质
|
|
|
- specifications: this.specificationValue.id, //规格
|
|
|
- number: this.inputNumberValue //数量
|
|
|
- }]
|
|
|
- }
|
|
|
- }
|
|
|
|
|
|
- }
|
|
|
}
|
|
|
|
|
|
- addTearOldPipe(param).then(res => {
|
|
|
- if (res.code == '200') {
|
|
|
- uni.showToast({
|
|
|
- title: res.msg,
|
|
|
- icon: 'none',
|
|
|
- //显示持续时间为 3秒
|
|
|
- duration: 2000
|
|
|
- });
|
|
|
- setTimeout(function() {
|
|
|
- uni.navigateBack();
|
|
|
- }, 1000)
|
|
|
-
|
|
|
- }
|
|
|
- })
|
|
|
}
|
|
|
|
|
|
+ addTearOldPipe(param).then(res => {
|
|
|
+ if (res.code == '200') {
|
|
|
+ uni.showToast({
|
|
|
+ title: res.msg,
|
|
|
+ icon: 'none',
|
|
|
+ //显示持续时间为 3秒
|
|
|
+ duration: 2000
|
|
|
+ });
|
|
|
+ setTimeout(function() {
|
|
|
+ uni.navigateBack();
|
|
|
+ }, 1000)
|
|
|
+
|
|
|
+ }
|
|
|
+ })
|
|
|
+
|
|
|
},
|
|
|
history() {
|
|
|
if (this.isEmpty(this.projectValue.dictValue)) {
|
|
@@ -1093,16 +839,17 @@
|
|
|
|
|
|
if (res.data != null) {
|
|
|
|
|
|
- getRoomProjectList(res.data.id, this.objValue.enginClassValue).then(res => {
|
|
|
+ getRoomProjectList(res.data.id, this.objValue.enginClassValue).then(
|
|
|
+ res => {
|
|
|
|
|
|
- this.historyList = res.data
|
|
|
- if (res.data.zEngineeringNodeBo != null) {
|
|
|
- this.showHistoryList();
|
|
|
- } else {
|
|
|
- this.$modal.msg("暂无历史信息")
|
|
|
- }
|
|
|
+ this.historyList = res.data
|
|
|
+ if (res.data.zEngineeringNodeBo != null) {
|
|
|
+ this.showHistoryList();
|
|
|
+ } else {
|
|
|
+ this.$modal.msg("暂无历史信息")
|
|
|
+ }
|
|
|
|
|
|
- })
|
|
|
+ })
|
|
|
|
|
|
} else {
|
|
|
this.$modal.msg("暂无工程信息")
|
|
@@ -1116,7 +863,6 @@
|
|
|
showHistoryList() {
|
|
|
this.$refs.refShare.handleShowShare();
|
|
|
}
|
|
|
-
|
|
|
}
|
|
|
}
|
|
|
</script>
|
|
@@ -1162,4 +908,12 @@
|
|
|
padding: 10px;
|
|
|
/* 设置padding以提高视觉效果 */
|
|
|
}
|
|
|
+
|
|
|
+ .textarea {
|
|
|
+ margin-top: 10upx;
|
|
|
+ width: 100%;
|
|
|
+ border: 1rpx solid red;
|
|
|
+ min-height: 100upx;
|
|
|
+ line-height: 20px;
|
|
|
+ }
|
|
|
</style>
|