FormPanelController.js 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. Ext.define('saas.view.money.othreceipts.FormPanelController', {
  2. extend: 'saas.view.core.form.FormPanelController',
  3. alias: 'controller.money-othreceipts-formpanel',
  4. init: function (form) {
  5. var me = this;
  6. this.control({
  7. //放大镜赋值关系 以及 tpl模板
  8. 'dbfindtrigger[name=or_custname]':{
  9. beforerender:function(f){
  10. Ext.apply(f,{
  11. dataUrl:basePath+'document/customer/list',
  12. dbfinds:[{
  13. from:'id',to:'or_custid'
  14. },{
  15. from:'cu_code',to:'or_custcode'
  16. },{
  17. from:'cu_name',to:'or_custname'
  18. }],
  19. dbtpls:[{
  20. field:'cu_code',width:100
  21. },{
  22. field:'cu_name',width:100
  23. }],
  24. dbColumns:[{
  25. "text": "客户ID",
  26. "flex": 0,
  27. "dataIndex": "id",
  28. "width": 100,
  29. "xtype": ""
  30. },{
  31. "text": "客户编号",
  32. "flex": 1,
  33. "dataIndex": "cu_code",
  34. "width": 100,
  35. "xtype": ""
  36. }, {
  37. "text": "客户名称",
  38. "flex": 1,
  39. "dataIndex": "cu_name",
  40. "xtype": ""
  41. }, {
  42. "text": "客户类型",
  43. "flex": 0,
  44. "dataIndex": "cu_type",
  45. "width": 200,
  46. "xtype": ""
  47. }]
  48. }) ;
  49. }
  50. },
  51. //放大镜赋值关系 以及 tpl模板
  52. 'dbfindtrigger[name=or_bankname]':{
  53. beforerender:function(f){
  54. Ext.apply(f,{
  55. dataUrl:basePath+'document/bankinformation/list',
  56. dbfinds:[{
  57. from:'bk_bankcode',to:'or_bankcode'
  58. },{
  59. from:'bk_bankname',to:'or_bankname'
  60. },{
  61. from:'id',to:'or_bankid'
  62. }],
  63. dbtpls:[{
  64. field:'bk_bankcode',width:100
  65. },{
  66. field:'bk_bankname',width:100
  67. }],
  68. dbColumns:[{
  69. "text": "账户ID",
  70. "flex": 0,
  71. "dataIndex": "id",
  72. "width": 0,
  73. "xtype": ""
  74. },{
  75. "text": "账户编号",
  76. "flex": 1,
  77. "dataIndex": "bk_bankcode",
  78. "width": 100,
  79. "xtype": ""
  80. }, {
  81. "text": "账户名称",
  82. "flex": 1,
  83. "dataIndex": "bk_bankname",
  84. "xtype": ""
  85. }, {
  86. "text": "账户类型",
  87. "flex": 0,
  88. "dataIndex": "bk_type",
  89. "width": 200,
  90. "xtype": ""
  91. }]
  92. }) ;
  93. }
  94. }
  95. });
  96. }
  97. });