indoor.vue 67 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070
  1. <template>
  2. <scroll-view>
  3. <view class="background">
  4. <view>
  5. <view style="font-size: 16px;margin-left: 10px;margin-top: 10px;display: flex; justify-content: space-between;margin-bottom: 10px;">
  6. <view style="display: flex;align-items: center;">房间信息
  7. <image :src="loadImgSrc('icon_copy.png')" @click='copyAddress()' style="display: flex;justify-content:flex-end; margin-left: 10px;width: 15px;height: 15px;">
  8. </image>
  9. </view>
  10. <image v-if="changefj==false" :src="loadImgSrc('icon_user_open.png')" @click='this.changefj = !this.changefj' style="display: flex;justify-content:flex-end; margin-right: 10px;width: 15px;height: 15px;">
  11. </image>
  12. <image v-if="changefj==true" :src="loadImgSrc('icon_user_close.png')" @click='this.changefj = !this.changefj' style="display: flex;justify-content:flex-end; margin-right: 10px;width: 15px;height: 15px;">
  13. </image>
  14. </view>
  15. </view>
  16. <view v-show="changefj">
  17. <view class="uni-list">
  18. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  19. <view>
  20. 行政区
  21. </view>
  22. <view v-if="this.isEmpty(this.XZQValue.dictValue)" style="margin-top: 10;" @click="pickerShow('xzq')">
  23. <span style="color: darkgray;">请选择行政区</span>
  24. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  25. </view>
  26. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('xzq')">
  27. <span style="color: black;">{{XZQValue.dictLabel}}</span>
  28. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  29. </view>
  30. </view>
  31. </view>
  32. <view class="uni-list">
  33. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  34. <view>
  35. 小区
  36. </view>
  37. <view v-if="this.isEmpty(this.XQValue.id)" class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('xq')">
  38. <span style="color: darkgray;">请选择小区</span>
  39. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  40. </view>
  41. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('xq')">
  42. <span style="color: black;">{{XQValue.name}}</span>
  43. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  44. </view>
  45. </view>
  46. </view>
  47. <view class="uni-list">
  48. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  49. <view class="uni-list-cell-left">
  50. 楼栋
  51. </view>
  52. <view v-if="this.isEmpty(this.LDValue.id)" class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('ld')">
  53. <span style="color: darkgray;">请选择楼栋</span>
  54. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  55. </view>
  56. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('ld')">
  57. <span style="color: black;">{{LDValue.name}}</span>
  58. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  59. </view>
  60. </view>
  61. </view>
  62. <view class="uni-list" style="margin-top: 10;">
  63. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  64. <view class="uni-list-cell-left">
  65. 单元
  66. </view>
  67. <view v-if="this.isEmpty(this.DYValue.id)" class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('dy')">
  68. <span style="color: darkgray;">请选择单元</span>
  69. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  70. </view>
  71. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('dy')">
  72. <span style="color: black;">{{DYValue.name}}</span>
  73. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  74. </view>
  75. </view>
  76. </view>
  77. <view class="uni-list">
  78. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  79. <view class="uni-list-cell-left">
  80. 房间
  81. </view>
  82. <view v-if="this.isEmpty(this.FJValue.id)" class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('fj')">
  83. <span style="color: darkgray;">请选择房间</span>
  84. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  85. </view>
  86. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('fj')">
  87. <span style="color: black;">{{FJValue.name}}</span>
  88. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  89. </view>
  90. </view>
  91. <view v-for="(user,index) in currentResidentsPhoe" :key="index" class="num-style">
  92. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  93. <spane>现住人电话</spane>
  94. <view style="display: flex; justify-content: flex-end; ">
  95. <input class="uni-input" type="tel" v-model="user.phone" maxlength="11" style="text-align: center; border: 1px solid #00aaff; border-radius: 20rpx; "></input>
  96. </view>
  97. </view>
  98. <button v-if="index!=0" @click="this.currentResidentsPhoe.splice(index,1)" class="sc-btn">删除</button>
  99. </view>
  100. <button @click="this.currentResidentsPhoe.push({phone:''})" class="tj-btn">添加</button>
  101. </view>
  102. </view>
  103. </view>
  104. <SelectPicker :list="selectList" @change="changeSelect" v-if="open" @close="close" titleKey="name" subtitleKey="id" v-model="name"></SelectPicker>
  105. <SelectPicker :list="dictOptions" @change="changeSelectDict" v-if="openDict" @close="closeDict" titleKey="dictLabel" subtitleKey="dictValue" v-model="name"></SelectPicker>
  106. </view>
  107. <view class="background">
  108. <input class="uni-input" type="idcard" v-model="idCard" maxlength="18" placeholder="请输入身份证号码" style="text-align: center; border: 1px solid #00aaff; border-radius: 20rpx; "></input>
  109. </view>
  110. <button class="tj-btn" style="margin: 40rpx 90rpx;" @click="serchByCard"> 搜索</button>
  111. <view class="background">
  112. <view>
  113. <view style="font-size: 16px;margin-left: 10px;margin-top: 10px;display: flex; justify-content: space-between;margin-bottom: 10px;">
  114. 户主信息
  115. <image v-if="change==false" :src="loadImgSrc('icon_user_open.png')" @click='change1' style="display: flex;justify-content:flex-end; margin-right: 10px;width: 15px;height: 15px;">
  116. </image>
  117. <image v-if="change==true" :src="loadImgSrc('icon_user_close.png')" @click='change1' style="display: flex;justify-content:flex-end; margin-right: 10px;width: 15px;height: 15px;">
  118. </image>
  119. </view>
  120. </view>
  121. <view v-show="change">
  122. <view class="uni-list">
  123. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  124. <view class="uni-list-cell-left">
  125. 户主姓名
  126. </view>
  127. <view class="uni-list-cell-db" style="margin-top: 10;">
  128. <span style="color: darkgray;" v-model="houseHeadName">{{houseHeadName}}</span>
  129. </view>
  130. </view>
  131. </view>
  132. <view class="uni-list">
  133. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  134. <view class="uni-list-cell-left">
  135. 户主电话
  136. </view>
  137. <view class="uni-list-cell-db" style="margin-top: 10;">
  138. <span style="color: darkgray;" v-model="houseHeadPhone">{{houseHeadPhone}}</span>
  139. </view>
  140. </view>
  141. </view>
  142. <view class="uni-list">
  143. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  144. <view class="uni-list-cell-left">
  145. 户主身份证号码
  146. </view>
  147. <view class="uni-list-cell-db" style="margin-top: 10;">
  148. <span style="color: darkgray;" v-model="houseHeadIDcardNumber">{{houseHeadIDcardNumber}}</span>
  149. </view>
  150. </view>
  151. </view>
  152. <view class="uni-list">
  153. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  154. <view class="uni-list-cell-left">
  155. 管理所
  156. </view>
  157. <view class="uni-list-cell-db" style="margin-top: 10;">
  158. <span style="color: darkgray;" v-model="administrative">{{administrative}}</span>
  159. </view>
  160. </view>
  161. </view>
  162. </view>
  163. </view>
  164. <!--报警器切断阀-->
  165. <view class="background">
  166. <view v-if="objValue.enginClassValue=='报警器'||objValue.enginClassValue=='切断阀'">
  167. <view class="uni-list">
  168. <view style="font-size: 16px;margin-left: 10px;margin-top: 10px;display: flex; justify-content: space-between; margin-bottom: 10px;">
  169. {{objValue.enginClassValue}}
  170. <span style="color: blue;font-size: 14px; display: flex;justify-content:flex-end; margin-right: 10px;" @click="history" v-if="objValue.enginType == 'old_renovation'">{{historyName}}</span>
  171. </view>
  172. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  173. <text>厂 家</text>
  174. <view v-if="this.isEmpty(this.brandValue.id)" style="margin-top: 10;" @click="pickerShow('brand')">
  175. <span style="color: darkgray;">请选择厂家</span>
  176. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  177. </view>
  178. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('brand')">
  179. <span style="color: black;">{{brandValue.name}}</span>
  180. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  181. </view>
  182. </view>
  183. </view>
  184. </view>
  185. <!--拆旧管-->
  186. <view v-if="objValue.enginClassValue=='拆旧管'">
  187. <view class="uni-list">
  188. <view style="font-size: 16px;margin-left: 10px;margin-top: 10px;display: flex; justify-content: space-between;margin-bottom: 10px;">
  189. 拆旧管
  190. <span style="color: blue;font-size: 14px; display: flex;justify-content:flex-end; margin-right: 10px;" @click="history" v-if="objValue.enginType == 'old_renovation'">{{historyName}}</span>
  191. </view>
  192. <view class="container" style="margin-bottom: 20PX;border-bottom: 1px solid #f8f8f8;">
  193. <view>
  194. 腐蚀等级
  195. </view>
  196. <view v-if="this.isEmpty(this.LevelValue.id)" style="margin-top: 10;" @click="pickerShow('fsdj')">
  197. <span style="color: darkgray;">请选择腐蚀等级</span>
  198. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  199. </view>
  200. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('fsdj')">
  201. <span style="color: black;">{{LevelValue.name}}</span>
  202. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  203. </view>
  204. </view>
  205. </view>
  206. </view>
  207. <view v-if="objValue.enginClassValue=='打孔'">
  208. <view class="uni-list">
  209. <view style="font-size: 16px;margin-left: 10px;margin-top: 10px;display: flex; justify-content: space-between;margin-bottom: 10px;">
  210. 打孔
  211. <span style="color: blue;font-size: 14px; display: flex;justify-content:flex-end; margin-right: 10px;" @click="history" v-if="objValue.enginType == 'old_renovation'">{{historyName}}</span>
  212. </view>
  213. <!-- <view class="container" style="margin-bottom: 20PX;border-bottom: 1px solid #f8f8f8;">
  214. <view>
  215. 孔距
  216. </view>
  217. <view v-if="this.isEmpty(this.LevelValue.id)" style="margin-top: 10;"
  218. @click="pickerShow('kj')">
  219. <span style="color: darkgray;">请选择孔距</span>
  220. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  221. </view>
  222. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('kj')">
  223. <span style="color: black;">{{LevelValue.name}}</span>
  224. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  225. </view>
  226. </view> -->
  227. </view>
  228. </view>
  229. <!--立杠-->
  230. <view v-else-if="objValue.enginClassValue=='立杠'">
  231. <view class="uni-list" style="margin-bottom: 20px;">
  232. <view style="font-size: 16px;margin-left: 10px;margin-top: 10px;display: flex; justify-content: space-between;margin-bottom: 10px;">
  233. 立杠
  234. <span style="color: blue;font-size: 14px; display: flex;justify-content:flex-end; margin-right: 10px;" @click="history" v-if="objValue.enginType == 'old_renovation'">{{historyName}}</span>
  235. </view>
  236. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  237. <view>
  238. 材 质
  239. </view>
  240. <view v-if="this.isEmpty(this.materialValue.id)" style="margin-top: 10;" @click="pickerShow('cz')">
  241. <span style="color: darkgray;">请选择材质</span>
  242. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  243. </view>
  244. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('cz')">
  245. <span style="color: black;">{{materialValue.name}}</span>
  246. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  247. </view>
  248. </view>
  249. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  250. <view>
  251. 规 格
  252. </view>
  253. <view v-if="this.isEmpty(this.specificationValue.id)" style="margin-top: 10;" @click="pickerShow('gg')">
  254. <span style="color: darkgray;">请选择规格</span>
  255. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  256. </view>
  257. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('gg')">
  258. <span style="color: black;">{{specificationValue.name}}</span>
  259. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  260. </view>
  261. </view>
  262. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  263. <text>米 数</text>
  264. <!-- style="margin-left: 10px;text-align: right;" -->
  265. <view style="display: flex; justify-content: right; width: 70%;">
  266. <input class="uni-input" type="number" v-model="inputIntegerNumberValue" maxlength="6" style="text-align: center; border: 1px solid #00aaff; border-radius: 20rpx;"></input>
  267. <text style="font-weight:bold;margin-left: 10px;margin-right: 10px;">.</text>
  268. <input class="uni-input" type="number" v-model="inputDecimalNumberValue" maxlength="1" style="text-align: center; border: 1px solid #00aaff; border-radius: 20rpx;"></input>
  269. </view>
  270. </view>
  271. </view>
  272. </view>
  273. <!--挂表-->
  274. <view v-else-if="objValue.enginClassValue=='挂表'">
  275. <view class="uni-list" style="margin-bottom: 20px;">
  276. <view style="font-size: 16px;margin-left: 10px;margin-top: 10px;display: flex; justify-content: space-between;margin-bottom: 10px;">
  277. 挂表
  278. <span style="color: blue;font-size: 14px; display: flex;justify-content:flex-end; margin-right: 10px;" @click="history" v-if="objValue.enginType == 'old_renovation'">{{historyName}}</span>
  279. </view>
  280. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  281. <view>
  282. 品 牌
  283. </view>
  284. <view v-if="this.isEmpty(this.brandValue.id)" style="margin-top: 10;" @click="pickerShow('brand')">
  285. <span style="color: darkgray;">请选择品牌</span>
  286. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  287. </view>
  288. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('brand')">
  289. <span style="color: black;">{{brandValue.name}}</span>
  290. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  291. </view>
  292. </view>
  293. </view>
  294. </view>
  295. <!--表后管-->
  296. <view v-else-if="objValue.enginClassValue=='表后管'">
  297. <view class="uni-list" style="margin-bottom: 20px;">
  298. <view style="font-size: 16px;margin-left: 10px;margin-top: 10px;display: flex; justify-content: space-between;margin-bottom: 10px;">
  299. 表后管
  300. <span style="color: blue;font-size: 14px; display: flex;justify-content:flex-end; margin-right: 10px;" @click="history" v-if="objValue.enginType == 'old_renovation'">{{historyName}}</span>
  301. </view>
  302. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  303. <view>
  304. 材 质
  305. </view>
  306. <view v-if="this.isEmpty(this.materialValue.id)" style="margin-top: 10;" @click="pickerShow('cz')">
  307. <span style="color: darkgray;">请选择材质</span>
  308. </view>
  309. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('cz')">
  310. <span style="color: black;">{{materialValue.name}}</span>
  311. </view>
  312. </view>
  313. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  314. <view>
  315. 规 格
  316. </view>
  317. <view v-if="this.isEmpty(this.specificationValue.id)" style="margin-top: 10;" @click="pickerShow('gg')">
  318. <span style="color: darkgray;">请选择规格</span>
  319. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  320. </view>
  321. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('gg')">
  322. <span style="color: black;">{{specificationValue.name}}</span>
  323. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  324. </view>
  325. </view>
  326. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  327. <text>米 数</text>
  328. <!-- style="margin-left: 10px;text-align: right;" -->
  329. <view style="display: flex; justify-content: right; width: 70%;">
  330. <input class="uni-input" type="number" v-model="inputIntegerNumberValue" maxlength="6" style="text-align: center; border: 1px solid #00aaff; border-radius: 20rpx;"></input>
  331. <text style="font-weight:bold;margin-left: 10px;margin-right: 10px;">.</text>
  332. <input class="uni-input" type="number" v-model="inputDecimalNumberValue" maxlength="1" style="text-align: center; border: 1px solid #00aaff; border-radius: 20rpx;"></input>
  333. </view>
  334. </view>
  335. </view>
  336. </view>
  337. <!--阀管-->
  338. <view v-else-if="objValue.enginClassValue=='阀管'">
  339. <view class="uni-list" style="margin-bottom: 20px;">
  340. <view style="font-size: 16px;margin-left: 10px;margin-top: 10px;display: flex; justify-content: space-between;margin-bottom: 10px;">
  341. 阀管
  342. <span style="color: blue;font-size: 14px; display: flex;justify-content:flex-end; margin-right: 10px;" @click="history" v-if="objValue.enginType == 'old_renovation'">{{historyName}}</span>
  343. </view>
  344. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  345. <view>
  346. 上门类型
  347. </view>
  348. <view v-if="this.isEmpty(this.doorValue.dictValue)" style="margin-top: 10;" @click="pickerShow('door')">
  349. <span style="color: darkgray;">请选择上门类型</span>
  350. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  351. </view>
  352. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('door')">
  353. <span style="color: black;">{{doorValue.dictLabel}}</span>
  354. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  355. </view>
  356. </view>
  357. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  358. <view>
  359. 自闭阀厂家
  360. </view>
  361. <view v-if="this.isEmpty(this.SelfClosValve.id)" style="margin-top: 10;" @click="pickerShow('zbf')">
  362. <span style="color: darkgray;">请选择自闭阀厂家</span>
  363. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  364. </view>
  365. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('zbf')">
  366. <span style="color: black;">{{SelfClosValve.name}}</span>
  367. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  368. </view>
  369. </view>
  370. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  371. <view>
  372. 灶具管厂家
  373. </view>
  374. <view v-if="this.isEmpty(this.materialValue.id)" style="margin-top: 10;" @click="pickerShow('cz')">
  375. <span style="color: darkgray;">请选择灶具管厂家</span>
  376. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  377. </view>
  378. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('cz')">
  379. <span style="color: black;">{{materialValue.name}}</span>
  380. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  381. </view>
  382. </view>
  383. <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  384. <view>
  385. 规 格
  386. </view>
  387. <view v-if="this.isEmpty(this.specificationValue.id)" style="margin-top: 10;" @click="pickerShow('gg')">
  388. <span style="color: darkgray;">请选择规格</span>
  389. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  390. </view>
  391. <view v-else class="uni-list-cell-db" style="margin-top: 10;" @click="pickerShow('gg')">
  392. <span style="color: black;">{{specificationValue.name}}</span>
  393. <image :src="loadImgSrc('icon_right.png')" class="to-right-icon"></image>
  394. </view>
  395. </view>
  396. <!-- <view class="container" style="border-bottom: 1px solid #f8f8f8;">
  397. <text>米 数</text>
  398. <view style="display: flex; justify-content: right; width: 70%;">
  399. <input class="uni-input" type="number" v-model="inputIntegerNumberValue" maxlength="6"
  400. style="text-align: center; border: 1px solid #00aaff; border-radius: 20rpx;"></input>
  401. <text style="font-weight:bold;margin-left: 10px;margin-right: 10px;">.</text>
  402. <input class="uni-input" type="number" v-model="inputDecimalNumberValue" maxlength="1"
  403. style="text-align: center; border: 1px solid #00aaff; border-radius: 20rpx;"></input>
  404. </view>
  405. </view> -->
  406. </view>
  407. </view>
  408. <view class="align-items" style="margin-top: 20px;margin-bottom: 20px;">
  409. <view class="container" style="color: #b2b2b2;">*请上传照片</view>
  410. <view class="" style="display: flex; flex-wrap: wrap;margin-top: 10px; margin-left: 10px;">
  411. <image :src="loadImgSrc('updateimg.png')" mode="" style="width: 200rpx; height: 150rpx; margin: 0 12rpx;; " @click="choose()" v-show="reviewStatus!='1'"></image>
  412. <view v-for="(item,index) in imgArr" :key="index" style="position: relative;">
  413. <view v-if="item.substring(item.length - 3) == 'png' || item.substring(item.length - 3) == 'jpg'||item.substring(item.length-4)=='jpeg' ">
  414. <image :src="item" mode="" style="width: 200rpx; height: 200rpx; margin: 0 12rpx;" @click="showPhoto(index)">
  415. </image>
  416. </view>
  417. <view v-else>
  418. <video :src="item" style="width: 200rpx; height: 200rpx; margin: 0 12rpx;"></video>
  419. </view>
  420. <view @click="remove(index)" style="position: absolute; top: 0; right: 14rpx; border-radius: 50%;">
  421. <image :src="loadImgSrc('icon_close.png')" style=" width: 15px; height: 15px;">
  422. </image>
  423. </view>
  424. </view>
  425. </view>
  426. <view v-if="objValue.enginType == 'old_renovation'" style="margin-top: 10px;">
  427. <view v-if="objValue.enginClassValue=='拆旧管'">
  428. <span class="container-text">(1)拆除前照片(能体现出周边环境的宏观照片)</span>
  429. <span class="container-text">(2)拆除的立杠照片(如腐蚀严重需增加腐蚀处特写照片)</span>
  430. <span class="container-text">(3)立杠腐蚀照片</span>
  431. </view>
  432. <view v-if="objValue.enginClassValue=='立杠'">
  433. <span class="container-text">改造完成后的宏观照片,热收缩套照片,立杠要求有卡子及三通、表弯头、立杠刷油均匀</span>
  434. </view>
  435. <view v-if="objValue.enginClassValue=='挂表'">
  436. <span class="container-text">安装后的业主家燃气表正面能看清相关信息的照片</span>
  437. </view>
  438. <view v-if="objValue.enginClassValue=='表后管'">
  439. <span class="container-text">表后管整体照片+表至自闭阀区间的管道走向视频,表后管需按照施工标准横平竖直且有卡子固定</span>
  440. </view>
  441. <view v-if="objValue.enginClassValue=='阀管'">
  442. <span class="container-text">(1)自闭阀照片(自闭阀必须安装底座)</span>
  443. <span class="container-text">(2)灶具连接处照片</span>
  444. <span class="container-text">(3)打压照片</span>
  445. <span class="container-text">(4)回执单照片</span>
  446. </view>
  447. </view>
  448. </view>
  449. </view>
  450. <view class=" action-btn" v-show="reviewStatus!='1'" style="display: flex;padding: 5px;">
  451. <button @click="submit('submit')" class="btn cu-btn block bg-blue lg round" style="margin-right: 10px;">确认上传</button>
  452. <button @click="submit('save')" class="btn cu-btn block bg-blue lg round" v-if="objValue.enginType == 'old_renovation'">暂存</button>
  453. </view>
  454. <bottom-sheet ref="refShare" :data="historyList"></bottom-sheet>
  455. </scroll-view>
  456. </template>
  457. <script>
  458. import SelectPicker from '../../../components/selectPicker/select_picker.vue'
  459. import bottomSheet from '../../../components/bottomSheet/bottomSheet.vue'
  460. import {
  461. getDicts
  462. } from "@/api/system/dict/data";
  463. import {
  464. getAreaList,
  465. getBuildingList,
  466. getUnitList,
  467. getHousesList,
  468. addTearOldPipe,
  469. getEnginMaterialQualityList,
  470. getEnginSpecificationsList,
  471. getRoomProjectList,
  472. getRoomProjectId,
  473. getRoomDetailsIDCard,
  474. putRoomDetails
  475. } from '@/api/common'
  476. import {
  477. getToken
  478. } from '../../../utils/auth';
  479. import {
  480. showConfirm
  481. } from '../../../utils/common';
  482. import {
  483. login
  484. } from '../../../api/login';
  485. export default {
  486. components: {
  487. SelectPicker,
  488. bottomSheet
  489. },
  490. data() {
  491. return {
  492. headers: {
  493. Authorization: "Bearer " + getToken()
  494. },
  495. historyName: '恢复暂存',
  496. houseHeadName: '',
  497. houseHeadPhone: '',
  498. houseHeadIDcardNumber: '',
  499. administrative: '',
  500. type: '',
  501. changefj: false,
  502. change: false,
  503. open: false,
  504. reviewStatus: '', //是否可以点击
  505. objValue: '', //上一页面传过来的值 新增接口用
  506. openDict: false,
  507. selectList: [],
  508. dictOptions: [],
  509. imgArr: [],
  510. idCard: '',
  511. XQValue: {},
  512. XZQValue: {},
  513. projectValue: {
  514. 'dictValue': '0'
  515. },
  516. currentResidentsPhoe: [{
  517. phone: ''
  518. }],
  519. LevelValue: {},
  520. LDValue: {},
  521. DYValue: {},
  522. FJValue: {},
  523. specificationValue: {}, //规格
  524. materialValue: {}, //材质
  525. brandValue: {}, //品牌
  526. doorValue: {}, //上门类型
  527. SelfClosValve: {}, //自闭阀类型
  528. materialList: '', //材质list
  529. XQList: '',
  530. LDList: '',
  531. DYList: '',
  532. FJList: '',
  533. progress: 0, //上传图片进度百分比
  534. loading: false,
  535. isCheck: true, //是否按照施工图纸施工
  536. inputNumberValue: '',
  537. inputIntegerNumberValue: '',
  538. inputDecimalNumberValue: '',
  539. title: '',
  540. historyList: {}, //历史数据
  541. tempState: '',
  542. tempSelectList: [],
  543. }
  544. },
  545. created() {
  546. },
  547. onLoad(options) {
  548. if ('params' in options) {
  549. this.objValue = JSON.parse(decodeURIComponent(options.params));
  550. if (this.objValue.enginType == `old_renovation`) {
  551. this.title = '旧改工程-室内'
  552. } else if (this.objValue.enginType == `new_built`) {
  553. this.title = '新建工程-室内'
  554. }
  555. uni.setNavigationBarTitle({
  556. title: this.title
  557. })
  558. }
  559. },
  560. methods: {
  561. copyAddress() {
  562. if (uni.getStorageSync('XZQValue') != {}) {
  563. this.type = 'xzq';
  564. this.changeSelectDict(uni.getStorageSync('XZQValue'));
  565. }
  566. if (uni.getStorageSync('XQValue') != {}) {
  567. this.type = 'xq';
  568. this.changeSelect(uni.getStorageSync('XQValue'))
  569. }
  570. if (uni.getStorageSync('LDValue') != {}) {
  571. this.type = 'ld';
  572. this.changeSelect(uni.getStorageSync('LDValue'))
  573. }
  574. if (uni.getStorageSync('DYValue') != {}) {
  575. this.type = 'dy';
  576. this.changeSelect(uni.getStorageSync('DYValue'))
  577. }
  578. if (uni.getStorageSync('FJValue') != {}) {
  579. this.type = 'fj';
  580. this.changeSelect(uni.getStorageSync('FJValue'))
  581. }
  582. },
  583. //判断是否选择
  584. isEmpty(str) {
  585. return (!str || 0 === str.length);
  586. },
  587. change1() {
  588. this.change = !this.change
  589. },
  590. // 显示历史弹窗
  591. handleShowSheet() {
  592. this.shareState = true;
  593. },
  594. // 隐藏历史弹窗
  595. handleHiddenShare() {
  596. this.shareState = false;
  597. },
  598. showPhoto(index) {
  599. uni.previewImage({
  600. current: index,
  601. urls: this.imgArr,
  602. })
  603. },
  604. remove(index) {
  605. uni.showModal({
  606. title: '提示',
  607. content: '是否删除该图片或视频?',
  608. success: (res) => {
  609. if (res.confirm) {
  610. this.imgArr.splice(index, 1)
  611. if (this.imgArr.length <= 0) {
  612. this.photo = true;
  613. }
  614. }
  615. }
  616. })
  617. },
  618. choose() {
  619. let _this = this;
  620. uni.showActionSheet({
  621. title: '上传',
  622. itemList: ['图片', '视频'],
  623. success: (res) => {
  624. if (res.tapIndex == 0) {
  625. this.chooseimage()
  626. } else {
  627. this.choosevideo()
  628. }
  629. }
  630. })
  631. },
  632. chooseimage() {
  633. let _this = this;
  634. uni.chooseImage({
  635. sourceType: this.objValue.enginType == `old_renovation` ? ['camera'] : ['album', 'camera'],
  636. success(resp) {
  637. resp.tempFiles.forEach((item, index) => {
  638. const task = uni.uploadFile({
  639. url: _this.$HTTP + `/obs`,
  640. filePath: item.path,
  641. name: 'file',
  642. formData: {},
  643. header: _this.headers,
  644. success: res => {
  645. // 判断是否json字符串,将其转为json格式
  646. // let data = _this.$u.test.jsonString(res
  647. // .data) ? JSON.parse(res.data) : res.data;
  648. let data = JSON.parse(res.data);
  649. if (![200].includes(data.code)) {
  650. // this.uploadError(index, data);
  651. _this.$modal.msg(data.msg)
  652. } else {
  653. if (_this.progress === 100) {
  654. _this.imgArr.push(data.data.url)
  655. _this.$modal.msg('上传成功!')
  656. _this.photo = false;
  657. }
  658. }
  659. },
  660. fail: e => {
  661. _this.$modal.msg('上传失败!')
  662. //_this.uploadError(index, e);
  663. },
  664. complete: res => {
  665. uni.hideLoading();
  666. _this.uploading = false;
  667. }
  668. });
  669. task.onProgressUpdate(res => {
  670. _this.progress = res.progress;
  671. uni.showLoading({
  672. title: '上传中'
  673. })
  674. if (_this.progress != 100) {
  675. _this.loading = false
  676. } else {
  677. _this.loading = true
  678. }
  679. });
  680. })
  681. },
  682. })
  683. },
  684. choosevideo() {
  685. let _this = this;
  686. uni.chooseVideo({
  687. sourceType: this.objValue.enginType == `old_renovation` ? ['camera'] : ['album', 'camera'],
  688. maxDuration: 30,
  689. success(resp) {
  690. const task = uni.uploadFile({
  691. url: _this.$HTTP + `/obs`,
  692. filePath: resp.tempFilePath,
  693. name: 'file',
  694. formData: {},
  695. header: _this.headers,
  696. success: res => {
  697. // 判断是否json字符串,将其转为json格式
  698. let data = JSON.parse(res.data);
  699. if (![200].includes(res.statusCode)) {
  700. this.uploadError(index, data);
  701. } else {
  702. //上传成功
  703. if (_this.progress === 100) {
  704. _this.imgArr.push(data.data.url)
  705. _this.$modal.msg('上传成功!')
  706. _this.photo = false;
  707. }
  708. }
  709. },
  710. fail: e => {
  711. _this.$modal.msg('上传失败!')
  712. this.uploadError(index, e);
  713. },
  714. complete: res => {
  715. uni.hideLoading();
  716. _this.uploading = false;
  717. }
  718. });
  719. task.onProgressUpdate(res => {
  720. _this.progress = res.progress;
  721. uni.showLoading({
  722. title: '上传中'
  723. })
  724. if (_this.progress != 100) {
  725. _this.loading = false
  726. } else {
  727. _this.loading = true
  728. }
  729. });
  730. },
  731. })
  732. },
  733. pickerShow(e) {
  734. this.type = e; //赋值类型
  735. if (e == 'door') { //上门类型
  736. this.openDict = true;
  737. getDicts("visit_type").then(response => {
  738. this.dictOptions = response.data;
  739. });
  740. } else if (e == 'zbf') { //自闭阀类型
  741. this.open = true;
  742. getEnginMaterialQualityList("民用工程", this.objValue.enginType, this.objValue.enginClassification, this
  743. .objValue.enginClassValue, '自闭阀厂家').then(response => {
  744. this.selectList = response.data;
  745. });
  746. } else if (e == 'brand') { //品牌
  747. this.open = true;
  748. getEnginMaterialQualityList("民用工程", this.objValue.enginType, this.objValue.enginClassification, this
  749. .objValue.enginClassValue).then(response => {
  750. this.selectList = response.data;
  751. });
  752. } else if (e == 'cz') { //材质
  753. this.open = true;
  754. if (this.objValue.enginClassValue == '阀管') {
  755. getEnginMaterialQualityList("民用工程", this.objValue.enginType, this.objValue.enginClassification,
  756. this
  757. .objValue.enginClassValue, "灶具管厂家").then(response => {
  758. this.selectList = response.data;
  759. });
  760. } else {
  761. getEnginMaterialQualityList("民用工程", this.objValue.enginType, this.objValue.enginClassification,
  762. this
  763. .objValue.enginClassValue).then(response => {
  764. this.selectList = response.data;
  765. });
  766. }
  767. } else if (e == 'gg') { //规格
  768. if (this.isEmpty(this.materialValue.id)) {
  769. if (this.objValue.enginClassValue == '阀管') {
  770. this.$modal.msg('请选择灶具管厂家')
  771. } else {
  772. this.$modal.msg('请选择材质')
  773. }
  774. } else {
  775. this.open = true;
  776. this.selectList = this.materialList;
  777. }
  778. } else if (e == 'fsdj') {
  779. this.open = true;
  780. getEnginMaterialQualityList("民用工程", this.objValue.enginType, this.objValue.enginClassification, this
  781. .objValue.enginClassValue).then(response => {
  782. this.selectList = response.data;
  783. });
  784. } else if (e == 'kj') {
  785. //孔距
  786. this.open = true;
  787. getEnginMaterialQualityList("民用工程", this.objValue.enginType, this.objValue.enginClassification, this
  788. .objValue.enginClassValue).then(response => {
  789. this.selectList = response.data;
  790. });
  791. } else if (e == 'gczq') { //工程周期
  792. this.openDict = true;
  793. getDicts("engin_cycle").then(response => {
  794. this.dictOptions = response.data;
  795. });
  796. } else if (e == 'xzq') { //行政区
  797. if (this.isEmpty(this.projectValue.dictValue)) {
  798. this.$modal.msg('请选择工程周期')
  799. } else {
  800. this.openDict = true;
  801. getDicts("district").then(response => {
  802. this.dictOptions = response.data;
  803. });
  804. }
  805. //this.selectList = this.dictOptions;
  806. } else if (e == 'xq') { //小区
  807. if (this.isEmpty(this.XZQValue.dictValue)) {
  808. getAreaList('').then(res => {
  809. this.XQList = res.data;
  810. this.open = true;
  811. this.selectList = this.XQList;
  812. })
  813. } else {
  814. this.open = true;
  815. this.selectList = this.XQList;
  816. }
  817. } else if (e == 'ld') { //楼栋
  818. if (this.isEmpty(this.XQValue.id)) {
  819. this.$modal.msg('请选择小区')
  820. } else {
  821. this.open = true;
  822. this.selectList = this.LDList;
  823. }
  824. } else if (e == 'dy') { //单元
  825. if (this.isEmpty(this.LDValue.id)) {
  826. this.$modal.msg('请选择楼栋')
  827. } else {
  828. this.open = true;
  829. this.selectList = this.DYList;
  830. }
  831. } else if (e == 'fj') { //房间
  832. if (this.isEmpty(this.DYValue.id)) {
  833. this.$modal.msg('请选择单元')
  834. } else {
  835. this.open = true;
  836. this.selectList = this.FJList;
  837. }
  838. }
  839. },
  840. switchChange(e) {
  841. //'switch 发生 change 事件,携带值为', e.detail.value)
  842. this.isCheck = e.detail.value;
  843. },
  844. changeSelectDict(item, index) {
  845. this.openDict = false;
  846. if (this.type == 'door') {
  847. this.doorValue = item
  848. } else if (this.type == 'gczq') {
  849. this.projectValue = item
  850. if (!this.isEmpty(this.FJValue.id)) {
  851. //房间选完 判断 工程周期 工程周期切换
  852. this.getStatus();
  853. }
  854. } else if (this.type == 'xzq') {
  855. this.XZQValue = item;
  856. //根据行政区id获取小区数据
  857. this.XQValue = ''; //重置小区数据
  858. this.LDValue = ''; //重置楼栋数据
  859. this.DYValue = ''; //重置单元数据
  860. this.FJValue = ''; //重置房间数据
  861. this.currentResidentsPhoe = [];
  862. //this.historyName = "";
  863. this.houseHeadName = "";
  864. this.houseHeadPhone = "";
  865. this.houseHeadIDcardNumber = "";
  866. this.administrative = "";
  867. getAreaList(item.dictValue).then(res => {
  868. this.XQList = res.data;
  869. })
  870. }
  871. },
  872. changeSelect(item, index) {
  873. // this.index = index;
  874. // this.address = item.communityName;
  875. this.open = false;
  876. if (this.type == 'cz') {
  877. this.materialValue = item;
  878. this.specificationValue = ''; //重置规格
  879. //根据材质ID 获取规格数据
  880. getEnginSpecificationsList(item.id).then(res => {
  881. this.materialList = res.data
  882. })
  883. } else if (this.type == 'gg') {
  884. this.specificationValue = item;
  885. } else if (this.type == 'xq') {
  886. this.XZQValue = {
  887. dictValue: item.district,
  888. dictLabel: item.districtName
  889. };
  890. this.XQValue = item;
  891. //根据小区id 获取楼栋数据
  892. this.LDValue = ''; //重置楼栋数据
  893. this.DYValue = ''; //重置单元数据
  894. this.FJValue = ''; //重置房间数据
  895. this.currentResidentsPhoe = [];
  896. //this.historyName = "";
  897. this.houseHeadName = "";
  898. this.houseHeadPhone = "";
  899. this.houseHeadIDcardNumber = "";
  900. this.administrative = item.administrative;
  901. getBuildingList(item.id).then(res => {
  902. this.LDList = res.data
  903. })
  904. } else if (this.type == 'ld') {
  905. this.LDValue = item;
  906. //根据楼栋ID 获取单元数据
  907. this.DYValue = ''; //重置单元数据
  908. this.FJValue = ''; //重置房间数据
  909. this.currentResidentsPhoe = [];
  910. //this.historyName = "";
  911. this.houseHeadName = "";
  912. this.houseHeadPhone = "";
  913. this.houseHeadIDcardNumber = "";
  914. getUnitList(item.id).then(res => {
  915. this.DYList = res.data
  916. })
  917. } else if (this.type == 'dy') {
  918. this.DYValue = item;
  919. //根据单元数据 获取房间数据
  920. this.FJValue = ''; //重置房间数据
  921. this.currentResidentsPhoe = [];
  922. //this.historyName = "";
  923. this.houseHeadName = "";
  924. this.houseHeadPhone = "";
  925. this.houseHeadIDcardNumber = "";
  926. getHousesList(item.id).then(res => {
  927. this.FJList = res.data
  928. })
  929. } else if (this.type == 'fj') {
  930. this.FJValue = item;
  931. //this.history();
  932. this.houseHeadName = item.houseUserName;
  933. this.houseHeadPhone = item.phone;
  934. this.houseHeadIDcardNumber = item.idCard;
  935. this.currentResidentsPhoe = [];
  936. if (!this.isEmpty(item.newPhone)) {
  937. let str = item.newPhone;
  938. var array = str.split(",");
  939. array.forEach((list) => {
  940. this.currentResidentsPhoe.push({
  941. phone: list
  942. })
  943. })
  944. }
  945. if (!this.isEmpty(this.projectValue.id)) {
  946. //房间选完 判断 工程周期
  947. this.getStatus();
  948. }
  949. } else if (this.type == 'zbf') {
  950. this.SelfClosValve = item
  951. } else if (this.type == 'brand') {
  952. this.brandValue = item
  953. } else {
  954. this.LevelValue = item;
  955. }
  956. },
  957. //关闭弹窗
  958. close(e) {
  959. this.open = false
  960. },
  961. //关闭弹窗
  962. closeDict(e) {
  963. this.openDict = false
  964. },
  965. getStatus() {
  966. let param = {
  967. areaId: this.XQValue.id, // 小区id
  968. buildingId: this.LDValue.id, // 楼宇id
  969. unitId: this.DYValue.id, // 单元id
  970. houseId: this.FJValue.id, // 房间id
  971. enginCycle: this.projectValue.id, // 工程周期
  972. enginType: this.objValue.enginType, //写死 上一页面传过来的
  973. enginClassification: this.objValue.enginClassification, //写死 上一页面传过来的 //室内 - 庭院 - 架空
  974. }
  975. getRoomProjectId(param).then(res => {
  976. if (res.code == '200') {
  977. if (res.data != null && res.data.zEngineeringNodeBoList != null) {
  978. res.data.zEngineeringNodeBoList.forEach((item, index) => {
  979. if (this.objValue.enginClassValue == item.type) {
  980. this.reviewStatus = item.reviewStatus;
  981. if (item.reviewStatus == '1')
  982. this.$modal.msg('当前工程已结束')
  983. }
  984. })
  985. } else {
  986. this.reviewStatus = '' //置空
  987. }
  988. } else {
  989. this.$modal.msg(res.msg)
  990. this.reviewStatus = '' //置空
  991. }
  992. })
  993. },
  994. serchByCard() {
  995. if (this.isEmpty(this.idCard)) {
  996. this.$modal.msg("请输入身份证号码")
  997. return
  998. }
  999. if (!this.$validation.idCard(this.idCard)) {
  1000. this.$modal.msg("身份证号码格式不正确")
  1001. return
  1002. }
  1003. getRoomDetailsIDCard(this.idCard).then(res => {
  1004. if (res.code == '200' && res.data != null) {
  1005. if (!this.isEmpty(res.data.newPhone)) {
  1006. this.currentResidentsPhoe = [];
  1007. let str = res.data.newPhone;
  1008. var array = str.split(",");
  1009. array.forEach((list) => {
  1010. this.currentResidentsPhoe.push({
  1011. phone: list
  1012. })
  1013. })
  1014. }
  1015. this.houseHeadName = res.data.houseUserName;
  1016. this.houseHeadIDcardNumber = res.data.idCard;
  1017. this.houseHeadPhone = res.data.phone;
  1018. this.XZQValue = {
  1019. dictValue: res.data.district,
  1020. dictLabel: res.data.districtName
  1021. };
  1022. this.XQValue = {
  1023. id: res.data.areaId,
  1024. name: res.data.areaName
  1025. }
  1026. this.LDValue = {
  1027. id: res.data.buildingId,
  1028. name: res.data.buildingName
  1029. }
  1030. this.DYValue = {
  1031. id: res.data.unitId,
  1032. name: res.data.unitName
  1033. }
  1034. this.FJValue = {
  1035. id: res.data.id,
  1036. name: res.data.name
  1037. }
  1038. getAreaList(this.XZQValue.dictValue).then(res => {
  1039. this.XQList = res.data;
  1040. })
  1041. getBuildingList(this.XQValue.id).then(res => {
  1042. this.LDList = res.data
  1043. })
  1044. getUnitList(this.LDValue.id).then(res => {
  1045. this.DYList = res.data
  1046. })
  1047. getHousesList(this.DYValue.id).then(res => {
  1048. this.FJList = res.data
  1049. })
  1050. }
  1051. })
  1052. },
  1053. //提交数据
  1054. submit(e) {
  1055. this.tempState = e == 'submit' ? '' : '99'
  1056. if (this.isEmpty(this.projectValue.dictValue)) {
  1057. this.$modal.msg("请选择工程周期")
  1058. return
  1059. }
  1060. if (this.isEmpty(this.XZQValue.dictValue)) {
  1061. this.$modal.msg("请选择行政区")
  1062. return
  1063. }
  1064. if (this.isEmpty(this.XQValue.id)) {
  1065. this.$modal.msg("请选择小区")
  1066. return
  1067. }
  1068. if (this.isEmpty(this.LDValue.id)) {
  1069. this.$modal.msg("请选择楼栋")
  1070. return
  1071. }
  1072. if (this.isEmpty(this.DYValue.id)) {
  1073. this.$modal.msg("请选择单元")
  1074. return
  1075. }
  1076. if (this.isEmpty(this.FJValue.id)) {
  1077. this.$modal.msg("请选择房间")
  1078. return
  1079. }
  1080. if (this.currentResidentsPhoe.length <= 0) {
  1081. this.$modal.msg('现住人电话不能为空');
  1082. return
  1083. }
  1084. try {
  1085. this.currentResidentsPhoe.forEach((list) => {
  1086. if (this.isEmpty(list.phone)) {
  1087. this.$modal.msg('现住人电话不能为空')
  1088. throw new Error('End Loop')
  1089. }
  1090. if (list.phone.length == 11 || list.phone.length == 8) {} else {
  1091. this.$modal.msg('现住人电话填写错误')
  1092. throw new Error('End Loop')
  1093. }
  1094. })
  1095. } catch (e) {
  1096. if (e.message === 'End Loop') throw e
  1097. }
  1098. uni.setStorageSync("XZQValue", this.XZQValue)
  1099. uni.setStorageSync("XQValue", this.XQValue)
  1100. uni.setStorageSync("LDValue", this.LDValue)
  1101. uni.setStorageSync("DYValue", this.DYValue)
  1102. this.FJValue.newPhone = this.currentResidentsPhoe.map(item => item.phone).join();
  1103. uni.setStorageSync("FJValue", this.FJValue)
  1104. if (this.objValue.enginClassValue == '报警器' || this.objValue.enginClassValue == '切断阀') {
  1105. if (e == 'submit') {
  1106. if (this.isEmpty(this.brandValue.id)) {
  1107. this.$modal.msg("请选择厂家")
  1108. } else {
  1109. this.onsubmit(e);
  1110. }
  1111. } else {
  1112. this.onsubmit(e); //暂存
  1113. }
  1114. } else if (this.objValue.enginClassValue == '打孔') {
  1115. // if (this.isEmpty(this.LevelValue.id)) {
  1116. // this.$modal.msg("请选择孔距") //打孔 判断孔距
  1117. // } else {
  1118. this.onsubmit(e);
  1119. //}
  1120. } else if (this.objValue.enginClassValue == '拆旧管') {
  1121. if (e == 'submit') {
  1122. if (this.isEmpty(this.LevelValue.id)) {
  1123. this.$modal.msg("请选择腐蚀等级") //拆旧管 判断腐蚀等级
  1124. } else {
  1125. this.onsubmit(e);
  1126. }
  1127. } else {
  1128. this.onsubmit(e); //暂存
  1129. }
  1130. } else if (this.objValue.enginClassValue == '立杠') {
  1131. //立杠 判断 材质 规格 米数
  1132. if (e == 'submit') {
  1133. if (this.isEmpty(this.materialValue.id)) {
  1134. this.$modal.msg("请选择材质")
  1135. } else if (this.isEmpty(this.specificationValue.id)) {
  1136. this.$modal.msg("请选择规格")
  1137. } else if (this.isEmpty(this.inputIntegerNumberValue)) {
  1138. this.$modal.msg("请输入米数")
  1139. } else {
  1140. if (this.isEmpty(this.inputDecimalNumberValue)) {
  1141. this.inputNumberValue = this.inputIntegerNumberValue;
  1142. } else {
  1143. this.inputNumberValue = this.inputIntegerNumberValue + "." + this.inputDecimalNumberValue;
  1144. }
  1145. this.onsubmit(e);
  1146. }
  1147. } else {
  1148. this.onsubmit(e); //暂存
  1149. }
  1150. } else if (this.objValue.enginClassValue == '挂表') {
  1151. //挂表 判断 品牌
  1152. if (e == 'submit') {
  1153. if (this.isEmpty(this.brandValue.id)) {
  1154. this.$modal.msg("请选择品牌")
  1155. } else {
  1156. this.onsubmit(e);
  1157. }
  1158. } else {
  1159. this.onsubmit(e);
  1160. }
  1161. } else if (this.objValue.enginClassValue == '表后管') {
  1162. //表后管 判断 材质 规格 米数 (为必须有一张照片和一个视频)
  1163. if (e == 'submit') {
  1164. if (this.isEmpty(this.materialValue.id)) {
  1165. this.$modal.msg("请选择材质")
  1166. } else if (this.isEmpty(this.specificationValue.id)) {
  1167. this.$modal.msg("请选择规格")
  1168. } else if (this.isEmpty(this.inputIntegerNumberValue)) {
  1169. this.$modal.msg("请输入米数")
  1170. } else {
  1171. const hasImage = this.imgArr.some(item => item.endsWith('.jpg') || item.endsWith(
  1172. '.png') || item
  1173. .endsWith('.jpeg') || item.endsWith('.JPG') || item.endsWith('.PNG') || item
  1174. .endsWith('.JPEG'));
  1175. const hasVideo = this.imgArr.some(item => item.endsWith('.mp4') || item.endsWith('.MP4'));
  1176. if (hasImage && hasVideo) {
  1177. //表后管
  1178. this.againSubmitBHG();
  1179. } else {
  1180. this.$modal.msg('请至少上传一张照片和一个视频')
  1181. }
  1182. }
  1183. } else {
  1184. //暂存
  1185. this.againSubmitBHG();
  1186. }
  1187. } else if (this.objValue.enginClassValue == '阀管') {
  1188. //阀管 判断 材质 规格 米数
  1189. if (e == 'submit') {
  1190. if (this.isEmpty(this.doorValue.dictValue)) {
  1191. this.$modal.msg("请选择上门类型")
  1192. } else if (this.isEmpty(this.SelfClosValve.id)) {
  1193. this.$modal.msg("请选择自闭阀厂家")
  1194. } else if (this.isEmpty(this.materialValue.id)) {
  1195. this.$modal.msg("请选择灶具管厂家")
  1196. } else if (this.isEmpty(this.specificationValue.id)) {
  1197. this.$modal.msg("请选择规格")
  1198. } else {
  1199. if (this.isEmpty(this.inputDecimalNumberValue)) {
  1200. this.inputNumberValue = this.inputIntegerNumberValue;
  1201. } else {
  1202. this.inputNumberValue = this.inputIntegerNumberValue + "." + this.inputDecimalNumberValue;
  1203. }
  1204. this.onsubmit(e);
  1205. }
  1206. } else {
  1207. this.onsubmit(e); //暂存
  1208. }
  1209. }
  1210. },
  1211. onsubmit(e) {
  1212. if (e == 'submit') {
  1213. if (this.imgArr.length <= 0) {
  1214. this.$modal.msg('请上传照片或视频')
  1215. return
  1216. }
  1217. }
  1218. // else if (this.loading == false) {
  1219. // this.$modal.msg('照片或视频未上传完毕,无法提交!')
  1220. // }
  1221. //else {
  1222. let phoneArr = [];
  1223. this.currentResidentsPhoe.forEach((list) => {
  1224. phoneArr.push(list.phone)
  1225. })
  1226. putRoomDetails(this.FJValue.id, phoneArr.join())
  1227. .then(res => {
  1228. if (res.code == '200') {
  1229. this.againSubmit();
  1230. }
  1231. })
  1232. //}
  1233. },
  1234. againSubmitBHG() {
  1235. //表后管 特殊 提交
  1236. if (this.isEmpty(this.inputDecimalNumberValue)) {
  1237. this.inputNumberValue = this.inputIntegerNumberValue;
  1238. } else {
  1239. this.inputNumberValue = this.inputIntegerNumberValue + "." + this.inputDecimalNumberValue;
  1240. }
  1241. let phoneArr = [];
  1242. this.currentResidentsPhoe.forEach((list) => {
  1243. phoneArr.push(list.phone)
  1244. })
  1245. putRoomDetails(this.FJValue.id, phoneArr
  1246. .join())
  1247. .then(res => {
  1248. if (res.code == '200') {
  1249. let param = {
  1250. district: this.XZQValue.dictValue,
  1251. areaId: this.XQValue.id,
  1252. buildingId: this.LDValue.id,
  1253. unitId: this.DYValue.id,
  1254. houseId: this.FJValue.id,
  1255. enginType: this.objValue.enginType, //写死 上一页面传过来的
  1256. enginClassification: this.objValue
  1257. .enginClassification, //写死 上一页面传过来的 //室内 - 庭院 - 架空
  1258. enginCycle: this.projectValue.dictValue, //工程周期
  1259. zEngineeringNodeBo: {
  1260. type: this.objValue.enginClassValue, //写死 上一页面传过来的 (拆旧管等 字典值)
  1261. zEngineeringInfoBo: {
  1262. constructAccordingDrawings: this.isCheck, //是否按图纸施工
  1263. state: this.tempState,
  1264. zEngiineeringPhotoBoList: this.imgArr, //照片集合
  1265. zEngineeringMaterialBo: [{
  1266. materialQuality: this.materialValue.id, //材质
  1267. specifications: this.specificationValue.id, //规格
  1268. number: this.inputNumberValue //米数
  1269. }]
  1270. }
  1271. }
  1272. }
  1273. uni.showLoading()
  1274. addTearOldPipe(param).then(res => {
  1275. if (res.code == '200') {
  1276. uni.hideLoading()
  1277. uni.showToast({
  1278. title: res.msg,
  1279. icon: 'none',
  1280. //显示持续时间为 1秒
  1281. duration: 1000
  1282. });
  1283. uni.navigateBack();
  1284. }
  1285. })
  1286. }
  1287. })
  1288. },
  1289. againSubmit() {
  1290. //提交
  1291. let param = '';
  1292. if (this.objValue.enginClassValue == '拆旧管' || this.objValue.enginClassValue ==
  1293. '打孔') { //拆旧管 打孔
  1294. param = {
  1295. district: this.XZQValue.dictValue,
  1296. areaId: this.XQValue.id,
  1297. buildingId: this.LDValue.id,
  1298. unitId: this.DYValue.id,
  1299. houseId: this.FJValue.id,
  1300. enginType: this.objValue.enginType, //写死 上一页面传过来的
  1301. enginClassification: this.objValue
  1302. .enginClassification, //写死 上一页面传过来的 //室内 - 庭院 - 架空
  1303. enginCycle: this.projectValue.dictValue, //工程周期
  1304. zEngineeringNodeBo: {
  1305. type: this.objValue.enginClassValue, //写死 上一页面传过来的 (拆旧管等 字典值)
  1306. zEngineeringInfoBo: {
  1307. constructAccordingDrawings: this.isCheck, //是否按图纸施工
  1308. state: this.tempState,
  1309. zEngiineeringPhotoBoList: this.imgArr, //照片集合
  1310. zEngineeringMaterialBo: [{
  1311. corrosionLevel: this.LevelValue.id //腐蚀等级 //孔距
  1312. }]
  1313. }
  1314. }
  1315. }
  1316. //this.onsubmit(param)
  1317. } else if (this.objValue.enginClassValue == '报警器' || this.objValue.enginClassValue ==
  1318. '切断阀') { //报警器切断阀
  1319. param = {
  1320. district: this.XZQValue.dictValue,
  1321. areaId: this.XQValue.id,
  1322. buildingId: this.LDValue.id,
  1323. unitId: this.DYValue.id,
  1324. houseId: this.FJValue.id,
  1325. enginType: this.objValue.enginType, //写死 上一页面传过来的
  1326. enginClassification: this.objValue
  1327. .enginClassification, //写死 上一页面传过来的 //室内 - 庭院 - 架空
  1328. enginCycle: this.projectValue.dictValue, //工程周期
  1329. zEngineeringNodeBo: {
  1330. type: this.objValue.enginClassValue, //写死 上一页面传过来的 (拆旧管等 字典值)
  1331. zEngineeringInfoBo: {
  1332. constructAccordingDrawings: this.isCheck, //是否按图纸施工
  1333. state: this.tempState,
  1334. zEngiineeringPhotoBoList: this.imgArr, //照片集合
  1335. zEngineeringMaterialBo: [{
  1336. brand: this.brandValue.id, //品牌
  1337. // number: this.inputNumberValue //米数
  1338. }]
  1339. }
  1340. }
  1341. }
  1342. } else if (this.objValue.enginClassValue == '立杠') { //立杠
  1343. param = {
  1344. district: this.XZQValue.dictValue,
  1345. areaId: this.XQValue.id,
  1346. buildingId: this.LDValue.id,
  1347. unitId: this.DYValue.id,
  1348. houseId: this.FJValue.id,
  1349. enginType: this.objValue.enginType, //写死 上一页面传过来的
  1350. enginClassification: this.objValue
  1351. .enginClassification, //写死 上一页面传过来的 //室内 - 庭院 - 架空
  1352. enginCycle: this.projectValue.dictValue, //工程周期
  1353. zEngineeringNodeBo: {
  1354. type: this.objValue.enginClassValue, //写死 上一页面传过来的 (拆旧管等 字典值)
  1355. zEngineeringInfoBo: {
  1356. constructAccordingDrawings: this.isCheck, //是否按图纸施工
  1357. state: this.tempState,
  1358. zEngiineeringPhotoBoList: this.imgArr, //照片集合
  1359. zEngineeringMaterialBo: [{
  1360. materialQuality: this.materialValue.id, //材质
  1361. specifications: this.specificationValue.id, //规格
  1362. number: this.inputNumberValue //米数
  1363. }]
  1364. }
  1365. }
  1366. }
  1367. } else if (this.objValue.enginClassValue == '挂表') { //挂表
  1368. param = {
  1369. district: this.XZQValue.dictValue,
  1370. areaId: this.XQValue.id,
  1371. buildingId: this.LDValue.id,
  1372. unitId: this.DYValue.id,
  1373. houseId: this.FJValue.id,
  1374. enginType: this.objValue.enginType, //写死 上一页面传过来的
  1375. enginClassification: this.objValue
  1376. .enginClassification, //写死 上一页面传过来的 //室内 - 庭院 - 架空
  1377. enginCycle: this.projectValue.dictValue, //工程周期
  1378. zEngineeringNodeBo: {
  1379. type: this.objValue.enginClassValue, //写死 上一页面传过来的 (拆旧管等 字典值)
  1380. zEngineeringInfoBo: {
  1381. constructAccordingDrawings: this.isCheck, //是否按图纸施工
  1382. state: this.tempState,
  1383. zEngiineeringPhotoBoList: this.imgArr, //照片集合
  1384. zEngineeringMaterialBo: [{
  1385. brand: this.brandValue.id, //品牌
  1386. //number: this.inputNumberValue //米数
  1387. }]
  1388. }
  1389. }
  1390. }
  1391. } else if (this.objValue.enginClassValue == '阀管') { //自闭阀
  1392. if (!this.isEmpty(this.specificationValue.name)) {
  1393. var onlyNumbers = this.specificationValue.name.replace(/[^\d.]/g, '');
  1394. }
  1395. param = {
  1396. district: this.XZQValue.dictValue,
  1397. areaId: this.XQValue.id,
  1398. buildingId: this.LDValue.id,
  1399. unitId: this.DYValue.id,
  1400. houseId: this.FJValue.id,
  1401. enginType: this.objValue.enginType, //写死 上一页面传过来的
  1402. enginClassification: this.objValue
  1403. .enginClassification, //写死 上一页面传过来的 //室内 - 庭院 - 架空
  1404. enginCycle: this.projectValue.dictValue, //工程周期
  1405. zEngineeringNodeBo: {
  1406. type: this.objValue.enginClassValue, //写死 上一页面传过来的 (拆旧管等 字典值)
  1407. zEngineeringInfoBo: {
  1408. constructAccordingDrawings: this.isCheck, //是否按图纸施工
  1409. state: this.tempState,
  1410. zEngiineeringPhotoBoList: this.imgArr, //照片集合
  1411. zEngineeringMaterialBo: [{
  1412. visitType: this.doorValue.dictValue, //上门类型
  1413. selfClosingValveType: this.SelfClosValve.id, //自闭阀类型
  1414. materialQuality: this.materialValue.id, //材质
  1415. specifications: this.specificationValue.id, //规格
  1416. number: onlyNumbers //米数
  1417. }]
  1418. }
  1419. }
  1420. }
  1421. }
  1422. uni.showLoading()
  1423. addTearOldPipe(param).then(res => {
  1424. if (res.code == '200') {
  1425. uni.hideLoading()
  1426. uni.showToast({
  1427. title: res.msg,
  1428. icon: 'none',
  1429. //显示持续时间为 3秒
  1430. duration: 2000
  1431. });
  1432. setTimeout(function() {
  1433. uni.navigateBack();
  1434. }, 1000)
  1435. }
  1436. })
  1437. },
  1438. history() {
  1439. this.LevelValue = {};
  1440. this.imgArr = [];
  1441. this.materialValue = {};
  1442. this.specificationValue = {};
  1443. this.inputIntegerNumberValue = '';
  1444. this.inputDecimalNumberValue = '';
  1445. this.brandValue = {};
  1446. this.doorValue = {};
  1447. this.SelfClosValve = {};
  1448. if (this.isEmpty(this.projectValue.dictValue)) {
  1449. this.$modal.msg("请选择工程周期")
  1450. return
  1451. }
  1452. if (this.isEmpty(this.XZQValue.dictValue)) {
  1453. this.$modal.msg("请选择行政区")
  1454. return
  1455. }
  1456. if (this.isEmpty(this.XQValue.id)) {
  1457. this.$modal.msg("请选择小区")
  1458. return
  1459. }
  1460. if (this.isEmpty(this.LDValue.id)) {
  1461. this.$modal.msg("请选择楼栋")
  1462. return
  1463. }
  1464. if (this.isEmpty(this.DYValue.id)) {
  1465. this.$modal.msg("请选择单元")
  1466. return
  1467. }
  1468. if (this.isEmpty(this.FJValue.id)) {
  1469. this.$modal.msg("请选择房间")
  1470. return
  1471. }
  1472. let param = {
  1473. areaId: this.XQValue.id, // 小区id
  1474. buildingId: this.LDValue.id, // 楼宇id
  1475. unitId: this.DYValue.id, // 单元id
  1476. houseId: this.FJValue.id, // 房间id
  1477. enginCycle: this.projectValue.dictValue, // 工程周期
  1478. enginType: this.objValue.enginType, //写死 上一页面传过来的
  1479. enginClassification: this.objValue.enginClassification, //写死 上一页面传过来的 //室内 - 庭院 - 架空
  1480. }
  1481. getRoomProjectId(param).then(res => {
  1482. if (res.code == '200') {
  1483. if (res.data != null) {
  1484. getRoomProjectList(res.data.id, this.objValue.enginClassValue).then(res => {
  1485. // this.historyName = res.data.zEngineeringNodeBo.reviewStatus == '0' ?
  1486. // '未通过' : '已通过'
  1487. // if (res.data.zEngineeringNodeBo.reviewStatus != null && res.data.zEngineeringNodeBo.reviewStatus == '99') {
  1488. // this.historyName = '恢复暂存';
  1489. // } else {
  1490. // this.historyName = '';
  1491. // }
  1492. this.historyList = res.data
  1493. if (res.data.zEngineeringNodeBo != null) {
  1494. if (res.data.zEngineeringNodeBo.reviewStatus == '1') {
  1495. // this.showHistoryList();
  1496. this.$modal.msg("当前步骤以审核通过请谨慎!")
  1497. } else if (res.data.zEngineeringNodeBo.reviewStatus == '99') {
  1498. let dataJson = res.data.zEngineeringNodeBo
  1499. .zEngineeringInfoBoList[0];
  1500. this.imgArr = dataJson.zEngiineeringPhotoBoList;
  1501. if (this.objValue.enginClassValue == '拆旧管') {
  1502. this.LevelValue.id = dataJson
  1503. .zEngineeringMaterialBo[0]
  1504. .corrosionLevel
  1505. this.LevelValue.name = dataJson
  1506. .zEngineeringMaterialBo[0]
  1507. .corrosionLevelName
  1508. } else if (this.objValue.enginClassValue == '立杠' || this.objValue
  1509. .enginClassValue == '表后管') {
  1510. this.materialValue.id = dataJson.zEngineeringMaterialBo[0].materialQuality;
  1511. if (!this.isEmpty(this.materialValue.id) && this.materialValue.id != null) {
  1512. //根据材质ID 获取规格数据
  1513. getEnginSpecificationsList(this.materialValue.id).then(res => {
  1514. this.materialList = res.data
  1515. })
  1516. }
  1517. this.specificationValue.id = dataJson
  1518. .zEngineeringMaterialBo[0]
  1519. .specifications;
  1520. this.materialValue.name = dataJson.zEngineeringMaterialBo[0]
  1521. .materialQualityName;
  1522. this.specificationValue.name = dataJson
  1523. .zEngineeringMaterialBo[0].specificationsName;
  1524. if (dataJson.zEngineeringMaterialBo[0].number != null) {
  1525. this.inputIntegerNumberValue = this.getIntegerPart(
  1526. dataJson
  1527. .zEngineeringMaterialBo[0].number, 0);
  1528. this.inputDecimalNumberValue = this.getIntegerPart(dataJson
  1529. .zEngineeringMaterialBo[0].number, 1);
  1530. }
  1531. } else if (this.objValue.enginClassValue == '报警器' || this.objValue
  1532. .enginClassValue == '切断阀' || this.objValue
  1533. .enginClassValue == '挂表') {
  1534. this.brandValue.id = dataJson.zEngineeringMaterialBo[0]
  1535. .brand
  1536. this.brandValue.name = dataJson.zEngineeringMaterialBo[0]
  1537. .brandName
  1538. } else if (this.objValue.enginClassValue == '阀管') {
  1539. this.doorValue.dictValue = dataJson
  1540. .zEngineeringMaterialBo[0]
  1541. .visitType;
  1542. this.doorValue.dictLabel = dataJson
  1543. .zEngineeringMaterialBo[0]
  1544. .visitType;
  1545. this.SelfClosValve.id = dataJson
  1546. .zEngineeringMaterialBo[0]
  1547. .selfClosingValveType;
  1548. this.SelfClosValve.name = dataJson
  1549. .zEngineeringMaterialBo[0]
  1550. .selfClosingValveTypeName;
  1551. this.materialValue.id = dataJson
  1552. .zEngineeringMaterialBo[0]
  1553. .materialQuality;
  1554. if (!this.isEmpty(this.materialValue.id) && this.materialValue.id != null) {
  1555. //根据材质ID 获取规格数据
  1556. getEnginSpecificationsList(this.materialValue.id).then(res => {
  1557. this.materialList = res.data
  1558. })
  1559. }
  1560. this.specificationValue.id = dataJson
  1561. .zEngineeringMaterialBo[0]
  1562. .specifications;
  1563. this.materialValue.name = dataJson.zEngineeringMaterialBo[0]
  1564. .materialQualityName;
  1565. this.specificationValue.name = dataJson
  1566. .zEngineeringMaterialBo[0].specificationsName;
  1567. }
  1568. } else {
  1569. this.$modal.msg("暂无暂存信息")
  1570. }
  1571. } else {
  1572. this.$modal.msg("暂无历史信息")
  1573. }
  1574. })
  1575. } else {
  1576. this.$modal.msg("暂无工程信息")
  1577. }
  1578. } else {
  1579. this.$modal.msg(res.msg)
  1580. }
  1581. })
  1582. },
  1583. getIntegerPart(numStr, i) {
  1584. if (numStr != null && numStr != undefined && numStr != '') {
  1585. return numStr.toString().split('.')[i] == undefined ? '0' : numStr.toString().split('.')[i];
  1586. }
  1587. },
  1588. setInfoBoNumber(key, number, i) {
  1589. let Ynumber = this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key].zEngineeringMaterialBo[0]
  1590. .number;
  1591. let resAry = Ynumber.toString().split('.');
  1592. resAry[i] = number
  1593. this.dataJson.zEngineeringNodeBo.zEngineeringInfoBoList[key].zEngineeringMaterialBo[0].number = resAry
  1594. .join('.');
  1595. },
  1596. showHistoryList() {
  1597. this.$refs.refShare.handleShowShare();
  1598. }
  1599. }
  1600. }
  1601. </script>
  1602. <style lang="scss">
  1603. .container-text {
  1604. display: flex;
  1605. align-items: center;
  1606. justify-content: space-between;
  1607. color: #b2b2b2;
  1608. position: relative;
  1609. }
  1610. .container {
  1611. display: flex;
  1612. align-items: center;
  1613. justify-content: space-between;
  1614. padding: 10px;
  1615. position: relative;
  1616. }
  1617. .uni-list {
  1618. border: 1xp solid #eee;
  1619. }
  1620. .to-right-icon {
  1621. width: 15px;
  1622. height: 15px;
  1623. position: absolute;
  1624. top: 50%;
  1625. transform: translateY(-50%);
  1626. }
  1627. .text {
  1628. font-size: 16px;
  1629. color: #333;
  1630. }
  1631. .background {
  1632. // border: 15px solid hsla(0, 0%, 100%, .5);
  1633. background: white;
  1634. background-clip: padding-box;
  1635. padding: 20rpx;
  1636. border-radius: 20rpx;
  1637. margin: 20rpx 10rpx;
  1638. /*从padding开始往外面裁剪背景*/
  1639. }
  1640. .btn {
  1641. width: 715rpx;
  1642. height: 69rpx;
  1643. background: #79A4F0;
  1644. border-radius: 6rpx;
  1645. font-size: 25rpx;
  1646. font-family: Microsoft YaHei;
  1647. font-weight: 400;
  1648. color: #FFFFFF;
  1649. line-height: 69rpx;
  1650. margin-top: 40rpx;
  1651. margin-bottom: 100rpx;
  1652. }
  1653. .number {
  1654. display: flex;
  1655. /* 水平居中显示子元素 */
  1656. align-items: flex-start;
  1657. /* 垂直居中显示子元素 */
  1658. justify-content: space-between;
  1659. /* 左右间距等于间距大小 */
  1660. padding: 10px;
  1661. /* 设置padding以提高视觉效果 */
  1662. }
  1663. .tj-btn {
  1664. height: 69rpx;
  1665. background: #3184f0;
  1666. border-radius: 6rpx;
  1667. font-size: 25rpx;
  1668. font-weight: 400;
  1669. color: #FFFFFF;
  1670. line-height: 69rpx;
  1671. margin: 40rpx 70rpx;
  1672. }
  1673. .sc-btn {
  1674. height: 69rpx;
  1675. background: #f0686b;
  1676. border-radius: 6rpx;
  1677. font-size: 25rpx;
  1678. font-weight: 400;
  1679. color: #FFFFFF;
  1680. line-height: 69rpx;
  1681. margin: 40rpx;
  1682. }
  1683. .num-style {
  1684. background: #e8f4f9;
  1685. margin: 20rpx;
  1686. padding: 10rpx;
  1687. border-radius: 20rpx;
  1688. border: 1px solid #d4e3f0;
  1689. }
  1690. .textarea {
  1691. margin-top: 10upx;
  1692. width: 100%;
  1693. border: 1rpx solid red;
  1694. min-height: 100upx;
  1695. line-height: 20px;
  1696. }
  1697. page {
  1698. background: #f2f2f2;
  1699. }
  1700. .flex-x {
  1701. display: flex;
  1702. align-items: center;
  1703. }
  1704. .template_title,
  1705. .template_title1,
  1706. .template_title_list {
  1707. height: 90rpx;
  1708. background: #fff;
  1709. justify-content: space-between;
  1710. padding: 0 30rpx;
  1711. box-sizing: border-box;
  1712. }
  1713. .template_title1 {
  1714. background: none;
  1715. }
  1716. .template_title_list {
  1717. margin-bottom: 4rpx;
  1718. }
  1719. .template_title>view,
  1720. .template_title1>view {
  1721. font-size: 32rpx;
  1722. color: #8f8f8f;
  1723. flex-shrink: 0;
  1724. margin-right: 20rpx;
  1725. }
  1726. .template_title>input {
  1727. font-size: 28rpx;
  1728. color: #808080;
  1729. text-align: right;
  1730. flex-grow: 1;
  1731. }
  1732. /* 添加内容 */
  1733. .add_con>text {
  1734. font-size: 40rpx;
  1735. color: #f16765;
  1736. display: block;
  1737. margin-right: 20rpx;
  1738. margin-left: 10rpx;
  1739. line-height: 44rpx;
  1740. }
  1741. .add_con>view {
  1742. font-size: 32rpx;
  1743. color: #7885cb;
  1744. }
  1745. /* 删除内容 */
  1746. .del {
  1747. font-size: 32rpx;
  1748. color: #f16765;
  1749. margin-right: 14rpx;
  1750. padding: 20rpx;
  1751. }
  1752. input {
  1753. flex-grow: 1;
  1754. font-size: 28rpx;
  1755. color: #808080;
  1756. }
  1757. // .container {
  1758. // display: flex;
  1759. // align-items: center;
  1760. // justify-content: space-between;
  1761. // padding: 10px;
  1762. // position: relative;
  1763. // }
  1764. // .uni-list {
  1765. // border: 1xp solid #eee;
  1766. // }
  1767. // .to-right-icon {
  1768. // width: 15px;
  1769. // height: 15px;
  1770. // position: absolute;
  1771. // top: 50%;
  1772. // transform: translateY(-50%);
  1773. // }
  1774. // .text {
  1775. // font-size: 16px;
  1776. // color: #333;
  1777. // }
  1778. // .background {
  1779. // // border: 15px solid hsla(0, 0%, 100%, .5);
  1780. // background: white;
  1781. // background-clip: padding-box;
  1782. // padding: 20rpx;
  1783. // border-radius: 20rpx;
  1784. // margin: 20rpx;
  1785. // /*从padding开始往外面裁剪背景*/
  1786. // }
  1787. // .btn {
  1788. // width: 715rpx;
  1789. // height: 69rpx;
  1790. // background: #79A4F0;
  1791. // border-radius: 6rpx;
  1792. // font-size: 25rpx;
  1793. // font-family: Microsoft YaHei;
  1794. // font-weight: 400;
  1795. // color: #FFFFFF;
  1796. // line-height: 69rpx;
  1797. // margin-top: 40rpx;
  1798. // margin-bottom: 100rpx;
  1799. // }
  1800. // .number {
  1801. // display: flex;
  1802. // /* 水平居中显示子元素 */
  1803. // align-items: flex-start;
  1804. // /* 垂直居中显示子元素 */
  1805. // justify-content: space-between;
  1806. // /* 左右间距等于间距大小 */
  1807. // padding: 10px;
  1808. // /* 设置padding以提高视觉效果 */
  1809. // }
  1810. // .textarea {
  1811. // margin-top: 10upx;
  1812. // width: 100%;
  1813. // border: 1rpx solid red;
  1814. // min-height: 100upx;
  1815. // line-height: 20px;
  1816. // }
  1817. </style>