QueryPanel.js 5.1 KB

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