新增待办信息
This commit is contained in:
@@ -49,7 +49,7 @@ import java.io.Serial;
|
|||||||
@Column(name = "f_flow_id", attrName = "fflowId", label = "流程id", isUpdate = false, isQuery = false),
|
@Column(name = "f_flow_id", attrName = "fflowId", label = "流程id", isUpdate = false, isQuery = false),
|
||||||
@Column(name = "f_flow_task_id", attrName = "fflowTaskId", label = "流程任务主键", isUpdate = false, isQuery = false),
|
@Column(name = "f_flow_task_id", attrName = "fflowTaskId", label = "流程任务主键", isUpdate = false, isQuery = false),
|
||||||
@Column(name = "f_flow_state", attrName = "fflowState", label = "流程任务状态", isUpdate = false, isQuery = false, isUpdateForce = true),
|
@Column(name = "f_flow_state", attrName = "fflowState", label = "流程任务状态", isUpdate = false, isQuery = false, isUpdateForce = true),
|
||||||
}, orderBy = "a.id DESC"
|
}, orderBy = "a.create_time DESC"
|
||||||
)
|
)
|
||||||
@Data
|
@Data
|
||||||
public class BizMeetingInfo extends DataEntity<BizMeetingInfo> implements Serializable {
|
public class BizMeetingInfo extends DataEntity<BizMeetingInfo> implements Serializable {
|
||||||
|
|||||||
@@ -1,6 +1,9 @@
|
|||||||
package com.jeesite.modules.biz.web;
|
package com.jeesite.modules.biz.web;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.jeesite.modules.sys.entity.User;
|
||||||
|
import com.jeesite.modules.sys.utils.UserUtils;
|
||||||
import jakarta.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import jakarta.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
@@ -26,6 +29,7 @@ import com.jeesite.modules.biz.service.BizMeetingInfoService;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 会议主表Controller
|
* 会议主表Controller
|
||||||
|
*
|
||||||
* @author gaoxq
|
* @author gaoxq
|
||||||
* @version 2026-01-02
|
* @version 2026-01-02
|
||||||
*/
|
*/
|
||||||
@@ -33,114 +37,116 @@ import com.jeesite.modules.biz.service.BizMeetingInfoService;
|
|||||||
@RequestMapping(value = "${adminPath}/biz/meetingInfo")
|
@RequestMapping(value = "${adminPath}/biz/meetingInfo")
|
||||||
public class BizMeetingInfoController extends BaseController {
|
public class BizMeetingInfoController extends BaseController {
|
||||||
|
|
||||||
private final BizMeetingInfoService bizMeetingInfoService;
|
private final BizMeetingInfoService bizMeetingInfoService;
|
||||||
|
|
||||||
public BizMeetingInfoController(BizMeetingInfoService bizMeetingInfoService) {
|
public BizMeetingInfoController(BizMeetingInfoService bizMeetingInfoService) {
|
||||||
this.bizMeetingInfoService = bizMeetingInfoService;
|
this.bizMeetingInfoService = bizMeetingInfoService;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* 获取数据
|
|
||||||
*/
|
|
||||||
@ModelAttribute
|
|
||||||
public BizMeetingInfo get(String id, boolean isNewRecord) {
|
|
||||||
return bizMeetingInfoService.get(id, isNewRecord);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 查询列表
|
|
||||||
*/
|
|
||||||
@RequiresPermissions("biz:meetingInfo:view")
|
|
||||||
@RequestMapping(value = {"list", ""})
|
|
||||||
public String list(BizMeetingInfo bizMeetingInfo, Model model) {
|
|
||||||
model.addAttribute("bizMeetingInfo", bizMeetingInfo);
|
|
||||||
return "modules/biz/bizMeetingInfoList";
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 查询列表数据
|
|
||||||
*/
|
|
||||||
@RequiresPermissions("biz:meetingInfo:view")
|
|
||||||
@RequestMapping(value = "listData")
|
|
||||||
@ResponseBody
|
|
||||||
public Page<BizMeetingInfo> listData(BizMeetingInfo bizMeetingInfo, HttpServletRequest request, HttpServletResponse response) {
|
|
||||||
bizMeetingInfo.setPage(new Page<>(request, response));
|
|
||||||
Page<BizMeetingInfo> page = bizMeetingInfoService.findPage(bizMeetingInfo);
|
|
||||||
return page;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查看编辑表单
|
* 获取数据
|
||||||
*/
|
*/
|
||||||
@RequiresPermissions("biz:meetingInfo:view")
|
@ModelAttribute
|
||||||
@RequestMapping(value = "form")
|
public BizMeetingInfo get(String id, boolean isNewRecord) {
|
||||||
public String form(BizMeetingInfo bizMeetingInfo, Model model) {
|
return bizMeetingInfoService.get(id, isNewRecord);
|
||||||
model.addAttribute("bizMeetingInfo", bizMeetingInfo);
|
}
|
||||||
return "modules/biz/bizMeetingInfoForm";
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 保存数据
|
* 查询列表
|
||||||
*/
|
*/
|
||||||
@RequiresPermissions("biz:meetingInfo:edit")
|
@RequiresPermissions("biz:meetingInfo:view")
|
||||||
@PostMapping(value = "save")
|
@RequestMapping(value = {"list", ""})
|
||||||
@ResponseBody
|
public String list(BizMeetingInfo bizMeetingInfo, Model model) {
|
||||||
public String save(@Validated BizMeetingInfo bizMeetingInfo) {
|
model.addAttribute("bizMeetingInfo", bizMeetingInfo);
|
||||||
bizMeetingInfoService.save(bizMeetingInfo);
|
return "modules/biz/bizMeetingInfoList";
|
||||||
return renderResult(Global.TRUE, text("保存会议信息成功!"));
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 导出数据
|
* 查询列表数据
|
||||||
*/
|
*/
|
||||||
@RequiresPermissions("biz:meetingInfo:view")
|
@RequiresPermissions("biz:meetingInfo:view")
|
||||||
@RequestMapping(value = "exportData")
|
@RequestMapping(value = "listData")
|
||||||
public void exportData(BizMeetingInfo bizMeetingInfo, HttpServletResponse response) {
|
@ResponseBody
|
||||||
List<BizMeetingInfo> list = bizMeetingInfoService.findList(bizMeetingInfo);
|
public Page<BizMeetingInfo> listData(BizMeetingInfo bizMeetingInfo, HttpServletRequest request, HttpServletResponse response) {
|
||||||
String fileName = "会议信息" + DateUtils.getDate("yyyyMMddHHmmss") + ".xlsx";
|
bizMeetingInfo.setPage(new Page<>(request, response));
|
||||||
try(ExcelExport ee = new ExcelExport("会议信息", BizMeetingInfo.class)){
|
Page<BizMeetingInfo> page = bizMeetingInfoService.findPage(bizMeetingInfo);
|
||||||
ee.setDataList(list).write(response, fileName);
|
return page;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 下载模板
|
* 查看编辑表单
|
||||||
*/
|
*/
|
||||||
@RequiresPermissions("biz:meetingInfo:view")
|
@RequiresPermissions("biz:meetingInfo:view")
|
||||||
@RequestMapping(value = "importTemplate")
|
@RequestMapping(value = "form")
|
||||||
public void importTemplate(HttpServletResponse response) {
|
public String form(BizMeetingInfo bizMeetingInfo, Model model) {
|
||||||
BizMeetingInfo bizMeetingInfo = new BizMeetingInfo();
|
model.addAttribute("bizMeetingInfo", bizMeetingInfo);
|
||||||
List<BizMeetingInfo> list = ListUtils.newArrayList(bizMeetingInfo);
|
return "modules/biz/bizMeetingInfoForm";
|
||||||
String fileName = "会议信息模板.xlsx";
|
}
|
||||||
try(ExcelExport ee = new ExcelExport("会议信息", BizMeetingInfo.class, Type.IMPORT)){
|
|
||||||
ee.setDataList(list).write(response, fileName);
|
/**
|
||||||
}
|
* 保存数据
|
||||||
}
|
*/
|
||||||
|
@RequiresPermissions("biz:meetingInfo:edit")
|
||||||
|
@PostMapping(value = "save")
|
||||||
|
@ResponseBody
|
||||||
|
public String save(@Validated BizMeetingInfo bizMeetingInfo) {
|
||||||
|
User user = UserUtils.getUser();
|
||||||
|
bizMeetingInfo.setCreateUser(user.getLoginCode());
|
||||||
|
bizMeetingInfoService.save(bizMeetingInfo);
|
||||||
|
return renderResult(Global.TRUE, text("保存会议信息成功!"));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出数据
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("biz:meetingInfo:view")
|
||||||
|
@RequestMapping(value = "exportData")
|
||||||
|
public void exportData(BizMeetingInfo bizMeetingInfo, HttpServletResponse response) {
|
||||||
|
List<BizMeetingInfo> list = bizMeetingInfoService.findList(bizMeetingInfo);
|
||||||
|
String fileName = "会议信息" + DateUtils.getDate("yyyyMMddHHmmss") + ".xlsx";
|
||||||
|
try (ExcelExport ee = new ExcelExport("会议信息", BizMeetingInfo.class)) {
|
||||||
|
ee.setDataList(list).write(response, fileName);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 下载模板
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("biz:meetingInfo:view")
|
||||||
|
@RequestMapping(value = "importTemplate")
|
||||||
|
public void importTemplate(HttpServletResponse response) {
|
||||||
|
BizMeetingInfo bizMeetingInfo = new BizMeetingInfo();
|
||||||
|
List<BizMeetingInfo> list = ListUtils.newArrayList(bizMeetingInfo);
|
||||||
|
String fileName = "会议信息模板.xlsx";
|
||||||
|
try (ExcelExport ee = new ExcelExport("会议信息", BizMeetingInfo.class, Type.IMPORT)) {
|
||||||
|
ee.setDataList(list).write(response, fileName);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导入数据
|
||||||
|
*/
|
||||||
|
@ResponseBody
|
||||||
|
@RequiresPermissions("biz:meetingInfo:edit")
|
||||||
|
@PostMapping(value = "importData")
|
||||||
|
public String importData(MultipartFile file) {
|
||||||
|
try {
|
||||||
|
String message = bizMeetingInfoService.importData(file);
|
||||||
|
return renderResult(Global.TRUE, "posfull:" + message);
|
||||||
|
} catch (Exception ex) {
|
||||||
|
return renderResult(Global.FALSE, "posfull:" + ex.getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除数据
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("biz:meetingInfo:edit")
|
||||||
|
@RequestMapping(value = "delete")
|
||||||
|
@ResponseBody
|
||||||
|
public String delete(BizMeetingInfo bizMeetingInfo) {
|
||||||
|
bizMeetingInfoService.delete(bizMeetingInfo);
|
||||||
|
return renderResult(Global.TRUE, text("删除会议信息成功!"));
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* 导入数据
|
|
||||||
*/
|
|
||||||
@ResponseBody
|
|
||||||
@RequiresPermissions("biz:meetingInfo:edit")
|
|
||||||
@PostMapping(value = "importData")
|
|
||||||
public String importData(MultipartFile file) {
|
|
||||||
try {
|
|
||||||
String message = bizMeetingInfoService.importData(file);
|
|
||||||
return renderResult(Global.TRUE, "posfull:"+message);
|
|
||||||
} catch (Exception ex) {
|
|
||||||
return renderResult(Global.FALSE, "posfull:"+ex.getMessage());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 删除数据
|
|
||||||
*/
|
|
||||||
@RequiresPermissions("biz:meetingInfo:edit")
|
|
||||||
@RequestMapping(value = "delete")
|
|
||||||
@ResponseBody
|
|
||||||
public String delete(BizMeetingInfo bizMeetingInfo) {
|
|
||||||
bizMeetingInfoService.delete(bizMeetingInfo);
|
|
||||||
return renderResult(Global.TRUE, text("删除会议信息成功!"));
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user