QueryPanel.js 5.6 KB

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