系统架构调整
This commit is contained in:
parent
1bb8f555b8
commit
cf929bb4c0
|
|
@ -3,6 +3,12 @@
|
|||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<parent>
|
||||
<groupId>com.rzyc</groupId>
|
||||
<artifactId>inventory</artifactId>
|
||||
<version>0.0.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath> <!-- lookup parent from repository -->
|
||||
</parent>
|
||||
|
||||
<groupId>com.rzyc</groupId>
|
||||
<artifactId>inventory-dao</artifactId>
|
||||
|
|
@ -24,65 +30,7 @@
|
|||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
<!-- mybatis start -->
|
||||
<dependency>
|
||||
<groupId>com.baomidou</groupId>
|
||||
<artifactId>mybatis-plus-boot-starter</artifactId>
|
||||
<version>3.4.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.baomidou</groupId>
|
||||
<artifactId>mybatis-plus</artifactId>
|
||||
<version>3.4.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.baomidou</groupId>
|
||||
<artifactId>mybatis-plus-generator</artifactId>
|
||||
<version>3.3.2</version>
|
||||
</dependency>
|
||||
|
||||
<!-- mybatis end -->
|
||||
|
||||
<!-- mysql start -->
|
||||
<dependency>
|
||||
<groupId>mysql</groupId>
|
||||
<artifactId>mysql-connector-java</artifactId>
|
||||
<version>8.0.31</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.freemarker</groupId>
|
||||
<artifactId>freemarker</artifactId>
|
||||
<version>2.3.30</version>
|
||||
</dependency>
|
||||
<!-- mysql end -->
|
||||
|
||||
<!--分页插件 start -->
|
||||
<dependency>
|
||||
<groupId>com.github.pagehelper</groupId>
|
||||
<artifactId>pagehelper-spring-boot-starter</artifactId>
|
||||
<version>1.2.5</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>org.mybatis</groupId>
|
||||
<artifactId>mybatis</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<!-- 插件 end -->
|
||||
|
||||
<!-- 参数验证 start -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-validation</artifactId>
|
||||
<version>2.2.8.RELEASE</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.projectlombok</groupId>
|
||||
<artifactId>lombok</artifactId>
|
||||
<version>RELEASE</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<!-- 参数验证 end -->
|
||||
|
||||
|
||||
</dependencies>
|
||||
|
|
@ -94,8 +42,8 @@
|
|||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>3.8.1</version>
|
||||
<configuration>
|
||||
<source>1.8</source>
|
||||
<target>1.8</target>
|
||||
<source>11</source>
|
||||
<target>11</target>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@ package com.rzyc.mapper.ex;
|
|||
import com.rzyc.model.ex.ExExamineItem;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
|
@ -14,6 +15,7 @@ import java.util.List;
|
|||
* @author
|
||||
* @since 2024-04-01
|
||||
*/
|
||||
@Repository
|
||||
public interface ExExamineItemMapper extends BaseMapper<ExExamineItem> {
|
||||
|
||||
/*考核项列表*/
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@ package com.rzyc.mapper.ex;
|
|||
import com.rzyc.model.ex.ExExamine;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
|
@ -14,6 +15,7 @@ import java.util.List;
|
|||
* @author
|
||||
* @since 2024-04-01
|
||||
*/
|
||||
@Repository
|
||||
public interface ExExamineMapper extends BaseMapper<ExExamine> {
|
||||
|
||||
/*考核列表*/
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@ package com.rzyc.mapper.ex;
|
|||
import com.rzyc.model.ex.ExPerform;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
|
|
@ -12,6 +13,7 @@ import org.apache.ibatis.annotations.Param;
|
|||
* @author
|
||||
* @since 2024-04-02
|
||||
*/
|
||||
@Repository
|
||||
public interface ExPerformMapper extends BaseMapper<ExPerform> {
|
||||
|
||||
/*查询总分*/
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@ package com.rzyc.mapper.ex;
|
|||
|
||||
import com.rzyc.model.ex.ExScoreFile;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
|
|
@ -11,6 +12,7 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
|||
* @author
|
||||
* @since 2024-04-02
|
||||
*/
|
||||
@Repository
|
||||
public interface ExScoreFileMapper extends BaseMapper<ExScoreFile> {
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@ package com.rzyc.mapper.ex;
|
|||
import com.rzyc.model.ex.ExScore;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import javax.validation.Valid;
|
||||
|
||||
|
|
@ -14,6 +15,7 @@ import javax.validation.Valid;
|
|||
* @author
|
||||
* @since 2024-04-02
|
||||
*/
|
||||
@Repository
|
||||
public interface ExScoreMapper extends BaseMapper<ExScore> {
|
||||
|
||||
/*部门评分信息*/
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@ package com.rzyc.mapper.ex;
|
|||
|
||||
import com.rzyc.model.ex.ExScoreRecord;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
|
|
@ -11,6 +12,7 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
|||
* @author
|
||||
* @since 2024-04-02
|
||||
*/
|
||||
@Repository
|
||||
public interface ExScoreRecordMapper extends BaseMapper<ExScoreRecord> {
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@ import com.rzyc.bean.ex.vo.StandardInfo;
|
|||
import com.rzyc.model.ex.ExStandard;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
|
@ -15,6 +16,7 @@ import java.util.List;
|
|||
* @author
|
||||
* @since 2024-04-01
|
||||
*/
|
||||
@Repository
|
||||
public interface ExStandardMapper extends BaseMapper<ExStandard> {
|
||||
|
||||
/*普通评分标准*/
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
package com.common.utils.pager;
|
||||
package com.rzyc.pager;
|
||||
|
||||
import java.lang.annotation.*;
|
||||
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package com.common.utils.pager;
|
||||
package com.rzyc.pager;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
|
||||
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package com.common.utils.pager;
|
||||
package com.rzyc.pager;
|
||||
|
||||
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
590
inventory-dao/src/main/java/com/rzyc/service/BaseService.java
Normal file
590
inventory-dao/src/main/java/com/rzyc/service/BaseService.java
Normal file
|
|
@ -0,0 +1,590 @@
|
|||
package com.rzyc.service;
|
||||
|
||||
import com.rzyc.config.ConstantsConfigure;
|
||||
import com.rzyc.mapper.*;
|
||||
import com.rzyc.mapper.check.*;
|
||||
import com.rzyc.mapper.ent.*;
|
||||
import com.rzyc.mapper.ex.*;
|
||||
import com.rzyc.mapper.log.OrgLogDangerOperateMapper;
|
||||
import com.rzyc.mapper.log.SysLogsMapper;
|
||||
import com.rzyc.mapper.organization.OrgBatchMapper;
|
||||
import com.rzyc.mapper.organization.OrgDangerMapper;
|
||||
import com.rzyc.mapper.organization.OrgEnterpriseMapper;
|
||||
import com.rzyc.mapper.organization.OrganizationMapper;
|
||||
import com.rzyc.mapper.oth.*;
|
||||
import com.rzyc.mapper.personal.SysResourceMapper;
|
||||
import com.rzyc.mapper.sys.*;
|
||||
import com.rzyc.mapper.user.*;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
|
||||
/**
|
||||
* @author dong
|
||||
* @date 2025-03-18 9:40
|
||||
* @Version V1.0
|
||||
*/
|
||||
public class BaseService {
|
||||
|
||||
|
||||
//培训学习
|
||||
@Autowired
|
||||
protected EducationStudyMapper educationStudyMapper;
|
||||
|
||||
//培训资料
|
||||
@Autowired
|
||||
protected EducationResourceMapper educationResourceMapper;
|
||||
|
||||
/*用户*/
|
||||
@Autowired
|
||||
protected SysUserMapper sysUserMapper;
|
||||
|
||||
/*部门*/
|
||||
@Autowired
|
||||
protected SysUnitDeptMapper sysUnitDeptMapper;
|
||||
|
||||
/*履职类别*/
|
||||
@Autowired
|
||||
protected ListPerformMapper listPerformMapper;
|
||||
|
||||
/*新闻*/
|
||||
@Autowired
|
||||
protected NewsCntMapper newsCntMapper;
|
||||
|
||||
/*地区信息*/
|
||||
@Autowired
|
||||
protected SysOrgMapper sysOrgMapper;
|
||||
|
||||
/*企业信息*/
|
||||
@Autowired
|
||||
protected SysEnterpriseMapper sysEnterpriseMapper;
|
||||
|
||||
//检查类型
|
||||
@Autowired
|
||||
protected ChkGovBillMapper chkGovBillMapper;
|
||||
|
||||
//检查项详情
|
||||
@Autowired
|
||||
protected ChkGovBillDetailMapper chkGovBillDetailMapper;
|
||||
|
||||
//检查记录
|
||||
@Autowired
|
||||
protected BookEntCheckMapper bookEntCheckMapper;
|
||||
|
||||
//检查记录详情
|
||||
@Autowired
|
||||
protected BookEntCheckDetailMapper bookEntCheckDetailMapper;
|
||||
|
||||
//隐患
|
||||
@Autowired
|
||||
protected BookEntHTMapper bookEntHTMapper;
|
||||
|
||||
//文件
|
||||
@Autowired
|
||||
protected SysdocumentMapper sysdocumentMapper;
|
||||
|
||||
//隐患 检查项关联
|
||||
@Autowired
|
||||
protected BookRelationMapper bookRelationMapper;
|
||||
|
||||
//检查人员表
|
||||
@Autowired
|
||||
protected ChkPersonMapper chkPersonMapper;
|
||||
|
||||
//检查库
|
||||
@Autowired
|
||||
protected ChkBillDetailMapper chkBillDetailMapper;
|
||||
|
||||
//职责
|
||||
@Autowired
|
||||
protected ListSafeMapper listSafeMapper;
|
||||
|
||||
//用户履职档案
|
||||
@Autowired
|
||||
protected ListFactorMapper listFactorMapper;
|
||||
|
||||
//动态
|
||||
@Autowired
|
||||
protected DynamicMapper dynamicMapper;
|
||||
|
||||
//隐患避难场所
|
||||
@Autowired
|
||||
protected OthRefugeMapper othRefugeMapper;
|
||||
|
||||
//应急队伍
|
||||
@Autowired
|
||||
protected OthTeamMapper othTeamMapper;
|
||||
|
||||
//应急队伍人员
|
||||
@Autowired
|
||||
protected OthPersonMapper othPersonMapper;
|
||||
|
||||
//应急装备
|
||||
@Autowired
|
||||
protected OthResourceMapper othResourceMapper;
|
||||
|
||||
//紧急预案
|
||||
@Autowired
|
||||
protected OthPlanMapper othPlanMapper;
|
||||
|
||||
//值班表
|
||||
@Autowired
|
||||
protected GovDutyMapper govDutyMapper;
|
||||
|
||||
//值班人员
|
||||
@Autowired
|
||||
protected GovDutyPersonMapper govDutyPersonMapper;
|
||||
|
||||
//企业清单
|
||||
@Autowired
|
||||
protected SysEntListMapper sysEntListMapper;
|
||||
|
||||
//企业用户
|
||||
@Autowired
|
||||
protected SysEntUserMapper sysEntUserMapper;
|
||||
|
||||
//企业承诺
|
||||
@Autowired
|
||||
protected EntPromiseMapper entPromiseMapper;
|
||||
|
||||
//企业承诺用户
|
||||
@Autowired
|
||||
protected EntPromiseUserMapper entPromiseUserMapper;
|
||||
|
||||
//重大危险源列表
|
||||
@Autowired
|
||||
protected EntRiskSourceMapper entRiskSourceMapper;
|
||||
|
||||
//企业清单关联表
|
||||
@Autowired
|
||||
protected EntBillConMapper entBillConMapper;
|
||||
|
||||
//履职记录详情
|
||||
@Autowired
|
||||
protected ListDetailMapper listDetailMapper;
|
||||
|
||||
//应急类型
|
||||
@Autowired
|
||||
protected OthTypeMapper othTypeMapper;
|
||||
|
||||
//角色
|
||||
@Autowired
|
||||
protected SysRoleMapper sysRoleMapper;
|
||||
|
||||
//行业类别
|
||||
@Autowired
|
||||
protected BaseInClassMapper baseInClassMapper;
|
||||
|
||||
//安全类别
|
||||
@Autowired
|
||||
protected BaseSafeClassMapper baseSafeClassMapper;
|
||||
|
||||
//任务
|
||||
@Autowired
|
||||
protected OATaskMapper oaTaskMapper;
|
||||
|
||||
//任务接收用户
|
||||
@Autowired
|
||||
protected OADistributionMapper oaDistributionMapper;
|
||||
|
||||
//动态分类
|
||||
@Autowired
|
||||
protected NewsClassMapper newsClassMapper;
|
||||
|
||||
//日志记录
|
||||
@Autowired
|
||||
protected SysLogOptMapper sysLogOptMapper;
|
||||
|
||||
//应急专家
|
||||
@Autowired
|
||||
protected OthExpertMapper othExpertMapper;
|
||||
|
||||
//履职记录-安全检查
|
||||
@Autowired
|
||||
protected ListdetacheckMapper listdetacheckMapper;
|
||||
|
||||
//事故
|
||||
@Autowired
|
||||
protected AccidentMapper accidentMapper;
|
||||
|
||||
//事故类型
|
||||
@Autowired
|
||||
protected AccidentTypeMapper accidentTypeMapper;
|
||||
|
||||
//政府部门
|
||||
@Autowired
|
||||
protected SysUnitMapper sysUnitMapper;
|
||||
|
||||
//日志
|
||||
@Autowired
|
||||
protected SysLogAuthMapper sysLogAuthMapper;
|
||||
|
||||
//app帮助文档
|
||||
@Autowired
|
||||
protected AppHelpMapper appHelpMapper;
|
||||
|
||||
//执法
|
||||
@Autowired
|
||||
protected BookLawMapper bookLawMapper;
|
||||
|
||||
//约谈
|
||||
@Autowired
|
||||
protected BookTalkMapper bookTalkMapper;
|
||||
|
||||
//企业统计信息
|
||||
@Autowired
|
||||
protected EntMessageMapper entMessageMapper;
|
||||
|
||||
//应急装备
|
||||
@Autowired
|
||||
protected OthEquipmentMapper othEquipmentMapper;
|
||||
|
||||
//类型
|
||||
@Autowired
|
||||
protected SysCodeMapper sysCodeMapper;
|
||||
|
||||
//功能
|
||||
@Autowired
|
||||
protected SysResourceMapper sysResourceMapper;
|
||||
|
||||
//角色资源
|
||||
@Autowired
|
||||
protected SysRoleResourceMapper sysRoleResourceMapper;
|
||||
|
||||
//浏览器对象
|
||||
@Autowired
|
||||
protected HttpServletRequest request;
|
||||
|
||||
@Autowired
|
||||
protected BasekpiMapper basekpiMapper;
|
||||
|
||||
//任务类型
|
||||
@Autowired
|
||||
protected OaTaskTypeMapper oaTaskTypeMapper;
|
||||
|
||||
//日志
|
||||
@Autowired
|
||||
protected SysLogsMapper sysLogsMapper;
|
||||
|
||||
//法规
|
||||
@Autowired
|
||||
protected SysStatuteMapper sysStatuteMapper;
|
||||
|
||||
//法规详情
|
||||
@Autowired
|
||||
protected SysStatuteDescMapper sysStatuteDescMapper;
|
||||
|
||||
//最小工作单元
|
||||
@Autowired
|
||||
protected MinWorkUnitMapper minWorkUnitMapper;
|
||||
|
||||
|
||||
//最小工作单元分类对应的检查项
|
||||
@Autowired
|
||||
protected MinMiddleIndexMapper minMiddleIndexMapper;
|
||||
|
||||
//最小工作单元检查中间表
|
||||
@Autowired
|
||||
protected MinWorkCheckMiddleMapper minWorkCheckMiddleMapper;
|
||||
|
||||
//检查记录,一次可以检查多个工作单元
|
||||
@Autowired
|
||||
protected MinCheckUnitIdsMapper minCheckUnitIdsMapper;
|
||||
|
||||
//最小工作单元分类
|
||||
@Autowired
|
||||
protected MinWorkUnitCategoryMapper minWorkUnitCategoryMapper;
|
||||
|
||||
//企业自查检查表
|
||||
@Autowired
|
||||
protected BookentcheckCompanyMapper bookentcheckCompanyMapper;
|
||||
|
||||
//企业自查检查项中间表
|
||||
@Autowired
|
||||
protected BookentcheckdetailCompanyMapper bookentcheckdetailCompanyMapper;
|
||||
|
||||
//企业自查隐患表
|
||||
@Autowired
|
||||
protected BookenthtCompanyMapper bookenthtCompanyMapper;
|
||||
|
||||
//通知
|
||||
@Autowired
|
||||
protected NoticeMapper noticeMapper;
|
||||
|
||||
//用户监管地区
|
||||
@Autowired
|
||||
protected SysUserAreaMapper sysUserAreaMapper;
|
||||
|
||||
//行业工作单元分类
|
||||
@Autowired
|
||||
protected IndustryWorkMapper industryWorkMapper;
|
||||
|
||||
//企业应急资源
|
||||
@Autowired
|
||||
protected EntEmEquipmentMapper entEmEquipmentMapper;
|
||||
|
||||
// //企业监管用户
|
||||
// @Autowired
|
||||
// protected EntUserMapper entUserMapper;
|
||||
|
||||
//责任树
|
||||
@Autowired
|
||||
protected DutyTreeMapper dutyTreeMapper;
|
||||
|
||||
//第三方机构
|
||||
@Autowired
|
||||
protected OrganizationMapper organizationMapper;
|
||||
|
||||
//第三方机构发起隐患
|
||||
@Autowired
|
||||
protected OrgDangerMapper orgDangerMapper;
|
||||
|
||||
//第三方机构管理企业关联表
|
||||
@Autowired
|
||||
protected OrgEnterpriseMapper orgEnterpriseMapper;
|
||||
|
||||
//三方机构隐患操作记录
|
||||
@Autowired
|
||||
protected OrgLogDangerOperateMapper orgLogDangerOperateMapper;
|
||||
|
||||
|
||||
//隐患类型
|
||||
@Autowired
|
||||
protected OrgBookTypeMapper orgBookTypeMapper;
|
||||
|
||||
//三方检查记录
|
||||
@Autowired
|
||||
protected OrgBatchMapper orgBatchMapper;
|
||||
|
||||
//仓库
|
||||
@Autowired
|
||||
protected OtheWareHouseMapper otheWareHouseMapper;
|
||||
|
||||
//设备清单
|
||||
@Autowired
|
||||
protected OtheCheckListMapper otheCheckListMapper;
|
||||
|
||||
//装备记录
|
||||
@Autowired
|
||||
protected OtheEquipRecordMapper otheEquipRecordMapper;
|
||||
|
||||
//仓库
|
||||
@Autowired
|
||||
protected StorageMapper storageMapper;
|
||||
|
||||
//权限
|
||||
@Autowired
|
||||
protected SysAuthMapper sysAuthMapper;
|
||||
|
||||
//部门角色
|
||||
@Autowired
|
||||
protected SysUnitRoleMapper sysUnitRoleMapper;
|
||||
|
||||
@Autowired
|
||||
protected OtheBackRecordMapper otheBackRecordMapper;
|
||||
|
||||
//配置文件
|
||||
@Autowired
|
||||
protected ConstantsConfigure constantsConfigure;
|
||||
|
||||
//最小工作单元格清单
|
||||
@Autowired
|
||||
protected ListWorkMapper listWorkMapper;
|
||||
|
||||
//清单考核指标
|
||||
@Autowired
|
||||
protected ListQuotaMapper listQuotaMapper;
|
||||
|
||||
//工作手册
|
||||
@Autowired
|
||||
protected ManualMapper manualMapper;
|
||||
|
||||
//工作手册标签
|
||||
@Autowired
|
||||
protected ManualLableMapper manualLableMapper;
|
||||
|
||||
//工作手册响应级别
|
||||
@Autowired
|
||||
protected ManualLevelMapper manualLevelMapper;
|
||||
|
||||
//工作手册时间
|
||||
@Autowired
|
||||
protected ManualTimeMapper manualTimeMapper;
|
||||
|
||||
//工作手册处置措施
|
||||
@Autowired
|
||||
protected ManualMeasuresMapper manualMeasuresMapper;
|
||||
|
||||
//工作手册处置措施标签
|
||||
@Autowired
|
||||
protected MaMeasuresLableMapper maMeasuresLableMapper;
|
||||
|
||||
//通知记录
|
||||
@Autowired
|
||||
protected NoRecordMapper noRecordMapper;
|
||||
|
||||
//危险源类型
|
||||
@Autowired
|
||||
protected RkRiskTypeMapper rkRiskTypeMapper;
|
||||
|
||||
//重大危险源
|
||||
@Autowired
|
||||
protected RkSourcesMapper rkSourcesMapper;
|
||||
|
||||
//文书模板
|
||||
@Autowired
|
||||
protected SysDocumenttempMapper sysDocumenttempMapper;
|
||||
|
||||
//企业清单
|
||||
@Autowired
|
||||
protected InListMapper inListMapper;
|
||||
|
||||
//所属清单项
|
||||
@Autowired
|
||||
protected InListItemMapper inListItemMapper;
|
||||
|
||||
//企业证照
|
||||
@Autowired
|
||||
protected EntCertificatesMapper entCertificatesMapper;
|
||||
|
||||
//用户任务关联
|
||||
@Autowired
|
||||
protected OaTaskUserMapper oaTaskUserMapper;
|
||||
|
||||
//任务记录
|
||||
@Autowired
|
||||
protected TaskRecordMapper taskRecordMapper;
|
||||
|
||||
//企业清单
|
||||
@Autowired
|
||||
protected InEntListMapper inEntListMapper;
|
||||
|
||||
//企业应急预案
|
||||
@Autowired
|
||||
protected EntEmReservePlanMapper entEmReservePlanMapper;
|
||||
|
||||
//政府智能预警
|
||||
@Autowired
|
||||
protected GovWarningMapper govWarningMapper;
|
||||
|
||||
//企业岗位
|
||||
@Autowired
|
||||
protected EntPostMapper entPostMapper;
|
||||
|
||||
//企业用户
|
||||
@Autowired
|
||||
protected EntUserMapper entUserMapper;
|
||||
|
||||
//企业公共岗位
|
||||
@Autowired
|
||||
protected InPostMapper inPostMapper;
|
||||
|
||||
//企业岗位关联责任清单
|
||||
@Autowired
|
||||
protected InPostItemMapper inPostItemMapper;
|
||||
|
||||
//企业岗位履职表
|
||||
@Autowired
|
||||
protected InPostListMapper inPostListMapper;
|
||||
|
||||
//企业岗位职责
|
||||
@Autowired
|
||||
protected EntPostDutyMapper entPostDutyMapper;
|
||||
|
||||
//企业岗位任务
|
||||
@Autowired
|
||||
protected EntPostTaskMapper entPostTaskMapper;
|
||||
|
||||
//智能预警类型
|
||||
@Autowired
|
||||
protected SysWarningTypeMapper sysWarningTypeMapper;
|
||||
|
||||
//智能预警类型
|
||||
@Autowired
|
||||
protected SysWarningMapper sysWarningMapper;
|
||||
|
||||
//智能预警类型
|
||||
@Autowired
|
||||
protected SysWarningUserMapper sysWarningUserMapper;
|
||||
|
||||
//变更记录
|
||||
@Autowired
|
||||
protected ListchangeMapper listchangeMapper;
|
||||
|
||||
//企业周边情况
|
||||
@Autowired
|
||||
protected RkSensitiveTypeMapper rkSensitiveTypeMapper;
|
||||
|
||||
//企业周边数据信息
|
||||
@Autowired
|
||||
protected RkEntSensitiveMapper rkEntSensitiveMapper;
|
||||
|
||||
//企业风险分级条款
|
||||
@Autowired
|
||||
protected RkScoreTypeMapper rkScoreTypeMapper;
|
||||
|
||||
//企业风险评估分数
|
||||
@Autowired
|
||||
protected RkEnterpriseScoreMapper rkEnterpriseScoreMapper;
|
||||
|
||||
//风险评估分数
|
||||
@Autowired
|
||||
protected RkCompanyDiagnosisMapper rkCompanyDiagnosisMapper;
|
||||
|
||||
//企业履职清单
|
||||
@Autowired
|
||||
protected EntPostListMapper entPostListMapper;
|
||||
|
||||
//部门行业关联
|
||||
@Autowired
|
||||
protected SysUnitTradeMapper sysUnitTradeMapper;
|
||||
|
||||
//企业设备
|
||||
@Autowired
|
||||
protected EntDeviceMapper entDeviceMapper;
|
||||
|
||||
//企业人员证照
|
||||
@Autowired
|
||||
protected EntUserCredentialMapper entUserCredentialMapper;
|
||||
|
||||
//app使用帮助
|
||||
@Autowired
|
||||
protected AppHelpVersionMapper appHelpVersionMapper;
|
||||
|
||||
//履职记录关联信息
|
||||
@Autowired
|
||||
protected ListRelationMapper listRelationMapper;
|
||||
|
||||
//ip登录信息
|
||||
@Autowired
|
||||
protected SysUserLoginMapper sysUserLoginMapper;
|
||||
|
||||
//党政同责考核
|
||||
@Autowired
|
||||
protected ExExamineMapper exExamineMapper;
|
||||
|
||||
//党政同责考核项
|
||||
@Autowired
|
||||
protected ExExamineItemMapper exExamineItemMapper;
|
||||
|
||||
//党政同责考核内容
|
||||
@Autowired
|
||||
protected ExStandardMapper exStandardMapper;
|
||||
|
||||
//部门评分信息
|
||||
@Autowired
|
||||
protected ExPerformMapper exPerformMapper;
|
||||
|
||||
//评分信息
|
||||
@Autowired
|
||||
protected ExScoreMapper exScoreMapper;
|
||||
|
||||
//评分附件信息
|
||||
@Autowired
|
||||
protected ExScoreFileMapper exScoreFileMapper;
|
||||
|
||||
//评分记录
|
||||
@Autowired
|
||||
protected ExScoreRecordMapper exScoreRecordMapper;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
package com.rzyc.service;
|
||||
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* 省厅接口对接
|
||||
* @author dong
|
||||
* @date 2025-03-18 9:40
|
||||
* @Version V1.0
|
||||
*/
|
||||
@Service
|
||||
public class ProvinceService extends BaseService{
|
||||
|
||||
|
||||
}
|
||||
|
|
@ -3,10 +3,10 @@
|
|||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-parent</artifactId>
|
||||
<version>2.2.5.RELEASE</version>
|
||||
<relativePath/> <!-- lookup parent from repository -->
|
||||
<groupId>com.rzyc</groupId>
|
||||
<artifactId>inventory</artifactId>
|
||||
<version>0.0.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
<groupId>com.rzyc</groupId>
|
||||
|
|
@ -23,146 +23,9 @@
|
|||
|
||||
<dependencies>
|
||||
|
||||
<!-- spring boot start -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-thymeleaf</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-test</artifactId>
|
||||
<scope>test</scope>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>org.junit.vintage</groupId>
|
||||
<artifactId>junit-vintage-engine</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-web</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- spring boot end -->
|
||||
|
||||
<!-- aop start -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-aop</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.aspectj</groupId>
|
||||
<artifactId>aspectjrt</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.aspectj</groupId>
|
||||
<artifactId>aspectjweaver</artifactId>
|
||||
</dependency>
|
||||
<!-- aop end -->
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- swagger start -->
|
||||
<dependency>
|
||||
<groupId>io.springfox</groupId>
|
||||
<artifactId>springfox-swagger2</artifactId>
|
||||
<version>2.9.2</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>io.swagger</groupId>
|
||||
<artifactId>swagger-models</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.swagger</groupId>
|
||||
<artifactId>swagger-models</artifactId>
|
||||
<version>1.5.21</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.springfox</groupId>
|
||||
<artifactId>springfox-swagger-ui</artifactId>
|
||||
<version>2.9.2</version>
|
||||
</dependency>
|
||||
<!-- swagger end -->
|
||||
|
||||
<!-- 参数验证 start -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-validation</artifactId>
|
||||
<version>2.2.8.RELEASE</version>
|
||||
</dependency>
|
||||
<!-- 参数验证 end -->
|
||||
|
||||
|
||||
<!-- baidu start -->
|
||||
<dependency>
|
||||
<groupId>com.baidu.aip</groupId>
|
||||
<artifactId>java-sdk</artifactId>
|
||||
<version>4.15.3</version>
|
||||
</dependency>
|
||||
<!-- baidu end -->
|
||||
|
||||
<!--xunfeiVoice start-->
|
||||
<dependency>
|
||||
<groupId>commons-codec</groupId>
|
||||
<artifactId>commons-codec</artifactId>
|
||||
<version>1.9</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.java-websocket</groupId>
|
||||
<artifactId>Java-WebSocket</artifactId>
|
||||
<version>1.3.4</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-logging</groupId>
|
||||
<artifactId>commons-logging</artifactId>
|
||||
<version>1.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.httpcomponents</groupId>
|
||||
<artifactId>httpclient</artifactId>
|
||||
<version>4.5.8</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.httpcomponents</groupId>
|
||||
<artifactId>httpcore</artifactId>
|
||||
<version>4.4.11</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.httpcomponents</groupId>
|
||||
<artifactId>httpmime</artifactId>
|
||||
<version>4.5.8</version>
|
||||
</dependency>
|
||||
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-websocket</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- pdf start -->
|
||||
|
||||
<dependency>
|
||||
<groupId>com.itextpdf</groupId>
|
||||
<artifactId>itextpdf</artifactId>
|
||||
<version>5.0.6</version>
|
||||
</dependency>
|
||||
<!-- pdf end -->
|
||||
|
||||
<!-- 公用方法 start -->
|
||||
<dependency>
|
||||
<groupId>com.rzyc</groupId>
|
||||
|
|
@ -178,63 +41,6 @@
|
|||
<version>0.0.1-SNAPSHOT</version>
|
||||
</dependency>
|
||||
|
||||
|
||||
<!-- 配置文件密码加密 start -->
|
||||
<dependency>
|
||||
<groupId>com.github.ulisesbocchio</groupId>
|
||||
<artifactId>jasypt-spring-boot-starter</artifactId>
|
||||
<version>2.1.0</version>
|
||||
</dependency>
|
||||
<!-- 配置文件密码加密 end -->
|
||||
|
||||
<!-- spring security start -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.security</groupId>
|
||||
<artifactId>spring-security-core</artifactId>
|
||||
<version>5.2.2.RELEASE</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.security</groupId>
|
||||
<artifactId>spring-security-config</artifactId>
|
||||
<version>5.2.2.RELEASE</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.security</groupId>
|
||||
<artifactId>spring-security-web</artifactId>
|
||||
<version>5.7.3</version>
|
||||
</dependency>
|
||||
<!-- spring security end -->
|
||||
<dependency>
|
||||
<groupId>org.projectlombok</groupId>
|
||||
<artifactId>lombok</artifactId>
|
||||
<version>RELEASE</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
<!-- redis -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-data-redis</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.commons</groupId>
|
||||
<artifactId>commons-pool2</artifactId>
|
||||
</dependency>
|
||||
<!-- redis -->
|
||||
<!-- easyExcel -->
|
||||
<dependency>
|
||||
<groupId>com.alibaba</groupId>
|
||||
<artifactId>easyexcel</artifactId>
|
||||
<version>3.1.3</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.testng</groupId>
|
||||
<artifactId>testng</artifactId>
|
||||
<version>RELEASE</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<!-- easyExcel -->
|
||||
|
||||
</dependencies>
|
||||
<build>
|
||||
<plugins>
|
||||
|
|
@ -247,8 +53,8 @@
|
|||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>3.8.1</version>
|
||||
<configuration>
|
||||
<source>1.8</source>
|
||||
<target>1.8</target>
|
||||
<source>11</source>
|
||||
<target>11</target>
|
||||
</configuration>
|
||||
</plugin>
|
||||
|
||||
|
|
|
|||
|
|
@ -7,7 +7,6 @@ import org.apache.tomcat.util.http.fileupload.impl.SizeLimitExceededException;
|
|||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.http.HttpStatus;
|
||||
import org.springframework.security.access.AccessDeniedException;
|
||||
import org.springframework.validation.BindException;
|
||||
import org.springframework.web.bind.MethodArgumentNotValidException;
|
||||
import org.springframework.web.bind.annotation.ExceptionHandler;
|
||||
|
|
@ -164,20 +163,4 @@ public class ExceptionAdvice {
|
|||
return result;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @author Xuwanxin
|
||||
* 权限不足总捕获异常
|
||||
* */
|
||||
@ResponseBody
|
||||
@ExceptionHandler(value = AccessDeniedException.class)
|
||||
public SingleResult<String> handleAccessRE(AccessDeniedException e) {
|
||||
e.printStackTrace();
|
||||
logger.info("权限不足");
|
||||
SingleResult<String> result = new SingleResult<>();
|
||||
result.setCode(Code.AUTHORIZATION_FAILED.getCode());
|
||||
result.setMessage(Message.AUTHORIZATION_FAILED);
|
||||
return result;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,10 +9,6 @@ import org.aspectj.lang.annotation.Pointcut;
|
|||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.core.annotation.Order;
|
||||
import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
|
||||
import org.springframework.security.core.GrantedAuthority;
|
||||
import org.springframework.security.core.authority.SimpleGrantedAuthority;
|
||||
import org.springframework.security.core.context.SecurityContextHolder;
|
||||
import org.springframework.stereotype.Component;
|
||||
import org.springframework.web.context.request.RequestContextHolder;
|
||||
import org.springframework.web.context.request.ServletRequestAttributes;
|
||||
|
|
@ -81,12 +77,6 @@ public class LoginAspect {
|
|||
if (!JwtUtil.checkToken(userToken)) {
|
||||
throw new TokenException("user token is expire");
|
||||
}
|
||||
List<GrantedAuthority> authoritys = new ArrayList<GrantedAuthority>();
|
||||
//给通过登陆的进行role权限,也可以根据业务调整
|
||||
authoritys.add(new SimpleGrantedAuthority("ROLE_ADMIN"));
|
||||
UsernamePasswordAuthenticationToken authenticationToken =
|
||||
new UsernamePasswordAuthenticationToken(null,authoritys);
|
||||
SecurityContextHolder.getContext().setAuthentication(authenticationToken);
|
||||
}
|
||||
} else {
|
||||
throw new TokenException("user token is null");
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ import java.util.List;
|
|||
@Aspect
|
||||
@Component
|
||||
public class PageAspect {
|
||||
@Pointcut("@annotation(com.common.utils.pager.PageOperation)execution(* com.rzyc..*.*(..))")
|
||||
@Pointcut("@annotation(com.rzyc.pager.PageOperation)execution(* com.rzyc..*.*(..))")
|
||||
public void page() {}
|
||||
|
||||
@Before("page()")
|
||||
|
|
|
|||
|
|
@ -1,92 +0,0 @@
|
|||
package com.rzyc.config;
|
||||
|
||||
import com.rzyc.filter.JwtAuthenticationTokenFiler;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.springframework.security.authentication.AuthenticationManager;
|
||||
import org.springframework.security.config.annotation.authentication.builders.AuthenticationManagerBuilder;
|
||||
import org.springframework.security.config.annotation.method.configuration.EnableGlobalMethodSecurity;
|
||||
import org.springframework.security.config.annotation.web.builders.HttpSecurity;
|
||||
import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity;
|
||||
import org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter;
|
||||
import org.springframework.security.config.http.SessionCreationPolicy;
|
||||
import org.springframework.security.core.userdetails.UserDetailsService;
|
||||
import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
|
||||
import org.springframework.security.crypto.password.PasswordEncoder;
|
||||
import org.springframework.security.web.authentication.UsernamePasswordAuthenticationFilter;
|
||||
|
||||
/**
|
||||
* spring security config
|
||||
* @author Xuwanxin
|
||||
* @date 2022/9/26
|
||||
* */
|
||||
@Configuration
|
||||
@EnableWebSecurity
|
||||
@EnableGlobalMethodSecurity(prePostEnabled = true)
|
||||
public class SecurityConfig extends WebSecurityConfigurerAdapter {
|
||||
|
||||
/**
|
||||
* 数据库用户连接
|
||||
*/
|
||||
private UserDetailsService userService;
|
||||
|
||||
|
||||
/**
|
||||
* token jwt 验证拦截器
|
||||
* */
|
||||
private JwtAuthenticationTokenFiler jwtAuthenticationTokenFiler;
|
||||
|
||||
@Autowired
|
||||
public void setSecurityConfigFinder(UserDetailsService userService,JwtAuthenticationTokenFiler jwtAuthenticationTokenFiler) {
|
||||
this.userService = userService;
|
||||
this.jwtAuthenticationTokenFiler = jwtAuthenticationTokenFiler;
|
||||
}
|
||||
|
||||
|
||||
@Bean
|
||||
public PasswordEncoder getPasswordEncoder() {
|
||||
return new BCryptPasswordEncoder();
|
||||
}
|
||||
|
||||
/**
|
||||
* 暴露AuthenticationManager,存上下文
|
||||
* */
|
||||
@Bean
|
||||
@Override
|
||||
public AuthenticationManager authenticationManagerBean() throws Exception
|
||||
{
|
||||
return super.authenticationManagerBean();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void configure(HttpSecurity http) throws Exception {
|
||||
http
|
||||
.authorizeRequests()
|
||||
// 对于登录接口 允许匿名访问
|
||||
.antMatchers("personal/login","personal/entlogin","common/generateCode").anonymous()
|
||||
//放行swagger
|
||||
.antMatchers("/swagger-ui.html","/swagger-resources/**","/webjars/**","/v2/**","/api/**").permitAll()
|
||||
// 除上面外的所有请求全部需要鉴权认证,配置退出路径
|
||||
.anyRequest().authenticated()
|
||||
.and()
|
||||
.logout().logoutUrl( "/logout")
|
||||
.and()
|
||||
//关闭security默认登陆框
|
||||
.formLogin().disable()
|
||||
//关闭csrf
|
||||
.csrf().disable()
|
||||
//不通过Session获取SecurityContext
|
||||
.sessionManagement().sessionCreationPolicy(SessionCreationPolicy.STATELESS)
|
||||
.and().addFilterBefore(jwtAuthenticationTokenFiler, UsernamePasswordAuthenticationFilter.class)
|
||||
;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
protected void configure(AuthenticationManagerBuilder auth) throws Exception {
|
||||
// 配置数据库访问,认证步骤
|
||||
auth.userDetailsService(userService);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -1,51 +0,0 @@
|
|||
package com.rzyc.config;
|
||||
|
||||
import org.springframework.security.core.GrantedAuthority;
|
||||
import org.springframework.security.core.userdetails.User;
|
||||
|
||||
import java.util.Collection;
|
||||
|
||||
|
||||
/**
|
||||
* spring security UserDetails Custom Part
|
||||
* @author Xuwanxin
|
||||
* @date 2022/9/28
|
||||
* */
|
||||
|
||||
public class UserDetailsAndId extends User {
|
||||
|
||||
/**
|
||||
* 用户id
|
||||
* */
|
||||
private String id;
|
||||
|
||||
/**
|
||||
* 企业岗位id
|
||||
* */
|
||||
private String postId;
|
||||
|
||||
public String getPostId() {
|
||||
return postId;
|
||||
}
|
||||
|
||||
public void setPostId(String postId) {
|
||||
this.postId = postId;
|
||||
}
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
|
||||
public UserDetailsAndId(String username, String password, Collection<? extends GrantedAuthority> authorities, String id,String postId) {
|
||||
super(username, password, authorities);
|
||||
setId(id);
|
||||
setPostId(postId);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -17,7 +17,6 @@ import io.swagger.annotations.Api;
|
|||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
|
@ -52,7 +51,6 @@ public class EmergencyEquipmentController {
|
|||
*/
|
||||
@ApiOperation(value = "应急资源列表", notes = "应急资源列表")
|
||||
@GetMapping(value = "/entEmEquipmentList")
|
||||
@PreAuthorize("hasAnyAuthority('entEmEquipmentList','entEmEquipmentList:update')")
|
||||
@MethodAnnotation(authorizations = {"entEmEquipmentList","entEmEquipmentList:update"},name = "应急资源列表")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "enterpriseId", value = "企业id",required = true, dataType = "string"),
|
||||
|
|
@ -74,7 +72,6 @@ public class EmergencyEquipmentController {
|
|||
*/
|
||||
@ApiOperation(value = "应急资源修改", notes = "应急资源修改")
|
||||
@PostMapping(value = "/entEmEquipmentUpdate")
|
||||
@PreAuthorize("hasAnyAuthority('entEmEquipmentList:update')")
|
||||
@MethodAnnotation(authorizations = {"entEmEquipmentList:update"},name = "应急资源修改")
|
||||
@ResponseBody
|
||||
public SingleResult entEmEquipmentUpdate(@RequestBody@Valid EntEmEquipmentDto entEmEquipmentDto)throws Exception{
|
||||
|
|
@ -89,7 +86,6 @@ public class EmergencyEquipmentController {
|
|||
*/
|
||||
@ApiOperation(value = "应急专家列表", notes = "应急专家列表")
|
||||
@GetMapping(value = "/entEmExpertList")
|
||||
@PreAuthorize("hasAnyAuthority('entEmExpertList','entEmExpertList:update')")
|
||||
@MethodAnnotation(authorizations = {"entEmExpertList","entEmExpertList:update"},name = "应急专家列表")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "enterpriseId", value = "企业id",required = true, dataType = "string"),
|
||||
|
|
@ -117,7 +113,6 @@ public class EmergencyEquipmentController {
|
|||
*/
|
||||
@ApiOperation(value = "应急专家修改", notes = "应急专家修改")
|
||||
@PostMapping(value = "/entEmExpertUpdate")
|
||||
@PreAuthorize("hasAnyAuthority('entEmExpertList:update')")
|
||||
@MethodAnnotation(authorizations = {"entEmExpertList:update"},name = "应急专家修改")
|
||||
@ResponseBody
|
||||
public SingleResult entEmExpertUpdate(@RequestBody@Valid EntEmExpertDto entEmExpertDto)throws Exception{
|
||||
|
|
@ -131,7 +126,6 @@ public class EmergencyEquipmentController {
|
|||
*/
|
||||
@ApiOperation(value = "应急预案列表", notes = "应急预案列表")
|
||||
@GetMapping(value = "/entEmReservePlanList")
|
||||
@PreAuthorize("hasAnyAuthority('entEmReservePlanList','entEmReservePlanList:update')")
|
||||
@MethodAnnotation(authorizations = {"entEmReservePlanList","entEmReservePlanList:update"},name = "应急预案列表")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "enterpriseId", value = "企业id",required = true, dataType = "string"),
|
||||
|
|
@ -154,7 +148,6 @@ public class EmergencyEquipmentController {
|
|||
*/
|
||||
@ApiOperation(value = "应急预案修改", notes = "应急预案修改")
|
||||
@PostMapping(value = "/entEmReservePlanUpdate")
|
||||
@PreAuthorize("hasAnyAuthority('entEmReservePlanList:update')")
|
||||
@MethodAnnotation(authorizations = {"entEmReservePlanList:update"},name = "应急预案修改")
|
||||
@ResponseBody
|
||||
public SingleResult entEmReservePlanUpdate(@RequestBody@Valid EntEmReservePlanDto entEmReservePlanDto)throws Exception{
|
||||
|
|
@ -169,7 +162,6 @@ public class EmergencyEquipmentController {
|
|||
*/
|
||||
@ApiOperation(value = "应急演练列表", notes = "应急演练列表")
|
||||
@GetMapping(value = "/entEmRehearsalList")
|
||||
@PreAuthorize("hasAnyAuthority('entEmRehearsalList','entEmRehearsalList:update')")
|
||||
@MethodAnnotation(authorizations = {"entEmRehearsalList","entEmRehearsalList:update"},name = "应急演练列表")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "enterpriseId", value = "企业id",required = true, dataType = "string"),
|
||||
|
|
@ -195,7 +187,6 @@ public class EmergencyEquipmentController {
|
|||
*/
|
||||
@ApiOperation(value = "应急演练修改", notes = "应急演练修改")
|
||||
@PostMapping(value = "/entEmRehearsalUpdate")
|
||||
@PreAuthorize("hasAnyAuthority('entEmRehearsalList:update')")
|
||||
@MethodAnnotation(authorizations = {"entEmRehearsalList:update"},name = "应急演练修改")
|
||||
@ResponseBody
|
||||
public SingleResult entEmRehearsalUpdate(@RequestBody@Valid EntEmRehearsalDto entEmRehearsalDto)throws Exception{
|
||||
|
|
@ -211,7 +202,6 @@ public class EmergencyEquipmentController {
|
|||
*/
|
||||
@ApiOperation(value = "应急演练删除", notes = "应急演练删除")
|
||||
@GetMapping(value = "/entEmRehearsalDelete")
|
||||
@PreAuthorize("hasAnyAuthority('entEmRehearsalList:delete')")
|
||||
@MethodAnnotation(authorizations = {"entEmRehearsalList:delete"},name = "应急演练删除")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "id", value = "主键",required = true, dataType = "string"),
|
||||
|
|
@ -229,7 +219,6 @@ public class EmergencyEquipmentController {
|
|||
*/
|
||||
@ApiOperation(value = "应急预案删除", notes = "应急预案删除")
|
||||
@GetMapping(value = "/entEmReservePlanDelete")
|
||||
@PreAuthorize("hasAnyAuthority('entEmReservePlanList:delete')")
|
||||
@MethodAnnotation(authorizations = {"entEmReservePlanList:delete"},name = "应急预案删除")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "id", value = "主键",required = true, dataType = "string"),
|
||||
|
|
@ -246,7 +235,6 @@ public class EmergencyEquipmentController {
|
|||
*/
|
||||
@ApiOperation(value = "应急专家删除", notes = "应急专家删除")
|
||||
@GetMapping(value = "/entEmExpertDelete")
|
||||
@PreAuthorize("hasAnyAuthority('entEmExpertList:delete')")
|
||||
@MethodAnnotation(authorizations = {"entEmExpertList:delete"},name = "应急专家删除")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "id", value = "主键",required = true, dataType = "string"),
|
||||
|
|
@ -264,7 +252,6 @@ public class EmergencyEquipmentController {
|
|||
*/
|
||||
@ApiOperation(value = "应急资源删除", notes = "应急资源删除")
|
||||
@GetMapping(value = "/entEmEquipmentDelete")
|
||||
@PreAuthorize("hasAnyAuthority('entEmEquipmentList:delete')")
|
||||
@MethodAnnotation(authorizations = {"entEmEquipmentList:delete"},name = "应急资源删除")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "id", value = "主键",required = true, dataType = "string"),
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ import io.swagger.annotations.Api;
|
|||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
|
@ -54,7 +53,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
@ApiImplicitParam(name = "enterpriseId", value = "公司id", required = true, dataType = "string")
|
||||
})
|
||||
@GetMapping(value = "/entEquipmentTypeList")
|
||||
@PreAuthorize("hasAnyAuthority('entEquipmentTypeList','entEquipmentList:update')")
|
||||
@MethodAnnotation(authorizations = {"entEquipmentTypeList","entEquipmentList:update"},name = "企业设备类型列表")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntDeviceType>> entEquipmentTypeList(@RequestParam(required = true) String enterpriseId)throws Exception{
|
||||
|
|
@ -78,7 +76,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
@ApiImplicitParam(name = "keyWord", value = "关键字", required = false, dataType = "string")
|
||||
})
|
||||
@GetMapping(value = "/entEquipmentList")
|
||||
@PreAuthorize("hasAnyAuthority('entEquipmentList','entEquipmentList:update')")
|
||||
@MethodAnnotation(authorizations = {"entEquipmentList","entEquipmentList:update"},name = "企业设备列表")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntDevice>> entEquipmentList(@RequestParam(required = true) String enterpriseId, String typeId, Integer page, Integer pageSize, String keyWord)throws Exception{
|
||||
|
|
@ -97,7 +94,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
@ApiImplicitParam(name = "deviceId", value = "设备id", required = true, dataType = "string"),
|
||||
})
|
||||
@GetMapping(value = "/deviceDetail")
|
||||
@PreAuthorize("hasAnyAuthority('entEquipmentList')")
|
||||
@MethodAnnotation(authorizations = {"entEquipmentList"},name = "企业设备详细")
|
||||
@ResponseBody
|
||||
public SingleResult<EntDevice> deviceDetail(@RequestParam(required = true) String deviceId)throws Exception{
|
||||
|
|
@ -118,7 +114,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
@ApiImplicitParam(name = "deviceId", value = "设备id", required = true, dataType = "string")
|
||||
})
|
||||
@GetMapping(value = "/entEquipmentStatistic")
|
||||
@PreAuthorize("hasAnyAuthority('entEquipmentStatistic')")
|
||||
@MethodAnnotation(authorizations = {"entEquipmentStatistic"},name = "企业设备保养和维修检查记录统计")
|
||||
@ResponseBody
|
||||
public SingleResult<EntDevice> entEquipmentStatistic(@RequestParam(required = true) String enterpriseId, String deviceId)throws Exception{
|
||||
|
|
@ -132,7 +127,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "新增设备类型,修改设备类型", notes = "新增设备类型,修改设备类型")
|
||||
@PostMapping(value = "/addOrUpdateEntEquipmentType")
|
||||
@PreAuthorize("hasAnyAuthority('entEquipmentType:update')")
|
||||
@MethodAnnotation(authorizations = {"entEquipmentType:update"},name = "新增设备类型,修改设备类型")
|
||||
@ResponseBody
|
||||
public SingleResult addOrUpdateEntEquipmentType(@RequestBody AddOrUpdateEntEquipmentTypeDto addOrUpdateEntEquipmentTypeDto)throws Exception{
|
||||
|
|
@ -146,7 +140,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "删除设备类型", notes = "删除设备类型")
|
||||
@PostMapping(value = "/delDeviceType")
|
||||
@PreAuthorize("hasAnyAuthority('entEquipmentType:delete')")
|
||||
@MethodAnnotation(authorizations = {"entEquipmentType:delete"},name = "删除设备类型")
|
||||
@ResponseBody
|
||||
public SingleResult delDeviceType(String typeId,String enterpriseId)throws Exception{
|
||||
|
|
@ -163,7 +156,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "新增设备,修改设备", notes = "新增设备,修改设备")
|
||||
@PostMapping(value = "/addOrUpdateEntEquipment")
|
||||
@PreAuthorize("hasAnyAuthority('entEquipment:update')")
|
||||
@MethodAnnotation(authorizations = {"entEquipment:update"},name = "新增设备,修改设备")
|
||||
@ResponseBody
|
||||
public SingleResult addOrUpdateEntEquipment(@RequestBody AddOrUpdateEntEquipmentDto addOrUpdateEntEquipmentDto)throws Exception{
|
||||
|
|
@ -177,7 +169,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "设备周期巡检", notes = "设备周期巡检")
|
||||
@GetMapping(value = "/deviceInspectionCycle")
|
||||
@PreAuthorize("hasAnyAuthority('deviceInspectionCycle','deviceInspectionCycle:update')")
|
||||
@MethodAnnotation(authorizations = {"deviceInspectionCycle","deviceInspectionCycle:update"},name = "设备维护周期")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "inspectionName", value = "巡检名", required = false, dataType = "string"),
|
||||
|
|
@ -196,7 +187,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "设备周期巡检-添加和修改巡检项目", notes = "设备周期巡检-添加和修巡检项目")
|
||||
@PostMapping(value = "/addOrUpdateDeviceInspectionCycle")
|
||||
@PreAuthorize("hasAnyAuthority('deviceInspectionCycle:update')")
|
||||
@MethodAnnotation(authorizations = {"deviceInspectionCycle:update"},name = "设备周期巡检-添加和修巡检项目")
|
||||
@ResponseBody
|
||||
public SingleResult addOrUpdateDeviceInspectionCycle(@RequestBody AddOrUpdateDeviceInspectionCycleDto addOrUpdateDeviceInspectionCycleDto)throws Exception{
|
||||
|
|
@ -210,7 +200,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "设备巡检记录-添加和修改巡检记录", notes = "设备巡检记录-添加和修改巡检记录")
|
||||
@PostMapping(value = "/addOrUpdateInspectionAddOrRecord")
|
||||
@PreAuthorize("hasAnyAuthority('addOrUpdateInspectionRecord:update')")
|
||||
@MethodAnnotation(authorizations = {"addOrUpdateInspectionRecord:update"},name = "设备巡检记录-添加和修改巡检记录")
|
||||
@ResponseBody
|
||||
public SingleResult addOrUpdateInspectionRecord(@RequestBody AddOrUpdateInspectionRecordDto addOrUpdateInspectionRecordDto)throws Exception{
|
||||
|
|
@ -224,7 +213,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "设备巡检记录", notes = "设备巡检记录")
|
||||
@GetMapping(value = "/insRecord")
|
||||
@PreAuthorize("hasAnyAuthority('insRecord','insRecord:update')")
|
||||
@MethodAnnotation(authorizations = {"insRecord","insRecord:update"},name = "设备巡检记录")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntInsRecord>> insRecord(String deviceId,String inspectionRecordName,Integer page,Integer pageSize)throws Exception{
|
||||
|
|
@ -240,7 +228,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
**/
|
||||
@ApiOperation(value = "备件列表", notes = "备件列表")
|
||||
@GetMapping(value = "/sparePartList")
|
||||
@PreAuthorize("hasAnyAuthority('sparePartList','sparePartList:update')")
|
||||
@MethodAnnotation(authorizations = {"sparePartList","sparePartList:update"},name = "备件列表")
|
||||
@ResponseBody
|
||||
public SingleResult<List<SparePart>> sparePartList(String name, Integer page, Integer pageSize)throws Exception{
|
||||
|
|
@ -255,7 +242,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
**/
|
||||
@ApiOperation(value = "备件列表-新增和修改", notes = "备件列表-新增和修改")
|
||||
@PostMapping(value = "/sparePartAddOrUpdate")
|
||||
@PreAuthorize("hasAnyAuthority('sparePartList:update')")
|
||||
@MethodAnnotation(authorizations = {"sparePartList:update"},name = "备件列表-新增和修改")
|
||||
@ResponseBody
|
||||
public SingleResult sparePartUpdate(SparePartDto sparePartDto)throws Exception{
|
||||
|
|
@ -270,7 +256,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
**/
|
||||
@ApiOperation(value = "保养计划-新增和修改", notes = "保养计划-新增和修改")
|
||||
@PostMapping(value = "/entDeviceMaintenancePlanAddOrUpdate")
|
||||
@PreAuthorize("hasAnyAuthority('entDeviceMaintenancePlan:update')")
|
||||
@MethodAnnotation(authorizations = {"entDeviceMaintenancePlan:update"},name = "保养计划-新增和修改")
|
||||
@ResponseBody
|
||||
public SingleResult entDeviceMaintenancePlanUpdate(@RequestBody EntDeviceMaintenancePlanDto deviceMaintenancePlanDto)throws Exception{
|
||||
|
|
@ -285,7 +270,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
**/
|
||||
@ApiOperation(value = "保养计划列表", notes = "保养计划列表")
|
||||
@GetMapping(value = "/entDeviceMaintenancePlan")
|
||||
@PreAuthorize("hasAnyAuthority('entDeviceMaintenancePlan','entDeviceMaintenancePlan:update')")
|
||||
@MethodAnnotation(authorizations = {"entDeviceMaintenancePlan","entDeviceMaintenancePlan:update"},name = "保养计划列表")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntDeviceMaintenancePlan>> entDeviceMaintenancePlan(String deviceId, Integer page, Integer pageSize)throws Exception{
|
||||
|
|
@ -301,7 +285,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
**/
|
||||
@ApiOperation(value = "保养记录-新增和修改", notes = "保养记录-新增和修改")
|
||||
@PostMapping(value = "/entDeviceMaintenanceRecordAddOrUpdate")
|
||||
@PreAuthorize("hasAnyAuthority('entDeviceMaintenanceRecord:update')")
|
||||
@MethodAnnotation(authorizations = {"entDeviceMaintenanceRecord:update"},name = "保养记录-新增和修改")
|
||||
@ResponseBody
|
||||
public SingleResult entDeviceMaintenanceRecordUpdate(@RequestBody EntDeviceMaintenanceRecordDto entDeviceMaintenanceRecordDto)throws Exception{
|
||||
|
|
@ -318,7 +301,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
**/
|
||||
@ApiOperation(value = "保养记录", notes = "保养记录")
|
||||
@GetMapping(value = "/entDeviceMaintenanceRecord")
|
||||
@PreAuthorize("hasAnyAuthority('entDeviceMaintenanceRecord','entDeviceMaintenanceRecord:update')")
|
||||
@MethodAnnotation(authorizations = {"entDeviceMaintenanceRecord","entDeviceMaintenanceRecord:update"},name = "保养记录")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntDeviceMaintenanceRecord>> entDeviceMaintenanceRecord(String deviceId, Integer page, Integer pageSize)throws Exception{
|
||||
|
|
@ -334,7 +316,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
**/
|
||||
@ApiOperation(value = "送检记录", notes = "送检记录")
|
||||
@GetMapping(value = "/inspectionRecord")
|
||||
@PreAuthorize("hasAnyAuthority('inspectionRecord','inspectionRecord:update')")
|
||||
@MethodAnnotation(authorizations = {"inspectionRecord","inspectionRecord:update"},name = "送检记录")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntInspectionRecord>> inspectionRecord(String startTime, String endTime,Integer page,Integer pageSize,String deviceId)throws Exception {
|
||||
|
|
@ -349,7 +330,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
**/
|
||||
@ApiOperation(value = "送检操作", notes = "送检操作")
|
||||
@PostMapping(value = "/submitInspection")
|
||||
@PreAuthorize("hasAnyAuthority('inspectionRecord:update')")
|
||||
@MethodAnnotation(authorizations = {"inspectionRecord:update"},name = "送检操作")
|
||||
@ResponseBody
|
||||
public SingleResult submitInspection(@RequestBody @Valid InspectionRecordDto inspectionRecordDto)throws Exception{
|
||||
|
|
@ -365,7 +345,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
**/
|
||||
@ApiOperation(value = "维修计划", notes = "维修计划")
|
||||
@GetMapping(value = "/repairPlan")
|
||||
@PreAuthorize("hasAnyAuthority('repairPlan','repairPlan:update')")
|
||||
@MethodAnnotation(authorizations = {"repairPlan","repairPlan:update"},name = "维修计划")
|
||||
@ResponseBody
|
||||
public SingleResult<EntRepairPlan> repairPlan(String deviceId,Integer page,Integer pageSize)throws Exception{
|
||||
|
|
@ -379,7 +358,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
**/
|
||||
@ApiOperation(value = "维修计划-新增,修改", notes = "维修计划-新增,修改")
|
||||
@PostMapping(value = "/repairPlanAddOrUpdate")
|
||||
@PreAuthorize("hasAnyAuthority('repairPlan:update')")
|
||||
@MethodAnnotation(authorizations = {"repairPlan:update"},name = "维修计划-新增,修改")
|
||||
@ResponseBody
|
||||
public SingleResult repairPlanAddOrUpdate(@RequestBody EntRepairPlanDto entRepairPlanDto)throws Exception{
|
||||
|
|
@ -396,7 +374,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
**/
|
||||
@ApiOperation(value = "维修记录", notes = "维修记录")
|
||||
@GetMapping(value = "/repairRecord")
|
||||
@PreAuthorize("hasAnyAuthority('repairRecord','repairRecord:update')")
|
||||
@MethodAnnotation(authorizations = {"repairRecord","repairRecord:update"},name = "维修记录")
|
||||
@ResponseBody
|
||||
public SingleResult<EntRepairRecord> repairRecord(Integer page,Integer pageSize,String deviceId)throws Exception{
|
||||
|
|
@ -410,7 +387,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
**/
|
||||
@ApiOperation(value = "维修记录修改/新增", notes = "维修记录修改/新增")
|
||||
@PostMapping(value = "/repairRecordUpdate")
|
||||
@PreAuthorize("hasAnyAuthority('repairRecord:update')")
|
||||
@MethodAnnotation(authorizations = {"repairRecord:update"},name = "维修记录修改/新增")
|
||||
@ResponseBody
|
||||
public SingleResult repairRecordUpdate(@RequestBody EntRepairRecordDto entRepairRecordDto)throws Exception{
|
||||
|
|
@ -425,7 +401,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
**/
|
||||
@ApiOperation(value = "报修记录", notes = "报修记录")
|
||||
@GetMapping(value = "/reportRecord")
|
||||
@PreAuthorize("hasAnyAuthority('reportRecord','reportRecord:update')")
|
||||
@MethodAnnotation(authorizations = {"reportRecord","reportRecord:update"},name = "报修记录")
|
||||
@ResponseBody
|
||||
public SingleResult<EntReportRepair> reportRecord(Integer page,Integer pageSize,String deviceId)throws Exception{
|
||||
|
|
@ -441,7 +416,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
**/
|
||||
@ApiOperation(value = "新增报修", notes = "新增报修")
|
||||
@PostMapping(value = "/addOrUpdateReportRecord")
|
||||
@PreAuthorize("hasAnyAuthority('reportRecord:update')")
|
||||
@MethodAnnotation(authorizations = {"reportRecord:update"},name = "新增报修")
|
||||
@ResponseBody
|
||||
public SingleResult addOrUpdateReportRecord(@RequestBody ReportRecordDto reportRecordDto)throws Exception{
|
||||
|
|
@ -460,7 +434,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
* */
|
||||
@ApiOperation(value = "操作规程", notes = "操作规程")
|
||||
@GetMapping(value = "/operatingInstructions")
|
||||
@PreAuthorize("hasAnyAuthority('operatingInstructions','operatingInstructions:update')")
|
||||
@MethodAnnotation(authorizations = {"operatingInstructions","operatingInstructions:update"},name = "操作规程")
|
||||
@ResponseBody
|
||||
public SingleResult<EntOperatingInstruction> operatingInstructions(String name,String deviceId,Integer page,Integer pageSize)throws Exception{
|
||||
|
|
@ -473,7 +446,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
* */
|
||||
@ApiOperation(value = "新增,修改操作规程", notes = "新增,修改操作规程")
|
||||
@PostMapping(value = "/operatingInstructionsAddOrUpdate")
|
||||
@PreAuthorize("hasAnyAuthority('operatingInstructions:update')")
|
||||
@MethodAnnotation(authorizations = {"operatingInstructions:update"},name = "新增,修改操作规程")
|
||||
@ResponseBody
|
||||
public SingleResult operatingInstructionsAddOrUpdate(@RequestBody OperatingInstructionsDto operatingInstructionsDto)throws Exception{
|
||||
|
|
@ -488,7 +460,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
* */
|
||||
@ApiOperation(value = "删除操作规程", notes = "删除操作规程")
|
||||
@PostMapping(value = "/delStateOperatingInstruction")
|
||||
@PreAuthorize("hasAnyAuthority('operatingInstructions:delete')")
|
||||
@MethodAnnotation(authorizations = {"operatingInstructions:delete"},name = "删除操作规程")
|
||||
@ResponseBody
|
||||
public SingleResult delStateOperatingInstruction(String opInstructionId)throws Exception{
|
||||
|
|
@ -502,7 +473,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "企业设备过期列表", notes = "企业设备过期列表")
|
||||
@GetMapping(value = "/entDeviceOverdue")
|
||||
@PreAuthorize("hasAnyAuthority('entDeviceOverdue')")
|
||||
@MethodAnnotation(authorizations = {"entDeviceOverdue"},name = "企业设备过期列表")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "enterpriseId", value = "企业id",required = true, dataType = "string"),
|
||||
|
|
@ -520,7 +490,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "企业设备删除", notes = "企业设备删除")
|
||||
@PostMapping(value = "/entDeviceDelete")
|
||||
@PreAuthorize("hasAnyAuthority('entDevice:delete')")
|
||||
@MethodAnnotation(authorizations = {"entDevice:delete"},name = "企业设备删除")
|
||||
@ResponseBody
|
||||
public SingleResult entDeviceDelete(@RequestParam(required = true) String deviceId)throws Exception{
|
||||
|
|
@ -534,7 +503,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "企业设备周期巡检删除", notes = "企业设备周期巡检删除")
|
||||
@PostMapping(value = "/deviceInspectionCycleDelete")
|
||||
@PreAuthorize("hasAnyAuthority('deviceInspectionCycle:delete')")
|
||||
@MethodAnnotation(authorizations = {"deviceInspectionCycle:delete"},name = "企业设备周期巡检删除")
|
||||
@ResponseBody
|
||||
public SingleResult deviceInspectionCycleDelete(@RequestParam(required = true) String deviceInspectionCycleId)throws Exception{
|
||||
|
|
@ -549,7 +517,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "企业设备巡检记录删除", notes = "企业设备巡检记录删除")
|
||||
@PostMapping(value = "/deviceEntInsRecordDelete")
|
||||
@PreAuthorize("hasAnyAuthority('deviceEntInsRecord:delete')")
|
||||
@MethodAnnotation(authorizations = {"deviceEntInsRecord:delete"},name = "企业设备巡检记录删除")
|
||||
@ResponseBody
|
||||
public SingleResult deviceEntInsRecordDelete(@RequestParam(required = true) String deviceEntInsRecordId)throws Exception{
|
||||
|
|
@ -563,7 +530,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "企业设备保养计划删除", notes = "企业设备保养计划删除")
|
||||
@PostMapping(value = "/entDeviceMaintenancePlanDelete")
|
||||
@PreAuthorize("hasAnyAuthority('entDeviceMaintenancePlan:delete')")
|
||||
@MethodAnnotation(authorizations = {"entDeviceMaintenancePlan:delete"},name = "企业设备保养计划删除")
|
||||
@ResponseBody
|
||||
public SingleResult entDeviceMaintenancePlanDelete(@RequestParam(required = true) String deviceEntInsPlanId)throws Exception{
|
||||
|
|
@ -579,7 +545,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "企业设备保养记录删除", notes = "企业设备保养记录删除")
|
||||
@PostMapping(value = "/entDeviceMaintenanceRecordDelete")
|
||||
@PreAuthorize("hasAnyAuthority('entDeviceMaintenanceRecord:delete')")
|
||||
@MethodAnnotation(authorizations = {"entDeviceMaintenanceRecord:delete"},name = "企业设备保养记录删除")
|
||||
@ResponseBody
|
||||
public SingleResult entDeviceMaintenanceRecordDelete(@RequestParam(required = true) String deviceEntInsRecordId)throws Exception{
|
||||
|
|
@ -593,7 +558,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "企业设备送检记录删除", notes = "企业设备送检记录删除")
|
||||
@PostMapping(value = "/entDeviceEntInspectionRecordDelete")
|
||||
@PreAuthorize("hasAnyAuthority('entDeviceEntInspectionRecord:delete')")
|
||||
@MethodAnnotation(authorizations = {"entDeviceEntInspectionRecord:delete"},name = "企业设备送检记录删除")
|
||||
@ResponseBody
|
||||
public SingleResult entDeviceEntInspectionRecordDelete(@RequestParam(required = true) String deviceEntInspectionRecordId)throws Exception{
|
||||
|
|
@ -607,7 +571,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "企业设备维修计划删除", notes = "企业设备维修计划删除")
|
||||
@PostMapping(value = "/entDeviceRepairPlanDelete")
|
||||
@PreAuthorize("hasAnyAuthority('entDeviceEntRepairPlan:delete')")
|
||||
@MethodAnnotation(authorizations = {"entDeviceEntRepairPlan:delete"},name = "企业设备维修计划删除")
|
||||
@ResponseBody
|
||||
public SingleResult entDeviceRepairPlanDelete(@RequestParam(required = true) String repairPlanId)throws Exception{
|
||||
|
|
@ -622,7 +585,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "企业设备维修记录删除", notes = "企业设备维修记录删除")
|
||||
@PostMapping(value = "/entDeviceRepairRecordDelete")
|
||||
@PreAuthorize("hasAnyAuthority('entDeviceEntRepairRecord:delete')")
|
||||
@MethodAnnotation(authorizations = {"entDeviceEntRepairRecord:delete"},name = "企业设备维修记录删除")
|
||||
@ResponseBody
|
||||
public SingleResult entDeviceRepairRecordDelete(@RequestParam(required = true) String repairRecordId)throws Exception{
|
||||
|
|
@ -636,7 +598,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "企业设备故障报修删除", notes = "企业设备故障报修删除")
|
||||
@PostMapping(value = "/entDeviceReportRepairDelete")
|
||||
@PreAuthorize("hasAnyAuthority('entDeviceReportRepair:delete')")
|
||||
@MethodAnnotation(authorizations = {"entDeviceReportRepair:delete"},name = "企业设备故障报修删除")
|
||||
@ResponseBody
|
||||
public SingleResult entDeviceReportRepairDelete(@RequestParam(required = true) String reportRepair)throws Exception{
|
||||
|
|
@ -652,7 +613,6 @@ public class EnterpriseEquipmentController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "小程序-企业设备", notes = "小程序-企业设备")
|
||||
@GetMapping(value = "/mobileEntDevice")
|
||||
@PreAuthorize("hasAnyAuthority('mobileEntDevice')")
|
||||
@MethodAnnotation(authorizations = {"mobileEntDevice"},name = "小程序-企业设备")
|
||||
@ResponseBody
|
||||
public SingleResult mobileEntDevice(String modelState,@RequestParam(required = true)Integer page,@RequestParam(required = true)Integer pageSize)throws Exception{
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@ import io.swagger.annotations.ApiImplicitParam;
|
|||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
|
@ -338,7 +337,6 @@ public class MinWorkController extends BaseController{
|
|||
@ApiImplicitParam(name = "deviceId", value = "设备id", required = true, dataType = "string"),
|
||||
})
|
||||
@GetMapping(value = "/deviceDetail")
|
||||
@PreAuthorize("hasAnyAuthority('entEquipmentList')")
|
||||
@MethodAnnotation(authorizations = {"entEquipmentList"},name = "企业设备详细")
|
||||
@ResponseBody
|
||||
public SingleResult<EntDevice> deviceDetail(@RequestParam(required = true) String deviceId)throws Exception{
|
||||
|
|
@ -353,7 +351,6 @@ public class MinWorkController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "设备巡检记录-添加和修改巡检记录", notes = "设备巡检记录-添加和修改巡检记录")
|
||||
@PostMapping(value = "/addOrUpdateInspectionAddOrRecord")
|
||||
@PreAuthorize("hasAnyAuthority('addOrUpdateInspectionRecord:update')")
|
||||
@MethodAnnotation(authorizations = {"addOrUpdateInspectionRecord:update"},name = "设备巡检记录-添加和修改巡检记录")
|
||||
@ResponseBody
|
||||
public SingleResult addOrUpdateInspectionRecord(@RequestBody AddOrUpdateInspectionRecordDto addOrUpdateInspectionRecordDto)throws Exception{
|
||||
|
|
@ -367,7 +364,6 @@ public class MinWorkController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "设备巡检记录", notes = "设备巡检记录")
|
||||
@GetMapping(value = "/insRecord")
|
||||
@PreAuthorize("hasAnyAuthority('insRecord','insRecord:update')")
|
||||
@MethodAnnotation(authorizations = {"insRecord","insRecord:update"},name = "设备巡检记录")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntInsRecord>> insRecord(String deviceId,String inspectionRecordName,Integer page,Integer pageSize)throws Exception{
|
||||
|
|
@ -384,7 +380,6 @@ public class MinWorkController extends BaseController{
|
|||
**/
|
||||
@ApiOperation(value = "维修记录", notes = "维修记录")
|
||||
@GetMapping(value = "/repairRecord")
|
||||
@PreAuthorize("hasAnyAuthority('repairRecord','repairRecord:update')")
|
||||
@MethodAnnotation(authorizations = {"repairRecord","repairRecord:update"},name = "维修记录")
|
||||
@ResponseBody
|
||||
public SingleResult<EntRepairRecord> repairRecord(Integer page,Integer pageSize,String deviceId)throws Exception{
|
||||
|
|
@ -398,7 +393,6 @@ public class MinWorkController extends BaseController{
|
|||
**/
|
||||
@ApiOperation(value = "维修记录修改/新增", notes = "维修记录修改/新增")
|
||||
@PostMapping(value = "/repairRecordUpdate")
|
||||
@PreAuthorize("hasAnyAuthority('repairRecord:update')")
|
||||
@MethodAnnotation(authorizations = {"repairRecord:update"},name = "维修记录修改/新增")
|
||||
@ResponseBody
|
||||
public SingleResult repairRecordUpdate(@RequestBody EntRepairRecordDto entRepairRecordDto)throws Exception{
|
||||
|
|
@ -422,7 +416,6 @@ public class MinWorkController extends BaseController{
|
|||
@ApiImplicitParam(name = "keyWord", value = "关键字", required = false, dataType = "string")
|
||||
})
|
||||
@GetMapping(value = "/entEquipmentListAndIns")
|
||||
@PreAuthorize("hasAnyAuthority('entEquipmentListAndIns','entEquipmentList:update')")
|
||||
@MethodAnnotation(authorizations = {"entEquipmentListAndIns","entEquipmentList:update"},name = "企业设备带巡检进度")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntDeviceInsStatistic>> entEquipmentListAndIns(@RequestParam(required = true) String enterpriseId, String typeId,Integer page,Integer pageSize,String keyWord)throws Exception{
|
||||
|
|
|
|||
|
|
@ -41,7 +41,6 @@ import org.apache.commons.beanutils.ConvertUtils;
|
|||
import org.apache.commons.beanutils.converters.DateConverter;
|
||||
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
|
@ -882,7 +881,6 @@ public class PcCompanyController extends BaseController{
|
|||
|
||||
@PostMapping("/testSpringSecurity")
|
||||
@ResponseBody
|
||||
@PreAuthorize("hasRole('USER')")
|
||||
public String testSpringSecurity(String SysEnterpriseId)throws Exception {
|
||||
return "SysEnterpriseId";
|
||||
}
|
||||
|
|
@ -901,7 +899,6 @@ public class PcCompanyController extends BaseController{
|
|||
@ApiImplicitParam(name = "pageSize", value = "pageSize",required = true, dataType = "int"),
|
||||
})
|
||||
@GetMapping(value = "/inListStatistic")
|
||||
@PreAuthorize("hasAnyAuthority('inListStatistic')")
|
||||
@MethodAnnotation(authorizations = {"inListStatistic"},name = "企业清单统计")
|
||||
@ResponseBody
|
||||
public SingleResult entUserList(String listId,
|
||||
|
|
@ -919,7 +916,6 @@ public class PcCompanyController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "企业清单类型", notes = "企业清单类型")
|
||||
@GetMapping(value = "/inListTypes")
|
||||
@PreAuthorize("hasAnyAuthority('inListTypes')")
|
||||
@MethodAnnotation(authorizations = {"inListTypes"},name = "企业清单类型")
|
||||
@ResponseBody
|
||||
public SingleResult<List<InEntList>> entUserList(@RequestParam(required = true) String enterpriseId)throws Exception{
|
||||
|
|
@ -938,7 +934,6 @@ public class PcCompanyController extends BaseController{
|
|||
@ApiImplicitParam(name = "year", value = "年份",required = false, dataType = "string"),
|
||||
@ApiImplicitParam(name = "listId", value = "清单id",required = false, dataType = "string"),
|
||||
})
|
||||
@PreAuthorize("hasAnyAuthority('entPostListFinishedPercent')")
|
||||
@MethodAnnotation(authorizations = {"entPostListFinishedPercent"},name = "企业工作要务总进度")
|
||||
@ResponseBody
|
||||
public SingleResult entPostListFinishedPercent(@RequestParam(required = true) String enterpriseId,Integer year,String listId)throws Exception{
|
||||
|
|
@ -958,7 +953,6 @@ public class PcCompanyController extends BaseController{
|
|||
@ApiImplicitParam(name = "year", value = "年份",required = false, dataType = "string"),
|
||||
@ApiImplicitParam(name = "listId", value = "清单id",required = false, dataType = "string"),
|
||||
})
|
||||
@PreAuthorize("hasAnyAuthority('entPostListPercentStatistic')")
|
||||
@MethodAnnotation(authorizations = {"entPostListPercentStatistic"},name = "企业清单履职总统计")
|
||||
@ResponseBody
|
||||
public SingleResult entPostListPercentStatistic(@RequestParam(required = true)String enterpriseId,Integer year,String listId)throws Exception{
|
||||
|
|
|
|||
|
|
@ -23,7 +23,6 @@ import io.swagger.annotations.ApiImplicitParam;
|
|||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
|
@ -195,7 +194,6 @@ public class PersonalController extends BaseController{
|
|||
@ApiImplicitParam(name = "postId", value = "企业用户岗位id",required = false, dataType = "string"),
|
||||
})
|
||||
@GetMapping(value = "/entUserTree")
|
||||
@PreAuthorize("hasAnyAuthority('entUserTree','entUserTree:update')")
|
||||
@MethodAnnotation(authorizations = {"entUserTree","entUserTree:update"},name = "企业用户组织树")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntPost>> entUserTree(@RequestParam(required = true) String enterpriseId, String postId)throws Exception{
|
||||
|
|
@ -211,7 +209,6 @@ public class PersonalController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "企业用户工作要务", notes = "企业用户工作要务")
|
||||
@PostMapping(value = "/entUserPostList")
|
||||
@PreAuthorize("hasAnyAuthority('entUserPostList','entUserPostList:update')")
|
||||
@MethodAnnotation(authorizations = {"entUserPostList","entUserPostList:update"},name = "企业用户工作要务")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntPostList>> entUserPostList(@RequestBody EntUserPostListDto entUserPostListDto)throws Exception{
|
||||
|
|
@ -228,7 +225,6 @@ public class PersonalController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "企业用户日常工作清单", notes = "企业用户日常工作清单")
|
||||
@PostMapping(value = "/entUserPostTask")
|
||||
@PreAuthorize("hasAnyAuthority('entUserPostTask','entUserPostTask:update')")
|
||||
@MethodAnnotation(authorizations = {"entUserPostTask","entUserPostTask:update"},name = "企业用户日常工作清单")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntPostTask>> entUserPostTask(@RequestBody EntUserPostTaskDto entUserPostTaskDto)throws Exception{
|
||||
|
|
@ -246,7 +242,6 @@ public class PersonalController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "企业用户岗位职责", notes = "企业用户岗位职责")
|
||||
@PostMapping(value = "/entUserPostDuty")
|
||||
@PreAuthorize("hasAnyAuthority('entUserPostDuty','entUserPostDuty:update')")
|
||||
@MethodAnnotation(authorizations = {"entUserPostDuty","entUserPostDuty:update"},name = "企业用户岗位职责")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntPostDuty>> entUserPostDuty(@RequestBody EntUserPostDutyDto entUserPostDutyDto)throws Exception{
|
||||
|
|
@ -270,7 +265,6 @@ public class PersonalController extends BaseController{
|
|||
@ApiImplicitParam(name = "enterpriseId", value = "企业id",required = false, dataType = "string"),
|
||||
})
|
||||
@GetMapping(value = "/entUserCredential")
|
||||
@PreAuthorize("hasAnyAuthority('entUserCredential','entUserCredential:update')")
|
||||
@MethodAnnotation(authorizations = {"entUserCredential","entUserCredential:update"},name = "企业用户证照表")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntUserCredential>> entUserCredential(String entUserId, @RequestParam(required = true) Integer page, @RequestParam(required = true)Integer pageSize,Integer credentialState,String enterpriseId)throws Exception{
|
||||
|
|
@ -285,7 +279,6 @@ public class PersonalController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "企业用户证照表-新增,修改", notes = "企业用户证照表-新增,修改")
|
||||
@PostMapping(value = "/entUserCredentialUpdate")
|
||||
@PreAuthorize("hasAnyAuthority('entUserCredentialUpdate:update')")
|
||||
@MethodAnnotation(authorizations = {"entUserCredentialUpdate:update"},name = "企业用户证照表-新增,修改")
|
||||
@ResponseBody
|
||||
public SingleResult entUserCredentialUpdate(@RequestBody EntUserCredentialUpdateDto entUserCredentialUpdateDto)throws Exception{
|
||||
|
|
@ -306,7 +299,6 @@ public class PersonalController extends BaseController{
|
|||
@ApiImplicitParam(name = "credentialId", value = "证件照id",required = true, dataType = "string"),
|
||||
})
|
||||
@PostMapping(value = "/entUserCredentialDelete")
|
||||
@PreAuthorize("hasAnyAuthority('entUserCredentialDelete')")
|
||||
@MethodAnnotation(authorizations = {"entUserCredentialDelete"},name = "企业用户证照表-删除")
|
||||
@ResponseBody
|
||||
public SingleResult entUserCredentialDelete(@RequestParam(required = true) String credentialId)throws Exception{
|
||||
|
|
@ -330,7 +322,6 @@ public class PersonalController extends BaseController{
|
|||
@ApiImplicitParam(name = "userType", value = "人员类型",required = false, dataType = "string"),
|
||||
})
|
||||
@GetMapping(value = "/entUserList")
|
||||
@PreAuthorize("hasAnyAuthority('entUserList','entUserList:update')")
|
||||
@MethodAnnotation(authorizations = {"entUserList","entUserList:update"},name = "企业岗位人员总体信息列表")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntUser>> entUserList(@RequestParam(required = false) String keyContent,
|
||||
|
|
@ -356,7 +347,6 @@ public class PersonalController extends BaseController{
|
|||
@ApiImplicitParam(name = "enterpriseId", value = "企业id",required = false, dataType = "string"),
|
||||
})
|
||||
@GetMapping(value = "/entUserListNoPage")
|
||||
@PreAuthorize("hasAnyAuthority('entUserList','entUserList:update')")
|
||||
@MethodAnnotation(authorizations = {"entUserList","entUserList:update"},name = "企业岗位人员不分页")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntUser>> entUserList(@RequestParam(required = false) String name,
|
||||
|
|
@ -374,7 +364,6 @@ public class PersonalController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "新增和修改公司岗位人员", notes = "新增和修改公司岗位人员")
|
||||
@PostMapping(value = "/addOrUpdateEntUser")
|
||||
@PreAuthorize("hasAnyAuthority('addOrUpdateEntUser:update')")
|
||||
@MethodAnnotation(authorizations = {"addOrUpdateEntUser:update"},name = "新增和修改公司岗位人员")
|
||||
@ResponseBody
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
|
|
@ -392,7 +381,6 @@ public class PersonalController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "停用岗位人员", notes = "停用岗位人员")
|
||||
@PostMapping(value = "/stopUseEntUser")
|
||||
@PreAuthorize("hasAnyAuthority('addOrUpdateEntUser:delete')")
|
||||
@MethodAnnotation(authorizations = {"addOrUpdateEntUser:delete"},name = "停用岗位人员")
|
||||
@ResponseBody
|
||||
public SingleResult stopUseEntUser(String entUserId)throws Exception{
|
||||
|
|
@ -409,7 +397,6 @@ public class PersonalController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "手动企业分配任务", notes = "手动企业分配任务")
|
||||
@PostMapping(value = "/manualAssignmentTask")
|
||||
@PreAuthorize("hasAnyAuthority('entUserPostTask:update')")
|
||||
@MethodAnnotation(authorizations = {"entUserPostTask:update"},name = "手动企业分配任务")
|
||||
@ResponseBody
|
||||
@Transactional
|
||||
|
|
@ -425,7 +412,6 @@ public class PersonalController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "手动企业添加履职记录", notes = "手动企业添加履职记录")
|
||||
@PostMapping(value = "/manualAddListDetail")
|
||||
@PreAuthorize("hasAnyAuthority('entPostListDetail:update')")
|
||||
@MethodAnnotation(authorizations = {"entPostListDetail:update"},name = "手动企业添加履职记录")
|
||||
@ResponseBody
|
||||
public SingleResult manualAddListDetail(@RequestBody EntPostListDetailDto entPostListDetailDto)throws Exception{
|
||||
|
|
@ -438,7 +424,6 @@ public class PersonalController extends BaseController{
|
|||
* */
|
||||
@ApiOperation(value = "查询履职记录列表", notes = "查询履职记录列表")
|
||||
@GetMapping(value = "/selectPostListDetail")
|
||||
@PreAuthorize("hasAnyAuthority('entPostListDetail:update')")
|
||||
@MethodAnnotation(authorizations = {"entPostListDetail:update"},name = "查询履职记录列表")
|
||||
@ResponseBody
|
||||
public SingleResult selectPostListDetail(String postListId,String userId,Integer page,Integer pageSize)throws Exception{
|
||||
|
|
@ -454,7 +439,6 @@ public class PersonalController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "新增和修改公司岗位", notes = "新增和修改公司岗位")
|
||||
@PostMapping(value = "/addOrUpdateEntPost")
|
||||
@PreAuthorize("hasAnyAuthority('addOrUpdateEntPost:update')")
|
||||
@MethodAnnotation(authorizations = {"addOrUpdateEntPost:update"},name = "新增和修改公司岗位")
|
||||
@ResponseBody
|
||||
public SingleResult addOrUpdateEntPost(@RequestBody AddOrUpdateEntPostDto addOrUpdateEntPostDto)throws Exception{
|
||||
|
|
@ -469,7 +453,6 @@ public class PersonalController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "软删除公司岗位", notes = "软删除公司岗位")
|
||||
@PostMapping(value = "/deletePost")
|
||||
@PreAuthorize("hasAnyAuthority('addOrUpdateEntPost:delete')")
|
||||
@MethodAnnotation(authorizations = {"addOrUpdateEntPost:delete"},name = "软删除公司岗位")
|
||||
@ResponseBody
|
||||
public SingleResult deleteEntPost(String postId)throws Exception{
|
||||
|
|
@ -491,7 +474,6 @@ public class PersonalController extends BaseController{
|
|||
@ApiImplicitParam(name = "userId", value = "用户id",required = true, dataType = "string"),
|
||||
})
|
||||
@GetMapping(value = "/entListGroupByListId")
|
||||
@PreAuthorize("hasAnyAuthority('entListGroupByListId','entListGroupByListId:update')")
|
||||
@MethodAnnotation(authorizations = {"entListGroupByListId","entListGroupByListId:update"},name = "企业清单(类型)分组查询")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntPostList>> entListGroupByListId(@RequestParam(required = true) String enterpriseId,
|
||||
|
|
@ -509,7 +491,6 @@ public class PersonalController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "人员类型列表", notes = "人员类型列表")
|
||||
@GetMapping(value = "/entUserTypeList")
|
||||
@PreAuthorize("hasAnyAuthority('entUserTypeList')")
|
||||
@MethodAnnotation(authorizations = {"entUserTypeList"},name = "人员类型列表")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntPostList>> entListGroupByListId()throws Exception{
|
||||
|
|
@ -527,7 +508,6 @@ public class PersonalController extends BaseController{
|
|||
@ApiImplicitParam(name = "type", value = "1.修改隐患 2.履职 3:系统通知 4:检查签名 5:履职提醒 7:文件下达",required = false, dataType = "string")
|
||||
})
|
||||
@GetMapping(value = "/entNotice")
|
||||
@PreAuthorize("hasAnyAuthority('entNotice')")
|
||||
@MethodAnnotation(authorizations = {"entNotice"},name = "消息通知接口")
|
||||
@ResponseBody
|
||||
public SingleResult<List<Notice>> notice(String type,Integer page,Integer pageSize)throws Exception{
|
||||
|
|
@ -541,7 +521,6 @@ public class PersonalController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "消息一键已读", notes = "消息一键已读")
|
||||
@GetMapping(value = "/oneButtonRead")
|
||||
@PreAuthorize("hasAnyAuthority('entNotice')")
|
||||
@MethodAnnotation(authorizations = {"entNotice"},name = "消息一键已读")
|
||||
@ResponseBody
|
||||
public SingleResult oneButtonRead()throws Exception{
|
||||
|
|
@ -557,7 +536,6 @@ public class PersonalController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "消息通知数量", notes = "消息通知数量")
|
||||
@GetMapping(value = "/entNoticeNumber")
|
||||
@PreAuthorize("hasAnyAuthority('entNotice')")
|
||||
@MethodAnnotation(authorizations = {"entNotice"},name = "消息通知数量")
|
||||
@ResponseBody
|
||||
public SingleResult entNoticeNumber()throws Exception{
|
||||
|
|
|
|||
|
|
@ -1,95 +0,0 @@
|
|||
package com.rzyc.filter;
|
||||
|
||||
import com.common.utils.jwt.JwtUtil;
|
||||
import com.rzyc.advice.CustomException;
|
||||
import com.rzyc.config.RedisUtil;
|
||||
import com.rzyc.mapper.AuthorityKeyMapper;
|
||||
import com.rzyc.model.AuthorityKey;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.AccessDeniedException;
|
||||
import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
|
||||
import org.springframework.security.core.GrantedAuthority;
|
||||
import org.springframework.security.core.authority.SimpleGrantedAuthority;
|
||||
import org.springframework.security.core.context.SecurityContextHolder;
|
||||
import org.springframework.stereotype.Component;
|
||||
import org.springframework.util.StringUtils;
|
||||
import org.springframework.web.filter.OncePerRequestFilter;
|
||||
|
||||
import javax.servlet.FilterChain;
|
||||
import javax.servlet.ServletException;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.io.IOException;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* spring security JWT Filter
|
||||
* @author Xuwanxin
|
||||
* @date 2022/9/26
|
||||
* */
|
||||
|
||||
@Component
|
||||
public class JwtAuthenticationTokenFiler extends OncePerRequestFilter {
|
||||
|
||||
AuthorityKeyMapper authorityKeyMapper;
|
||||
|
||||
RedisUtil redisUtil;
|
||||
|
||||
@Autowired
|
||||
public JwtAuthenticationTokenFiler(AuthorityKeyMapper authorityKeyMapper, RedisUtil redisUtil) {
|
||||
this.authorityKeyMapper = authorityKeyMapper;
|
||||
this.redisUtil = redisUtil;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void doFilterInternal(HttpServletRequest request, HttpServletResponse response, FilterChain filterChain) throws ServletException, IOException {
|
||||
//获取token
|
||||
String token = request.getHeader("userToken");
|
||||
if(null != token){
|
||||
token = "rzyc";
|
||||
}
|
||||
/*if (!StringUtils.hasText(token)) {
|
||||
//放行
|
||||
filterChain.doFilter(request, response);
|
||||
return;
|
||||
}*/
|
||||
|
||||
try {
|
||||
String userId = JwtUtil.getTokenMsg(token);
|
||||
} catch (Exception e) {
|
||||
System.out.println("token非法");
|
||||
throw new RuntimeException("token非法");
|
||||
}
|
||||
try {
|
||||
//这里是要去拿角色权限的
|
||||
List<AuthorityKey>authorizations = (List<AuthorityKey>) redisUtil.get("allKeys");
|
||||
List<GrantedAuthority> authority= new ArrayList<GrantedAuthority>();
|
||||
if (null != authorizations && authorizations.size() > 0 ){
|
||||
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
for (AuthorityKey s:authorizations) {
|
||||
stringBuilder.append(s.getAuthKey());
|
||||
authority.add(new SimpleGrantedAuthority(stringBuilder.toString()));
|
||||
stringBuilder.setLength(0);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
// 获取权限信息封装到Authentication中
|
||||
UsernamePasswordAuthenticationToken authenticationToken =
|
||||
new UsernamePasswordAuthenticationToken(null,null,authority);
|
||||
SecurityContextHolder.getContext().setAuthentication(authenticationToken);
|
||||
filterChain.doFilter(request, response);
|
||||
}catch (AccessDeniedException e){
|
||||
System.out.println("权限失败");
|
||||
throw new CustomException("无权限操作");
|
||||
}catch (Exception e){
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -2,7 +2,7 @@ package com.rzyc.service;
|
|||
|
||||
|
||||
import com.common.utils.model.SingleResult;
|
||||
import com.common.utils.pager.PageOperation;
|
||||
import com.rzyc.pager.PageOperation;
|
||||
import com.rzyc.controller.BaseController;
|
||||
import com.rzyc.model.DangerStatistic;
|
||||
import com.rzyc.model.ent.EntDevice;
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ import com.common.utils.encryption.MD5;
|
|||
import com.common.utils.model.Code;
|
||||
import com.common.utils.model.Message;
|
||||
import com.common.utils.model.SingleResult;
|
||||
import com.common.utils.pager.PageOperation;
|
||||
import com.rzyc.pager.PageOperation;
|
||||
import com.github.pagehelper.Page;
|
||||
import com.rzyc.advice.CustomException;
|
||||
import com.rzyc.config.RedisUtil;
|
||||
|
|
|
|||
|
|
@ -1,91 +0,0 @@
|
|||
package com.rzyc.service;
|
||||
|
||||
|
||||
import com.rzyc.advice.CustomException;
|
||||
import com.rzyc.config.RedisUtil;
|
||||
import com.rzyc.config.UserDetailsAndId;
|
||||
import com.rzyc.enums.SysEnterpriseState;
|
||||
import com.rzyc.mapper.AuthorityKeyMapper;
|
||||
import com.rzyc.mapper.ent.EntUserMapper;
|
||||
import com.rzyc.mapper.ent.SysEnterpriseMapper;
|
||||
import com.rzyc.model.AuthorityKey;
|
||||
import com.rzyc.model.ent.EntUser;
|
||||
import com.rzyc.model.ent.SysEnterprise;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.core.GrantedAuthority;
|
||||
import org.springframework.security.core.authority.SimpleGrantedAuthority;
|
||||
import org.springframework.security.core.userdetails.UserDetails;
|
||||
import org.springframework.security.core.userdetails.UserDetailsService;
|
||||
import org.springframework.security.core.userdetails.UsernameNotFoundException;
|
||||
import org.springframework.security.crypto.password.PasswordEncoder;
|
||||
import org.springframework.stereotype.Service;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
/**
|
||||
* spring security 用户认证过程
|
||||
* @author Xuwanxin
|
||||
* @author 2022/09/27
|
||||
* */
|
||||
|
||||
@Service("userService")
|
||||
public class UserDetailsServiceImpl implements UserDetailsService {
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 内存过程密码加密
|
||||
* */
|
||||
private PasswordEncoder passwordEncoder;
|
||||
|
||||
/**
|
||||
* 企业端用户
|
||||
* */
|
||||
private EntUserMapper entUserMapper;
|
||||
|
||||
/**
|
||||
* 权限表mapper
|
||||
* */
|
||||
private AuthorityKeyMapper authorityKeyMapper;
|
||||
|
||||
|
||||
/**
|
||||
* redis操作工具
|
||||
* */
|
||||
private RedisUtil redisUtil;
|
||||
|
||||
|
||||
|
||||
@Autowired
|
||||
public void UserDetailsServiceImplFinder(PasswordEncoder passwordEncoder,EntUserMapper entUserMapper,AuthorityKeyMapper authorityKeyMapper,RedisUtil redisUtil) {
|
||||
this.passwordEncoder = passwordEncoder;
|
||||
this.entUserMapper = entUserMapper;
|
||||
this.authorityKeyMapper = authorityKeyMapper;
|
||||
this.redisUtil = redisUtil;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public UserDetails loadUserByUsername(String mobileNumber){
|
||||
//判断用户是否存在
|
||||
EntUser user = entUserMapper.validAccount(mobileNumber,null);
|
||||
if (Objects.isNull(user)){
|
||||
throw new CustomException("用户名不存在");
|
||||
}
|
||||
List<GrantedAuthority> authority= new ArrayList<GrantedAuthority>();
|
||||
List<AuthorityKey>authorizations = authorityKeyMapper.allAuthorizations();
|
||||
redisUtil.set("allKeys",authorizations);
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
for (AuthorityKey s:authorizations) {
|
||||
stringBuilder.append(s.getAuthKey());
|
||||
authority.add(new SimpleGrantedAuthority(stringBuilder.toString()));
|
||||
stringBuilder.setLength(0);
|
||||
}
|
||||
return new UserDetailsAndId(user.getName(), passwordEncoder.encode(user.getPasswd()), authority,user.getEntUserId(),user.getPostId());
|
||||
|
||||
}
|
||||
}
|
||||
|
|
@ -1,28 +1,10 @@
|
|||
package com.rzyc.service;
|
||||
|
||||
|
||||
import com.common.utils.encryption.MD5;
|
||||
import com.common.utils.jwt.JwtUtil;
|
||||
|
||||
import com.rzyc.advice.CustomException;
|
||||
import com.rzyc.config.UserDetailsAndId;
|
||||
import com.rzyc.enums.SysEnterpriseState;
|
||||
import com.rzyc.mapper.ent.EntPostMapper;
|
||||
import com.rzyc.mapper.ent.SysEnterpriseMapper;
|
||||
import com.rzyc.model.ent.EntPost;
|
||||
import com.rzyc.model.ent.EntUser;
|
||||
import com.rzyc.model.ent.SysEnterprise;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.authentication.BadCredentialsException;
|
||||
import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
|
||||
import org.springframework.security.core.AuthenticationException;
|
||||
import org.springframework.security.core.context.SecurityContextHolder;
|
||||
import org.springframework.security.core.userdetails.UserDetails;
|
||||
import org.springframework.security.core.userdetails.UserDetailsService;
|
||||
import org.springframework.security.core.userdetails.UsernameNotFoundException;
|
||||
import org.springframework.security.crypto.password.PasswordEncoder;
|
||||
import org.springframework.stereotype.Service;
|
||||
import java.util.Objects;
|
||||
|
||||
/**
|
||||
* 用户登陆 Service
|
||||
|
|
@ -33,16 +15,6 @@ import java.util.Objects;
|
|||
@Service
|
||||
public class UserLoginService {
|
||||
|
||||
/**
|
||||
* spring security 登陆业务接口service
|
||||
* */
|
||||
private UserDetailsService userDetailsService;
|
||||
|
||||
|
||||
/**
|
||||
* spring security 内存中加密
|
||||
* */
|
||||
private PasswordEncoder passwordEncoder;
|
||||
|
||||
/**
|
||||
* 企业端公司
|
||||
|
|
@ -55,49 +27,11 @@ public class UserLoginService {
|
|||
private EntPostMapper entPostMapper;
|
||||
|
||||
|
||||
@Autowired
|
||||
public void UserLoginServiceFinder(UserDetailsService userDetailsService,PasswordEncoder passwordEncoder,SysEnterpriseMapper sysEnterpriseMapper,EntPostMapper entPostMapper){
|
||||
this.userDetailsService = userDetailsService;
|
||||
this.passwordEncoder = passwordEncoder;
|
||||
this.sysEnterpriseMapper= sysEnterpriseMapper;
|
||||
this.entPostMapper = entPostMapper;
|
||||
}
|
||||
|
||||
public EntUser login(String username, String password)throws Exception {
|
||||
EntUser entUser = new EntUser();
|
||||
String token = null;
|
||||
UserDetails userDetails = userDetailsService.loadUserByUsername(username);
|
||||
if (Objects.isNull(userDetails)) {
|
||||
throw new CustomException("账号不存在,请填入企业名或企业绑定的手机号");
|
||||
}
|
||||
SysEnterprise sysEnterprise = sysEnterpriseMapper.findEnterpriseByPhoneNumber(username);
|
||||
if (Objects.isNull(sysEnterprise) || sysEnterprise.getState().equals(SysEnterpriseState.DISABLE)){
|
||||
throw new CustomException("企业不存在或已经禁用");
|
||||
}
|
||||
String madPasswd = MD5.md5(password);
|
||||
System.out.println("madPasswd --> "+madPasswd);
|
||||
|
||||
//这里可能会不对,因为我们是MD5,这个是spring security 中的 encoder加密
|
||||
if (!passwordEncoder.matches(madPasswd, userDetails.getPassword())) {
|
||||
throw new CustomException("密码不正确");
|
||||
}
|
||||
//spring security context insert
|
||||
UsernamePasswordAuthenticationToken authentication = new UsernamePasswordAuthenticationToken(userDetails, null, userDetails.getAuthorities());
|
||||
SecurityContextHolder.getContext().setAuthentication(authentication);
|
||||
//企业用户id
|
||||
String id = ((UserDetailsAndId)SecurityContextHolder.getContext().getAuthentication().getPrincipal()).getId();
|
||||
token = JwtUtil.createToken(id);
|
||||
String postId = ((UserDetailsAndId)SecurityContextHolder.getContext().getAuthentication().getPrincipal()).getPostId();
|
||||
EntPost entPost = entPostMapper.selectById(postId);
|
||||
//封装返回数据
|
||||
entUser.setName(userDetails.getUsername());
|
||||
entUser.setEntUserId(id);
|
||||
entUser.setEnterpriseId(sysEnterprise.getSysenterpriseid());
|
||||
entUser.setUserToken(token);
|
||||
entUser.setEntPostName(entPost.getName());
|
||||
entUser.setPostId(entPost.getPostId());
|
||||
entUser.setUserTypeName("企业用户");
|
||||
entUser.setEnterpriseName(sysEnterprise.getEntname());
|
||||
return entUser;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,24 +0,0 @@
|
|||
package com.rzyc.utils.easyexcel;
|
||||
|
||||
|
||||
import com.alibaba.excel.EasyExcel;
|
||||
import com.rzyc.mapper.ent.BaseInClassMapper;
|
||||
import com.rzyc.mapper.ent.InListItemMapper;
|
||||
import com.rzyc.mapper.ent.InListMapper;
|
||||
import com.rzyc.model.EasyExcel.EasyExcelInList;
|
||||
import jdk.nashorn.internal.ir.annotations.Ignore;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
|
||||
/**
|
||||
* 读的常见写法
|
||||
*
|
||||
* @author Jiaju Zhuang
|
||||
*/
|
||||
@Ignore
|
||||
@Slf4j
|
||||
public class ReadTest {
|
||||
|
||||
|
||||
}
|
||||
|
|
@ -39,7 +39,7 @@ spring:
|
|||
#数据库
|
||||
datasource:
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
url: jdbc:mysql://42.193.40.239:33063/inventory_23?useUnicode=true&characterEncoding=UTF-8&serverTimezone=GMT%2B8&useSSL=false
|
||||
url: jdbc:mysql://42.193.40.239:33063/ganzi25?useUnicode=true&characterEncoding=UTF-8&serverTimezone=GMT%2B8&useSSL=false
|
||||
username: zyjy
|
||||
password: eaNCBySJdHLb23GW
|
||||
tomcat:
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
spring:
|
||||
profiles:
|
||||
active: prod #设定打包配置文件
|
||||
active: test #设定打包配置文件
|
||||
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -3,10 +3,10 @@
|
|||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-parent</artifactId>
|
||||
<version>2.2.5.RELEASE</version>
|
||||
<relativePath/> <!-- lookup parent from repository -->
|
||||
<groupId>com.rzyc</groupId>
|
||||
<artifactId>inventory</artifactId>
|
||||
<version>0.0.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath> <!-- lookup parent from repository -->
|
||||
</parent>
|
||||
|
||||
<groupId>com.rzyc</groupId>
|
||||
|
|
@ -23,151 +23,6 @@
|
|||
|
||||
<dependencies>
|
||||
|
||||
<!-- spring boot start -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-thymeleaf</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-test</artifactId>
|
||||
<scope>test</scope>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>org.junit.vintage</groupId>
|
||||
<artifactId>junit-vintage-engine</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-web</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- spring boot end -->
|
||||
|
||||
<!-- aop start -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-aop</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.aspectj</groupId>
|
||||
<artifactId>aspectjrt</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.aspectj</groupId>
|
||||
<artifactId>aspectjweaver</artifactId>
|
||||
</dependency>
|
||||
<!-- aop end -->
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- swagger start -->
|
||||
<dependency>
|
||||
<groupId>io.springfox</groupId>
|
||||
<artifactId>springfox-swagger2</artifactId>
|
||||
<version>2.9.2</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>io.swagger</groupId>
|
||||
<artifactId>swagger-models</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.swagger</groupId>
|
||||
<artifactId>swagger-models</artifactId>
|
||||
<version>1.5.21</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.springfox</groupId>
|
||||
<artifactId>springfox-swagger-ui</artifactId>
|
||||
<version>2.9.2</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.github.xiaoymin</groupId>
|
||||
<artifactId>swagger-bootstrap-ui</artifactId>
|
||||
<version>1.9.6</version>
|
||||
</dependency>
|
||||
<!-- swagger end -->
|
||||
|
||||
<!-- 参数验证 start -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-validation</artifactId>
|
||||
<version>2.2.8.RELEASE</version>
|
||||
</dependency>
|
||||
<!-- 参数验证 end -->
|
||||
|
||||
|
||||
<!-- baidu start -->
|
||||
<dependency>
|
||||
<groupId>com.baidu.aip</groupId>
|
||||
<artifactId>java-sdk</artifactId>
|
||||
<version>4.15.3</version>
|
||||
</dependency>
|
||||
<!-- baidu end -->
|
||||
|
||||
<!--xunfeiVoice start-->
|
||||
<dependency>
|
||||
<groupId>commons-codec</groupId>
|
||||
<artifactId>commons-codec</artifactId>
|
||||
<version>1.9</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.java-websocket</groupId>
|
||||
<artifactId>Java-WebSocket</artifactId>
|
||||
<version>1.3.4</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-logging</groupId>
|
||||
<artifactId>commons-logging</artifactId>
|
||||
<version>1.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.httpcomponents</groupId>
|
||||
<artifactId>httpclient</artifactId>
|
||||
<version>4.5.8</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.httpcomponents</groupId>
|
||||
<artifactId>httpcore</artifactId>
|
||||
<version>4.4.11</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.httpcomponents</groupId>
|
||||
<artifactId>httpmime</artifactId>
|
||||
<version>4.5.8</version>
|
||||
</dependency>
|
||||
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-websocket</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- pdf start -->
|
||||
|
||||
<dependency>
|
||||
<groupId>com.itextpdf</groupId>
|
||||
<artifactId>itextpdf</artifactId>
|
||||
<version>5.0.6</version>
|
||||
</dependency>
|
||||
<!-- pdf end -->
|
||||
|
||||
<!-- 公用方法 start -->
|
||||
<dependency>
|
||||
|
|
@ -184,65 +39,6 @@
|
|||
<version>0.0.1-SNAPSHOT</version>
|
||||
</dependency>
|
||||
|
||||
|
||||
<!-- 配置文件密码加密 start -->
|
||||
<dependency>
|
||||
<groupId>com.github.ulisesbocchio</groupId>
|
||||
<artifactId>jasypt-spring-boot-starter</artifactId>
|
||||
<version>2.1.0</version>
|
||||
</dependency>
|
||||
<!-- 配置文件密码加密 end -->
|
||||
|
||||
<!-- spring security start -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.security</groupId>
|
||||
<artifactId>spring-security-core</artifactId>
|
||||
<version>5.2.2.RELEASE</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.security</groupId>
|
||||
<artifactId>spring-security-config</artifactId>
|
||||
<version>5.2.2.RELEASE</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.security</groupId>
|
||||
<artifactId>spring-security-web</artifactId>
|
||||
<version>5.7.3</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.projectlombok</groupId>
|
||||
<artifactId>lombok</artifactId>
|
||||
<version>RELEASE</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<!-- spring security end -->
|
||||
|
||||
<!-- redis -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-data-redis</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.commons</groupId>
|
||||
<artifactId>commons-pool2</artifactId>
|
||||
</dependency>
|
||||
<!-- redis -->
|
||||
|
||||
<!-- easyExcel -->
|
||||
<dependency>
|
||||
<groupId>com.alibaba</groupId>
|
||||
<artifactId>easyexcel</artifactId>
|
||||
<version>3.1.3</version>
|
||||
</dependency>
|
||||
<!-- easyExcel -->
|
||||
|
||||
<dependency>
|
||||
<groupId>com.squareup.okhttp3</groupId>
|
||||
<artifactId>okhttp</artifactId>
|
||||
<version>3.3.1</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
|
|
@ -256,8 +52,8 @@
|
|||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>3.8.1</version>
|
||||
<configuration>
|
||||
<source>1.8</source>
|
||||
<target>1.8</target>
|
||||
<source>11</source>
|
||||
<target>11</target>
|
||||
</configuration>
|
||||
</plugin>
|
||||
|
||||
|
|
|
|||
|
|
@ -1,34 +0,0 @@
|
|||
package com.rzyc.advice;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import org.aspectj.lang.JoinPoint;
|
||||
import org.aspectj.lang.annotation.Aspect;
|
||||
import org.aspectj.lang.annotation.Before;
|
||||
import org.aspectj.lang.annotation.Pointcut;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import java.lang.reflect.Field;
|
||||
|
||||
/**
|
||||
* @Author jilin
|
||||
* @Date 2021/11/09 11:57
|
||||
* 分页aop
|
||||
* 注解写在mapper上,aop代理方式需为jdk代理,cglib代理无法aop mapper
|
||||
**/
|
||||
@Aspect
|
||||
@Component
|
||||
public class PageAspect {
|
||||
@Pointcut("@annotation(com.rzyc.advice.PageOperation)execution(* com.rzyc..*.*(..))")
|
||||
public void page() {}
|
||||
|
||||
@Before("page()")
|
||||
public void pageOperation(JoinPoint joinPoint) throws IllegalAccessException, NoSuchFieldException {
|
||||
Object[] args = joinPoint.getArgs();
|
||||
Class clazz = args[0].getClass();
|
||||
Field page = clazz.getDeclaredField("page");
|
||||
page.setAccessible(true);
|
||||
Field pageSize = clazz.getDeclaredField("pageSize");
|
||||
pageSize.setAccessible(true);
|
||||
PageHelper.startPage((Integer) page.get(args[0]),(Integer) pageSize.get(args[0]));
|
||||
}
|
||||
}
|
||||
|
|
@ -1,15 +0,0 @@
|
|||
package com.rzyc.advice;
|
||||
|
||||
import java.lang.annotation.*;
|
||||
|
||||
/**
|
||||
* @Author jilin
|
||||
* @Date 2021/11/09 11:59
|
||||
* 分页aop
|
||||
**/
|
||||
@Target({ElementType.PARAMETER, ElementType.METHOD})
|
||||
@Retention(RetentionPolicy.CLASS)
|
||||
@Documented
|
||||
public @interface PageOperation {
|
||||
String content() default "";
|
||||
}
|
||||
|
|
@ -7,7 +7,6 @@ import org.apache.tomcat.util.http.fileupload.impl.SizeLimitExceededException;
|
|||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.http.HttpStatus;
|
||||
import org.springframework.security.access.AccessDeniedException;
|
||||
import org.springframework.validation.BindException;
|
||||
import org.springframework.web.bind.MethodArgumentNotValidException;
|
||||
import org.springframework.web.bind.annotation.ExceptionHandler;
|
||||
|
|
@ -179,18 +178,5 @@ public class ExceptionAdvice {
|
|||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* @author Xuwanxin
|
||||
* 权限不足总捕获异常
|
||||
* */
|
||||
@ResponseBody
|
||||
@ExceptionHandler(value = AccessDeniedException.class)
|
||||
public SingleResult<String> handleAccessRE(AccessDeniedException e) {
|
||||
e.printStackTrace();
|
||||
logger.info("权限不足");
|
||||
SingleResult<String> result = new SingleResult<>();
|
||||
result.setCode(Code.AUTHORIZATION_FAILED.getCode());
|
||||
result.setMessage(Message.AUTHORIZATION_FAILED);
|
||||
return result;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ import java.util.List;
|
|||
@Aspect
|
||||
@Component
|
||||
public class PageGovAspect {
|
||||
@Pointcut("@annotation(com.common.utils.pager.PageOperation)execution(* com.rzyc..*.*(..))")
|
||||
@Pointcut("@annotation(com.rzyc.pager.PageOperation)execution(* com.rzyc..*.*(..))")
|
||||
public void page() {}
|
||||
|
||||
@Before("page()")
|
||||
|
|
|
|||
|
|
@ -1,92 +0,0 @@
|
|||
package com.rzyc.config;
|
||||
|
||||
import com.rzyc.filter.JwtAuthenticationTokenFiler;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.springframework.security.authentication.AuthenticationManager;
|
||||
import org.springframework.security.config.annotation.authentication.builders.AuthenticationManagerBuilder;
|
||||
import org.springframework.security.config.annotation.method.configuration.EnableGlobalMethodSecurity;
|
||||
import org.springframework.security.config.annotation.web.builders.HttpSecurity;
|
||||
import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity;
|
||||
import org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter;
|
||||
import org.springframework.security.config.http.SessionCreationPolicy;
|
||||
import org.springframework.security.core.userdetails.UserDetailsService;
|
||||
import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
|
||||
import org.springframework.security.crypto.password.PasswordEncoder;
|
||||
import org.springframework.security.web.authentication.UsernamePasswordAuthenticationFilter;
|
||||
|
||||
/**
|
||||
* spring security config
|
||||
* @author Xuwanxin
|
||||
* @date 2022/9/26
|
||||
* */
|
||||
@Configuration
|
||||
@EnableWebSecurity
|
||||
@EnableGlobalMethodSecurity(prePostEnabled = true)
|
||||
public class SecurityConfig extends WebSecurityConfigurerAdapter {
|
||||
|
||||
/**
|
||||
* 数据库用户连接
|
||||
*/
|
||||
private UserDetailsService userService;
|
||||
|
||||
|
||||
/**
|
||||
* token jwt 验证拦截器
|
||||
* */
|
||||
private JwtAuthenticationTokenFiler jwtAuthenticationTokenFiler;
|
||||
|
||||
@Autowired
|
||||
public void setSecurityConfigFinder(UserDetailsService userService,JwtAuthenticationTokenFiler jwtAuthenticationTokenFiler) {
|
||||
this.userService = userService;
|
||||
this.jwtAuthenticationTokenFiler = jwtAuthenticationTokenFiler;
|
||||
}
|
||||
|
||||
|
||||
@Bean
|
||||
public PasswordEncoder getPasswordEncoder() {
|
||||
return new BCryptPasswordEncoder();
|
||||
}
|
||||
|
||||
/**
|
||||
* 暴露AuthenticationManager,存上下文
|
||||
* */
|
||||
@Bean
|
||||
@Override
|
||||
public AuthenticationManager authenticationManagerBean() throws Exception
|
||||
{
|
||||
return super.authenticationManagerBean();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void configure(HttpSecurity http) throws Exception {
|
||||
http
|
||||
.authorizeRequests()
|
||||
// 对于登录接口 允许匿名访问
|
||||
.antMatchers("pcPersonal/pclogin","pcPersonal/pcManageLogin","generateCode").anonymous()
|
||||
//放行swagger
|
||||
.antMatchers("/swagger-ui.html","/swagger-resources/**","/webjars/**","/v2/**","/api/**").permitAll()
|
||||
// 除上面外的所有请求全部需要鉴权认证,配置退出路径
|
||||
.anyRequest().authenticated()
|
||||
.and()
|
||||
.logout().logoutUrl("/logout")
|
||||
.and()
|
||||
//关闭security默认登陆框
|
||||
.formLogin().disable()
|
||||
//关闭csrf
|
||||
.csrf().disable()
|
||||
//不通过Session获取SecurityContext
|
||||
.sessionManagement().sessionCreationPolicy(SessionCreationPolicy.STATELESS)
|
||||
.and().addFilterBefore(jwtAuthenticationTokenFiler, UsernamePasswordAuthenticationFilter.class)
|
||||
;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
protected void configure(AuthenticationManagerBuilder auth) throws Exception {
|
||||
// 配置数据库访问,认证步骤
|
||||
auth.userDetailsService(userService);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -1,33 +0,0 @@
|
|||
package com.rzyc.config;
|
||||
|
||||
import org.springframework.security.core.GrantedAuthority;
|
||||
import org.springframework.security.core.userdetails.User;
|
||||
|
||||
import java.util.Collection;
|
||||
|
||||
|
||||
/**
|
||||
* spring security UserDetails Custom Part
|
||||
* @author Xuwanxin
|
||||
* @date 2022/9/28
|
||||
* */
|
||||
|
||||
public class UserDetailsAndId extends User {
|
||||
|
||||
|
||||
private String id;
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public UserDetailsAndId(String username, String password, Collection<? extends GrantedAuthority> authorities, String id) {
|
||||
super(username, password, authorities);
|
||||
setId(id);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -20,7 +20,6 @@ import io.swagger.annotations.ApiOperation;
|
|||
import org.apache.commons.beanutils.BeanUtils;
|
||||
import org.apache.commons.beanutils.ConvertUtils;
|
||||
import org.apache.commons.beanutils.converters.DateConverter;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
|
|
@ -50,7 +49,6 @@ public class AppletsTaskController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "工作要务列表",position = 1)
|
||||
@GetMapping("workList")
|
||||
@PreAuthorize("hasAnyAuthority('workList','workList:update')")
|
||||
@MethodAnnotation(authorizations = {"workList","workList:update"},name = "工作要务列表")
|
||||
public MultiResult<WorkPriorityVo> workList(@Valid WorkDto workDto){
|
||||
MultiResult<WorkPriorityVo> result = new MultiResult<>();
|
||||
|
|
@ -72,7 +70,6 @@ public class AppletsTaskController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "新增或修改履职记录",position = 2)
|
||||
@PostMapping("addExecute")
|
||||
@PreAuthorize("hasAnyAuthority('addExecute','addExecute:update')")
|
||||
@MethodAnnotation(authorizations = {"addExecute","addExecute:update"},name = "工作要务列表")
|
||||
public SingleResult<String> addExecute(@Valid PerRecordDto perRecordDto) throws Exception{
|
||||
SingleResult<String> result = new SingleResult<>();
|
||||
|
|
@ -118,7 +115,6 @@ public class AppletsTaskController extends BaseController{
|
|||
@ApiImplicitParam(name = "id",value = "任务接收id(OADistributionId)")
|
||||
})
|
||||
@GetMapping("preList")
|
||||
@PreAuthorize("hasAnyAuthority('preList','preList:update')")
|
||||
@MethodAnnotation(authorizations = {"preList","preList:update"},name = "工作要务列表")
|
||||
public MultiResult<PerformanceVo> preList(@Valid IdDto idDto){
|
||||
MultiResult<PerformanceVo> result = new MultiResult<>();
|
||||
|
|
@ -134,7 +130,6 @@ public class AppletsTaskController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "专项工作列表",position = 11)
|
||||
@GetMapping("speWorkList")
|
||||
@PreAuthorize("hasAnyAuthority('speWorkList','speWorkList:update')")
|
||||
@MethodAnnotation(authorizations = {"speWorkList","speWorkList:update"},name = "工作要务列表")
|
||||
public MultiResult<SpecialWorkVo> speWorkList(@Valid SpeWorkDto SpeWorkDto){
|
||||
MultiResult<SpecialWorkVo> result = new MultiResult<>();
|
||||
|
|
@ -142,7 +137,7 @@ public class AppletsTaskController extends BaseController{
|
|||
result.setData(workList);
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @Description: 专项工作任务详情
|
||||
* @Author ZQW
|
||||
|
|
@ -153,7 +148,6 @@ public class AppletsTaskController extends BaseController{
|
|||
@ApiImplicitParams(value = {
|
||||
@ApiImplicitParam(name = "id",value = "任务接收id(OADistributionId)")
|
||||
})
|
||||
@PreAuthorize("hasAnyAuthority('singleWorkDetail','singleWorkDetail:update')")
|
||||
@MethodAnnotation(authorizations = {"singleWorkDetail","singleWorkDetail:update"},name = "工作要务列表")
|
||||
public SingleResult<SingleWorkVo> singleWorkDetail(@Valid IdDto idDto){
|
||||
SingleResult<SingleWorkVo> result = new SingleResult();
|
||||
|
|
@ -177,7 +171,6 @@ public class AppletsTaskController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "判断当前任务是否过期",position = 13)
|
||||
@PostMapping("judgeTask")
|
||||
@PreAuthorize("hasAnyAuthority('judgeTask:update')")
|
||||
@MethodAnnotation(authorizations = {"judgeTask:update"},name = "判断当前任务是否过期")
|
||||
public SingleResult<String> judgeTask(@Valid IdDto idDto){
|
||||
SingleResult<String> result = new SingleResult<>();
|
||||
|
|
@ -202,7 +195,7 @@ public class AppletsTaskController extends BaseController{
|
|||
oaTaskMapper.updateOATask(oaTask);
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
|
|
@ -212,7 +205,6 @@ public class AppletsTaskController extends BaseController{
|
|||
*/
|
||||
@ApiOperation(value = "参与人员姓名显示",position = 14)
|
||||
@GetMapping("nameList")
|
||||
@PreAuthorize("hasAnyAuthority('nameList','nameList:update')")
|
||||
@MethodAnnotation(authorizations = {"nameList","nameList:update"},name = "参与人员姓名显示")
|
||||
public MultiResult<NameVo> nameList(@Valid NameDto nameDto){
|
||||
MultiResult<NameVo> result = new MultiResult<>();
|
||||
|
|
|
|||
|
|
@ -30,7 +30,6 @@ import io.swagger.annotations.ApiImplicitParam;
|
|||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.commons.beanutils.BeanUtils;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
|
|
@ -623,7 +622,6 @@ public class EmergencyController extends BaseController {
|
|||
* */
|
||||
@ApiOperation(value = "事故类型", notes = "事故类型")
|
||||
@GetMapping("/accidentType")
|
||||
@PreAuthorize("hasAnyAuthority('accidentType','accidentType:updatae')")
|
||||
@MethodAnnotation(authorizations = {"accidentType","accidentType:update"},name = "事故类型")
|
||||
@ResponseBody
|
||||
public SingleResult<AccidentType> accidentType()throws Exception{
|
||||
|
|
|
|||
|
|
@ -7,7 +7,6 @@ import com.rzyc.model.Risk.dto.RiskDto;
|
|||
import com.rzyc.model.Risk.vo.RiskVo;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
|
|
@ -36,7 +35,6 @@ public class EnterpriseRecordController extends BaseController {
|
|||
|
||||
@ApiOperation(value = "企业证照", notes = "企业证照")
|
||||
@GetMapping("/entCertificates")
|
||||
@PreAuthorize("hasAnyAuthority('entCertificates','entCertificates:update')")
|
||||
@MethodAnnotation(authorizations = {"entCertificates","entCertificates:update"},name = "企业证照")
|
||||
@ResponseBody
|
||||
public MultiResult<EntCertificates> entCertificates(){
|
||||
|
|
@ -55,7 +53,6 @@ public class EnterpriseRecordController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "风险管控信息", notes = "风险管控信息")
|
||||
@GetMapping("/riskInformation")
|
||||
@PreAuthorize("hasAnyAuthority('riskInformation','riskInformation:update')")
|
||||
@MethodAnnotation(authorizations = {"riskInformation","riskInformation:update"},name = "风险管控信息")
|
||||
@ResponseBody
|
||||
public MultiResult<RiskVo> riskInformation(@Valid RiskDto riskDto){
|
||||
|
|
|
|||
|
|
@ -21,7 +21,6 @@ import org.apache.commons.beanutils.BeanUtils;
|
|||
import org.apache.commons.beanutils.ConvertUtils;
|
||||
import org.apache.commons.beanutils.converters.DateConverter;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
|
@ -95,7 +94,6 @@ public class WorkController extends BaseController {
|
|||
* @CreateTime 2022/11/2 17:01
|
||||
*/
|
||||
@ApiOperation(value = "修改任务", position = 2)
|
||||
@PreAuthorize("hasAnyAuthority('updateTask','updateTask:update')")
|
||||
@MethodAnnotation(authorizations = {"updateTask", "updateTask:update"}, name = "修改任务")
|
||||
@PostMapping("updateTask")
|
||||
public SingleResult<String> updateTask(@Valid AddTaskDto addTaskDto) throws Exception {
|
||||
|
|
@ -164,7 +162,6 @@ public class WorkController extends BaseController {
|
|||
@ApiImplicitParam(name = "id", value = "任务类型id"),
|
||||
@ApiImplicitParam(name = "userId", value = "用户id", required = true, dataType = "string"),
|
||||
})
|
||||
@PreAuthorize("hasAnyAuthority('thingsList','thingsList:update')")
|
||||
@MethodAnnotation(authorizations = {"thingsList", "thingsList:update"}, name = "待办事项列表")
|
||||
public MultiResult<ThingVo> thingsList(@Valid IdDto idDto, @RequestParam(required = true) String userId) {
|
||||
MultiResult<ThingVo> result = new MultiResult<>();
|
||||
|
|
@ -346,7 +343,6 @@ public class WorkController extends BaseController {
|
|||
@ApiImplicitParams(value = {
|
||||
@ApiImplicitParam(name = "id", value = "登录用户id", required = true)
|
||||
})
|
||||
@PreAuthorize("hasAnyAuthority('selectUser','selectUser:update')")
|
||||
@MethodAnnotation(authorizations = {"selectUser", "selectUser:update"}, name = "查询用户")
|
||||
public MultiResult<UserVo> selectUser(@Valid IdDto idDto) {
|
||||
MultiResult<UserVo> result = new MultiResult();
|
||||
|
|
@ -373,7 +369,6 @@ public class WorkController extends BaseController {
|
|||
@ApiImplicitParams(value = {
|
||||
@ApiImplicitParam(name = "id", value = "任务id")
|
||||
})
|
||||
@PreAuthorize("hasAnyAuthority('checkFinish','checkFinish:update')")
|
||||
@MethodAnnotation(authorizations = {"checkFinish", "checkFinish:update"}, name = "查询任务是否完成")
|
||||
public SingleResult<String> checkFinish(@Valid IdDto idDto) {
|
||||
SingleResult<String> result = new SingleResult<>();
|
||||
|
|
@ -398,7 +393,6 @@ public class WorkController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "任务流转接收人列表", position = 15)
|
||||
@GetMapping("selectFlowUser")
|
||||
@PreAuthorize("hasAnyAuthority('selectFlowUser','selectFlowUser:update')")
|
||||
@MethodAnnotation(authorizations = {"selectFlowUser", "selectFlowUser:update"}, name = "任务流转接收人列表")
|
||||
public MultiResult<FlowUserVo> selectFlowUser(@Valid FlowUserDto flowUserDto) {
|
||||
MultiResult<FlowUserVo> result = new MultiResult();
|
||||
|
|
@ -426,7 +420,6 @@ public class WorkController extends BaseController {
|
|||
@ApiImplicitParams(value = {
|
||||
@ApiImplicitParam(name = "id", value = "任务分配id")
|
||||
})
|
||||
@PreAuthorize("hasAnyAuthority('FlowUserDetail','FlowUserDetail:update')")
|
||||
@MethodAnnotation(authorizations = {"FlowUserDetail", "FlowUserDetail:update"}, name = "任务流转人详情")
|
||||
public SingleResult<FlowDetailVo> FlowUserDetail(@Valid IdDto idDto) {
|
||||
SingleResult<FlowDetailVo> result = new SingleResult();
|
||||
|
|
@ -452,7 +445,6 @@ public class WorkController extends BaseController {
|
|||
@ApiImplicitParams(value = {
|
||||
@ApiImplicitParam(name = "id", value = "任务id")
|
||||
})
|
||||
@PreAuthorize("hasAnyAuthority('modifyState','modifyState:update')")
|
||||
@MethodAnnotation(authorizations = {"modifyState", "modifyState:update"}, name = "修改任务完成状态")
|
||||
public SingleResult<String> modifyState(@Valid IdDto idDto) {
|
||||
SingleResult<String> result = new SingleResult<>();
|
||||
|
|
@ -470,7 +462,6 @@ public class WorkController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "查看发布人任务执行情况", position = 18)
|
||||
@GetMapping("selectImplementation")
|
||||
@PreAuthorize("hasAnyAuthority('selectImplementation','selectImplementation:update')")
|
||||
@MethodAnnotation(authorizations = {"selectImplementation", "selectImplementation:update"}, name = "查看发布人任务执行情况")
|
||||
public MultiResult<ImplementationVo> selectImplementation(@Valid DeliverDto deliverDto) {
|
||||
MultiResult<ImplementationVo> result = new MultiResult();
|
||||
|
|
@ -486,7 +477,6 @@ public class WorkController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "查询任务类型id", position = 20)
|
||||
@GetMapping("selectTypeId")
|
||||
@PreAuthorize("hasAnyAuthority('selectTypeId','selectTypeId:update')")
|
||||
@MethodAnnotation(authorizations = {"selectTypeId", "selectTypeId:update"}, name = "查询任务类型id")
|
||||
public MultiResult<OaTaskType> selectTypeId() {
|
||||
MultiResult<OaTaskType> result = new MultiResult();
|
||||
|
|
@ -505,7 +495,6 @@ public class WorkController extends BaseController {
|
|||
@ApiImplicitParams(value = {
|
||||
@ApiImplicitParam(name = "userId", value = "任务发送人id", required = true)
|
||||
})
|
||||
@PreAuthorize("hasAnyAuthority('selectName','selectName:update')")
|
||||
@MethodAnnotation(authorizations = {"selectName", "selectName:update"}, name = "查询参与人员姓名")
|
||||
public MultiResult<NameVo> selectName(@Valid AddWorkDto addWorkDto) {
|
||||
MultiResult<NameVo> result = new MultiResult();
|
||||
|
|
@ -524,7 +513,6 @@ public class WorkController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "应急资源列表", notes = "应急资源列表")
|
||||
@GetMapping(value = "/entEmEquipmentList")
|
||||
@PreAuthorize("hasAnyAuthority('entEmEquipmentList','entEmEquipmentList:update')")
|
||||
@MethodAnnotation(authorizations = {"entEmEquipmentList", "entEmEquipmentList:update"}, name = "应急资源列表")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "enterpriseId", value = "企业id", required = true, dataType = "string"),
|
||||
|
|
@ -549,7 +537,6 @@ public class WorkController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "应急预案列表", notes = "应急预案列表")
|
||||
@GetMapping(value = "/entEmReservePlanList")
|
||||
@PreAuthorize("hasAnyAuthority('entEmReservePlanList','entEmReservePlanList:update')")
|
||||
@MethodAnnotation(authorizations = {"entEmReservePlanList", "entEmReservePlanList:update"}, name = "应急预案列表")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "enterpriseId", value = "企业id", required = true, dataType = "string"),
|
||||
|
|
@ -572,7 +559,6 @@ public class WorkController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "查询智能预警", position = 30)
|
||||
@GetMapping("selectWarn")
|
||||
@PreAuthorize("hasAnyAuthority('selectWarn','selectWarn:update')")
|
||||
@MethodAnnotation(authorizations = {"selectWarn", "selectWarn:update"}, name = "查询智能预警")
|
||||
public MultiResult<GovWarning> selectWarn(@Valid WarnDto warnDto) {
|
||||
MultiResult<GovWarning> result = new MultiResult();
|
||||
|
|
@ -588,7 +574,6 @@ public class WorkController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "智能预警分页", notes = "智能预警分页", position = 31)
|
||||
@GetMapping("/WarnList")
|
||||
@PreAuthorize("hasAnyAuthority('WarnList','WarnList:update')")
|
||||
@MethodAnnotation(authorizations = {"WarnList", "WarnList:update"}, name = "智能预警分页")
|
||||
public SingleResult<Pager<GovWarning>> WarnList(@Valid PageDto pageDto) throws Exception {
|
||||
SingleResult<Pager<GovWarning>> result = new SingleResult<>();
|
||||
|
|
@ -608,7 +593,6 @@ public class WorkController extends BaseController {
|
|||
@ApiOperation(value = "计算未处理数量值", position = 32)
|
||||
@PostMapping("countWarnNum")
|
||||
@ApiImplicitParam(name = "type", value = "类型:1.企业重大隐患 2.隐患未按期闭环 3.企业清单未落实 4.政府履职清单未履行 5.下级未履行上级任务", required = true)
|
||||
@PreAuthorize("hasAnyAuthority('countWarnNum','countWarnNum:update')")
|
||||
@MethodAnnotation(authorizations = {"countWarnNum", "countWarnNum:update"}, name = "计算未处理数量值")
|
||||
public SingleResult<NumVo> countWarnNum(@Valid Integer type){
|
||||
SingleResult<NumVo> result = new SingleResult<>();
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@ import io.swagger.annotations.ApiImplicitParam;
|
|||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
|
|
@ -59,7 +58,6 @@ public class WxProductionController extends BaseController {
|
|||
@ApiImplicitParam(name = "enterpriseId", value = "企业id",required = false, dataType = "string"),
|
||||
})
|
||||
@GetMapping(value = "/entUserCredential")
|
||||
@PreAuthorize("hasAnyAuthority('entUserCredential','entUserCredential:update')")
|
||||
@MethodAnnotation(authorizations = {"entUserCredential","entUserCredential:update"},name = "企业用户证照表")
|
||||
@ResponseBody
|
||||
public SingleResult<List<EntUserCredential>> entUserCredential(String entUserId, @RequestParam(required = true) Integer page, @RequestParam(required = true)Integer pageSize, Integer credentialState, String enterpriseId)throws Exception{
|
||||
|
|
@ -74,7 +72,6 @@ public class WxProductionController extends BaseController {
|
|||
*/
|
||||
@ApiOperation(value = "企业设备过期列表", notes = "企业设备过期列表")
|
||||
@GetMapping(value = "/entDeviceOverdue")
|
||||
@PreAuthorize("hasAnyAuthority('entDeviceOverdue')")
|
||||
@MethodAnnotation(authorizations = {"entDeviceOverdue"},name = "应急资源删除")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "enterpriseId", value = "企业id",required = true, dataType = "string"),
|
||||
|
|
|
|||
|
|
@ -1,89 +0,0 @@
|
|||
package com.rzyc.filter;
|
||||
|
||||
import com.common.utils.jwt.JwtUtil;
|
||||
import com.rzyc.advice.CustomException;
|
||||
import com.rzyc.mapper.AuthorityKeyMapper;
|
||||
import com.rzyc.model.AuthorityKey;
|
||||
import com.rzyc.utils.IpUtil;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.AccessDeniedException;
|
||||
import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
|
||||
import org.springframework.security.core.GrantedAuthority;
|
||||
import org.springframework.security.core.authority.SimpleGrantedAuthority;
|
||||
import org.springframework.security.core.context.SecurityContextHolder;
|
||||
import org.springframework.stereotype.Component;
|
||||
import org.springframework.util.StringUtils;
|
||||
import org.springframework.web.filter.OncePerRequestFilter;
|
||||
|
||||
import javax.servlet.FilterChain;
|
||||
import javax.servlet.ServletException;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* spring security JWT Filter
|
||||
* @author Xuwanxin
|
||||
* @date 2022/9/26
|
||||
* */
|
||||
|
||||
@Component
|
||||
@Slf4j
|
||||
public class JwtAuthenticationTokenFiler extends OncePerRequestFilter {
|
||||
|
||||
@Autowired
|
||||
AuthorityKeyMapper authorityKeyMapper;
|
||||
|
||||
@Override
|
||||
protected void doFilterInternal(HttpServletRequest request, HttpServletResponse response, FilterChain filterChain) throws ServletException, IOException {
|
||||
//获取token
|
||||
String token = request.getHeader("userToken");
|
||||
|
||||
System.out.println("addr ------> "+ IpUtil.getIpAddr(request));
|
||||
/* if (!StringUtils.hasText(token)) {
|
||||
//放行
|
||||
filterChain.doFilter(request, response);
|
||||
return;
|
||||
}*/
|
||||
if(null != token){
|
||||
token = "rzyc";
|
||||
}
|
||||
|
||||
try {
|
||||
String userId = JwtUtil.getTokenMsg(token);
|
||||
} catch (Exception e) {
|
||||
System.out.println("token非法");
|
||||
throw new RuntimeException("token非法");
|
||||
}
|
||||
try {
|
||||
|
||||
List<AuthorityKey>authorizations = authorityKeyMapper.allAuthorizations();
|
||||
List<GrantedAuthority> authority= new ArrayList<GrantedAuthority>();
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
for (AuthorityKey s:authorizations) {
|
||||
stringBuilder.append(s.getAuthKey());
|
||||
authority.add(new SimpleGrantedAuthority(stringBuilder.toString()));
|
||||
stringBuilder.setLength(0);
|
||||
}
|
||||
|
||||
// 获取权限信息封装到Authentication中
|
||||
UsernamePasswordAuthenticationToken authenticationToken =
|
||||
new UsernamePasswordAuthenticationToken(null,null,authority);
|
||||
SecurityContextHolder.getContext().setAuthentication(authenticationToken);
|
||||
|
||||
|
||||
System.out.println("授权通行");
|
||||
filterChain.doFilter(request, response);
|
||||
}catch (AccessDeniedException e){
|
||||
System.out.println("权限失败");
|
||||
throw new CustomException("无权限操作");
|
||||
}catch (Exception e){
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -5,7 +5,7 @@ import com.common.utils.RandomNumber;
|
|||
import com.common.utils.model.Code;
|
||||
import com.common.utils.model.Message;
|
||||
import com.common.utils.model.SingleResult;
|
||||
import com.common.utils.pager.PageOperation;
|
||||
import com.rzyc.pager.PageOperation;
|
||||
import com.github.pagehelper.Page;
|
||||
import com.rzyc.bean.RiskSource.RiskSourceStatistic;
|
||||
import com.rzyc.config.RedisUtil;
|
||||
|
|
|
|||
|
|
@ -1,72 +0,0 @@
|
|||
package com.rzyc.service;
|
||||
|
||||
|
||||
import com.rzyc.config.UserDetailsAndId;
|
||||
import com.rzyc.mapper.AuthorityKeyMapper;
|
||||
import com.rzyc.mapper.ent.EntUserMapper;
|
||||
import com.rzyc.model.AuthorityKey;
|
||||
import com.rzyc.model.ent.EntUser;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.core.GrantedAuthority;
|
||||
import org.springframework.security.core.authority.SimpleGrantedAuthority;
|
||||
import org.springframework.security.core.userdetails.UserDetails;
|
||||
import org.springframework.security.core.userdetails.UserDetailsService;
|
||||
import org.springframework.security.core.userdetails.UsernameNotFoundException;
|
||||
import org.springframework.security.crypto.password.PasswordEncoder;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
/**
|
||||
* spring security 用户认证过程
|
||||
* @author Xuwanxin
|
||||
* @author 2022/09/27
|
||||
* */
|
||||
|
||||
@Service("userService")
|
||||
public class UserDetailsServiceImpl implements UserDetailsService {
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 内存过程密码加密
|
||||
* */
|
||||
private PasswordEncoder passwordEncoder;
|
||||
|
||||
/**
|
||||
* 企业端用户
|
||||
* */
|
||||
private EntUserMapper entUserMapper;
|
||||
|
||||
private AuthorityKeyMapper authorityKeyMapper;
|
||||
|
||||
@Autowired
|
||||
public void UserDetailsServiceImplFinder(PasswordEncoder passwordEncoder,EntUserMapper entUserMapper,AuthorityKeyMapper authorityKeyMapper) {
|
||||
this.passwordEncoder = passwordEncoder;
|
||||
this.entUserMapper = entUserMapper;
|
||||
this.authorityKeyMapper = authorityKeyMapper;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public UserDetails loadUserByUsername(String name) throws UsernameNotFoundException {
|
||||
//判断数据库用户
|
||||
EntUser entUser = entUserMapper.selectByName(name);
|
||||
if (Objects.isNull(entUser)){
|
||||
throw new UsernameNotFoundException("用户名或密码错误");
|
||||
}
|
||||
List<GrantedAuthority> authority= new ArrayList<GrantedAuthority>();
|
||||
List<AuthorityKey>authorizations = authorityKeyMapper.allAuthorizations();
|
||||
StringBuilder stringBuilder = new StringBuilder();
|
||||
for (AuthorityKey s:authorizations) {
|
||||
stringBuilder.append(s.getCategory() +":"+s.getAuthKey());
|
||||
authority.add(new SimpleGrantedAuthority(stringBuilder.toString()));
|
||||
}
|
||||
return new UserDetailsAndId(entUser.getName(), passwordEncoder.encode(entUser.getPasswd()), authority,entUser.getEntUserId());
|
||||
|
||||
}
|
||||
}
|
||||
|
|
@ -1,63 +0,0 @@
|
|||
package com.rzyc.service;
|
||||
|
||||
|
||||
import com.common.utils.jwt.JwtUtil;
|
||||
|
||||
import com.rzyc.config.UserDetailsAndId;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.authentication.BadCredentialsException;
|
||||
import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
|
||||
import org.springframework.security.core.AuthenticationException;
|
||||
import org.springframework.security.core.context.SecurityContextHolder;
|
||||
import org.springframework.security.core.userdetails.UserDetails;
|
||||
import org.springframework.security.core.userdetails.UserDetailsService;
|
||||
import org.springframework.security.core.userdetails.UsernameNotFoundException;
|
||||
import org.springframework.security.crypto.password.PasswordEncoder;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
/**
|
||||
* 用户登陆 Service
|
||||
* @author Xuwanxin
|
||||
* @date 2022/9/26
|
||||
* */
|
||||
|
||||
@Service
|
||||
public class UserLoginService {
|
||||
|
||||
|
||||
private UserDetailsService userDetailsService;
|
||||
|
||||
|
||||
private PasswordEncoder passwordEncoder;
|
||||
|
||||
@Autowired
|
||||
public void UserLoginServiceFinder(UserDetailsService userDetailsService,PasswordEncoder passwordEncoder){
|
||||
this.userDetailsService = userDetailsService;
|
||||
this.passwordEncoder = passwordEncoder;
|
||||
}
|
||||
|
||||
public String login(String username, String password) {
|
||||
String token = null;
|
||||
try {
|
||||
UserDetails userDetails = userDetailsService.loadUserByUsername(username);
|
||||
if (Objects.isNull(userDetails)) {
|
||||
throw new UsernameNotFoundException("账号不存在");
|
||||
}
|
||||
//这里可能会不对,因为我们是MD5,这个是spring security 中的 encoder加密
|
||||
if (!passwordEncoder.matches(password, userDetails.getPassword())) {
|
||||
throw new BadCredentialsException("密码不正确");
|
||||
}
|
||||
//spring security context insert
|
||||
UsernamePasswordAuthenticationToken authentication = new UsernamePasswordAuthenticationToken(userDetails, null, userDetails.getAuthorities());
|
||||
SecurityContextHolder.getContext().setAuthentication(authentication);
|
||||
//企业用户id
|
||||
String id = ((UserDetailsAndId)SecurityContextHolder.getContext().getAuthentication().getPrincipal()).getId();
|
||||
token = JwtUtil.createToken(id);
|
||||
} catch (AuthenticationException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
return token;
|
||||
}
|
||||
}
|
||||
|
|
@ -39,9 +39,9 @@ spring:
|
|||
#数据库
|
||||
datasource:
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
url: jdbc:mysql://172.27.181.52:3306/inventory_db?useUnicode=true&characterEncoding=UTF-8&serverTimezone=GMT%2B8&useSSL=false&autoReconnect=true
|
||||
username: root
|
||||
password: gzQdz2023
|
||||
url: jdbc:mysql://42.193.40.239:33063/ganzi25?useUnicode=true&characterEncoding=UTF-8&serverTimezone=GMT%2B8&useSSL=false&autoReconnect=true
|
||||
username: zyjy
|
||||
password: eaNCBySJdHLb23GW
|
||||
tomcat:
|
||||
max-active: 10
|
||||
min-idle: 10
|
||||
|
|
|
|||
531
pom.xml
531
pom.xml
|
|
@ -3,6 +3,13 @@
|
|||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<parent>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-parent</artifactId>
|
||||
<version>2.4.5</version>
|
||||
<relativePath/> <!-- lookup parent from repository -->
|
||||
</parent>
|
||||
|
||||
<groupId>com.rzyc</groupId>
|
||||
<artifactId>inventory</artifactId>
|
||||
<version>0.0.1-SNAPSHOT</version>
|
||||
|
|
@ -23,5 +30,529 @@
|
|||
<module>inventory-dao</module>
|
||||
</modules>
|
||||
|
||||
<dependencies>
|
||||
<!-- spring boot start -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-thymeleaf</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-test</artifactId>
|
||||
<scope>test</scope>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>org.junit.vintage</groupId>
|
||||
<artifactId>junit-vintage-engine</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-web</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- spring boot end -->
|
||||
|
||||
<!-- aop start -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-aop</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.aspectj</groupId>
|
||||
<artifactId>aspectjrt</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.aspectj</groupId>
|
||||
<artifactId>aspectjweaver</artifactId>
|
||||
</dependency>
|
||||
<!-- aop end -->
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- swagger end -->
|
||||
|
||||
<!-- 参数验证 start -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-validation</artifactId>
|
||||
<version>2.2.8.RELEASE</version>
|
||||
</dependency>
|
||||
<!-- 参数验证 end -->
|
||||
|
||||
|
||||
<!-- baidu start -->
|
||||
<dependency>
|
||||
<groupId>com.baidu.aip</groupId>
|
||||
<artifactId>java-sdk</artifactId>
|
||||
<version>4.15.3</version>
|
||||
</dependency>
|
||||
<!-- baidu end -->
|
||||
|
||||
<!--xunfeiVoice start-->
|
||||
<dependency>
|
||||
<groupId>commons-codec</groupId>
|
||||
<artifactId>commons-codec</artifactId>
|
||||
<version>1.9</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.java-websocket</groupId>
|
||||
<artifactId>Java-WebSocket</artifactId>
|
||||
<version>1.3.4</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-logging</groupId>
|
||||
<artifactId>commons-logging</artifactId>
|
||||
<version>1.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.httpcomponents</groupId>
|
||||
<artifactId>httpclient</artifactId>
|
||||
<version>4.5.8</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.httpcomponents</groupId>
|
||||
<artifactId>httpcore</artifactId>
|
||||
<version>4.4.11</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.httpcomponents</groupId>
|
||||
<artifactId>httpmime</artifactId>
|
||||
<version>4.5.8</version>
|
||||
</dependency>
|
||||
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-websocket</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- pdf start -->
|
||||
|
||||
<dependency>
|
||||
<groupId>com.itextpdf</groupId>
|
||||
<artifactId>itextpdf</artifactId>
|
||||
<version>5.0.6</version>
|
||||
</dependency>
|
||||
<!-- pdf end -->
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- 配置文件密码加密 start -->
|
||||
<dependency>
|
||||
<groupId>com.github.ulisesbocchio</groupId>
|
||||
<artifactId>jasypt-spring-boot-starter</artifactId>
|
||||
<version>2.1.0</version>
|
||||
</dependency>
|
||||
<!-- 配置文件密码加密 end -->
|
||||
|
||||
|
||||
|
||||
<!-- redis -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-data-redis</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.commons</groupId>
|
||||
<artifactId>commons-pool2</artifactId>
|
||||
</dependency>
|
||||
<!-- redis -->
|
||||
|
||||
<!-- easyExcel -->
|
||||
<dependency>
|
||||
<groupId>com.alibaba</groupId>
|
||||
<artifactId>easyexcel</artifactId>
|
||||
<version>3.1.3</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.testng</groupId>
|
||||
<artifactId>testng</artifactId>
|
||||
<version>RELEASE</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
<!-- easyExcel -->
|
||||
|
||||
<dependency>
|
||||
<groupId>com.squareup.okhttp3</groupId>
|
||||
<artifactId>okhttp</artifactId>
|
||||
<version>3.3.1</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
<!-- mybatis start -->
|
||||
<dependency>
|
||||
<groupId>com.baomidou</groupId>
|
||||
<artifactId>mybatis-plus-boot-starter</artifactId>
|
||||
<version>3.4.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.baomidou</groupId>
|
||||
<artifactId>mybatis-plus</artifactId>
|
||||
<version>3.4.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.baomidou</groupId>
|
||||
<artifactId>mybatis-plus-generator</artifactId>
|
||||
<version>3.3.2</version>
|
||||
</dependency>
|
||||
|
||||
<!-- mybatis end -->
|
||||
|
||||
<!-- mysql start -->
|
||||
<dependency>
|
||||
<groupId>mysql</groupId>
|
||||
<artifactId>mysql-connector-java</artifactId>
|
||||
<version>8.0.31</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.freemarker</groupId>
|
||||
<artifactId>freemarker</artifactId>
|
||||
<version>2.3.30</version>
|
||||
</dependency>
|
||||
<!-- mysql end -->
|
||||
|
||||
<!--分页插件 start -->
|
||||
<dependency>
|
||||
<groupId>com.github.pagehelper</groupId>
|
||||
<artifactId>pagehelper-spring-boot-starter</artifactId>
|
||||
<version>1.4.7</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>org.mybatis</groupId>
|
||||
<artifactId>mybatis</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<!-- 插件 end -->
|
||||
|
||||
<!-- 参数验证 start -->
|
||||
|
||||
<dependency>
|
||||
<groupId>org.projectlombok</groupId>
|
||||
<artifactId>lombok</artifactId>
|
||||
<version>RELEASE</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<!-- 参数验证 end -->
|
||||
|
||||
<!-- servlet start -->
|
||||
<dependency>
|
||||
<groupId>javax.servlet</groupId>
|
||||
<artifactId>javax.servlet-api</artifactId>
|
||||
<version>3.1.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<!-- servlet end -->
|
||||
|
||||
|
||||
<!-- apache 提供的一些工具类 -->
|
||||
<dependency>
|
||||
<groupId>commons-codec</groupId>
|
||||
<artifactId>commons-codec</artifactId>
|
||||
<version>1.9</version>
|
||||
</dependency>
|
||||
<!-- 集合类操作 -->
|
||||
<dependency>
|
||||
<groupId>org.apache.commons</groupId>
|
||||
<artifactId>commons-collections4</artifactId>
|
||||
<version>4.1</version>
|
||||
</dependency>
|
||||
|
||||
<!-- binlog 监听与解析: https://github.com/shyiko/mysql-binlog-connector-java -->
|
||||
<dependency>
|
||||
<groupId>com.github.shyiko</groupId>
|
||||
<artifactId>mysql-binlog-connector-java</artifactId>
|
||||
<version>0.13.0</version>
|
||||
</dependency>
|
||||
|
||||
|
||||
|
||||
<dependency>
|
||||
<groupId>com.alibaba</groupId>
|
||||
<artifactId>fastjson</artifactId>
|
||||
<version>1.2.31</version>
|
||||
</dependency>
|
||||
|
||||
|
||||
<dependency>
|
||||
<groupId>org.jsoup</groupId>
|
||||
<artifactId>jsoup</artifactId>
|
||||
<version>1.7.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.aliyun.oss</groupId>
|
||||
<artifactId>aliyun-sdk-oss</artifactId>
|
||||
<version>2.2.3</version>
|
||||
</dependency>
|
||||
<!--alipay start-->
|
||||
<dependency>
|
||||
<groupId>com.alipay.sdk</groupId>
|
||||
<artifactId>alipay-sdk-java</artifactId>
|
||||
<version>3.7.4.ALL</version>
|
||||
</dependency>
|
||||
<!--alipay end-->
|
||||
|
||||
<!--amap start-->
|
||||
<dependency>
|
||||
<groupId>com.amap.api</groupId>
|
||||
<artifactId>3dmap</artifactId>
|
||||
<version>7.7.0</version>
|
||||
</dependency>
|
||||
<!--amap end-->
|
||||
|
||||
<!-- 网络请求 start -->
|
||||
<dependency>
|
||||
<groupId>commons-httpclient</groupId>
|
||||
<artifactId>commons-httpclient</artifactId>
|
||||
<version>3.1</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.httpcomponents</groupId>
|
||||
<artifactId>httpclient</artifactId>
|
||||
<version>4.5.9</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.httpcomponents</groupId>
|
||||
<artifactId>httpmime</artifactId>
|
||||
<version>4.5.9</version>
|
||||
</dependency>
|
||||
<!-- 网络请求 end -->
|
||||
|
||||
<!-- HikariCP start -->
|
||||
<dependency>
|
||||
<groupId>commons-dbutils</groupId>
|
||||
<artifactId>commons-dbutils</artifactId>
|
||||
<version>1.7</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.zaxxer</groupId>
|
||||
<artifactId>HikariCP</artifactId>
|
||||
<version>2.7.2</version>
|
||||
</dependency>
|
||||
<!-- HikariCP end -->
|
||||
|
||||
<!-- jpush start -->
|
||||
<dependency>
|
||||
<groupId>cn.jpush.api</groupId>
|
||||
<artifactId>jpush-client</artifactId>
|
||||
<version>3.3.10</version>
|
||||
</dependency>
|
||||
<!-- jpush end -->
|
||||
|
||||
<!-- mongodb start -->
|
||||
<dependency>
|
||||
<groupId>org.mongodb</groupId>
|
||||
<artifactId>mongodb-driver</artifactId>
|
||||
<version>3.4.2</version>
|
||||
</dependency>
|
||||
<!-- mongodb end -->
|
||||
|
||||
<dependency>
|
||||
<groupId>org.json</groupId>
|
||||
<artifactId>json</artifactId>
|
||||
<version>20160810</version>
|
||||
</dependency>
|
||||
|
||||
<!-- 二维码 start -->
|
||||
<dependency>
|
||||
<groupId>com.google.zxing</groupId>
|
||||
<artifactId>core</artifactId>
|
||||
<version>3.3.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.google.zxing</groupId>
|
||||
<artifactId>javase</artifactId>
|
||||
<version>3.3.0</version>
|
||||
</dependency>
|
||||
<!-- 二维码 end -->
|
||||
|
||||
<!-- redis start -->
|
||||
<dependency>
|
||||
<groupId>redis.clients</groupId>
|
||||
<artifactId>jedis</artifactId>
|
||||
<version>2.9.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>commons-pool</groupId>
|
||||
<artifactId>commons-pool</artifactId>
|
||||
<version>1.6</version>
|
||||
</dependency>
|
||||
<!-- redis end -->
|
||||
|
||||
|
||||
|
||||
<!-- excel download start -->
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>poi</artifactId>
|
||||
<version>4.1.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>poi-ooxml</artifactId>
|
||||
<version>4.1.0</version>
|
||||
</dependency>
|
||||
<!-- excel download end -->
|
||||
|
||||
|
||||
<!-- swagger start -->
|
||||
<dependency>
|
||||
<groupId>io.springfox</groupId>
|
||||
<artifactId>springfox-swagger2</artifactId>
|
||||
<version>2.9.2</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>io.swagger</groupId>
|
||||
<artifactId>swagger-models</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.swagger</groupId>
|
||||
<artifactId>swagger-models</artifactId>
|
||||
<version>1.5.21</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.springfox</groupId>
|
||||
<artifactId>springfox-swagger-ui</artifactId>
|
||||
<version>2.9.2</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.github.xiaoymin</groupId>
|
||||
<artifactId>swagger-bootstrap-ui</artifactId>
|
||||
<version>1.9.6</version>
|
||||
</dependency>
|
||||
<!-- swagger end -->
|
||||
|
||||
<!-- dom4j start -->
|
||||
<dependency>
|
||||
<groupId>dom4j</groupId>
|
||||
<artifactId>dom4j</artifactId>
|
||||
<version>1.6.1</version>
|
||||
</dependency>
|
||||
<!-- dom4j end -->
|
||||
|
||||
<dependency>
|
||||
<groupId>com.auth0</groupId>
|
||||
<artifactId>java-jwt</artifactId>
|
||||
<version>3.10.3</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-deploy-plugin</artifactId>
|
||||
<version>2.7</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-io</groupId>
|
||||
<artifactId>commons-io</artifactId>
|
||||
<version>2.6</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
<!-- pdf start -->
|
||||
<dependency>
|
||||
<groupId>com.itextpdf</groupId>
|
||||
<artifactId>itextpdf</artifactId>
|
||||
<version>5.5.10</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.itextpdf</groupId>
|
||||
<artifactId>itext-asian</artifactId>
|
||||
<version>5.2.0</version>
|
||||
</dependency>
|
||||
<!-- pdf end -->
|
||||
|
||||
<!-- 文档 start -->
|
||||
<dependency>
|
||||
<groupId>cn.afterturn</groupId>
|
||||
<artifactId>easypoi-base</artifactId>
|
||||
<version>4.1.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.jfree</groupId>
|
||||
<artifactId>jcommon</artifactId>
|
||||
<version>1.0.24</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.jfree</groupId>
|
||||
<artifactId>jfreechart</artifactId>
|
||||
<version>1.5.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>cn.afterturn</groupId>
|
||||
<artifactId>easypoi</artifactId>
|
||||
<version>4.1.2</version>
|
||||
<type>pom</type>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>cn.afterturn</groupId>
|
||||
<artifactId>easypoi-spring-boot-starter</artifactId>
|
||||
<version>4.4.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>poi-ooxml-schemas</artifactId>
|
||||
<version>4.1.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>poi-ooxml</artifactId>
|
||||
<version>4.1.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>poi</artifactId>
|
||||
<version>4.1.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>poi-scratchpad</artifactId>
|
||||
<version>4.1.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.xmlbeans</groupId>
|
||||
<artifactId>xmlbeans</artifactId>
|
||||
<version>3.1.0</version>
|
||||
</dependency>
|
||||
|
||||
<!-- 文档 end -->
|
||||
|
||||
<dependency>
|
||||
<groupId>cn.hutool</groupId>
|
||||
<artifactId>hutool-all</artifactId>
|
||||
<version>5.8.11</version>
|
||||
</dependency>
|
||||
|
||||
|
||||
</dependencies>
|
||||
|
||||
|
||||
</project>
|
||||
|
|
|
|||
323
utils/pom.xml
323
utils/pom.xml
|
|
@ -5,6 +5,13 @@
|
|||
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<parent>
|
||||
<groupId>com.rzyc</groupId>
|
||||
<artifactId>inventory</artifactId>
|
||||
<version>0.0.1-SNAPSHOT</version>
|
||||
<relativePath>../pom.xml</relativePath> <!-- lookup parent from repository -->
|
||||
</parent>
|
||||
|
||||
<groupId>com.rzyc</groupId>
|
||||
<artifactId>utils</artifactId>
|
||||
<version>1.0-SNAPSHOT</version>
|
||||
|
|
@ -18,319 +25,7 @@
|
|||
|
||||
<dependencies>
|
||||
|
||||
<!-- apache 提供的一些工具类 -->
|
||||
<dependency>
|
||||
<groupId>commons-codec</groupId>
|
||||
<artifactId>commons-codec</artifactId>
|
||||
<version>1.9</version>
|
||||
</dependency>
|
||||
<!-- 集合类操作 -->
|
||||
<dependency>
|
||||
<groupId>org.apache.commons</groupId>
|
||||
<artifactId>commons-collections4</artifactId>
|
||||
<version>4.1</version>
|
||||
</dependency>
|
||||
|
||||
<!-- binlog 监听与解析: https://github.com/shyiko/mysql-binlog-connector-java -->
|
||||
<dependency>
|
||||
<groupId>com.github.shyiko</groupId>
|
||||
<artifactId>mysql-binlog-connector-java</artifactId>
|
||||
<version>0.13.0</version>
|
||||
</dependency>
|
||||
|
||||
|
||||
|
||||
<dependency>
|
||||
<groupId>com.alibaba</groupId>
|
||||
<artifactId>fastjson</artifactId>
|
||||
<version>1.2.31</version>
|
||||
</dependency>
|
||||
|
||||
|
||||
<dependency>
|
||||
<groupId>org.jsoup</groupId>
|
||||
<artifactId>jsoup</artifactId>
|
||||
<version>1.7.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.aliyun.oss</groupId>
|
||||
<artifactId>aliyun-sdk-oss</artifactId>
|
||||
<version>2.2.3</version>
|
||||
</dependency>
|
||||
<!--alipay start-->
|
||||
<dependency>
|
||||
<groupId>com.alipay.sdk</groupId>
|
||||
<artifactId>alipay-sdk-java</artifactId>
|
||||
<version>3.7.4.ALL</version>
|
||||
</dependency>
|
||||
<!--alipay end-->
|
||||
|
||||
<!--amap start-->
|
||||
<dependency>
|
||||
<groupId>com.amap.api</groupId>
|
||||
<artifactId>3dmap</artifactId>
|
||||
<version>7.7.0</version>
|
||||
</dependency>
|
||||
<!--amap end-->
|
||||
|
||||
<!-- 网络请求 start -->
|
||||
<dependency>
|
||||
<groupId>commons-httpclient</groupId>
|
||||
<artifactId>commons-httpclient</artifactId>
|
||||
<version>3.1</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.httpcomponents</groupId>
|
||||
<artifactId>httpclient</artifactId>
|
||||
<version>4.5.9</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.httpcomponents</groupId>
|
||||
<artifactId>httpmime</artifactId>
|
||||
<version>4.5.9</version>
|
||||
</dependency>
|
||||
<!-- 网络请求 end -->
|
||||
|
||||
<!-- HikariCP start -->
|
||||
<dependency>
|
||||
<groupId>commons-dbutils</groupId>
|
||||
<artifactId>commons-dbutils</artifactId>
|
||||
<version>1.7</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.zaxxer</groupId>
|
||||
<artifactId>HikariCP</artifactId>
|
||||
<version>2.7.2</version>
|
||||
</dependency>
|
||||
<!-- HikariCP end -->
|
||||
|
||||
<!-- jpush start -->
|
||||
<dependency>
|
||||
<groupId>cn.jpush.api</groupId>
|
||||
<artifactId>jpush-client</artifactId>
|
||||
<version>3.3.10</version>
|
||||
</dependency>
|
||||
<!-- jpush end -->
|
||||
|
||||
<!-- mongodb start -->
|
||||
<dependency>
|
||||
<groupId>org.mongodb</groupId>
|
||||
<artifactId>mongodb-driver</artifactId>
|
||||
<version>3.4.2</version>
|
||||
</dependency>
|
||||
<!-- mongodb end -->
|
||||
|
||||
<dependency>
|
||||
<groupId>org.json</groupId>
|
||||
<artifactId>json</artifactId>
|
||||
<version>20160810</version>
|
||||
</dependency>
|
||||
|
||||
<!-- 二维码 start -->
|
||||
<dependency>
|
||||
<groupId>com.google.zxing</groupId>
|
||||
<artifactId>core</artifactId>
|
||||
<version>3.3.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.google.zxing</groupId>
|
||||
<artifactId>javase</artifactId>
|
||||
<version>3.3.0</version>
|
||||
</dependency>
|
||||
<!-- 二维码 end -->
|
||||
|
||||
<!-- redis start -->
|
||||
<dependency>
|
||||
<groupId>redis.clients</groupId>
|
||||
<artifactId>jedis</artifactId>
|
||||
<version>2.9.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>commons-pool</groupId>
|
||||
<artifactId>commons-pool</artifactId>
|
||||
<version>1.6</version>
|
||||
</dependency>
|
||||
<!-- redis end -->
|
||||
|
||||
|
||||
|
||||
<!-- excel download start -->
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>poi</artifactId>
|
||||
<version>4.1.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>poi-ooxml</artifactId>
|
||||
<version>4.1.0</version>
|
||||
</dependency>
|
||||
<!-- excel download end -->
|
||||
|
||||
|
||||
<!-- swagger start -->
|
||||
<dependency>
|
||||
<groupId>io.springfox</groupId>
|
||||
<artifactId>springfox-swagger2</artifactId>
|
||||
<version>2.9.2</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>io.swagger</groupId>
|
||||
<artifactId>swagger-models</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.swagger</groupId>
|
||||
<artifactId>swagger-models</artifactId>
|
||||
<version>1.5.21</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.springfox</groupId>
|
||||
<artifactId>springfox-swagger-ui</artifactId>
|
||||
<version>2.9.2</version>
|
||||
</dependency>
|
||||
<!-- swagger end -->
|
||||
|
||||
<!-- dom4j start -->
|
||||
<dependency>
|
||||
<groupId>dom4j</groupId>
|
||||
<artifactId>dom4j</artifactId>
|
||||
<version>1.6.1</version>
|
||||
</dependency>
|
||||
<!-- dom4j end -->
|
||||
|
||||
<!-- servlet start -->
|
||||
<dependency>
|
||||
<groupId>javax.servlet</groupId>
|
||||
<artifactId>javax.servlet-api</artifactId>
|
||||
<version>3.1.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<!-- servlet end -->
|
||||
|
||||
<dependency>
|
||||
<groupId>com.auth0</groupId>
|
||||
<artifactId>java-jwt</artifactId>
|
||||
<version>3.10.3</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-deploy-plugin</artifactId>
|
||||
<version>2.7</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-io</groupId>
|
||||
<artifactId>commons-io</artifactId>
|
||||
<version>2.6</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
<!-- pdf start -->
|
||||
<dependency>
|
||||
<groupId>com.itextpdf</groupId>
|
||||
<artifactId>itextpdf</artifactId>
|
||||
<version>5.5.10</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.itextpdf</groupId>
|
||||
<artifactId>itext-asian</artifactId>
|
||||
<version>5.2.0</version>
|
||||
</dependency>
|
||||
<!-- pdf end -->
|
||||
|
||||
<!-- 文档 start -->
|
||||
<dependency>
|
||||
<groupId>cn.afterturn</groupId>
|
||||
<artifactId>easypoi-base</artifactId>
|
||||
<version>4.1.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.jfree</groupId>
|
||||
<artifactId>jcommon</artifactId>
|
||||
<version>1.0.24</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.jfree</groupId>
|
||||
<artifactId>jfreechart</artifactId>
|
||||
<version>1.5.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>cn.afterturn</groupId>
|
||||
<artifactId>easypoi</artifactId>
|
||||
<version>4.1.2</version>
|
||||
<type>pom</type>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>cn.afterturn</groupId>
|
||||
<artifactId>easypoi-spring-boot-starter</artifactId>
|
||||
<version>4.4.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>poi-ooxml-schemas</artifactId>
|
||||
<version>4.1.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>poi-ooxml</artifactId>
|
||||
<version>4.1.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>poi</artifactId>
|
||||
<version>4.1.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>poi-scratchpad</artifactId>
|
||||
<version>4.1.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.xmlbeans</groupId>
|
||||
<artifactId>xmlbeans</artifactId>
|
||||
<version>3.1.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>ooxml-schemas</artifactId>
|
||||
<version>1.4</version>
|
||||
</dependency>
|
||||
|
||||
<!-- 文档 end -->
|
||||
|
||||
<!--分页 start-->
|
||||
<dependency>
|
||||
<groupId>com.fasterxml.jackson.core</groupId>
|
||||
<artifactId>jackson-databind</artifactId>
|
||||
<version>2.10.2</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.github.pagehelper</groupId>
|
||||
<artifactId>pagehelper</artifactId>
|
||||
<version>5.1.4</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.fasterxml.jackson.core</groupId>
|
||||
<artifactId>jackson-databind</artifactId>
|
||||
<version>2.13.3</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<!--分页 end-->
|
||||
|
||||
<dependency>
|
||||
<groupId>cn.hutool</groupId>
|
||||
<artifactId>hutool-all</artifactId>
|
||||
<version>5.8.11</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
|
|
@ -341,8 +36,8 @@
|
|||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>3.8.1</version>
|
||||
<configuration>
|
||||
<source>1.8</source>
|
||||
<target>1.8</target>
|
||||
<source>11</source>
|
||||
<target>11</target>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
|
|
|
|||
|
|
@ -125,7 +125,7 @@ public class ENDEUtils {
|
|||
|
||||
public static void main(String[] args) {
|
||||
//加密请求测试JSON格式字符参数
|
||||
String bodyStr = "{\"sysUniqueCode\":\"273556746985934848\"}";
|
||||
String bodyStr = "{\"sysUniqueCode\":\"127829545796636679\"}";
|
||||
//加密请求参数
|
||||
JSONObject req = RSAEncryptRequest(bodyStr);
|
||||
System.out.println("k----> "+req.getString("k"));
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user