batchProductJobBom.vue 45 KB

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