高章伟
2022-02-18 8b5f4c6c281cfa548f92de52c8021e37aa81901e
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
public with sharing class Solution_ProgrammeDeleteController {
 
    public String ids {get;set;}
    public boolean is_Alert_Delete {get; set;}
 
    public Solution_ProgrammeDeleteController(ApexPages.StandardController controller)
    {
        ids = ApexPages.currentPage().getParameters().get('id');
    }
    public void init(){
        Solution_Programme__c solutionProgrames =[select id , Status__c from Solution_Programme__c where id = :ids];
        if (solutionProgrames.Status__c.contains('草案中')){
            delete solutionProgrames;
            is_Alert_Delete = true;
        }else {
            is_Alert_Delete = false;    
        }
     
    }
}