FormPanelController.js 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. Ext.define('uas.view.form.formpanel.FormPanelController', {
  2. extend: 'Ext.app.ViewController',
  3. alias: 'controller.formpanelcontroller',
  4. init: function (form) {
  5. var me = this;
  6. this.control({
  7. //放大镜赋值关系 以及 tpl模板
  8. 'producttrigger[name=code]':{
  9. beforerender:function(f){
  10. Ext.apply(f, {
  11. dbfinds: [{
  12. from: 'code',
  13. to: 'code',
  14. ignore: true
  15. }, {
  16. from: 'price',
  17. to: 'price'
  18. }],
  19. searchUrl:'/api/searchPlanTree',
  20. dataUrl:'/api/productList',
  21. addTitle: '物料资料',
  22. defaultCondition: "pr_statuscode='ENABLE'",
  23. });
  24. }
  25. },
  26. 'vendormultitrigger[name=vcode]':{
  27. beforerender:function(f){
  28. Ext.apply(f, {
  29. dbfinds: [{
  30. from: 'vcode',
  31. to: 'vcode',
  32. ignore: true
  33. }],
  34. searchUrl:'/api/searchPlanTree',
  35. dataUrl:'/api/productList',
  36. addTitle: '供应商资料',
  37. defaultCondition: "pr_statuscode='ENABLE'",
  38. });
  39. }
  40. }
  41. });
  42. }
  43. });