use of com.vartech.common.app.beans.SearchParameter in project varsql by varsqlinfo.
the class PluginController method historySearch.
/**
* @Method Name : historySearch
* @Method 설명 : sql history search.
* @작성자 : ytkim
* @작성일 : 2018. 7. 26.
* @변경이력 :
* @param req
* @return
* @throws Exception
*/
@RequestMapping(value = "/history/search", method = RequestMethod.POST)
@ResponseBody
public ResponseResult historySearch(HttpServletRequest req) throws Exception {
SearchParameter param = HttpUtils.getSearchParameter(req);
param.addCustomParam(VarsqlParamConstants.CONN_UUID, SecurityUtil.getVconnid(String.valueOf(param.getCustomParam().get(VarsqlParamConstants.CONN_UUID))));
param.addCustomParam(VarsqlParamConstants.UID, SecurityUtil.userViewId());
return pluginServiceImpl.historySearch(param);
}
use of com.vartech.common.app.beans.SearchParameter in project varsql by varsqlinfo.
the class AdminDbMgmtServiceImpl method jdbcProviderList.
public ResponseResult jdbcProviderList(SearchParameter searchParameter) {
Sort sort = Sort.by(Sort.Direction.ASC, DBTypeDriverProviderEntity.DB_TYPE).and(Sort.by(Sort.Direction.ASC, DBTypeDriverProviderEntity.PROVIDER_NAME));
List<DBTypeDriverProviderEntity> result = dbTypeDriverProviderRepository.findAll(DBTypeDriverProviderSpec.searchField(searchParameter), sort);
List<DBTypeDriverProviderResponseDTO> list = result.stream().map(item -> {
DBTypeDriverProviderResponseDTO dto = new DBTypeDriverProviderResponseDTO();
dto.setDbType(item.getDbType());
dto.setProviderName(item.getProviderName());
dto.setDriverProviderId(item.getDriverProviderId());
dto.setDriverId(item.getDriverId());
dto.setDirectYn(item.getDirectYn());
return dto;
}).collect(Collectors.toList());
return VarsqlUtils.getResponseResultItemList(list);
}
use of com.vartech.common.app.beans.SearchParameter in project varsql by varsqlinfo.
the class UserPreferencesSqlFileController method list.
/**
* @Method Name : list
* @Method 설명 : 목록 .
* @작성자 : ytkim
* @작성일 : 2019. 11. 1.
* @변경이력 :
* @param req
* @return
*/
@RequestMapping(value = "/list", method = RequestMethod.POST)
@ResponseBody
public ResponseResult list(@RequestParam(value = "vconnid", required = true) String vconnid, HttpServletRequest req) {
SearchParameter searchParameter = HttpUtils.getSearchParameter(req);
searchParameter.addCustomParam(VarsqlParamConstants.UID, SecurityUtil.userViewId(req));
return userPreferencesSqlFileServiceImpl.sqlFileList(vconnid, searchParameter);
}
use of com.vartech.common.app.beans.SearchParameter in project varsql by varsqlinfo.
the class DriverProvierMgmtServiceImpl method list.
public ResponseResult list(SearchParameter searchParameter) {
Sort sort = Sort.by(Sort.Direction.DESC, DBTypeDriverProviderEntity.REG_DT).and(Sort.by(Sort.Direction.DESC, DBTypeDriverProviderEntity.PROVIDER_NAME));
Page<DBTypeDriverProviderEntity> result = dbTypeDriverProviderRepository.findAll(DBTypeDriverProviderSpec.searchField(searchParameter), VarsqlUtils.convertSearchInfoToPage(searchParameter, sort));
List<DBTypeDriverProviderResponseDTO> list = result.stream().map(item -> {
DBTypeDriverProviderResponseDTO dto = new DBTypeDriverProviderResponseDTO();
dto.setDbType(item.getDbType());
dto.setProviderName(item.getProviderName());
dto.setDriverClass(item.getDriverClass());
dto.setPathType(item.getPathType());
dto.setDriverProviderId(item.getDriverProviderId());
return dto;
}).collect(Collectors.toList());
return VarsqlUtils.getResponseResult(list, result.getTotalElements(), searchParameter);
}
use of com.vartech.common.app.beans.SearchParameter in project varsql by varsqlinfo.
the class QnaController method qnaMgmtList.
/**
* @method : qnaMgmtList
* @desc : qna 매니저 목록.
* @author : ytkim
* @date : 2020. 4. 30.
* @param req
* @return
* @throws Exception
*/
@RequestMapping(value = "/qnaMgmtList", method = RequestMethod.POST)
@ResponseBody
public ResponseResult qnaMgmtList(HttpServletRequest req) throws Exception {
SearchParameter searchParameter = HttpUtils.getSearchParameter(req);
searchParameter.addCustomParam(VarsqlParamConstants.ROLE, SecurityUtil.loginRole(req));
searchParameter.addCustomParam(VarsqlParamConstants.UID, SecurityUtil.userViewId(req));
return qnaServiceImpl.selectQnaMgmtList(searchParameter);
}
Aggregations