FormPanel.js 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153
  1. Ext.define('saas.view.money.payBalance.FormPanel', {
  2. extend: 'saas.view.core.form.FormPanel',
  3. xtype: 'money-paybalance-formpanel',
  4. controller: 'money-paybalance-formpanel',
  5. viewModel: 'money-paybalance-formpanel',
  6. viewName: 'money-paybalance-formpanel',
  7. caller: 'Purchase',
  8. //字段属性
  9. _title: '付款单',
  10. _idField: 'id',
  11. _codeField: 'pu_code',
  12. _statusField: 'pu_status',
  13. _statusCodeField: 'pu_statuscode',
  14. _relationColumn: 'pd_puid',
  15. _readUrl: 'http://192.168.0.181:8560/api/purchase/purchase/read/',
  16. _saveUrl: 'http://192.168.0.181:8560/api/purchase/purchase/save',
  17. _auditUrl: 'http://192.168.0.181:8560/api/purchase/purchase/audit',
  18. _deleteUrl: 'http://192.168.0.181:8560/api/purchase/purchase/delete/',
  19. _deleteDetailUrl: 'http://192.168.0.181:8560/api/purchase/purchase/deleteItem/',
  20. _turnInUrl: 'http://192.168.253.228:8800/purchase/turnProdin/',
  21. initId: 0,
  22. // toolBtns: [{
  23. // xtype: 'button',
  24. // text: '转采购验收单',
  25. // handler: 'turnIn'
  26. // }],
  27. defaultItems: [{
  28. xtype: 'hidden',
  29. name: 'id',
  30. fieldLabel: 'id'
  31. }, {
  32. xtype: "textfield",
  33. name: "pb_code",
  34. fieldLabel: "付款单号"
  35. }, {
  36. xtype: "hidden",
  37. name: "pb_vendid",
  38. bind: "{pb_vendid}",
  39. fieldLabel: "供应商ID"
  40. }, {
  41. xtype: "hidden",
  42. name: "pb_vendcode",
  43. fieldLabel: "供应商编号"
  44. }, {
  45. xtype: "dbfindtrigger",
  46. name: "pb_vendname",
  47. fieldLabel: "供应商名称"
  48. }, {
  49. xtype: 'numberfield',
  50. name: 'pb_pdamount',
  51. fieldLabel: '总欠款'
  52. }, {
  53. xtype: "datefield",
  54. name: "pb_date",
  55. fieldLabel: "日期"
  56. }, {
  57. xtype: "detailGridField",
  58. storeModel: 'saas.model.purchase.purchasedetail',
  59. _detnoColumn: 'pd_detno',
  60. columns: [{
  61. text: "序号",
  62. dataIndex: "pd_detno",
  63. width: 100,
  64. xtype: "numbercolumn",
  65. align: 'center',
  66. format: '0',
  67. summaryType: 'count',
  68. summaryRenderer: function (value, summaryData, dataIndex) {
  69. return Ext.String.format('合计: {0}条', value);
  70. },
  71. }, {
  72. text: '资金账户',
  73. dataIndex: 'pd_bankname'
  74. }, {
  75. text: "付款金额",
  76. dataIndex: "pd_amount",
  77. }, {
  78. text: "结算方式",
  79. dataIndex: "pd_paymethod"
  80. }, {
  81. text: "结算号",
  82. dataIndex: "pd_paycode"
  83. }, {
  84. text: "备注",
  85. dataIndex: "pd_remark"
  86. }]
  87. }, {
  88. xtype: "detailGridField",
  89. storeModel: 'saas.model.purchase.purchasedetail',
  90. _detnoColumn: 'pbd_detno',
  91. columns: [{
  92. text: "序号",
  93. dataIndex: "pbd_detno",
  94. width: 100,
  95. xtype: "numbercolumn",
  96. align: 'center',
  97. format: '0',
  98. summaryType: 'count',
  99. summaryRenderer: function (value, summaryData, dataIndex) {
  100. return Ext.String.format('合计: {0}条', value);
  101. },
  102. }, {
  103. text: '来源单号',
  104. dataIndex: 'pbd_slcode'
  105. }, {
  106. text: "业务类型",
  107. dataIndex: "pbd_slkind",
  108. }, {
  109. text: "单据日期",
  110. dataIndex: "pbd_sldate"
  111. }, {
  112. text: "单据金额",
  113. dataIndex: "pbd_amount"
  114. }, {
  115. text: "已核销金额",
  116. dataIndex: "pd_remark"
  117. }, {
  118. text: "未核销金额",
  119. dataIndex: "pd_remark"
  120. }, {
  121. text: "本次核销金额",
  122. dataIndex: "pbd_nowbalance"
  123. }]
  124. }, {
  125. format: "Y-m-d",
  126. xtype: "datefield",
  127. name: "createTime",
  128. fieldLabel: "创建时间"
  129. }, {
  130. xtype: "datefield",
  131. name: "updateTime",
  132. fieldLabel: "更新时间"
  133. }, {
  134. xtype: "textfield",
  135. readOnly: true,
  136. editable: false,
  137. name: "pd_status",
  138. fieldLabel: "单据状态"
  139. }, {
  140. xtype: "hidden",
  141. readOnly: true,
  142. editable: false,
  143. name: "pd_statuscode",
  144. fieldLabel: "单据状态码"
  145. }]
  146. });