gasImgIdentify.vue 91 KB

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