@ -70,9 +70,7 @@ public class ProjectManagementController {
@ApiParam ( name = "state" , value = "项目状态(0、草稿箱 1、已发布)" , required = false ) @RequestParam ( required = false ) Integer state ,
@ApiParam ( name = "projectName" , value = "项目名称" , required = false ) @RequestParam ( required = false ) String projectName ,
@ApiParam ( name = "systemId" , value = "系统id" , required = true ) @RequestParam Integer systemId ,
@ApiParam ( name = "userId" , value = "用户id" , required = true ) @RequestParam Integer userId ,
@ApiParam ( name = "pageNo" , value = "第几页,页码" , required = true ) @RequestParam Integer pageNo ,
@ApiParam ( name = "pageSize" , value = "每页展示的数据条数" , required = true ) @RequestParam Integer pageSize ) {
@ApiParam ( name = "userId" , value = "用户id" , required = true ) @RequestParam Integer userId ) {
Response resp = new Response ( ) ;
ProjectManagement vo = new ProjectManagement ( ) ;
if ( null ! = projectPermissions ) {
@ -93,7 +91,7 @@ public class ProjectManagementController {
if ( null ! = userId ) {
vo . setUserId ( userId ) ;
}
HashMap < String , Object > ret = service . queryAllManagements ( vo , pageNo , pageSize ) ;
HashMap < String , Object > ret = service . queryAllManagements ( vo ) ;
int status = ( int ) ret . get ( "retcode" ) ;
if ( status = = 200 ) {
resp . setStatus ( status ) ;
@ -104,6 +102,99 @@ public class ProjectManagementController {
}
return resp ;
}
// /**
// * 首页面查询
// * <p>
// *
// * @param projectPermissions:权限
// * @param founder:创建人
// * @param state:状态
// * @param projectName:项目名称
// * @param systemId
// * @return
// */
// @ApiOperation(value = "项目管理列表", notes = "项目管理列表")
// @GetMapping("/queryAllManagements")
// Response queryAllManagements(
// @ApiParam(name = "projectPermissions", value = "项目权限(0、练习 1、考核 2、竞赛)", required = false) @RequestParam(required = false) Integer projectPermissions,
// @ApiParam(name = "founder", value = "项目创建人(0、系统 1、老师)", required = false) @RequestParam(required = false) Integer founder,
// @ApiParam(name = "state", value = "项目状态(0、草稿箱 1、已发布)", required = false) @RequestParam(required = false) Integer state,
// @ApiParam(name = "projectName", value = "项目名称", required = false) @RequestParam(required = false) String projectName,
// @ApiParam(name = "systemId", value = "系统id", required = true) @RequestParam Integer systemId,
// @ApiParam(name = "userId", value = "用户id", required = true) @RequestParam Integer userId,
// @ApiParam(name = "pageNo", value = "第几页,页码", required = true) @RequestParam Integer pageNo,
// @ApiParam(name = "pageSize", value = "每页展示的数据条数", required = true) @RequestParam Integer pageSize) {
// Response resp = new Response();
// ProjectManagement vo = new ProjectManagement();
// if (null != projectPermissions) {
// vo.setProjectPermissions(projectPermissions);
// }
// if (null != founder) {
// vo.setFounder(founder);
// }
// if (null != state) {
// vo.setState(state);
// }
// if (null != systemId) {
// vo.setSystemId(systemId);
// }
// if (null != projectName && projectName != "") {
// vo.setProjectName(projectName);
// }
// if (null != userId) {
// vo.setUserId(userId);
// }
// HashMap<String, Object> ret = service.queryAllManagements(vo, pageNo, pageSize);
// int status = (int) ret.get("retcode");
// if (status == 200) {
// resp.setStatus(status);
// resp.setMessage(ret.get("retvalue"));
// } else {
// resp.setStatus(status);
// resp.setErrmessage(ret.get("retvalue").toString());
// }
// return resp;
// }
/ * *
* 页面查询 , 排除练习
* < p >
*
* @param systemId
* @return
* /
@ApiOperation ( value = "项目列表(排除练习)" , notes = "项目列表(用于创建实验,排除练习项目)" )
@GetMapping ( "/queryManagements" )
Response queryManagements (
@ApiParam ( name = "systemId" , value = "系统id" , required = true ) @RequestParam ( required = false ) Integer systemId ,
@ApiParam ( name = "userId" , value = "用户id" , required = true ) @RequestParam ( required = false ) Integer userId ,
@ApiParam ( name = "pageNo" , value = "第几页,页码" , required = true ) @RequestParam Integer pageNo ,
@ApiParam ( name = "pageSize" , value = "每页展示的数据条数" , required = true ) @RequestParam Integer pageSize ) {
Response resp = new Response ( ) ;
ProjectManagement vo = new ProjectManagement ( ) ;
if ( null ! = systemId ) {
vo . setSystemId ( systemId ) ;
}
if ( null ! = userId ) {
vo . setUserId ( userId ) ;
}
HashMap < String , Object > ret = service . queryManagements ( vo , pageNo , pageSize ) ;
int status = ( int ) ret . get ( "retcode" ) ;
if ( status = = 200 ) {
resp . setStatus ( status ) ;
resp . setMessage ( ret . get ( "retvalue" ) ) ;
} else {
resp . setStatus ( status ) ;
resp . setErrmessage ( ret . get ( "retvalue" ) . toString ( ) ) ;
}
return resp ;
}
/ * *
* 批量删除