CheckCOAccount.js 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. Ext.define('erp.view.co.cost.CheckCOAccount',{
  2. extend: 'Ext.Viewport',
  3. layout: 'anchor',
  4. hideBorders: true,
  5. initComponent : function(){
  6. var me = this;
  7. Ext.apply(me, {
  8. items: [{
  9. xtype: 'grid',
  10. id: 'account-check',
  11. anchor: '100% 100%',
  12. tbar: [{
  13. xtype: 'tbtext',
  14. text: '当前期间:',
  15. margin: '0 0 0 20'
  16. },{
  17. xtype: 'tbtext',
  18. id: 'yearmonth',
  19. text: '201305',
  20. margin: '0 0 0 2'
  21. },'->'],
  22. columns: [{
  23. text: '',
  24. dataIndex: 'check',
  25. flex: 1,
  26. renderer: function(val, meta, record) {
  27. meta.tdCls = val;
  28. return '';
  29. }
  30. },{
  31. text: '检测项',
  32. dataIndex: 'value',
  33. flex: 10,
  34. renderer: function(val, meta, record) {
  35. if(record.get('check') == 'error') {
  36. meta.style = 'color: gray';
  37. }
  38. return val;
  39. }
  40. },{
  41. text: '',
  42. dataIndex: 'link',
  43. flex: 1,
  44. renderer: function(val, meta, record) {
  45. if(record.get('check') == 'error') {
  46. meta.tdCls = 'detail';
  47. return '详细情况';
  48. }
  49. return '';
  50. }
  51. }],
  52. columnLines: true,
  53. store: Ext.create('Ext.data.Store',{
  54. fields: [{name: 'action', type: 'string'}, {name: 'type', type: 'string'}, {name: 'value', type: 'string'}],
  55. data: [{
  56. action: 'co/cost/chk_a.action',
  57. type: 'co_chk_a',
  58. value: '成本表上直接人工的金额与直接人工制造费用维护界面是否一致'
  59. },{
  60. action: 'co/cost/chk_b.action',
  61. type: 'co_chk_b',
  62. value: '成本表上制造费用的金额与直接人工制造费用维护界面是否一致'
  63. },{
  64. action: 'co/cost/chk_c.action',
  65. type: 'co_chk_c',
  66. value: '总账生产成本科目余额与成本表上工单类型是制造单的期末结余金额+期末报废结余金额合计是否一致'
  67. },{
  68. action: 'co/cost/chk_d.action',
  69. type: 'co_chk_d',
  70. value: '总账委托加工物资科目余额与成本表上工单类型是委外加工单的期末结余金额+期末报废结余金额合计是否一致'
  71. }]
  72. }),
  73. bbar: [{
  74. xtype: 'checkbox',
  75. boxLabel: '知道错误了,我要继续结账',
  76. id : 'allow',
  77. hidden : true,
  78. margin: '0 5 0 20'
  79. },'->',{
  80. cls: 'x-btn-blue',
  81. id: 'check',
  82. text: '结账检查',
  83. width: 80,
  84. margin: '0 0 0 50'
  85. },{
  86. cls: 'x-btn-blue',
  87. id: 'accoutover',
  88. text: '结 账',
  89. width: 80,
  90. disabled : true,
  91. margin: '0 0 0 5'
  92. },{
  93. cls: 'x-btn-blue',
  94. id: 'resaccoutover',
  95. text: '反结账',
  96. width: 80,
  97. margin: '0 0 0 5'
  98. },{
  99. cls: 'x-btn-blue',
  100. id: 'close',
  101. text: $I18N.common.button.erpCloseButton,
  102. width: 80,
  103. margin: '0 175 0 5'
  104. }]
  105. }]
  106. });
  107. me.callParent(arguments);
  108. }
  109. });