batchProductJobBom.vue 45 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735
  1. <template>
  2. <view>
  3. <view class="title_box rx-bc">
  4. <view class="name"> 报工信息: ({{ list.length || 0 }})个</view>
  5. </view>
  6. <view
  7. :class="[
  8. 'material',
  9. it.extInfo.reportWeight && it.extInfo.reportWeight && 'materialBor',
  10. ]"
  11. v-for="(it, idx) in list"
  12. :key="idx"
  13. >
  14. <view class="content_table">
  15. <view class="item rx-sc">
  16. <view class="rx">
  17. <view class="lable lable190 rx-cc" v-if="isDetails">
  18. <view class="round">{{ idx + 1 }}</view>
  19. <uni-icons
  20. custom-prefix="iconfont"
  21. type="icon-shanchu"
  22. size="16"
  23. color="#fa3534"
  24. ></uni-icons>
  25. 物料编码
  26. </view>
  27. <view class="lable lable190 rx-cc" @click="getDelete2(idx)" v-else>
  28. <view class="round">{{ idx + 1 }}</view>
  29. <uni-icons
  30. custom-prefix="iconfont"
  31. type="icon-shanchu"
  32. size="16"
  33. color="#fa3534"
  34. ></uni-icons>
  35. 物料编码
  36. </view>
  37. <view class="content rx-bc">
  38. <view>{{ it.code }} </view>
  39. <view
  40. class="tag_box"
  41. v-if="
  42. Object.prototype.hasOwnProperty.call(it, 'extInfo') &&
  43. Object.prototype.hasOwnProperty.call(
  44. it.extInfo,
  45. 'productionTimes'
  46. ) &&
  47. Object.prototype.hasOwnProperty.call(
  48. it.extInfo.productionTimes,
  49. item.currentTaskDiagram.taskId
  50. )
  51. "
  52. >
  53. {{ it.extInfo.productionTimes[item.currentTaskDiagram.taskId] }}
  54. </view>
  55. </view>
  56. </view>
  57. </view>
  58. <view class="item rx-sc">
  59. <view class="rx">
  60. <view class="lable lable150 rx-cc">名称</view>
  61. <view class="content rx-bc">
  62. <view
  63. >{{ it.name }}
  64. <text
  65. v-if="[2, 23, 9, 28].includes(Number(it.rootCategoryLevelId))"
  66. >
  67. ({{
  68. it.rootCategoryLevelId == 2
  69. ? "在制品"
  70. : it.rootCategoryLevelId == 23
  71. ? "半成品"
  72. : it.rootCategoryLevelId == 9
  73. ? "产品"
  74. : it.rootCategoryLevelId == 28
  75. ? "废品"
  76. : ""
  77. }})
  78. </text>
  79. </view>
  80. <view class="rx-ec">
  81. <view
  82. class="tag_box"
  83. v-if="it.isCache"
  84. style="margin-right: -36rpx; margin-right: 4rpx"
  85. >缓</view
  86. >
  87. <view
  88. class="tag_box"
  89. v-if="
  90. Object.prototype.hasOwnProperty.call(
  91. it.extInfo,
  92. 'isOutsource'
  93. ) && it.extInfo.isOutsource == 1
  94. "
  95. style="margin-right: -36rpx"
  96. >委外</view
  97. >
  98. </view>
  99. </view>
  100. </view>
  101. </view>
  102. <view class="item rx-sc">
  103. <view class="rx">
  104. <view class="lable lable150 rx-cc">型号</view>
  105. <view class="content rx-sc">
  106. <view>{{ it.modelType }}</view>
  107. </view>
  108. </view>
  109. </view>
  110. <view class="item rx-sc">
  111. <view class="rx">
  112. <view class="lable lable150 rx-cc">规格</view>
  113. <view class="content rx-sc">
  114. <view>{{ it.specification }}</view>
  115. </view>
  116. </view>
  117. </view>
  118. <view class="item rx-sc">
  119. <view class="rx ww50">
  120. <view class="lable lable150 rx-cc">批次号</view>
  121. <view class="content content_num">
  122. <view v-if="isDetails">{{ it.batchNo }}</view>
  123. <input class="uni-input" v-else v-model="it.batchNo" />
  124. </view>
  125. </view>
  126. <view class="rx ww50">
  127. <view class="lable lable150 rx-cc">牌号</view>
  128. <view class="content content_num">
  129. <view>{{ it.brandNum }}</view>
  130. </view>
  131. </view>
  132. </view>
  133. <view class="item rx-sc">
  134. <view class="rx ww50">
  135. <view class="lable lable150 rx-cc">物料代号</view>
  136. <view class="content content_num">
  137. <view v-if="isDetails">{{ it.extInfo.materielCode }}</view>
  138. <input
  139. class="uni-input"
  140. v-else
  141. v-model="it.extInfo.materielCode"
  142. />
  143. </view>
  144. </view>
  145. <view class="rx ww50">
  146. <view class="lable lable150 rx-cc">客户代号</view>
  147. <view class="content content_num">
  148. <view v-if="isDetails">{{ it.extInfo.clientCode }}</view>
  149. <input class="uni-input" v-else v-model="it.extInfo.clientCode" />
  150. </view>
  151. </view>
  152. </view>
  153. <view class="item rx-sc">
  154. <view class="rx ww50">
  155. <view class="lable lable150 rx-cc" v-if="clientEnvironmentId != 5"
  156. >刻码</view
  157. >
  158. <view class="lable lable150 rx-cc" v-if="clientEnvironmentId == 5"
  159. >识别码</view
  160. >
  161. <view class="content content_num">
  162. <view v-if="isDetails">{{ it.extInfo.engrave }}</view>
  163. <input class="uni-input" v-else v-model="it.extInfo.engrave" />
  164. </view>
  165. </view>
  166. <view class="rx ww50">
  167. <view class="lable lable150 rx-cc">序列号</view>
  168. <view class="content content_num">
  169. <view v-if="isDetails">{{ it.extInfo.productSequence }}</view>
  170. </view>
  171. </view>
  172. </view>
  173. <view class="item rx-sc">
  174. <view class="rx ww50">
  175. <view class="lable lable150 rx-cc">设备</view>
  176. <view class="content content_num">
  177. <view v-if="isDetails">{{ it.deviceName }}</view>
  178. <zxz-uni-data-select
  179. :localdata="deviceList"
  180. v-model="it.deviceId"
  181. dataValue="instanceId"
  182. format="{name}"
  183. dataKey="instanceId"
  184. filterable
  185. :clear="false"
  186. v-else
  187. ></zxz-uni-data-select>
  188. </view>
  189. <!-- <view class="content ">
  190. <view>{{ it.deviceName || it.extInfo.deviceName }}</view>
  191. </view> -->
  192. </view>
  193. <view class="rx ww50">
  194. <view class="lable lable150 rx-cc">炉次号</view>
  195. <view class="content content_num">
  196. <view v-if="isDetails">{{ it.extInfo.heatNumber }}</view>
  197. <input class="uni-input" v-else v-model="it.extInfo.heatNumber" />
  198. </view>
  199. </view>
  200. </view>
  201. <view class="item rx-sc">
  202. <view class="rx ww50">
  203. <view class="lable lable150 rx-cc">位置</view>
  204. <view class="content content_num">
  205. <view v-if="isDetails">{{ it.extInfo.position }}</view>
  206. <input class="uni-input" v-else v-model="it.extInfo.position" />
  207. </view>
  208. </view>
  209. <view class="rx ww50">
  210. <view class="lable lable150 rx-cc">数量</view>
  211. <view class="content content_num">
  212. <view v-if="isDetails">{{ it.feedQuantity }}</view>
  213. <input class="uni-input" v-else v-model="it.feedQuantity" />
  214. </view>
  215. </view>
  216. </view>
  217. <view class="item rx-sc">
  218. <view class="rx ww50">
  219. <view class="lable lable150 rx-cc">是否合格</view>
  220. <view class="content content_num">
  221. <zxz-uni-data-select
  222. :localdata="isQualifiedList"
  223. v-model="it.extInfo.isQualified"
  224. dataValue="code"
  225. format="{name}"
  226. dataKey="code"
  227. filterable
  228. :disabled="isDetails"
  229. :clear="false"
  230. ></zxz-uni-data-select>
  231. </view>
  232. </view>
  233. <view
  234. class="rx ww50"
  235. v-if="it.extInfo.isQualified && it.extInfo.isQualified == 2"
  236. >
  237. <view class="lable lable150 rx-cc">处置类型</view>
  238. <view class="content">
  239. <zxz-uni-data-select
  240. :localdata="notTypeList"
  241. v-model="it.extInfo.notType"
  242. dataValue="code"
  243. format="{name}"
  244. dataKey="code"
  245. filterable
  246. :disabled="isDetails"
  247. :clear="false"
  248. ></zxz-uni-data-select>
  249. </view>
  250. </view>
  251. </view>
  252. <view class="item rx-sc">
  253. <view class="rx ww50">
  254. <view class="lable lable150 rx-cc">原因/处置</view>
  255. <view
  256. class="content"
  257. v-if="
  258. it.extInfo.isQualified != 1 &&
  259. it.extInfo.notType != 5 &&
  260. it.extInfo.notType != 8 &&
  261. it.extInfo.notType
  262. "
  263. >
  264. <view v-if="isDetails">{{ it.extInfo.notReason }}</view>
  265. <input
  266. class="uni-input content_num"
  267. v-else
  268. v-model="it.extInfo.notReason"
  269. />
  270. </view>
  271. <view
  272. v-if="![1, 2, 3, 4, 6, 9, 7].includes(Number(it.extInfo.notType))"
  273. class="content"
  274. >
  275. <span v-if="isDetails">{{ it.extInfo.taskName }}</span>
  276. <zxz-uni-data-select
  277. :localdata="stepsList"
  278. v-model="it.extInfo.taskId"
  279. dataValue="taskId"
  280. format="{taskTypeName}"
  281. dataKey="taskId"
  282. filterable
  283. :disabled="isDetails"
  284. :clear="false"
  285. >
  286. </zxz-uni-data-select>
  287. </view>
  288. </view>
  289. <view class="rx ww50">
  290. <view class="lable lable150 rx-cc">报工重量</view>
  291. <view class="content content_num">
  292. <view v-if="isDetails">{{ it.extInfo.reportWeight }}</view>
  293. <input
  294. class="uni-input"
  295. v-else
  296. v-model="it.extInfo.reportWeight"
  297. @input="handleInput"
  298. />
  299. </view>
  300. </view>
  301. </view>
  302. <view class="item rx-sc">
  303. <view class="rx ww50">
  304. <view class="lable lable150 rx-cc">损耗</view>
  305. <view class="content content_num">
  306. <view v-if="it.extInfo.isLoss && it.extInfo.isLoss == 1">是</view>
  307. <view v-else>否</view>
  308. </view>
  309. </view>
  310. </view>
  311. <view class="item rx-sc" v-if="!isDetails">
  312. <view class="rx">
  313. <view class="lable lable150 rx-cc">操作</view>
  314. <view class="content rx-bc">
  315. <view style="display: flex">
  316. <u-button
  317. size="small"
  318. class="u-reset-button"
  319. type="primary"
  320. @click="batchClick(it, idx)"
  321. v-if="it.extInfo.sourceQuantity > 1"
  322. >拆批</u-button
  323. >
  324. <u-button
  325. size="small"
  326. class="u-reset-button"
  327. type="error"
  328. @click="deleteBatch(idx)"
  329. style="margin-left: 20px"
  330. >删除</u-button
  331. >
  332. <u-button
  333. size="small"
  334. class="u-reset-button"
  335. type="warning"
  336. style="margin-left: 20px"
  337. @click="openLoss(it, idx)"
  338. v-if="
  339. !it.extInfo.isLoss &&
  340. item.currentTaskDiagram.isFirstTask != 1
  341. "
  342. >损耗</u-button
  343. >
  344. </view>
  345. </view>
  346. </view>
  347. </view>
  348. </view>
  349. <view
  350. class="content_table2"
  351. v-if="
  352. ![1, 2, 3, 4].includes(Number(it.extInfo.notType)) &&
  353. clientEnvironmentId == 3
  354. "
  355. >
  356. <view class="head row rx-sc">
  357. <view class="item ww25" style="font-size: 20rpx"
  358. >{{ it.extInfo.newWeight ? "上道工序重量" : "物料重量" }}
  359. {{ it.extInfo.weightUnit }}
  360. </view>
  361. <view class="item ww25">报工重量{{ it.extInfo.weightUnit }}</view>
  362. <view class="item ww25" v-if="isFirstTask == 1">质检结果 </view>
  363. <view class="item ww25" :class="[isFirstTask == 1 ? 'ww25' : 'ww50']"
  364. >处置
  365. </view>
  366. </view>
  367. <view class="table">
  368. <view class="tr row rx-sc">
  369. <view
  370. class="item ww25"
  371. v-if="
  372. Object.prototype.hasOwnProperty.call(it.extInfo, 'newWeight') &&
  373. it.extInfo.newWeight
  374. "
  375. >
  376. {{ it.extInfo.newWeight }}
  377. </view>
  378. <view
  379. class="item ww25 content_num"
  380. v-if="
  381. !Object.prototype.hasOwnProperty.call(
  382. it.extInfo,
  383. 'newWeight'
  384. ) ||
  385. it.extInfo.newWeight == null ||
  386. it.extInfo.newWeight == 0
  387. "
  388. >
  389. <input
  390. class="uni-input"
  391. v-model="it.extInfo.weight"
  392. type="digit"
  393. />
  394. </view>
  395. <view class="item ww25 content_num">
  396. <view v-if="isDetails">{{ it.extInfo.reportWeight }}</view>
  397. <input
  398. class="uni-input"
  399. v-else
  400. v-model="it.extInfo.reportWeight"
  401. type="digit"
  402. @input="handleInput"
  403. />
  404. </view>
  405. <view
  406. class="item ww25"
  407. @click="openNumerate(it, idx)"
  408. v-if="isFirstTask == 1"
  409. >
  410. <view class="numerate">点击计算</view>
  411. </view>
  412. <view
  413. class="item"
  414. v-if="isDetails"
  415. :class="[isFirstTask == 1 ? 'ww25' : 'ww50']"
  416. >
  417. {{ it.extInfo.taskName }}
  418. </view>
  419. <view
  420. class="item"
  421. v-else
  422. :class="[isFirstTask == 1 ? 'ww25' : 'ww50']"
  423. >
  424. <zxz-uni-data-select
  425. :localdata="stepsList"
  426. v-model="it.extInfo.taskId"
  427. dataValue="taskId"
  428. format="{taskTypeName}"
  429. dataKey="taskId"
  430. filterable
  431. @change="(e) => (it.extInfo.taskName = e.taskTypeName)"
  432. :clear="false"
  433. ></zxz-uni-data-select>
  434. </view>
  435. </view>
  436. </view>
  437. </view>
  438. </view>
  439. <u-popup
  440. :show="show"
  441. mode="center"
  442. v-if="show"
  443. :closeOnClickOverlay="false"
  444. >
  445. <view class="popup_box">
  446. <view class="title_box rx-bc">
  447. <view class="name">工序计算列表</view>
  448. <view class="btn_box rx-ec">
  449. <view class="btn" @click="handAddParam">新增</view>
  450. </view>
  451. </view>
  452. <view class="content_table2">
  453. <view class="head row rx-sc">
  454. <view class="item ww30">工序名称</view>
  455. <view class="item ww20">坯体密度</view>
  456. <view class="item ww20">密度系数</view>
  457. <view class="item ww20">重量</view>
  458. <view class="item ww10">操作</view>
  459. </view>
  460. <view class="table">
  461. <view
  462. class="tr row rx-sc"
  463. v-for="(it, idx) in paramList"
  464. :key="idx"
  465. >
  466. <view class="item rx-bc ww30">
  467. <zxz-uni-data-select
  468. :localdata="stepsList"
  469. v-model="it.taskId"
  470. dataValue="taskId"
  471. format="{taskTypeName}"
  472. dataKey="taskId"
  473. filterable
  474. @change="(e) => (it.taskName = e.taskTypeName)"
  475. :clear="false"
  476. ></zxz-uni-data-select>
  477. </view>
  478. <view class="item ww20 content_num">
  479. <input
  480. class="uni-input"
  481. v-model="it.billet"
  482. type="digit"
  483. @input="changeInp(it, idx)"
  484. />
  485. </view>
  486. <view class="item ww20 content_num">
  487. <input
  488. class="uni-input"
  489. v-model="it.density"
  490. type="digit"
  491. @input="changeInp(it, idx)"
  492. />
  493. </view>
  494. <view
  495. class="item ww20"
  496. v-if="idx == 0 || idx != paramList.length - 1"
  497. >
  498. < {{ it.CVIWeight }}
  499. </view>
  500. <view
  501. class="item ww20"
  502. v-if="paramList.length > 1 && idx == paramList.length - 1"
  503. >
  504. ≥ {{ it.CVIWeight }}
  505. </view>
  506. <view class="item ww10 rx-cc" @click="getDelete(idx)">
  507. <uni-icons
  508. custom-prefix="iconfont"
  509. type="icon-shanchu"
  510. size="20"
  511. color="#fa3534"
  512. ></uni-icons>
  513. </view>
  514. </view>
  515. </view>
  516. <view class="formula_box"
  517. >计算公式: 物料重量/坯体密度*密度系数
  518. </view>
  519. <view class="rx-cc">
  520. <u-button
  521. size="small"
  522. class="u-reset-button"
  523. style="width: 300rpx; margin: 20rpx"
  524. type="success"
  525. @click="paramSave"
  526. >工序列表保存</u-button
  527. >
  528. </view>
  529. <view class="reportWeight rx-sc">
  530. 物料重量: {{ weight }} ; 报工重量: {{ reportWeight }}
  531. </view>
  532. </view>
  533. <view class="operate_box rx-sc">
  534. <u-button size="small" class="u-reset-button" @click="cancel"
  535. >取消</u-button
  536. >
  537. <u-button
  538. size="small"
  539. class="u-reset-button"
  540. type="success"
  541. @click="save"
  542. >确定</u-button
  543. >
  544. </view>
  545. </view>
  546. </u-popup>
  547. <uni-popup ref="inputDialog" type="center" :animation="false">
  548. <view class="popup-content">
  549. <view style="font-size: 18px; margin-bottom: 10px">拆批</view>
  550. <uni-forms
  551. ref="baseForm"
  552. :modelValue="batchForm"
  553. label-position="left"
  554. label-align="center"
  555. >
  556. <uni-forms-item label="批次号:" label-width="100" prop="batchNo">
  557. <uni-easyinput
  558. v-model="batchForm.batchNo"
  559. placeholder="请输入批次号"
  560. />
  561. </uni-forms-item>
  562. <uni-forms-item label="拆批数:" label-width="100" prop="quantity">
  563. <uni-easyinput
  564. v-model="batchForm.quantity"
  565. placeholder="请输入拆批数"
  566. />
  567. </uni-forms-item>
  568. <uni-forms-item
  569. label="是否合格:"
  570. label-width="100"
  571. prop="isQualified"
  572. >
  573. <zxz-uni-data-select
  574. :localdata="isQualifiedList"
  575. v-model="batchForm.isQualified"
  576. dataValue="code"
  577. format="{name}"
  578. dataKey="code"
  579. filterable
  580. :clear="false"
  581. @change="isChange"
  582. ></zxz-uni-data-select>
  583. </uni-forms-item>
  584. <uni-forms-item
  585. label="不合格类型:"
  586. label-width="100"
  587. prop="notType"
  588. v-if="batchForm.isQualified == 2"
  589. >
  590. <zxz-uni-data-select
  591. :localdata="notTypeList"
  592. v-model="batchForm.notType"
  593. dataValue="code"
  594. format="{name}"
  595. dataKey="code"
  596. filterable
  597. :clear="false"
  598. ></zxz-uni-data-select>
  599. </uni-forms-item>
  600. <uni-forms-item
  601. label="不良原因:"
  602. v-if="
  603. batchForm.isQualified != 1 &&
  604. batchForm.notType &&
  605. batchForm.notType != 5 &&
  606. batchForm.notType != 8
  607. "
  608. prop="notReason"
  609. >
  610. <uni-easyinput
  611. v-model="batchForm.notReason"
  612. placeholder="请输入不良原因"
  613. />
  614. </uni-forms-item>
  615. </uni-forms>
  616. <view class="button-group">
  617. <button type="primary" size="mini" @click="handleClose">取消</button>
  618. <button type="primary" size="mini" @click="timeoutCauseConfirm">
  619. 确定
  620. </button>
  621. </view>
  622. </view>
  623. </uni-popup>
  624. <uni-popup ref="lossDialog" type="center" :animation="false">
  625. <view class="popup-content">
  626. <view style="font-size: 18px; margin-bottom: 10px">损耗数</view>
  627. <uni-forms
  628. ref="lossForm"
  629. :modelValue="lossForm"
  630. label-position="left"
  631. label-align="center"
  632. >
  633. <uni-forms-item label="批次号:" label-width="100" prop="batchNo">
  634. <uni-easyinput
  635. v-model="lossForm.batchNo"
  636. placeholder="请输入批次号"
  637. />
  638. </uni-forms-item>
  639. <uni-forms-item label="损耗数:" label-width="100" prop="quantity">
  640. <uni-easyinput
  641. v-model="lossForm.quantity"
  642. placeholder="请输入损耗数"
  643. />
  644. </uni-forms-item>
  645. </uni-forms>
  646. <view class="button-group">
  647. <button type="primary" size="mini" @click="handleClose">取消</button>
  648. <button type="primary" size="mini" @click="getLossParam">确定</button>
  649. </view>
  650. </view>
  651. </uni-popup>
  652. </view>
  653. </template>
  654. <script>
  655. import { getTaskInstanceList } from "@/api/pda/workOrder.js";
  656. import { saveParam, getComputeParam } from "@/api/pda/tangu.js";
  657. import { splitBatch } from "@/api/pda/feeding";
  658. import SearchPopup from "./searchPopup.vue";
  659. export default {
  660. props: {
  661. item: {
  662. type: Object,
  663. default: () => {},
  664. },
  665. list: {
  666. type: Array,
  667. default: () => [],
  668. },
  669. isDetails: {
  670. type: Boolean,
  671. default: false,
  672. },
  673. equipmentList: {
  674. type: Array,
  675. default: () => [],
  676. },
  677. },
  678. components: {
  679. SearchPopup,
  680. },
  681. watch: {
  682. equipmentList: {
  683. immediate: true,
  684. deep: true,
  685. handler(newVal) {
  686. this.deviceList = newVal;
  687. this.changeHeatNumber();
  688. },
  689. },
  690. list: {
  691. immediate: true,
  692. deep: true,
  693. handler(newVal) {
  694. if (newVal.length) {
  695. console.log(newVal);
  696. this.newList = newVal;
  697. this.sumweight(newVal);
  698. this.sunTj();
  699. }
  700. },
  701. },
  702. },
  703. mounted() {
  704. if (this.deviceList.length > 0) {
  705. this.list.forEach((item) => {
  706. item.deviceId = this.deviceList[0].id
  707. ? this.deviceList[0].id
  708. : this.deviceList[0].instanceId;
  709. });
  710. }
  711. },
  712. data() {
  713. return {
  714. taskTypeName: null,
  715. isFirstTask: null,
  716. stepsList: [],
  717. clientEnvironmentId:
  718. uni.getStorageSync("userInfo") &&
  719. uni.getStorageSync("userInfo").clientEnvironmentId, // *1 主环境-601环境 2 soll-索尔环境 3 tg-碳谷环境
  720. show: false,
  721. rowIt: [],
  722. paramList: [],
  723. paramObj: {},
  724. weight: 0,
  725. reportWeight: 0,
  726. resultObj: {},
  727. resultIdx: 0,
  728. deviceList: [],
  729. isQualifiedList: [
  730. {
  731. code: 1,
  732. name: "合格",
  733. },
  734. {
  735. code: 2,
  736. name: "不合格",
  737. },
  738. ],
  739. notTypeList: [
  740. {
  741. code: 1,
  742. name: "返工",
  743. },
  744. {
  745. code: 2,
  746. name: "返修",
  747. },
  748. {
  749. code: 3,
  750. name: "报废",
  751. },
  752. {
  753. code: 4,
  754. name: "降级使用",
  755. },
  756. {
  757. code: 5,
  758. name: "让步接收",
  759. },
  760. {
  761. code: 6,
  762. name: "留样",
  763. },
  764. {
  765. code: 7,
  766. name: "消耗",
  767. },
  768. {
  769. code: 8,
  770. name: "回用",
  771. },
  772. {
  773. code: 9,
  774. name: "转试销",
  775. },
  776. ],
  777. batchShow: false,
  778. batchForm: {
  779. quantity: "",
  780. batchNo: "",
  781. notReason: "",
  782. isQualified: 1,
  783. notType: "",
  784. },
  785. bacthData: {},
  786. bacthIndex: "",
  787. lossForm: {
  788. batchNo: "",
  789. quantity: "",
  790. unit: "",
  791. isLoss: 1,
  792. },
  793. lossVisible: false,
  794. lossData: {},
  795. lossIndex: "",
  796. };
  797. },
  798. created() {
  799. this.taskTypeName = this.item.currentTaskDiagram.taskTypeName;
  800. this.isFirstTask = this.item.currentTaskDiagram.isFirstTask;
  801. console.log(this.list, "this.list");
  802. this.getSteps();
  803. this.getCompute();
  804. setTimeout(() => {
  805. this.handleInput();
  806. }, 800);
  807. },
  808. methods: {
  809. getSteps() {
  810. getTaskInstanceList(this.item.workOrderId).then((res) => {
  811. res.pop();
  812. this.stepsList = res;
  813. });
  814. },
  815. getCompute() {
  816. getComputeParam(
  817. this.item.workOrderId,
  818. this.item.currentTaskDiagram.taskId
  819. ).then((res) => {
  820. this.paramList = [];
  821. this.paramList = (res && res.paramList) || [];
  822. this.paramObj = res || {};
  823. });
  824. },
  825. handAddParam() {
  826. // billet: null,
  827. // density: null,
  828. // result: null,
  829. // PIPDensity: null,
  830. // volume: null,
  831. // coefficient: null
  832. if (this.isFirstTask == 1) {
  833. this.paramList.push({
  834. taskId: null,
  835. taskName: null,
  836. });
  837. }
  838. },
  839. getDelete(idx) {
  840. this.paramList.splice(idx, 1);
  841. },
  842. changeInp(item, index) {
  843. if (Number(item.billet) && Number(item.density)) {
  844. this.paramList[index].CVIWeight = (
  845. (Number(this.weight) / item.billet) *
  846. item.density
  847. ).toFixed(2);
  848. }
  849. },
  850. paramSave() {
  851. if (this.isFirstTask == 1 && this.paramList.length > 0) {
  852. let bol;
  853. let _i;
  854. bol = this.paramList.every((e, i) => {
  855. _i = i + 1;
  856. return e.taskId && e.billet && e.density;
  857. });
  858. if (!bol) {
  859. uni.showToast({
  860. title: `请完善第${_i}计算数据`,
  861. icon: "none",
  862. });
  863. return false;
  864. }
  865. if (this.paramList.length < 1) {
  866. uni.showToast({
  867. title: `请输入二个以上计算数据`,
  868. icon: "none",
  869. });
  870. return false;
  871. }
  872. }
  873. let param = {};
  874. if (!Object.prototype.hasOwnProperty.call(this.paramObj, "id")) {
  875. param = {
  876. paramList: this.paramList,
  877. workOrderId: this.item.workOrderId,
  878. taskId: this.item.currentTaskDiagram.taskId,
  879. };
  880. } else {
  881. this.paramObj.paramList = this.paramList;
  882. param = this.paramObj;
  883. }
  884. saveParam(param).then((res) => {
  885. uni.showToast({
  886. icon: "none",
  887. title: "操作成功",
  888. });
  889. this.getCompute();
  890. });
  891. },
  892. openNumerate(row, idx) {
  893. if (!row.extInfo.reportWeight) {
  894. uni.showToast({
  895. icon: "none",
  896. title: "请先输入报工重量",
  897. });
  898. return false;
  899. }
  900. this.weight = row.extInfo.weight;
  901. this.reportWeight = row.extInfo.reportWeight;
  902. this.resultIdx = idx;
  903. this.show = true;
  904. },
  905. handleInput() {
  906. let arr = JSON.parse(JSON.stringify(this.list));
  907. this.sumweight(arr);
  908. this.sunTj();
  909. console.log("arr11111112222", this.item);
  910. // console.log('this.list33333',this.list)
  911. },
  912. sumweight(arr) {
  913. // let formedWeight = 0;
  914. // let noFormedWeight = 0;
  915. // arr.map((s, i) => {
  916. // if (s.extInfo.reportWeight) {
  917. // if (s.extInfo.isQualified == 1) {
  918. // formedWeight += s.extInfo.reportWeight * 1;
  919. // } else {
  920. // noFormedWeight += s.extInfo.reportWeight * 1;
  921. // }
  922. // } else {
  923. // s.extInfo.reportWeight = null;
  924. // }
  925. // this.$set(this.list[i].extInfo, "reportWeight", s.extInfo.reportWeight);
  926. // });
  927. // if (this.item.workReportInfo) {
  928. // this.item.workReportInfo.formedWeight = parseFloat(
  929. // formedWeight.toFixed(4)
  930. // );
  931. // this.item.workReportInfo.notFormedWeight = parseFloat(
  932. // noFormedWeight.toFixed(4)
  933. // );
  934. // }
  935. let formedWeight = 0;
  936. let noFormedWeight = 0;
  937. let lossWeight = 0;
  938. arr.map((s, i) => {
  939. if (s.extInfo.reportWeight) {
  940. if (s.extInfo.isQualified == 1 && !s.extInfo.isLoss) {
  941. formedWeight += s.extInfo.reportWeight * 1;
  942. } else if (!s.extInfo.isLoss) {
  943. noFormedWeight += s.extInfo.reportWeight * 1;
  944. } else if (s.extInfo.isLoss == 1) {
  945. lossWeight += s.extInfo.reportWeight * 1;
  946. }
  947. } else {
  948. s.extInfo.reportWeight = null;
  949. }
  950. this.$set(this.list[i].extInfo, "reportWeight", s.extInfo.reportWeight);
  951. });
  952. if (this.item.workReportInfo) {
  953. this.item.workReportInfo.formedWeight = parseFloat(
  954. formedWeight.toFixed(4)
  955. );
  956. this.item.workReportInfo.notFormedWeight = parseFloat(
  957. noFormedWeight.toFixed(4)
  958. );
  959. this.item.workReportInfo.lossWeight = parseFloat(lossWeight.toFixed(4));
  960. }
  961. console.log(this.item.workReportInfo, "this.item.workReportInfo");
  962. },
  963. sunTj() {
  964. if (this.item.workReportInfo && this.item.singleReport == 1) {
  965. this.item.workReportInfo.formedNum = this.newList.filter(
  966. (v) => v.extInfo.isQualified == 1
  967. ).length;
  968. this.item.workReportInfo.notFormedNum = this.newList.filter(
  969. (v) => v.extInfo.isQualified !== 1
  970. ).length;
  971. }
  972. },
  973. cancel() {
  974. this.show = false;
  975. this.reportWeight = 0;
  976. this.weight = 0;
  977. },
  978. taskChange(e) {
  979. console.log(e);
  980. },
  981. getDelete2(idx) {
  982. uni.showModal({
  983. title: "删除",
  984. content: "是否确实删除此物料!",
  985. confirmText: "确认", //这块是确定按钮的文字
  986. success: (rr) => {
  987. if (rr.confirm) {
  988. this.list.splice(idx, 1);
  989. }
  990. if (this.list.length == 0) {
  991. this.$set(this.item.workReportInfo, "formedNum", 0);
  992. this.$set(this.item.workReportInfo, "notFormedNum", 0);
  993. }
  994. this.$forceUpdate();
  995. },
  996. });
  997. },
  998. batchClick(item, index) {
  999. this.batchForm.quantity = "";
  1000. this.batchForm.notType = "";
  1001. this.batchForm.notReason = "";
  1002. this.batchForm.isQualified = 1;
  1003. this.bacthData = item;
  1004. this.bacthIndex = index;
  1005. this.batchForm.batchNo = item.batchNo;
  1006. this.$refs.inputDialog.open();
  1007. },
  1008. deleteBatch(index) {
  1009. uni.showModal({
  1010. title: "删除",
  1011. content: "是否确实删除此物料!",
  1012. confirmText: "确认", //这块是确定按钮的文字
  1013. success: (rr) => {
  1014. this.list.splice(index, 1);
  1015. this.$set(this.item, "product", this.list);
  1016. if (this.list.length == 0) {
  1017. this.$set(this.item.workReportInfo, "formedNum", 0);
  1018. this.$set(this.item.workReportInfo, "notFormedNum", 0);
  1019. }
  1020. this.$forceUpdate();
  1021. },
  1022. });
  1023. },
  1024. handleClose() {
  1025. this.$refs.inputDialog.close();
  1026. this.$refs.lossDialog.close();
  1027. },
  1028. async timeoutCauseConfirm() {
  1029. if (!this.batchForm.quantity) {
  1030. uni.showToast({
  1031. title: "请输入拆批的数量",
  1032. icon: "none",
  1033. });
  1034. return;
  1035. }
  1036. if (this.batchForm.quantity == 0) {
  1037. uni.showToast({
  1038. title: "拆批数不能等于0",
  1039. icon: "none",
  1040. });
  1041. return;
  1042. }
  1043. if (!this.batchForm.quantity) {
  1044. uni.showToast({
  1045. title: "拆批数不能为空",
  1046. icon: "none",
  1047. });
  1048. return;
  1049. }
  1050. if (this.bacthData.extInfo.sourceQuantity < this.batchForm.quantity) {
  1051. uni.showToast({
  1052. title: "拆批数不能大于数量",
  1053. icon: "none",
  1054. });
  1055. return;
  1056. }
  1057. if (this.batchForm.isQualified == 2 && !this.batchForm.notType) {
  1058. uni.showToast({
  1059. title: "请选择不合格类型",
  1060. icon: "none",
  1061. });
  1062. return;
  1063. }
  1064. let dataList = [];
  1065. await splitBatch({
  1066. product: this.bacthData,
  1067. splitQt: Number(this.batchForm.quantity),
  1068. batchNo: this.batchForm.batchNo,
  1069. isQualified: this.batchForm.isQualified,
  1070. notType: this.batchForm.notType,
  1071. notReason: this.batchForm.notReason,
  1072. }).then((res) => {
  1073. res.forEach((item) => {
  1074. dataList.push(this.deepCopy(item));
  1075. });
  1076. this.refreshData(dataList, this.batchForm.quantity);
  1077. });
  1078. // this.$refs.inputDialog.close()
  1079. },
  1080. refreshData(list, feedQuantity) {
  1081. const number =
  1082. Number(this.list[this.bacthIndex].extInfo.sourceQuantity) -
  1083. Number(feedQuantity);
  1084. this.list[this.bacthIndex].extInfo.sourceQuantity = number;
  1085. this.list[this.bacthIndex].feedQuantity = number;
  1086. this.list[this.bacthIndex].extInfo.newWeight =
  1087. (Number(this.list[this.bacthIndex].extInfo.newWeight) * 100000) /
  1088. 100000 -
  1089. (Number(list[0].extInfo.newWeight) * 100000) / 100000;
  1090. list.forEach((item) => {
  1091. item.childBatch = 1;
  1092. });
  1093. let _arr = [...this.list, ...list];
  1094. this.$set(this.list, this.list.length, ...list);
  1095. this.$set(this.item, "product", _arr);
  1096. this.$forceUpdate();
  1097. this.$refs.inputDialog.close();
  1098. },
  1099. openLoss(item, index) {
  1100. this.lossForm.quantity = "";
  1101. this.lossForm.unit = "";
  1102. this.lossForm.batchNo = "";
  1103. this.lossData = item;
  1104. this.lossIndex = index;
  1105. this.lossForm.batchNo = item.batchNo;
  1106. this.lossForm.unit = item.unit;
  1107. this.$refs.lossDialog.open();
  1108. },
  1109. async getLossParam() {
  1110. if (this.lossForm.quantity) {
  1111. if (
  1112. Number(this.lossData.feedQuantity) < Number(this.lossForm.quantity)
  1113. ) {
  1114. this.$message.warning("损耗数不能大于数量");
  1115. return;
  1116. }
  1117. let dataList = [];
  1118. await splitBatch({
  1119. product: this.lossData,
  1120. splitQt: Number(this.lossForm.quantity),
  1121. batchNo: this.lossForm.batchNo,
  1122. isLoss: 1,
  1123. }).then((res) => {
  1124. res.forEach((item) => {
  1125. dataList.push(this.deepCopy(item));
  1126. });
  1127. if (dataList.length != 0) {
  1128. this.refreshLossData(dataList);
  1129. }
  1130. });
  1131. }
  1132. this.$refs.lossDialog.close();
  1133. },
  1134. toInteger(num) {
  1135. const len = this.getDecimalLength(num);
  1136. return {
  1137. int: Math.round(num * Math.pow(10, len)),
  1138. factor: Math.pow(10, len),
  1139. };
  1140. },
  1141. add(a, b) {
  1142. const { int: aInt, factor: aFactor } = this.toInteger(a);
  1143. const { int: bInt, factor: bFactor } = this.toInteger(b);
  1144. const maxFactor = Math.max(aFactor, bFactor);
  1145. return (
  1146. (aInt * (maxFactor / aFactor) + bInt * (maxFactor / bFactor)) /
  1147. maxFactor
  1148. );
  1149. },
  1150. sub(a, b) {
  1151. const { int: aInt, factor: aFactor } = this.toInteger(a);
  1152. const { int: bInt, factor: bFactor } = this.toInteger(b);
  1153. const maxFactor = Math.max(aFactor, bFactor);
  1154. return (
  1155. (aInt * (maxFactor / aFactor) - bInt * (maxFactor / bFactor)) /
  1156. maxFactor
  1157. );
  1158. },
  1159. getDecimalLength(num) {
  1160. return (num.toString().split(".")[1] || "").length;
  1161. },
  1162. refreshLossData(list) {
  1163. const number =
  1164. Number(this.list[this.lossIndex].feedQuantity) -
  1165. Number(this.lossForm.quantity);
  1166. this.list[this.lossIndex].extInfo.sourceQuantity = number;
  1167. this.list[this.lossIndex].feedQuantity = number;
  1168. this.list[this.lossIndex].extInfo.newWeight =
  1169. (Number(this.list[this.lossIndex].extInfo.newWeight) * 100000) /
  1170. 100000 -
  1171. (Number(list[0].extInfo.newWeight) * 100000) / 100000;
  1172. list.forEach((item) => {
  1173. item.childBatch = 1;
  1174. });
  1175. const newList = this.list.filter((item) => item.feedQuantity != 0);
  1176. let _arr = [...newList, ...list];
  1177. this.$set(newList, newList.length, ...list);
  1178. this.$set(this.item, "product", _arr);
  1179. this.$forceUpdate();
  1180. this.$refs.inputDialog.close();
  1181. },
  1182. isChange(val) {
  1183. if (val == "合格") {
  1184. this.batchForm.notType = "";
  1185. this.batchForm.notReason = "";
  1186. }
  1187. },
  1188. deepCopy(obj, hash = new WeakMap()) {
  1189. if (obj === null) return null;
  1190. if (obj instanceof Date) return new Date(obj);
  1191. if (obj instanceof RegExp) return new RegExp(obj);
  1192. if (typeof obj !== "object" && typeof obj !== "function") return obj;
  1193. if (hash.has(obj)) return hash.get(obj);
  1194. const result = Array.isArray(obj) ? [] : {};
  1195. hash.set(obj, result);
  1196. return Object.keys(obj).reduce((acc, key) => {
  1197. acc[key] = this.deepCopy(obj[key], hash);
  1198. return acc;
  1199. }, result);
  1200. },
  1201. save() {
  1202. if (this.isFirstTask == 1) {
  1203. this.resultObj = {};
  1204. if (Number(this.reportWeight) < Number(this.paramList[0].CVIWeight)) {
  1205. this.resultObj = this.paramList[0];
  1206. this.setDataSave();
  1207. return false;
  1208. }
  1209. if (
  1210. Number(this.reportWeight) >=
  1211. this.paramList[this.paramList.length - 1].CVIWeight
  1212. ) {
  1213. this.resultObj = this.paramList[this.paramList.length - 1];
  1214. this.setDataSave();
  1215. return false;
  1216. }
  1217. for (let i = 1; i < this.paramList.length; i++) {
  1218. console.log(i);
  1219. console.log(
  1220. 11,
  1221. Number(this.paramList[i - 1].CVIWeight),
  1222. Number(this.reportWeight)
  1223. );
  1224. if (
  1225. Number(this.paramList[i - 1].CVIWeight) <
  1226. Number(this.reportWeight) &&
  1227. Number(this.reportWeight) < Number(this.paramList[i].CVIWeight)
  1228. ) {
  1229. this.resultObj = this.paramList[i];
  1230. break;
  1231. }
  1232. }
  1233. this.setDataSave();
  1234. }
  1235. },
  1236. setDataSave() {
  1237. this.$set(
  1238. this.list[this.resultIdx].extInfo,
  1239. "taskId",
  1240. this.resultObj.taskId
  1241. );
  1242. this.$set(
  1243. this.list[this.resultIdx].extInfo,
  1244. "density",
  1245. this.resultObj.density
  1246. );
  1247. this.$set(
  1248. this.list[this.resultIdx].extInfo,
  1249. "billet",
  1250. this.resultObj.billet
  1251. );
  1252. this.$set(
  1253. this.list[this.resultIdx].extInfo,
  1254. "taskName",
  1255. this.resultObj.taskName
  1256. );
  1257. this.cancel();
  1258. },
  1259. changeHeatNumber() {
  1260. if (this.deviceList.length != 0) {
  1261. this.deviceList.forEach((f) => {
  1262. this.list.forEach((o) => {
  1263. if (
  1264. o.deviceId &&
  1265. f.instanceId == o.deviceId &&
  1266. this.deviceList.length > 1
  1267. ) {
  1268. o.extInfo.heatNumber = f.extInfo.heatNumber;
  1269. o.deviceId = f.instanceId;
  1270. this.$forceUpdate();
  1271. } else if (this.deviceList.length == 1) {
  1272. o.extInfo.heatNumber = this.deviceList[0].extInfo.heatNumber;
  1273. o.deviceId = this.deviceList[0].instanceId;
  1274. this.$forceUpdate();
  1275. } else if (this.deviceList.length > 1) {
  1276. o.extInfo.heatNumber = f.extInfo.heatNumber;
  1277. o.deviceId = f.instanceId;
  1278. this.$forceUpdate();
  1279. }
  1280. });
  1281. });
  1282. }
  1283. },
  1284. },
  1285. };
  1286. </script>
  1287. <style lang="scss" scoped>
  1288. .title_box {
  1289. margin-top: 20rpx;
  1290. .name {
  1291. font-size: 28rpx;
  1292. font-style: normal;
  1293. font-weight: 400;
  1294. color: $theme-color;
  1295. padding-left: 20rpx;
  1296. position: relative;
  1297. &:before {
  1298. position: absolute;
  1299. content: "";
  1300. left: 0rpx;
  1301. top: 0rpx;
  1302. bottom: 0rpx;
  1303. width: 4rpx;
  1304. height: 28rpx;
  1305. background: $theme-color;
  1306. margin: auto;
  1307. }
  1308. }
  1309. .btn_box {
  1310. .btn {
  1311. padding: 0 18rpx;
  1312. height: 50rpx;
  1313. line-height: 50rpx;
  1314. background: $theme-color;
  1315. font-size: 26rpx;
  1316. font-style: normal;
  1317. font-weight: 400;
  1318. font-size: 24rpx;
  1319. color: #fff;
  1320. border-radius: 4rpx;
  1321. margin-left: 24rpx;
  1322. }
  1323. }
  1324. }
  1325. .material {
  1326. margin-top: 16rpx;
  1327. border: 1rpx solid transparent;
  1328. .content_table {
  1329. width: 100%;
  1330. border: 2rpx solid $border-color;
  1331. box-sizing: border-box;
  1332. .item {
  1333. display: flex;
  1334. border-bottom: 2rpx solid $border-color;
  1335. .lable {
  1336. width: 132rpx;
  1337. text-align: center;
  1338. background-color: #f7f9fa;
  1339. font-size: 26rpx;
  1340. border-right: 2rpx solid $border-color;
  1341. flex-shrink: 0;
  1342. }
  1343. .lable150 {
  1344. width: 156rpx !important;
  1345. font-size: 24rpx;
  1346. }
  1347. .lable190 {
  1348. width: 200rpx !important;
  1349. font-size: 24rpx;
  1350. }
  1351. .ww80 {
  1352. width: 80rpx;
  1353. }
  1354. .content {
  1355. width: 518rpx;
  1356. min-height: 64rpx;
  1357. font-size: 28rpx;
  1358. line-height: 28rpx;
  1359. font-style: normal;
  1360. font-weight: 400;
  1361. padding: 18rpx 8rpx;
  1362. box-sizing: border-box;
  1363. word-wrap: break-word;
  1364. flex-grow: 1 !important;
  1365. .unit {
  1366. padding: 0 4rpx;
  1367. font-size: 24rpx;
  1368. color: #404446;
  1369. }
  1370. .penalize {
  1371. width: 160rpx;
  1372. line-height: 60rpx;
  1373. background: $theme-color;
  1374. font-size: 24rpx;
  1375. text-align: center;
  1376. color: #fff;
  1377. }
  1378. }
  1379. .content_H {
  1380. min-height: 92rpx;
  1381. }
  1382. .pd4 {
  1383. padding: 4rpx 8rpx;
  1384. }
  1385. &:last-child {
  1386. border-bottom: none;
  1387. }
  1388. }
  1389. .ww55 {
  1390. width: 55%;
  1391. }
  1392. .ww50 {
  1393. width: 50%;
  1394. }
  1395. .ww45 {
  1396. width: 45%;
  1397. }
  1398. .tag_box {
  1399. padding: 2rpx 10rpx;
  1400. margin-right: 12rpx;
  1401. background: #e6a23c;
  1402. font-size: 22rpx;
  1403. color: #fff;
  1404. border-radius: 4rpx;
  1405. }
  1406. }
  1407. }
  1408. .button-group {
  1409. margin-top: 15px;
  1410. display: flex;
  1411. width: 100%;
  1412. justify-content: space-around;
  1413. }
  1414. .materialBor {
  1415. border: 1rpx solid #157a2c;
  1416. }
  1417. .content_table2 {
  1418. width: 100%;
  1419. .row {
  1420. width: 100%;
  1421. .item {
  1422. color: #404446;
  1423. font-size: 28rpx;
  1424. padding-left: 12rpx;
  1425. }
  1426. .color157 {
  1427. color: $theme-color;
  1428. }
  1429. .ww30 {
  1430. width: 30%;
  1431. }
  1432. .ww20 {
  1433. width: 20%;
  1434. }
  1435. .ww15 {
  1436. width: 15%;
  1437. }
  1438. .ww25 {
  1439. width: 25%;
  1440. }
  1441. .ww50 {
  1442. width: 50%;
  1443. }
  1444. .ww10 {
  1445. width: 10%;
  1446. }
  1447. }
  1448. .head {
  1449. height: 64rpx;
  1450. background: #f7f9fa;
  1451. // border-top: 2rpx solid #E3E5E5;
  1452. border-left: 2rpx solid #e3e5e5;
  1453. box-sizing: border-box;
  1454. .item {
  1455. height: 64rpx;
  1456. line-height: 64rpx;
  1457. border-right: 2rpx solid #e3e5e5;
  1458. box-sizing: border-box;
  1459. font-size: 22rpx;
  1460. }
  1461. }
  1462. .tr {
  1463. border-top: 2rpx solid #e3e5e5;
  1464. border-left: 2rpx solid #e3e5e5;
  1465. .item {
  1466. font-size: 24rpx;
  1467. min-height: 74rpx;
  1468. display: flex;
  1469. align-items: center;
  1470. border-right: 2rpx solid #e3e5e5;
  1471. box-sizing: border-box;
  1472. white-space: normal;
  1473. word-break: break-all;
  1474. }
  1475. &:last-child {
  1476. border-bottom: 2rpx solid #e3e5e5;
  1477. }
  1478. .numerate {
  1479. font-size: 22rpx;
  1480. color: $theme-color;
  1481. }
  1482. }
  1483. }
  1484. .content_num {
  1485. display: flex;
  1486. align-items: center;
  1487. padding: 0 4rpx;
  1488. /deep/ .uni-input-input {
  1489. border: 2rpx solid #f0f8f2;
  1490. background: #f0f8f2;
  1491. color: $theme-color;
  1492. }
  1493. }
  1494. .popup-content {
  1495. @include flex;
  1496. align-items: center;
  1497. justify-content: center;
  1498. flex-direction: column;
  1499. padding: 15px;
  1500. background-color: #fff;
  1501. box-sizing: border-box;
  1502. border-radius: 10px 10px 10px 10px;
  1503. }
  1504. .round {
  1505. width: 32rpx;
  1506. height: 32rpx;
  1507. line-height: 30rpx;
  1508. text-align: center;
  1509. border-radius: 50%;
  1510. background: $theme-color;
  1511. font-size: 24rpx;
  1512. font-style: normal;
  1513. font-weight: 400;
  1514. color: #fff;
  1515. margin-right: 10rpx;
  1516. }
  1517. .popup_box {
  1518. width: 94vw;
  1519. padding: 16rpx 12rpx;
  1520. box-sizing: border-box;
  1521. }
  1522. .operate_box {
  1523. margin-top: 32rpx;
  1524. padding: 10rpx 100rpx;
  1525. /deep/ .u-button {
  1526. width: 160rpx;
  1527. }
  1528. }
  1529. .formula_box {
  1530. font-size: 24rpx;
  1531. font-style: normal;
  1532. font-weight: 400;
  1533. margin-top: 12rpx;
  1534. }
  1535. .reportWeight {
  1536. font-size: 24rpx;
  1537. font-style: normal;
  1538. font-weight: 400;
  1539. margin-top: 30rpx;
  1540. text {
  1541. color: $theme-color;
  1542. }
  1543. }
  1544. .unit {
  1545. color: #666;
  1546. font-size: 14px;
  1547. margin-right: 8px;
  1548. }
  1549. ::v-deep .uni-forms-item__label {
  1550. font-size: 12px;
  1551. }
  1552. </style>