QueryPanel.js 5.3 KB

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