Merge branch 'master' of https://gitlab.com/entgra/carbon-device-mgt into application-mgt-new

feature/appm-store/pbac
Charitha Goonetilleke 5 years ago
commit bfed11080d

@ -40,8 +40,8 @@ public class GroupManagementAdminServiceImpl implements GroupManagementAdminServ
try { try {
RequestValidationUtil.validatePaginationParameters(offset, limit); RequestValidationUtil.validatePaginationParameters(offset, limit);
GroupPaginationRequest request = new GroupPaginationRequest(offset, limit); GroupPaginationRequest request = new GroupPaginationRequest(offset, limit);
request.setGroupName(name); request.setGroupName(name.toUpperCase());
request.setOwner(owner); request.setOwner(owner.toUpperCase());
PaginationResult deviceGroupsResult = DeviceMgtAPIUtils.getGroupManagementProviderService() PaginationResult deviceGroupsResult = DeviceMgtAPIUtils.getGroupManagementProviderService()
.getGroups(request); .getGroups(request);
DeviceGroupList deviceGroupList = new DeviceGroupList(); DeviceGroupList deviceGroupList = new DeviceGroupList();

@ -55,11 +55,11 @@ public class GenericGroupDAOImpl extends AbstractGroupDAOImpl {
Connection conn = GroupManagementDAOFactory.getConnection(); Connection conn = GroupManagementDAOFactory.getConnection();
String sql = "SELECT ID, DESCRIPTION, GROUP_NAME, OWNER FROM DM_GROUP WHERE TENANT_ID = ?"; String sql = "SELECT ID, DESCRIPTION, GROUP_NAME, OWNER FROM DM_GROUP WHERE TENANT_ID = ?";
if (groupName != null && !groupName.isEmpty()) { if (groupName != null && !groupName.isEmpty()) {
sql += " AND GROUP_NAME LIKE ?"; sql += " AND UPPER(GROUP_NAME) LIKE ?";
hasGroupName = true; hasGroupName = true;
} }
if (owner != null && !owner.isEmpty()) { if (owner != null && !owner.isEmpty()) {
sql += " AND OWNER LIKE ?"; sql += " AND UPPER(OWNER) LIKE ?";
hasOwner = true; hasOwner = true;
} }
if (hasLimit) { if (hasLimit) {

Loading…
Cancel
Save