【删除】开发已经重写了标准法规更新记录,所以去掉旧的文档动态模块
This commit is contained in:
-9
@@ -31,13 +31,6 @@ import com.jero.modules.document.enums.LawsStateEnum;
|
||||
import com.jero.modules.document.enums.SearchEnum;
|
||||
import com.jero.modules.document.mapper.BussDocumentLibraryEOMapper;
|
||||
import com.jero.modules.document.service.IBussDocumentLibraryEOService;
|
||||
import com.jero.modules.document.utils.ReadPdfUtil;
|
||||
import com.jero.modules.document.utils.ReadWordUtil;
|
||||
import com.jero.modules.document.vo.QueryConditionVO;
|
||||
//import com.jero.modules.domain.entity.DomainUserRel;
|
||||
//import com.jero.modules.domain.service.impl.DomainManageServiceImpl;
|
||||
import com.jero.modules.home.entity.HomeDocumentDynamicEO;
|
||||
import com.jero.modules.home.service.IHomeDocumentDynamicEOService;
|
||||
import com.jero.modules.log.entity.BussLogEO;
|
||||
import com.jero.modules.log.service.IBussLogEOService;
|
||||
import com.jero.modules.message.websocket.WebSocket;
|
||||
@@ -130,8 +123,6 @@ public class BussDocumentLibraryEOServiceImpl extends ServiceImpl<BussDocumentLi
|
||||
private ISarFileSplitInfoService sarFileSplitInfoService;
|
||||
@Resource
|
||||
private WebSocket webSocket;
|
||||
@Autowired
|
||||
private IHomeDocumentDynamicEOService homeDocumentDynamicEOService;
|
||||
// @Autowired
|
||||
// private IOcrRecordEOService ocrRecordEOService;
|
||||
// @Autowired
|
||||
|
||||
-186
@@ -1,186 +0,0 @@
|
||||
package com.jero.modules.home.controller;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.jero.common.api.vo.Result;
|
||||
import com.jero.common.aspect.annotation.AutoLog;
|
||||
import com.jero.common.constant.enums.LanguageEnum;
|
||||
import com.jero.common.system.base.controller.JeroController;
|
||||
import com.jero.common.system.query.QueryGenerator;
|
||||
import com.jero.modules.home.entity.HomeDocumentDynamicEO;
|
||||
import com.jero.modules.home.service.IHomeDocumentDynamicEOService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.lang3.ObjectUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* @Description: 文档动态
|
||||
* @Author: jero-boot
|
||||
* @Date: 2022-05-24
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Api(tags="文档动态")
|
||||
@RestController
|
||||
@RequestMapping("/home/homeDocumentDynamicEO")
|
||||
@Slf4j
|
||||
public class HomeDocumentDynamicEOController extends JeroController<HomeDocumentDynamicEO, IHomeDocumentDynamicEOService> {
|
||||
@Autowired
|
||||
private IHomeDocumentDynamicEOService homeDocumentDynamicEOService;
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param homeDocumentDynamicEO
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "文档动态-分页列表查询")
|
||||
@ApiOperation(value="文档动态-分页列表查询", notes="文档动态-分页列表查询")
|
||||
@GetMapping(value = "/page")
|
||||
public Result<?> queryPageList(HomeDocumentDynamicEO homeDocumentDynamicEO,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
HttpServletRequest req,
|
||||
String cut) {
|
||||
QueryWrapper<HomeDocumentDynamicEO> queryWrapper = QueryGenerator.initQueryWrapper(homeDocumentDynamicEO, req.getParameterMap());
|
||||
queryWrapper.orderByDesc("create_time");
|
||||
Page<HomeDocumentDynamicEO> page = new Page<HomeDocumentDynamicEO>(pageNo, pageSize);
|
||||
IPage<HomeDocumentDynamicEO> pageList = homeDocumentDynamicEOService.page(page, queryWrapper);
|
||||
if(LanguageEnum.CN.getValue().equals(cut) && ObjectUtils.isNotEmpty(pageList.getRecords())){
|
||||
for (HomeDocumentDynamicEO record : pageList.getRecords()) {
|
||||
if(StringUtils.isNotBlank(record.getMsgContentCn())){
|
||||
record.setMsgContent(record.getMsgContentCn());
|
||||
}
|
||||
if(StringUtils.isNotBlank(record.getMsgContentInfoCn())){
|
||||
record.setMsgContentInfo(record.getMsgContentInfoCn());
|
||||
}
|
||||
}
|
||||
}
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "文档动态-列表查询")
|
||||
@ApiOperation(value="文档动态-列表查询", notes="文档动态-列表查询")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<List<HomeDocumentDynamicEO>> queryList() {
|
||||
List<HomeDocumentDynamicEO> list = homeDocumentDynamicEOService.queryList();
|
||||
return Result.OK(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param homeDocumentDynamicEO
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "文档动态-添加")
|
||||
@ApiOperation(value="文档动态-添加", notes="文档动态-添加")
|
||||
@PostMapping(value = "/add")
|
||||
public Result<?> add(@Validated @RequestBody HomeDocumentDynamicEO homeDocumentDynamicEO) {
|
||||
homeDocumentDynamicEOService.add(homeDocumentDynamicEO);
|
||||
return Result.OK("添加成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param homeDocumentDynamicEO
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "文档动态-编辑")
|
||||
@ApiOperation(value="文档动态-编辑", notes="文档动态-编辑")
|
||||
@PostMapping(value = "/edit")
|
||||
public Result<?> edit(@Validated @RequestBody HomeDocumentDynamicEO homeDocumentDynamicEO) {
|
||||
homeDocumentDynamicEOService.editById(homeDocumentDynamicEO);
|
||||
return Result.OK("编辑成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "文档动态-通过id删除")
|
||||
@ApiOperation(value="文档动态-通过id删除", notes="文档动态-通过id删除")
|
||||
@PostMapping(value = "/delete")
|
||||
public Result<?> delete(@RequestParam(name="id",required=true) String id) {
|
||||
homeDocumentDynamicEOService.deleteById(id);
|
||||
return Result.OK("删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "文档动态-批量删除")
|
||||
@ApiOperation(value="文档动态-批量删除", notes="文档动态-批量删除")
|
||||
@GetMapping(value = "/deleteBatch")
|
||||
public Result<?> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||
this.homeDocumentDynamicEOService.deleteByIds(Arrays.asList(ids.split(",")));
|
||||
return Result.OK("批量删除成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "文档动态-通过id查询")
|
||||
@ApiOperation(value="文档动态-通过id查询", notes="文档动态-通过id查询")
|
||||
@GetMapping(value = "/queryById")
|
||||
public Result<?> queryById(@RequestParam(name="id",required=true) String id) {
|
||||
HomeDocumentDynamicEO homeDocumentDynamicEO = homeDocumentDynamicEOService.queryById(id);
|
||||
if(homeDocumentDynamicEO==null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.OK(homeDocumentDynamicEO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel
|
||||
*
|
||||
* @param request
|
||||
* @param homeDocumentDynamicEO
|
||||
*/
|
||||
@RequestMapping(value = "/exportXls")
|
||||
public ModelAndView exportXls(HttpServletRequest request, HomeDocumentDynamicEO homeDocumentDynamicEO) {
|
||||
return super.exportXls(request, homeDocumentDynamicEO, HomeDocumentDynamicEO.class, "文档动态");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过excel导入数据
|
||||
*
|
||||
* @param request
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||
return super.importExcel(request, response, HomeDocumentDynamicEO.class);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,77 +0,0 @@
|
||||
package com.jero.modules.home.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.experimental.Accessors;
|
||||
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
|
||||
/**
|
||||
* @Description: 文档动态
|
||||
* @Author: jero-boot
|
||||
* @Date: 2022-05-24
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Data
|
||||
@TableName("home_document_dynamic")
|
||||
@Accessors(chain = true)
|
||||
@EqualsAndHashCode(callSuper = false)
|
||||
@ApiModel(value="home_document_dynamic对象", description="文档动态")
|
||||
public class HomeDocumentDynamicEO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**主键*/
|
||||
@TableId(type = IdType.ASSIGN_ID)
|
||||
@ApiModelProperty(value = "主键")
|
||||
private String id;
|
||||
|
||||
/**创建人*/
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private String createBy;
|
||||
|
||||
/**创建日期*/
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
@ApiModelProperty(value = "创建日期")
|
||||
private java.util.Date createTime;
|
||||
|
||||
/**更新人*/
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private String updateBy;
|
||||
|
||||
/**更新日期*/
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
@ApiModelProperty(value = "更新日期")
|
||||
private java.util.Date updateTime;
|
||||
|
||||
/**所属部门*/
|
||||
@ApiModelProperty(value = "所属部门")
|
||||
private String sysOrgCode;
|
||||
|
||||
/**消息内容*/
|
||||
@Excel(name = "消息内容", width = 15)
|
||||
@ApiModelProperty(value = "消息内容")
|
||||
private String msgContent;
|
||||
|
||||
/**消息内容详情*/
|
||||
@Excel(name = "消息内容详情", width = 15)
|
||||
@ApiModelProperty(value = "消息内容详情")
|
||||
private String msgContentInfo;
|
||||
|
||||
//消息中文
|
||||
private String msgContentCn;
|
||||
|
||||
//消息详情中文
|
||||
private String msgContentInfoCn;
|
||||
|
||||
}
|
||||
-14
@@ -1,14 +0,0 @@
|
||||
package com.jero.modules.home.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.jero.modules.home.entity.HomeDocumentDynamicEO;
|
||||
|
||||
/**
|
||||
* @Description: 文档动态
|
||||
* @Author: jero-boot
|
||||
* @Date: 2022-05-24
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface HomeDocumentDynamicEOMapper extends BaseMapper<HomeDocumentDynamicEO> {
|
||||
|
||||
}
|
||||
-14
@@ -1,14 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.jero.modules.home.mapper.HomeDocumentDynamicEOMapper">
|
||||
<resultMap id="HomeDocumentDynamicEOResultMap" type="com.jero.modules.home.entity.HomeDocumentDynamicEO">
|
||||
<id column="id" property="id" />
|
||||
<result column="create_by" property="createBy" />
|
||||
<result column="create_time" property="createTime" />
|
||||
<result column="update_by" property="updateBy" />
|
||||
<result column="update_time" property="updateTime" />
|
||||
<result column="sys_org_code" property="sysOrgCode" />
|
||||
<result column="msg_content" property="msgContent" />
|
||||
<result column="msg_content_info" property="msgContentInfo" />
|
||||
</resultMap>
|
||||
</mapper>
|
||||
-62
@@ -1,62 +0,0 @@
|
||||
package com.jero.modules.home.service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.jero.modules.home.entity.HomeDocumentDynamicEO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Description: 文档动态
|
||||
* @Author: jero-boot
|
||||
* @Date: 2022-05-24
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface IHomeDocumentDynamicEOService extends IService<HomeDocumentDynamicEO> {
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*
|
||||
* @param homeDocumentDynamicEO
|
||||
* @return
|
||||
*/
|
||||
void add(HomeDocumentDynamicEO homeDocumentDynamicEO);
|
||||
|
||||
/**
|
||||
* 更新
|
||||
*
|
||||
* @param homeDocumentDynamicEO
|
||||
* @return
|
||||
*/
|
||||
void editById(HomeDocumentDynamicEO homeDocumentDynamicEO);
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
void deleteById(String id);
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
void deleteByIds(List<String> ids);
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
HomeDocumentDynamicEO queryById(String id);
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
List<HomeDocumentDynamicEO> queryList();
|
||||
}
|
||||
-90
@@ -1,90 +0,0 @@
|
||||
package com.jero.modules.home.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.jero.modules.home.entity.HomeDocumentDynamicEO;
|
||||
import com.jero.modules.home.mapper.HomeDocumentDynamicEOMapper;
|
||||
import com.jero.modules.home.service.IHomeDocumentDynamicEOService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Description: 文档动态
|
||||
* @Author: jero-boot
|
||||
* @Date: 2022-05-24
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Service
|
||||
public class HomeDocumentDynamicEOServiceImpl extends ServiceImpl<HomeDocumentDynamicEOMapper, HomeDocumentDynamicEO> implements IHomeDocumentDynamicEOService {
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*
|
||||
* @param homeDocumentDynamicEO
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void add(HomeDocumentDynamicEO homeDocumentDynamicEO) {
|
||||
Date now = new Date();
|
||||
homeDocumentDynamicEO.setCreateTime(now);
|
||||
homeDocumentDynamicEO.setUpdateTime(now);
|
||||
save(homeDocumentDynamicEO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新
|
||||
*
|
||||
* @param homeDocumentDynamicEO
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void editById(HomeDocumentDynamicEO homeDocumentDynamicEO) {
|
||||
Date now = new Date();
|
||||
homeDocumentDynamicEO.setUpdateTime(now);
|
||||
saveOrUpdate(homeDocumentDynamicEO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void deleteById(String id) {
|
||||
removeById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public void deleteByIds(List<String> ids) {
|
||||
removeByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public HomeDocumentDynamicEO queryById(String id) {
|
||||
return getById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public List<HomeDocumentDynamicEO> queryList() {
|
||||
return list();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user