PayDetailController.js 3.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. Ext.define('saas.view.money.report.PayDetailController', {
  2. extend: 'saas.view.core.report.ReportPanelController',
  3. alias: 'controller.money-report-paydetail',
  4. init: function (form) {
  5. this.control({
  6. // 供应商编号
  7. 'dbfindtrigger[name=pi_vendname]':{
  8. beforerender:function(f){
  9. Ext.apply(f,{
  10. dataUrl:'/api/document/vendor/list',
  11. addXtype: 'document-vendor-formpanel',
  12. addTitle: '供应商资料',
  13. dbfinds:[{
  14. from:'ve_name',to:'pi_vendname'
  15. }],
  16. dbtpls:[{
  17. field:'ve_code',width:100
  18. },{
  19. field:'ve_name',width:100
  20. }],
  21. defaultCondition: "ve_statuscode='OPEN'",
  22. dbSearchFields:[{
  23. emptyText:'输入供应商编号或名称',
  24. xtype : "textfield",
  25. name : "search",
  26. getCondition: function(v) {
  27. return "(upper(ve_code) like '%"+v.toUpperCase()+"%' or upper(ve_name) like '%"+v.toUpperCase()+"%')";
  28. },
  29. allowBlank : true,
  30. columnWidth : 0.25
  31. }],
  32. dbColumns:[
  33. {
  34. "text": "供应商ID",
  35. "hidden": true,
  36. "dataIndex": "id",
  37. "width": 100,
  38. "xtype": "numbercolumn"
  39. },{
  40. "text": "供应商编号",
  41. "dataIndex": "ve_code",
  42. "width": 200
  43. }, {
  44. "text": "供应商名称",
  45. "dataIndex": "ve_name",
  46. "width": 200
  47. }, {
  48. "text": "供应商类型",
  49. "dataIndex": "ve_type",
  50. "width": 180,
  51. "items": null
  52. }, {
  53. "text": "税率",
  54. "dataIndex": "ve_taxrate",
  55. "width": 100,
  56. xtype: 'numbercolumn',
  57. align: 'end'
  58. }, {
  59. "text": "承付天数",
  60. "dataIndex": "ve_promisedays",
  61. "width": 100,
  62. xtype: 'numbercolumn',
  63. align: 'end'
  64. }, {
  65. "text": "纳税人识别号",
  66. "dataIndex": "ve_bankaccount",
  67. "width": 150
  68. }, {
  69. "text": "开户银行",
  70. "dataIndex": "ve_bankaccount",
  71. "width": 100
  72. }, {
  73. "text": "银行账户",
  74. "dataIndex": "ve_bankcode",
  75. "width": 100
  76. }]
  77. }) ;
  78. }
  79. }
  80. });
  81. }
  82. });