|
|
|
@ -2,10 +2,13 @@ package cn.estsh.i3plus.core.apiservice.controller;
|
|
|
|
|
|
|
|
|
|
import cn.estsh.i3plus.core.api.iservice.busi.ISysUserService;
|
|
|
|
|
import cn.estsh.i3plus.core.api.iservice.busi.ITestService;
|
|
|
|
|
import cn.estsh.i3plus.pojo.base.bean.BaseResultBean;
|
|
|
|
|
import cn.estsh.i3plus.pojo.base.bean.DdlPackBean;
|
|
|
|
|
import cn.estsh.i3plus.pojo.base.bean.ListPager;
|
|
|
|
|
import cn.estsh.i3plus.pojo.base.common.Pager;
|
|
|
|
|
import cn.estsh.i3plus.pojo.base.enumutil.CommonEnumUtil;
|
|
|
|
|
import cn.estsh.i3plus.pojo.base.enumutil.ResourceEnumUtil;
|
|
|
|
|
import cn.estsh.i3plus.pojo.base.tool.DdlPreparedPack;
|
|
|
|
|
import cn.estsh.i3plus.pojo.base.tool.HqlPack;
|
|
|
|
|
import cn.estsh.i3plus.pojo.platform.bean.SysUser;
|
|
|
|
|
import cn.estsh.impp.framework.boot.exception.ImppBusiException;
|
|
|
|
@ -22,6 +25,8 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
|
|
import org.springframework.web.bind.annotation.RestController;
|
|
|
|
|
|
|
|
|
|
import java.sql.SQLException;
|
|
|
|
|
import java.util.ArrayList;
|
|
|
|
|
import java.util.List;
|
|
|
|
|
|
|
|
|
|
@RestController
|
|
|
|
|
@RequestMapping("/impp-ddl")
|
|
|
|
@ -44,4 +49,37 @@ public class DemoDdlPackController {
|
|
|
|
|
return ResultBean.fail(busExcep);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@GetMapping(value="/testpackin")
|
|
|
|
|
@ApiOperation(value="ddl封装in")
|
|
|
|
|
public BaseResultBean testDdlPackIn(int testType){
|
|
|
|
|
String[] strArr = {"1","2"};
|
|
|
|
|
Integer[] intArr = {1,2};
|
|
|
|
|
|
|
|
|
|
List strList = new ArrayList();
|
|
|
|
|
strList.add("1");
|
|
|
|
|
strList.add("2");
|
|
|
|
|
|
|
|
|
|
List intList = new ArrayList();
|
|
|
|
|
intList.add(1);
|
|
|
|
|
intList.add(2);
|
|
|
|
|
|
|
|
|
|
DdlPackBean packBean = new DdlPackBean(true);
|
|
|
|
|
if(testType == 1) {
|
|
|
|
|
DdlPreparedPack.getInPack("aaa", "userName", packBean);
|
|
|
|
|
}else if(testType == 2) {
|
|
|
|
|
DdlPreparedPack.getInPackArray(strArr, "userName", packBean);
|
|
|
|
|
}else if(testType == 3) {
|
|
|
|
|
DdlPreparedPack.getInPackArray(intArr, "userStatus", packBean);
|
|
|
|
|
}else if(testType == 4) {
|
|
|
|
|
DdlPreparedPack.getInPackList(strList, "userName", packBean);
|
|
|
|
|
}else if(testType == 5) {
|
|
|
|
|
DdlPreparedPack.getInPackList(intList, "userStatus", packBean);
|
|
|
|
|
}
|
|
|
|
|
List<SysUser> list = testService.querySysUserByPack(packBean);
|
|
|
|
|
|
|
|
|
|
return ResultBean.success("用户数量:" + list.size())
|
|
|
|
|
.setCode(ResourceEnumUtil.MESSAGE.SUCCESS.getCode())
|
|
|
|
|
.setResultList(list);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|