FormPanel.js 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159
  1. Ext.define('saas.view.money.othreceipts.FormPanel', {
  2. extend: 'saas.view.core.form.FormPanel',
  3. xtype: 'money-othreceipts-formpanel',
  4. controller: 'money-othreceipts-formpanel',
  5. viewModel: 'money-othreceipts-formpanel',
  6. viewName: 'money-othreceipts-formpanel',
  7. caller:'OthReceipts',
  8. //字段属性
  9. _title:'其它收入单',
  10. _idField: 'id',
  11. _codeField: 'or_code',
  12. _statusField: 'or_status',
  13. _statusCodeField: 'or_statuscode',
  14. _relationColumn: 'ord_orid',
  15. _readUrl:'/api/money/othreceipts/read/',
  16. _saveUrl:'/api/money/othreceipts/save/',
  17. _auditUrl:'/api/money/othreceipts/audit/',
  18. _unAuditUrl: '/api/money/othreceipts/unAudit/',
  19. _deleteUrl:'/api/money/othreceipts/delete/',
  20. initId:0,
  21. defaultItems: [{
  22. xtype: 'hidden',
  23. name: 'id',
  24. fieldLabel: 'id'
  25. }, {
  26. xtype : 'hidden',
  27. name : 'or_custid',
  28. fieldLabel : '客户ID'
  29. }, {
  30. xtype : 'hidden',
  31. name : 'or_custcode',
  32. fieldLabel : '客户编号'
  33. }, {
  34. xtype : "dbfindtrigger",
  35. name : "or_custname",
  36. fieldLabel : "客户名称"
  37. }, {
  38. xtype : 'hidden',
  39. name : 'or_bankid',
  40. fieldLabel : '账户ID'
  41. }, {
  42. xtype : 'hidden',
  43. name : 'or_bankcode',
  44. fieldLabel : '账户编号'
  45. }, {
  46. xtype : "dbfindtrigger",
  47. name : "or_bankname",
  48. fieldLabel : "账户名称"
  49. }, {
  50. name : "detailGridField",
  51. xtype : "detailGridField",
  52. storeModel:'saas.model.money.Othreceipts',
  53. detnoColumn: 'ord_detno',
  54. deleteDetailUrl:'/api/money/othreceipts/deleteDetail/',
  55. columnWidth : 1,
  56. columns : [
  57. {
  58. text : "id",
  59. dataIndex : "id",
  60. xtype : "numbercolumn",
  61. width:0
  62. }, {
  63. text : "期间",
  64. dataIndex : "ord_ym",
  65. editor : {
  66. xtype : "numberfield"
  67. },
  68. width : 120.0,
  69. xtype : "numbercolumn",
  70. items : null
  71. }, {
  72. text : "收入类别",
  73. width : 200.0,
  74. dataIndex : "ord_type",
  75. xtype : "",
  76. items : null,
  77. editor : {
  78. xtype : "remotecombo",
  79. storeUrl:'/api/document/inoutkind/getCombo',
  80. addHandler:function(b){
  81. var document = Ext.create('saas.view.document.kind.Kind',{});
  82. var form =this.ownerCmp.ownerCt.ownerCmp.ownerCt;
  83. this.dialog = form.getController().getView().add({
  84. xtype: 'document-kind-childwin',
  85. bind: {
  86. title: '新增收入类别类型'
  87. },
  88. dataKind:'inoutkind',
  89. belong:document.etc['inoutkind'],
  90. _parent:form,
  91. _combo:this.ownerCmp,
  92. record:null,
  93. session: true
  94. });
  95. this.dialog.show();
  96. }
  97. }
  98. }, {
  99. text : "金额",
  100. dataIndex : "ord_nowbalance",
  101. editor : {
  102. xtype : "numberfield"
  103. },
  104. width : 120.0,
  105. xtype : "numbercolumn",
  106. format:'0',
  107. items : null,
  108. summaryType: 'sum'
  109. }, {
  110. text : "单价",
  111. editor : {
  112. xtype : "numberfield"
  113. },
  114. format:'0,000.00',
  115. dataIndex : "sd_price",
  116. width : 120.0,
  117. xtype : "numbercolumn",
  118. items : null,
  119. summaryType: 'sum'
  120. }, {
  121. text : "备注",
  122. dataIndex : "ord_remark",
  123. width : 120.0,
  124. items : null,
  125. flex : 1.0,
  126. editor : {
  127. xtype : ""
  128. }
  129. }
  130. ]
  131. }, {
  132. xtype : "textfield",
  133. name : "or_amount",
  134. fieldLabel : "收款金额",
  135. readOnly:true
  136. },{
  137. xtype : "textfield",
  138. name : "or_remark",
  139. fieldLabel : "备注",
  140. allowBlank : true,
  141. columnWidth : 0.75
  142. }, {
  143. xtype : "textfield",
  144. name : "or_recorder",
  145. fieldLabel : "录入人",
  146. readOnly:true
  147. }, {
  148. xtype : "datefield",
  149. name : "or_date",
  150. fieldLabel : "录入日期",
  151. readOnly:true
  152. }
  153. ]
  154. });