batchProductJobBom.vue 45 KB

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