gasImgIdentify.vue 111 KB

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