PurchasePay.js 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108
  1. Ext.define('saas.view.purchase.report.PurchasePay', {
  2. extend: 'saas.view.core.report.ReportPanel',
  3. xtype: 'purchase-report-purchasepay',
  4. controller: 'purchase-report-purchasepay',
  5. viewModel: 'purchase-report-purchasepay',
  6. viewName: 'purchase-report-purchasepay',
  7. //按供应商分组 付款金额合计
  8. groupField: 'pu_vendname',
  9. listUrl: '/api/purchase/report/purchasePay',
  10. defaultCondition: null,
  11. reportTitle: '采购付款一览表',
  12. QueryWidth:0.25,
  13. searchItems: [
  14. {
  15. xtype: 'vendorDbfindTrigger',
  16. name: 'pu_vendname',
  17. fieldLabel: '供应商名称',
  18. columnWidth: 0.25
  19. }, {
  20. xtype: 'condatefield',
  21. name: 'createTime',
  22. fieldLabel: '单据日期',
  23. columnWidth: 0.5
  24. }],
  25. reportColumns: [
  26. {
  27. text: 'id',
  28. dataIndex: 'pb_id',
  29. hidden: true
  30. }, {
  31. text: '付款单号',
  32. dataIndex: 'pb_code',
  33. width: 200
  34. }, {
  35. text: '供应商编号',
  36. dataIndex: 'pu_vendcode',
  37. width: 200
  38. }, {
  39. text: '供应商名称',
  40. dataIndex: 'pu_vendname',
  41. width: 200
  42. }, {
  43. text: '录入人',
  44. dataIndex: 'creatorName',
  45. width: 200
  46. }, {
  47. text : "日期",
  48. dataIndex : "createTime",
  49. xtype:'datecolumn'
  50. }, {
  51. text: '来源单号',
  52. dataIndex: 'pbd_slcode',
  53. width: 200
  54. }, {
  55. text: '类型',
  56. dataIndex: 'pbd_slkind',
  57. width: 200
  58. }, {//∑求和
  59. text: '采购金额',
  60. xtype: 'numbercolumn',
  61. dataIndex: 'pbd_amount',
  62. xtype: 'numbercolumn',
  63. width: 200,
  64. summaryType: 'sum',
  65. summaryRenderer: function(v) {
  66. var arr = (v + '.').split('.');
  67. var xr = (new Array(arr[1].length > 2 ? 2 : arr[1].length)).fill('0');
  68. var format = '0,000.' + xr.join();
  69. return Ext.util.Format.number(v, format);
  70. }
  71. }, {//∑求和
  72. text: '本次付款',
  73. dataIndex: 'pbd_nowbalance',
  74. xtype: 'numbercolumn',
  75. width: 200,
  76. summaryType: 'sum',
  77. summaryRenderer: function(v) {
  78. var arr = (v + '.').split('.');
  79. var xr = (new Array(arr[1].length > 2 ? 2 : arr[1].length)).fill('0');
  80. var format = '0,000.' + xr.join();
  81. return Ext.util.Format.number(v, format);
  82. }
  83. }, {
  84. text: '应付余额',
  85. xtype: 'numbercolumn',
  86. dataIndex: 'pb_pbdamount',
  87. xtype: 'numbercolumn'
  88. }, {
  89. text: '付款比例%',
  90. //本次付款/采购金额*100%
  91. dataIndex: 'pb_payrate',
  92. xtype: 'numbercolumn',
  93. renderer : function(v) {
  94. var arr = (v + '.').split('.');
  95. var xr = (new Array(arr[1].length > 2 ? 2 : arr[1].length)).fill('0');
  96. var format = '0.' + xr.join();
  97. return Ext.util.Format.number(v, format);
  98. }
  99. }, {
  100. text: '备注',
  101. dataIndex: 'pb_remark',
  102. width: 200
  103. }]
  104. });