Coverage Report - org.kuali.student.lum.program.client.permissions.ModelPermissionType
 
Classes in this File Line Coverage Branch Coverage Complexity
ModelPermissionType
0%
0/2
N/A
1
ModelPermissionType$1
0%
0/3
0%
0/2
1
 
 1  
 package org.kuali.student.lum.program.client.permissions;
 2  
 
 3  
 import org.kuali.student.common.ui.client.mvc.DataModel;
 4  
 import org.kuali.student.lum.program.client.ProgramConstants;
 5  
 import org.kuali.student.lum.program.client.ProgramStatus;
 6  
 
 7  
 /**
 8  
  * @author Igor
 9  
  */
 10  0
 public enum ModelPermissionType implements IModelPermission {
 11  0
     DRAFT_STATUS {
 12  
         @Override
 13  
         public boolean check(DataModel dataModel) {
 14  0
             ProgramStatus programStatus = ProgramStatus.of((String) dataModel.get(ProgramConstants.STATE));
 15  0
             return programStatus != ProgramStatus.DRAFT;
 16  
         }
 17  
     };
 18  
 
 19  
     public abstract boolean check(DataModel dataModel);
 20  
 }