QueryPanel.js 7.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256
  1. Ext.define('saas.view.purchase.purchaseIn.QueryPanel', {
  2. extend: 'saas.view.core.query.QueryPanel',
  3. xtype: 'purchase-purchaseIn-querypanel',
  4. controller: 'purchase-purchaseIn-queryformcontroller',
  5. viewModel: 'purchase-purchaseIn-queryformmodel',
  6. _baseVastUrl:'http://192.168.253.58:8800/purchase/',
  7. _idField:'pi_id',
  8. _codeField:'pi_inoutno',
  9. queryFormItems: [{
  10. xtype: 'hidden',
  11. name: 'pi_id',
  12. bind: '{pi_id}',
  13. fieldLabel: 'ID',
  14. allowBlank: true,
  15. columnWidth: 0
  16. }, {
  17. xtype: 'dbfindtrigger',
  18. name: 'pi_inoutno',
  19. bind: '{pi_inoutno}',
  20. fieldLabel: '单据编号',
  21. allowBlank: true,
  22. columnWidth: 0.25,
  23. dataUrl:'http://192.168.253.41:9480/api/document/vendor/getVendorsByCondition',
  24. dbfinds:[{
  25. from:'ve_code',to:'pu_code'
  26. }],
  27. dbColumns:[{
  28. conditionCode:'ve_id',
  29. "text": "供应商ID",
  30. "flex": 0,
  31. "dataIndex": "ve_id",
  32. "width": 0,
  33. "xtype": "",
  34. "items": null
  35. },{
  36. conditionCode:'ve_code',
  37. "text": "供应商编号",
  38. "flex": 1,
  39. "dataIndex": "ve_code",
  40. "width": 100,
  41. "xtype": "",
  42. "items": null
  43. }, {
  44. conditionCode:'ve_name',
  45. "text": "供应商名称",
  46. "flex": 1,
  47. "dataIndex": "ve_name",
  48. "xtype": "",
  49. "items": null
  50. }, {
  51. conditionCode:'ve_type',
  52. "text": "供应商类型",
  53. "flex": 0,
  54. "dataIndex": "ve_type",
  55. "width": 200,
  56. "xtype": "",
  57. "items": null
  58. }]
  59. }, {
  60. xtype: 'condatefield',
  61. name: 'pu_date',
  62. bind: '{pu_date}',
  63. fieldLabel: '采购日期',
  64. allowBlank: true,
  65. columnWidth: 0.5
  66. }, {
  67. xtype: 'dbfindtrigger',
  68. name: 'pu_vendcode',
  69. bind: '{pu_vendcode}',
  70. fieldLabel: '供应商编号',
  71. allowBlank: true,
  72. columnWidth: 0.25,
  73. configUrl: 'resources/json/purchase/vendorColumnsDbfind.json',
  74. dataUrl: 'resources/json/purchase/vendorDataDbfind.json'
  75. }, {
  76. xtype: 'textfield',
  77. name: 'pu_vendname',
  78. bind: '{pu_vendname}',
  79. fieldLabel: '供应商名称',
  80. allowBlank: true,
  81. columnWidth: 0.25
  82. }, {
  83. xtype: 'dbfindtrigger',
  84. name: 'pd_prodcode#pd_prodcode',
  85. bind: '{pd_prodcode}',
  86. fieldLabel: '物料编号',
  87. fieldMode: 'DETAIL',
  88. queryType:'VAG',
  89. allowBlank: true,
  90. columnWidth: 0.25,
  91. configUrl: 'resources/json/purchase/vendorColumnsDbfind.json',
  92. dataUrl: 'resources/json/purchase/vendorDataDbfind.json'
  93. }, {
  94. xtype: 'textfield',
  95. name: 'pr_detail',
  96. bind: '{pr_detail}',
  97. fieldLabel: '物料名称',
  98. allowBlank: true,
  99. columnWidth: 0.25
  100. }, {
  101. xtype: 'combobox',
  102. name: 'pr_statuscode',
  103. // bind: '{pr_statuscode}',
  104. fieldLabel: '审核状态',
  105. allowBlank: true,
  106. columnWidth: 0.25,
  107. queryMode: 'local',
  108. displayField: 'pr_status',
  109. valueField: 'pr_statuscode',
  110. store: Ext.create('Ext.data.ArrayStore', {
  111. fields: ['pr_statuscode', 'pr_status'],
  112. data: [
  113. ["$ALL", "全部"],
  114. ["AUDITED", "已审核"],
  115. ["UNAUDITED", "未审核"]
  116. ]
  117. })
  118. }, {
  119. xtype: 'combobox',
  120. name: 'pu_acceptstatuscode',
  121. bind: '{pu_acceptstatuscode}',
  122. fieldLabel: '入库状态',
  123. allowBlank: true,
  124. columnWidth: 0.25,
  125. queryMode: 'local',
  126. displayField: 'pu_acceptstatus',
  127. valueField: 'pu_acceptstatuscode',
  128. store: Ext.create('Ext.data.ArrayStore', {
  129. fields: ['pu_acceptstatuscode', 'pu_acceptstatus'],
  130. data: [
  131. ["$ALL", "全部"],
  132. ["TURNOUT", "已入库"],
  133. ["NOOUT", "未入库"],
  134. ["PARTOUT", "部分入库"]
  135. ]
  136. })
  137. }],
  138. moreQueryFormItems: [{
  139. xtype: 'textfield',
  140. name: 'pu_buyername',
  141. bind: '{pu_buyername}',
  142. fieldLabel: '采购员',
  143. allowBlank: true
  144. }, {
  145. xtype: 'textfield',
  146. name: 'pu_total',
  147. bind: '{pu_total}',
  148. fieldLabel: '金额',
  149. allowBlank: true
  150. }, {
  151. xtype: 'condatefield',
  152. name: 'pu_delivery',
  153. bind: '{pu_delivery}',
  154. fieldLabel: '交货日期',
  155. allowBlank: true,
  156. columnWidth: 1
  157. }],
  158. queryGridConfig: {
  159. _idField:'pu_id',
  160. _codeField:'pu_code',
  161. _title:'采购单',
  162. _addXtype:'test-order-formpanel',
  163. _baseVastUrl:'http://192.168.253.58:8800/purchase/',
  164. _baseColumn: [{
  165. text: '序号',
  166. width: 80,
  167. xtype: 'rownumberer'
  168. }, {
  169. text: 'id',
  170. dataIndex: 'pu_id',
  171. width: 100,
  172. xtype: 'numbercolumn'
  173. }, {
  174. text: '单据编号',
  175. dataIndex: 'pu_code',
  176. width: 120
  177. }, {
  178. text: '单据状态',
  179. dataIndex: 'pu_status',
  180. width: 120
  181. }, {
  182. text: '下单日期',
  183. dataIndex: 'pu_indate',
  184. xtype:'datecolumn',
  185. width: 200
  186. },{
  187. text: '供应商名称',
  188. dataIndex: 'pu_vendname',
  189. width: 120
  190. },{
  191. text: '含税金额',
  192. dataIndex: 'pu_taxtotal',
  193. xtype:'numbercolumn',
  194. width: 120
  195. },{
  196. text: '金额',
  197. dataIndex: 'pu_total',
  198. xtype:'numbercolumn',
  199. width: 120,
  200. flex: 1
  201. }],
  202. _relativeColumn: [{
  203. text: '序号',
  204. width: 80,
  205. xtype: 'rownumberer'
  206. }, {
  207. text: 'id',
  208. dataIndex: 'pu_id',
  209. width: 100,
  210. xtype: 'numbercolumn'
  211. }, {
  212. text: '单据编号',
  213. dataIndex: 'pu_code',
  214. width: 120
  215. }, {
  216. text: '单据状态',
  217. dataIndex: 'pu_status',
  218. width: 120
  219. }, {
  220. text: '下单日期',
  221. dataIndex: 'pu_indate',
  222. xtype:'datecolumn',
  223. width: 200
  224. },{
  225. text: '供应商名称',
  226. dataIndex: 'pu_vendname',
  227. width: 120
  228. },{
  229. text: '采购序号',
  230. dataIndex: 'pd_detno',
  231. xtype:'numbercolumn',
  232. width: 120
  233. },{
  234. text: '物料编号',
  235. dataIndex: 'pd_prodcode',
  236. width: 120
  237. },{
  238. text: '数量',
  239. dataIndex: 'pd_qty',
  240. xtype:'numbercolumn',
  241. width: 120
  242. },{
  243. text: '单价',
  244. dataIndex: 'pd_price',
  245. xtype:'numbercolumn',
  246. width: 120
  247. },{
  248. text: '已转数',
  249. dataIndex: 'pd_ytqy',
  250. xtype:'numbercolumn',
  251. width: 120,
  252. flex: 1
  253. }]
  254. }
  255. });