Guest User

Untitled

a guest
Nov 24th, 2017
63
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.56 KB | None | 0 0
  1. public static final String CLOSED_STATUS = 'Closed';
  2. Case cId {get;set;}
  3. Case stat {get;set;}
  4. private ApexPages.StandardController stdController;
  5.  
  6. public String Status;
  7. public String CaseNumber;
  8.  
  9. //constructor
  10. public CaseClass(ApexPages.StandardController stdController){
  11. this.stdController = stdController;
  12. cId = (Case)stdController.getRecord();
  13.  
  14. }
  15. public PageReference saveAndReturn()
  16. {
  17.  
  18. Case upstat = [select Status from case where Id =: cId.Id];
  19. upstat.Status = 'Closed';
  20. update upstat;
  21. CaseNumber='1000432';
  22. stdController.save();
  23.  
  24.  
  25. return null;
Add Comment
Please, Sign In to add comment