Commit 28f58958 authored by 严国华's avatar 严国华

20251212专家库试运行定版

parent 767beba5
......@@ -27,9 +27,8 @@ steps:
secret_key:
from_secret: SECRET_KEY_MINIO
- name: build
image: hub.wodcloud.com/base/devops-maven:3.8-openjdk-17
image: registry.cn-qingdao.aliyuncs.com/wod/devops-maven:3.8-openjdk-11
commands:
- mvn clean install -Dmaven.test.skip=true
......@@ -46,74 +45,74 @@ steps:
from_secret: ACCESS_KEY_MINIO
secret_key:
from_secret: SECRET_KEY_MINIO
# - name: docker-system-amd64
# image: registry.cn-qingdao.aliyuncs.com/wod/devops-docker:1.0
# volumes:
# - name: docker-sock
# path: /var/run/docker.sock
# settings:
# base: registry.cn-qingdao.aliyuncs.com/wod/openjdk:11.0-jdk-amd64 # 基础镜像
# dockerfile: .beagle/dockerfile.system
# repo: zjk/system
# version: "1.0"
# channel: amd64
# args: "TARGETOS=linux,TARGETARCH=amd64"
# registry: hub.wodcloud.com
# registry_user:
# from_secret: REGISTRY_USER
# registry_password:
# from_secret: REGISTRY_PASSWORD
# - name: docker-auth-amd64
# image: registry.cn-qingdao.aliyuncs.com/wod/devops-docker:1.0
# volumes:
# - name: docker-sock
# path: /var/run/docker.sock
# settings:
# base: registry.cn-qingdao.aliyuncs.com/wod/openjdk:11.0-jdk-amd64 # 基础镜像
# dockerfile: .beagle/dockerfile.auth
# repo: zjk/auth
# version: "1.0"
# channel: amd64
# args: "TARGETOS=linux,TARGETARCH=amd64"
# registry: hub.wodcloud.com
# registry_user:
# from_secret: REGISTRY_USER
# registry_password:
# from_secret: REGISTRY_PASSWORD
# - name: docker-resource-amd64
# image: registry.cn-qingdao.aliyuncs.com/wod/devops-docker:1.0
# volumes:
# - name: docker-sock
# path: /var/run/docker.sock
# settings:
# base: registry.cn-qingdao.aliyuncs.com/wod/openjdk:11.0-jdk-amd64 # 基础镜像
# dockerfile: .beagle/dockerfile.resource
# repo: zjk/resource
# version: "1.0"
# channel: amd64
# args: "TARGETOS=linux,TARGETARCH=amd64"
# registry: hub.wodcloud.com
# registry_user:
# from_secret: REGISTRY_USER
# registry_password:
# from_secret: REGISTRY_PASSWORD
# - name: docker-zjkapi-amd64
# image: registry.cn-qingdao.aliyuncs.com/wod/devops-docker:1.0
# volumes:
# - name: docker-sock
# path: /var/run/docker.sock
# settings:
# base: registry.cn-qingdao.aliyuncs.com/wod/openjdk:11.0-jdk-amd64 # 基础镜像
# dockerfile: .beagle/dockerfile.zjkapi
# repo: zjk/zjk-api
# version: "1.0"
# channel: amd64
# args: "TARGETOS=linux,TARGETARCH=amd64"
# registry: hub.wodcloud.com
# registry_user:
# from_secret: REGISTRY_USER
# registry_password:
# from_secret: REGISTRY_PASSWORD
# - name: docker-system-amd64
# image: registry.cn-qingdao.aliyuncs.com/wod/devops-docker:1.0
# volumes:
# - name: docker-sock
# path: /var/run/docker.sock
# settings:
# base: registry.cn-qingdao.aliyuncs.com/wod/openjdk:11.0-jdk-amd64 # 基础镜像
# dockerfile: .beagle/dockerfile.system
# repo: zjk/system
# version: "1.0"
# channel: amd64
# args: "TARGETOS=linux,TARGETARCH=amd64"
# registry: hub.wodcloud.com
# registry_user:
# from_secret: REGISTRY_USER
# registry_password:
# from_secret: REGISTRY_PASSWORD
# - name: docker-auth-amd64
# image: registry.cn-qingdao.aliyuncs.com/wod/devops-docker:1.0
# volumes:
# - name: docker-sock
# path: /var/run/docker.sock
# settings:
# base: registry.cn-qingdao.aliyuncs.com/wod/openjdk:11.0-jdk-amd64 # 基础镜像
# dockerfile: .beagle/dockerfile.auth
# repo: zjk/auth
# version: "1.0"
# channel: amd64
# args: "TARGETOS=linux,TARGETARCH=amd64"
# registry: hub.wodcloud.com
# registry_user:
# from_secret: REGISTRY_USER
# registry_password:
# from_secret: REGISTRY_PASSWORD
# - name: docker-resource-amd64
# image: registry.cn-qingdao.aliyuncs.com/wod/devops-docker:1.0
# volumes:
# - name: docker-sock
# path: /var/run/docker.sock
# settings:
# base: registry.cn-qingdao.aliyuncs.com/wod/openjdk:11.0-jdk-amd64 # 基础镜像
# dockerfile: .beagle/dockerfile.resource
# repo: zjk/resource
# version: "1.0"
# channel: amd64
# args: "TARGETOS=linux,TARGETARCH=amd64"
# registry: hub.wodcloud.com
# registry_user:
# from_secret: REGISTRY_USER
# registry_password:
# from_secret: REGISTRY_PASSWORD
# - name: docker-zjkapi-amd64
# image: registry.cn-qingdao.aliyuncs.com/wod/devops-docker:1.0
# volumes:
# - name: docker-sock
# path: /var/run/docker.sock
# settings:
# base: registry.cn-qingdao.aliyuncs.com/wod/openjdk:11.0-jdk-amd64 # 基础镜像
# dockerfile: .beagle/dockerfile.zjkapi
# repo: zjk/zjk-api
# version: "1.0"
# channel: amd64
# args: "TARGETOS=linux,TARGETARCH=amd64"
# registry: hub.wodcloud.com
# registry_user:
# from_secret: REGISTRY_USER
# registry_password:
# from_secret: REGISTRY_PASSWORD
- name: docker-zjkapi-arm64
image: registry.cn-qingdao.aliyuncs.com/wod/devops-docker:1.0
......
# 使用基础镜像作为构建起点
ARG BASE
FROM ${BASE}
# 设置时区
RUN echo "Asia/Shanghai" > /etc/timezone
# 拷贝 .service 和 .job 的 jar 包到容器中
COPY ../jtjxx-service/target/jtjxx-service-0.0.1-SNAPSHOT.jar /app/jtjxx-service.jar
COPY ../jtjxx-job/powerjob-server/powerjob-server-starter/target/jtjxx-job-service.jar /app/jtjxx-job-service.jar
# 暴露两个服务所需的端口
EXPOSE 8091 7700
# 启动脚本:同时启动两个 Java 服务
ENTRYPOINT ["sh", "-c", "java -jar /app/jtjxx-service.jar -Duser.timezone=Asia/Shanghai & java -jar /app/jtjxx-job-service.jar -Duser.timezone=Asia/Shanghai"]
FROM hub.wodcloud.com/base/openjdk17:17-jdk-slim
# 安装 Maven
ARG MAVEN_VERSION=3.8.6
ARG USER_HOME_DIR="/root"
ARG SHA=c704d082a11eca8344b68347029f51ad59588714ded9078f61393e505064ac0263390717454071242948aa1b390604529512033750907819f032220151745cf7
ARG BASE_URL=https://archive.apache.org/dist/maven/maven-3/${MAVEN_VERSION}/binaries
RUN mkdir -p /usr/share/maven /usr/share/maven/ref \
&& curl -fsSL -o /tmp/apache-maven.tar.gz ${BASE_URL}/apache-maven-${MAVEN_VERSION}-bin.tar.gz \
&& echo "${SHA} /tmp/apache-maven.tar.gz" | sha512sum -c - \
&& tar -xzf /tmp/apache-maven.tar.gz -C /usr/share/maven --strip-components=1 \
&& rm -f /tmp/apache-maven.tar.gz \
&& ln -s /usr/share/maven/bin/mvn /usr/bin/mvn
ENV MAVEN_HOME /usr/share/maven
ENV MAVEN_CONFIG "$USER_HOME_DIR/.m2"
# 创建 .m2 目录
RUN mkdir -p $USER_HOME_DIR/.m2
MIT License
Copyright (c) 2022 RuoYi-Cloud-Plus
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
......@@ -7,7 +7,7 @@ spring:
boot:
admin:
ui:
title: RuoYi-Cloud-Plus服务监控中心
title: 专家库服务监控中心
discovery:
# seata 不具有健康检查的能力 防止报错排除掉
ignored-services: ruoyi-seata-server
ALTER TABLE "zjk_expert"
ADD COLUMN "scope_of_activity" varchar(255),
ADD COLUMN "is_classified" tinyint DEFAULT 0;
COMMENT ON COLUMN "zjk_expert"."scope_of_activity" IS '活动范围';
COMMENT ON COLUMN "zjk_expert"."is_classified" IS '是否涉密';
delete from zjk_expert where expert_id in (select expert_id from zjk_expert where to_date(create_time, 'YYYY-MM-DD')< '2025-12-10')
delete from zjk_review_phase;
delete from zjk_product;
delete from zjk_product_reviewsn;
delete from zjk_product_summarize;
delete from zjk_product_summarize_log;
delete from zjk_project_evaluation;
delete from zjk_retirement_records;
delete from zjk_settlement_voucher;
delete from zjk_point;
delete from zjk_point_user;
delete from zjk_leave;
delete from zjk_item_extreation;
delete from zjk_credit;
delete from zjk_credit_reward;
delete from zjk_annual_inspection;
delete from zjk_annual_inspection_copy1;
delete from zjk_annual_inspection_records;
delete from zjk_credit_reward;
--删除抽取记录
delete from zjk_item_extreation where id ='1998937901021708289';
delete from zjk_review_phase where id=34;
delete from zjk_expert_item where review_id=34;
@startuml
class org.dromara.zjk.controller.ZjkEvaluateController {
- ZjkEvaluateService zjkEvaluateService
+ TableDataInfo<ZjkEvaluateVO> listToZj(ZjkEvaluateVO,PageQuery)
+ TableDataInfo<ZjkEvaluateVO> listToOrg(ZjkEvaluateVO,PageQuery)
+ TableDataInfo<ZjkEvaluateVO> listToXm(ZjkEvaluateVO,PageQuery)
+ R<Void> addComment(ZjkEvaluateVO)
+ R<ZjkEvaluateVO> getInfo(String)
+ TableDataInfo<ZjkEvaluateVO> getEvaluateListByExpert(ZjkEvaluateVO,PageQuery)
+ R<StsEvaluateNumVO> getStsNum()
+ R<StsEvaluateVO> stsChart(Integer)
+ TableDataInfo<StsListVO> getStsList(ZjkEvaluateVO,PageQuery)
+ void export(ZjkEvaluateVO,HttpServletResponse)
}
org.dromara.common.web.core.BaseController <|-- org.dromara.zjk.controller.ZjkEvaluateController
@enduml
\ No newline at end of file
......@@ -72,6 +72,7 @@ public interface RemoteUserService {
Boolean wbjregisterUserInfo(List<RemoteUserBo> remoteUserBo) throws UserException, ServiceException;
Boolean expertRegisterUserInfo(List<RemoteUserBo> remoteUserBo,String tenantId) throws UserException, ServiceException;
Boolean expertRegisterUserInfoForSpj(List<RemoteUserBo> remoteUserBo,String tenantId) throws UserException, ServiceException;
/**
* 通过userId查询用户账户
......
......@@ -190,6 +190,7 @@ public class TokenController {
}
return R.ok(sxzwfwLoginService.sxzwfwUserInfo(null, clientId, accessLink, acctType, tenantId));
} catch (Exception e) {
e.printStackTrace();
throw new ServiceException("登陆失败请重试"+e.getMessage());
}
......
package org.dromara.common.core.config;
import org.springframework.boot.autoconfigure.AutoConfiguration;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.EnableAspectJAutoProxy;
import org.springframework.scheduling.annotation.EnableAsync;
import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor;
import java.util.concurrent.Executor;
import java.util.concurrent.ThreadPoolExecutor;
/**
* 程序注解配置
......@@ -14,4 +19,15 @@ import org.springframework.scheduling.annotation.EnableAsync;
@EnableAsync(proxyTargetClass = true)
public class ApplicationConfig {
@Bean("smsTaskExecutor")
public Executor smsTaskExecutor() {
ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();
executor.setCorePoolSize(5);
executor.setMaxPoolSize(10);
executor.setQueueCapacity(100);
executor.setThreadNamePrefix("sms-sender-");
executor.setRejectedExecutionHandler(new ThreadPoolExecutor.CallerRunsPolicy());
executor.initialize();
return executor;
}
}
package org.dromara.common.excel.convert;
import cn.hutool.core.annotation.AnnotationUtil;
import cn.hutool.core.convert.Convert;
import cn.hutool.core.util.ObjectUtil;
import com.alibaba.excel.converters.Converter;
import com.alibaba.excel.enums.CellDataTypeEnum;
import com.alibaba.excel.metadata.GlobalConfiguration;
import com.alibaba.excel.metadata.data.ReadCellData;
import com.alibaba.excel.metadata.data.WriteCellData;
import com.alibaba.excel.metadata.property.ExcelContentProperty;
import org.dromara.common.excel.annotation.ExcelDictFormat;
import org.dromara.common.core.service.DictService;
import org.dromara.common.core.utils.SpringUtils;
import org.dromara.common.core.utils.StringUtils;
import org.dromara.common.excel.utils.ExcelUtil;
import lombok.extern.slf4j.Slf4j;
import java.lang.reflect.Field;
import java.util.ArrayList;
import java.util.List;
/**
* 多选字典格式化转换处理
*
* @author your-name
*/
@Slf4j
public class MultiDictConvert implements Converter<Object> {
@Override
public Class<Object> supportJavaTypeKey() {
return Object.class;
}
@Override
public CellDataTypeEnum supportExcelTypeKey() {
return null;
}
@Override
public Object convertToJavaData(ReadCellData<?> cellData, ExcelContentProperty contentProperty, GlobalConfiguration globalConfiguration) {
ExcelDictFormat anno = getAnnotation(contentProperty.getField());
String type = anno.dictType();
String label = cellData.getStringValue();
String value;
if (StringUtils.isBlank(label)) {
return null;
}
// 处理多选值
if (label.contains(anno.separator())) {
String[] labels = label.split(anno.separator());
List<String> values = new ArrayList<>();
for (String l : labels) {
String v;
if (StringUtils.isBlank(type)) {
v = ExcelUtil.reverseByExp(l.trim(), anno.readConverterExp(), anno.separator());
} else {
v = SpringUtils.getBean(DictService.class).getDictValue(type, l.trim(), anno.separator());
}
if (StringUtils.isNotEmpty(v)) {
values.add(v);
}
}
value = String.join(anno.separator(), values);
} else {
// 单值处理
if (StringUtils.isBlank(type)) {
value = ExcelUtil.reverseByExp(label, anno.readConverterExp(), anno.separator());
} else {
value = SpringUtils.getBean(DictService.class).getDictValue(type, label, anno.separator());
}
}
return Convert.convert(contentProperty.getField().getType(), value);
}
@Override
public WriteCellData<String> convertToExcelData(Object object, ExcelContentProperty contentProperty, GlobalConfiguration globalConfiguration) {
if (ObjectUtil.isNull(object)) {
return new WriteCellData<>("");
}
ExcelDictFormat anno = getAnnotation(contentProperty.getField());
String type = anno.dictType();
String value = Convert.toStr(object);
String label;
if (StringUtils.isBlank(value)) {
return new WriteCellData<>("");
}
// 处理多选值
if (value.contains(anno.separator())) {
String[] values = value.split(anno.separator());
List<String> labels = new ArrayList<>();
for (String v : values) {
String l;
if (StringUtils.isBlank(type)) {
l = ExcelUtil.convertByExp(v.trim(), anno.readConverterExp(), anno.separator());
} else {
l = SpringUtils.getBean(DictService.class).getDictLabel(type, v.trim(), anno.separator());
}
if (StringUtils.isNotEmpty(l)) {
labels.add(l);
}
}
label = String.join(anno.separator(), labels);
} else {
// 单值处理
if (StringUtils.isBlank(type)) {
label = ExcelUtil.convertByExp(value, anno.readConverterExp(), anno.separator());
} else {
label = SpringUtils.getBean(DictService.class).getDictLabel(type, value, anno.separator());
}
}
return new WriteCellData<>(label);
}
private ExcelDictFormat getAnnotation(Field field) {
return AnnotationUtil.getAnnotation(field, ExcelDictFormat.class);
}
}
......@@ -58,36 +58,26 @@
<groupId>com.tongweb.springboot</groupId>
<artifactId>tongweb-spring-boot-starter-3.x</artifactId>
<version>${tw.starter.version}</version>
<scope>system</scope>
<systemPath>${basedir}/libs/tongweb-spring-boot-starter-3.x-7.0.E.6_P7.jar</systemPath>
</dependency>
<dependency>
<groupId>com.tongweb.springboot</groupId>
<artifactId>tongweb-spring-boot-websocket-3.x</artifactId>
<version>${tw.starter.version}</version>
<scope>system</scope>
<systemPath>${basedir}/libs/tongweb-spring-boot-websocket-3.x-7.0.E.6_P7.jar</systemPath>
</dependency>
<dependency>
<groupId>com.tongweb</groupId>
<artifactId>tongweb-lic-sdk</artifactId>
<version>4.5.0.0</version>
<scope>system</scope>
<systemPath>${basedir}/libs/tongweb-lic-sdk-4.5.0.0.jar</systemPath>
</dependency>
<dependency>
<groupId>com.tongweb</groupId>
<artifactId>tongweb-embed-core</artifactId>
<version>${tw.starter.version}</version>
<scope>system</scope>
<systemPath>${basedir}/libs/tongweb-embed-core-3.x-7.0.E.6_P7.jar</systemPath>
</dependency>
<dependency>
<groupId>com.tongweb</groupId>
<artifactId>tongweb-embed-websocket</artifactId>
<version>${tw.starter.version}</version>
<scope>system</scope>
<systemPath>${basedir}/libs/tongweb-embed-websocket-3.x-7.0.E.6_P7.jar</systemPath>
</dependency>
<!-- SpringBoot Actuator -->
<dependency>
......
......@@ -21,6 +21,7 @@ import org.springframework.transaction.annotation.Transactional;
import java.io.IOException;
import java.util.List;
import java.util.UUID;
/**
* 文件请求处理
......@@ -38,7 +39,6 @@ public class RemoteFileServiceImpl implements RemoteFileService {
/**
* 文件上传请求
*/
@Transactional(rollbackFor = Exception.class)
@Override
public RemoteFile upload(String name, String originalFilename, String contentType, byte[] file) throws ServiceException {
try {
......@@ -61,7 +61,8 @@ public class RemoteFileServiceImpl implements RemoteFileService {
sysFile.setFileSuffix(suffix);
return sysFile;
} catch (Exception e) {
log.error("上传文件失败", e);
log.error("上传文件失败");
e.printStackTrace();
throw new ServiceException("上传文件失败");
}
}
......
......@@ -56,6 +56,7 @@ public class SysProfileController extends BaseController {
* 个人信息
*/
@GetMapping
@DecryptOperation
public R<ProfileVo> profile() {
SysUserVo user = userService.selectUserById(LoginHelper.getUserId());
ProfileVo profileVo = new ProfileVo();
......@@ -68,6 +69,7 @@ public class SysProfileController extends BaseController {
/**
* 修改用户信息
*/
@DecryptOperation
@RepeatSubmit
@Log(title = "个人信息", businessType = BusinessType.UPDATE)
@PutMapping
......@@ -125,7 +127,6 @@ public class SysProfileController extends BaseController {
* @param avatarfile 用户头像
*/
@RepeatSubmit
@GlobalTransactional(rollbackFor = Exception.class)
@Log(title = "用户头像", businessType = BusinessType.UPDATE)
@PostMapping(value = "/avatar", consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
public R<AvatarVo> avatar(@RequestPart("avatarfile") MultipartFile avatarfile) throws IOException {
......
......@@ -5,12 +5,10 @@ import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import org.dromara.common.sensitive.annotation.Sensitive;
import org.dromara.common.sensitive.core.SensitiveStrategy;
import org.dromara.system.zwy.annotation.EncryptSensitive;
import org.dromara.common.excel.annotation.ExcelDictFormat;
import org.dromara.common.excel.convert.ExcelDictConvert;
import org.dromara.system.domain.SysDept;
import org.dromara.system.zwy.annotation.EncryptSensitive;
import java.io.Serial;
import java.io.Serializable;
......
......@@ -225,19 +225,14 @@ public class RemoteUserServiceImpl implements RemoteUserService {
public Boolean expertRegisterUserInfo(List<RemoteUserBo> remoteUserBo,String tenantId) throws UserException, ServiceException {
// 将 RemoteUserBo 转换为 SysUserBo 列表
List<SysUserBo> sysUserBoList = BeanUtil.copyToList(remoteUserBo, SysUserBo.class);
// 获取所有用户名
List<String> userNameList = sysUserBoList.stream()
.map(SysUserBo::getUserName)
.collect(Collectors.toList());
// 根据用户名列表查询已存在的用户
List<SysUser> existingSysUsers = userService.selectListByUserNames(userNameList);
// 提取已存在用户的租户 ID
Set<String> existingTenantIds = existingSysUsers.stream()
.map(SysUser::getTenantId)
.collect(Collectors.toSet());
// 过滤掉租户 ID 已存在的用户
List<String> names = sysUserBoList.stream().map(item -> {
String name = userService.selectByIdcardAndNickName(item.getIdCard(), item.getNickName());
return name;
}).collect(Collectors.toList());
// 过滤掉已存在的用户
sysUserBoList = sysUserBoList.stream()
.filter(sysUser -> !existingTenantIds.contains(sysUser.getTenantId()))
.filter(sysUser -> !names.contains(sysUser.getNickName()))
.collect(Collectors.toList());
// 如果过滤后的列表为空,则直接返回 true
if (CollectionUtil.isEmpty(sysUserBoList)) {
......@@ -247,6 +242,14 @@ public class RemoteUserServiceImpl implements RemoteUserService {
return userService.registerExpertUser(sysUserBoList,tenantId);
}
@Override
public Boolean expertRegisterUserInfoForSpj(List<RemoteUserBo> remoteUserBo, String tenantId) throws UserException, ServiceException {
List<SysUserBo> sysUserBoList = BeanUtil.copyToList(remoteUserBo, SysUserBo.class);
// 注册新用户
return userService.registerExpertUser(sysUserBoList,tenantId);
}
/**
* 通过用户ID查询用户账户
*
......
......@@ -76,10 +76,6 @@ public interface SysUserMapper extends BaseMapperPlus<SysUser, SysUserVo> {
long countUserById(Long userId);
@Override
@DataPermission({
@DataColumn(key = "deptName", value = "dept_id"),
@DataColumn(key = "userName", value = "user_id")
})
int update(@Param(Constants.ENTITY) SysUser user, @Param(Constants.WRAPPER) Wrapper<SysUser> updateWrapper);
@Override
......@@ -105,4 +101,6 @@ public interface SysUserMapper extends BaseMapperPlus<SysUser, SysUserVo> {
int updatePasswordById(@Param("userId") Long userId, @Param("password") String password);
void updateHmacById(SysUser update);
String selectByIdcardAndNickName(String idCard, String nickName);
}
package org.dromara.system.service;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import org.dromara.common.mybatis.core.page.PageQuery;
import org.dromara.common.mybatis.core.page.TableDataInfo;
import org.dromara.system.domain.SysUser;
......@@ -312,4 +314,6 @@ public interface ISysUserService {
Object selectSysUserById(Long id);
void updateUserHmac(SysUser update);
String selectByIdcardAndNickName(String idCard, String nickName);
}
......@@ -557,6 +557,12 @@ public class SysUserServiceImpl implements ISysUserService {
baseMapper.updateHmacById(update);
}
@Override
public String selectByIdcardAndNickName(String idCard, String nickName) {
return baseMapper.selectByIdcardAndNickName(idCard, nickName);
}
/**
* 用户授权角色
*
......@@ -608,8 +614,7 @@ public class SysUserServiceImpl implements ISysUserService {
.set(SysUser::getEmail, user.getEmail())
.set(SysUser::getSex, user.getSex())
.eq(SysUser::getUserId, user.getUserId())
.set(SysUser::getPasswordUpdateTime, user.getPasswordUpdateTime())
.set(ObjectUtil.isNotNull(user.getBankName()), SysUser::getBankName, user.getBankName())
.set(ObjectUtil.isNotNull(user.getPasswordUpdateTime()), SysUser::getPasswordUpdateTime, user.getPasswordUpdateTime()) .set(ObjectUtil.isNotNull(user.getBankName()), SysUser::getBankName, user.getBankName())
.set(ObjectUtil.isNotNull(user.getBankCode()), SysUser::getBankCode, user.getBankCode())
.set(ObjectUtil.isNotNull(user.getBankAddr()), SysUser::getBankAddr, user.getBankAddr())
);
......
......@@ -101,6 +101,9 @@
AND del_flag = '0'
</select>
<select id="selectByIdcardAndNickName" resultType="java.lang.String">
select nick_name from sys_user where user_name=#{idCard} and nick_name=#{nickName}
</select>
<update id="updatePasswordById">
UPDATE sys_user
......
......@@ -112,9 +112,12 @@
<groupId>cn.bubi.sdk</groupId>
<artifactId>bubichain-sdk</artifactId>
<version>4.0.4</version>
<scope>system</scope>
<systemPath>${basedir}/libs/bubichain-sdk-4.0.4.jar</systemPath>
</dependency>
<dependency>
<groupId>cn.bubi.sdk</groupId>
<artifactId>bubichain-sdk</artifactId>
<version>4.0.4</version>
</dependency>
</dependencies>
<build>
......
......@@ -3,6 +3,7 @@ package org.dromara.zjk.annualInspection.annualInspectionAudit.domain;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import com.baomidou.mybatisplus.annotation.TableField;
import lombok.EqualsAndHashCode;
import org.dromara.common.tenant.core.TenantEntity;
import org.dromara.zjk.annotation.PropertyMsg;
......@@ -86,5 +87,9 @@ public class ZjkAnnualInspection extends TenantEntity {
private String reason;
private String hmac;
/**
* 更新人(年检审核人)
*/
@TableField(exist = false)
private String updateByStr;
}
......@@ -91,4 +91,6 @@ public class ZjkAnnualInspectionBo extends BaseEntity {
@JsonFormat(pattern = "yyyy-MM-dd",timezone="GMT+8")
@DateTimeFormat(pattern = "yyyy-MM-dd")
private Date endAuditTime;
private String start;
private String end;
}
......@@ -19,4 +19,5 @@ public interface ZjkAnnualInspectionMapper extends BaseMapperPlus<ZjkAnnualInspe
void batchAnnualInspection(ZjkAnnualInspectionBo zjkAnnualInspectionBo);
String selectApprovalByUserId(Long updateBy);
}
......@@ -5,6 +5,7 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import lombok.RequiredArgsConstructor;
import org.dromara.common.satoken.utils.LoginHelper;
import lombok.extern.slf4j.Slf4j;
import org.dromara.common.core.exception.ServiceException;
import org.dromara.common.core.utils.DateUtils;
......@@ -28,6 +29,7 @@ import org.dromara.zjk.utils.IdCardUtils;
import org.dromara.zjk.utils.NumberGenerator;
import org.dromara.zjk.zwy.client.HmacClient;
import org.dromara.zjk.zwy.utils.ObjectHashGenerator;
import org.dromara.zjk.zwy.utils.StringCryptoUtil;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
......@@ -55,7 +57,8 @@ public class ZjkAnnualInspectionServiceImpl implements IZjkAnnualInspectionServi
private IZjkExpertService zjkExpertService;
private final HmacClient hmacClient;
@Autowired
private StringCryptoUtil stringCryptoUtil;
/**
* 查询年检管理
*
......@@ -76,6 +79,16 @@ public class ZjkAnnualInspectionServiceImpl implements IZjkAnnualInspectionServi
*/
@Override
public TableDataInfo<ZjkAnnualInspectionVo> queryPageList(ZjkAnnualInspectionBo bo, PageQuery pageQuery) {
if(StringUtils.isNotBlank(bo.getContact())){
String phone = stringCryptoUtil.encryptField(bo.getContact());
bo.setContact(phone);
}
Map<String, Object> params = bo.getParams();
if(params!=null){
bo.setStart((String) params.get("beginAuditTime"));
bo.setEnd((String) params.get("endAuditTime"));
}
bo.setAnnualInspectionType(AnnualInspectionTypeEnum.MANUAL_ANNUAL_INSPECTION.getCode());
Page<ZjkAnnualInspectionVo> result = zjkAnnualInspectionMapper.queryAnnualInspection(pageQuery.build(), bo);
return TableDataInfo.build(result);
}
......@@ -193,6 +206,8 @@ public class ZjkAnnualInspectionServiceImpl implements IZjkAnnualInspectionServi
} catch (Exception e) {
log.error("年检HMAC生成失败 expertId:{}", zjkExpert.getExpertId(), e);
}
zjkAnnualInspectionBo.setUpdateBy(LoginHelper.getUserId());
zjkAnnualInspectionBo.setUpdateTime(new Date());
zjkAnnualInspectionMapper.batchAnnualInspection(zjkAnnualInspectionBo);
}
......
package org.dromara.zjk.config;
import com.alibaba.fastjson.JSON;
import jakarta.servlet.http.HttpServletRequest;
import jakarta.servlet.http.HttpServletResponse;
import org.apache.dubbo.config.annotation.DubboReference;
import org.dromara.common.core.constant.HttpStatus;
import org.dromara.common.core.domain.R;
import org.dromara.common.core.utils.StringUtils;
import org.dromara.system.api.RemoteConfigService;
import org.dromara.zjk.utils.ApiThreadLocal;
import org.springframework.stereotype.Component;
import org.springframework.web.servlet.HandlerInterceptor;
/**
* @author : yanguohua
* @version : 1.0
* @date : 2025/8/26 15:19
*/
@Component
public class ApiAuthInterceptor implements HandlerInterceptor {
@DubboReference
private RemoteConfigService remoteConfigService;
private static final String DEFAULT_SECRET_KEY = "k6psy7kafT%UaPd2";
@Override
public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler) throws Exception {
// 设置响应的字符编码为 UTF-8
response.setCharacterEncoding("UTF-8");
response.setContentType("application/json;charset=UTF-8");
String authorizationCode = request.getHeader("Authorization");
// 获取密钥配置
String secretKey = remoteConfigService.selectConfigByKey("api.secret.key");
// 验证授权码是否为空
if (StringUtils.isEmpty(authorizationCode)) {
response.setStatus(HttpStatus.UNAUTHORIZED);
response.getWriter().write(JSON.toJSONString(R.fail("授权码为空,禁止访问")));
return false;
}
// 验证授权码是否匹配
if (!authorizationCode.equals(secretKey)) {
response.setStatus(HttpStatus.FORBIDDEN);
response.getWriter().write(JSON.toJSONString(R.fail("授权码错误,禁止访问")));
return false;
}
ApiThreadLocal.putAk(authorizationCode);
return true;
}
}
package org.dromara.zjk.config;
import cn.bubi.SDK;
import cn.bubi.common.Tools;
import cn.bubi.model.request.*;
import cn.bubi.model.request.operation.AccountSetMetadataOperation;
import cn.bubi.model.request.operation.BaseOperation;
......@@ -9,6 +8,7 @@ import cn.bubi.model.response.*;
import cn.bubi.model.response.result.data.Signature;
import cn.bubi.model.response.result.data.TransactionHistory;
import lombok.extern.slf4j.Slf4j;
import org.springframework.scheduling.annotation.Async;
import org.springframework.stereotype.Component;
import javax.annotation.Resource;
......@@ -20,43 +20,44 @@ public class OnChainUtils {
@Resource
private YsdpaasConfig ysdpaasConfig;
// 在 OnChainUtils 中添加异步方法
@Async
public void toChainAsync(String data, Long reviewId) {
toChain(data, reviewId);
}
// private static String address = "adxSqD9EdNMNYkfssD28YmSmgE1NLdm18Uhi9";
// private static String privateKey = "privbynqzw8xmhim7LuwsLbkr4GVzkwn6CasJdbYEhVbFgFEcTWJ9Khq";
public void toChain(String data, Long reviewId) {
sdk = SDK.getInstance(ysdpaasConfig.getOnchainUrl());
Long nonce = getAccountNonce();
String key = "expert_cq_" + reviewId;
//String value = "{\"Plaintext\":{},\"Privacy\":{\"userId\":\"\",\"loginName\":\"\",\"phone\":\"\",\"userName\":\"\",\"source\":\"\",\"password\":\"\",\"userType\":\"\",\"isRegisterd\":\"\",\"caHash\":\"\",\"status\":\"\",\"updateTime\":\"\",\"company\":\"\"}}";
BaseOperation[] operations = buildOperations(ysdpaasConfig.getOnchainAddress(), key, data);
long startTime = System.currentTimeMillis();
try {
log.info("开始上链操作,reviewId: {}", reviewId);
sdk = SDK.getInstance(ysdpaasConfig.getOnchainUrl());
Long nonce = getAccountNonce();
String key = "expert_cq_" + reviewId;
BaseOperation[] operations = buildOperations(ysdpaasConfig.getOnchainAddress(), key, data);
String tranBlob = seralizeTransaction(nonce, operations);
String tranBlob = seralizeTransaction(nonce, operations);
Signature[] signatures = signTransaction(tranBlob);
Signature[] signatures = signTransaction(tranBlob);
String txHash = submitTransaction(tranBlob, signatures);
System.out.println(txHash);
String txHash = submitTransaction(tranBlob, signatures);
long endTime = System.currentTimeMillis();
log.info("交易已提交,txHash: {}, reviewId: {}, 耗时: {} ms", txHash, reviewId, endTime - startTime);
long startTime = System.currentTimeMillis();
while (true) {
// 立即返回,不再等待区块链确认
// 移除了原来的轮询等待逻辑
} catch (Exception e) {
long endTime = System.currentTimeMillis();
if (endTime - startTime > 60000000) {
log.info("交易执行超时");
return;
}
TransactionHistory transactionHistory = checkTransactionStatus(txHash);
if (!Tools.isNULL(transactionHistory) && transactionHistory.getErrorCode() == 0) {
break;
}
try {
Thread.sleep(3000);
} catch (InterruptedException e) {
e.printStackTrace();
}
log.error("上链操作异常,reviewId: {}, 耗时: {} ms", reviewId, endTime - startTime, e);
}
log.info("交易结束");
log.info("上链请求已完成,reviewId: {}", reviewId);
}
public long getAccountNonce() {
long nonce = 0;
......
package org.dromara.zjk.config;
import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;
/**
* @author : yanguohua
* @version : 1.0
* @date : 2024/10/28 11:28
*/
@Data
@Configuration
@ConfigurationProperties(prefix = "syncuser")
public class SyncRemortUserConfig {
private String spjSyncUserUrl;
}
package org.dromara.zjk.config;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
/**
* 对外接口拦截器
*
* @author : yanguohua
* @version : 1.0
* @date : 2025/8/26 15:23
*/
@Configuration
public class ZjkApiWebMvcConfig implements WebMvcConfigurer {
@Autowired
private ApiAuthInterceptor apiAuthInterceptor;
@Override
public void addInterceptors(InterceptorRegistry registry) {
registry.addInterceptor(apiAuthInterceptor)
.addPathPatterns("/api/**"); // 拦截所有 /api 开头的请求
}
}
package org.dromara.zjk.controller;
import com.alibaba.fastjson.JSON;
import jakarta.validation.constraints.NotNull;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.apache.dubbo.config.annotation.DubboReference;
import org.dromara.common.core.domain.R;
import org.dromara.common.core.exception.ServiceException;
import org.dromara.common.core.utils.StringUtils;
import org.dromara.common.mybatis.core.page.PageQuery;
import org.dromara.common.mybatis.core.page.TableDataInfo;
import org.dromara.system.api.RemoteConfigService;
import org.dromara.zjk.domain.bo.ZjkExpertBo;
import org.dromara.zjk.domain.bo.ZjkProductBo;
import org.dromara.zjk.domain.vo.ProductPanoramaDetailVo;
import org.dromara.zjk.domain.vo.ZjkExpertVo;
import org.dromara.zjk.domain.vo.ZjkProductVo;
import org.dromara.zjk.service.IZjkExpertService;
import org.dromara.zjk.service.IZjkProductService;
import org.dromara.zjk.service.ZjkExpertMoneyInfoService;
import org.dromara.zjk.utils.ApiThreadLocal;
import org.dromara.zjk.utils.EncryptionUtil;
import org.dromara.zjk.zwy.annotation.DecryptOperation;
import org.dromara.zjk.zwy.utils.StringCryptoUtil;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.util.CollectionUtils;
import org.springframework.web.bind.annotation.*;
import java.util.List;
/**
* 专家库对外api接口
*/
@RestController
@RequiredArgsConstructor
@RequestMapping("/zjk")
@RequestMapping("/api")
@Slf4j
public class ApiController {
// 默认的密钥常量
private static final String DEFAULT_SECRET_KEY = "k6psy7kafT%UaPd2";
@DubboReference(timeout=5000)
@DubboReference(timeout = 5000)
private final RemoteConfigService remoteConfigService;
private final IZjkExpertService zjkExpertService;
@Autowired
private StringCryptoUtil stringCryptoUtil;
private final IZjkProductService zjkProductService;
private final ZjkExpertMoneyInfoService zjkExpertMoneyInfoService;
/**
* 专家库数据获取
* @param authorizationCode
* 专家库数据列表获取
*
* @return
*/
@PostMapping("/api/expert-data")
public R<String> getEncryptedExpertData(@RequestHeader("Authorization") String authorizationCode) {
@DecryptOperation
@GetMapping("/expertList")
public R<String> getExpertListData(ZjkExpertBo bo) {
try {
// 获取密钥配置
String secretKey = remoteConfigService.selectConfigByKey("api.secret.key");
if (StringUtils.isEmpty(secretKey)) {
secretKey = DEFAULT_SECRET_KEY;
PageQuery pageQuery = new PageQuery();
pageQuery.setPageNum(1);
pageQuery.setPageSize(2000);
if (StringUtils.isNotBlank(bo.getContact())) {
String phone = stringCryptoUtil.encryptField(bo.getContact());
bo.setContact(phone);
}
// 验证授权码是否为空
if (StringUtils.isEmpty(authorizationCode)) {
log.warn("Authorization code is missing.");
throw new ServiceException("授权码为空,禁止访问");
if (StringUtils.isNotBlank(bo.getIdCard())) {
String idcard = stringCryptoUtil.encryptField(bo.getIdCard());
bo.setIdCard(idcard);
}
// 验证授权码是否匹配
if (!authorizationCode.equals(secretKey)) {
log.warn("Invalid authorization code: {}", authorizationCode);
throw new ServiceException("授权码错误,禁止访问");
}
// 查询专家数据
List<ZjkExpertVo> zjkExpertVoList = zjkExpertService.exportList(new ZjkExpertBo());
if (zjkExpertVoList == null || zjkExpertVoList.isEmpty()) {
log.info("无可返回的数据");
TableDataInfo<ZjkExpertVo> zjkExpertVoTableDataInfo = zjkExpertService.expertList(bo, pageQuery);
List<ZjkExpertVo> rows = zjkExpertVoTableDataInfo.getRows();
if (CollectionUtils.isEmpty(rows)) {
return R.ok("无可返回的数据");
}
String data = JSON.toJSONString(zjkExpertVoList);
// 数据加密
String encryptedData = EncryptionUtil.encrypt(data, secretKey);
return R.ok("操作成功",encryptedData);
} catch (ServiceException e) {
log.error("Service exception occurred: {}", e.getMessage());
return R.fail(e.getMessage());
String ak = ApiThreadLocal.getAk();
String data = JSON.toJSONString(rows);
return R.ok("操作成功", data);
} catch (Exception e) {
log.error("Unexpected error occurred", e);
return R.fail("系统异常,请联系管理员");
}
}
/**
* 专家详情信息获取
*
* @return
*/
@DecryptOperation
@GetMapping("/expertInfo/{id}")
public R<String> getExpertInfo(@PathVariable Long id) {
ZjkExpertVo zjkExpertVo = zjkExpertService.queryById(id);
if (zjkExpertVo == null) {
return R.fail("数据不存在");
}
String data = JSON.toJSONString(zjkExpertVo);
return R.ok("操作成功", data);
}
/**
* 项目列表数据获取
*
* @return
*/
@DecryptOperation
@GetMapping("/productList")
public R<String> getProductList(ZjkProductBo bo) {
List<ZjkProductVo> rows = zjkProductService.queryListForApi(bo);
if (CollectionUtils.isEmpty(rows)) {
return R.ok("无可返回的数据");
}
String data = JSON.toJSONString(rows);
return R.ok("操作成功", data);
}
/**
* 项目基本细信息获取
*
* @return
*/
@DecryptOperation
@GetMapping("/productInfo/{id}")
public R<String> getProductInfo(@PathVariable Long id) {
ZjkProductVo vo = zjkProductService.queryById(id);
if (vo == null) {
return R.fail("数据不存在");
}
String data = JSON.toJSONString(vo);
return R.ok("操作成功", data);
}
/**
* 项目阶段全景细信息获取
*
* @return
*/
@DecryptOperation
@GetMapping("/productLife/{id}")
public R<String> getProductLife(@PathVariable Long id) {
List<ProductPanoramaDetailVo> vo = zjkProductService.getProductPanoramaDetailVoById(id);
if (vo.size() == 0) {
return R.fail("数据不存在");
}
String data = JSON.toJSONString(vo);
return R.ok("操作成功", data);
}
/**
* 获取项目某个阶段参评的专家信息
*
* @param productId
* @param reviewSn
* @return
*/
@DecryptOperation
@GetMapping("/stageExperts")
public R<String> getStageExperts(@NotNull(message = "项目不能为空")
Long productId, @NotNull(message = "阶段不能为空")
Integer reviewSn) {
List<ZjkExpertVo> res = zjkExpertService.getStageExperts(productId, reviewSn);
if (CollectionUtils.isEmpty(res)) {
return R.ok("无可返回的数据");
}
String data = JSON.toJSONString(res);
return R.ok("操作成功", data);
}
// 解密接口 (用于调试或者需要解密的地方)
@PostMapping("/api/decrypt")
@PostMapping("/decrypt")
public String decryptData(
@RequestHeader("Authorization") String authorizationCode,
@RequestBody String encryptedData) {
......@@ -102,4 +192,5 @@ public class ApiController {
}
}
}
......@@ -18,6 +18,7 @@ import org.dromara.common.mybatis.core.page.PageQuery;
import org.dromara.common.mybatis.core.page.TableDataInfo;
import org.dromara.common.web.core.BaseController;
import org.dromara.zjk.domain.bo.InoutCheckBo;
import org.dromara.zjk.domain.bo.ZjkProductBo;
import org.dromara.zjk.domain.vo.CheckSupportVo;
import org.dromara.zjk.domain.vo.InoutCheckVo;
import org.dromara.zjk.domain.vo.ProductPanoramaVo;
......@@ -120,12 +121,13 @@ public class InoutCheckController extends BaseController {
}, mode = SaMode.OR)
@GetMapping("/productList")
public TableDataInfo<ProductPanoramaVo> productPanorama(ProductPanoramaVo vo, PageQuery pageQuery) {
return zjkProductService.productPanorama(vo, pageQuery);
return zjkProductService.getProductList(vo, pageQuery);
}
/**
* 财务审计支持-查看
*/
@DecryptOperation
@SaCheckRole(value = {
TenantConstants.JG_ROLE_KEY
}, mode = SaMode.OR)
......
......@@ -44,7 +44,6 @@ public class LearningSuggestController extends BaseController {
* 查询学习园地-学习推荐列表
*/
@SaCheckRole(value = {
TenantConstants.JG_ROLE_KEY,
TenantConstants.EXPERT_ROLE_KEY
},mode = SaMode.OR)
......
......@@ -69,6 +69,7 @@ public class SmsUpController {
@PostMapping("/receive")
public String receiveUpSms(@RequestParam("deliver") String deliver) {
try {
log.info("接收到上行数据: {}", deliver);
String[] records = deliver.split(";");
List<SmsUpEventDto> dtoList = new ArrayList<>();
......
......@@ -57,7 +57,6 @@ public class ZjkApprovalProcessLogsController extends BaseController {
/**
* 导出审批流程记录列表
*/
@SaCheckPermission("traceManagement:approvalProcessLogs:export")
@Log(title = "审批流程记录", businessType = BusinessType.EXPORT)
@PostMapping("/export")
public void export(ZjkApprovalProcessLogsBo bo, HttpServletResponse response) {
......
......@@ -36,6 +36,8 @@ public class ZjkChartController extends BaseController {
public R<ChartBaseVO> getChartBase(Long userId) {
return zjkExpertChartService.getChartBase(userId);
}
@DecryptOperation
@GetMapping("/users")
public R<List<SimpleExpertDto>> getExperts() {
return zjkExpertChartService.getExperts();
......
......@@ -122,8 +122,8 @@ public class ZjkCreditUserController extends BaseController {
//专家信用详情
@GetMapping("/selectUserById")
public R<List<ZjkCreditRuleVo>> expertPointRanks(ZjkCreditBo creditId, PageQuery pageQuery) {
return zjkCreditUserService.selectUserById(creditId,pageQuery);
public TableDataInfo<ZjkCreditRuleVo> expertPointRanks(ZjkCreditBo dto, PageQuery pageQuery) {
return zjkCreditUserService.selectUserById(dto,pageQuery);
}
//黑名单
......
......@@ -58,7 +58,6 @@ public class ZjkDataChangesLogsController extends BaseController {
/**
* 导出业务数据变更记录列表
*/
@SaCheckPermission("dataChangesLogs:dataChangesLogs:export")
@Log(title = "业务数据变更记录", businessType = BusinessType.EXPORT)
@PostMapping("/export")
public void export(ZjkDataChangesLogsBo bo, HttpServletResponse response) {
......
......@@ -13,6 +13,7 @@ import org.dromara.common.core.utils.StringUtils;
import org.dromara.common.core.validate.AddGroup;
import org.dromara.common.core.validate.EditGroup;
import org.dromara.common.excel.core.DropDownOptions;
import org.dromara.common.excel.utils.ExcelUtil;
import org.dromara.common.idempotent.annotation.RepeatSubmit;
import org.dromara.common.log.annotation.Log;
......@@ -23,9 +24,12 @@ import org.dromara.common.mybatis.core.page.TableDataInfo;
import org.dromara.common.satoken.utils.LoginHelper;
import org.dromara.common.web.core.BaseController;
import org.dromara.zjk.domain.ExpertBaseInfo;
import org.dromara.zjk.domain.ZjkInvoice;
import org.dromara.zjk.domain.bo.ApprovalCommonBo;
import org.dromara.zjk.domain.bo.ZjkExpertBo;
import org.dromara.zjk.domain.vo.ExpertPerformWorkCountVO;
import org.dromara.zjk.domain.vo.SelectOptionVo;
import org.dromara.zjk.domain.vo.SyncUserReturnVO;
import org.dromara.zjk.domain.vo.ZjkExpertVo;
import org.dromara.zjk.enums.ResultTypeEnum;
import org.dromara.zjk.enums.ZjkExpertTypeEnum;
......@@ -39,6 +43,7 @@ import org.springframework.web.multipart.MultipartFile;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;
/**
* 专家库
......@@ -158,8 +163,8 @@ public class ZjkExpertController extends BaseController {
}, mode = SaMode.OR)
public void export(@ModelAttribute ZjkExpertBo bo, HttpServletResponse response) {
if (bo.getIsTemplate() == 0){
List<ZjkExpertVo> list = new ArrayList<>();
ExcelUtil.exportExcel(list, "专家库模板", ZjkExpertVo.class, response);
zjkExpertService.exportTml(response);
}else {
List<ZjkExpertVo> list = zjkExpertService.exportList(bo);
ExcelUtil.exportExcel(list, "专家库", ZjkExpertVo.class, response);
......@@ -179,13 +184,7 @@ public class ZjkExpertController extends BaseController {
TenantConstants.TENANT_ADMIN_ROLE_KEY
}, mode = SaMode.OR)
public R<Void> imports(@RequestPart("file") MultipartFile file) {
List<String> list = zjkExpertService.imports(file);
// 如果存在重复的身份证号则提示,剔除之后再次导入
if (!CollUtil.isEmpty(list)){
// 将身份证号列表转换为用逗号分隔的字符串
return R.fail("以下身份证号专家已经存在,请剔除后再次导入专家数据:" + String.join(", ", list));
}
return R.ok();
return zjkExpertService.imports(file);
}
/**
......@@ -218,7 +217,20 @@ public class ZjkExpertController extends BaseController {
public R<Void> save(@Validated(AddGroup.class) @RequestBody ZjkExpertBo bo) {
return toAjax(zjkExpertService.insertByBo(bo));
}
/**
* 专专家库-专家涉密修改
* @param bo
* @return
*/
@Log(title = "专家库-专家涉密修改", businessType = BusinessType.EXPERT_SYS,operatorType = OperatorType.BROWSER)
@RepeatSubmit()
@PostMapping("handleClassified")
@SaCheckRole(value = {
TenantConstants.JG_ROLE_KEY
}, mode = SaMode.OR)
public R<Void> handleClassified(@RequestBody ZjkExpertBo bo) {
return toAjax(zjkExpertService.handleClassified(bo));
}
/**
* 提交
*/
......@@ -481,9 +493,8 @@ public class ZjkExpertController extends BaseController {
TenantConstants.TENANT_ADMIN_ROLE_KEY
},mode = SaMode.OR)
@GetMapping("/api/fetchRemoteProfessors")
public R<Void> fetchRemoteProfessors() {
zjkExpertService.fetchRemoteProfessors();
return R.ok();
public R<SyncUserReturnVO> fetchRemoteProfessors() {
return R.ok( zjkExpertService.fetchRemoteProfessors());
}
......
......@@ -50,7 +50,7 @@ public class ZjkExpertMoneyInfoController extends BaseController {
TenantConstants.TENANT_ADMIN_ROLE_KEY,
TenantConstants.XM_ROLE_KEY,
}, mode = SaMode.OR)
public TableDataInfo<ZjkExpertMoneyInfoVO> page(ZjkExpertMoneyInfoBo bo, PageQuery query) {
public TableDataInfo<ZjkExpertMoneyInfo> page(ZjkExpertMoneyInfoBo bo, PageQuery query) {
return zjkExpertMoneyInfoService.queryPageList(bo, query);
}
......@@ -197,15 +197,24 @@ public class ZjkExpertMoneyInfoController extends BaseController {
* 通过项目id和阶段获取参评专家列表
* @param productId
* @param reviewSn
* @param toSettle 1:新增结算单带出的专家
* @return
*/
@DecryptOperation
@SaCheckRole(value = {
TenantConstants.JG_ROLE_KEY
}, mode = SaMode.OR)
@GetMapping("/expertList")
public R<List<ZjkExpertVo>> getExpertList(@NotNull(message = "项目不能为空")
Long productId, @NotNull(message = "阶段不能为空")
Integer reviewSn) {
return R.ok(zjkExpertMoneyInfoService.getExpertList(productId, reviewSn));
Integer reviewSn,String toSettle) {
if(toSettle!=null){
return R.ok(zjkExpertMoneyInfoService.getExpertListForSettle(productId, reviewSn));
}else{
//发票管理的人员带出
return R.ok(zjkExpertMoneyInfoService.getExpertList(productId, reviewSn));
}
}
}
......@@ -139,8 +139,7 @@ public class ZjkInvoiceController extends BaseController {
@Log(title = "发票", businessType = BusinessType.OTHER)
@PostMapping("/downloadExcel")
public void downloadExcel(HttpServletResponse response) {
List<ZjkInvoiceVo> list = new ArrayList<>();
ExcelUtil.exportExcel(list, "模板", ZjkInvoiceVo.class, response);
zjkInvoiceService.downloadExcelTem(response);
}
......@@ -149,15 +148,13 @@ public class ZjkInvoiceController extends BaseController {
* @param file
* @return
*/
@EncryptOperation
@Log(title = "发票信息导入", businessType = BusinessType.IMPORT)
@PostMapping("/imports")
@SaCheckRole(value = {
TenantConstants.JG_ROLE_KEY,
}, mode = SaMode.OR)
public R<Void> imports(@RequestPart("file") MultipartFile file) {
zjkInvoiceService.imports(file);
return R.ok();
return zjkInvoiceService.imports(file);
}
......
......@@ -43,7 +43,7 @@ public class ZjkLeaveController extends BaseController {
private final IZjkLeaveRuleService zjkLeaveRuleService;
@InitBinder //解决前段传过来时间的字符串解析成时间报错问题
public void initBinder(WebDataBinder webDataBinder){
webDataBinder.registerCustomEditor(Date.class,new CustomDateEditor(new SimpleDateFormat("yyyy-MM-dd"),true));
webDataBinder.registerCustomEditor(Date.class,new CustomDateEditor(new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"),true));
}
@GetMapping("/pros")
......
......@@ -56,7 +56,7 @@ public class ZjkPointController extends BaseController {
private RemoteUserService remoteUserService;
@InitBinder //解决前段传过来时间的字符串解析成时间报错问题
public void initBinder(WebDataBinder webDataBinder){
webDataBinder.registerCustomEditor(Date.class,new CustomDateEditor(new SimpleDateFormat("yyyy-MM-dd"),true));
webDataBinder.registerCustomEditor(Date.class,new CustomDateEditor(new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"),true));
}
/**
* 查询列表-积分规则定义
......@@ -71,7 +71,7 @@ public class ZjkPointController extends BaseController {
},mode = SaMode.OR)
public R<List<ZjkPointRule>> pointRule(PointReqDto dto) {
QueryWrapper<ZjkPointRule> wq = new QueryWrapper<>();
wq.lambda().eq(!StringUtils.isEmpty(dto.getStartFlag()), ZjkPointRule::getStatus, dto.getStartFlag())
wq.lambda().eq(!StringUtils.isEmpty(dto.getStatus()), ZjkPointRule::getStatus, dto.getStatus())
.like(!StringUtils.isEmpty(dto.getRuleName()), ZjkPointRule::getRuleName, dto.getRuleName())
.between(dto.getStartDate() != null && dto.getEndDate() != null, ZjkPointRule::getCreateTime,
dto.getStartDate(), dto.getEndDate());
......@@ -90,8 +90,8 @@ public class ZjkPointController extends BaseController {
},mode = SaMode.OR)
public R<List<ZjkPointRewardVO>> rewardList(PointReqDto dto) {
QueryWrapper<ZjkPointReward> wq = new QueryWrapper<>();
wq.lambda().eq(!StringUtils.isEmpty(dto.getStartFlag()), ZjkPointReward::getStatus, dto.getStartFlag())
.like(!StringUtils.isEmpty(dto.getRuleName()), ZjkPointReward::getRewardName, dto.getRuleName())
wq.lambda().eq(!StringUtils.isEmpty(dto.getStatus()), ZjkPointReward::getStatus, dto.getStatus())
.like(!StringUtils.isEmpty(dto.getRewardName()), ZjkPointReward::getRewardName, dto.getRewardName())
.between(dto.getStartDate() != null && dto.getEndDate() != null, ZjkPointReward::getCreateTime, dto.getStartDate(), dto.getEndDate());
List<ZjkPointReward> list = zjkPointRewardService.list(wq);
List<ZjkPointRewardVO> zjkPointRewardVOS = BeanUtil.copyToList(list, ZjkPointRewardVO.class);
......
......@@ -85,7 +85,7 @@ public class ZjkProductController extends BaseController {
/**
* 导出项目管理列表
*/
// @DecryptOperation
@DecryptOperation
@SaCheckRole(value={
TenantConstants.JG_ROLE_KEY,
TenantConstants.SUPER_ADMIN_ROLE_KEY,
......
......@@ -67,9 +67,8 @@ public class ZjkProductSummarizeController extends BaseController {
@SaCheckPermission("zjk:productSummarize:export")
public void export(ZjkProductSummarizeBo bo, HttpServletResponse response) {
List<ZjkProductSummarizeVo> list = zjkProductSummarizeService.queryList(bo);
List<ZjkProductSummarizeExportVo> zjkProductSummarizeExportVos = BeanUtil.copyToList(list, ZjkProductSummarizeExportVo.class);
ExcelUtil.exportExcel(zjkProductSummarizeExportVos, "项目总结", ZjkProductSummarizeExportVo.class, response);
ExcelUtil.exportExcel(list, "项目总结", ZjkProductSummarizeVo.class, response);
}
/**
* 导出项目总结列表
......
......@@ -8,6 +8,7 @@ import jakarta.servlet.http.HttpServletResponse;
import jakarta.validation.constraints.NotEmpty;
import jakarta.validation.constraints.NotNull;
import lombok.RequiredArgsConstructor;
import org.apache.commons.math3.stat.descriptive.summary.Product;
import org.dromara.common.core.constant.TenantConstants;
import org.dromara.common.core.domain.R;
import org.dromara.common.core.validate.AddGroup;
......@@ -19,6 +20,7 @@ import org.dromara.common.log.enums.BusinessType;
import org.dromara.common.mybatis.core.page.PageQuery;
import org.dromara.common.mybatis.core.page.TableDataInfo;
import org.dromara.common.web.core.BaseController;
import org.dromara.zjk.domain.bo.ZjkProductBo;
import org.dromara.zjk.domain.bo.ZjkReviewPhaseBo;
import org.dromara.zjk.domain.bo.ZjkReviewProductBo;
import org.dromara.zjk.domain.vo.ZjkReviewExportVo;
......@@ -125,14 +127,22 @@ public class ZjkReviewPhaseController extends BaseController {
return zjkReviewPhaseService.reviewProductList(bo, pageQuery);
}
/**
* 发票/结算 获取项目列表
* @return
*/
@GetMapping("/invoice/productList")
public R<List<ZjkProductBo>> invoiceProductList() {
return zjkReviewPhaseService.invoiceProductList();
}
@DecryptOperation
@SaCheckPermission("zjk:reviewproduct:export")
@PostMapping("/review/export")
public void reviewExport(ZjkReviewProductBo bo, HttpServletResponse response) {
List<ZjkReviewProductVo> zjkReviewProductVos = zjkReviewPhaseService.reviewExport(bo);
List<ZjkReviewExportVo> zjkReviewExportVo = BeanUtil.copyToList(zjkReviewProductVos, ZjkReviewExportVo.class);
ExcelUtil.exportExcel(zjkReviewExportVo, "评审项目", ZjkReviewExportVo.class, response);
//List<ZjkReviewExportVo> zjkReviewExportVo = BeanUtil.copyToList(zjkReviewProductVos, ZjkReviewExportVo.class);
ExcelUtil.exportExcel(zjkReviewProductVos, "评审项目", ZjkReviewProductVo.class, response);
}
......
......@@ -35,7 +35,11 @@ public class ZjkApprovalProcessLogs extends TenantEntity {
* 操作内容
*/
private String actionContent;
/**
* 操作人
*/
@TableField(exist = false)
private String createByStr;
/**
* 审批意见
*/
......
......@@ -360,5 +360,14 @@ public class ZjkExpert extends BaseEntity {
private String unitTypeDescribe;
private String hmac;
/**
* 活动范围
*/
private String scopeOfActivity;
/**
* 是否涉密
*/
private Integer isClassified;
}
......@@ -6,11 +6,18 @@ import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.baomidou.mybatisplus.annotation.TableField;
import com.alibaba.excel.annotation.ExcelIgnore;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.dromara.common.excel.annotation.ExcelDictFormat;
import org.dromara.common.excel.convert.ExcelDictConvert;
import org.dromara.common.mybatis.core.domain.BaseEntity;
import org.dromara.zjk.annotation.PropertyMsg;
import org.dromara.zjk.zwy.annotation.EncryptSensitive;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import java.io.Serial;
import java.math.BigDecimal;
......@@ -25,6 +32,7 @@ import java.util.Date;
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("zjk_invoice")
@ExcelIgnoreUnannotated
public class ZjkInvoice extends BaseEntity {
@Serial
......@@ -35,21 +43,24 @@ public class ZjkInvoice extends BaseEntity {
*/
@PropertyMsg(propertyName = "id")
@TableId(type = IdType.ASSIGN_ID)
@ExcelIgnore // 忽略该字段导出
private Long id;
/**
* 发票号码
*/
@PropertyMsg(propertyName = "invoice_number")
@ExcelProperty(value = "发票号码")
private Long invoiceNumber;
@ExcelProperty(value = "*发票号码")
@NotBlank(message = "发票号码不能为空")
private String invoiceNumber;
/**
* 发票金额
*/
@PropertyMsg(propertyName = "invoice_money")
@ExcelProperty(value = "发票金额")
@ExcelProperty(value = "*发票金额")
@JsonFormat(shape = JsonFormat.Shape.NUMBER)
@NotNull(message = "发票金额不能为空")
private BigDecimal invoiceMoney;
/**
......@@ -58,16 +69,44 @@ public class ZjkInvoice extends BaseEntity {
@PropertyMsg(propertyName = "start_date")
@JsonFormat(pattern = "yyyy-MM-dd")
@DateTimeFormat(value = "yyyy-MM-dd")
@ExcelProperty(value = "开票日期")
@ExcelProperty(value = "*开票日期")
@NotNull(message = "开票日期不能为空")
private Date startDate;
@TableField(exist = false)
@ExcelProperty(value = "*项目名称")
@NotBlank(message = "项目名称不能为空")
private String productName;
/**
* 项目阶段
*/
@PropertyMsg(propertyName = "review_sn")
@ExcelIgnore // 忽略该字段导出
private Integer reviewSn;
/**
* 项目阶段
*/
@ExcelProperty(value = "*项目阶段",converter = ExcelDictConvert.class)
@ExcelDictFormat(dictType = "item_stage")
@TableField(exist = false)
@NotBlank(message = "项目阶段不能为空")
private String reviewSnStr;
/**
* 专家名称
*/
@PropertyMsg(propertyName = "expert_name")
@ExcelProperty(value = "专家名称")
@ExcelProperty(value = "*专家名称")
@NotBlank(message = "专家名称不能为空")
private String expertName;
/**
* 专家身份证号
*/
@PropertyMsg(propertyName = "expert_id_number")
@ExcelProperty(value = "*专家身份证号")
@NotBlank(message = "专家身份证号不能为空")
private String expertIdNumber;
/**
* 联系电话
*/
......@@ -76,12 +115,6 @@ public class ZjkInvoice extends BaseEntity {
@ExcelProperty(value = "联系电话")
private String expertPhone;
/**
* 专家身份证号
*/
@PropertyMsg(propertyName = "expert_id_number")
@ExcelProperty(value = "专家身份证号")
private String expertIdNumber;
/**
* 职称等级
......@@ -94,62 +127,31 @@ public class ZjkInvoice extends BaseEntity {
* 电子发票附件相关 ,存储oss的id
*/
@PropertyMsg(propertyName = "invoice_attached")
@ExcelIgnore // 忽略该字段导出
private String invoiceAttached;
/**
* 创建人
*/
@PropertyMsg(propertyName = "create_by")
private Long createBy;
/**
* 创建时间
*/
@PropertyMsg(propertyName = "create_time")
private Date createTime;
/**
* 修改人
*/
@PropertyMsg(propertyName = "update_by")
private Long updateBy;
/**
* 创建时间
*/
@PropertyMsg(propertyName = "update_time")
private Date updateTime;
/**
* 创建部门
*/
@PropertyMsg(propertyName = "create_dept")
private Long createDept;
/**
* 租户编码
*/
@PropertyMsg(propertyName = "tenant_id")
private String tenantId;
/**
* 项目id
*/
@PropertyMsg(propertyName = "product_id")
@ExcelIgnore // 忽略该字段导出
private Long productId;
/**
* 项目阶段
*/
@PropertyMsg(propertyName = "reviewSn")
private Integer reviewSn;
/**
* 结算单id
*/
@PropertyMsg(propertyName = "settle_id")
@ExcelIgnore // 忽略该字段导出
private Long settleId;
@TableField(exist = false)
@ExcelProperty(value = "*结算单号")
@NotBlank(message = "结算单号不能为空")
private String settleNo;
@ExcelIgnore // 忽略该字段导出
private String hmac;
/**
* 审核状态1:已审核
*/
@ExcelIgnore // 忽略该字段导出
private Integer checkStatus;
}
package org.dromara.zjk.domain.bo;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.dromara.common.mybatis.core.domain.BaseEntity;
import org.dromara.zjk.domain.InoutCheck;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;
......@@ -32,11 +34,15 @@ public class InoutCheckBo extends BaseEntity {
/**
* 时间范围开始
*/
@JsonFormat(pattern = "yyyy-MM-dd",timezone="GMT+8")
@DateTimeFormat(pattern="yyyy-MM-dd")
private Date checkRangeStart;
/**
* 时间范围结束
*/
@JsonFormat(pattern = "yyyy-MM-dd",timezone="GMT+8")
@DateTimeFormat(pattern="yyyy-MM-dd")
private Date checkRangeEnd;
/**
......
package org.dromara.zjk.domain.bo;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.github.linpeilie.annotations.AutoMapper;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Pattern;
import jakarta.validation.constraints.Size;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.dromara.common.core.validate.AddGroup;
import org.dromara.common.excel.annotation.ExcelDictFormat;
import org.dromara.common.excel.convert.ExcelDictConvert;
import org.dromara.common.excel.convert.MultiDictConvert;
import org.dromara.common.mybatis.core.domain.BaseEntity;
import org.dromara.zjk.zwy.annotation.EncryptSensitive;
import org.dromara.zjk.annotation.PropertyMsg;
import org.dromara.zjk.domain.ZjkExpert;
import org.dromara.zjk.domain.ZjkExpertMajor;
......@@ -20,6 +22,7 @@ import org.dromara.zjk.domain.ZjkExpertProfessional;
import org.dromara.zjk.expert.expertAwards.domain.ZjkExpertAwards;
import org.dromara.zjk.expert.expertPaper.domain.ZjkExpertPaper;
import org.dromara.zjk.expert.expertPatent.domain.ZjkExpertPatent;
import org.dromara.zjk.zwy.annotation.EncryptSensitive;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;
......@@ -33,6 +36,7 @@ import java.util.List;
*/
@Data
@EqualsAndHashCode(callSuper = true)
@ExcelIgnoreUnannotated
@AutoMapper(target = ZjkExpert.class, reverseConvertGenerate = false)
public class ZjkExpertBo extends BaseEntity {
......@@ -44,8 +48,9 @@ public class ZjkExpertBo extends BaseEntity {
/**
* 姓名
*/
@ExcelProperty(value = "姓名")
@Size(max = 20, message = "推荐专家姓名长度不能超过20个字符",groups = { AddGroup.class})
@ExcelProperty(value = "*姓名")
@Size(max = 20, message = "推荐专家姓名长度不能超过20个字符", groups = {AddGroup.class})
@NotBlank(message = "姓名不能为空")
private String expertName;
/**
......@@ -53,20 +58,29 @@ public class ZjkExpertBo extends BaseEntity {
*/
@ExcelProperty(value = "性别", converter = ExcelDictConvert.class)
@ExcelDictFormat(dictType = "sys_user_sex")
@NotNull(message = "性别不能为空")
private Long sex;
/**
* 身份证号
*/
@ExcelProperty(value = "身份证号")
@ExcelProperty(value = "*身份证号")
@Pattern(
regexp = "^[1-9]\\d{5}(18|19|20|21)?\\d{2}(0[1-9]|1[0-2])(0[1-9]|[12]\\d|3[01])\\d{3}[0-9Xx]$",
message = "身份证号格式不正确",
groups = { AddGroup.class }
groups = {AddGroup.class}
)
@EncryptSensitive
@NotBlank(message = "身份证号不能为空")
private String idCard;
/**
* 联系方式
*/
@ExcelProperty(value = "*联系方式")
@Size(max = 11, message = "专家手机号长度不能超过11个字符", groups = {AddGroup.class})
@EncryptSensitive
@NotBlank(message = "联系方式不能为空")
private String contact;
/**
* 生日
*/
......@@ -75,13 +89,7 @@ public class ZjkExpertBo extends BaseEntity {
@DateTimeFormat(pattern = "yyyy-MM-dd")
private Date birthDate;
/**
* 联系方式
*/
@ExcelProperty(value = "联系方式")
@Size(max = 11, message = "专家手机号长度不能超过11个字符",groups = { AddGroup.class })
@EncryptSensitive
private String contact;
/**
* 工作单位
......@@ -92,7 +100,7 @@ public class ZjkExpertBo extends BaseEntity {
/**
* 单位类型 1企业,2高校,3政府单位
*/
@ExcelProperty(value = "单位类型" ,converter = ExcelDictConvert.class)
@ExcelProperty(value = "单位类型", converter = ExcelDictConvert.class)
@ExcelDictFormat(dictType = "unit_type")
private String unitType;
......@@ -100,7 +108,7 @@ public class ZjkExpertBo extends BaseEntity {
/**
* 是否专家推荐 1 是 2 否
*/
@ExcelProperty(value = "是否专家推荐" ,converter = ExcelDictConvert.class)
@ExcelProperty(value = "是否专家推荐", converter = ExcelDictConvert.class)
@ExcelDictFormat(dictType = "is_recommend")
private Integer isRecommend;
......@@ -113,7 +121,7 @@ public class ZjkExpertBo extends BaseEntity {
/**
* 政治面貌
*/
@ExcelProperty(value = "政治面貌" ,converter = ExcelDictConvert.class)
@ExcelProperty(value = "政治面貌", converter = ExcelDictConvert.class)
@ExcelDictFormat(dictType = "politics")
private String politics;
......@@ -130,7 +138,7 @@ public class ZjkExpertBo extends BaseEntity {
private String major;
@ExcelProperty(value = "学历" ,converter = ExcelDictConvert.class)
@ExcelProperty(value = "学历", converter = ExcelDictConvert.class)
@ExcelDictFormat(dictType = "degree_type")
private String degree;
......@@ -144,13 +152,11 @@ public class ZjkExpertBo extends BaseEntity {
/**
* 专业技术资格
*/
@ExcelProperty(value = "专业技术资格")
private String professional;
/**
* 专业技术资格取得时间
*/
@ExcelProperty(value = "专业技术资格取得时间")
@JsonFormat(pattern = "yyyy-MM-dd")
private Date professionalAcquisitionDate;
......@@ -175,14 +181,13 @@ public class ZjkExpertBo extends BaseEntity {
/**
* 从事工作或研究领域
*/
@ExcelProperty(value = "从事工作或研究领域", converter = ExcelDictConvert.class)
@ExcelProperty(value = "从事工作或研究领域", converter = MultiDictConvert.class)
@ExcelDictFormat(dictType = "perform_work_type")
private String performWorkId;
/**
* 其他领域描述
*/
@ExcelProperty(value = "其他领域描述")
private String otherDescribe;
/**
......@@ -200,7 +205,6 @@ public class ZjkExpertBo extends BaseEntity {
/**
* 主要论著、业绩成果及获奖情况
*/
@ExcelProperty(value = "主要论著、业绩成果及获奖情况")
private String achievement;
......@@ -267,21 +271,25 @@ public class ZjkExpertBo extends BaseEntity {
/**
* 省
*/
@ExcelProperty(value = "省")
private String province;
/**
* 市
*/
@ExcelProperty(value = "市")
private String city;
/**
* 区
*/
@ExcelProperty(value = "区")
private String area;
/**
* 详细地址
*/
@ExcelProperty(value = "详细地址")
private String address;
......@@ -331,11 +339,27 @@ public class ZjkExpertBo extends BaseEntity {
*/
@PropertyMsg(propertyName = "职称等级")
private Long positionTitleLevel;
@ExcelProperty(value = "职称等级")
private String positionTitleLevelStr;
@PropertyMsg(propertyName = "籍贯")
@ExcelProperty(value = "籍贯")
private String origin;
private String unitTypeDescribe;
private String expertIds;
/**
* 审批局同步过来的专业领域对应的类型名称
*/
private String professorDeclareCategory;
/**
* 活动范围
*/
private String scopeOfActivity;
/**
* 是否涉密0:不涉密 1:涉密
*/
private Integer isClassified;
}
......@@ -39,7 +39,7 @@ public class ZjkInvoiceBo extends BaseEntity {
*/
@NotNull(message = "发票号码不能为空", groups = { AddGroup.class, EditGroup.class })
@JsonFormat(shape = JsonFormat.Shape.NUMBER)
private Long invoiceNumber;
private String invoiceNumber;
/**
* 发票金额
......
......@@ -4,6 +4,7 @@ import com.fasterxml.jackson.annotation.JsonFormat;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.format.annotation.DateTimeFormat;
import org.dromara.common.mybatis.core.domain.BaseEntity;
import org.dromara.zjk.domain.ZjkLeave;
......@@ -29,10 +30,12 @@ public class ZjkLeaveBo extends BaseEntity {
* $column.columnComment
*/
private String leaveType;
@JsonFormat(timezone = "UTC",pattern="yyyy-MM-dd")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
private Date startDate;
@JsonFormat(timezone = "UTC",pattern="yyyy-MM-dd")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
private Date endDate;
/**
......@@ -64,6 +67,8 @@ public class ZjkLeaveBo extends BaseEntity {
* 租户ID
*/
private String tenantId;
/**
* 创建人
*/
private String createByStr;
}
......@@ -33,11 +33,11 @@ public class ZjkProductSummarizeBo extends BaseEntity {
private String search;
private String reviewSn;
@DateTimeFormat(pattern = "YYYY-MM-dd hh:mm:ss")
@JsonFormat(pattern = "YYYY-MM-dd hh:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
private Date startTime;
@DateTimeFormat(pattern = "YYYY-MM-dd hh:mm:ss")
@JsonFormat(pattern = "YYYY-MM-dd hh:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
private Date endTime;
......@@ -116,4 +116,5 @@ public class ZjkProductSummarizeBo extends BaseEntity {
private List<String> statusList;
private List<Long> productIds;
private List<Long> ids;
}
......@@ -33,5 +33,6 @@ public class ZjkReviewProductBo implements Serializable {
private Date endTime;
private Long expertId;
private Long userId;
private Integer isExpert;
}
......@@ -13,6 +13,7 @@ import java.util.Date;
public class PointReqDto {
private Long id;
private String ruleName;
private String rewardName;
private Date startDate;
......
......@@ -15,7 +15,7 @@ public class ZjkProductSummarizeExcelVO {
@ExcelProperty(value = "所属项目")
private String productName;
@ExcelProperty(value = "项目总结总结名称")
@ExcelProperty(value = "项目总结名称")
private String productSummarizeName;
@ExcelProperty(value = "项目总结分类",converter = ExcelDictConvert.class)
......
......@@ -5,6 +5,7 @@ import com.alibaba.excel.annotation.ExcelProperty;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import org.dromara.zjk.domain.InoutCheck;
import org.dromara.zjk.zwy.annotation.EncryptSensitive;
import java.io.Serial;
import java.io.Serializable;
......@@ -38,11 +39,13 @@ public class CheckSupportVo implements Serializable {
* 联系电话
*/
@ExcelProperty(value = "联系电话")
@EncryptSensitive
private String contact;
/**
* 身份证号
*/
@ExcelProperty(value = "身份证号")
@EncryptSensitive
private String idcard;
/**
* 评审阶段
......
......@@ -46,12 +46,14 @@ public class InoutCheckVo implements Serializable {
* 时间范围开始
*/
@ExcelProperty(value = "时间范围开始")
@JsonFormat(pattern = "yyyy-MM-dd")
private Date checkRangeStart;
/**
* 时间范围结束
*/
@ExcelProperty(value = "时间范围结束")
@JsonFormat(pattern = "yyyy-MM-dd")
private Date checkRangeEnd;
/**
......@@ -63,9 +65,12 @@ public class InoutCheckVo implements Serializable {
/**
* 创建人
*/
@ExcelProperty(value = "创建人")
private Long createBy;
/**
* 操作员
*/
@ExcelProperty(value = "创建人")
private String createByStr;
/**
* 创建时间
*/
......
package org.dromara.zjk.domain.vo;
import lombok.Data;
/**
* 同步用户返回
*
* @author : yanguohua
* @version : 1.0
* @date : 2025/12/11 16:26
*/
@Data
public class SyncUserReturnVO {
//数据同步完成,共新增X条,更新Y条,失败Z条
private boolean statu;
private String msg;
}
......@@ -56,9 +56,12 @@ public class ZjkApprovalProcessLogsVo implements Serializable {
/**
* 创建人
*/
@ExcelProperty(value = "操作人")
private Long createBy;
/**
* 创建人
*/
@ExcelProperty(value = "操作人")
private String createByStr;
/**
* 创建时间
*/
......
......@@ -2,6 +2,7 @@ package org.dromara.zjk.domain.vo;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.baomidou.mybatisplus.annotation.TableField;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import org.dromara.common.excel.annotation.ExcelDictFormat;
......@@ -70,7 +71,11 @@ public class ZjkDataChangesLogsVo implements Serializable {
* 操作人
*/
private Long createBy;
/**
* 操作人
*/
@ExcelProperty(value = "操作人")
private String createByStr;
/**
* 操作时间
......
......@@ -145,6 +145,10 @@ public class ZjkEvaluateVO implements Serializable {
* 1.正常评价,不进行控制
*/
private Integer xmEvaluateStatus;
/**
* 项目管理员id
*/
private String productCreateBy;
private static final long serialVersionUID = 1L;
}
......@@ -63,8 +63,10 @@ public class ZjkExpertLogVo implements Serializable {
/**
* 入库结果
*/
@ExcelProperty(value = "入库结果")
private Integer entryResult;
@ExcelProperty(value = "入库结果")
private String entryResultStr;
/**
* 申请时间
......
......@@ -6,13 +6,10 @@ import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.dromara.common.core.utils.StringUtils;
import org.dromara.common.excel.annotation.ExcelDictFormat;
import org.dromara.common.excel.convert.ExcelDictConvert;
import org.dromara.common.sensitive.annotation.Sensitive;
import org.dromara.common.sensitive.core.SensitiveStrategy;
import org.dromara.common.excel.convert.MultiDictConvert;
import org.dromara.resource.api.domain.RemoteFile;
import org.dromara.zjk.zwy.annotation.EncryptSensitive;
import org.dromara.zjk.annotation.PropertyMsg;
import org.dromara.zjk.annualInspection.annualInspectionAudit.domain.ZjkAnnualInspection;
import org.dromara.zjk.domain.ZjkExpert;
......@@ -21,6 +18,7 @@ import org.dromara.zjk.domain.ZjkExpertProfessional;
import org.dromara.zjk.expert.expertAwards.domain.ZjkExpertAwards;
import org.dromara.zjk.expert.expertPaper.domain.ZjkExpertPaper;
import org.dromara.zjk.expert.expertPatent.domain.ZjkExpertPatent;
import org.dromara.zjk.zwy.annotation.EncryptSensitive;
import java.io.Serial;
import java.io.Serializable;
......@@ -72,8 +70,6 @@ public class ZjkExpertVo implements Serializable {
/**
* 身份证号
*/
@ExcelProperty(value = "身份证号")
@EncryptSensitive
private String idCard;
......@@ -82,7 +78,6 @@ public class ZjkExpertVo implements Serializable {
*/
@ExcelProperty(value = "联系方式")
@EncryptSensitive
private String contact;
/**
......@@ -90,6 +85,10 @@ public class ZjkExpertVo implements Serializable {
*/
@ExcelProperty(value = "工作单位")
private String workUnit;
/**
* 详细地址
*/
private String address;
/**
* 职务
......@@ -100,14 +99,11 @@ public class ZjkExpertVo implements Serializable {
/**
* 政治面貌
*/
@ExcelProperty(value = "政治面貌", converter = ExcelDictConvert.class)
@ExcelDictFormat(dictType = "politics")
private String politics;
/**
* 毕业学校
*/
@ExcelProperty(value = "毕业学校")
private String graduateSchool;
/**
......@@ -118,11 +114,11 @@ public class ZjkExpertVo implements Serializable {
/**
* 邮箱
*/
@ExcelProperty(value = "邮箱")
@EncryptSensitive
private String email;
@ExcelDictFormat(dictType = "degree_type")
private String degree;
/**
* 专业技术资格
*/
......@@ -136,14 +132,11 @@ public class ZjkExpertVo implements Serializable {
/**
* 从事专业
*/
@ExcelProperty(value = "从事专业")
private String workProfessial;
/**
* 从事专业年限
*/
@ExcelProperty(value = "从事专业年限", converter = ExcelDictConvert.class)
@ExcelDictFormat(dictType = "work_professial_year")
private Integer workProfessialYear;
/**
......@@ -164,13 +157,11 @@ public class ZjkExpertVo implements Serializable {
/**
* 主要工作经历
*/
@ExcelProperty(value = "主要工作经历")
private String workExperience;
/**
* 社会兼职情况
*/
@ExcelProperty(value = "社会兼职情况")
private String workPluralistic;
/**
......@@ -236,23 +227,17 @@ public class ZjkExpertVo implements Serializable {
/**
* 审批类型 0 专家申请 1 信息变更
*/
@ExcelProperty(value = "审批类型", converter = ExcelDictConvert.class)
@ExcelDictFormat(dictType = "approval_type")
private Integer approvalType;
/**
* 单位类型 1企业,2高校,3政府单位
*/
@ExcelProperty(value = "单位类型", converter = ExcelDictConvert.class)
@ExcelDictFormat(dictType = "unit_type")
private String unitType;
/**
* 是否专家推荐 1 是 2 否
*/
@ExcelProperty(value = "是否专家推荐", converter = ExcelDictConvert.class)
@ExcelDictFormat(dictType = "is_recommend")
private Integer isRecommend;
/**
......@@ -270,10 +255,6 @@ public class ZjkExpertVo implements Serializable {
*/
private String area;
/**
* 详细地址
*/
private String address;
/**
* 专业关系表对象
......@@ -304,7 +285,9 @@ public class ZjkExpertVo implements Serializable {
* 发生变化的字段
*/
private String modifiedFields;
/**
* 接受状态(1:已接受;0:未接受;2:拒绝; 4:取消)
*/
private Integer acceptStatus;
/**
......@@ -353,6 +336,8 @@ public class ZjkExpertVo implements Serializable {
private ZjkAnnualInspection zjkAnnualInspection;
private String rewardType;
private String rewardId;
/**
* 其他附件集合
*/
......@@ -370,8 +355,8 @@ public class ZjkExpertVo implements Serializable {
private String positionTitleLevelStr;
/*
* 抽取的数据来源
* */
* 抽取的数据来源
* */
private Integer isSource;
//2024/12/3 add返回字段 抽取状态(0:取消,1:确认,2:重抽) 页面进行显示 枚举类ExtractionStatusEnum
......@@ -383,10 +368,19 @@ public class ZjkExpertVo implements Serializable {
}
return Arrays.asList(performWorkId.split(","));
}
@PropertyMsg(propertyName = "籍贯")
private String origin;
private String unitTypeDescribe;
private String hmac;
/**
* 活动范围
*/
private String scopeOfActivity;
/**
* 是否涉密0:不涉密 1:涉密
*/
private Integer isClassified;
}
......@@ -37,7 +37,7 @@ public class ZjkInvoiceVo implements Serializable {
* 发票号码
*/
@ExcelProperty(value = "发票号码")
private Long invoiceNumber;
private String invoiceNumber;
/**
* 发票金额
......@@ -103,6 +103,10 @@ public class ZjkInvoiceVo implements Serializable {
* 结算单id
*/
private Long settleId;
/**
* 结算单id
*/
private String settleIdName;
/**
* 审核状态1:已审核
*/
......
......@@ -48,6 +48,7 @@ public class ZjkLeaveVo implements Serializable {
*/
@ExcelProperty(value = "${comment}", converter = ExcelDictConvert.class)
@ExcelDictFormat(readConverterExp = "$column.readConverterExp()")
@JsonFormat(pattern = "yyyy-MM-dd")
private Date startDate;
/**
......@@ -55,6 +56,7 @@ public class ZjkLeaveVo implements Serializable {
*/
@ExcelProperty(value = "${comment}", converter = ExcelDictConvert.class)
@ExcelDictFormat(readConverterExp = "$column.readConverterExp()")
@JsonFormat(pattern = "yyyy-MM-dd")
private Date endDate;
/**
......
......@@ -36,96 +36,89 @@ public class ZjkProductSummarizeVo implements Serializable {
/**
* id
*/
@ExcelProperty(value = "id", converter = ExcelDictConvert.class)
@ExcelProperty(value = "项目总结编号")
private Long id;
/**
* 专家抽取id
*/
@ExcelProperty(value = "专家抽取id", converter = ExcelDictConvert.class)
private Long reviewId;
/**
* 总结名称
*/
@ExcelProperty(value = "总结名称", converter = ExcelDictConvert.class)
@ExcelProperty(value = "总结名称")
private String productSummarizeName;
/**
* 总结类型
*/
@ExcelProperty(value = "总结类型", converter = ExcelDictConvert.class)
@ExcelProperty(value = "总结分类", converter = ExcelDictConvert.class)
@ExcelDictFormat(dictType = "summarize_classify")
private String productSummarizeType;
/**
* 备注
*/
@ExcelProperty(value = "总结标签")
private String remark;
@ExcelProperty(value = "所属项目")
private String productName;
/**
* 状态
*/
@ExcelProperty(value = "总结状态", converter = ExcelDictConvert.class)
@ExcelDictFormat(dictType = "summarize_status")
private String status;
private String statusName;
private String productSummarizeTypeName;
/**
* 项目概况
*/
@ExcelProperty(value = "项目概况", converter = ExcelDictConvert.class)
private String productGeneral;
/**
* 评审范围
*/
@ExcelProperty(value = "评审范围", converter = ExcelDictConvert.class)
private String reviewScope;
/**
* 评审结论
*/
@ExcelProperty(value = "评审结论", converter = ExcelDictConvert.class)
private String reviewConclusion;
/**
* 反馈
*/
@ExcelProperty(value = "反馈", converter = ExcelDictConvert.class)
private String feedback;
/**
* 后续改进措施
*/
@ExcelProperty(value = "后续改进措施", converter = ExcelDictConvert.class)
private String subsequent;
/**
* 附件
*/
@ExcelProperty(value = "附件", converter = ExcelDictConvert.class)
@ExcelIgnore
private String attachment;
/**
* 专家id
*/
@ExcelIgnore
private String expertIds;
/**
* 状态
*/
@ExcelIgnore
private String status;
/**
* 状态名称
*/
@ExcelProperty(value = "状态", converter = ExcelDictConvert.class)
private String statusName;
/**
* 备注
*/
@ExcelProperty(value = "备注", converter = ExcelDictConvert.class)
private String remark;
@ExcelProperty(value = "项目时间", converter = ExcelDictConvert.class)
@ExcelProperty(value = "项目时间")
private Date reviewTime;
@ExcelIgnore
private List<ZjkExpertVo> zjkExpertList;
@ExcelIgnore
private String productName;
private Long productId;
......
......@@ -105,7 +105,6 @@ public class ZjkProductVo implements Serializable {
/**
* $column.columnComment
*/
@ExcelProperty(value = "备注")
private String remark;
private Long reviewId;
......
......@@ -2,10 +2,14 @@ package org.dromara.zjk.domain.vo;
import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.dromara.zjk.zwy.annotation.EncryptSensitive;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serial;
import java.io.Serializable;
import java.util.Date;
import java.util.List;
......@@ -49,6 +53,7 @@ public class ZjkReviewExportVo implements Serializable {
/**
* 联系方式
*/
@EncryptSensitive
@ExcelProperty(value = "联系方式")
private String unitConcat;
......@@ -61,6 +66,11 @@ public class ZjkReviewExportVo implements Serializable {
/**
* 评审时间
*/
/**
* 评审时间
*/
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ExcelProperty(value = "评审时间")
private String reviewTime;
private Date reviewTime;
}
package org.dromara.zjk.domain.vo;
import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
......@@ -22,6 +23,7 @@ import java.util.List;
* @date 2024-10-29
*/
@Data
@ExcelIgnoreUnannotated
public class ZjkReviewProductVo implements Serializable {
@Serial
......@@ -37,18 +39,6 @@ public class ZjkReviewProductVo implements Serializable {
*/
private Long expertId;
/**
* 项目阶段
*/
private String reviewSn;
/**
* 评审时间
*/
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date reviewTime;
/**
* 规则id
*/
......@@ -67,19 +57,6 @@ public class ZjkReviewProductVo implements Serializable {
*/
@ExcelProperty(value = "项目名称")
private String productName;
/**
* 项目类型
*/
@ExcelProperty(value = "项目类型")
private String productType;
/**
* 项目规则
*/
@ExcelProperty(value = "项目规模")
private Integer productScale;
/**
* 项目单位
*/
......@@ -99,11 +76,36 @@ public class ZjkReviewProductVo implements Serializable {
@EncryptSensitive
@ExcelProperty(value = "联系方式")
private String unitConcat;
/**
* 评审阶段
*/
@ExcelProperty(value = "评审阶段")
private String reviewSn;
/**
* 评审时间
*/
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ExcelProperty(value = "评审时间")
private Date reviewTime;
/**
* 项目类型
*/
//@ExcelProperty(value = "项目类型")
private String productType;
/**
* 项目规则
*/
//@ExcelProperty(value = "项目规模")
private Integer productScale;
/**
* 简介
*/
@ExcelProperty(value = "简介")
//@ExcelProperty(value = "简介")
private String productBrief;
/**
......@@ -120,7 +122,6 @@ public class ZjkReviewProductVo implements Serializable {
/**
* 备注
*/
@ExcelProperty(value = "备注")
private String remark;
private Long productId;
......
......@@ -22,7 +22,28 @@ public enum ReviewSnEnum {
* 描述
*/
private final String desc;
/**
* 通过描述获取编码
*
* @param desc 描述
* @return 编码
*/
public static Integer getCodeByDesc(String desc) {
for (ReviewSnEnum status : ReviewSnEnum.values()) {
if (status.getDesc().equals(desc)) {
return Integer.valueOf(status.getCode());
}
}
return null; // 找不到对应描述的枚举值时返回 null
}
public static String getDescByCode(String code) {
for (ReviewSnEnum status : ReviewSnEnum.values()) {
if (status.getCode().equals(code)) {
return status.getDesc();
}
}
return null; // 找不到对应描述的枚举值时返回 null
}
public static ReviewSnEnum getByCode(String code) {
for (ReviewSnEnum status : ReviewSnEnum.values()) {
if (status.getCode().equals( code)) {
......
......@@ -9,8 +9,7 @@ public enum SourceTypeEnum implements BaseCodeEnum {
ACADEMIC_TYPE("1","政务信息"),
RESEARCH_REPORTS("2","政务信息"),
ACADEMIC_CONFERENCES("3","政务信息");
RESEARCH_REPORTS("2","政务服务");
private String code;
private String name;
......
package org.dromara.zjk.enums;
import lombok.AllArgsConstructor;
import lombok.Getter;
@Getter
@AllArgsConstructor
public enum UserSourceTypeEnum implements BaseCodeEnum {
FROM_SPJ("11", "审批局原系统用户同步");
private String code;
private String name;
}
......@@ -9,6 +9,7 @@ import org.dromara.zjk.event.OnchainEvent;
import org.dromara.zjk.service.IZjkExpertItemService;
import org.springframework.context.ApplicationListener;
import org.springframework.context.event.EventListener;
import org.springframework.scheduling.annotation.Async;
import org.springframework.stereotype.Component;
import org.springframework.util.CollectionUtils;
......@@ -32,12 +33,18 @@ public class OnchainListener implements ApplicationListener<OnchainEvent> {
* 保存系统日志记录
*/
@EventListener
@Async("smsTaskExecutor")
public void sendChainInfo(OnchainDto onchainDto) {
log.info("规则id为{},抽取的专家上区块链开始", onchainDto.getReviewId());
List<ZjkExpertItemVo> data = zjkExpertItemService.getByReviewId(onchainDto.getReviewId());
if (!CollectionUtils.isEmpty(data)) {
String jsonStr = JSONUtil.toJsonStr(data);
onChainUtils.toChain(jsonStr, onchainDto.getReviewId());
try {
List<ZjkExpertItemVo> data = zjkExpertItemService.getByReviewId(onchainDto.getReviewId());
if (!CollectionUtils.isEmpty(data)) {
String jsonStr = JSONUtil.toJsonStr(data);
onChainUtils.toChainAsync(jsonStr, onchainDto.getReviewId());
}
} catch (Exception e) {
e.printStackTrace();
log.error("规则id为{},抽取的专家上区块链异常", onchainDto.getReviewId());
}
log.info("规则id为{},抽取的专家上区块链结束", onchainDto.getReviewId());
}
......
......@@ -9,6 +9,7 @@ import org.dromara.zjk.event.SmsSendEvent;
import org.dromara.zjk.mapper.ZjkSmsInfoMapper;
import org.springframework.context.ApplicationListener;
import org.springframework.context.event.EventListener;
import org.springframework.scheduling.annotation.Async;
import org.springframework.stereotype.Component;
import javax.annotation.Resource;
......@@ -40,15 +41,28 @@ public class SmsSendListener implements ApplicationListener<SmsSendEvent> {
* 保存系统日志记录
*/
@EventListener
@Async("smsTaskExecutor")
public void sendSms(SmsSendYsdDto dto) {
List<Map<String, String>> data = dto.getReceiveUserTels().stream().map(item -> {
Map<String, String> stringStringMap = remoteSmsService.sendYsdSingleSms(dto.getContent(), item);
return stringStringMap;
}).collect(Collectors.toList());
//数据库信息回改
handleData(data, dto);
try {
// 设置整体处理超时时间
List<Map<String, String>> data = dto.getReceiveUserTels().parallelStream().map(item -> {
try {
// 为单个短信发送设置超时
return remoteSmsService.sendYsdSingleSms(dto.getContent(), item);
} catch (Exception e) {
log.error("发送短信失败,手机号: {}", item, e);
return Map.of("status", "-1", "tel", item, "resultId", "", "msg", "发送失败");
}
}).collect(Collectors.toList());
//数据库信息回改
handleData(data, dto);
} catch (Exception e) {
log.error("短信批量发送处理异常,批次号: {}", dto.getBatchNum(), e);
}
}
private void handleData(List<Map<String, String>> data, SmsSendYsdDto dto) {
//发送短信后的数据入库
List<ZjkSmsInfo> collect = data.stream().map(item -> {
......
......@@ -24,6 +24,8 @@ import org.dromara.zjk.expert.expertRecommend.service.IZjkExpertRecommendService
import org.dromara.zjk.mapper.ZjkExpertMapper;
import org.dromara.zjk.zwy.client.HmacClient;
import org.dromara.zjk.zwy.utils.ObjectHashGenerator;
import org.dromara.zjk.zwy.utils.StringCryptoUtil;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.nio.charset.StandardCharsets;
......@@ -45,7 +47,8 @@ public class ZjkExpertRecommendServiceImpl implements IZjkExpertRecommendService
private final ZjkExpertMapper zjkExpertMapper;
private final HmacClient hmacClient;
@Autowired
private StringCryptoUtil stringCryptoUtil;
/**
* 查询专家推荐信息
*
......@@ -67,6 +70,10 @@ public class ZjkExpertRecommendServiceImpl implements IZjkExpertRecommendService
@Override
public TableDataInfo<ZjkExpertRecommendVo> queryPageList(ZjkExpertRecommendBo bo, PageQuery pageQuery) {
LambdaQueryWrapper<ZjkExpertRecommend> lqw = buildQueryWrapper(bo);
if(StringUtils.isNotBlank(bo.getExpertPhone())){
String phone = stringCryptoUtil.encryptField(bo.getExpertPhone());
lqw.eq(ZjkExpertRecommend::getExpertPhone, phone);
}
Page<ZjkExpertRecommendVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);
return TableDataInfo.build(result);
}
......@@ -86,6 +93,8 @@ public class ZjkExpertRecommendServiceImpl implements IZjkExpertRecommendService
}
bo.setExpertId(existingExpert.getExpertId());
}
bo.getExpertPhone();
LambdaQueryWrapper<ZjkExpertRecommend> lqw = buildQueryWrapper(bo);
Page<ZjkExpertRecommendVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);
return TableDataInfo.build(result);
......@@ -109,7 +118,6 @@ public class ZjkExpertRecommendServiceImpl implements IZjkExpertRecommendService
lqw.eq(bo.getExpertId() != null, ZjkExpertRecommend::getExpertId, bo.getExpertId());
lqw.eq(bo.getUserId() != null, ZjkExpertRecommend::getUserId, bo.getUserId());
lqw.like(StringUtils.isNotBlank(bo.getExpertName()), ZjkExpertRecommend::getExpertName, bo.getExpertName());
lqw.like(StringUtils.isNotBlank(bo.getExpertPhone()), ZjkExpertRecommend::getExpertPhone, bo.getExpertPhone());
lqw.eq(StringUtils.isNotBlank(bo.getReason()), ZjkExpertRecommend::getReason, bo.getReason());
lqw.eq(StringUtils.isNotBlank(bo.getStatus()), ZjkExpertRecommend::getStatus, bo.getStatus());
lqw.orderByDesc(ZjkExpertRecommend::getCreateTime);
......
......@@ -21,6 +21,9 @@ import org.dromara.common.web.core.BaseController;
import org.dromara.zjk.expert.retirementRecords.domain.bo.ZjkRetirementRecordsBo;
import org.dromara.zjk.expert.retirementRecords.domain.vo.ZjkRetirementRecordsVo;
import org.dromara.zjk.expert.retirementRecords.service.IZjkRetirementRecordsService;
import org.dromara.zjk.zwy.annotation.DecryptOperation;
import org.dromara.zjk.zwy.utils.StringCryptoUtil;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;
......@@ -41,6 +44,9 @@ public class ZjkRetirementRecordsController extends BaseController {
private final IZjkRetirementRecordsService zjkRetirementRecordsService;
@Autowired
private StringCryptoUtil stringCryptoUtil;
/**
* 查询专家退休记录列表
*/
......@@ -49,8 +55,16 @@ public class ZjkRetirementRecordsController extends BaseController {
TenantConstants.TENANT_ADMIN_ROLE_KEY,
TenantConstants.SUPER_ADMIN_ROLE_KEY
}, mode = SaMode.OR)
@DecryptOperation
@GetMapping("/list")
public TableDataInfo<ZjkRetirementRecordsVo> list(ZjkRetirementRecordsBo bo, PageQuery pageQuery) {
// 2025-08-11 搜索时敏感字段需先加密
String encryptContact = stringCryptoUtil.encryptField(bo.getContact());
String encryptIdCard = stringCryptoUtil.encryptField(bo.getIdCard());
bo.setContact(encryptContact);
bo.setContact(encryptIdCard);
return zjkRetirementRecordsService.queryPageList(bo, pageQuery);
}
......@@ -76,6 +90,7 @@ public class ZjkRetirementRecordsController extends BaseController {
TenantConstants.SUPER_ADMIN_ROLE_KEY
}, mode = SaMode.OR)
@SaCheckPermission("expert:retirementRecords:query")
@DecryptOperation
@GetMapping("/{id}")
public R<ZjkRetirementRecordsVo> getInfo(@NotNull(message = "主键不能为空")
@PathVariable Long id) {
......
......@@ -78,6 +78,7 @@ public class ZjkRetirementRecordsVo implements Serializable {
private String expertName;
@ExcelProperty(value = "联系方式")
@EncryptSensitive
private String contact;
@ExcelProperty(value = "身份证号")
......
......@@ -5,6 +5,7 @@ import org.dromara.common.mybatis.core.page.PageQuery;
import org.dromara.common.mybatis.core.page.TableDataInfo;
import org.dromara.zjk.expert.retirementRecords.domain.bo.ZjkRetirementRecordsBo;
import org.dromara.zjk.expert.retirementRecords.domain.vo.ZjkRetirementRecordsVo;
import org.dromara.zjk.zwy.annotation.DecryptOperation;
import java.util.Collection;
import java.util.List;
......
package org.dromara.zjk.handler;
import lombok.extern.slf4j.Slf4j;
import org.dromara.common.core.domain.R;
import org.dromara.common.core.utils.StringUtils;
import org.dromara.zjk.utils.ApiThreadLocal;
import org.dromara.zjk.utils.EncryptionUtil;
import org.springframework.core.MethodParameter;
import org.springframework.http.MediaType;
import org.springframework.http.converter.HttpMessageConverter;
import org.springframework.http.server.ServerHttpRequest;
import org.springframework.http.server.ServerHttpResponse;
import org.springframework.web.bind.annotation.RestControllerAdvice;
import org.springframework.web.servlet.mvc.method.annotation.ResponseBodyAdvice;
/**
* @author : yanguohua
* @version : 1.0
* @date : 2025/8/27 10:11
*/
@RestControllerAdvice(basePackages = "org.dromara.zjk.controller")
@Slf4j
public class ApiEncryptResponseAdvice implements ResponseBodyAdvice<R<String>> {
@Override
public boolean supports(MethodParameter returnType, Class<? extends HttpMessageConverter<?>> converterType) {
// 只处理返回类型为 R<String> 的接口
return R.class.isAssignableFrom(returnType.getParameterType());
}
@Override
public R<String> beforeBodyWrite(R<String> body, MethodParameter returnType, MediaType selectedContentType,
Class<? extends HttpMessageConverter<?>> selectedConverterType,
ServerHttpRequest request, ServerHttpResponse response) {
// 判断是否需要加密(可以根据注解、路径等条件判断)
if (body != null && body.getCode() == 200 ) {
String ak = ApiThreadLocal.getAk();
if (StringUtils.isNotEmpty(ak)) {
try {
// 对数据进行加密
String encryptedData = EncryptionUtil.encrypt(body.getData(), ak);
// 替换原始数据为加密数据
return R.ok(body.getMsg(), encryptedData);
} catch (Exception e) {
// 加密失败记录日志
log.error("数据加密失败", e);
}
}
}
return body;
}
}
......@@ -20,6 +20,7 @@ import org.dromara.common.web.core.BaseController;
import org.dromara.zjk.learning_world.domain.bo.ZjkLearningCommontBo;
import org.dromara.zjk.learning_world.domain.vo.ZjkLearningCommontVo;
import org.dromara.zjk.learning_world.service.IZjkLearningCommontService;
import org.dromara.zjk.zwy.annotation.DecryptOperation;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;
......@@ -62,7 +63,7 @@ public class ZjkLearningCommontController extends BaseController {
TenantConstants.SUPER_ADMIN_ROLE_KEY,
TenantConstants.TENANT_ADMIN_ROLE_KEY,
},mode = SaMode.OR)
@Log(title = "评论", businessType = BusinessType.EXPORT)
@DecryptOperation
@PostMapping("/export")
public void export(ZjkLearningCommontBo bo, HttpServletResponse response) {
List<ZjkLearningCommontVo> list = zjkLearningCommontService.queryList(bo);
......
package org.dromara.zjk.learning_world.domain.bo;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.dromara.zjk.learning_world.domain.entity.ZjkLearningActivity;
import org.dromara.common.mybatis.core.domain.BaseEntity;
import org.dromara.common.core.validate.AddGroup;
......@@ -8,6 +9,8 @@ import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.EqualsAndHashCode;
import jakarta.validation.constraints.*;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;
/**
......@@ -43,11 +46,15 @@ public class ZjkLearningActivityBo extends BaseEntity {
* 活动时间
*/
@NotNull(message = "活动开始时间不能为空", groups = { AddGroup.class})
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
private Date activityStartTime;
/**
* 活动时间
*/
@NotNull(message = "活动结束时间不能为空", groups = { AddGroup.class})
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
private Date activityEndTime;
/**
......
......@@ -19,6 +19,7 @@ import java.util.Date;
* @date 2024-11-08
*/
@Data
@ExcelIgnoreUnannotated
public class ZjkLearningActivityExcel {
......@@ -32,13 +33,12 @@ public class ZjkLearningActivityExcel {
/**
* 活动分类
*/
@ExcelIgnore
@ExcelProperty(value = "活动分类")
private String activityClassify;
/**
* 活动分类
*/
@ExcelProperty(value = "活动分类")
private String activityClassifyName;
/**
......@@ -73,7 +73,6 @@ public class ZjkLearningActivityExcel {
/**
* 状态
*/
@ExcelProperty(value = "发布状态")
private String status;
/**
......@@ -85,13 +84,12 @@ public class ZjkLearningActivityExcel {
/**
* 活动状态
*/
@ExcelProperty(value = "活动状态")
@ExcelProperty(value = "发布状态")
private String activityStatusName;
/**
* 备注
*/
@ExcelProperty(value = "备注")
private String remark;
......
......@@ -2,7 +2,10 @@ package org.dromara.zjk.learning_world.domain.excel;
import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.format.DateTimeFormat;
import lombok.Data;
import org.dromara.common.excel.annotation.ExcelDictFormat;
import org.dromara.common.excel.convert.ExcelDictConvert;
import java.util.Date;
......@@ -24,14 +27,13 @@ public class ZjkLearningResourceExcel {
@ExcelProperty(value = "资源编号")
private String resourceName;
@ExcelProperty(value = "资源类型", converter = ExcelDictConvert.class)
@ExcelDictFormat(dictType = "source_type")
private String resourceClassify;
/**
* 资源分类
*/
@ExcelIgnore
private String resourceClassify; /**
* 资源分类
*/
@ExcelProperty(value = "资源分类")
private String resourceClassifyName;
/**
......@@ -42,7 +44,7 @@ public class ZjkLearningResourceExcel {
/**
* 资源类型
*/
@ExcelProperty(value = "资源类型")
@ExcelProperty(value = "资源分类")
private String resourceTypeName;
/**
......@@ -55,6 +57,7 @@ public class ZjkLearningResourceExcel {
* 发布时间
*/
@ExcelProperty(value = "发布时间")
@DateTimeFormat("yyyy-MM-dd")
private Date resourceTime;
/**
......
......@@ -5,6 +5,8 @@ import com.alibaba.excel.annotation.ExcelProperty;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import org.dromara.common.excel.annotation.ExcelDictFormat;
import org.dromara.common.excel.convert.ExcelDictConvert;
import org.dromara.zjk.learning_world.domain.entity.ZjkLearningCommont;
import org.springframework.format.annotation.DateTimeFormat;
......@@ -31,35 +33,41 @@ public class ZjkLearningCommontVo implements Serializable {
/**
* id
*/
@ExcelProperty(value = "id")
@ExcelProperty(value = "评论记录编号")
private Long id;
/**
* 资讯id
* 评论
*/
@ExcelProperty(value = "资讯id")
private Long informationId;
@ExcelProperty(value = "资讯Title")
@ExcelProperty(value = "评论内容")
private String comment;
@ExcelProperty(value = "所属帖子")
private String informationTitle;
/**
* 状态
*/
@ExcelProperty(value = "评论状态",converter = ExcelDictConvert.class)
@ExcelDictFormat(dictType = "is_publish")
private String status;
/**
* 评论人
*/
@ExcelProperty(value = "评论人")
private String reviewer;
private Long reviewerId;
/**
* 资讯id
*/
private Long informationId;
/**
* 被回复人ID
*/
@ExcelProperty(value = "被回复人ID")
private Long replyId;
/**
* 评论
*/
@ExcelProperty(value = "评论")
private String comment;
/**
* 评论时间
......@@ -69,16 +77,11 @@ public class ZjkLearningCommontVo implements Serializable {
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date commentTime;
/**
* 状态
*/
@ExcelProperty(value = "状态")
private String status;
/**
* 备注
*/
@ExcelProperty(value = "备注")
private String remark;
/**
......@@ -89,24 +92,17 @@ public class ZjkLearningCommontVo implements Serializable {
@ExcelProperty(value = "撤销时间")
private Date takedownTime;
@ExcelProperty(value = "上级")
private Long parentId;
@ExcelProperty(value = "专家名称")
private String expertName;
@ExcelProperty(value = "专家头像")
private String expertPhotograph;
@ExcelProperty(value = "部门名称")
private String deptName;
@ExcelProperty(value = "被回复人名称")
private String replyName;
@ExcelProperty(value = "被回复人头像")
private String replyPhotograph;
@ExcelProperty(value = "部门名称")
private String replyDeptName;
/**
......
......@@ -90,4 +90,6 @@ public class ZjkLearningCourseVo implements Serializable {
* 附件名称
*/
private String originalName;
private String createBy;
private Date createTime;
}
......@@ -8,7 +8,20 @@ import org.dromara.zjk.enums.BaseCodeEnum;
@AllArgsConstructor
public enum ActivityTypeEnum implements BaseCodeEnum {
GOVERNMENT_INFORMATION("1","政务信息");
/**
* 老年活动
*/
SENIOR_ACTIVITY("1", "老年活动"),
/**
* 线下运动
*/
OFFLINE_SPORTS("2", "线下运动"),
/**
* 阅读
*/
READING("3", "阅读");
private String code;
......
......@@ -8,7 +8,8 @@ import org.dromara.zjk.enums.BaseCodeEnum;
@AllArgsConstructor
public enum CourseTypeEnum implements BaseCodeEnum {
GOVERNMENT_INFORMATION("1","政务信息");
GOVERNMENT_INFORMATION("1","政务信息"),
GOVERNMENT_SERVICE("2","政务服务");
private String code;
......
package org.dromara.zjk.learning_world.mapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;
import org.dromara.zjk.learning_world.domain.bo.ZjkLearningCommontBo;
import org.dromara.zjk.learning_world.domain.entity.ZjkLearningCommont;
import org.dromara.common.mybatis.core.mapper.BaseMapperPlus;
import org.dromara.zjk.learning_world.domain.vo.ZjkLearningCommontVo;
import java.util.List;
/**
* 评论Mapper接口
*
......@@ -15,4 +18,6 @@ import org.dromara.zjk.learning_world.domain.vo.ZjkLearningCommontVo;
public interface ZjkLearningCommontMapper extends BaseMapperPlus<ZjkLearningCommont, ZjkLearningCommontVo> {
Page<ZjkLearningCommontVo> selectCommonPage(Page<Object> build, ZjkLearningCommontBo bo);
List<ZjkLearningCommontVo> selectCommonList(@Param("bo") ZjkLearningCommontBo bo);
}
......@@ -7,6 +7,8 @@ import org.dromara.zjk.learning_world.domain.bo.ZjkLearningToolBo;
import org.dromara.zjk.learning_world.domain.entity.ZjkLearningTool;
import org.dromara.zjk.learning_world.domain.vo.ZjkLearningToolVo;
import java.util.Collection;
/**
* 学习工具管理Mapper接口
*
......@@ -20,5 +22,5 @@ public interface ZjkLearningToolMapper extends BaseMapperPlus<ZjkLearningTool, Z
Page<ZjkLearningToolVo> selectByAll(@Param("page") Page<ZjkLearningToolVo> page, @Param("bo") ZjkLearningToolBo zjkLearningToolBo);
void deleteTool(Collection<Long> ids);
}
......@@ -155,10 +155,6 @@ public class ZjkLearningActivityServiceImpl implements IZjkLearningActivityServi
if (zjkLearningActivityVo == null) {
return false;
}
String activityStatus = zjkLearningActivityVo.getActivityStatus();
if (!activityStatus.equals(ActivityStatusEnum.DIDN_T_START.getCode())) {
throw new ServiceException("活动无法修改,请确认活动状态");
}
return baseMapper.updateById(update) > 0;
}
......@@ -195,12 +191,12 @@ public class ZjkLearningActivityServiceImpl implements IZjkLearningActivityServi
String activityStatus = excel.getActivityStatus();
String nameByCode = EnumUtil.getNameByCode(ActivityStatusEnum.class, activityStatus);
if (StringUtils.isNotBlank(nameByCode)) {
excel.setActivityStatus(nameByCode);
excel.setActivityStatusName(nameByCode);
}
String activityClassify = excel.getActivityClassify();
String classifyByCode = EnumUtil.getNameByCode(ActivityTypeEnum.class, activityClassify);
if (StringUtils.isNotBlank(classifyByCode)) {
excel.setActivityStatusName(classifyByCode);
excel.setActivityClassify(classifyByCode);
}
}
......
......@@ -13,6 +13,7 @@ import org.dromara.common.mybatis.core.page.PageQuery;
import org.dromara.common.mybatis.core.page.TableDataInfo;
import org.dromara.common.satoken.utils.LoginHelper;
import org.dromara.system.api.model.LoginUser;
import org.dromara.zjk.annualInspection.annualInspectionAudit.mapper.ZjkAnnualInspectionMapper;
import org.dromara.zjk.domain.vo.ZjkExpertVo;
import org.dromara.zjk.learning_world.domain.bo.ZjkLearningCommontBo;
import org.dromara.zjk.learning_world.domain.entity.ZjkLearningCommont;
......@@ -43,6 +44,7 @@ public class ZjkLearningCommontServiceImpl implements IZjkLearningCommontService
private final ZjkLearningInformationMapper zjkLearningInformationMapper;
private final ZjkExpertMapper zjkExpertMapper;
private final ZjkAnnualInspectionMapper zjkAnnualInspectionMapper;
/**
* 查询评论
......@@ -80,11 +82,9 @@ public class ZjkLearningCommontServiceImpl implements IZjkLearningCommontService
if (null == zjkLearningInformation) {
throw new ServiceException("无效帖子ID");
}
userId = zjkLearningInformation.getUserId();
userId = zjkLearningInformation.getUserId();
}
//LambdaQueryWrapper<ZjkLearningCommont> lqw = buildQueryWrapper(bo);
bo.setStatus("2");
Page<ZjkLearningCommontVo> result = baseMapper.selectCommonPage(pageQuery.build(), bo);
List<ZjkLearningCommontVo> records = result.getRecords();
if (CollectionUtil.isEmpty(records)) {
......@@ -100,7 +100,7 @@ public class ZjkLearningCommontServiceImpl implements IZjkLearningCommontService
Map<Long, ZjkExpertVo> getExpertMap = zjkExpertVos.stream().collect(Collectors.toMap(ZjkExpertVo::getUserId, v -> v));
for (ZjkLearningCommontVo record : records) {
ZjkExpertVo zjkExpertVo = getExpertMap.get(record.getReviewerId());
record.setExpertName(zjkExpertVo.getExpertName());
record.setExpertName(zjkExpertVo.getUserName());
record.setExpertPhotograph(zjkExpertVo.getPhotograph());
boolean flag = LoginHelper.getUserId().equals(userId);
record.setReply(flag);
......@@ -158,8 +158,13 @@ public class ZjkLearningCommontServiceImpl implements IZjkLearningCommontService
*/
@Override
public List<ZjkLearningCommontVo> queryList(ZjkLearningCommontBo bo) {
LambdaQueryWrapper<ZjkLearningCommont> lqw = buildQueryWrapper(bo);
return baseMapper.selectVoList(lqw);
List<ZjkLearningCommontVo> zjkLearningCommontVos = baseMapper.selectCommonList(bo);
zjkLearningCommontVos.stream().forEach(item -> {
item.setReviewer(zjkAnnualInspectionMapper.selectApprovalByUserId(item.getReviewerId()));
item.setInformationTitle(zjkLearningInformationMapper.selectById(item.getInformationId()).getInformationTitle());
});
return zjkLearningCommontVos;
}
private LambdaQueryWrapper<ZjkLearningCommont> buildQueryWrapper(ZjkLearningCommontBo bo) {
......@@ -285,7 +290,6 @@ public class ZjkLearningCommontServiceImpl implements IZjkLearningCommontService
}
@Override
public int updateStatuso(ZjkLearningCommontBo bo) {
Long id = bo.getId();
......
......@@ -166,14 +166,14 @@ public class ZjkLearningResourceServiceImpl implements IZjkLearningResourceServi
String statusByCode = EnumUtil.getNameByCode(PublishStatusEnum.class, status);
zjkLearningResourceExcel.setStatusName(statusByCode);
}
String resourceClassify = zjkLearningResourceExcel.getResourceClassify();
if (StringUtils.isNotBlank(resourceClassify)) {
String resourceClassifyByCode = EnumUtil.getNameByCode(SourceClassifyEnum.class, resourceClassify);
zjkLearningResourceExcel.setResourceClassifyName(resourceClassifyByCode);
}
// String resourceClassify = zjkLearningResourceExcel.getResourceClassify();
// if (StringUtils.isNotBlank(resourceClassify)) {
// String resourceClassifyByCode = EnumUtil.getNameByCode(SourceClassifyEnum.class, resourceClassify);
// zjkLearningResourceExcel.setResourceClassifyName(resourceClassifyByCode);
// }
}
return List.of();
return zjkLearningResourceExcels;
}
@Override
......
......@@ -129,7 +129,8 @@ public class ZjkLearningToolServiceImpl implements IZjkLearningToolService {
if(isValid){
//TODO 做一些业务上的校验,判断是否需要校验
}
return baseMapper.deleteByIds(ids) > 0;
baseMapper.deleteTool(ids);
return true;
}
@Override
......
......@@ -24,4 +24,6 @@ public interface InoutCheckMapper extends BaseMapperPlus<InoutCheck, InoutCheckV
String getInvFileNameById(String invFileId);
String getCheckNo();
String selectUserNameById(Long createBy);
}
......@@ -18,4 +18,5 @@ import org.dromara.common.mybatis.core.mapper.BaseMapperPlus;
public interface ZjkCreditMapper extends BaseMapperPlus<ZjkCredit, ZjkCreditVo> {
IPage<CreditShowVO> queryPointList(Page<Object> build, @Param("bo") CreditReqDto bo);
Integer getPointCount(@Param("bo") CreditReqDto bo);
}
package org.dromara.zjk.mapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;
import org.dromara.zjk.domain.ZjkCreditRule;
import org.dromara.common.mybatis.core.mapper.BaseMapperPlus;
import org.dromara.zjk.domain.bo.ZjkCreditBo;
import org.dromara.zjk.domain.vo.ZjkCreditRuleVo;
/**
......@@ -12,4 +15,5 @@ import org.dromara.zjk.domain.vo.ZjkCreditRuleVo;
*/
public interface ZjkCreditRuleMapper extends BaseMapperPlus<ZjkCreditRule, ZjkCreditRuleVo> {
Page<ZjkCreditRuleVo> selectCreditInfo(Page<Object> build,@Param("bo") ZjkCreditBo dto);
}
......@@ -4,6 +4,8 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;
import org.dromara.common.mybatis.annotation.DataColumn;
import org.dromara.common.mybatis.annotation.DataPermission;
import org.dromara.zjk.domain.ZjkEvaluate;
import org.dromara.zjk.domain.dto.LeaveStsDto;
import org.dromara.zjk.domain.dto.SelExpertRuleDto;
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment