material.js 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846
  1. /**
  2. * 材料服务
  3. * 冯海夫
  4. * 20201008
  5. */
  6. var ServiceMaterial={
  7. // 待入库材料
  8. getWatingInList:function(){
  9. // return getService.methodGet("/fbsPuArrivalvouch/fbsPuArrivalvouch/getWatingInList");
  10. const materialList = [];
  11. materialList.push({
  12. vendorName:"A公司",
  13. materialCode:"10001",
  14. materialName:"物料A",
  15. specs:"3*4",
  16. arriveSum:"10",
  17. arriveDate:"09月18日",
  18. memo:""
  19. });
  20. materialList.push({
  21. vendorName:"B公司",
  22. materialCode:"10002",
  23. materialName:"物料B",
  24. specs:"3*4",
  25. arriveSum:"20",
  26. arriveDate:"09月18日",
  27. memo:""
  28. });
  29. materialList.push({
  30. vendorName:"C公司",
  31. materialCode:"10003",
  32. materialName:"物料C",
  33. specs:"3*4",
  34. arriveSum:"30",
  35. arriveDate:"09月18日",
  36. memo:""
  37. });
  38. materialList.push({
  39. vendorName:"D公司",
  40. materialCode:"10004",
  41. materialName:"物料D",
  42. specs:"3*4",
  43. arriveSum:"40",
  44. arriveDate:"09月18日",
  45. memo:""
  46. });
  47. materialList.push({
  48. vendorName:"E公司",
  49. materialCode:"10005",
  50. materialName:"物料E",
  51. specs:"3*4",
  52. arriveSum:"50",
  53. arriveDate:"09月18日",
  54. memo:""
  55. });
  56. materialList.push({
  57. vendorName:"F公司",
  58. materialCode:"10006",
  59. materialName:"物料F",
  60. specs:"3*4",
  61. arriveSum:"60",
  62. arriveDate:"09月18日",
  63. memo:""
  64. });
  65. var i = 1;
  66. $.each(materialList, function(index,item){
  67. item.index = i++;
  68. })
  69. return materialList;
  70. },
  71. // 已入库数量
  72. getInSum:function(){
  73. // return getService.methodPost("/fbsPuArrivalvouch/fbsPuArrivalvouch/getInSum");
  74. return 8;
  75. },
  76. // 待检材料
  77. getWatingCheckList:function(){
  78. // return getService.methodGet("/fbsPuArrivalvouch/fbsPuArrivalvouch/getWatingCheckList");
  79. const materialList = [];
  80. materialList.push({
  81. vendorName:"A公司",
  82. materialCode:"10001",
  83. materialName:"物料A",
  84. specs:"3*4",
  85. arriveSum:"10",
  86. arriveDate:"09月18日"
  87. });
  88. materialList.push({
  89. vendorName:"B公司",
  90. materialCode:"10002",
  91. materialName:"物料B",
  92. specs:"3*4",
  93. arriveSum:"20",
  94. arriveDate:"09月18日"
  95. });
  96. materialList.push({
  97. vendorName:"C公司",
  98. materialCode:"10003",
  99. materialName:"物料C",
  100. specs:"3*4",
  101. arriveSum:"30",
  102. arriveDate:"09月18日"
  103. });
  104. materialList.push({
  105. vendorName:"D公司",
  106. materialCode:"10004",
  107. materialName:"物料D",
  108. specs:"3*4",
  109. arriveSum:"40",
  110. arriveDate:"09月18日"
  111. });
  112. materialList.push({
  113. vendorName:"E公司",
  114. materialCode:"10005",
  115. materialName:"物料E",
  116. specs:"3*4",
  117. arriveSum:"50",
  118. arriveDate:"09月18日"
  119. });
  120. materialList.push({
  121. vendorName:"F公司",
  122. materialCode:"10006",
  123. materialName:"物料F",
  124. specs:"3*4",
  125. arriveSum:"60",
  126. arriveDate:"09月18日"
  127. });
  128. return materialList;
  129. },
  130. // 已检数量
  131. getCheckSum:function(){
  132. // return getService.methodPost("/fbsPuArrivalvouch/fbsPuArrivalvouch/getCheckSum");
  133. return 10;
  134. },
  135. // 安全库存
  136. getStockList:function(){
  137. const materialList = [];
  138. materialList.push({
  139. materialCode:"10001",
  140. materialName:"物料A",
  141. specs:"3*4",
  142. realStockSum:"10",
  143. safeStockSum:"20"
  144. });
  145. materialList.push({
  146. materialCode:"10002",
  147. materialName:"物料B",
  148. specs:"3*4",
  149. realStockSum:"100",
  150. safeStockSum:"80"
  151. });
  152. materialList.push({
  153. materialCode:"10001",
  154. materialName:"物料A",
  155. specs:"3*4",
  156. realStockSum:"10",
  157. safeStockSum:"20"
  158. });
  159. materialList.push({
  160. materialCode:"10002",
  161. materialName:"物料B",
  162. specs:"3*4",
  163. realStockSum:"100",
  164. safeStockSum:"80"
  165. });materialList.push({
  166. materialCode:"10001",
  167. materialName:"物料A",
  168. specs:"3*4",
  169. realStockSum:"10",
  170. safeStockSum:"20"
  171. });
  172. materialList.push({
  173. materialCode:"10002",
  174. materialName:"物料B",
  175. specs:"3*4",
  176. realStockSum:"100",
  177. safeStockSum:"80"
  178. });materialList.push({
  179. materialCode:"10001",
  180. materialName:"物料A",
  181. specs:"3*4",
  182. realStockSum:"10",
  183. safeStockSum:"20"
  184. });
  185. materialList.push({
  186. materialCode:"10002",
  187. materialName:"物料B",
  188. specs:"3*4",
  189. realStockSum:"100",
  190. safeStockSum:"80"
  191. });materialList.push({
  192. materialCode:"10001",
  193. materialName:"物料A",
  194. specs:"3*4",
  195. realStockSum:"10",
  196. safeStockSum:"20"
  197. });
  198. materialList.push({
  199. materialCode:"10002",
  200. materialName:"物料B",
  201. specs:"3*4",
  202. realStockSum:"100",
  203. safeStockSum:"80"
  204. });materialList.push({
  205. materialCode:"10001",
  206. materialName:"物料A",
  207. specs:"3*4",
  208. realStockSum:"10",
  209. safeStockSum:"20"
  210. });
  211. materialList.push({
  212. materialCode:"10002",
  213. materialName:"物料B",
  214. specs:"3*4",
  215. realStockSum:"100",
  216. safeStockSum:"80"
  217. });materialList.push({
  218. materialCode:"10001",
  219. materialName:"物料A",
  220. specs:"3*4",
  221. realStockSum:"10",
  222. safeStockSum:"20"
  223. });
  224. materialList.push({
  225. materialCode:"10002",
  226. materialName:"物料B",
  227. specs:"3*4",
  228. realStockSum:"100",
  229. safeStockSum:"80"
  230. });
  231. materialList.push({
  232. materialCode:"10001",
  233. materialName:"物料A",
  234. specs:"3*4",
  235. realStockSum:"10",
  236. safeStockSum:"20"
  237. });
  238. return materialList;
  239. },
  240. // 工单备料
  241. getListByOrderSheet:function(){
  242. const materialList = [];
  243. materialList.push({
  244. orderSheetCode:"G10001",
  245. materialCode:"10001",
  246. materialName:"物料A",
  247. specs:"3*4",
  248. needSum:"20",
  249. stockSum:"20"
  250. });
  251. materialList.push({
  252. orderSheetCode:"G10001",
  253. materialCode:"10002",
  254. materialName:"物料B",
  255. specs:"3*4",
  256. needSum:"10",
  257. stockSum:"30"
  258. });
  259. materialList.push({
  260. orderSheetCode:"G10002",
  261. materialCode:"10003",
  262. materialName:"物料C",
  263. specs:"3*4",
  264. needSum:"40",
  265. stockSum:"20"
  266. });
  267. materialList.push({
  268. orderSheetCode:"G10003",
  269. materialCode:"10004",
  270. materialName:"物料D",
  271. specs:"3*4",
  272. needSum:"30",
  273. stockSum:"30"
  274. });
  275. materialList.push({
  276. orderSheetCode:"G10004",
  277. materialCode:"10005",
  278. materialName:"物料E",
  279. specs:"3*4",
  280. needSum:"20",
  281. stockSum:"20"
  282. });
  283. materialList.push({
  284. orderSheetCode:"G10001",
  285. materialCode:"10001",
  286. materialName:"物料A",
  287. specs:"3*4",
  288. needSum:"20",
  289. stockSum:"20"
  290. });
  291. materialList.push({
  292. orderSheetCode:"G10004",
  293. materialCode:"10005",
  294. materialName:"物料E",
  295. specs:"3*4",
  296. needSum:"20",
  297. stockSum:"20"
  298. });
  299. return materialList;
  300. },
  301. // 工单缺料
  302. getListByOrderSheetNotEnough:function(){
  303. const materialList = [];
  304. materialList.push({
  305. orderSheetCode:"G10001",
  306. materialCode:"10001",
  307. materialName:"物料A",
  308. specs:"3*4",
  309. needSum:"30",
  310. stockSum:"20"
  311. });
  312. materialList.push({
  313. orderSheetCode:"G10001",
  314. materialCode:"10002",
  315. materialName:"物料B",
  316. specs:"3*4",
  317. needSum:"55",
  318. stockSum:"30"
  319. });
  320. materialList.push({
  321. orderSheetCode:"G10002",
  322. materialCode:"10003",
  323. materialName:"物料C",
  324. specs:"3*4",
  325. needSum:"40",
  326. stockSum:"20"
  327. });
  328. materialList.push({
  329. orderSheetCode:"G10003",
  330. materialCode:"10004",
  331. materialName:"物料D",
  332. specs:"3*4",
  333. needSum:"40",
  334. stockSum:"30"
  335. });
  336. materialList.push({
  337. orderSheetCode:"G10004",
  338. materialCode:"10005",
  339. materialName:"物料E",
  340. specs:"3*4",
  341. needSum:"25",
  342. stockSum:"20"
  343. });
  344. return materialList;
  345. },
  346. // 工单齐套
  347. getListByOrderSheetEnough:function(){
  348. const materialList = [];
  349. materialList.push({
  350. orderSheetCode:"G10001",
  351. materialCode:"10001",
  352. materialName:"物料A",
  353. specs:"3*4",
  354. needSum:"10",
  355. stockSum:"20"
  356. });
  357. materialList.push({
  358. orderSheetCode:"G10001",
  359. materialCode:"10002",
  360. materialName:"物料B",
  361. specs:"3*4",
  362. needSum:"15",
  363. stockSum:"30"
  364. });
  365. materialList.push({
  366. orderSheetCode:"G10002",
  367. materialCode:"10003",
  368. materialName:"物料C",
  369. specs:"3*4",
  370. needSum:"20",
  371. stockSum:"20"
  372. });
  373. materialList.push({
  374. orderSheetCode:"G10003",
  375. materialCode:"10004",
  376. materialName:"物料D",
  377. specs:"3*4",
  378. needSum:"30",
  379. stockSum:"30"
  380. });
  381. materialList.push({
  382. orderSheetCode:"G10003",
  383. materialCode:"10004",
  384. materialName:"物料D",
  385. specs:"3*4",
  386. needSum:"30",
  387. stockSum:"30"
  388. });
  389. materialList.push({
  390. orderSheetCode:"G10003",
  391. materialCode:"10004",
  392. materialName:"物料D",
  393. specs:"3*4",
  394. needSum:"30",
  395. stockSum:"30"
  396. });
  397. materialList.push({
  398. orderSheetCode:"G10003",
  399. materialCode:"10004",
  400. materialName:"物料D",
  401. specs:"3*4",
  402. needSum:"30",
  403. stockSum:"30"
  404. });
  405. materialList.push({
  406. orderSheetCode:"G10003",
  407. materialCode:"10004",
  408. materialName:"物料D",
  409. specs:"3*4",
  410. needSum:"30",
  411. stockSum:"30"
  412. });
  413. materialList.push({
  414. orderSheetCode:"G10003",
  415. materialCode:"10004",
  416. materialName:"物料D",
  417. specs:"3*4",
  418. needSum:"30",
  419. stockSum:"30"
  420. });
  421. materialList.push({
  422. orderSheetCode:"G10004",
  423. materialCode:"10005",
  424. materialName:"物料E",
  425. specs:"3*4",
  426. needSum:"15",
  427. stockSum:"20"
  428. });
  429. return materialList;
  430. },
  431. // 领料申请通知
  432. getApplyList:function(){
  433. const materialList = [];
  434. materialList.push({
  435. orderSheetCode:"G10001",
  436. materialCode:"10001",
  437. materialName:"物料A",
  438. specs:"3*4",
  439. applyPerson:"张三",
  440. applysum:"20"
  441. });
  442. materialList.push({
  443. orderSheetCode:"G10001",
  444. materialCode:"10002",
  445. materialName:"物料B",
  446. specs:"3*4",
  447. applyPerson:"张三",
  448. applysum:"20"
  449. });
  450. materialList.push({
  451. orderSheetCode:"G10002",
  452. materialCode:"10003",
  453. materialName:"物料C",
  454. specs:"3*4",
  455. applyPerson:"张三",
  456. applysum:"20"
  457. });
  458. materialList.push({
  459. orderSheetCode:"G10003",
  460. materialCode:"10004",
  461. materialName:"物料D",
  462. specs:"3*4",
  463. applyPerson:"张三",
  464. applysum:"20"
  465. });
  466. materialList.push({
  467. orderSheetCode:"G10004",
  468. materialCode:"10005",
  469. materialName:"物料E",
  470. specs:"3*4",
  471. applyPerson:"张三",
  472. applysum:"20"
  473. });
  474. return materialList;
  475. },
  476. // 领料申请完成数量
  477. getApplyCompleteSum:function(){
  478. return 10;
  479. },
  480. // 未来几天内到货计划
  481. getWillArriveList:function(days){
  482. const materialList = [];
  483. materialList.push({
  484. vendorName:"A公司",
  485. materialCode:"10001",
  486. materialName:"物料A",
  487. specs:"3*4",
  488. arriveSum:"10",
  489. arriveDate:"09月18日",
  490. memo:""
  491. });
  492. materialList.push({
  493. vendorName:"B公司",
  494. materialCode:"10002",
  495. materialName:"物料B",
  496. specs:"3*4",
  497. arriveSum:"20",
  498. arriveDate:"09月18日",
  499. memo:""
  500. });
  501. materialList.push({
  502. vendorName:"C公司",
  503. materialCode:"10003",
  504. materialName:"物料C",
  505. specs:"3*4",
  506. arriveSum:"30",
  507. arriveDate:"09月18日",
  508. memo:""
  509. });
  510. materialList.push({
  511. vendorName:"D公司",
  512. materialCode:"10004",
  513. materialName:"物料D",
  514. specs:"3*4",
  515. arriveSum:"40",
  516. arriveDate:"09月18日",
  517. memo:""
  518. });
  519. materialList.push({
  520. vendorName:"E公司",
  521. materialCode:"10005",
  522. materialName:"物料E",
  523. specs:"3*4",
  524. arriveSum:"50",
  525. arriveDate:"09月18日",
  526. memo:""
  527. });
  528. materialList.push({
  529. vendorName:"F公司",
  530. materialCode:"10006",
  531. materialName:"物料F",
  532. specs:"3*4",
  533. arriveSum:"60",
  534. arriveDate:"09月18日",
  535. memo:""
  536. });
  537. var i = 1;
  538. $.each(materialList, function(index,item){
  539. item.index = i++;
  540. })
  541. return materialList;
  542. },
  543. // 当天到货批数
  544. getTodayArriveSum:function(){
  545. return 100;
  546. },
  547. // 未来几天到货批数
  548. getWillArriveSum:function(days){
  549. return 300;
  550. },
  551. // 当月到货批数
  552. getThisMonthArriveSum:function(){
  553. return 7882;
  554. },
  555. // 未入库总批数
  556. getNotInSum:function(){
  557. return 90;
  558. },
  559. // 近6个月质量目标合格率比较
  560. getLastSixMonthQualityTargetCompare: function () {
  561. const list = [];
  562. list.push({
  563. month: "04",
  564. target: 98,
  565. real: 97
  566. });
  567. list.push({
  568. month: "05",
  569. target: 98,
  570. real: 96
  571. });
  572. list.push({
  573. month: "06",
  574. target: 98,
  575. real: 95
  576. });
  577. list.push({
  578. month: "07",
  579. target: 98,
  580. real: 99
  581. });
  582. list.push({
  583. month: "08",
  584. target: 98,
  585. real: 100
  586. });
  587. list.push({
  588. month: "09",
  589. target: 98,
  590. real: 98
  591. });
  592. $.each(list, function (index, item) {
  593. item.label = item.month;
  594. item.label1 = "质量目标";
  595. item.sum1 = item.target;
  596. item.label2 = "合格率";
  597. item.sum2 = item.real;
  598. });
  599. return list;
  600. },
  601. // 当月供应商合格率
  602. getPassRateByVendor: function () {
  603. return {
  604. "供应商A":98,
  605. "供应商B":95,
  606. "供应商C":94,
  607. "供应商D":93,
  608. "供应商E":99,
  609. "供应商F":97
  610. }
  611. },
  612. // 当月检验合格率
  613. getCheckRateByBatchno: function () {
  614. return {
  615. "07001":98,
  616. "07002":95,
  617. "07003":94,
  618. "07004":93,
  619. "07005":99,
  620. "07006":97
  621. }
  622. },
  623. // 未来几天内到货计划
  624. getQualityUnpassList:function(days){
  625. const materialList = [];
  626. materialList.push({
  627. vendorName:"A公司",
  628. materialCode:"10001",
  629. materialName:"物料A",
  630. specs:"3*4",
  631. arriveSum:"100",
  632. checkSum:"10",
  633. unpassSum:"1",
  634. checkDate:"09月18日",
  635. images:[
  636. "/images/quality/11.png",
  637. "/images/quality/12.png"
  638. ]
  639. });
  640. materialList.push({
  641. vendorName:"B公司",
  642. materialCode:"10002",
  643. materialName:"物料B",
  644. specs:"3*4",
  645. arriveSum:"200",
  646. checkSum:"10",
  647. unpassSum:"1",
  648. checkDate:"09月18日",
  649. images:[
  650. "/images/quality/13.png",
  651. "/images/quality/21.png"
  652. ]
  653. });
  654. materialList.push({
  655. vendorName:"C公司",
  656. materialCode:"10003",
  657. materialName:"物料C",
  658. specs:"3*4",
  659. arriveSum:"300",
  660. checkSum:"10",
  661. unpassSum:"1",
  662. checkDate:"09月18日",
  663. images:[
  664. "/images/quality/22.png",
  665. "/images/quality/23.png"
  666. ]
  667. });
  668. materialList.push({
  669. vendorName:"D公司",
  670. materialCode:"10004",
  671. materialName:"物料D",
  672. specs:"3*4",
  673. arriveSum:"400",
  674. checkSum:"10",
  675. unpassSum:"1",
  676. checkDate:"09月18日",
  677. images:[
  678. "/images/quality/11.png",
  679. "/images/quality/12.png",
  680. "/images/quality/13.png"
  681. ]
  682. });
  683. materialList.push({
  684. vendorName:"E公司",
  685. materialCode:"10005",
  686. materialName:"物料E",
  687. specs:"3*4",
  688. arriveSum:"500",
  689. checkSum:"10",
  690. unpassSum:"1",
  691. checkDate:"09月18日",
  692. images:[
  693. "/images/quality/21.png",
  694. "/images/quality/22.png",
  695. "/images/quality/23.png"
  696. ]
  697. });
  698. materialList.push({
  699. vendorName:"F公司",
  700. materialCode:"10006",
  701. materialName:"物料F",
  702. specs:"3*4",
  703. arriveSum:"600",
  704. checkSum:"10",
  705. unpassSum:"1",
  706. checkDate:"09月18日",
  707. images:[
  708. "/images/quality/11.png",
  709. "/images/quality/12.png",
  710. "/images/quality/13.png",
  711. "/images/quality/21.png"
  712. ]
  713. });
  714. materialList.push({
  715. vendorName:"A公司",
  716. materialCode:"10001",
  717. materialName:"物料A",
  718. specs:"3*4",
  719. arriveSum:"100",
  720. checkSum:"10",
  721. unpassSum:"1",
  722. checkDate:"09月18日",
  723. images:[
  724. "/images/quality/12.png",
  725. "/images/quality/13.png",
  726. "/images/quality/21.png",
  727. "/images/quality/22.png"
  728. ]
  729. });
  730. materialList.push({
  731. vendorName:"B公司",
  732. materialCode:"10002",
  733. materialName:"物料B",
  734. specs:"3*4",
  735. arriveSum:"200",
  736. checkSum:"10",
  737. unpassSum:"1",
  738. checkDate:"09月18日",
  739. images:[
  740. "/images/quality/21.png",
  741. "/images/quality/22.png",
  742. "/images/quality/13.png",
  743. "/images/quality/23.png"
  744. ]
  745. });
  746. materialList.push({
  747. vendorName:"C公司",
  748. materialCode:"10003",
  749. materialName:"物料C",
  750. specs:"3*4",
  751. arriveSum:"300",
  752. checkSum:"10",
  753. unpassSum:"1",
  754. checkDate:"09月18日",
  755. images:[
  756. "/images/quality/22.png",
  757. "/images/quality/13.png",
  758. "/images/quality/23.png"
  759. ]
  760. });
  761. materialList.push({
  762. vendorName:"D公司",
  763. materialCode:"10004",
  764. materialName:"物料D",
  765. specs:"3*4",
  766. arriveSum:"400",
  767. checkSum:"10",
  768. unpassSum:"1",
  769. checkDate:"09月18日",
  770. images:[
  771. "/images/quality/21.png",
  772. "/images/quality/22.png",
  773. "/images/quality/13.png",
  774. "/images/quality/23.png",
  775. "/images/quality/11.png",
  776. "/images/quality/12.png"
  777. ]
  778. });
  779. materialList.push({
  780. vendorName:"E公司",
  781. materialCode:"10005",
  782. materialName:"物料E",
  783. specs:"3*4",
  784. arriveSum:"500",
  785. checkSum:"10",
  786. unpassSum:"1",
  787. checkDate:"09月18日",
  788. images:[
  789. "/images/quality/23.png",
  790. "/images/quality/21.png",
  791. "/images/quality/11.png",
  792. "/images/quality/22.png",
  793. "/images/quality/13.png",
  794. "/images/quality/12.png"
  795. ]
  796. });
  797. materialList.push({
  798. vendorName:"F公司",
  799. materialCode:"10006",
  800. materialName:"物料F",
  801. specs:"3*4",
  802. arriveSum:"600",
  803. checkSum:"10",
  804. unpassSum:"1",
  805. checkDate:"09月18日",
  806. images:[
  807. "/images/quality/13.png",
  808. "/images/quality/12.png",
  809. "/images/quality/23.png",
  810. "/images/quality/22.png",
  811. "/images/quality/11.png",
  812. "/images/quality/21.png"
  813. ]
  814. });
  815. var i = 1;
  816. $.each(materialList, function(index,item){
  817. if (i == 1){
  818. item.bg = "selectrow";
  819. }else{
  820. item.bg = "";
  821. }
  822. item.index = i++;
  823. item.passRate = ((item.checkSum-item.unpassSum)/item.checkSum*100).toFixed(0)+"%";
  824. })
  825. return materialList;
  826. },
  827. }