product.js 7.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267
  1. /**
  2. * 成品服务
  3. * 冯海夫
  4. * 20201008
  5. */
  6. var ServiceProduct = {
  7. // 待发货成品
  8. getWatingSendList: function () {
  9. return getService.methodGet("/fbsDispatchList/fbsDispatchList/getWatingSendList");
  10. // const productList = [];
  11. // productList.push({
  12. // warehouseName: "A仓库",
  13. // materialCode: "10001",
  14. // materialName: "物料A",
  15. // specs: "3*4",
  16. // sendSum: "10",
  17. // planSendDate: "09月18日"
  18. // });
  19. // productList.push({
  20. // warehouseName: "A仓库",
  21. // materialCode: "10002",
  22. // materialName: "物料B",
  23. // specs: "3*4",
  24. // sendSum: "20",
  25. // planSendDate: "09月18日"
  26. // });
  27. // productList.push({
  28. // warehouseName: "A仓库",
  29. // materialCode: "10003",
  30. // materialName: "物料C",
  31. // specs: "3*4",
  32. // sendSum: "30",
  33. // planSendDate: "09月18日"
  34. // });
  35. // productList.push({
  36. // warehouseName: "B仓库",
  37. // materialCode: "10004",
  38. // materialName: "物料D",
  39. // specs: "3*4",
  40. // sendSum: "40",
  41. // planSendDate: "09月18日"
  42. // });
  43. // productList.push({
  44. // warehouseName: "B仓库",
  45. // materialCode: "10005",
  46. // materialName: "物料E",
  47. // specs: "3*4",
  48. // sendSum: "50",
  49. // planSendDate: "09月18日"
  50. // });
  51. // productList.push({
  52. // warehouseName: "B仓库",
  53. // materialCode: "10006",
  54. // materialName: "物料F",
  55. // specs: "3*4",
  56. // sendSum: "60",
  57. // planSendDate: "09月18日"
  58. // });
  59. // return productList;
  60. },
  61. // 已入库数量
  62. getSendSum: function () {
  63. return getService.methodPost("/fbsDispatchList/fbsDispatchList/getSendSum");
  64. // return 9;
  65. },
  66. // 月成品出货统计,根据成品维度
  67. getMonthSend: function () {
  68. // return getService.methodGet("/fbsRdrecord32/fbsRdrecords32/getMonthSend");
  69. return getService.methodGet("/fbsDispatchLists/fbsDispatchLists/getProjectDelivery");
  70. // return {
  71. // "成品A": 20,
  72. // "成品B": 100,
  73. // "成品C": 80,
  74. // "成品D": 150,
  75. // "成品E": 200,
  76. // };
  77. },
  78. // 月项目发货统计,根据项目维度
  79. getMonthSendByProject: function () {
  80. // return {
  81. // "项目A": 20,
  82. // "项目B": 100,
  83. // "项目C": 80,
  84. // "项目D": 150,
  85. // "项目E": 200,
  86. // };
  87. var getMonthSendByProject=MethodGetService.methodGet("/fbsDispatchLists/fbsDispatchLists/getMonthSendByProject");
  88. return getMonthSendByProject;
  89. },
  90. // 成品库存,物料维度
  91. getStockList: function () {
  92. return getService.methodGet("/fbsInventory/fbsInventory/getAllStockList");
  93. // return {
  94. // "成品A": 800,
  95. // "成品B": 900,
  96. // "成品C": 1000,
  97. // "成品D": 700,
  98. // "成品E": 600,
  99. // "成品F": 1100,
  100. // "成品G": 500
  101. // };
  102. },
  103. // 根据产品分类获取质量异常数量
  104. getQualityExceptionByCategory: function () {
  105. return MethodGetService.methodGet("/fbsWorkshopDispatchList/fbsWorkshopDispatchList/getAbnormalHoursMonthReport");
  106. // return {
  107. // "分类A": 800,
  108. // "分类B": 900,
  109. // "分类C": 1000,
  110. // "分类D": 700,
  111. // "分类E": 600,
  112. // "分类F": 1100,
  113. // "分类G": 500
  114. // };
  115. },
  116. // 某月产品良数量
  117. getMonthGood: function () {
  118. // const list = [];
  119. // list.push({
  120. // label: "产品A",
  121. // sum1: 48,
  122. // sum2: 50
  123. // });
  124. // list.push({
  125. // label: "产品B",
  126. // sum1: 80,
  127. // sum2: 90
  128. // });
  129. // list.push({
  130. // label: "产品C",
  131. // sum1: 47,
  132. // sum2: 50
  133. // });
  134. // list.push({
  135. // label: "产品D",
  136. // sum1: 40,
  137. // sum2: 50
  138. // });
  139. // list.push({
  140. // label: "产品E",
  141. // sum1: 42,
  142. // sum2: 50
  143. // });
  144. // list.push({
  145. // label: "产品F",
  146. // sum1: 44,
  147. // sum2: 50
  148. // });
  149. // list.push({
  150. // label: "产品G",
  151. // sum1: 45,
  152. // sum2: 50
  153. // });
  154. // return list;
  155. return MethodGetService.methodGet("/fbsAbnormalWorkingHours/fbsAbnormalWorkingHours/getRejectsNumber");
  156. },
  157. // 月制程异常,根据分类
  158. getMonthExceptionByCategory: function () {
  159. // return {
  160. // "分类A": 600,
  161. // "分类B": 500,
  162. // "分类C": 300,
  163. // "分类D": 200,
  164. // "分类E": 100,
  165. // "分类F": 200,
  166. // "分类G": 400
  167. // };
  168. // return MethodGetService.methodGet("/fbsAbnormalWorkingHours/fbsAbnormalWorkingHours/getQualityType");
  169. return MethodGetService.methodGet("/fbsAbnormalWorkingHours/fbsAbnormalWorkingHoursDescribe/getMonthExceptionByCategory");
  170. },
  171. // 周成品入库数量,根据分类
  172. getWeekInByCategory: function () {
  173. // return {
  174. // "分类A": 500,
  175. // "分类B": 600,
  176. // "分类C": 800,
  177. // "分类D": 700,
  178. // "分类E": 600,
  179. // "分类F": 400,
  180. // "分类G": 500
  181. // };
  182. return MethodGetService.methodGet("/fbsMomOrder/fbsMomOrderdetail/getQualifiedInQtyWeek");
  183. },
  184. // 生产效率
  185. getProduceRate: function () {
  186. // const rate = 95;
  187. rate=MethodGetService.methodGet("/fbsWorkshopDispatchList/fbsWorkshopDispatchList/getProductionEfficiency");
  188. return {
  189. name: "当月生产效率",
  190. value: rate
  191. };
  192. },
  193. // 日生产效率
  194. getDayProduceRate: function () {
  195. // const rate = 90;
  196. rate=MethodGetService.methodGet("/fbsWorkshopDispatchList/fbsWorkshopDispatchList/getProductionEfficiency?type=1");
  197. return {
  198. name: "生产效率",
  199. value: rate
  200. };
  201. },
  202. // 某日产品良数量
  203. getDayGood: function () {
  204. // const list = [];
  205. // list.push({
  206. // label: "产品A",
  207. // sum1: 48,
  208. // sum2: 50
  209. // });
  210. // list.push({
  211. // label: "产品B",
  212. // sum1: 80,
  213. // sum2: 90
  214. // });
  215. // list.push({
  216. // label: "产品C",
  217. // sum1: 47,
  218. // sum2: 50
  219. // });
  220. // list.push({
  221. // label: "产品D",
  222. // sum1: 40,
  223. // sum2: 50
  224. // });
  225. // list.push({
  226. // label: "产品E",
  227. // sum1: 42,
  228. // sum2: 50
  229. // });
  230. // list.push({
  231. // label: "产品F",
  232. // sum1: 44,
  233. // sum2: 50
  234. // });
  235. // list.push({
  236. // label: "产品G",
  237. // sum1: 45,
  238. // sum2: 50
  239. // });
  240. // return list;
  241. return MethodGetService.methodGet("/fbsAbnormalWorkingHours/fbsAbnormalWorkingHours/getRejectsNumber?type=1");
  242. },
  243. // 日质量异常,根据分类
  244. getDayExceptionByCategory: function () {
  245. // return {
  246. // "分类A": 600,
  247. // "分类B": 500,
  248. // "分类C": 300,
  249. // "分类D": 200,
  250. // "分类E": 100,
  251. // "分类F": 200,
  252. // "分类G": 400
  253. // };
  254. return MethodGetService.methodGet("/fbsWorkshopDispatchList/fbsWorkshopDispatchList/getAbnormalHoursMonthReport?type=1");
  255. },
  256. }