gasFill.vue 121 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417
  1. <template>
  2. <view class="gas-fill" >
  3. <!-- 瓦斯上报列表 -->
  4. <view v-if="!isShowAdd">
  5. <view class="top-gas-list">
  6. <view class="search-box" @click="getChangeTimeTb">
  7. <text class="dialog-label">填报时间:</text>
  8. <u--input v-model="tbTime" placeholder="请选择填报时间" inputAlign="center"
  9. suffixIcon="arrow-right"></u--input>
  10. <u-datetime-picker :show="showCalendarTb" v-model="timeRan" mode="date" closeOnClickOverlay
  11. @confirm="confirmTb" @cancel="showCalendarTb = false" @change="changeTb"
  12. @close="showCalendarTb = false"></u-datetime-picker>
  13. </view>
  14. <u-button v-if="hasPermission('gasReport:add')" type="primary" size="small" style="margin: 2px 0px;" @click="getAdd">新增</u-button>
  15. </view>
  16. <view class="bot-gas-list">
  17. <view class="top-title">
  18. <view style="font-weight: bold;">瓦斯填报列表</view>
  19. </view>
  20. <view class="top-content" v-for="(item, index) in gasList" :key="index">
  21. <view class="content-title-gas">
  22. <text>
  23. {{ item.strInstallPos || '--' }}
  24. </text>
  25. </view>
  26. <view class="content-item-box">
  27. <view class="content-item">
  28. <view class="item-l">
  29. <view class="item-value">{{ item.timeNight1 || '--' }}</view>
  30. <view class="item-label">夜班监测时间一</view>
  31. </view>
  32. <view class="item-c"></view>
  33. <view class="item-r">
  34. <view class="item-value">{{ item.timeNight2 || '--' }}</view>
  35. <view class="item-label">夜班监测时间二</view>
  36. </view>
  37. </view>
  38. <view class="content-item">
  39. <view class="item-l">
  40. <view class="item-value">{{ item.timeEarly1 || '--' }}</view>
  41. <view class="item-label">早班监测时间一</view>
  42. </view>
  43. <view class="item-c"></view>
  44. <view class="item-r">
  45. <view class="item-value">{{ item.timeEarly2 || '--' }}</view>
  46. <view class="item-label">早班监测时间二</view>
  47. </view>
  48. </view>
  49. <view class="content-item">
  50. <view class="item-l">
  51. <view class="item-value">{{ item.timeNoon1 || '--' }}</view>
  52. <view class="item-label">中班监测时间一</view>
  53. </view>
  54. <view class="item-c"></view>
  55. <view class="item-r">
  56. <view class="item-value">{{ item.timeNoon2 || '--' }}</view>
  57. <view class="item-label">中班监测时间二</view>
  58. </view>
  59. </view>
  60. </view>
  61. </view>
  62. </view>
  63. </view>
  64. <!-- 新增弹窗 -->
  65. <view v-if="isShowAdd">
  66. <view class="top-dialog-area">
  67. <view class="dialog-item">
  68. <text class="dialog-label">班次:</text>
  69. <uni-data-select placeholder="请选择班次" align="center" :clear="true" v-model="formState.bc"
  70. :localdata="rangeBc" @change="changeBc"></uni-data-select>
  71. </view>
  72. <view class="dialog-item">
  73. <text class="dialog-label">检测次数:</text>
  74. <uni-data-select placeholder="请选择检测次数" align="center" :clear="true" v-model="formState.count"
  75. :localdata="rangeCount" @change="changeCount"></uni-data-select>
  76. </view>
  77. <view class="dialog-item">
  78. <text class="dialog-label">煤层工作面:</text>
  79. <uni-data-select placeholder="请选择煤层工作面" align="center" :clear="true" v-model="formState.mcgzm"
  80. :localdata="rangeMcgzm" @change="changeMc"></uni-data-select>
  81. </view>
  82. <view class="dialog-item">
  83. <text class="dialog-label">检测地点:</text>
  84. <uni-data-select placeholder="请选择检测地点" align="center" :clear="true" v-model="formState.jcdd"
  85. :localdata="rangeJcdd" @change="changeJc"></uni-data-select>
  86. </view>
  87. <view class="dialog-item" @click="getChangeTime">
  88. <text class="dialog-label">检测时间:</text>
  89. <u--input v-model="formState.time" placeholder="请选择检测时间" inputAlign="center"
  90. suffixIcon="arrow-right"></u--input>
  91. <u-datetime-picker :show="showCalendar" v-model="timeRan" mode="datetime" closeOnClickOverlay
  92. @confirm="showCalendar = false" @cancel="showCalendar = false" @change="change"
  93. @close="showCalendar = false"></u-datetime-picker>
  94. </view>
  95. <view class="dialog-item">
  96. <text class="dialog-label">填报日期:</text>
  97. <u--input inputAlign="center" v-model="formState.tbrq" placeholder="请选择填报日期"></u--input>
  98. </view>
  99. <view class="dialog-item">
  100. <text class="dialog-label">瓦斯检查工:</text>
  101. <u--input inputAlign="center" disabled v-model="formState.jcy" placeholder="请输入"></u--input>
  102. </view>
  103. </view>
  104. <view>
  105. <view class="center-dialog-area">
  106. <div class="dialog-title">气体检测数据</div>
  107. <view class="dialog-item">
  108. <text class="dialog-label">CH₄(%):</text>
  109. <u--input inputAlign="center" :disabled="isDisabled" v-model="formState.ch4"
  110. :placeholder="isRule2 ? '请输入' : '数据有误'" type="number" @blur="getBlurCH4"
  111. @input="changeInput($event, 'ch4')" clearable
  112. :placeholderStyle="isRule2 ? 'color:#c0c4cc' : 'color:#ff0000'"></u--input>
  113. </view>
  114. <view class="dialog-item">
  115. <text class="dialog-label">CO₂(%):</text>
  116. <u--input inputAlign="center" :disabled="isDisabled" v-model="formState.co2"
  117. :placeholder="isRule ? '请输入' : '数据有误'" type="number" @blur="getBlurCO2"
  118. @input="changeInput($event, 'co2')" clearable
  119. :placeholderStyle="isRule ? 'color:#c0c4cc' : 'color:#ff0000'"></u--input>
  120. </view>
  121. <view class="dialog-item">
  122. <text class="dialog-label">CO(ppm):</text>
  123. <u--input inputAlign="center" :disabled="isDisabled" v-model="formState.co"
  124. :placeholder="isRule14 ? '请输入' : '数据有误'" clearable
  125. :placeholderStyle="isRule14 ? 'color:#c0c4cc' : 'color:#ff0000'" type="number"
  126. @blur="getBlurCO" @input="changeInput($event, 'co')"></u--input>
  127. </view>
  128. <view class="dialog-item">
  129. <text class="dialog-label">O₂(%):</text>
  130. <u--input inputAlign="center" :disabled="isDisabled" clearable type="number"
  131. v-model="formState.o2" placeholder="请输入" @input="changeInput($event, 'o2')"></u--input>
  132. </view>
  133. <view class="dialog-item">
  134. <text class="dialog-label">T(℃):</text>
  135. <u--input inputAlign="center" :disabled="isDisabled" clearable type="number"
  136. @input="changeInput($event, 'temp')" v-model="formState.temp"
  137. placeholder="请输入"></u--input>
  138. </view>
  139. </view>
  140. <view class="bottom-dialog-area">
  141. <div class="dialog-title">三对照数据</div>
  142. <view class="dialog-item">
  143. <text class="dialog-label">甲烷传感器:</text>
  144. <!-- <u--input inputAlign="center" :disabled="isDisabled" type="number" v-model="formState.jw"
  145. placeholder="请输入"></u--input> -->
  146. <u--input inputAlign="center" :disabled="isDisabled" type="number" v-model="formState.ch4"
  147. placeholder="请输入" clearable @input="changeInput($event, 'ch4')"></u--input>
  148. </view>
  149. <view class="dialog-item">
  150. <text class="dialog-label">光瓦测量数据:</text>
  151. <u--input inputAlign="center" :disabled="isDisabled" v-model="formState.gw"
  152. :placeholder="isRule1 ? '请输入' : '数据有误'" type="number" @blur="getBlur" clearable
  153. @input="changeInput($event, 'gw')"
  154. :placeholderStyle="isRule1 ? 'color:#c0c4cc' : 'color:#ff0000'"></u--input>
  155. </view>
  156. <view class="dialog-item">
  157. <text class="dialog-label">便携仪测量数据:</text>
  158. <u--input inputAlign="center" :disabled="isDisabled"
  159. :placeholderStyle="isRule3 ? 'color:#c0c4cc' : 'color:#ff0000'"
  160. :placeholder="isRule3 ? '请输入' : '数据有误'" type="number" v-model="formState.bxy" clearable
  161. @blur="getBlurBxy" @input="changeInput($event, 'bxy')"></u--input>
  162. </view>
  163. </view>
  164. </view>
  165. <view class="dialog-btn">
  166. <u-button type="success" size="small" v-if="!isDisabled" @click="getConfirm">保存</u-button>
  167. <u-button type="primary" size="small" @click="getCancel">取消</u-button>
  168. </view>
  169. </view>
  170. </view>
  171. </template>
  172. <script>
  173. import api from "@/api/api";
  174. import moment from 'moment'
  175. import { mapGetters } from "vuex";
  176. export default {
  177. name: 'gasFill',
  178. props: {},
  179. watch: {},
  180. data() {
  181. return {
  182. isDisabled: false,
  183. isStatus: '',
  184. deviceId: '',
  185. rangeBc: [
  186. { value: '夜班', text: "夜班" },
  187. { value: '早班', text: "早班" },
  188. { value: '中班', text: "中班" },
  189. ],
  190. rangeMcgzm: [],
  191. rangeJcdd: [],
  192. rangeCount: [
  193. { value: '第一次', text: '第一次' },
  194. { value: '第二次', text: '第二次' },
  195. ],
  196. isRule: true,
  197. isRule1: true,
  198. isRule14: true,
  199. isRule2: true,
  200. isRule3: true,
  201. //新增参数信息
  202. isShowAdd: false,//是否显示新增弹窗
  203. showCalendar: false,//控制日期选型下拉开启
  204. timeRan: Number(new Date()),
  205. gasList: [],//瓦斯填报列表数据
  206. tbTime: moment(new Date()).format('YYYY-MM-DD'),//查询条件-填报时间
  207. showCalendarTb: false,//控制填报时间组件弹出
  208. saveShowList: {},
  209. formState: {
  210. id: '',
  211. bc: '',
  212. count: '',
  213. jcdd: '',
  214. jcy: '',
  215. time: moment(new Date()).format('YYYY-MM-DD HH:mm:ss'),
  216. ch4: '',
  217. co2: '',
  218. co: '',
  219. o2: '',
  220. jw: '',
  221. gw: '',
  222. bxy: '',
  223. tbrq: moment(new Date()).format('YYYY-MM-DD'),
  224. temp: '',
  225. mcgzm: '',
  226. },
  227. };
  228. },
  229. computed: {
  230. username: function () {
  231. return uni.getStorageSync('login_user_info')['realname']
  232. },
  233. },
  234. mounted() {
  235. console.log(uni.getStorageSync('login_user_info'), 'ceshi00-----------')
  236. this.getGasList()
  237. this.getMcList()
  238. },
  239. methods: {
  240. hasPermission(param){
  241. let permission= uni.getStorageSync('btnPermission')
  242. return permission.filter(v=>v.action==param).length!=0 ? true : false
  243. },
  244. //班次下拉选项切换
  245. changeBc(e) {
  246. let that = this
  247. console.log(e, '班次----------')
  248. this.formState.bc = e
  249. if (that.formState.bc == '早班' && that.formState.count == '第一次') {
  250. if (that.saveShowList.bxySdzEarly1 || that.saveShowList.ch4Early1 || that.saveShowList.co2Early1 || that.saveShowList.coEarly1 || that.saveShowList.gwSdzEarly1 || that.saveShowList.jwSdzEarly1 || that.saveShowList.o2Early1 || that.saveShowList.tearly1) {
  251. that.formState = {
  252. id: that.saveShowList.id || '',
  253. bc: that.formState.bc,
  254. count: that.formState.count,
  255. jcdd: that.formState.jcdd,
  256. jcy: that.formState.jcy,
  257. time: that.formState.time,
  258. ch4: that.saveShowList.ch4Early1 || '',
  259. co2: that.saveShowList.co2Early1 || '',
  260. co: that.saveShowList.coEarly1 || '',
  261. o2: that.saveShowList.o2Early1 || '',
  262. jw: that.saveShowList.jwSdzEarly1 || '',
  263. gw: that.saveShowList.gwSdzEarly1 || '',
  264. bxy: that.saveShowList.bxySdzEarly1 || '',
  265. tbrq: that.formState.tbrq,
  266. temp: that.saveShowList.tearly1 || '',
  267. mcgzm: that.formState.mcgzm,
  268. }
  269. that.isDisabled = true
  270. } else {
  271. that.formState = {
  272. id: that.formState.id,
  273. bc: that.formState.bc,
  274. count: that.formState.count,
  275. jcdd: that.formState.jcdd,
  276. jcy: that.formState.jcy,
  277. time: that.formState.time,
  278. ch4: '',
  279. co2: '',
  280. co: '',
  281. o2: '',
  282. jw: '',
  283. gw: '',
  284. bxy: '',
  285. tbrq: that.formState.tbrq,
  286. temp: '',
  287. mcgzm: that.formState.mcgzm,
  288. }
  289. that.isDisabled = false
  290. }
  291. } else if (that.formState.bc == '早班' && that.formState.count == '第二次') {
  292. if (that.saveShowList.bxySdzEarly2 || that.saveShowList.ch4Early2 || that.saveShowList.co2Early2 || that.saveShowList.coEarly2 || that.saveShowList.gwSdzEarly2 || that.saveShowList.jwSdzEarly2 || that.saveShowList.o2Early2 || that.saveShowList.tearly2) {
  293. that.formState = {
  294. id: that.saveShowList.id || '',
  295. bc: that.formState.bc,
  296. count: that.formState.count,
  297. jcdd: that.formState.jcdd,
  298. jcy: that.formState.jcy,
  299. time: that.formState.time,
  300. ch4: that.saveShowList.ch4Early2 || '',
  301. co2: that.saveShowList.co2Early2 || '',
  302. co: that.saveShowList.coEarly2 || '',
  303. o2: that.saveShowList.o2Early2 || '',
  304. jw: that.saveShowList.jwSdzEarly2 || '',
  305. gw: that.saveShowList.gwSdzEarly2 || '',
  306. bxy: that.saveShowList.bxySdzEarly2 || '',
  307. tbrq: that.formState.tbrq,
  308. temp: that.saveShowList.tearly2 || '',
  309. mcgzm: that.formState.mcgzm,
  310. }
  311. that.isDisabled = true
  312. } else {
  313. that.formState = {
  314. id: that.formState.id,
  315. bc: that.formState.bc,
  316. count: that.formState.count,
  317. jcdd: that.formState.jcdd,
  318. jcy: that.formState.jcy,
  319. time: that.formState.time,
  320. ch4: '',
  321. co2: '',
  322. co: '',
  323. o2: '',
  324. jw: '',
  325. gw: '',
  326. bxy: '',
  327. tbrq: that.formState.tbrq,
  328. temp: '',
  329. mcgzm: that.formState.mcgzm,
  330. }
  331. that.isDisabled = false
  332. }
  333. } else if (that.formState.bc == '中班' && that.formState.count == '第一次') {
  334. if (that.saveShowList.bxySdzNoon1 || that.saveShowList.ch4Noon1 || that.saveShowList.co2Noon1 || that.saveShowList.coNoon1 || that.saveShowList.gwSdzNoon1 || that.saveShowList.jwSdzNoon1 || that.saveShowList.o2Noon1 || that.saveShowList.tnoon1) {
  335. that.formState = {
  336. id: that.saveShowList.id || '',
  337. bc: that.formState.bc,
  338. count: that.formState.count,
  339. jcdd: that.formState.jcdd,
  340. jcy: that.formState.jcy,
  341. time: that.formState.time,
  342. ch4: that.saveShowList.bxySdzNoon1 || '',
  343. co2: that.saveShowList.co2Noon1 || '',
  344. co: that.saveShowList.coNoon1 || '',
  345. o2: that.saveShowList.o2Noon1 || '',
  346. jw: that.saveShowList.jwSdzNoon1 || '',
  347. gw: that.saveShowList.gwSdzNoon1 || '',
  348. bxy: that.saveShowList.bxySdzNoon1 || '',
  349. tbrq: that.formState.tbrq,
  350. temp: that.saveShowList.tnoon1 || '',
  351. mcgzm: that.formState.mcgzm,
  352. }
  353. that.isDisabled = true
  354. } else {
  355. that.formState = {
  356. id: that.formState.id,
  357. bc: that.formState.bc,
  358. count: that.formState.count,
  359. jcdd: that.formState.jcdd,
  360. jcy: that.formState.jcy,
  361. time: that.formState.time,
  362. ch4: '',
  363. co2: '',
  364. co: '',
  365. o2: '',
  366. jw: '',
  367. gw: '',
  368. bxy: '',
  369. tbrq: that.formState.tbrq,
  370. temp: '',
  371. mcgzm: that.formState.mcgzm,
  372. }
  373. that.isDisabled = false
  374. }
  375. } else if (that.formState.bc == '中班' && that.formState.count == '第二次') {
  376. if (that.saveShowList.bxySdzNoon2 || that.saveShowList.ch4Noon2 || that.saveShowList.co2Noon2 || that.saveShowList.coNoon2 || that.saveShowList.gwSdzNoon2 || that.saveShowList.jwSdzNoon2 || that.saveShowList.o2Noon2 || that.saveShowList.tnoon2) {
  377. that.formState = {
  378. id: that.saveShowList.id || '',
  379. bc: that.formState.bc,
  380. count: that.formState.count,
  381. jcdd: that.formState.jcdd,
  382. jcy: that.formState.jcy,
  383. time: that.formState.time,
  384. ch4: that.saveShowList.bxySdzNoon2 || '',
  385. co2: that.saveShowList.co2Noon2 || '',
  386. co: that.saveShowList.coNoon2 || '',
  387. o2: that.saveShowList.o2Noon2 || '',
  388. jw: that.saveShowList.jwSdzNoon2 || '',
  389. gw: that.saveShowList.gwSdzNoon2 || '',
  390. bxy: that.saveShowList.bxySdzNoon2 || '',
  391. tbrq: that.formState.tbrq,
  392. temp: that.saveShowList.tnoon2 || '',
  393. mcgzm: that.formState.mcgzm,
  394. }
  395. that.isDisabled = true
  396. } else {
  397. that.formState = {
  398. id: that.formState.id,
  399. bc: that.formState.bc,
  400. count: that.formState.count,
  401. jcdd: that.formState.jcdd,
  402. jcy: that.formState.jcy,
  403. time: that.formState.time,
  404. ch4: '',
  405. co2: '',
  406. co: '',
  407. o2: '',
  408. jw: '',
  409. gw: '',
  410. bxy: '',
  411. tbrq: that.formState.tbrq,
  412. temp: '',
  413. mcgzm: that.formState.mcgzm,
  414. }
  415. that.isDisabled = false
  416. }
  417. } else if (that.formState.bc == '夜班' && that.formState.count == '第一次') {
  418. if (that.saveShowList.bxySdzNight1 || that.saveShowList.ch4Night1 || that.saveShowList.co2Night1 || that.saveShowList.coNight1 || that.saveShowList.gwSdzNight1 || that.saveShowList.jwSdzNight1 || that.saveShowList.o2Night1 || that.saveShowList.tnight1) {
  419. that.formState = {
  420. id: that.saveShowList.id || '',
  421. bc: that.formState.bc,
  422. count: that.formState.count,
  423. jcdd: that.formState.jcdd,
  424. jcy: that.formState.jcy,
  425. time: that.formState.time,
  426. ch4: that.saveShowList.ch4Night1 || '',
  427. co2: that.saveShowList.co2Night1 || '',
  428. co: that.saveShowList.coNight1 || '',
  429. o2: that.saveShowList.o2Night1 || '',
  430. jw: that.saveShowList.jwSdzNight1 || '',
  431. gw: that.saveShowList.gwSdzNight1 || '',
  432. bxy: that.saveShowList.bxySdzNight1 || '',
  433. tbrq: that.formState.tbrq,
  434. temp: that.saveShowList.tnight1 || '',
  435. mcgzm: that.formState.mcgzm,
  436. }
  437. that.isDisabled = true
  438. } else {
  439. that.formState = {
  440. id: that.formState.id,
  441. bc: that.formState.bc,
  442. count: that.formState.count,
  443. jcdd: that.formState.jcdd,
  444. jcy: that.formState.jcy,
  445. time: that.formState.time,
  446. ch4: '',
  447. co2: '',
  448. co: '',
  449. o2: '',
  450. jw: '',
  451. gw: '',
  452. bxy: '',
  453. tbrq: that.formState.tbrq,
  454. temp: '',
  455. mcgzm: that.formState.mcgzm,
  456. }
  457. that.isDisabled = false
  458. }
  459. } else if (that.formState.bc == '夜班' && that.formState.count == '第二次') {
  460. if (that.saveShowList.bxySdzNight2 || that.saveShowList.ch4Night2 || that.saveShowList.co2Night2 || that.saveShowList.coNight2 || that.saveShowList.gwSdzNight2 || that.saveShowList.jwSdzNight2 || that.saveShowList.o2Night2 || that.saveShowList.tnight2) {
  461. that.formState = {
  462. id: that.saveShowList.id || '',
  463. bc: that.formState.bc,
  464. count: that.formState.count,
  465. jcdd: that.formState.jcdd,
  466. jcy: that.formState.jcy,
  467. time: that.formState.time,
  468. ch4: that.saveShowList.ch4Night2 || '',
  469. co2: that.saveShowList.co2Night2 || '',
  470. co: that.saveShowList.coNight2 || '',
  471. o2: that.saveShowList.o2Night2 || '',
  472. jw: that.saveShowList.jwSdzNight2 || '',
  473. gw: that.saveShowList.gwSdzNight2 || '',
  474. bxy: that.saveShowList.bxySdzNight2 || '',
  475. tbrq: that.formState.tbrq,
  476. temp: that.saveShowList.tnight2 || '',
  477. mcgzm: that.formState.mcgzm,
  478. }
  479. that.isDisabled = true
  480. } else {
  481. that.formState = {
  482. id: that.formState.id,
  483. bc: that.formState.bc,
  484. count: that.formState.count,
  485. jcdd: that.formState.jcdd,
  486. jcy: that.formState.jcy,
  487. time: that.formState.time,
  488. ch4: '',
  489. co2: '',
  490. co: '',
  491. o2: '',
  492. jw: '',
  493. gw: '',
  494. bxy: '',
  495. tbrq: that.formState.tbrq,
  496. temp: '',
  497. mcgzm: that.formState.mcgzm,
  498. }
  499. that.isDisabled = false
  500. }
  501. }
  502. },
  503. //监测次数选项切换
  504. changeCount(e) {
  505. let that = this
  506. that.formState.count = e
  507. if (that.formState.bc == '早班' && that.formState.count == '第一次') {
  508. if (that.saveShowList.bxySdzEarly1 || that.saveShowList.ch4Early1 || that.saveShowList.co2Early1 || that.saveShowList.coEarly1 || that.saveShowList.gwSdzEarly1 || that.saveShowList.jwSdzEarly1 || that.saveShowList.o2Early1 || that.saveShowList.tearly1) {
  509. that.formState = {
  510. id: that.saveShowList.id || '',
  511. bc: that.formState.bc,
  512. count: that.formState.count,
  513. jcdd: that.formState.jcdd,
  514. jcy: that.formState.jcy,
  515. time: that.formState.time,
  516. ch4: that.saveShowList.ch4Early1 || '',
  517. co2: that.saveShowList.co2Early1 || '',
  518. co: that.saveShowList.coEarly1 || '',
  519. o2: that.saveShowList.o2Early1 || '',
  520. jw: that.saveShowList.jwSdzEarly1 || '',
  521. gw: that.saveShowList.gwSdzEarly1 || '',
  522. bxy: that.saveShowList.bxySdzEarly1 || '',
  523. tbrq: that.formState.tbrq,
  524. temp: that.saveShowList.tearly1 || '',
  525. mcgzm: that.formState.mcgzm,
  526. }
  527. that.isDisabled = true
  528. } else {
  529. that.formState = {
  530. id: that.formState.id,
  531. bc: that.formState.bc,
  532. count: that.formState.count,
  533. jcdd: that.formState.jcdd,
  534. jcy: that.formState.jcy,
  535. time: that.formState.time,
  536. ch4: '',
  537. co2: '',
  538. co: '',
  539. o2: '',
  540. jw: '',
  541. gw: '',
  542. bxy: '',
  543. tbrq: that.formState.tbrq,
  544. temp: '',
  545. mcgzm: that.formState.mcgzm,
  546. }
  547. that.isDisabled = false
  548. }
  549. } else if (that.formState.bc == '早班' && that.formState.count == '第二次') {
  550. if (that.saveShowList.bxySdzEarly2 || that.saveShowList.ch4Early2 || that.saveShowList.co2Early2 || that.saveShowList.coEarly2 || that.saveShowList.gwSdzEarly2 || that.saveShowList.jwSdzEarly2 || that.saveShowList.o2Early2 || that.saveShowList.tearly2) {
  551. that.formState = {
  552. id: that.saveShowList.id || '',
  553. bc: that.formState.bc,
  554. count: that.formState.count,
  555. jcdd: that.formState.jcdd,
  556. jcy: that.formState.jcy,
  557. time: that.formState.time,
  558. ch4: that.saveShowList.ch4Early2 || '',
  559. co2: that.saveShowList.co2Early2 || '',
  560. co: that.saveShowList.coEarly2 || '',
  561. o2: that.saveShowList.o2Early2 || '',
  562. jw: that.saveShowList.jwSdzEarly2 || '',
  563. gw: that.saveShowList.gwSdzEarly2 || '',
  564. bxy: that.saveShowList.bxySdzEarly2 || '',
  565. tbrq: that.formState.tbrq,
  566. temp: that.saveShowList.tearly2 || '',
  567. mcgzm: that.formState.mcgzm,
  568. }
  569. that.isDisabled = true
  570. } else {
  571. that.formState = {
  572. id: that.formState.id,
  573. bc: that.formState.bc,
  574. count: that.formState.count,
  575. jcdd: that.formState.jcdd,
  576. jcy: that.formState.jcy,
  577. time: that.formState.time,
  578. ch4: '',
  579. co2: '',
  580. co: '',
  581. o2: '',
  582. jw: '',
  583. gw: '',
  584. bxy: '',
  585. tbrq: that.formState.tbrq,
  586. temp: '',
  587. mcgzm: that.formState.mcgzm,
  588. }
  589. that.isDisabled = false
  590. }
  591. } else if (that.formState.bc == '中班' && that.formState.count == '第一次') {
  592. if (that.saveShowList.bxySdzNoon1 || that.saveShowList.ch4Noon1 || that.saveShowList.co2Noon1 || that.saveShowList.coNoon1 || that.saveShowList.gwSdzNoon1 || that.saveShowList.jwSdzNoon1 || that.saveShowList.o2Noon1 || that.saveShowList.tnoon1) {
  593. that.formState = {
  594. id: that.saveShowList.id || '',
  595. bc: that.formState.bc,
  596. count: that.formState.count,
  597. jcdd: that.formState.jcdd,
  598. jcy: that.formState.jcy,
  599. time: that.formState.time,
  600. ch4: that.saveShowList.bxySdzNoon1 || '',
  601. co2: that.saveShowList.co2Noon1 || '',
  602. co: that.saveShowList.coNoon1 || '',
  603. o2: that.saveShowList.o2Noon1 || '',
  604. jw: that.saveShowList.jwSdzNoon1 || '',
  605. gw: that.saveShowList.gwSdzNoon1 || '',
  606. bxy: that.saveShowList.bxySdzNoon1 || '',
  607. tbrq: that.formState.tbrq,
  608. temp: that.saveShowList.tnoon1 || '',
  609. mcgzm: that.formState.mcgzm,
  610. }
  611. that.isDisabled = true
  612. } else {
  613. that.formState = {
  614. id: that.formState.id,
  615. bc: that.formState.bc,
  616. count: that.formState.count,
  617. jcdd: that.formState.jcdd,
  618. jcy: that.formState.jcy,
  619. time: that.formState.time,
  620. ch4: '',
  621. co2: '',
  622. co: '',
  623. o2: '',
  624. jw: '',
  625. gw: '',
  626. bxy: '',
  627. tbrq: that.formState.tbrq,
  628. temp: '',
  629. mcgzm: that.formState.mcgzm,
  630. }
  631. that.isDisabled = false
  632. }
  633. } else if (that.formState.bc == '中班' && that.formState.count == '第二次') {
  634. if (that.saveShowList.bxySdzNoon2 || that.saveShowList.ch4Noon2 || that.saveShowList.co2Noon2 || that.saveShowList.coNoon2 || that.saveShowList.gwSdzNoon2 || that.saveShowList.jwSdzNoon2 || that.saveShowList.o2Noon2 || that.saveShowList.tnoon2) {
  635. that.formState = {
  636. id: that.saveShowList.id || '',
  637. bc: that.formState.bc,
  638. count: that.formState.count,
  639. jcdd: that.formState.jcdd,
  640. jcy: that.formState.jcy,
  641. time: that.formState.time,
  642. ch4: that.saveShowList.bxySdzNoon2 || '',
  643. co2: that.saveShowList.co2Noon2 || '',
  644. co: that.saveShowList.coNoon2 || '',
  645. o2: that.saveShowList.o2Noon2 || '',
  646. jw: that.saveShowList.jwSdzNoon2 || '',
  647. gw: that.saveShowList.gwSdzNoon2 || '',
  648. bxy: that.saveShowList.bxySdzNoon2 || '',
  649. tbrq: that.formState.tbrq,
  650. temp: that.saveShowList.tnoon2 || '',
  651. mcgzm: that.formState.mcgzm,
  652. }
  653. that.isDisabled = true
  654. } else {
  655. that.formState = {
  656. id: that.formState.id,
  657. bc: that.formState.bc,
  658. count: that.formState.count,
  659. jcdd: that.formState.jcdd,
  660. jcy: that.formState.jcy,
  661. time: that.formState.time,
  662. ch4: '',
  663. co2: '',
  664. co: '',
  665. o2: '',
  666. jw: '',
  667. gw: '',
  668. bxy: '',
  669. tbrq: that.formState.tbrq,
  670. temp: '',
  671. mcgzm: that.formState.mcgzm,
  672. }
  673. that.isDisabled = false
  674. }
  675. } else if (that.formState.bc == '夜班' && that.formState.count == '第一次') {
  676. if (that.saveShowList.bxySdzNight1 || that.saveShowList.ch4Night1 || that.saveShowList.co2Night1 || that.saveShowList.coNight1 || that.saveShowList.gwSdzNight1 || that.saveShowList.jwSdzNight1 || that.saveShowList.o2Night1 || that.saveShowList.tnight1) {
  677. that.formState = {
  678. id: that.saveShowList.id || '',
  679. bc: that.formState.bc,
  680. count: that.formState.count,
  681. jcdd: that.formState.jcdd,
  682. jcy: that.formState.jcy,
  683. time: that.formState.time,
  684. ch4: that.saveShowList.ch4Night1 || '',
  685. co2: that.saveShowList.co2Night1 || '',
  686. co: that.saveShowList.coNight1 || '',
  687. o2: that.saveShowList.o2Night1 || '',
  688. jw: that.saveShowList.jwSdzNight1 || '',
  689. gw: that.saveShowList.gwSdzNight1 || '',
  690. bxy: that.saveShowList.bxySdzNight1 || '',
  691. tbrq: that.formState.tbrq,
  692. temp: that.saveShowList.tnight1 || '',
  693. mcgzm: that.formState.mcgzm,
  694. }
  695. that.isDisabled = true
  696. } else {
  697. that.formState = {
  698. id: that.formState.id,
  699. bc: that.formState.bc,
  700. count: that.formState.count,
  701. jcdd: that.formState.jcdd,
  702. jcy: that.formState.jcy,
  703. time: that.formState.time,
  704. ch4: '',
  705. co2: '',
  706. co: '',
  707. o2: '',
  708. jw: '',
  709. gw: '',
  710. bxy: '',
  711. tbrq: that.formState.tbrq,
  712. temp: '',
  713. mcgzm: that.formState.mcgzm,
  714. }
  715. that.isDisabled = false
  716. }
  717. } else if (that.formState.bc == '夜班' && that.formState.count == '第二次') {
  718. if (that.saveShowList.bxySdzNight2 || that.saveShowList.ch4Night2 || that.saveShowList.co2Night2 || that.saveShowList.coNight2 || that.saveShowList.gwSdzNight2 || that.saveShowList.jwSdzNight2 || that.saveShowList.o2Night2 || that.saveShowList.tnight2) {
  719. that.formState = {
  720. id: that.saveShowList.id || '',
  721. bc: that.formState.bc,
  722. count: that.formState.count,
  723. jcdd: that.formState.jcdd,
  724. jcy: that.formState.jcy,
  725. time: that.formState.time,
  726. ch4: that.saveShowList.ch4Night2 || '',
  727. co2: that.saveShowList.co2Night2 || '',
  728. co: that.saveShowList.coNight2 || '',
  729. o2: that.saveShowList.o2Night2 || '',
  730. jw: that.saveShowList.jwSdzNight2 || '',
  731. gw: that.saveShowList.gwSdzNight2 || '',
  732. bxy: that.saveShowList.bxySdzNight2 || '',
  733. tbrq: that.formState.tbrq,
  734. temp: that.saveShowList.tnight2 || '',
  735. mcgzm: that.formState.mcgzm,
  736. }
  737. that.isDisabled = true
  738. } else {
  739. that.formState = {
  740. id: that.formState.id,
  741. bc: that.formState.bc,
  742. count: that.formState.count,
  743. jcdd: that.formState.jcdd,
  744. jcy: that.formState.jcy,
  745. time: that.formState.time,
  746. ch4: '',
  747. co2: '',
  748. co: '',
  749. o2: '',
  750. jw: '',
  751. gw: '',
  752. bxy: '',
  753. tbrq: that.formState.tbrq,
  754. temp: '',
  755. mcgzm: that.formState.mcgzm,
  756. }
  757. that.isDisabled = false
  758. }
  759. }
  760. },
  761. //检测地点拉选项切换
  762. changeJc(e) {
  763. let that = this
  764. that.formState.jcdd = e
  765. that.deviceId = that.rangeJcdd.filter(v => v.text == e)[0].deviceId
  766. new Promise((resolve, reject) => {
  767. api
  768. .getGas({ reportTime: that.formState.tbrq, deviceId: that.deviceId })
  769. .then((response) => {
  770. if (response.data.code == 200) {
  771. let data = response.data.result.records
  772. if (data.length != 0) {
  773. that.saveShowList = data[0]
  774. if (that.formState.bc == '早班' && that.formState.count == '第一次') {
  775. if (that.saveShowList.bxySdzEarly1 || that.saveShowList.ch4Early1 || that.saveShowList.co2Early1 || that.saveShowList.coEarly1 || that.saveShowList.gwSdzEarly1 || that.saveShowList.jwSdzEarly1 || that.saveShowList.o2Early1 || that.saveShowList.tearly1) {
  776. that.formState = {
  777. id: that.saveShowList.id || '',
  778. bc: that.formState.bc,
  779. count: that.formState.count,
  780. jcdd: that.formState.jcdd,
  781. jcy: that.formState.jcy,
  782. time: that.formState.time,
  783. ch4: that.saveShowList.ch4Early1 || '',
  784. co2: that.saveShowList.co2Early1 || '',
  785. co: that.saveShowList.coEarly1 || '',
  786. o2: that.saveShowList.o2Early1 || '',
  787. jw: that.saveShowList.jwSdzEarly1 || '',
  788. gw: that.saveShowList.gwSdzEarly1 || '',
  789. bxy: that.saveShowList.bxySdzEarly1 || '',
  790. tbrq: that.formState.tbrq,
  791. temp: that.saveShowList.tearly1 || '',
  792. mcgzm: that.formState.mcgzm,
  793. }
  794. that.isDisabled = true
  795. } else {
  796. that.formState = {
  797. id: that.formState.id,
  798. bc: that.formState.bc,
  799. count: that.formState.count,
  800. jcdd: that.formState.jcdd,
  801. jcy: that.formState.jcy,
  802. time: that.formState.time,
  803. ch4: '',
  804. co2: '',
  805. co: '',
  806. o2: '',
  807. jw: '',
  808. gw: '',
  809. bxy: '',
  810. tbrq: that.formState.tbrq,
  811. temp: '',
  812. mcgzm: that.formState.mcgzm,
  813. }
  814. that.isDisabled = false
  815. }
  816. } else if (that.formState.bc == '早班' && that.formState.count == '第二次') {
  817. if (that.saveShowList.bxySdzEarly2 || that.saveShowList.ch4Early2 || that.saveShowList.co2Early2 || that.saveShowList.coEarly2 || that.saveShowList.gwSdzEarly2 || that.saveShowList.jwSdzEarly2 || that.saveShowList.o2Early2 || that.saveShowList.tearly2) {
  818. that.formState = {
  819. id: that.saveShowList.id || '',
  820. bc: that.formState.bc,
  821. count: that.formState.count,
  822. jcdd: that.formState.jcdd,
  823. jcy: that.formState.jcy,
  824. time: that.formState.time,
  825. ch4: that.saveShowList.ch4Early2 || '',
  826. co2: that.saveShowList.co2Early2 || '',
  827. co: that.saveShowList.coEarly2 || '',
  828. o2: that.saveShowList.o2Early2 || '',
  829. jw: that.saveShowList.jwSdzEarly2 || '',
  830. gw: that.saveShowList.gwSdzEarly2 || '',
  831. bxy: that.saveShowList.bxySdzEarly2 || '',
  832. tbrq: that.formState.tbrq,
  833. temp: that.saveShowList.tearly2 || '',
  834. mcgzm: that.formState.mcgzm,
  835. }
  836. that.isDisabled = true
  837. } else {
  838. that.formState = {
  839. id: that.formState.id,
  840. bc: that.formState.bc,
  841. count: that.formState.count,
  842. jcdd: that.formState.jcdd,
  843. jcy: that.formState.jcy,
  844. time: that.formState.time,
  845. ch4: '',
  846. co2: '',
  847. co: '',
  848. o2: '',
  849. jw: '',
  850. gw: '',
  851. bxy: '',
  852. tbrq: that.formState.tbrq,
  853. temp: '',
  854. mcgzm: that.formState.mcgzm,
  855. }
  856. that.isDisabled = false
  857. }
  858. } else if (that.formState.bc == '中班' && that.formState.count == '第一次') {
  859. if (that.saveShowList.bxySdzNoon1 || that.saveShowList.ch4Noon1 || that.saveShowList.co2Noon1 || that.saveShowList.coNoon1 || that.saveShowList.gwSdzNoon1 || that.saveShowList.jwSdzNoon1 || that.saveShowList.o2Noon1 || that.saveShowList.tnoon1) {
  860. that.formState = {
  861. id: that.saveShowList.id || '',
  862. bc: that.formState.bc,
  863. count: that.formState.count,
  864. jcdd: that.formState.jcdd,
  865. jcy: that.formState.jcy,
  866. time: that.formState.time,
  867. ch4: that.saveShowList.bxySdzNoon1 || '',
  868. co2: that.saveShowList.co2Noon1 || '',
  869. co: that.saveShowList.coNoon1 || '',
  870. o2: that.saveShowList.o2Noon1 || '',
  871. jw: that.saveShowList.jwSdzNoon1 || '',
  872. gw: that.saveShowList.gwSdzNoon1 || '',
  873. bxy: that.saveShowList.bxySdzNoon1 || '',
  874. tbrq: that.formState.tbrq,
  875. temp: that.saveShowList.tnoon1 || '',
  876. mcgzm: that.formState.mcgzm,
  877. }
  878. that.isDisabled = true
  879. } else {
  880. that.formState = {
  881. id: that.formState.id,
  882. bc: that.formState.bc,
  883. count: that.formState.count,
  884. jcdd: that.formState.jcdd,
  885. jcy: that.formState.jcy,
  886. time: that.formState.time,
  887. ch4: '',
  888. co2: '',
  889. co: '',
  890. o2: '',
  891. jw: '',
  892. gw: '',
  893. bxy: '',
  894. tbrq: that.formState.tbrq,
  895. temp: '',
  896. mcgzm: that.formState.mcgzm,
  897. }
  898. that.isDisabled = false
  899. }
  900. } else if (that.formState.bc == '中班' && that.formState.count == '第二次') {
  901. if (that.saveShowList.bxySdzNoon2 || that.saveShowList.ch4Noon2 || that.saveShowList.co2Noon2 || that.saveShowList.coNoon2 || that.saveShowList.gwSdzNoon2 || that.saveShowList.jwSdzNoon2 || that.saveShowList.o2Noon2 || that.saveShowList.tnoon2) {
  902. that.formState = {
  903. id: that.saveShowList.id || '',
  904. bc: that.formState.bc,
  905. count: that.formState.count,
  906. jcdd: that.formState.jcdd,
  907. jcy: that.formState.jcy,
  908. time: that.formState.time,
  909. ch4: that.saveShowList.bxySdzNoon2 || '',
  910. co2: that.saveShowList.co2Noon2 || '',
  911. co: that.saveShowList.coNoon2 || '',
  912. o2: that.saveShowList.o2Noon2 || '',
  913. jw: that.saveShowList.jwSdzNoon2 || '',
  914. gw: that.saveShowList.gwSdzNoon2 || '',
  915. bxy: that.saveShowList.bxySdzNoon2 || '',
  916. tbrq: that.formState.tbrq,
  917. temp: that.saveShowList.tnoon2 || '',
  918. mcgzm: that.formState.mcgzm,
  919. }
  920. that.isDisabled = true
  921. } else {
  922. that.formState = {
  923. id: that.formState.id,
  924. bc: that.formState.bc,
  925. count: that.formState.count,
  926. jcdd: that.formState.jcdd,
  927. jcy: that.formState.jcy,
  928. time: that.formState.time,
  929. ch4: '',
  930. co2: '',
  931. co: '',
  932. o2: '',
  933. jw: '',
  934. gw: '',
  935. bxy: '',
  936. tbrq: that.formState.tbrq,
  937. temp: '',
  938. mcgzm: that.formState.mcgzm,
  939. }
  940. that.isDisabled = false
  941. }
  942. } else if (that.formState.bc == '夜班' && that.formState.count == '第一次') {
  943. if (that.saveShowList.bxySdzNight1 || that.saveShowList.ch4Night1 || that.saveShowList.co2Night1 || that.saveShowList.coNight1 || that.saveShowList.gwSdzNight1 || that.saveShowList.jwSdzNight1 || that.saveShowList.o2Night1 || that.saveShowList.tnight1) {
  944. that.formState = {
  945. id: that.saveShowList.id || '',
  946. bc: that.formState.bc,
  947. count: that.formState.count,
  948. jcdd: that.formState.jcdd,
  949. jcy: that.formState.jcy,
  950. time: that.formState.time,
  951. ch4: that.saveShowList.ch4Night1 || '',
  952. co2: that.saveShowList.co2Night1 || '',
  953. co: that.saveShowList.coNight1 || '',
  954. o2: that.saveShowList.o2Night1 || '',
  955. jw: that.saveShowList.jwSdzNight1 || '',
  956. gw: that.saveShowList.gwSdzNight1 || '',
  957. bxy: that.saveShowList.bxySdzNight1 || '',
  958. tbrq: that.formState.tbrq,
  959. temp: that.saveShowList.tnight1 || '',
  960. mcgzm: that.formState.mcgzm,
  961. }
  962. that.isDisabled = true
  963. } else {
  964. that.formState = {
  965. id: that.formState.id,
  966. bc: that.formState.bc,
  967. count: that.formState.count,
  968. jcdd: that.formState.jcdd,
  969. jcy: that.formState.jcy,
  970. time: that.formState.time,
  971. ch4: '',
  972. co2: '',
  973. co: '',
  974. o2: '',
  975. jw: '',
  976. gw: '',
  977. bxy: '',
  978. tbrq: that.formState.tbrq,
  979. temp: '',
  980. mcgzm: that.formState.mcgzm,
  981. }
  982. that.isDisabled = false
  983. }
  984. } else if (that.formState.bc == '夜班' && that.formState.count == '第二次') {
  985. if (that.saveShowList.bxySdzNight2 || that.saveShowList.ch4Night2 || that.saveShowList.co2Night2 || that.saveShowList.coNight2 || that.saveShowList.gwSdzNight2 || that.saveShowList.jwSdzNight2 || that.saveShowList.o2Night2 || that.saveShowList.tnight2) {
  986. that.formState = {
  987. id: that.saveShowList.id || '',
  988. bc: that.formState.bc,
  989. count: that.formState.count,
  990. jcdd: that.formState.jcdd,
  991. jcy: that.formState.jcy,
  992. time: that.formState.time,
  993. ch4: that.saveShowList.ch4Night2 || '',
  994. co2: that.saveShowList.co2Night2 || '',
  995. co: that.saveShowList.coNight2 || '',
  996. o2: that.saveShowList.o2Night2 || '',
  997. jw: that.saveShowList.jwSdzNight2 || '',
  998. gw: that.saveShowList.gwSdzNight2 || '',
  999. bxy: that.saveShowList.bxySdzNight2 || '',
  1000. tbrq: that.formState.tbrq,
  1001. temp: that.saveShowList.tnight2 || '',
  1002. mcgzm: that.formState.mcgzm,
  1003. }
  1004. that.isDisabled = true
  1005. } else {
  1006. that.formState = {
  1007. id: that.formState.id,
  1008. bc: that.formState.bc,
  1009. count: that.formState.count,
  1010. jcdd: that.formState.jcdd,
  1011. jcy: that.formState.jcy,
  1012. time: that.formState.time,
  1013. ch4: '',
  1014. co2: '',
  1015. co: '',
  1016. o2: '',
  1017. jw: '',
  1018. gw: '',
  1019. bxy: '',
  1020. tbrq: that.formState.tbrq,
  1021. temp: '',
  1022. mcgzm: that.formState.mcgzm,
  1023. }
  1024. that.isDisabled = false
  1025. }
  1026. }
  1027. } else {
  1028. that.isDisabled = false
  1029. that.saveShowList = {}
  1030. that.formState = {
  1031. id: '',
  1032. bc: that.formState.bc || '',
  1033. count: that.formState.count || '',
  1034. jcdd: that.formState.jcdd || '',
  1035. mcgzm: that.formState.mcgzm || '',
  1036. jcy: that.formState.jcy || '',
  1037. time: that.formState.time,
  1038. tbrq: that.formState.tbrq,
  1039. ch4: '',
  1040. co2: '',
  1041. co: '',
  1042. o2: '',
  1043. jw: '',
  1044. gw: '',
  1045. bxy: '',
  1046. temp: '',
  1047. }
  1048. }
  1049. } else {
  1050. reject(response);
  1051. }
  1052. })
  1053. .catch((error) => {
  1054. console.log("catch===>response", response);
  1055. reject(error);
  1056. });
  1057. });
  1058. },
  1059. //工作面煤层选项切换
  1060. changeMc(e) {
  1061. this.formState.mcgzm = e
  1062. this.getSelectList()
  1063. },
  1064. //检测时间下拉选项切换
  1065. change(e) {
  1066. let that = this
  1067. that.formState.time = moment(e.value).format('YYYY-MM-DD HH:mm:ss')
  1068. that.formState.tbrq = moment(e.value).format('YYYY-MM-DD')
  1069. new Promise((resolve, reject) => {
  1070. api
  1071. .getGas({ reportTime: that.formState.tbrq, deviceId: that.deviceId })
  1072. .then((response) => {
  1073. if (response.data.code == 200) {
  1074. let data = response.data.result.records
  1075. if (data.length != 0) {
  1076. that.saveShowList = data[0]
  1077. if (that.formState.bc == '早班' && that.formState.count == '第一次') {
  1078. if (that.saveShowList.bxySdzEarly1 || that.saveShowList.ch4Early1 || that.saveShowList.co2Early1 || that.saveShowList.coEarly1 || that.saveShowList.gwSdzEarly1 || that.saveShowList.jwSdzEarly1 || that.saveShowList.o2Early1 || that.saveShowList.tearly1) {
  1079. that.formState = {
  1080. id: that.saveShowList.id || '',
  1081. bc: that.formState.bc,
  1082. count: that.formState.count,
  1083. jcdd: that.formState.jcdd,
  1084. jcy: that.formState.jcy,
  1085. time: that.formState.time,
  1086. ch4: that.saveShowList.ch4Early1 || '',
  1087. co2: that.saveShowList.co2Early1 || '',
  1088. co: that.saveShowList.coEarly1 || '',
  1089. o2: that.saveShowList.o2Early1 || '',
  1090. jw: that.saveShowList.jwSdzEarly1 || '',
  1091. gw: that.saveShowList.gwSdzEarly1 || '',
  1092. bxy: that.saveShowList.bxySdzEarly1 || '',
  1093. tbrq: that.formState.tbrq,
  1094. temp: that.saveShowList.tearly1 || '',
  1095. mcgzm: that.formState.mcgzm,
  1096. }
  1097. that.isDisabled = true
  1098. } else {
  1099. that.formState = {
  1100. id: that.formState.id,
  1101. bc: that.formState.bc,
  1102. count: that.formState.count,
  1103. jcdd: that.formState.jcdd,
  1104. jcy: that.formState.jcy,
  1105. time: that.formState.time,
  1106. ch4: '',
  1107. co2: '',
  1108. co: '',
  1109. o2: '',
  1110. jw: '',
  1111. gw: '',
  1112. bxy: '',
  1113. tbrq: that.formState.tbrq,
  1114. temp: '',
  1115. mcgzm: that.formState.mcgzm,
  1116. }
  1117. that.isDisabled = false
  1118. }
  1119. } else if (that.formState.bc == '早班' && that.formState.count == '第二次') {
  1120. if (that.saveShowList.bxySdzEarly2 || that.saveShowList.ch4Early2 || that.saveShowList.co2Early2 || that.saveShowList.coEarly2 || that.saveShowList.gwSdzEarly2 || that.saveShowList.jwSdzEarly2 || that.saveShowList.o2Early2 || that.saveShowList.tearly2) {
  1121. that.formState = {
  1122. id: that.saveShowList.id || '',
  1123. bc: that.formState.bc,
  1124. count: that.formState.count,
  1125. jcdd: that.formState.jcdd,
  1126. jcy: that.formState.jcy,
  1127. time: that.formState.time,
  1128. ch4: that.saveShowList.ch4Early2 || '',
  1129. co2: that.saveShowList.co2Early2 || '',
  1130. co: that.saveShowList.coEarly2 || '',
  1131. o2: that.saveShowList.o2Early2 || '',
  1132. jw: that.saveShowList.jwSdzEarly2 || '',
  1133. gw: that.saveShowList.gwSdzEarly2 || '',
  1134. bxy: that.saveShowList.bxySdzEarly2 || '',
  1135. tbrq: that.formState.tbrq,
  1136. temp: that.saveShowList.tearly2 || '',
  1137. mcgzm: that.formState.mcgzm,
  1138. }
  1139. that.isDisabled = true
  1140. } else {
  1141. that.formState = {
  1142. id: that.formState.id,
  1143. bc: that.formState.bc,
  1144. count: that.formState.count,
  1145. jcdd: that.formState.jcdd,
  1146. jcy: that.formState.jcy,
  1147. time: that.formState.time,
  1148. ch4: '',
  1149. co2: '',
  1150. co: '',
  1151. o2: '',
  1152. jw: '',
  1153. gw: '',
  1154. bxy: '',
  1155. tbrq: that.formState.tbrq,
  1156. temp: '',
  1157. mcgzm: that.formState.mcgzm,
  1158. }
  1159. that.isDisabled = false
  1160. }
  1161. } else if (that.formState.bc == '中班' && that.formState.count == '第一次') {
  1162. if (that.saveShowList.bxySdzNoon1 || that.saveShowList.ch4Noon1 || that.saveShowList.co2Noon1 || that.saveShowList.coNoon1 || that.saveShowList.gwSdzNoon1 || that.saveShowList.jwSdzNoon1 || that.saveShowList.o2Noon1 || that.saveShowList.tnoon1) {
  1163. that.formState = {
  1164. id: that.saveShowList.id || '',
  1165. bc: that.formState.bc,
  1166. count: that.formState.count,
  1167. jcdd: that.formState.jcdd,
  1168. jcy: that.formState.jcy,
  1169. time: that.formState.time,
  1170. ch4: that.saveShowList.bxySdzNoon1 || '',
  1171. co2: that.saveShowList.co2Noon1 || '',
  1172. co: that.saveShowList.coNoon1 || '',
  1173. o2: that.saveShowList.o2Noon1 || '',
  1174. jw: that.saveShowList.jwSdzNoon1 || '',
  1175. gw: that.saveShowList.gwSdzNoon1 || '',
  1176. bxy: that.saveShowList.bxySdzNoon1 || '',
  1177. tbrq: that.formState.tbrq,
  1178. temp: that.saveShowList.tnoon1 || '',
  1179. mcgzm: that.formState.mcgzm,
  1180. }
  1181. that.isDisabled = true
  1182. } else {
  1183. that.formState = {
  1184. id: that.formState.id,
  1185. bc: that.formState.bc,
  1186. count: that.formState.count,
  1187. jcdd: that.formState.jcdd,
  1188. jcy: that.formState.jcy,
  1189. time: that.formState.time,
  1190. ch4: '',
  1191. co2: '',
  1192. co: '',
  1193. o2: '',
  1194. jw: '',
  1195. gw: '',
  1196. bxy: '',
  1197. tbrq: that.formState.tbrq,
  1198. temp: '',
  1199. mcgzm: that.formState.mcgzm,
  1200. }
  1201. that.isDisabled = false
  1202. }
  1203. } else if (that.formState.bc == '中班' && that.formState.count == '第二次') {
  1204. if (that.saveShowList.bxySdzNoon2 || that.saveShowList.ch4Noon2 || that.saveShowList.co2Noon2 || that.saveShowList.coNoon2 || that.saveShowList.gwSdzNoon2 || that.saveShowList.jwSdzNoon2 || that.saveShowList.o2Noon2 || that.saveShowList.tnoon2) {
  1205. that.formState = {
  1206. id: that.saveShowList.id || '',
  1207. bc: that.formState.bc,
  1208. count: that.formState.count,
  1209. jcdd: that.formState.jcdd,
  1210. jcy: that.formState.jcy,
  1211. time: that.formState.time,
  1212. ch4: that.saveShowList.bxySdzNoon2 || '',
  1213. co2: that.saveShowList.co2Noon2 || '',
  1214. co: that.saveShowList.coNoon2 || '',
  1215. o2: that.saveShowList.o2Noon2 || '',
  1216. jw: that.saveShowList.jwSdzNoon2 || '',
  1217. gw: that.saveShowList.gwSdzNoon2 || '',
  1218. bxy: that.saveShowList.bxySdzNoon2 || '',
  1219. tbrq: that.formState.tbrq,
  1220. temp: that.saveShowList.tnoon2 || '',
  1221. mcgzm: that.formState.mcgzm,
  1222. }
  1223. that.isDisabled = true
  1224. } else {
  1225. that.formState = {
  1226. id: that.formState.id,
  1227. bc: that.formState.bc,
  1228. count: that.formState.count,
  1229. jcdd: that.formState.jcdd,
  1230. jcy: that.formState.jcy,
  1231. time: that.formState.time,
  1232. ch4: '',
  1233. co2: '',
  1234. co: '',
  1235. o2: '',
  1236. jw: '',
  1237. gw: '',
  1238. bxy: '',
  1239. tbrq: that.formState.tbrq,
  1240. temp: '',
  1241. mcgzm: that.formState.mcgzm,
  1242. }
  1243. that.isDisabled = false
  1244. }
  1245. } else if (that.formState.bc == '夜班' && that.formState.count == '第一次') {
  1246. if (that.saveShowList.bxySdzNight1 || that.saveShowList.ch4Night1 || that.saveShowList.co2Night1 || that.saveShowList.coNight1 || that.saveShowList.gwSdzNight1 || that.saveShowList.jwSdzNight1 || that.saveShowList.o2Night1 || that.saveShowList.tnight1) {
  1247. that.formState = {
  1248. id: that.saveShowList.id || '',
  1249. bc: that.formState.bc,
  1250. count: that.formState.count,
  1251. jcdd: that.formState.jcdd,
  1252. jcy: that.formState.jcy,
  1253. time: that.formState.time,
  1254. ch4: that.saveShowList.ch4Night1 || '',
  1255. co2: that.saveShowList.co2Night1 || '',
  1256. co: that.saveShowList.coNight1 || '',
  1257. o2: that.saveShowList.o2Night1 || '',
  1258. jw: that.saveShowList.jwSdzNight1 || '',
  1259. gw: that.saveShowList.gwSdzNight1 || '',
  1260. bxy: that.saveShowList.bxySdzNight1 || '',
  1261. tbrq: that.formState.tbrq,
  1262. temp: that.saveShowList.tnight1 || '',
  1263. mcgzm: that.formState.mcgzm,
  1264. }
  1265. that.isDisabled = true
  1266. } else {
  1267. that.formState = {
  1268. id: that.formState.id,
  1269. bc: that.formState.bc,
  1270. count: that.formState.count,
  1271. jcdd: that.formState.jcdd,
  1272. jcy: that.formState.jcy,
  1273. time: that.formState.time,
  1274. ch4: '',
  1275. co2: '',
  1276. co: '',
  1277. o2: '',
  1278. jw: '',
  1279. gw: '',
  1280. bxy: '',
  1281. tbrq: that.formState.tbrq,
  1282. temp: '',
  1283. mcgzm: that.formState.mcgzm,
  1284. }
  1285. that.isDisabled = false
  1286. }
  1287. } else if (that.formState.bc == '夜班' && that.formState.count == '第二次') {
  1288. if (that.saveShowList.bxySdzNight2 || that.saveShowList.ch4Night2 || that.saveShowList.co2Night2 || that.saveShowList.coNight2 || that.saveShowList.gwSdzNight2 || that.saveShowList.jwSdzNight2 || that.saveShowList.o2Night2 || that.saveShowList.tnight2) {
  1289. that.formState = {
  1290. id: that.saveShowList.id || '',
  1291. bc: that.formState.bc,
  1292. count: that.formState.count,
  1293. jcdd: that.formState.jcdd,
  1294. jcy: that.formState.jcy,
  1295. time: that.formState.time,
  1296. ch4: that.saveShowList.ch4Night2 || '',
  1297. co2: that.saveShowList.co2Night2 || '',
  1298. co: that.saveShowList.coNight2 || '',
  1299. o2: that.saveShowList.o2Night2 || '',
  1300. jw: that.saveShowList.jwSdzNight2 || '',
  1301. gw: that.saveShowList.gwSdzNight2 || '',
  1302. bxy: that.saveShowList.bxySdzNight2 || '',
  1303. tbrq: that.formState.tbrq,
  1304. temp: that.saveShowList.tnight2 || '',
  1305. mcgzm: that.formState.mcgzm,
  1306. }
  1307. that.isDisabled = true
  1308. } else {
  1309. that.formState = {
  1310. id: that.formState.id,
  1311. bc: that.formState.bc,
  1312. count: that.formState.count,
  1313. jcdd: that.formState.jcdd,
  1314. jcy: that.formState.jcy,
  1315. time: that.formState.time,
  1316. ch4: '',
  1317. co2: '',
  1318. co: '',
  1319. o2: '',
  1320. jw: '',
  1321. gw: '',
  1322. bxy: '',
  1323. tbrq: that.formState.tbrq,
  1324. temp: '',
  1325. mcgzm: that.formState.mcgzm,
  1326. }
  1327. that.isDisabled = false
  1328. }
  1329. }
  1330. } else {
  1331. that.isDisabled = false
  1332. that.saveShowList = {}
  1333. that.formState = {
  1334. id: '',
  1335. bc: that.formState.bc || '',
  1336. count: that.formState.count || '',
  1337. jcdd: that.formState.jcdd || '',
  1338. mcgzm: that.formState.mcgzm || '',
  1339. jcy: that.formState.jcy || '',
  1340. time: that.formState.time,
  1341. tbrq: that.formState.tbrq,
  1342. ch4: '',
  1343. co2: '',
  1344. co: '',
  1345. o2: '',
  1346. jw: '',
  1347. gw: '',
  1348. bxy: '',
  1349. temp: '',
  1350. }
  1351. }
  1352. } else {
  1353. reject(response);
  1354. }
  1355. })
  1356. .catch((error) => {
  1357. console.log("catch===>response", response);
  1358. reject(error);
  1359. });
  1360. });
  1361. },
  1362. changeTb(e) {
  1363. this.tbTime = moment(e.value).format('YYYY-MM-DD')
  1364. },
  1365. //点击弹出日期下拉选项
  1366. getChangeTime() {
  1367. this.showCalendar = true
  1368. },
  1369. getChangeTimeTb() {
  1370. this.showCalendarTb = true
  1371. },
  1372. confirmTb() {
  1373. this.showCalendarTb = false
  1374. this.getGasList()
  1375. },
  1376. //输入框内容变换
  1377. changeInput(val, data) {
  1378. if (/^00/.test(val)) {
  1379. this.formState[data] = val.replace(/^00/, '0');
  1380. } else {
  1381. this.formState[data] = val
  1382. }
  1383. },
  1384. //便携仪失去焦点时参数校验
  1385. getBlurBxy(val) {
  1386. let str = val.substring(val.indexOf('.') + 1).split('')
  1387. if (/^(\-|\+)?\d+$/.test(val)) {
  1388. this.formState.bxy = val
  1389. this.isRule3 = true
  1390. } else if (/^-?([1-9]\d*\.\d*|0\.\d*[1-9]\d*|0?\.0+|0)$/.test(val) && str.length <= 2) {
  1391. this.formState.bxy = val
  1392. this.isRule3 = true
  1393. } else {
  1394. this.formState.bxy = ''
  1395. this.isRule3 = false
  1396. }
  1397. },
  1398. //新增光瓦失去焦点时参数校验
  1399. getBlur(val) {
  1400. let str = val.substring(val.indexOf('.') + 1).split('')
  1401. if (val.slice(-1) == '0' || val.slice(-1) == '2' || val.slice(-1) == '4' || val.slice(-1) == '6' || val.slice(-1) == '8') {
  1402. if (/^-?([1-9]\d*\.\d*|0\.\d*[1-9]\d*|0?\.0+|0)$/.test(val)) {
  1403. if (str.length <= 2) {
  1404. this.formState.gw = val
  1405. this.isRule1 = true
  1406. } else {
  1407. this.formState.gw = ''
  1408. this.isRule1 = false
  1409. }
  1410. } else {
  1411. this.formState.gw = val
  1412. this.isRule1 = true
  1413. }
  1414. } else {
  1415. this.formState.gw = ''
  1416. this.isRule1 = false
  1417. }
  1418. },
  1419. //新增CO2失去焦点时参数校验
  1420. getBlurCO2(val) {
  1421. console.log(val, '000')
  1422. let str = val.substring(val.indexOf('.') + 1).split('')
  1423. if (val.slice(-1) == '0' || val.slice(-1) == '2' || val.slice(-1) == '4' || val.slice(-1) == '6' || val.slice(-1) == '8') {
  1424. if (/^-?([1-9]\d*\.\d*|0\.\d*[1-9]\d*|0?\.0+|0)$/.test(val)) {
  1425. if (str.length <= 2) {
  1426. this.formState.co2 = val
  1427. this.isRule = true
  1428. } else {
  1429. console.log(111)
  1430. this.formState.co2 = ''
  1431. this.isRule = false
  1432. }
  1433. } else {
  1434. this.formState.co2 = val
  1435. this.isRule = true
  1436. }
  1437. } else {
  1438. console.log(222)
  1439. this.formState.co2 = ''
  1440. this.isRule = false
  1441. }
  1442. },
  1443. //新增CH4失去焦点时参数校验
  1444. getBlurCH4(val) {
  1445. let str = val.substring(val.indexOf('.') + 1).split('')
  1446. if (val.slice(-1) == '0' || val.slice(-1) == '2' || val.slice(-1) == '4' || val.slice(-1) == '6' || val.slice(-1) == '8') {
  1447. if (/^-?([1-9]\d*\.\d*|0\.\d*[1-9]\d*|0?\.0+|0)$/.test(val)) {
  1448. if (str.length <= 2) {
  1449. this.formState.ch4 = val
  1450. this.isRule2 = true
  1451. } else {
  1452. this.formState.ch4 = ''
  1453. this.isRule2 = false
  1454. }
  1455. } else {
  1456. this.formState.ch4 = val
  1457. this.isRule2 = true
  1458. }
  1459. } else {
  1460. this.formState.ch4 = ''
  1461. this.isRule2 = false
  1462. }
  1463. },
  1464. getBlurCO(val) {
  1465. let str = val.substring(val.indexOf('.') + 1).split('')
  1466. if (/^(\-|\+)?\d+$/.test(val) && parseFloat(val) <= 24) {
  1467. this.formState.co = val
  1468. this.isRule14 = true
  1469. } else if (/^-?([1-9]\d*\.\d*|0\.\d*[1-9]\d*|0?\.0+|0)$/.test(val) && str.length <= 2 && parseFloat(val) <= 24) {
  1470. this.formState.co = val
  1471. this.isRule14 = true
  1472. } else {
  1473. this.formState.co = ''
  1474. this.isRule14 = false
  1475. }
  1476. },
  1477. //瓦斯新增
  1478. getAdd() {
  1479. let that = this
  1480. that.isShowAdd = true
  1481. that.isStatus = 'add'
  1482. that.formState.jcy = this.username
  1483. },
  1484. getAddSave() {
  1485. let that = this
  1486. let param = {}
  1487. if (that.formState.bc == '早班' && that.formState.count == '第一次') {
  1488. param = {
  1489. id: that.formState.id,
  1490. deviceId: that.deviceId,
  1491. bxySdzEarly1: that.formState.bxy,
  1492. ch4Early1: that.formState.ch4,
  1493. checkPersonEarly: that.formState.jcy,
  1494. co2Early1: that.formState.co2,
  1495. coEarly1: that.formState.co,
  1496. gwSdzEarly1: that.formState.gw,
  1497. jwSdzEarly1: that.formState.ch4,
  1498. o2Early1: that.formState.o2,
  1499. strInstallPos: that.formState.jcdd,
  1500. timeEarly1: that.formState.time,
  1501. reportTime: that.formState.tbrq,
  1502. tearly1: that.formState.temp
  1503. }
  1504. } else if (that.formState.bc == '早班' && that.formState.count == '第二次') {
  1505. param = {
  1506. deviceId: that.deviceId,
  1507. id: that.formState.id,
  1508. bxySdzEarly2: that.formState.bxy,
  1509. ch4Early2: that.formState.ch4,
  1510. checkPersonEarly: that.formState.jcy,
  1511. co2Early2: that.formState.co2,
  1512. coEarly2: that.formState.co,
  1513. gwSdzEarly2: that.formState.gw,
  1514. jwSdzEarly2: that.formState.ch4,
  1515. o2Early2: that.formState.o2,
  1516. strInstallPos: that.formState.jcdd,
  1517. timeEarly2: that.formState.time,
  1518. reportTime: that.formState.tbrq,
  1519. tearly2: that.formState.temp
  1520. }
  1521. } else if (that.formState.bc == '中班' && that.formState.count == '第一次') {
  1522. param = {
  1523. deviceId: that.deviceId,
  1524. id: that.formState.id,
  1525. bxySdzNoon1: that.formState.bxy,
  1526. ch4Noon1: that.formState.ch4,
  1527. checkPersonNoon: that.formState.jcy,
  1528. co2Noon1: that.formState.co2,
  1529. coNoon1: that.formState.co,
  1530. gwSdzNoon1: that.formState.gw,
  1531. jwSdzNoon1: that.formState.ch4,
  1532. o2Noon1: that.formState.o2,
  1533. strInstallPos: that.formState.jcdd,
  1534. timeNoon1: that.formState.time,
  1535. reportTime: that.formState.tbrq,
  1536. tnoon1: that.formState.temp
  1537. }
  1538. } else if (that.formState.bc == '中班' && that.formState.count == '第二次') {
  1539. param = {
  1540. deviceId: that.deviceId,
  1541. id: that.formState.id,
  1542. bxySdzNoon2: that.formState.bxy,
  1543. ch4Noon2: that.formState.ch4,
  1544. checkPersonNoon: that.formState.jcy,
  1545. co2Noon2: that.formState.co2,
  1546. coNoon2: that.formState.co,
  1547. gwSdzNoon2: that.formState.gw,
  1548. jwSdzNoon2: that.formState.ch4,
  1549. o2Noon2: that.formState.o2,
  1550. strInstallPos: that.formState.jcdd,
  1551. timeNoon2: that.formState.time,
  1552. reportTime: that.formState.tbrq,
  1553. tnoon2: that.formState.temp
  1554. }
  1555. } else if (that.formState.bc == '夜班' && that.formState.count == '第一次') {
  1556. param = {
  1557. deviceId: that.deviceId,
  1558. id: that.formState.id,
  1559. bxySdzNight1: that.formState.bxy,
  1560. ch4Night1: that.formState.ch4,
  1561. checkPersonNight: that.formState.jcy,
  1562. co2Night1: that.formState.co2,
  1563. coNight1: that.formState.co,
  1564. gwSdzNight1: that.formState.gw,
  1565. jwSdzNight1: that.formState.ch4,
  1566. o2Night1: that.formState.o2,
  1567. strInstallPos: that.formState.jcdd,
  1568. timeNight1: that.formState.time,
  1569. reportTime: that.formState.tbrq,
  1570. tnight1: that.formState.temp
  1571. }
  1572. } else if (that.formState.bc == '夜班' && that.formState.count == '第二次') {
  1573. param = {
  1574. deviceId: that.deviceId,
  1575. id: that.formState.id,
  1576. bxySdzNight2: that.formState.bxy,
  1577. ch4Night2: that.formState.ch4,
  1578. checkPersonNoon: that.formState.jcy,
  1579. co2Night2: that.formState.co2,
  1580. coNight2: that.formState.co,
  1581. gwSdzNight2: that.formState.gw,
  1582. jwSdzNight2: that.formState.ch4,
  1583. o2Night2: that.formState.o2,
  1584. strInstallPos: that.formState.jcdd,
  1585. timeNight2: that.formState.time,
  1586. reportTime: that.formState.tbrq,
  1587. tnight2: that.formState.temp
  1588. }
  1589. }
  1590. new Promise((resolve, reject) => {
  1591. api
  1592. .getAdd({ ...param })
  1593. .then((response) => {
  1594. if (response.data.code == 200) {
  1595. that.getGasList()
  1596. that.isShowAdd = false
  1597. that.isDisabled = false
  1598. that.saveShowList = {}
  1599. that.clearData()
  1600. } else {
  1601. reject(response);
  1602. }
  1603. })
  1604. .catch((error) => {
  1605. console.log("catch===>response", response);
  1606. reject(error);
  1607. });
  1608. });
  1609. },
  1610. getEditSave() {
  1611. let that = this
  1612. let param = {}
  1613. if (that.formState.bc == '早班' && that.formState.count == '第一次') {
  1614. param = {
  1615. id: that.saveShowList.id,
  1616. bxySdzEarly1: that.formState.bxy,
  1617. ch4Early1: that.formState.ch4,
  1618. checkPersonEarly: that.formState.jcy,
  1619. co2Early1: that.formState.co2,
  1620. coEarly1: that.formState.co,
  1621. gwSdzEarly1: that.formState.gw,
  1622. jwSdzEarly1: that.formState.ch4,
  1623. o2Early1: that.formState.o2,
  1624. strInstallPos: that.formState.jcdd,
  1625. timeEarly1: that.formState.time,
  1626. tearly1: that.formState.temp,
  1627. bxySdzEarly2: that.saveShowList.bxySdzEarly2,
  1628. ch4Early2: that.saveShowList.ch4Early2,
  1629. co2Early2: that.saveShowList.co2Early2,
  1630. coEarly2: that.saveShowList.coEarly2,
  1631. gwSdzEarly2: that.saveShowList.gwSdzEarly2,
  1632. jwSdzEarly2: that.saveShowList.jwSdzEarly2,
  1633. o2Early2: that.saveShowList.o2Early2,
  1634. timeEarly2: that.saveShowList.timeEarly2,
  1635. tearly2: that.saveShowList.tearly2,
  1636. bxySdzNoon1: that.saveShowList.bxySdzNoon1,
  1637. ch4Noon1: that.saveShowList.ch4Noon1,
  1638. checkPersonNoon: that.formState.jcy,
  1639. co2Noon1: that.saveShowList.co2Noon1,
  1640. coNoon1: that.saveShowList.coNoon1,
  1641. gwSdzNoon1: that.saveShowList.gwSdzNoon1,
  1642. jwSdzNoon1: that.saveShowList.jwSdzNoon1,
  1643. o2Noon1: that.saveShowList.o2Noon1,
  1644. strInstallPos: that.saveShowList.strInstallPos,
  1645. timeNoon1: that.saveShowList.timeNoon1,
  1646. tnoon1: that.saveShowList.tnoon1,
  1647. bxySdzNoon2: that.saveShowList.bxySdzNoon2,
  1648. ch4Noon2: that.saveShowList.ch4Noon2,
  1649. co2Noon2: that.saveShowList.co2Noon2,
  1650. coNoon2: that.saveShowList.coNoon2,
  1651. gwSdzNoon2: that.saveShowList.gwSdzNoon2,
  1652. jwSdzNoon2: that.saveShowList.jwSdzNoon2,
  1653. o2Noon2: that.saveShowList.o2Noon2,
  1654. timeNoon2: that.saveShowList.timeNoon2,
  1655. tnoon2: that.saveShowList.tnoon2,
  1656. bxySdzNight1: that.saveShowList.bxySdzNight1,
  1657. ch4Night1: that.saveShowList.ch4Night1,
  1658. checkPersonNight: that.formState.jcy,
  1659. co2Night1: that.saveShowList.co2Night1,
  1660. coNight1: that.saveShowList.coNight1,
  1661. gwSdzNight1: that.saveShowList.gwSdzNight1,
  1662. jwSdzNight1: that.saveShowList.jwSdzNight1,
  1663. o2Night1: that.saveShowList.o2Night1,
  1664. strInstallPos: that.saveShowList.strInstallPos,
  1665. timeNight1: that.saveShowList.timeNight1,
  1666. tnight1: that.saveShowList.tnight1,
  1667. bxySdzNight2: that.saveShowList.bxySdzNight2,
  1668. ch4Night2: that.saveShowList.ch4Night2,
  1669. co2Night2: that.saveShowList.co2Night2,
  1670. coNight2: that.saveShowList.coNight2,
  1671. gwSdzNight2: that.saveShowList.gwSdzNight2,
  1672. jwSdzNight2: that.saveShowList.jwSdzNight2,
  1673. o2Night2: that.saveShowList.o2Night2,
  1674. timeNight2: that.saveShowList.timeNight2,
  1675. tnight2: that.saveShowList.tnight2,
  1676. }
  1677. } else if (that.formState.bc == '早班' && that.formState.count == '第二次') {
  1678. param = {
  1679. id: that.saveShowList.id,
  1680. bxySdzEarly1: that.saveShowList.bxySdzEarly1,
  1681. ch4Early1: that.saveShowList.ch4Early1,
  1682. co2Early1: that.saveShowList.co2Early1,
  1683. coEarly1: that.saveShowList.coEarly1,
  1684. gwSdzEarly1: that.saveShowList.gwSdzEarly1,
  1685. jwSdzEarly1: that.saveShowList.jwSdzEarly1,
  1686. o2Early1: that.saveShowList.o2Early1,
  1687. timeEarly1: that.saveShowList.timeEarly1,
  1688. tearly1: that.saveShowList.tearly1,
  1689. bxySdzEarly2: that.formState.bxy,
  1690. ch4Early2: that.formState.ch4,
  1691. checkPersonEarly: that.formState.jcy,
  1692. co2Early2: that.formState.co2,
  1693. coEarly2: that.formState.co,
  1694. gwSdzEarly2: that.formState.gw,
  1695. jwSdzEarly2: that.formState.ch4,
  1696. o2Early2: that.formState.o2,
  1697. strInstallPos: that.formState.jcdd,
  1698. timeEarly2: that.formState.time,
  1699. tearly2: that.formState.temp,
  1700. bxySdzNoon1: that.saveShowList.bxySdzNoon1,
  1701. ch4Noon1: that.saveShowList.ch4Noon1,
  1702. checkPersonNoon: that.formState.jcy,
  1703. co2Noon1: that.saveShowList.co2Noon1,
  1704. coNoon1: that.saveShowList.coNoon1,
  1705. gwSdzNoon1: that.saveShowList.gwSdzNoon1,
  1706. jwSdzNoon1: that.saveShowList.jwSdzNoon1,
  1707. o2Noon1: that.saveShowList.o2Noon1,
  1708. strInstallPos: that.saveShowList.strInstallPos,
  1709. timeNoon1: that.saveShowList.timeNoon1,
  1710. tnoon1: that.saveShowList.tnoon1,
  1711. bxySdzNoon2: that.saveShowList.bxySdzNoon2,
  1712. ch4Noon2: that.saveShowList.ch4Noon2,
  1713. co2Noon2: that.saveShowList.co2Noon2,
  1714. coNoon2: that.saveShowList.coNoon2,
  1715. gwSdzNoon2: that.saveShowList.gwSdzNoon2,
  1716. jwSdzNoon2: that.saveShowList.jwSdzNoon2,
  1717. o2Noon2: that.saveShowList.o2Noon2,
  1718. timeNoon2: that.saveShowList.timeNoon2,
  1719. tnoon2: that.saveShowList.tnoon2,
  1720. bxySdzNight1: that.saveShowList.bxySdzNight1,
  1721. ch4Night1: that.saveShowList.ch4Night1,
  1722. checkPersonNight: that.formState.jcy,
  1723. co2Night1: that.saveShowList.co2Night1,
  1724. coNight1: that.saveShowList.coNight1,
  1725. gwSdzNight1: that.saveShowList.gwSdzNight1,
  1726. jwSdzNight1: that.saveShowList.jwSdzNight1,
  1727. o2Night1: that.saveShowList.o2Night1,
  1728. strInstallPos: that.saveShowList.strInstallPos,
  1729. timeNight1: that.saveShowList.timeNight1,
  1730. tnight1: that.saveShowList.tnight1,
  1731. bxySdzNight2: that.saveShowList.bxySdzNight2,
  1732. ch4Night2: that.saveShowList.ch4Night2,
  1733. co2Night2: that.saveShowList.co2Night2,
  1734. coNight2: that.saveShowList.coNight2,
  1735. gwSdzNight2: that.saveShowList.gwSdzNight2,
  1736. jwSdzNight2: that.saveShowList.jwSdzNight2,
  1737. o2Night2: that.saveShowList.o2Night2,
  1738. timeNight2: that.saveShowList.timeNight2,
  1739. tnight2: that.saveShowList.tnight2,
  1740. }
  1741. } else if (that.formState.bc == '中班' && that.formState.count == '第一次') {
  1742. param = {
  1743. id: that.saveShowList.id,
  1744. bxySdzEarly1: that.saveShowList.bxySdzEarly1,
  1745. ch4Early1: that.saveShowList.ch4Early1,
  1746. co2Early1: that.saveShowList.co2Early1,
  1747. coEarly1: that.saveShowList.coEarly1,
  1748. gwSdzEarly1: that.saveShowList.gwSdzEarly1,
  1749. jwSdzEarly1: that.saveShowList.jwSdzEarly1,
  1750. o2Early1: that.saveShowList.o2Early1,
  1751. timeEarly1: that.saveShowList.timeEarly1,
  1752. checkPersonEarly: that.formState.jcy,
  1753. strInstallPos: that.saveShowList.strInstallPos,
  1754. tearly1: that.saveShowList.tearly1,
  1755. bxySdzEarly2: that.saveShowList.bxySdzEarly2,
  1756. ch4Early2: that.saveShowList.ch4Early2,
  1757. co2Early2: that.saveShowList.co2Early2,
  1758. coEarly2: that.saveShowList.coEarly2,
  1759. gwSdzEarly2: that.saveShowList.gwSdzEarly2,
  1760. jwSdzEarly2: that.saveShowList.jwSdzEarly2,
  1761. o2Early2: that.saveShowList.o2Early2,
  1762. timeEarly2: that.saveShowList.timeEarly2,
  1763. tearly2: that.saveShowList.tearly2,
  1764. bxySdzNoon1: that.formState.bxy,
  1765. ch4Noon1: that.formState.ch4,
  1766. checkPersonNoon: that.formState.jcy,
  1767. co2Noon1: that.formState.co2,
  1768. coNoon1: that.formState.co,
  1769. gwSdzNoon1: that.formState.gw,
  1770. jwSdzNoon1: that.formState.ch4,
  1771. o2Noon1: that.formState.o2,
  1772. strInstallPos: that.formState.jcdd,
  1773. timeNoon1: that.formState.time,
  1774. tnoon1: that.formState.temp,
  1775. bxySdzNoon2: that.saveShowList.bxySdzNoon2,
  1776. ch4Noon2: that.saveShowList.ch4Noon2,
  1777. co2Noon2: that.saveShowList.co2Noon2,
  1778. coNoon2: that.saveShowList.coNoon2,
  1779. gwSdzNoon2: that.saveShowList.gwSdzNoon2,
  1780. jwSdzNoon2: that.saveShowList.jwSdzNoon2,
  1781. o2Noon2: that.saveShowList.o2Noon2,
  1782. timeNoon2: that.saveShowList.timeNoon2,
  1783. tnoon2: that.saveShowList.tnoon2,
  1784. bxySdzNight1: that.saveShowList.bxySdzNight1,
  1785. ch4Night1: that.saveShowList.ch4Night1,
  1786. checkPersonNight: that.formState.jcy,
  1787. co2Night1: that.saveShowList.co2Night1,
  1788. coNight1: that.saveShowList.coNight1,
  1789. gwSdzNight1: that.saveShowList.gwSdzNight1,
  1790. jwSdzNight1: that.saveShowList.jwSdzNight1,
  1791. o2Night1: that.saveShowList.o2Night1,
  1792. strInstallPos: that.saveShowList.strInstallPos,
  1793. timeNight1: that.saveShowList.timeNight1,
  1794. tnight1: that.saveShowList.tnight1,
  1795. bxySdzNight2: that.saveShowList.bxySdzNight2,
  1796. ch4Night2: that.saveShowList.ch4Night2,
  1797. co2Night2: that.saveShowList.co2Night2,
  1798. coNight2: that.saveShowList.coNight2,
  1799. gwSdzNight2: that.saveShowList.gwSdzNight2,
  1800. jwSdzNight2: that.saveShowList.jwSdzNight2,
  1801. o2Night2: that.saveShowList.o2Night2,
  1802. timeNight2: that.saveShowList.timeNight2,
  1803. tnight2: that.saveShowList.tnight2,
  1804. }
  1805. } else if (that.formState.bc == '中班' && that.formState.count == '第二次') {
  1806. param = {
  1807. id: that.saveShowList.id,
  1808. bxySdzEarly1: that.saveShowList.bxySdzEarly1,
  1809. ch4Early1: that.saveShowList.ch4Early1,
  1810. co2Early1: that.saveShowList.co2Early1,
  1811. coEarly1: that.saveShowList.coEarly1,
  1812. gwSdzEarly1: that.saveShowList.gwSdzEarly1,
  1813. jwSdzEarly1: that.saveShowList.jwSdzEarly1,
  1814. o2Early1: that.saveShowList.o2Early1,
  1815. timeEarly1: that.saveShowList.timeEarly1,
  1816. checkPersonEarly: that.formState.jcy,
  1817. strInstallPos: that.saveShowList.strInstallPos,
  1818. tearly1: that.saveShowList.tearly1,
  1819. bxySdzEarly2: that.saveShowList.bxySdzEarly2,
  1820. ch4Early2: that.saveShowList.ch4Early2,
  1821. co2Early2: that.saveShowList.co2Early2,
  1822. coEarly2: that.saveShowList.coEarly2,
  1823. gwSdzEarly2: that.saveShowList.gwSdzEarly2,
  1824. jwSdzEarly2: that.saveShowList.jwSdzEarly2,
  1825. o2Early2: that.saveShowList.o2Early2,
  1826. timeEarly2: that.saveShowList.timeEarly2,
  1827. tearly2: that.saveShowList.tearly2,
  1828. bxySdzNoon1: that.saveShowList.bxySdzNoon1,
  1829. ch4Noon1: that.saveShowList.ch4Noon1,
  1830. co2Noon1: that.saveShowList.co2Noon1,
  1831. coNoon1: that.saveShowList.coNoon1,
  1832. gwSdzNoon1: that.saveShowList.gwSdzNoon1,
  1833. jwSdzNoon1: that.saveShowList.jwSdzNoon1,
  1834. o2Noon1: that.saveShowList.o2Noon1,
  1835. timeNoon1: that.saveShowList.timeNoon1,
  1836. tnoon1: that.saveShowList.tnoon1,
  1837. bxySdzNoon2: that.formState.bxy,
  1838. ch4Noon2: that.formState.ch4,
  1839. checkPersonNoon: that.formState.jcy,
  1840. co2Noon2: that.formState.co2,
  1841. coNoon2: that.formState.co,
  1842. gwSdzNoon2: that.formState.gw,
  1843. jwSdzNoon2: that.formState.ch4,
  1844. o2Noon2: that.formState.o2,
  1845. strInstallPos: that.formState.jcdd,
  1846. timeNoon2: that.formState.time,
  1847. tnoon2: that.formState.temp,
  1848. bxySdzNight1: that.saveShowList.bxySdzNight1,
  1849. ch4Night1: that.saveShowList.ch4Night1,
  1850. checkPersonNight: that.formState.jcy,
  1851. co2Night1: that.saveShowList.co2Night1,
  1852. coNight1: that.saveShowList.coNight1,
  1853. gwSdzNight1: that.saveShowList.gwSdzNight1,
  1854. jwSdzNight1: that.saveShowList.jwSdzNight1,
  1855. o2Night1: that.saveShowList.o2Night1,
  1856. strInstallPos: that.saveShowList.strInstallPos,
  1857. timeNight1: that.saveShowList.timeNight1,
  1858. tnight1: that.saveShowList.tnight1,
  1859. bxySdzNight2: that.saveShowList.bxySdzNight2,
  1860. ch4Night2: that.saveShowList.ch4Night2,
  1861. co2Night2: that.saveShowList.co2Night2,
  1862. coNight2: that.saveShowList.coNight2,
  1863. gwSdzNight2: that.saveShowList.gwSdzNight2,
  1864. jwSdzNight2: that.saveShowList.jwSdzNight2,
  1865. o2Night2: that.saveShowList.o2Night2,
  1866. timeNight2: that.saveShowList.timeNight2,
  1867. tnight2: that.saveShowList.tnight2,
  1868. }
  1869. } else if (that.formState.bc == '夜班' && that.formState.count == '第一次') {
  1870. param = {
  1871. id: that.saveShowList.id,
  1872. bxySdzEarly1: that.saveShowList.bxySdzEarly1,
  1873. ch4Early1: that.saveShowList.ch4Early1,
  1874. co2Early1: that.saveShowList.co2Early1,
  1875. coEarly1: that.saveShowList.coEarly1,
  1876. gwSdzEarly1: that.saveShowList.gwSdzEarly1,
  1877. jwSdzEarly1: that.saveShowList.jwSdzEarly1,
  1878. o2Early1: that.saveShowList.o2Early1,
  1879. timeEarly1: that.saveShowList.timeEarly1,
  1880. checkPersonEarly: that.formState.jcy,
  1881. strInstallPos: that.saveShowList.strInstallPos,
  1882. tearly1: that.saveShowList.tearly1,
  1883. bxySdzEarly2: that.saveShowList.bxySdzEarly2,
  1884. ch4Early2: that.saveShowList.ch4Early2,
  1885. co2Early2: that.saveShowList.co2Early2,
  1886. coEarly2: that.saveShowList.coEarly2,
  1887. gwSdzEarly2: that.saveShowList.gwSdzEarly2,
  1888. jwSdzEarly2: that.saveShowList.jwSdzEarly2,
  1889. o2Early2: that.saveShowList.o2Early2,
  1890. timeEarly2: that.saveShowList.timeEarly2,
  1891. tearly2: that.saveShowList.tearly2,
  1892. bxySdzNoon1: that.saveShowList.bxySdzNoon1,
  1893. ch4Noon1: that.saveShowList.ch4Noon1,
  1894. co2Noon1: that.saveShowList.co2Noon1,
  1895. coNoon1: that.saveShowList.coNoon1,
  1896. gwSdzNoon1: that.saveShowList.gwSdzNoon1,
  1897. jwSdzNoon1: that.saveShowList.jwSdzNoon1,
  1898. o2Noon1: that.saveShowList.o2Noon1,
  1899. timeNoon1: that.saveShowList.timeNoon1,
  1900. tnoon1: that.saveShowList.tnoon1,
  1901. bxySdzNoon2: that.saveShowList.bxySdzNoon2,
  1902. ch4Noon2: that.saveShowList.ch4Noon2,
  1903. checkPersonNoon: that.formState.jcy,
  1904. co2Noon2: that.saveShowList.co2Noon2,
  1905. coNoon2: that.saveShowList.coNoon2,
  1906. gwSdzNoon2: that.saveShowList.gwSdzNoon2,
  1907. jwSdzNoon2: that.saveShowList.jwSdzNoon2,
  1908. o2Noon2: that.saveShowList.o2Noon2,
  1909. strInstallPos: that.saveShowList.strInstallPos,
  1910. timeNoon2: that.saveShowList.timeNoon2,
  1911. tnoon2: that.saveShowList.tnoon2,
  1912. bxySdzNight1: that.formState.bxy,
  1913. ch4Night1: that.formState.ch4,
  1914. checkPersonNight: that.formState.jcy,
  1915. co2Night1: that.formState.co2,
  1916. coNight1: that.formState.co,
  1917. gwSdzNight1: that.formState.gw,
  1918. jwSdzNight1: that.formState.ch4,
  1919. o2Night1: that.formState.o2,
  1920. strInstallPos: that.formState.jcdd,
  1921. timeNight1: that.formState.time,
  1922. tnight1: that.formState.temp,
  1923. bxySdzNight2: that.saveShowList.bxySdzNight2,
  1924. ch4Night2: that.saveShowList.ch4Night2,
  1925. co2Night2: that.saveShowList.co2Night2,
  1926. coNight2: that.saveShowList.coNight2,
  1927. gwSdzNight2: that.saveShowList.gwSdzNight2,
  1928. jwSdzNight2: that.saveShowList.jwSdzNight2,
  1929. o2Night2: that.saveShowList.o2Night2,
  1930. timeNight2: that.saveShowList.timeNight2,
  1931. tnight2: that.saveShowList.tnight2,
  1932. }
  1933. } else if (that.formState.bc == '夜班' && that.formState.count == '第二次') {
  1934. param = {
  1935. id: that.saveShowList.id,
  1936. bxySdzEarly1: that.saveShowList.bxySdzEarly1,
  1937. ch4Early1: that.saveShowList.ch4Early1,
  1938. co2Early1: that.saveShowList.co2Early1,
  1939. coEarly1: that.saveShowList.coEarly1,
  1940. gwSdzEarly1: that.saveShowList.gwSdzEarly1,
  1941. jwSdzEarly1: that.saveShowList.jwSdzEarly1,
  1942. o2Early1: that.saveShowList.o2Early1,
  1943. timeEarly1: that.saveShowList.timeEarly1,
  1944. checkPersonEarly: that.formState.jcy,
  1945. strInstallPos: that.saveShowList.strInstallPos,
  1946. tearly1: that.saveShowList.tearly1,
  1947. bxySdzEarly2: that.saveShowList.bxySdzEarly2,
  1948. ch4Early2: that.saveShowList.ch4Early2,
  1949. co2Early2: that.saveShowList.co2Early2,
  1950. coEarly2: that.saveShowList.coEarly2,
  1951. gwSdzEarly2: that.saveShowList.gwSdzEarly2,
  1952. jwSdzEarly2: that.saveShowList.jwSdzEarly2,
  1953. o2Early2: that.saveShowList.o2Early2,
  1954. timeEarly2: that.saveShowList.timeEarly2,
  1955. tearly2: that.saveShowList.tearly2,
  1956. bxySdzNoon1: that.saveShowList.bxySdzNoon1,
  1957. ch4Noon1: that.saveShowList.ch4Noon1,
  1958. co2Noon1: that.saveShowList.co2Noon1,
  1959. coNoon1: that.saveShowList.coNoon1,
  1960. gwSdzNoon1: that.saveShowList.gwSdzNoon1,
  1961. jwSdzNoon1: that.saveShowList.jwSdzNoon1,
  1962. o2Noon1: that.saveShowList.o2Noon1,
  1963. timeNoon1: that.saveShowList.timeNoon1,
  1964. tnoon1: that.saveShowList.tnoon1,
  1965. bxySdzNoon2: that.saveShowList.bxySdzNoon2,
  1966. ch4Noon2: that.saveShowList.ch4Noon2,
  1967. checkPersonNoon: that.formState.jcy,
  1968. co2Noon2: that.saveShowList.co2Noon2,
  1969. coNoon2: that.saveShowList.coNoon2,
  1970. gwSdzNoon2: that.saveShowList.gwSdzNoon2,
  1971. jwSdzNoon2: that.saveShowList.jwSdzNoon2,
  1972. o2Noon2: that.saveShowList.o2Noon2,
  1973. strInstallPos: that.saveShowList.strInstallPos,
  1974. timeNoon2: that.saveShowList.timeNoon2,
  1975. tnoon2: that.saveShowList.tnoon2,
  1976. bxySdzNight1: that.saveShowList.bxySdzNight1,
  1977. ch4Night1: that.saveShowList.ch4Night1,
  1978. co2Night1: that.saveShowList.co2Night1,
  1979. coNight1: that.saveShowList.coNight1,
  1980. gwSdzNight1: that.saveShowList.gwSdzNight1,
  1981. jwSdzNight1: that.saveShowList.jwSdzNight1,
  1982. o2Night1: that.saveShowList.o2Night1,
  1983. timeNight1: that.saveShowList.timeNight1,
  1984. tnight1: that.saveShowList.tnight1,
  1985. bxySdzNight2: that.formState.bxy,
  1986. ch4Night2: that.formState.ch4,
  1987. checkPersonNight: that.formState.jcy,
  1988. co2Night2: that.formState.co2,
  1989. coNight2: that.formState.co,
  1990. gwSdzNight2: that.formState.gw,
  1991. jwSdzNight2: that.formState.ch4,
  1992. o2Night2: that.formState.o2,
  1993. strInstallPos: that.formState.jcdd,
  1994. timeNight2: that.formState.time,
  1995. tnight2: that.formState.temp,
  1996. }
  1997. }
  1998. new Promise((resolve, reject) => {
  1999. api
  2000. .getEdit({ ...param })
  2001. .then((response) => {
  2002. if (response.data.code == 200) {
  2003. that.getGasList()
  2004. that.isShowAdd = false
  2005. that.isDisabled = false
  2006. that.saveShowList = {}
  2007. that.clearData()
  2008. } else {
  2009. reject(response);
  2010. }
  2011. })
  2012. .catch((error) => {
  2013. console.log("catch===>response", response);
  2014. reject(error);
  2015. });
  2016. });
  2017. },
  2018. //新增保存
  2019. getConfirm() {
  2020. let that = this
  2021. console.log(that.saveShowList, '999999999999999999999999999999999')
  2022. that.isStatus = JSON.stringify(that.saveShowList) != '{}' ? 'edit' : 'add'
  2023. if (that.isStatus == 'add') {
  2024. that.getAddSave()
  2025. } else {
  2026. that.getEditSave()
  2027. }
  2028. },
  2029. clearData() {
  2030. this.formState = {
  2031. id: '',
  2032. bc: '',
  2033. count: '',
  2034. jcdd: '',
  2035. mcgzm: '',
  2036. jcy: this.username,
  2037. time: moment(new Date()).format('YYYY-MM-DD HH:mm:ss'),
  2038. ch4: '',
  2039. co2: '',
  2040. co: '',
  2041. o2: '',
  2042. jw: '',
  2043. gw: '',
  2044. bxy: '',
  2045. tbrq: moment(new Date()).format('YYYY-MM-DD'),
  2046. temp: '',
  2047. }
  2048. this.isRule = true
  2049. this.isRule2 = true
  2050. this.isRule1 = true
  2051. this.isRule3 = true
  2052. this.isRule14 = true
  2053. },
  2054. //新增取消
  2055. getCancel() {
  2056. this.isShowAdd = false
  2057. this.isDisabled = false
  2058. this.saveShowList = {}
  2059. this.clearData()
  2060. },
  2061. //获取瓦斯上报列表数据
  2062. getGasList() {
  2063. let that = this
  2064. new Promise((resolve, reject) => {
  2065. api
  2066. .getGas({ reportTime: that.tbTime, })
  2067. .then((response) => {
  2068. if (response.data.code == 200) {
  2069. let data = response.data.result.records
  2070. that.gasList = data
  2071. } else {
  2072. reject(response);
  2073. }
  2074. })
  2075. .catch((error) => {
  2076. console.log("catch===>response", response);
  2077. reject(error);
  2078. });
  2079. });
  2080. },
  2081. //获取煤层工作面列表数据
  2082. getMcList() {
  2083. new Promise((resolve, reject) => {
  2084. api
  2085. .getDictItems({ dictCode: 'coalseam' })
  2086. .then((response) => {
  2087. let data = response.data
  2088. this.rangeMcgzm = data.map(el => {
  2089. return {
  2090. text: el.label,
  2091. value: el.value,
  2092. }
  2093. })
  2094. })
  2095. .catch((error) => {
  2096. console.log("catch===>response", response);
  2097. reject(error);
  2098. });
  2099. });
  2100. },
  2101. //获取安装位置下拉选项
  2102. getSelectList() {
  2103. let param = this.rangeMcgzm.filter(v => this.formState.mcgzm == v.value)[0].value
  2104. new Promise((resolve, reject) => {
  2105. api
  2106. .getSelect({ coalseam: param, devicekind: 'gasDayReport' })
  2107. .then((response) => {
  2108. if (response.data.code == 200) {
  2109. let data = response.data.result
  2110. this.rangeJcdd = data.map(v => {
  2111. return {
  2112. text: v.strinstallpos,
  2113. value: v.strinstallpos,
  2114. deviceId: v.id,
  2115. }
  2116. })
  2117. } else {
  2118. reject(response);
  2119. }
  2120. })
  2121. .catch((error) => {
  2122. console.log("catch===>response", response);
  2123. reject(error);
  2124. });
  2125. });
  2126. },
  2127. },
  2128. };
  2129. </script>
  2130. <style lang="scss" scoped>
  2131. .gas-fill {
  2132. position: relative;
  2133. width: 100%;
  2134. height: 100%;
  2135. .top-title {
  2136. height: 28px;
  2137. margin-bottom: 5px;
  2138. display: flex;
  2139. justify-content: space-between;
  2140. align-items: center;
  2141. }
  2142. .top-content {
  2143. .content-title {
  2144. height: 26px;
  2145. line-height: 26px;
  2146. padding: 0px 20px;
  2147. font-size: 12px;
  2148. background: url('/static/warndata/title.png') no-repeat;
  2149. background-size: 100% 100%;
  2150. }
  2151. .content-item-box {
  2152. padding: 10px 0px;
  2153. .content-item {
  2154. height: 50px;
  2155. display: flex;
  2156. justify-content: space-between;
  2157. align-items: center;
  2158. background: linear-gradient(to right, rgba(55, 135, 254, 0.08), rgba(4, 184, 255, 0.08), rgba(60, 161, 237, 0.08));
  2159. border-radius: 10px;
  2160. margin-bottom: 5px;
  2161. .item-l {
  2162. width: calc(50% - 2px);
  2163. height: 100%;
  2164. display: flex;
  2165. flex-direction: column;
  2166. justify-content: center;
  2167. align-items: center;
  2168. }
  2169. .item-c {
  2170. width: 4px;
  2171. height: 70%;
  2172. border-left: 2px solid;
  2173. border-image: linear-gradient(to bottom, transparent, rgba(140, 203, 254, 1), transparent) 1 1 1;
  2174. }
  2175. .item-r {
  2176. width: calc(50% - 2px);
  2177. height: 100%;
  2178. display: flex;
  2179. flex-direction: column;
  2180. justify-content: center;
  2181. align-items: center;
  2182. }
  2183. }
  2184. }
  2185. }
  2186. .item-value {
  2187. height: 20px;
  2188. line-height: 20px;
  2189. color: #0eb4fc;
  2190. font-weight: bold;
  2191. }
  2192. .item-label {
  2193. font-size: 12px;
  2194. }
  2195. .top-dialog-area,
  2196. .center-dialog-area,
  2197. .bottom-dialog-area {
  2198. width: 100%;
  2199. padding: 10px;
  2200. box-sizing: border-box;
  2201. background-color: #FFF;
  2202. margin-bottom: 2px;
  2203. }
  2204. .top-gas-list {
  2205. display: flex;
  2206. flex-direction: column;
  2207. align-items: center;
  2208. width: 100%;
  2209. padding: 10px 20px;
  2210. box-sizing: border-box;
  2211. background-color: #FFF;
  2212. margin-bottom: 2px;
  2213. }
  2214. .bot-gas-list {
  2215. width: 100%;
  2216. height: calc(100% - 94px);
  2217. padding: 10px;
  2218. box-sizing: border-box;
  2219. background-color: #FFF;
  2220. margin-bottom: 2px;
  2221. overflow-y: auto;
  2222. }
  2223. .dialog-btn {
  2224. display: flex;
  2225. width: 100%;
  2226. padding: 8px 10px;
  2227. box-sizing: border-box;
  2228. background-color: #FFF;
  2229. // margin-bottom: 2px;
  2230. .u-button {
  2231. margin: 0px 10px;
  2232. }
  2233. }
  2234. .dialog-title {
  2235. height: 26px;
  2236. line-height: 26px;
  2237. padding: 0px 20px;
  2238. margin-bottom: 10px;
  2239. font-size: 12px;
  2240. background: url('/static/warndata/title.png') no-repeat;
  2241. background-size: 100% 100%;
  2242. }
  2243. .dialog-item {
  2244. display: flex;
  2245. align-items: center;
  2246. justify-content: center;
  2247. margin-bottom: 10px;
  2248. .dialog-label {
  2249. width: 120px;
  2250. text-align: right;
  2251. }
  2252. }
  2253. .search-box {
  2254. display: flex;
  2255. align-items: center;
  2256. justify-content: center;
  2257. margin-bottom: 10px;
  2258. .dialog-label {
  2259. width: 80px;
  2260. text-align: right;
  2261. }
  2262. }
  2263. .content-title-gas {
  2264. position: relative;
  2265. height: 26px;
  2266. line-height: 26px;
  2267. padding-left: 20px;
  2268. font-size: 12px;
  2269. background: url('/static/warndata/title.png') no-repeat;
  2270. background-size: 100% 100%;
  2271. }
  2272. .icon-gas-edit {
  2273. position: absolute;
  2274. right: 35px;
  2275. top: 0;
  2276. cursor: pointer;
  2277. }
  2278. .icon-gas-del {
  2279. position: absolute;
  2280. right: 10px;
  2281. top: 0;
  2282. cursor: pointer;
  2283. }
  2284. }
  2285. ::v-deep .u-input {
  2286. padding: 2px 6px !important;
  2287. }
  2288. ::v-deep .u-popup {
  2289. flex: 0;
  2290. }
  2291. ::v-deep .uni-select {
  2292. height: 30px;
  2293. border: 1px solid #dadbde;
  2294. }
  2295. ::v-deep .uni-select__input-box {
  2296. height: 30px;
  2297. }
  2298. ::v-deep .uni-select__input-placeholder {
  2299. font-size: 14px;
  2300. text-align: center;
  2301. color: rgb(192, 196, 204);
  2302. }
  2303. ::v-deep .u-modal__title {
  2304. font-size: 16px;
  2305. font-weight: bold;
  2306. color: #606266;
  2307. text-align: center;
  2308. padding-top: 10px;
  2309. }
  2310. ::v-deep .u-modal__content {
  2311. padding: 12px 25px 20px 25px;
  2312. }
  2313. ::v-deep .u-modal__button-group__wrapper {
  2314. height: 36px;
  2315. }
  2316. </style>