ProdinoutCount.js 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172
  1. Ext.define('saas.view.stock.report.ProdinoutCount', {
  2. extend: 'saas.view.core.report.ReportPanel',
  3. xtype: 'stock-report-prodinoutCount',
  4. controller: 'stock-report-prodinoutCount',
  5. viewModel: 'stock-report-prodinoutCount',
  6. viewName: 'stock-report-prodinoutCount',
  7. groupField: null,
  8. listUrl: '/api/storage/report/prodinoutCount',
  9. defaultCondition: null,
  10. reportTitle: '物料收发汇总表',
  11. QueryWidth:0.4,
  12. searchItems: [{
  13. xtype: 'textfield',
  14. name: 'wh_description',
  15. fieldLabel: '仓库',
  16. emptyText:'输入仓库编号或名称',
  17. columnWidth: 0.2,
  18. getCondition: function(value) {
  19. return ' (wh_description like\'%' + value + '%\' or wh_code like \'%'+value+'%\') ';
  20. }
  21. }, {
  22. xtype: 'productDbfindTrigger',
  23. name: 'pr_code',
  24. emptyText:'输入物料编号或名称',
  25. columnWidth: 0.2,
  26. margin:'0 0 0 20',
  27. }, {
  28. xtype: 'monthdatefield',
  29. name: 'pwm_yearmonth',
  30. fieldLabel: '期间',
  31. columnWidth: 0.2
  32. }],
  33. reportColumns: [{
  34. text: '物料编号',
  35. width: 150,
  36. dataIndex: 'pr_code'
  37. }, {
  38. text: '品牌',
  39. dataIndex: 'pr_brand',
  40. width: 100
  41. }, {
  42. text: '物料名称',
  43. dataIndex: 'pr_detail',
  44. width: 150
  45. }, {
  46. text: '型号',
  47. dataIndex: 'pr_orispeccode',
  48. width: 200
  49. }, {
  50. text: '规格',
  51. dataIndex: 'pr_spec',
  52. width: 200
  53. }, {
  54. text: '物料类型',
  55. dataIndex: 'pr_kind',
  56. width: 100
  57. }, {
  58. text: '单位',
  59. dataIndex: 'pr_unit',
  60. width: 65
  61. },{
  62. text: '仓库',
  63. dataIndex:'wh_description',
  64. width: 80
  65. }, {
  66. text: '期初',
  67. columns: [{
  68. text: '数量',
  69. dataIndex:'pwm_beginqty',
  70. exportFormat: 'Quantity',
  71. xtype: 'numbercolumn',
  72. width:110,
  73. renderer: function(v) {
  74. return saas.util.BaseUtil.numberFormat(v, 3, false);
  75. },
  76. },{
  77. text: '成本(元)',
  78. dataIndex:'pwm_beginamount',
  79. exportFormat: 'Amount',
  80. xtype: 'numbercolumn',
  81. width:110,
  82. renderer: function(v) {
  83. return saas.util.BaseUtil.numberFormat(v, 2, true);
  84. },
  85. summaryType: 'sum',
  86. summaryLabel: '期初成本',
  87. summaryRenderer: function(v) {
  88. return saas.util.BaseUtil.numberFormat(v, 3, false);
  89. }
  90. }]
  91. }, {
  92. text: '入库',
  93. columns: [{
  94. text: '数量',
  95. dataIndex:'pwm_nowinqty',
  96. exportFormat: 'Quantity',
  97. xtype: 'numbercolumn',
  98. width:110,
  99. renderer: function(v) {
  100. return saas.util.BaseUtil.numberFormat(v, 3, false);
  101. }
  102. },{
  103. text: '成本(元)',
  104. dataIndex:'pwm_nowinamount',
  105. exportFormat: 'Amount',
  106. xtype: 'numbercolumn',
  107. width:110,
  108. renderer: function(v) {
  109. return saas.util.BaseUtil.numberFormat(v, 2, true);
  110. },
  111. summaryType: 'sum',
  112. summaryLabel: '入库成本',
  113. summaryRenderer: function(v) {
  114. return saas.util.BaseUtil.numberFormat(v, 3, false);
  115. }
  116. }]
  117. }, {
  118. text: '出库',
  119. columns: [{
  120. text: '数量',
  121. dataIndex:'pwm_nowoutqty',
  122. exportFormat: 'Quantity',
  123. xtype: 'numbercolumn',
  124. width: 110,
  125. renderer: function(v) {
  126. return saas.util.BaseUtil.numberFormat(v, 3, false);
  127. }
  128. },{
  129. text: '成本(元)',
  130. dataIndex:'pwm_nowoutamount',
  131. exportFormat: 'Amount',
  132. xtype: 'numbercolumn',
  133. width: 110,
  134. renderer: function(v) {
  135. return saas.util.BaseUtil.numberFormat(v, 2, true);
  136. },
  137. summaryType: 'sum',
  138. summaryLabel: '出库成本',
  139. summaryRenderer: function(v) {
  140. return saas.util.BaseUtil.numberFormat(v, 3, false);
  141. }
  142. }]
  143. }, {
  144. text: '结存',
  145. columns: [{
  146. text: '数量',
  147. dataIndex:'pwm_endqty',
  148. exportFormat: 'Quantity',
  149. xtype: 'numbercolumn',
  150. width: 110,
  151. renderer: function(v) {
  152. return saas.util.BaseUtil.numberFormat(v, 3, false);
  153. }
  154. },{
  155. text: '成本(元)',
  156. dataIndex:'pwm_endamount',
  157. exportFormat: 'Amount',
  158. xtype: 'numbercolumn',
  159. width: 110,
  160. renderer: function(v) {
  161. return saas.util.BaseUtil.numberFormat(v, 2, true);
  162. },
  163. summaryType: 'sum',
  164. summaryLabel: '结存成本',
  165. summaryRenderer: function(v) {
  166. return saas.util.BaseUtil.numberFormat(v, 3, false);
  167. }
  168. }]
  169. }]
  170. });