BasePanel.js 2.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. Ext.define('saas.view.document.customer.BasePanel', {
  2. extend: 'saas.view.core.base.BasePanel',
  3. xtype: 'document-customer-basepanel',
  4. controller: 'document-customer-basepanel',
  5. viewModel: 'document-customer-basepanel',
  6. searchField:[{
  7. editable:false,
  8. hiddenBtn:true,
  9. xtype : "remotecombo",
  10. storeUrl:'/api/document/customerkind/getCombo',
  11. name : "cu_type",
  12. emptyText : "请选择客户类型",
  13. columnWidth : 0.25
  14. },{
  15. xtype : "textfield",
  16. name : "cu_name",
  17. emptyText : "客户名称",
  18. columnWidth : 0.25,
  19. },{
  20. xtype : "textfield",
  21. name : "cu_code",
  22. emptyText : "客户编号",
  23. columnWidth : 0.25,
  24. },{
  25. labelAlign:'left',
  26. fieldLabel : "显示不启用",
  27. xtype:"checkbox",
  28. name:"cu_statuscode"
  29. }],
  30. //字段属性
  31. _formXtype:'document-customer-formpanel',
  32. _title:'客户资料',
  33. _deleteUrl:'/api/document/customer/delete/',
  34. // _dataUrl:'/api/ducument/customer/list',
  35. _batchOpenUrl:'/api/document/customer/batchOpen',
  36. _batchCloseUrl:'/api/document/customer/batchClose',
  37. _batchDeleteUrl:'/api/document/customer/batchDelete',
  38. gridConfig: {
  39. idField: 'id',
  40. codeField: 'cu_code',
  41. statusCodeField:'cu_statuscode',
  42. dataUrl: '/api/document/customer/list',
  43. columns : [{
  44. text : "客户id",
  45. width : 0,
  46. dataIndex : "id",
  47. xtype : "numbercolumn",
  48. },{
  49. text : "客户编号",
  50. width : 200.0,
  51. dataIndex : "cu_code",
  52. },
  53. {
  54. text : "客户名称",
  55. dataIndex : "cu_name",
  56. width : 120.0,
  57. },
  58. {
  59. text : "客户状态",
  60. dataIndex : "cu_status",
  61. width : 120.0,
  62. },
  63. {
  64. text : "客户状态码",
  65. dataIndex : "cu_statuscode",
  66. width : 0,
  67. },
  68. {
  69. text : "客户UU",
  70. dataIndex : "cu_uu",
  71. width : 120.0,
  72. },
  73. {
  74. text : "客户类型",
  75. dataIndex : "cu_type",
  76. width : 120.0,
  77. },
  78. {
  79. text : "默认客户地址",
  80. dataIndex : "ca_address",
  81. width : 120.0,
  82. },
  83. {
  84. text : "默认客户联系人",
  85. dataIndex : "cc_name",
  86. flex : 1.0,
  87. }]
  88. },
  89. refresh:function(){
  90. this.items.items[0].store.load()
  91. }
  92. });