FormPanel.js 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166
  1. Ext.define('saas.view.test.query.FormPanel', {
  2. extend: 'saas.view.core.query.FormPanel',
  3. xtype: 'test-query-formpanel',
  4. controller: 'test-query-formcontroller',
  5. viewModel: 'test-query-formmodel',
  6. viewName:'test-query-formpanel',
  7. //字段属性
  8. _codeField: 'pu_code',
  9. _statusField: 'pu_statuscode',
  10. _idField: 'pu_id',
  11. items:[{
  12. xtype: 'core-query-queryformpanel',
  13. //_baseItems
  14. items:[
  15. {
  16. xtype: 'hidden',
  17. name: 'pu_id',
  18. bind:'{pu_id}',
  19. fieldLabel: 'ID',
  20. allowBlank: true,
  21. columnWidth: 0
  22. },
  23. {
  24. xtype: 'dbfindtrigger',
  25. name: 'pu_code',
  26. bind:'{pu_code}',
  27. fieldLabel: '单据编号',
  28. allowBlank: true,
  29. columnWidth: 0.25,
  30. configUrl: resources/json/purchase/vendorColumnsDbfind.json,
  31. dataUrl: resources/json/purchase/vendorDataDbfind.json
  32. },
  33. {
  34. xtype: 'condatefield',
  35. name: 'pu_date',
  36. bind: '{pu_date}',
  37. fieldLabel: '采购日期',
  38. allowBlank: true,
  39. columnWidth: 0.5
  40. },
  41. {
  42. xtype: 'dbfindtrigger',
  43. name: 'pu_vendcode',
  44. bind: '{pu_vendcode}',
  45. fieldLabel: '供应商编号',
  46. allowBlank: true,
  47. columnWidth: 0.25,
  48. configUrl: resources/json/purchase/vendorColumnsDbfind.json,
  49. dataUrl: resources/json/purchase/vendorDataDbfind.json
  50. },
  51. {
  52. xtype: 'textfield',
  53. name: 'pu_vendname',
  54. bind: '{pu_vendname}',
  55. fieldLabel: '供应商名称',
  56. allowBlank: true,
  57. columnWidth: 0.25
  58. },
  59. {
  60. xtype: 'dbfindtrigger',
  61. name: 'pd_prodcode',
  62. bind: '{pd_prodcode}',
  63. fieldLabel: '物料编号',
  64. fieldMode: 'DETAIL',
  65. allowBlank: true,
  66. columnWidth: 0.25,
  67. configUrl: resources/json/purchase/vendorColumnsDbfind.json,
  68. dataUrl: resources/json/purchase/vendorDataDbfind.json
  69. },
  70. {
  71. xtype: 'textfield',
  72. name: 'pr_detail',
  73. bind: '{pr_detail}',
  74. fieldLabel: '物料名称',
  75. allowBlank: true,
  76. columnWidth: 0.25
  77. },
  78. {
  79. xtype: 'remotecombo',
  80. name:'pr_statuscode',
  81. bind: '{pr_statuscode}',
  82. fieldLabel: '审核状态',
  83. allowBlank: true,
  84. columnWidth: 0.25,
  85. store: Ext.create('Ext.data.Store', {
  86. fields: ['pr_statuscode', 'pr_status'],
  87. queryMode: 'local',
  88. displayField: 'pr_status',
  89. valueField: 'pr_statuscode',
  90. data :[
  91. ["$ALL","全部"],
  92. ["=AUDITED" ,"已审核"],
  93. ["<>AUDITED","未审核"]
  94. ]
  95. })
  96. },
  97. {
  98. xtype: 'remotecombo',
  99. name: 'pu_acceptstatuscode',
  100. bind: '{pu_acceptstatuscode}',
  101. fieldLabel: '入库状态',
  102. allowBlank: true,
  103. columnWidth: 0.25,
  104. store: Ext.create('Ext.data.Store', {
  105. fields: ['pu_acceptstatuscode', 'pu_acceptstatus'],
  106. queryMode: 'local',
  107. displayField: 'pu_acceptstatus',
  108. valueField: 'pu_acceptstatuscode',
  109. data :[
  110. ["$ALL","全部"],
  111. ["=TURNOUT","已入库"],
  112. ["=NULL","未入库"],
  113. ["=PARTOUT","部分入库"]
  114. ]
  115. })
  116. }
  117. ]
  118. },{
  119. xtype: 'core-query-gridpanel',
  120. columns: [
  121. {
  122. text: '序号',
  123. width: 80,
  124. xtype: rownumberer
  125. },
  126. {
  127. text: 'id',
  128. dataIndex: 'pu_id',
  129. width: 100,
  130. xtype: 'numbercolumn'
  131. },
  132. {
  133. text: '单据编号',
  134. dataIndex: 'pu_code',
  135. width: 120
  136. },
  137. {
  138. text: '单据状态',
  139. dataIndex: 'pu_status',
  140. width: 120
  141. }
  142. //,
  143. // {
  144. // text: 下单时间,
  145. // dataIndex: puDate,
  146. // width: 120,
  147. // xtype: datecolumn
  148. // },
  149. // {
  150. // text: 供应商名称,
  151. // dataIndex: puVendname,
  152. // width: 200
  153. // },
  154. // {
  155. // text: 含税金额,
  156. // dataIndex: puTaxtotal,
  157. // width: 120,
  158. // xtype: numbercolumn,
  159. // flex: 1
  160. // }
  161. ]
  162. }]
  163. });