VendorCheck.js 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137
  1. Ext.define('saas.view.money.report.VendorCheck', {
  2. extend: 'saas.view.core.report.ReportPanel',
  3. xtype: 'monry-report-vendorcheck',
  4. controller: 'money-report-vendorcheck',
  5. viewModel: 'money-report-vendorcheck',
  6. viewName: 'money-report-vendorcheck',
  7. groupField: 'pi_vendname',
  8. listUrl: '/api/money/report/vendorCheck',
  9. defaultCondition: null,
  10. reportTitle: '供应商对账单',
  11. QueryWidth:0.25,
  12. //筛选:供应商、日期(必填)
  13. searchItems: [ {
  14. xtype: 'vendorDbfindTrigger',
  15. name: 'pi_vendname',
  16. fieldLabel: '供应商名称',
  17. columnWidth: 0.25
  18. }, {
  19. xtype: 'condatefield',
  20. name: 'pi_date',
  21. fieldLabel: '单据日期',
  22. columnWidth: 0.5
  23. }],
  24. reportColumns: [
  25. {
  26. text: 'id',
  27. dataIndex: 'pi_id',
  28. hidden: true
  29. }, {
  30. text: '单号',
  31. dataIndex: 'pi_inoutno',
  32. width: 150
  33. }, {
  34. text: '单据类型',
  35. dataIndex: 'pi_class',
  36. width: 110
  37. }, {
  38. text: '单据日期',
  39. dataIndex: 'pi_date',
  40. xtype:'datecolumn',
  41. width: 110
  42. }, {
  43. text: '序号',
  44. dataIndex: 'pd_pdno',
  45. width: 80
  46. },{
  47. text:'供应商编号',
  48. dataIndex:'pi_vendcode',
  49. width: 150
  50. },{
  51. text:'供应商名称',
  52. dataIndex:'pi_vendname',
  53. width: 200
  54. },{
  55. text: '物料编号',
  56. dataIndex: 'pr_code',
  57. width: 150
  58. }, {
  59. text: '物料名称',
  60. dataIndex: 'pr_detail',
  61. width: 200
  62. }, {
  63. text: '物料规格',
  64. dataIndex: 'pr_spec',
  65. width: 150
  66. }, {
  67. text: '单位',
  68. dataIndex: 'pd_unit',
  69. width: 80
  70. }, {
  71. text: '采购数量',
  72. xtype: 'numbercolumn',
  73. dataIndex: 'qty',
  74. xtype: 'numbercolumn',
  75. width: 110,
  76. renderer : function(v) {
  77. var arr = (v + '.').split('.');
  78. var xr = (new Array(arr[1].length > 3 ? 3 : arr[1].length)).fill('0');
  79. var format = '0.' + xr.join();
  80. return Ext.util.Format.number(v, format);
  81. },
  82. summaryType: 'sum',
  83. summaryRenderer: function(v) {
  84. var arr = (v + '.').split('.');
  85. var xr = (new Array(arr[1].length > 3 ? 3 : arr[1].length)).fill('0');
  86. var format = '0.' + xr.join();
  87. return Ext.util.Format.number(v, format);
  88. }
  89. }, {
  90. text: '单价',
  91. dataIndex: 'pd_orderprice',
  92. xtype: 'numbercolumn',
  93. width: 110
  94. }, {
  95. text: '税率',
  96. dataIndex: 'pd_taxrate',
  97. xtype: 'numbercolumn',
  98. width: 80
  99. }, {
  100. text: '金额',
  101. xtype: 'numbercolumn',
  102. dataIndex: 'pd_total',
  103. xtype: 'numbercolumn',
  104. width: 110,
  105. renderer : function(v) {
  106. var arr = (v + '.').split('.');
  107. var xr = (new Array(arr[1].length > 2 ? 2 : arr[1].length)).fill('0');
  108. var format = '0,000.' + xr.join();
  109. return Ext.util.Format.number(v, format);
  110. },
  111. summaryType: 'sum',
  112. summaryRenderer: function(v) {
  113. var arr = (v + '.').split('.');
  114. var xr = (new Array(arr[1].length > 2 ? 2 : arr[1].length)).fill('0');
  115. var format = '0,000.' + xr.join();
  116. return Ext.util.Format.number(v, format);
  117. }
  118. }, {
  119. text: '不含税单价',
  120. dataIndex: 'pd_netprice',
  121. xtype: 'numbercolumn',
  122. width: 110
  123. }, {
  124. text: '不含税金额',
  125. dataIndex: 'pd_nettotal',
  126. xtype: 'numbercolumn',
  127. width: 110
  128. }, {
  129. text: '备注',
  130. dataIndex: 'pd_remark',
  131. width: 250
  132. }]
  133. });