AccountRegister.js 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. Ext.define('erp.view.fa.gs.AccountRegister',{
  2. extend: 'Ext.Viewport',
  3. layout: 'anchor',
  4. hideBorders: true,
  5. initComponent : function(){
  6. var me = this;
  7. Ext.apply(me, {
  8. items: [{
  9. anchor: '100% 50%',
  10. xtype: 'erpFormPanel',
  11. saveUrl: 'fa/gs/saveAccountRegister.action',
  12. deleteUrl: 'fa/gs/deleteAccountRegister.action',
  13. updateUrl: 'fa/gs/updateAccountRegister.action',
  14. submitUrl: 'fa/gs/submitAccountRegister.action',
  15. resSubmitUrl: 'fa/gs/resSubmitAccountRegister.action',
  16. printUrl: 'fa/gs/printAccountRegister.action',
  17. accountedUrl: 'fa/gs/accountAccountRegister.action',
  18. resAccountedUrl: 'fa/gs/resAccountAccountRegister.action',
  19. getIdUrl: 'common/getId.action?seq=ACCOUNTREGISTER_SEQ',
  20. keyField: 'ar_id',
  21. statusField: 'ar_statuscode',
  22. codeField: 'ar_code',
  23. assCaller:'AccountRegisterAss',
  24. voucherConfig: {
  25. voucherField: 'ar_vouchercode',
  26. vs_code: 'AccountRegiste',
  27. yearmonth: 'ar_date',
  28. datas: 'ar_code',
  29. status: 'ar_statuscode',
  30. mode: 'single',
  31. kind: function(form){
  32. var f = form.down('#ar_type');
  33. return f ? f.getValue() : null;
  34. },
  35. vomode: 'CB'
  36. }
  37. },{
  38. anchor: '100% 50%',
  39. xtype: 'erpGridPanel2',
  40. autoSetSequence: true,
  41. isEmptyRecord: function(data) { // 判断明细单行数据是否有效
  42. return Ext.isEmpty(data.ard_catecode) && data.ard_debit == 0 && data.ard_credit == 0;
  43. }
  44. }]
  45. });
  46. me.callParent(arguments);
  47. }
  48. });