use of com.ngtesting.platform.vo.CaseTypeVo in project ngtesting-platform by aaronchen2k.
the class CaseTypeAction method changeOrder.
@AuthPassport(validate = true)
@RequestMapping(value = "changeOrder", method = RequestMethod.POST)
@ResponseBody
public Map<String, Object> changeOrder(HttpServletRequest request, @RequestBody JSONObject json) {
Map<String, Object> ret = new HashMap<String, Object>();
UserVo userVo = (UserVo) request.getSession().getAttribute(Constant.HTTP_SESSION_USER_KEY);
Long orgId = userVo.getDefaultOrgId();
Long id = json.getLong("id");
String act = json.getString("act");
boolean success = caseTypeService.changeOrderPers(id, act, orgId);
List<CaseTypeVo> vos = caseTypeService.listVos(orgId);
ret.put("data", vos);
ret.put("code", Constant.RespCode.SUCCESS.getCode());
return ret;
}
use of com.ngtesting.platform.vo.CaseTypeVo in project ngtesting-platform by aaronchen2k.
the class CaseTypeAction method list.
@AuthPassport(validate = true)
@RequestMapping(value = "list", method = RequestMethod.POST)
@ResponseBody
public Map<String, Object> list(HttpServletRequest request, @RequestBody JSONObject json) {
Map<String, Object> ret = new HashMap<String, Object>();
UserVo userVo = (UserVo) request.getSession().getAttribute(Constant.HTTP_SESSION_USER_KEY);
Long orgId = userVo.getDefaultOrgId();
List<CaseTypeVo> vos = caseTypeService.listVos(orgId);
Map<String, Map<String, String>> casePropertyMap = casePropertyService.getMap(orgId);
ret.put("data", vos);
ret.put("code", Constant.RespCode.SUCCESS.getCode());
return ret;
}
use of com.ngtesting.platform.vo.CaseTypeVo in project ngtesting-platform by aaronchen2k.
the class CaseTypeServiceImpl method genVos.
@Override
public List<CaseTypeVo> genVos(List<TestCaseType> pos) {
List<CaseTypeVo> vos = new LinkedList<CaseTypeVo>();
for (TestCaseType po : pos) {
CaseTypeVo vo = genVo(po);
vos.add(vo);
}
return vos;
}
Aggregations