QueryPanel.js 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207
  1. Ext.define('saas.view.purchase.purchaseOut.QueryPanel', {
  2. extend: 'saas.view.core.query.QueryPanel',
  3. xtype: 'purchase-purchaseout-querypanel',
  4. controller: 'purchase-purchaseout-querypanel',
  5. viewModel: 'purchase-purchaseout-querypanel',
  6. viewName: 'purchase-purchaseout-querypanel',
  7. queryFormItems: [{
  8. xtype: 'hidden',
  9. name: 'id',
  10. fieldLabel: 'ID',
  11. allowBlank: true,
  12. columnWidth: 0
  13. }, {
  14. xtype: 'textfield',
  15. name: 'pi_inoutno',
  16. fieldLabel: '单据编号',
  17. allowBlank: true,
  18. columnWidth: 0.25
  19. }, {
  20. xtype: 'condatefield',
  21. name: 'pi_date',
  22. fieldLabel: '单据日期',
  23. allowBlank: true,
  24. columnWidth: 0.5
  25. }, {
  26. xtype: 'textfield',
  27. name: 'pi_vendcode',
  28. fieldLabel: '供应商编号',
  29. allowBlank: true,
  30. hidden:true,
  31. columnWidth: 0.25
  32. },{
  33. xtype: 'textfield',
  34. name: 'pi_vendcode',
  35. fieldLabel: '供应商编号',
  36. allowBlank: true,
  37. hidden:true,
  38. columnWidth: 0.25
  39. }, {
  40. xtype: 'dbfindtrigger',
  41. name: 'pi_vendname',
  42. fieldLabel: '供应商名称',
  43. emptyText:'输入供应商编号或名称',
  44. allowBlank: true,
  45. columnWidth: 0.25
  46. }, {
  47. xtype: 'dbfindtrigger',
  48. name: 'pd_prodcode',
  49. fieldLabel: '物料编号',
  50. hidden:true,
  51. showDetail: true
  52. }, {
  53. xtype: 'dbfindtrigger',
  54. name: 'pr_detail',
  55. fieldLabel: '物料名称',
  56. emptyText:'输入物料编号或名称',
  57. showDetail: true
  58. }, {
  59. xtype: 'combobox',
  60. name: 'pi_statuscode',
  61. fieldLabel: '审核状态',
  62. allowBlank: true,
  63. emptyText :'全部',
  64. editable:false,
  65. columnWidth: 0.25,
  66. queryMode: 'local',
  67. displayField: 'pi_status',
  68. valueField: 'pi_statuscode',
  69. store: Ext.create('Ext.data.ArrayStore', {
  70. fields: ['pi_statuscode', 'pi_status'],
  71. data: [
  72. ["ALL", "全部"],
  73. ["AUDITED", "已审核"],
  74. ["UNAUDITED", "未审核"]
  75. ]
  76. }),
  77. getCondition: function(value) {
  78. if(value == 'ALL') {
  79. return '1=1';
  80. }else {
  81. return 'pi_statuscode=\'' + value + '\'';
  82. }
  83. }
  84. }],
  85. queryGridConfig: {
  86. idField:'id',
  87. codeField:'pi_inoutno',
  88. addTitle:'采购验退单',
  89. addXtype:'purchase-purchaseout-formpanel',
  90. defaultCondition:' pi_class = \'采购验退单\'',
  91. baseVastUrl:'/api/purchase/prodinout/',
  92. // baseVastUrl:"http://localhost:8800/prodinout/",
  93. baseColumn: [{
  94. text: 'id',
  95. dataIndex: 'id',
  96. hidden:true,
  97. xtype: 'numbercolumn'
  98. }, {
  99. text: '单据编号',
  100. dataIndex: 'pi_inoutno',
  101. width: 200
  102. },{
  103. text: '单据类型',
  104. dataIndex: 'pi_class',
  105. width: 120
  106. },{
  107. text: '单据日期',
  108. dataIndex: 'pi_date',
  109. xtype:'datecolumn',
  110. width: 200
  111. },{
  112. text: '审核状态',
  113. dataIndex: 'pi_status',
  114. width: 120
  115. },{
  116. text: '供应商名称',
  117. dataIndex: 'pi_vendname',
  118. width: 120
  119. },{
  120. text: '制单人',
  121. dataIndex: 'pi_recordman',
  122. width: 120
  123. },{
  124. text: '审核人',
  125. dataIndex: 'pi_auditman',
  126. width: 120
  127. },{
  128. text: '备注',
  129. dataIndex: 'pi_remark',
  130. width: 200
  131. }],
  132. relativeColumn: [{
  133. text: 'id',
  134. dataIndex: 'pu_id',
  135. xtype: 'numbercolumn',
  136. hidden:true
  137. }, {
  138. text: '单据编号',
  139. dataIndex: 'pi_inoutno',
  140. width: 200
  141. }, {
  142. text: '单据类型',
  143. dataIndex: 'pd_piclass',
  144. width: 200
  145. },{
  146. text: '审核状态',
  147. dataIndex: 'pi_status',
  148. width: 120
  149. },{
  150. text: '供应商编号',
  151. dataIndex: 'pi_vendcode',
  152. width: 120
  153. },{
  154. text: '供应商名称',
  155. dataIndex: 'pi_vendname',
  156. width: 120
  157. },{
  158. text: '物料编号',
  159. dataIndex: 'pd_prodcode',
  160. width: 120
  161. },{
  162. text: '物料名称',
  163. dataIndex: 'pr_detail',
  164. width: 120
  165. },{
  166. text: '物料规格',
  167. dataIndex: 'pr_spec',
  168. width: 120
  169. },{
  170. text: '单位',
  171. dataIndex: 'pr_unit',
  172. width: 120
  173. },{
  174. text: '数量',
  175. dataIndex: 'pd_inqty',
  176. xtype:'numbercolumn',
  177. width: 120
  178. },{
  179. text: '仓库',
  180. dataIndex: 'pd_whname',
  181. width: 120
  182. },{
  183. text: '单位成本',
  184. dataIndex: 'pd_orderprice',
  185. xtype:'numbercolumn',
  186. width: 120
  187. },{
  188. text: '税率',
  189. dataIndex: 'pd_taxrate',
  190. xtype:'numbercolumn',
  191. width: 120
  192. },{
  193. text: '金额',
  194. dataIndex: 'pd_total',
  195. xtype:'numbercolumn',
  196. width: 120
  197. },{
  198. text: '相关单号',
  199. dataIndex: 'pd_ordercode',
  200. xtype:'numbercolumn',
  201. width: 120
  202. }]
  203. }
  204. });