1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540 |
- <template>
- <scroll-view>
- <view class="uni-media-list" v-for="(value, key) in dataJson.zEngineeringNodeBo.zEngineeringInfoBoList"
- :key="key" v-if="isEdit(value)">
- <view class="uni-media-list-body">
- <view>
- <view class="uni-media-list-text-top">
- <view class="tit-text">施工时间:</view>{{value.updateTime}}
- </view>
- <view class="uni-media-list-text-top">
- <view class="uni-common-mt" style="width: 100%;">
- <text class="tit-text" style=" font-size: 13px;color:
- #000;margin-top: 5px;">施工内容:</text>
- <view style="width: 100%;box-sizing: border-box;">
- <textarea class="textarea" 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 :value="value.remark"
- @blur="bindTextAreaBlur($event.target.value,key)"></textarea>
- </view>
- </view>
- </view>
- <view
- v-if="title=='开挖前'||title=='开挖后'||title=='焊口照片'||title=='隐蔽工程'||title=='除锈刷油'||title=='打磨'||title=='全貌照片'||title=='焊接'||title=='管道施工记录'">
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px; margin-left: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; " @click="choose('other',key)">
- </image>
- <view v-for="(item,index) in value.zEngiineeringPhotoBoList" :key="index"
- style="position: relative;">
- <view
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg'||item.substring(item.length-4)=='jpeg' ">
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
- @click="showPhoto(index,value.zEngiineeringPhotoBoList)">
- </image>
- </view>
- <view v-else>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="remove(index,key)"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view>
- <view v-if="title=='全貌照片'">
- <view class="cz-style" v-for="(a,index) in value.zEngineeringMaterialBo" :key="index">
- <view class="uni-media-list-text-top" style=" ">
- <view class="tit-text">材质:</view>
- <view class="uni-list-cell-db" style="margin-top: 10;"
- @click="pickerShow('cz',key,index)">
- <span
- style="color: black;">{{a.materialQualityName==''?'请选择材质':a.materialQualityName}}</span>
- </view>
- </view>
- <view class="uni-media-list-text-top" style=" ">
- <view class="tit-text">规格:</view>
- <view class="uni-list-cell-db" style="margin-top: 10;"
- @click="pickerShow('gg',key,index)">
- <span
- style="color: black;">{{a.specificationsName==''?'请选择规格':a.specificationsName}}</span>
- </view>
- </view>
- <view class="uni-media-list-text-top" style="border-bottom: 1px solid #f8f8f8;">
- <text class="tit-text">米 数</text>
- <view style="display: flex; justify-content: right; width: 70%;">
- <input class="uni-input" type="number" :value="getIntegerPart(a.number,0)"
- @change="setInfoBoNumber(key,index,$event.target.value,0)" maxlength="6"
- style="text-align: center; border: 1px solid #00aaff; border-radius: 20rpx;"></input>
- <text style="font-weight:bold;margin-left: 10px;margin-right: 10px;">.</text>
- <input class="uni-input" type="number" :value="getIntegerPart(a.number,1)"
- @change="setInfoBoNumber(key,index,$event.target.value,1)" maxlength="1"
- style="text-align: center; border: 1px solid #00aaff; border-radius: 20rpx;"></input>
- </view>
- </view>
- <button v-if="index!=0" @click="btnDel(key,index)" class="sc-btn">删除</button>
- </view>
- <button @click="btnAdd(key,index)" class="tj-btn">添加</button>
- </view>
- </view>
- <view v-if="title=='回填'">
- <view class="uni-common-mt" style="width: 100%;">
- <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
- #000;margin-top: 5px; margin-left: 8px;">石粉回填照片:</text>
- </view>
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; " @click="choose('sfht',key)">
- </image>
- <view v-for="(item,index) in value.stonePowder" :key="index" style="position: relative;">
- <view
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' || item.substring(item.length - 3) == 'jpeg'">
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
- @click="showPhoto(index,value.stonePowder)">
- </image>
- </view>
- <view v-else>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="removeht(index,key,'sfht')"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view>
- <view class="uni-common-mt" style="width: 100%;">
- <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
- #000;margin-top: 5px;margin-left: 8px;">警示带铺设照片:</text>
- </view>
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; " @click="choose('jsdps',key)">
- </image>
- <view v-for="(item,index) in value.warningtTape" :key="index" style="position: relative;">
- <view
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' || item.substring(item.length - 3) == 'jpeg'">
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
- @click="showPhoto(index,value.warningtTape)">
- </image>
- </view>
- <view v-else>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="removeht(index,key,'jsdps')"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view>
- <view class="uni-common-mt" style="width: 100%;">
- <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
- #000;margin-top: 5px;margin-left: 8px;">回填后照片:</text>
- </view>
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; " @click="choose('hth',key)">
- </image>
- <view v-for="(item,index) in value.photosAfter" :key="index" style="position: relative;">
- <view
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' || item.substring(item.length - 3) == 'jpeg'">
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
- @click="showPhoto(index,value.photosAfter)">
- </image>
- </view>
- <view v-else>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="removeht(index,key,'hth')"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view>
- </view>
- <view v-if="title=='下沟'">
- <view class="cz-style" v-for="(a,index) in value.zEngineeringMaterialBo" :key="index">
- <view class="uni-media-list-text-top" style=" ">
- <view class="tit-text">材质:</view>
- <view class="uni-list-cell-db" style="margin-top: 10;"
- @click="pickerShow('cz',key,index)">
- <span
- style="color: black;">{{a.materialQualityName==''?'请选择材质':a.materialQualityName}}</span>
- </view>
- </view>
- <view class="uni-media-list-text-top" style=" ">
- <view class="tit-text">规格:</view>
- <view class="uni-list-cell-db" style="margin-top: 10;"
- @click="pickerShow('gg',key,index)">
- <span
- style="color: black;">{{a.specificationsName==''?'请选择规格':a.specificationsName}}</span>
- </view>
- </view>
- <view class="uni-media-list-text-top" style="border-bottom: 1px solid #f8f8f8;">
- <text class="tit-text">米 数</text>
- <view style="display: flex; justify-content: right; width: 70%;">
- <input class="uni-input" type="number" :value="getIntegerPart(a.number,0)"
- @change="setInfoBoNumber(key,index,$event.target.value,0)" maxlength="6"
- style="text-align: center; border: 1px solid #00aaff; border-radius: 20rpx;"></input>
- <text style="font-weight:bold;margin-left: 10px;margin-right: 10px;">.</text>
- <input class="uni-input" type="number" :value="getIntegerPart(a.number,1)"
- @change="setInfoBoNumber(key,index,$event.target.value,1)" maxlength="1"
- style="text-align: center; border: 1px solid #00aaff; border-radius: 20rpx;"></input>
- </view>
- </view>
- <button v-if="index!=0" @click="btnDel(key,index)" class="sc-btn">删除</button>
- </view>
- <button @click="btnAdd(key,index)" class="tj-btn">添加</button>
- <!-- <view class="uni-common-mt" style="width: 100%;">
- <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
- #000;margin-top: 5px; margin-left: 8px;">管道施工记录:</text>
- </view>
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; "
- @click="chooseType('gdsgjl',key)">
- </image>
- <view v-for="(item,index) in value.constructionRecords" :key="index"
- style="position: relative;">
- <view
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' || item.substring(item.length - 3) == 'jpeg'">
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
- @click="showPhoto(index,value.constructionRecords)">
- </image>
- </view>
- <view v-else>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="removeht(index,key,'gdsgjl')"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view> -->
- <view class="uni-common-mt" style="width: 100%;">
- <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
- #000;margin-top: 5px; margin-left: 8px;">管上皮深度测量照片:</text>
- </view>
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; "
- @click="chooseType('gspsdcl',key)">
- </image>
- <view v-for="(item,index) in value.ductalEpithelium" :key="index"
- style="position: relative;">
- <view
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' || item.substring(item.length - 3) == 'jpeg'">
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
- @click="showPhoto(index,value.ductalEpithelium)">
- </image>
- </view>
- <view v-else>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="removeht(index,key,'gspsdcl')"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view>
- <view class="uni-common-mt" style="width: 100%;">
- <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
- #000;margin-top: 5px;margin-left: 8px;">管沟远景照片:</text>
- </view>
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; "
- @click="chooseType('ggyj',key)">
- </image>
- <view v-for="(item,index) in value.trenchProspect" :key="index" style="position: relative;">
- <view
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' || item.substring(item.length - 3) == 'jpeg'">
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
- @click="showPhoto(index,value.trenchProspect)">
- </image>
- </view>
- <view v-else>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="removeht(index,key,'ggyj')"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view>
- <view class="uni-common-mt" style="width: 100%;">
- <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
- #000;margin-top: 5px;margin-left: 8px;">视频:</text>
- </view>
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; "
- @click="chooseType('video',key)">
- </image>
- <view v-for="(item,index) in value.video" :key="index" style="position: relative;">
- <view>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="removeht(index,key,'video')"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view>
- </view>
- <view v-if="title=='调压柜'">
- <view class="uni-common-mt" style="width: 100%;">
- <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
- #000;margin-top: 5px; margin-left: 8px;">调压箱铭牌照片:</text>
- </view>
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; " @click="choose('Box',key)">
- </image>
- <view v-for="(item,index) in value.boxBrand" :key="index" style="position: relative;">
- <view
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' || item.substring(item.length - 3) == 'jpeg'">
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
- @click="showPhoto(index,value.boxBrand)">
- </image>
- </view>
- <view v-else>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="removeht(index,key,'Box')"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view>
- <view class="uni-common-mt" style="width: 100%;">
- <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
- #000;margin-top: 5px; margin-left: 8px;">调压箱内石粉回填照片:</text>
- </view>
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; " @click="choose('Sfht',key)">
- </image>
- <view v-for="(item,index) in value.stonePowder" :key="index" style="position: relative;">
- <view
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' || item.substring(item.length - 3) == 'jpeg'">
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
- @click="showPhoto(index,value.stonePowder)">
- </image>
- </view>
- <view v-else>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="removeht(index,key,'Sfht')"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view>
- <view class="uni-common-mt" style="width: 100%;">
- <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
- #000;margin-top: 5px; margin-left: 8px;">调压箱防雷接地照片:</text>
- </view>
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; " @click="choose('Fljd',key)">
- </image>
- <view v-for="(item,index) in value.lightning" :key="index" style="position: relative;">
- <view
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' || item.substring(item.length - 3) == 'jpeg'">
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
- @click="showPhoto(index,value.lightning)">
- </image>
- </view>
- <view v-else>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="removeht(index,key,'Fljd')"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view>
- <view class="uni-common-mt" style="width: 100%;">
- <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
- #000;margin-top: 5px; margin-left: 8px;">调压箱底腿连接照片:</text>
- </view>
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; " @click="choose('Fljd',key)">
- </image>
- <view v-for="(item,index) in value.bottomLeg" :key="index" style="position: relative;">
- <view
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' || item.substring(item.length - 3) == 'jpeg'">
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
- @click="showPhoto(index,value.bottomLeg)">
- </image>
- </view>
- <view v-else>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="removeht(index,key,'Fljd')"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view>
- <view class="uni-common-mt" style="width: 100%;">
- <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
- #000;margin-top: 5px; margin-left: 8px;">调压箱护栏及地面硬化(远景)照片:</text>
- </view>
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; " @click="choose('Hldmyh',key)">
- </image>
- <view v-for="(item,index) in value.groundHardening" :key="index"
- style="position: relative;">
- <view
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' || item.substring(item.length - 3) == 'jpeg'">
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
- @click="showPhoto(index,value.groundHardening)">
- </image>
- </view>
- <view v-else>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="removeht(index,key,'Hldmyh')"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view>
- </view>
- <view v-if="title=='阀井'">
- <view class="uni-common-mt" style="width: 100%;">
- <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
- #000;margin-top: 5px; margin-left: 8px;">套管照片:</text>
- </view>
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; " @click="choose('Tg',key)">
- </image>
- <view v-for="(item,index) in value.cannula" :key="index" style="position: relative;">
- <view
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' || item.substring(item.length - 3) == 'jpeg'">
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
- @click="showPhoto(index,value.cannula)">
- </image>
- </view>
- <view v-else>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="removeht(index,key,'Tg')"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view>
- <view class="uni-common-mt" style="width: 100%;">
- <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
- #000;margin-top: 5px; margin-left: 8px;">内壁抹灰照片:</text>
- </view>
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; " @click="choose('Nbmh',key)">
- </image>
- <view v-for="(item,index) in value.wallPlaster" :key="index" style="position: relative;">
- <view
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' || item.substring(item.length - 3) == 'jpeg'">
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
- @click="showPhoto(index,value.wallPlaster)">
- </image>
- </view>
- <view v-else>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="removeht(index,key,'Nbmh')"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view>
- <view class="uni-common-mt" style="width: 100%;">
- <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
- #000;margin-top: 5px; margin-left: 8px;">防护网照片:</text>
- </view>
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; " @click="choose('Fhw',key)">
- </image>
- <view v-for="(item,index) in value.protectiveNet" :key="index" style="position: relative;">
- <view
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' || item.substring(item.length - 3) == 'jpeg'">
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
- @click="showPhoto(index,value.protectiveNet)">
- </image>
- </view>
- <view v-else>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="removeht(index,key,'Fhw')"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view>
- <view class="uni-common-mt" style="width: 100%;">
- <text class="uni-title uni-common-pl" style=" font-size: 13px;color:
- #000;margin-top: 5px; margin-left: 8px;">八角照片:</text>
- </view>
- <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px;">
- <image :src="loadImgSrc('updateimg.png')" mode=""
- style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; " @click="choose('Bj',key)">
- </image>
- <view v-for="(item,index) in value.starAnise" :key="index" style="position: relative;">
- <view
- v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' || item.substring(item.length - 3) == 'jpeg'">
- <image :src="item" mode="" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"
- @click="showPhoto(index,value.starAnise)">
- </image>
- </view>
- <view v-else>
- <video :src="item" style="width: 100rpx; height: 100rpx; margin: 0 12rpx;"></video>
- </view>
- <view @click="removeht(index,key,'Bj')"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- </view>
- </view>
- </view>
- </view>
- </view>
- </view>
- </view>
- <!-- <view class="gesture-area" v-show="playVideo" >
- <view @click="closeVideo()"
- style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
- <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
- </image>
- </view>
- <video :src="playVideoSrc"></video>
- </view> -->
- <SelectPicker :list="selectList" @change="changeSelect" v-if="open" @close="close" titleKey="name"
- subtitleKey="id">
- </SelectPicker>
- <SelectPicker :list="dictOptions" @change="changeSelectDict" v-if="openDict" @close="closeDict"
- titleKey="dictLabel" subtitleKey="dictValue" v-model="name"></SelectPicker>
- <view class="action-btn" v-if="hideButton==false">
- <button @click="submit" class="btn cu-btn block bg-blue lg round">确认</button>
- </view>
- </scroll-view>
- </template>
- <script>
- import SelectPicker from '../../components/selectPicker/select_picker.vue'
- import {
- getDicts
- } from "@/api/system/dict/data";
- import {
- getToken
- } from '../../utils/auth';
- import user from '@/store/modules/user'
- import {
- getHistoryDetails,
- getEnginMaterialQualityList,
- putHistory,
- getEnginSpecificationsList
- } from '@/api/common'
- export default {
- components: {
- SelectPicker,
- },
- data() {
- return {
- // playVideo: false,//视频播放放大
- // playVideoSrc:'',
- selectZbfList: [],
- dictOptions: [],
- openDict: false,
- dataIndex: 0, //数据用第几条
- selectIndex: 0, //材质规格用的第几条
- imageIndex: 0,
- headers: {
- Authorization: "Bearer " + getToken()
- },
- nodeId: '',
- type: '',
- title: '',
- dataJson: '',
- enginClassification: '',
- enginType: '',
- enginClassValue: '',
- selectList: [],
- open: false,
- selectType: '',
- hideButton: false,
- }
- },
- onLoad(options) {
- if ('params' in options) {
- let e = JSON.parse(decodeURIComponent(options.params));
- this.nodeId = e.id;
- this.type = e.type;
- getHistoryDetails(this.nodeId, this.type).then(response => {
- if (response.data.zEngineeringNodeBo != null) {
- let flag = false;
- for (let i in response.data.zEngineeringNodeBo.zEngineeringInfoBoList) {
- if (response.data.zEngineeringNodeBo.zEngineeringInfoBoList[i].createBy == this.$user
- .state.name) {
- flag = true;
- break;
- }
- }
- if (flag) {
- this.hideButton = false;
- this.dataJson = response.data;
- this.title = response.data.zEngineeringNodeBo.type;
- this.enginType = response.data.enginType;
- this.enginClassification = response.data.enginClassification;
- } else {
- this.hideButton = true;
- this.$modal.msg("暂无本人历史信息")
- }
- } else {
- this.hideButton = true;
- this.$modal.msg("暂无历史信息")
- }
- });
- }
- },
- methods: {
- //关闭弹窗
- close(e) {
- this.open = false
- },
- btnAdd(key, index) {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key].zEngineeringMaterialBo.push({
- 'materialQuality': '',
- 'materialQualityName': '',
- 'number': '',
- 'specifications': '',
- 'specificationsName': ''
- });
- },
- btnDel(key, index) {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key].zEngineeringMaterialBo.splice(index, 1);
- },
- pickerShow(e, index, indexTwo) {
- this.dataIndex = index;
- this.selectIndex = indexTwo; //材质规格 第几条
- this.selectType = e;
- if (e == 'cz') {
- this.open = true;
- getEnginMaterialQualityList("民用工程", this.enginType, this.enginClassification, this.title)
- .then(response => {
- this.selectList = response.data;
- });
- }
- if (e == 'gg') {
- if (this.isEmpty(this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[this.dataIndex]
- .zEngineeringMaterialBo[this.selectIndex].materialQuality)) {
- this.$modal.msg('请选择材质')
- } else {
- this.open = true;
- getEnginSpecificationsList(this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[this.dataIndex]
- .zEngineeringMaterialBo[this.selectIndex].materialQuality).then(res => {
- this.selectList = res.data
- })
- }
- }
- },
- changeSelect(item, index) {
- this.open = false;
- if (this.selectType == 'cz') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[this.dataIndex].zEngineeringMaterialBo[this
- .selectIndex]
- .materialQuality = item.id;
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[this.dataIndex].zEngineeringMaterialBo[this
- .selectIndex]
- .materialQualityName = item.name;
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[this.dataIndex].zEngineeringMaterialBo[this
- .selectIndex]
- .specifications = '';
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[this.dataIndex].zEngineeringMaterialBo[this
- .selectIndex]
- .specificationsName = '';
- } else if (this.selectType == 'gg') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[this.dataIndex].zEngineeringMaterialBo[this
- .selectIndex]
- .specifications = item.id;
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[this.dataIndex].zEngineeringMaterialBo[this
- .selectIndex]
- .specificationsName = item.name;
- }
- },
- // 截取小数点前的字符串
- getIntegerPart(numStr, i) {
- return numStr.toString().split('.')[i] == undefined ? '0' : numStr.toString().split('.')[i];
- },
- setInfoBoNumber(key, index, number, i) {
- let Ynumber = this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key].zEngineeringMaterialBo[index]
- .number;
- let resAry = Ynumber.toString().split('.');
- resAry[i] = number
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key].zEngineeringMaterialBo[index].number = resAry
- .join('.');
- },
- bindTextAreaBlur(e, index) {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[index].remark = e;
- },
- removeht(index, key, type) {
- uni.showModal({
- title: '提示',
- content: '是否删除该图片或视频?',
- success: (res) => {
- if (res.confirm) {
- if (type == 'sfht') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key].stonePowder
- .splice(index, 1)
- } else if (type == 'jsdps') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key].warningtTape
- .splice(index, 1)
- } else if (type == 'hth') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key].photosAfter
- .splice(index, 1)
- } else if (type == 'gdsgjl') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key]
- .constructionRecords
- .splice(index, 1)
- } else if (type == 'gspsdcl') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key]
- .ductalEpithelium
- .splice(index, 1)
- } else if (type == 'ggyj') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key]
- .trenchProspect
- .splice(index, 1)
- } else if (type == 'video') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key]
- .video
- .splice(index, 1)
- } else if (type == 'Box') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key]
- .boxBrand
- .splice(index, 1)
- } else if (type == 'Sfht') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key]
- .stonePowder
- .splice(index, 1)
- } else if (type == 'Fljd') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key]
- .lightning
- .splice(index, 1)
- } else if (type == 'Dtlj') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key]
- .bottomLeg
- .splice(index, 1)
- } else if (type == 'Hldmyh') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key]
- .groundHardening
- .splice(index, 1)
- } else if (type == 'Tg') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key]
- .cannula
- .splice(index, 1)
- } else if (type == 'Nbmh') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key]
- .wallPlaster
- .splice(index, 1)
- } else if (type == 'Fhw') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key]
- .protectiveNet
- .splice(index, 1)
- } else if (type == 'Bj') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key]
- .starAnise
- .splice(index, 1)
- }
- }
- }
- })
- },
- remove(index, key) {
- uni.showModal({
- title: '提示',
- content: '是否删除该图片或视频?',
- success: (res) => {
- if (res.confirm) {
- this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[key]
- .zEngiineeringPhotoBoList.splice(index, 1)
- }
- }
- })
- },
- chooseType(type, index) {
- this.dataIndex = index;
- let _this = this;
- if (type == 'video') {
- this.choosevideo(type)
- } else {
- this.chooseimage(type)
- }
- },
- choose(type, index) {
- this.dataIndex = index;
- let _this = this;
- uni.showActionSheet({
- title: '上传',
- itemList: ['图片', '视频'],
- success: (res) => {
- if (res.tapIndex == 0) {
- this.chooseimage(type)
- } else {
- this.choosevideo(type)
- }
- }
- })
- },
- chooseimage(e) {
- let _this = this;
- uni.chooseImage({
- sizeType: ['album', 'camera'],
- success(resp) {
- resp.tempFiles.forEach((item, index) => {
- const task = uni.uploadFile({
- url: _this.$HTTP + `/obs`,
- filePath: item.path,
- name: 'file',
- formData: {},
- header: _this.headers,
- success: res => {
- let data = JSON.parse(res.data);
- if (![200].includes(data.code)) {
- _this.$modal.msg(data.msg)
- } else {
- if (_this.progress === 100) {
- if (e == 'other') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .zEngiineeringPhotoBoList.push(data.data
- .url);
- } else if (e == 'sfht') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .stonePowder.push(data.data
- .url);
- } else if (e == 'jsdps') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .warningtTape.push(data.data
- .url);
- } else if (e == 'hth') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .photosAfter.push(data.data
- .url);
- } else if (e == 'gdsgjl') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .constructionRecords.push(data.data
- .url);
- } else if (e == 'gspsdcl') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .ductalEpithelium.push(data.data
- .url);
- } else if (e == 'ggyj') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .trenchProspect.push(data.data
- .url);
- } else if (e == 'Box') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .boxBrand.push(data
- .data
- .url);
- } else if (e == 'Sfht') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .stonePowder.push(data
- .data
- .url);
- } else if (e == 'Fljd') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .lightning.push(data
- .data
- .url);
- } else if (e == 'Dtlj') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .bottomLeg.push(data
- .data
- .url);
- } else if (e == 'Hldmyh') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .groundHardening.push(data
- .data
- .url);
- } else if (e == 'Tg') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .cannula.push(data
- .data
- .url);
- } else if (e == 'Nbmh') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .wallPlaster.push(data
- .data
- .url);
- } else if (e == 'Fhw') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .protectiveNet.push(data
- .data
- .url);
- } else if (e == 'Bj') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .starAnise.push(data
- .data
- .url);
- }
- _this.$modal.msg('上传成功!')
- }
- }
- },
- fail: e => {
- _this.$modal.msg('上传失败!')
- },
- complete: res => {
- uni.hideLoading();
- _this.uploading = false;
- }
- });
- task.onProgressUpdate(res => {
- _this.progress = res.progress;
- uni.showLoading({
- title: '上传中'
- })
- if (_this.progress != 100) {
- _this.loading = false
- } else {
- _this.loading = true
- }
- });
- })
- },
- })
- },
- choosevideo(e) {
- let _this = this;
- uni.chooseVideo({
- sourceType: ['album', 'camera'],
- maxDuration: 30,
- success(resp) {
- const task = uni.uploadFile({
- url: _this.$HTTP + `/obs`,
- filePath: resp.tempFilePath,
- name: 'file',
- formData: {},
- header: _this.headers,
- success: res => {
- let data = JSON.parse(res.data);
- if (![200].includes(res.statusCode)) {
- this.uploadError(index, data);
- } else {
- //上传成功
- if (_this.progress === 100) {
- if (e == 'other') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .zEngiineeringPhotoBoList.push(data.data.url);
- } else if (e == 'sfht') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .stonePowder.push(data.data.url);
- } else if (e == 'jsdps') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .warningtTape.push(data.data.url);
- } else if (e == 'hth') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .photosAfter.push(data.data.url);
- } else if (e == 'video') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .video.push(data.data.url);
- } else if (e == 'Box') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .boxBrand.push(data.data.url);
- } else if (e == 'Sfht') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .stonePowder.push(data.data.url);
- } else if (e == 'Fljd') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .lightning.push(data.data.url);
- } else if (e == 'Dtlj') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .bottomLeg.push(data.data.url);
- } else if (e == 'Hldmyh') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .groundHardening.push(data.data.url);
- } else if (e == 'Tg') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .cannula.push(data.data.url);
- } else if (e == 'Nbmh') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .wallPlaster.push(data.data.url);
- } else if (e == 'Fhw') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .protectiveNet.push(data.data.url);
- } else if (e == 'Bj') {
- _this.dataJson.zEngineeringNodeBo
- .zEngineeringInfoBoList[_this.dataIndex]
- .starAnise.push(data.data.url);
- }
- _this.$modal.msg('上传成功!')
- }
- }
- },
- fail: e => {
- _this.$modal.msg('上传失败!')
- this.uploadError(index, e);
- },
- complete: res => {
- uni.hideLoading();
- _this.uploading = false;
- }
- });
- task.onProgressUpdate(res => {
- _this.progress = res.progress;
- uni.showLoading({
- title: '上传中'
- })
- if (_this.progress != 100) {
- _this.loading = false
- } else {
- _this.loading = true
- }
- });
- },
- })
- },
- showPhoto(index, arr) {
- let newArr = [];
- arr.forEach((item, index) => {
- if (item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg' ||
- item.substring(item.length - 4) == 'jpeg') {
- newArr.push(item)
- }
- });
- uni.previewImage({
- current: index,
- urls: newArr,
- })
- },
- // showVideo(arr) {
- // this.playVideo = true;
- // this.playVideoSrc = arr;
- // },
- // closeVideo(){
- // this.playVideo = false;
- // },
- isEmpty(str) {
- return (!str || 0 === str.length);
- },
- isEdit(item) {
- var isShow = item.createBy == this.$user.state.name;
- return isShow;
- },
- submit() {
- let isSubmit = true;
- if (this.title == '回填') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList.forEach((res) => {
- // if (res.stonePowder.length == 0) {
- // this.$modal.msg("请上传石粉回填照片");
- // isSubmit = false;
- // }
- if (res.warningtTape.length == 0) {
- this.$modal.msg("请上传警示带铺设照片");
- isSubmit = false;
- }
- if (res.photosAfter.length == 0) {
- this.$modal.msg("请上传回填后照片");
- isSubmit = false;
- }
- })
- } else if (this.title == '下沟') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList.forEach((res) => {
- res.zEngineeringMaterialBo.forEach((itme) => {
- if (itme.specifications == '') {
- this.$modal.msg("请选择规格");
- isSubmit = false;
- }
- if (itme.number == '') {
- this.$modal.msg("请输入米数");
- isSubmit = false;
- }
- })
- if (res.constructionRecords.length <= 0) {
- this.$modal.msg('请上传管道施工记录照片')
- isSubmit = false;
- }
- if (res.ductalEpithelium.length <= 0) {
- this.$modal.msg('请上传管上皮深度测量照片')
- isSubmit = false;
- }
- if (res.trenchProspect.length <= 0) {
- this.$modal.msg('请上传管沟远景照片')
- isSubmit = false;
- }
- if (res.video.length <= 0) {
- this.$modal.msg('请上传视频')
- isSubmit = false;
- }
- })
- } else if (this.title == '调压柜') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList.forEach((res) => {
- if (res.boxBrand.length == 0) {
- this.$modal.msg("请上传调压箱铭牌照片");
- isSubmit = false;
- }
- if (res.stonePowder.length == 0) {
- this.$modal.msg("请上传调压箱内石粉回填照片");
- isSubmit = false;
- }
- if (res.lightning.length == 0) {
- this.$modal.msg("请上传调压箱防雷接地照片");
- isSubmit = false;
- }
- if (res.bottomLeg.length == 0) {
- this.$modal.msg("请上传调压箱底腿连接照片");
- isSubmit = false;
- }
- if (res.groundHardening.length == 0) {
- this.$modal.msg("请上传调压箱护栏及地面硬化(远景)照片");
- isSubmit = false;
- }
- })
- } else if (this.title == '阀井') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList.forEach((res) => {
- if (res.cannula.length == 0) {
- this.$modal.msg("请上传套管照片");
- isSubmit = false;
- }
- if (res.wallPlaster.length == 0) {
- this.$modal.msg("请上传内壁抹灰照片");
- isSubmit = false;
- }
- if (res.protectiveNet.length == 0) {
- this.$modal.msg("请上传防护网照片");
- isSubmit = false;
- }
- if (res.starAnise.length == 0) {
- this.$modal.msg("请上传八角照片");
- isSubmit = false;
- }
- })
- } else {
- if (this.title == '全貌照片') {
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList.forEach((res) => {
- res.zEngineeringMaterialBo.forEach((itme) => {
- if (itme.specifications == '') {
- this.$modal.msg("请选择规格");
- isSubmit = false;
- }
- if (itme.number == '') {
- this.$modal.msg("请输入米数");
- isSubmit = false;
- }
- })
- })
- }
- this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList.forEach((res) => {
- if (res.zEngiineeringPhotoBoList.length == 0) {
- this.$modal.msg("请上传照片");
- isSubmit = false;
- }
- })
- }
- if (!isSubmit) {
- return
- }
- putHistory(this.dataJson).then(
- response => {
- if (response.code == '200') {
- uni.hideLoading()
- uni.showToast({
- title: response.msg,
- icon: 'none',
- duration: 2000
- });
- setTimeout(function() {
- uni.navigateBack();
- }, 1000)
- }
- });
- }
- }
- }
- </script>
- <style lang="scss">
- .uni-media-list-body {
- background: #fff;
- border: 1px solid #eee;
- border-radius: 40rpx;
- margin: 20rpx;
- padding: 10rpx 0 40rpx;
- box-shadow: 0 0 5px #eee;
- }
- .uni-media-list-text-top {
- display: flex;
- align-items: center;
- justify-content: space-between;
- padding: 10px;
- position: relative;
- }
- .to-right-icon {
- width: 15px;
- height: 15px;
- position: absolute;
- top: 50%;
- transform: translateY(-50%);
- }
- .share {
- width: 100%;
- height: 100%;
- }
- .tit-text {
- color: #4f535a;
- margin-right: 20rpx;
- }
- .normal-text {}
- .cz-style {
- background: #e8f4f9;
- margin: 20rpx;
- padding: 10rpx;
- border-radius: 20rpx;
- border: 1px solid #d4e3f0;
- }
- .uni-media-list-text-top {
- font-size: 14px;
- color: #696969;
- padding: 20rpx 20rpx;
- border-bottom: 1px solid #eee;
- display: flex;
- align-items: center;
- }
- .share-box {
- width: 100%;
- height: 100%;
- position: fixed;
- top: 0rpx;
- left: 0rpx;
- bottom: 0rpx;
- right: 0rpx;
- background-color: rgba(0, 0, 0, 0.4);
- transition: .3s;
- z-index: 999;
- }
- // 进入分享动画
- .share-show {
- transition: all 0.3s ease;
- transform: translateY(0%) !important;
- border-radius: 20px 20px 0px 0px;
- }
- .scroll-Y {
- height: 58vh;
- }
- // 离开分享动画
- .share-item {
- position: fixed;
- left: 0;
- bottom: 0;
- width: 100%;
- height: 70%;
- background-color: #FFFFFF;
- transition: all 0.3s ease;
- transform: translateY(100%);
- z-index: 1999;
- .share-to {
- width: 100%;
- height: 30px;
- display: flex;
- justify-content: center;
- margin: 30rpx 0;
- align-items: center;
- }
- .content {
- width: 100%;
- height: auto;
- display: flex;
- flex-wrap: wrap;
- .block {
- width: 100%;
- display: flex;
- flex-direction: column;
- justify-content: center;
- align-items: left;
- height: auto;
- image {
- width: 80rpx;
- height: 80rpx;
- }
- text {
- margin-top: 16rpx;
- font-size: 28rpx;
- color: #606266;
- }
- }
- }
- .cancel {
- width: 100%;
- height: 3rem;
- display: flex;
- justify-content: center;
- align-items: center;
- border-top: 1rpx solid #E4E7ED;
- }
- }
- .uni-media-list-text-top {
- display: flex;
- align-items: center;
- justify-content: space-between;
- padding: 10px;
- position: relative;
- }
- .uni-list {
- border: 1xp solid #eee;
- }
- .to-right-icon {
- width: 15px;
- height: 15px;
- position: absolute;
- top: 50%;
- transform: translateY(-50%);
- }
- .text {
- font-size: 16px;
- color: #333;
- }
- .tj-btn {
- height: 69rpx;
- background: #3184f0;
- border-radius: 6rpx;
- font-size: 25rpx;
- font-weight: 400;
- color: #FFFFFF;
- line-height: 69rpx;
- margin: 40rpx 70rpx;
- }
- .sc-btn {
- height: 69rpx;
- background: #f0686b;
- border-radius: 6rpx;
- font-size: 25rpx;
- font-weight: 400;
- color: #FFFFFF;
- line-height: 69rpx;
- margin: 40rpx;
- }
- // .gesture-area {
- // //加浮动弹窗
- // width: 100%;
- // height: 100%;
- // }
- </style>
|