MainNav.js 834 B

1234567891011121314151617181920212223242526272829303132
  1. Ext.define('uas.main.MainNav', {
  2. extend: 'Ext.panel.Panel',
  3. xtype: 'mainnav',
  4. items: [{
  5. xtype: 'listview',
  6. reference: 'domainList',
  7. displayField: 'text',
  8. valueField: 'code',
  9. style: 'border-width: 0 1px 0 0',
  10. width: 120,
  11. height: '100%'
  12. }, {
  13. xtype: 'listview',
  14. reference: 'moduleList',
  15. displayField: 'text',
  16. valueField: 'code',
  17. style: 'border-width: 0 1px 0 0',
  18. width: 120,
  19. height: '100%'
  20. }],
  21. setDomain: function(data) {
  22. var domainList = this.getController().lookup('domainList');
  23. domainList.getStore().loadData(data);
  24. },
  25. setModule: function(data) {
  26. var moduleList = this.getController().lookup('moduleList');
  27. moduleList.getStore().loadData(data);
  28. }
  29. });