material.js 24 KB

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