Search in sources :

Example 16 with Permission

use of com.webank.wedatasphere.qualitis.entity.Permission in project Qualitis by WeBankFinTech.

the class RolePermissionDaoTest method savePermission.

private Permission savePermission() {
    // 保存是否成功
    Permission entity = new Permission();
    entity.setUrl("/junit/**");
    entity.setMethod("GET");
    Permission saveEntity = permissionDao.savePermission(entity);
    assertTrue(saveEntity.getId() != 0);
    return saveEntity;
}
Also used : Permission(com.webank.wedatasphere.qualitis.entity.Permission) RolePermission(com.webank.wedatasphere.qualitis.entity.RolePermission)

Aggregations

Permission (com.webank.wedatasphere.qualitis.entity.Permission)16 Transactional (org.springframework.transaction.annotation.Transactional)10 RolePermission (com.webank.wedatasphere.qualitis.entity.RolePermission)8 UserSpecPermission (com.webank.wedatasphere.qualitis.entity.UserSpecPermission)8 GeneralResponse (com.webank.wedatasphere.qualitis.response.GeneralResponse)8 UnExpectedRequestException (com.webank.wedatasphere.qualitis.exception.UnExpectedRequestException)7 Role (com.webank.wedatasphere.qualitis.entity.Role)4 User (com.webank.wedatasphere.qualitis.entity.User)4 Test (org.junit.Test)3 SpringBootTest (org.springframework.boot.test.context.SpringBootTest)3 PermissionResponse (com.webank.wedatasphere.qualitis.response.PermissionResponse)2 ArrayList (java.util.ArrayList)2 HttpSession (javax.servlet.http.HttpSession)2 AntPathMatcher (org.springframework.util.AntPathMatcher)2 GetAllResponse (com.webank.wedatasphere.qualitis.response.GetAllResponse)1 RolePermissionResponse (com.webank.wedatasphere.qualitis.response.RolePermissionResponse)1 UserSpecPermissionResponse (com.webank.wedatasphere.qualitis.response.UserSpecPermissionResponse)1 List (java.util.List)1 RoleNotFoundException (javax.management.relation.RoleNotFoundException)1 HttpServletRequest (javax.servlet.http.HttpServletRequest)1