Security implementation

This commit is contained in:
harish
2024-08-21 18:21:20 +05:30
parent 324490da69
commit 7a080504aa
30 changed files with 721 additions and 78 deletions

View File

@@ -9,6 +9,7 @@ import net.gepafin.tendermanagement.model.response.RoleResponseBean;
import net.gepafin.tendermanagement.service.RoleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
@Service
@@ -18,25 +19,30 @@ public class RoleServiceImpl implements RoleService {
private RoleDao roleDao;
@Override
@Transactional(rollbackFor = Exception.class)
public RoleResponseBean createRole(RoleReq roleReq) {
return roleDao.createRole(roleReq);
}
@Override
@Transactional(rollbackFor = Exception.class)
public RoleResponseBean updateRole(Long roleId, RoleReq roleReq) {
return roleDao.updateRole(roleId,roleReq);
}
@Override
@Transactional(readOnly = true)
public RoleEntity getRoleById(Long roleId) {
return roleDao.getRoleById(roleId);
}
@Override
@Transactional(rollbackFor = Exception.class)
public void deleteRole(Long roleId) {
roleDao.deleteById(roleId);
}
@Override
@Transactional(readOnly = true)
public List<RoleResponseBean> getAllRoles() {
return roleDao.getAllRoles();