SaleForecastChange.js 778 B

123456789101112131415161718192021
  1. Ext.define('erp.view.core.button.SaleForecastChange',{
  2. extend: 'Ext.Button',
  3. alias: 'widget.erpSaleForecastChangeButton',
  4. text:$I18N.common.button.erpSaleForecastChangeButton,
  5. iconCls: 'x-button-icon-save',
  6. cls: 'x-btn-gray',
  7. width: 100,
  8. style: {
  9. marginLeft: '10px'
  10. },
  11. handler: function(btn){
  12. var status=Ext.getCmp('sf_statuscode').getValue();
  13. if(status =='AUDITED'){
  14. Ext.create('erp.util.FormUtil').onAdd('addSaleForecastChange', '销售预测变更单', 'jsps/pm/mps/saleForecastChange.jsp?code='+Ext.getCmp('sf_code').value);
  15. }else showMessage('提示','当前状态不允许新增变更单',1000);
  16. },
  17. initComponent : function(){
  18. this.callParent(arguments);
  19. }
  20. });