BasePanelController.js 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. Ext.define('saas.view.document.customer.BasePanelController', {
  2. extend: 'saas.view.core.base.BasePanelController',
  3. alias: 'controller.document-customer-basepanel',
  4. init: function (form) {
  5. var me = this;
  6. this.control({
  7. // 主表-客户编号
  8. 'customerDbfindTrigger[name=cu_code]':{
  9. beforerender:function(f){
  10. Ext.apply(f,{
  11. //赋值
  12. dbfinds:[{
  13. from:'id',to:'cu_id',ignore:true
  14. },{
  15. from:'cu_code',to:'cu_code'
  16. },{
  17. from:'cu_name',to:'cu_name'
  18. },{
  19. from:'cu_sellername',to:'cu_sellername'
  20. },{
  21. from:'cu_promisedays',to:'cu_promisedays'
  22. },{
  23. from:'cu_credit',to:'cu_credit'
  24. },{
  25. from:'cu_statuscode',to:'cu_statuscode'
  26. }],
  27. }) ;
  28. }
  29. },'employeeDbfindTrigger[name=cu_sellername]':{
  30. beforerender:function(f){
  31. Ext.apply(f,{
  32. dbfinds:[{
  33. from:'em_name',to:'cu_sellername'
  34. }],
  35. }) ;
  36. }
  37. }
  38. });
  39. }
  40. });