diff --git a/web-app/src/main/java/com/zcloud/primeport/command/VehicleMessageAddExe.java b/web-app/src/main/java/com/zcloud/primeport/command/VehicleMessageAddExe.java index 125b009..5df63db 100644 --- a/web-app/src/main/java/com/zcloud/primeport/command/VehicleMessageAddExe.java +++ b/web-app/src/main/java/com/zcloud/primeport/command/VehicleMessageAddExe.java @@ -10,6 +10,7 @@ import com.zcloud.primeport.domain.model.VehicleMessageE; import com.zcloud.primeport.dto.VehicleMessageAddCmd; import com.zcloud.primeport.dto.VehicleMessageForCorpAddCmd; import lombok.AllArgsConstructor; +import lombok.val; import org.springframework.beans.BeanUtils; import org.springframework.stereotype.Component; import org.springframework.transaction.annotation.Transactional; @@ -55,8 +56,13 @@ public class VehicleMessageAddExe { * 1.判断是否重复 * 2.判断是否在黑名单中 */ - VehicleMessageE infoByLicenceNo = vehicleMessageGateway.getInfoByLicenceNo(examTypeE.getLicenceNo()); - if (infoByLicenceNo != null){ +// VehicleMessageE infoByLicenceNo = vehicleMessageGateway.getInfoByLicenceNo(examTypeE.getLicenceNo()); +// if (infoByLicenceNo != null){ +// throw new BizException("车辆已存在"); +// } + + Integer licenceNoCount = vehicleMessageGateway.countEnabledByLicenceNo(examTypeE.getLicenceNo()); + if (licenceNoCount > 0){ throw new BizException("车辆已存在"); } VehicleMessageE add = vehicleMessageGateway.add(examTypeE); diff --git a/web-app/src/main/java/com/zcloud/primeport/command/VehicleMessageUpdateExe.java b/web-app/src/main/java/com/zcloud/primeport/command/VehicleMessageUpdateExe.java index c600260..cbb7fb2 100644 --- a/web-app/src/main/java/com/zcloud/primeport/command/VehicleMessageUpdateExe.java +++ b/web-app/src/main/java/com/zcloud/primeport/command/VehicleMessageUpdateExe.java @@ -8,6 +8,7 @@ import com.zcloud.primeport.domain.model.VehicleMessageE; import com.zcloud.primeport.dto.VehicleMessageStatusCmd; import com.zcloud.primeport.dto.VehicleMessageUpdateCmd; import lombok.AllArgsConstructor; +import lombok.val; import org.springframework.beans.BeanUtils; import org.springframework.stereotype.Component; import org.springframework.transaction.annotation.Transactional; @@ -69,7 +70,18 @@ public class VehicleMessageUpdateExe { VehicleMessageE vehicleMessageE = new VehicleMessageE(); BeanUtils.copyProperties(statusCmd, vehicleMessageE); vehicleMessageE.updateFromCorp(vehicleMessageE); - boolean res = vehicleMessageGateway.update(vehicleMessageE); + boolean res = false; + if (statusCmd.getIsStatus() == 0){ // + val licenceNo = vehicleMessageGateway.countEnabledByLicenceNo(vehicleMessageE.getLicenceNo()); + if (licenceNo > 0){ + throw new BizException("车辆已存在"); + } + res = vehicleMessageGateway.update(vehicleMessageE); + }else if (statusCmd.getIsStatus() == 1){ + res = vehicleMessageGateway.update(vehicleMessageE); //如果是车辆停工,就直接修改车辆状态 + }else { + throw new BizException("车辆状态错误"); + } if (!res) { throw new BizException("修改失败"); } diff --git a/web-app/src/main/java/com/zcloud/primeport/service/VehicleMessageServiceImpl.java b/web-app/src/main/java/com/zcloud/primeport/service/VehicleMessageServiceImpl.java index bca3b45..ef07cbd 100644 --- a/web-app/src/main/java/com/zcloud/primeport/service/VehicleMessageServiceImpl.java +++ b/web-app/src/main/java/com/zcloud/primeport/service/VehicleMessageServiceImpl.java @@ -91,4 +91,4 @@ public class VehicleMessageServiceImpl implements VehicleMessageServiceI { return vehicleMessageQueryExe.countEnabledByLicenceNo(licenceNo); } -} \ No newline at end of file +} diff --git a/web-client/src/main/java/com/zcloud/primeport/api/VehicleMessageServiceI.java b/web-client/src/main/java/com/zcloud/primeport/api/VehicleMessageServiceI.java index b6d906d..3775a90 100644 --- a/web-client/src/main/java/com/zcloud/primeport/api/VehicleMessageServiceI.java +++ b/web-client/src/main/java/com/zcloud/primeport/api/VehicleMessageServiceI.java @@ -43,4 +43,4 @@ public interface VehicleMessageServiceI { */ int countEnabledByLicenceNo(String licenceNo); -} \ No newline at end of file +} diff --git a/web-client/src/main/java/com/zcloud/primeport/dto/VehicleMessageForCorpAddCmd.java b/web-client/src/main/java/com/zcloud/primeport/dto/VehicleMessageForCorpAddCmd.java index f709f07..038c1df 100644 --- a/web-client/src/main/java/com/zcloud/primeport/dto/VehicleMessageForCorpAddCmd.java +++ b/web-client/src/main/java/com/zcloud/primeport/dto/VehicleMessageForCorpAddCmd.java @@ -67,6 +67,8 @@ public class VehicleMessageForCorpAddCmd extends Command { private Long corpId; @ApiModelProperty(value = "附件地址", name = "attachmentUrl", required = true) private String attachmentUrl; + + /** * 审批信息 */ diff --git a/web-client/src/main/java/com/zcloud/primeport/dto/VehicleMessageStatusCmd.java b/web-client/src/main/java/com/zcloud/primeport/dto/VehicleMessageStatusCmd.java index 02f664e..0d705aa 100644 --- a/web-client/src/main/java/com/zcloud/primeport/dto/VehicleMessageStatusCmd.java +++ b/web-client/src/main/java/com/zcloud/primeport/dto/VehicleMessageStatusCmd.java @@ -26,10 +26,10 @@ public class VehicleMessageStatusCmd extends Command { @ApiModelProperty(value = "id", name = "id", required = true) @NotNull(message = "id不能为空") private Long id; - @ApiModelProperty(value = "进出港权限(1:有 2:无)", name = "mkmjPermission", required = true) - @NotNull(message = "进出港权限(1:有 2:无)不能为空") - @Min(value = 1, message = "进出港权限错误") - @Max(value = 2, message = "进出港权限错误") - private Integer mkmjPermission; + @ApiModelProperty(value = "进出港权限(1:有 2:无)", name = "isStatus", required = true) + @NotNull(message = "车辆状态(0未启用,1启用)") + @Min(value = 0, message = "车辆状态错误") + @Max(value = 2, message = "车辆状态错误") + private Integer isStatus; } diff --git a/web-client/src/main/java/com/zcloud/primeport/dto/VehicleStatusDTO.java b/web-client/src/main/java/com/zcloud/primeport/dto/VehicleStatusDTO.java new file mode 100644 index 0000000..6dfe684 --- /dev/null +++ b/web-client/src/main/java/com/zcloud/primeport/dto/VehicleStatusDTO.java @@ -0,0 +1,20 @@ +package com.zcloud.primeport.dto; + +import lombok.Data; + +/** + * 车辆状态数据传输对象 + */ +@Data +public class VehicleStatusDTO { + + /** + * 车牌号 + */ + private String licenceNo; + + /** + * 启用状态车辆数量 + */ + private int enabledCount; +} \ No newline at end of file diff --git a/web-domain/src/main/java/com/zcloud/primeport/domain/gateway/VehicleMessageGateway.java b/web-domain/src/main/java/com/zcloud/primeport/domain/gateway/VehicleMessageGateway.java index 7bff8fe..cc37dbe 100644 --- a/web-domain/src/main/java/com/zcloud/primeport/domain/gateway/VehicleMessageGateway.java +++ b/web-domain/src/main/java/com/zcloud/primeport/domain/gateway/VehicleMessageGateway.java @@ -37,6 +37,11 @@ public interface VehicleMessageGateway { */ VehicleMessageE getInfoByLicenceNo(String licenceNo); + Integer countEnabledByLicenceNo(String licenceNo); + + /** + * 根据用户ID获取这个用户有多少车辆 + */ } diff --git a/web-infrastructure/src/main/java/com/zcloud/primeport/gatewayimpl/VehicleMessageGatewayImpl.java b/web-infrastructure/src/main/java/com/zcloud/primeport/gatewayimpl/VehicleMessageGatewayImpl.java index a4cc327..a9080d6 100644 --- a/web-infrastructure/src/main/java/com/zcloud/primeport/gatewayimpl/VehicleMessageGatewayImpl.java +++ b/web-infrastructure/src/main/java/com/zcloud/primeport/gatewayimpl/VehicleMessageGatewayImpl.java @@ -67,5 +67,10 @@ public class VehicleMessageGatewayImpl implements VehicleMessageGateway { BeanUtils.copyProperties(repositoryOne, vehicleMessageE); return vehicleMessageE; } + @Override + public Integer countEnabledByLicenceNo(String licenceNo) { + return vehicleMessageRepository.countEnabledByLicenceNo(licenceNo); + } + } diff --git a/web-infrastructure/src/main/java/com/zcloud/primeport/persistence/dataobject/UserViewDO.java b/web-infrastructure/src/main/java/com/zcloud/primeport/persistence/dataobject/UserViewDO.java new file mode 100644 index 0000000..d3f2724 --- /dev/null +++ b/web-infrastructure/src/main/java/com/zcloud/primeport/persistence/dataobject/UserViewDO.java @@ -0,0 +1,153 @@ +package com.zcloud.primeport.persistence.dataobject; + +import com.baomidou.mybatisplus.annotation.TableName; +import com.jjb.saas.framework.repository.basedo.BaseDO; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * web-infrastructure + * User视图DO类 + * @Author guoyuepeng + * @Date 2025-12-18 14:32:14 + */ +@Data +@TableName("user") +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class UserViewDO extends BaseDO { + + @ApiModelProperty(value = "用户ID") + private Long id; + + @ApiModelProperty(value = "用户ID") + private String userId; + + @ApiModelProperty(value = "用户名") + private String username; + + @ApiModelProperty(value = "姓名") + private String name; + + @ApiModelProperty(value = "企业ID") + private Long corpinfoId; + + @ApiModelProperty(value = "主企业标识") + private String mainCorpFlag; + + @ApiModelProperty(value = "用户类型") + private String userType; + + @ApiModelProperty(value = "部门ID") + private Long departmentId; + + @ApiModelProperty(value = "岗位ID") + private Long postId; + + @ApiModelProperty(value = "角色ID") + private Long roleId; + + @ApiModelProperty(value = "邮箱") + private String email; + + @ApiModelProperty(value = "电话") + private String phone; + + @ApiModelProperty(value = "人员类型") + private String personnelType; + + @ApiModelProperty(value = "人员类型名称") + private String personnelTypeName; + + @ApiModelProperty(value = "民族") + private String nation; + + @ApiModelProperty(value = "民族名称") + private String nationName; + + @ApiModelProperty(value = "身份证号") + private String userIdCard; + + @ApiModelProperty(value = "头像URL") + private String userAvatarUrl; + + @ApiModelProperty(value = "当前地址") + private String currentAddress; + + @ApiModelProperty(value = "定位地址") + private String locationAddress; + + @ApiModelProperty(value = "职级") + private String rankLevel; + + @ApiModelProperty(value = "职级名称") + private String rankLevelName; + + @ApiModelProperty(value = "排序") + private Integer sort; + + @ApiModelProperty(value = "版本") + private Integer version; + + @ApiModelProperty(value = "创建人ID") + private Long createId; + + @ApiModelProperty(value = "创建人姓名") + private String createName; + + @ApiModelProperty(value = "创建时间") + private java.util.Date createTime; + + @ApiModelProperty(value = "更新人ID") + private Long updateId; + + @ApiModelProperty(value = "更新人姓名") + private String updateName; + + @ApiModelProperty(value = "更新时间") + private java.util.Date updateTime; + + @ApiModelProperty(value = "备注") + private String remarks; + + @ApiModelProperty(value = "删除标识") + private String deleteEnum; + + @ApiModelProperty(value = "租户ID") + private String tenantId; + + @ApiModelProperty(value = "组织ID") + private String orgId; + + @ApiModelProperty(value = "环境") + private String env; + + @ApiModelProperty(value = "部门负责人标识") + private String departmentLeaderFlag; + + @ApiModelProperty(value = "副职领导标识") + private String deputyLeaderFlag; + + @ApiModelProperty(value = "文化程度") + private String culturalLevel; + + @ApiModelProperty(value = "文化程度名称") + private String culturalLevelName; + + @ApiModelProperty(value = "婚姻状况") + private String maritalStatus; + + @ApiModelProperty(value = "婚姻状况名称") + private String maritalStatusName; + + @ApiModelProperty(value = "政治面貌") + private String politicalAffiliation; + + @ApiModelProperty(value = "政治面貌名称") + private String politicalAffiliationName; + + @ApiModelProperty(value = "在职标识") + private String employmentFlag; +} \ No newline at end of file diff --git a/web-infrastructure/src/main/java/com/zcloud/primeport/persistence/mapper/EmployeeMessageCustomMapper.java b/web-infrastructure/src/main/java/com/zcloud/primeport/persistence/mapper/EmployeeMessageCustomMapper.java new file mode 100644 index 0000000..ae8f576 --- /dev/null +++ b/web-infrastructure/src/main/java/com/zcloud/primeport/persistence/mapper/EmployeeMessageCustomMapper.java @@ -0,0 +1,28 @@ +package com.zcloud.primeport.persistence.mapper; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.zcloud.primeport.persistence.dataobject.EmployeeMessageDO; +import org.apache.ibatis.annotations.Mapper; +import org.apache.ibatis.annotations.Param; +import org.apache.ibatis.annotations.Select; + +import java.util.Map; + +/** + * web-infrastructure + * 自定义EmployeeMessageMapper接口,用于复杂查询 + * @Author guoyuepeng + * @Date 2025-12-18 14:32:14 + */ +@Mapper +public interface EmployeeMessageCustomMapper extends BaseMapper { + + /** + * 通过user视图和employee_message表关联查询分页数据 + * @param page 分页参数 + * @param params 查询参数 + * @return 分页结果 + */ + IPage selectPageFromUserView(IPage page, @Param("params") Map params); +} \ No newline at end of file diff --git a/web-infrastructure/src/main/java/com/zcloud/primeport/persistence/mapper/UserViewMapper.java b/web-infrastructure/src/main/java/com/zcloud/primeport/persistence/mapper/UserViewMapper.java new file mode 100644 index 0000000..ce808f4 --- /dev/null +++ b/web-infrastructure/src/main/java/com/zcloud/primeport/persistence/mapper/UserViewMapper.java @@ -0,0 +1,16 @@ +package com.zcloud.primeport.persistence.mapper; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.zcloud.primeport.persistence.dataobject.UserViewDO; +import org.apache.ibatis.annotations.Mapper; + +/** + * web-infrastructure + * User视图Mapper接口 + * @Author guoyuepeng + * @Date 2025-12-18 14:32:14 + */ +@Mapper +public interface UserViewMapper extends BaseMapper { + +} \ No newline at end of file diff --git a/web-infrastructure/src/main/java/com/zcloud/primeport/persistence/repository/VehicleStatusRepository.java b/web-infrastructure/src/main/java/com/zcloud/primeport/persistence/repository/VehicleStatusRepository.java new file mode 100644 index 0000000..558b8b6 --- /dev/null +++ b/web-infrastructure/src/main/java/com/zcloud/primeport/persistence/repository/VehicleStatusRepository.java @@ -0,0 +1,31 @@ +package com.zcloud.primeport.persistence.repository; + +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.zcloud.primeport.persistence.dataobject.VehicleMessageDO; +import com.zcloud.primeport.persistence.mapper.VehicleMessageMapper; +import lombok.RequiredArgsConstructor; +import org.springframework.stereotype.Repository; + +/** + * 车辆状态仓储类 + */ +@Repository +@RequiredArgsConstructor +public class VehicleStatusRepository { + + private final VehicleMessageMapper vehicleMessageMapper; + + /** + * 根据车牌号统计启用状态的车辆数量 + * @param licenceNo 车牌号 + * @return 启用状态的车辆数量 + */ + public int countEnabledByLicenceNo(String licenceNo) { + QueryWrapper queryWrapper = new QueryWrapper<>(); + queryWrapper.eq("licence_no", licenceNo); + queryWrapper.eq("delete_enum", "FALSE"); + // 假设 isAudit 值为 2(审核通过)时表示启用状态 + queryWrapper.eq("is_audit", 2); + return vehicleMessageMapper.selectCount(queryWrapper).intValue(); + } +} \ No newline at end of file diff --git a/web-infrastructure/src/main/java/com/zcloud/primeport/persistence/repository/impl/VehicleMessageRepositoryImpl.java b/web-infrastructure/src/main/java/com/zcloud/primeport/persistence/repository/impl/VehicleMessageRepositoryImpl.java index 809b056..d6d8dc9 100644 --- a/web-infrastructure/src/main/java/com/zcloud/primeport/persistence/repository/impl/VehicleMessageRepositoryImpl.java +++ b/web-infrastructure/src/main/java/com/zcloud/primeport/persistence/repository/impl/VehicleMessageRepositoryImpl.java @@ -79,7 +79,7 @@ public class VehicleMessageRepositoryImpl extends BaseRepositoryImpl + + + + + + + diff --git a/web-infrastructure/src/main/resources/mybatis/employee_message.sql b/web-infrastructure/src/main/resources/mybatis/employee_message.sql new file mode 100644 index 0000000..0930240 --- /dev/null +++ b/web-infrastructure/src/main/resources/mybatis/employee_message.sql @@ -0,0 +1,46 @@ +/* + Navicat Premium Dump SQL + + Source Server : GBS数据库 + Source Server Type : MySQL + Source Server Version : 80038 (8.0.38) + Source Host : 192.168.20.100:33080 + Source Schema : zcloud-gbs-primeport + + Target Server Type : MySQL + Target Server Version : 80038 (8.0.38) + File Encoding : 65001 + + Date: 18/12/2025 15:08:25 +*/ + +SET NAMES utf8mb4; +SET FOREIGN_KEY_CHECKS = 0; + +-- ---------------------------- +-- Table structure for employee_message +-- ---------------------------- +DROP TABLE IF EXISTS `employee_message`; +CREATE TABLE `employee_message` ( + `id` bigint NOT NULL COMMENT 'id', + `user_id` bigint NULL DEFAULT NULL COMMENT '用户ID', + `is_permission` int NULL DEFAULT NULL COMMENT '是否有进入一级口门的权限(0-无权限;1有权限)', + `is_user_face` int NULL DEFAULT NULL COMMENT '是否有人脸权限', + `mkmj_scope` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '可以进入的口门信息', + `status` int NULL DEFAULT 1 COMMENT '状态:0-停用 1-启用', + `delete_enum` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT 'FALSE' COMMENT '删除标识', + `create_time` datetime NULL DEFAULT NULL COMMENT '创建时间', + `update_time` datetime NULL DEFAULT NULL COMMENT '更新时间', + `create_id` bigint NULL DEFAULT NULL COMMENT '创建人ID', + `update_id` bigint NULL DEFAULT NULL COMMENT '更新人ID', + `env` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT 'PROD' COMMENT '环境标识', + `create_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '创建人姓名', + `update_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '更新人姓名', + `tenant_id` bigint NULL DEFAULT NULL COMMENT '租户ID', + `org_id` bigint NULL DEFAULT NULL COMMENT '组织ID', + `version` int NULL DEFAULT 0 COMMENT '版本号', + `remarks` text CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL COMMENT '备注', + PRIMARY KEY (`id`) USING BTREE +) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_0900_ai_ci COMMENT = '用户的进入一级口门的信息' ROW_FORMAT = Dynamic; + +SET FOREIGN_KEY_CHECKS = 1; \ No newline at end of file diff --git a/web-infrastructure/src/main/resources/mybatis/mkmj_approval_user.sql b/web-infrastructure/src/main/resources/mybatis/mkmj_approval_user.sql new file mode 100644 index 0000000..8cb74b5 --- /dev/null +++ b/web-infrastructure/src/main/resources/mybatis/mkmj_approval_user.sql @@ -0,0 +1,50 @@ +/* + Navicat Premium Dump SQL + + Source Server : GBS数据库 + Source Server Type : MySQL + Source Server Version : 80038 (8.0.38) + Source Host : 192.168.20.100:33080 + Source Schema : zcloud-gbs-primeport + + Target Server Type : MySQL + Target Server Version : 80038 (8.0.38) + File Encoding : 65001 + + Date: 18/12/2025 13:52:24 +*/ + +SET NAMES utf8mb4; +SET FOREIGN_KEY_CHECKS = 0; + +-- ---------------------------- +-- Table structure for mkmj_approval_user +-- ---------------------------- +DROP TABLE IF EXISTS `mkmj_approval_user`; +CREATE TABLE `mkmj_approval_user` ( + `id` bigint NOT NULL COMMENT '主键ID', + `dept_name` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '审批人部门ID', + `dept_id` bigint NULL DEFAULT NULL COMMENT '审批人部门', + `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '审批人姓名', + `user_name` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '审批人', + `user_id` bigint NULL DEFAULT NULL COMMENT '审批人名字', + `corp_id` bigint NULL DEFAULT NULL COMMENT '企业id', + `is_personnel_permission` tinyint NULL DEFAULT NULL COMMENT '人员审核权限(0-无权限,1-有权限)', + `is_vehicle_permission` tinyint NULL DEFAULT NULL COMMENT '车辆审核权限(0-无权限,1-有权限)', + `is_temporary_permission` tinyint NULL DEFAULT NULL COMMENT '临时审核权限(0-无权限,1-有权限)', + `delete_enum` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT 'FALSE' COMMENT '删除标识', + `create_time` datetime NULL DEFAULT NULL COMMENT '创建时间', + `update_time` datetime NULL DEFAULT NULL COMMENT '更新时间', + `create_id` bigint NULL DEFAULT NULL COMMENT '创建人ID', + `update_id` bigint NULL DEFAULT NULL COMMENT '更新人ID', + `env` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT 'PROD' COMMENT '环境标识', + `create_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '创建人姓名', + `update_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '更新人姓名', + `tenant_id` bigint NULL DEFAULT NULL COMMENT '租户ID', + `org_id` bigint NULL DEFAULT NULL COMMENT '组织ID', + `version` int NULL DEFAULT 0 COMMENT '版本号', + `remarks` text CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL COMMENT '备注', + PRIMARY KEY (`id`) USING BTREE +) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_0900_ai_ci COMMENT = '一级口门门禁审批人' ROW_FORMAT = Dynamic; + +SET FOREIGN_KEY_CHECKS = 1; \ No newline at end of file diff --git a/web-infrastructure/src/main/resources/mybatis/user.sql b/web-infrastructure/src/main/resources/mybatis/user.sql new file mode 100644 index 0000000..19dd6fd --- /dev/null +++ b/web-infrastructure/src/main/resources/mybatis/user.sql @@ -0,0 +1,50 @@ +SELECT + `jjb-saas-zcloud-basic-info`.`user`.`id` AS `id`, + `jjb-saas-zcloud-basic-info`.`user`.`user_id` AS `user_id`, + `jjb-saas-zcloud-basic-info`.`user`.`username` AS `username`, + `jjb-saas-zcloud-basic-info`.`user`.`name` AS `name`, + `jjb-saas-zcloud-basic-info`.`user`.`corpinfo_id` AS `corpinfo_id`, + `jjb-saas-zcloud-basic-info`.`user`.`main_corp_flag` AS `main_corp_flag`, + `jjb-saas-zcloud-basic-info`.`user`.`user_type` AS `user_type`, + `jjb-saas-zcloud-basic-info`.`user`.`department_id` AS `department_id`, + `jjb-saas-zcloud-basic-info`.`user`.`post_id` AS `post_id`, + `jjb-saas-zcloud-basic-info`.`user`.`role_id` AS `role_id`, + `jjb-saas-zcloud-basic-info`.`user`.`email` AS `email`, + `jjb-saas-zcloud-basic-info`.`user`.`phone` AS `phone`, + `jjb-saas-zcloud-basic-info`.`user`.`personnel_type` AS `personnel_type`, + `jjb-saas-zcloud-basic-info`.`user`.`personnel_type_name` AS `personnel_type_name`, + `jjb-saas-zcloud-basic-info`.`user`.`nation` AS `nation`, + `jjb-saas-zcloud-basic-info`.`user`.`nation_name` AS `nation_name`, + `jjb-saas-zcloud-basic-info`.`user`.`user_id_card` AS `user_id_card`, + `jjb-saas-zcloud-basic-info`.`user`.`user_avatar_url` AS `user_avatar_url`, + `jjb-saas-zcloud-basic-info`.`user`.`current_address` AS `current_address`, + `jjb-saas-zcloud-basic-info`.`user`.`location_address` AS `location_address`, + `jjb-saas-zcloud-basic-info`.`user`.`rank_level` AS `rank_level`, + `jjb-saas-zcloud-basic-info`.`user`.`rank_level_name` AS `rank_level_name`, + `jjb-saas-zcloud-basic-info`.`user`.`sort` AS `sort`, + `jjb-saas-zcloud-basic-info`.`user`.`version` AS `version`, + `jjb-saas-zcloud-basic-info`.`user`.`create_id` AS `create_id`, + `jjb-saas-zcloud-basic-info`.`user`.`create_name` AS `create_name`, + `jjb-saas-zcloud-basic-info`.`user`.`create_time` AS `create_time`, + `jjb-saas-zcloud-basic-info`.`user`.`update_id` AS `update_id`, + `jjb-saas-zcloud-basic-info`.`user`.`update_name` AS `update_name`, + `jjb-saas-zcloud-basic-info`.`user`.`update_time` AS `update_time`, + `jjb-saas-zcloud-basic-info`.`user`.`remarks` AS `remarks`, + `jjb-saas-zcloud-basic-info`.`user`.`delete_enum` AS `delete_enum`, + `jjb-saas-zcloud-basic-info`.`user`.`tenant_id` AS `tenant_id`, + `jjb-saas-zcloud-basic-info`.`user`.`org_id` AS `org_id`, + `jjb-saas-zcloud-basic-info`.`user`.`env` AS `env`, + `jjb-saas-zcloud-basic-info`.`user`.`department_leader_flag` AS `department_leader_flag`, + `jjb-saas-zcloud-basic-info`.`user`.`deputy_leader_flag` AS `deputy_leader_flag`, + `jjb-saas-zcloud-basic-info`.`user`.`cultural_level` AS `cultural_level`, + `jjb-saas-zcloud-basic-info`.`user`.`cultural_level_name` AS `cultural_level_name`, + `jjb-saas-zcloud-basic-info`.`user`.`marital_status` AS `marital_status`, + `jjb-saas-zcloud-basic-info`.`user`.`marital_status_name` AS `marital_status_name`, + `jjb-saas-zcloud-basic-info`.`user`.`political_affiliation` AS `political_affiliation`, + `jjb-saas-zcloud-basic-info`.`user`.`political_affiliation_name` AS `political_affiliation_name`, + `jjb-saas-zcloud-basic-info`.`user`.`employment_flag` AS `employment_flag` +FROM + `jjb-saas-zcloud-basic-info`.`user` +WHERE + ( + `jjb-saas-zcloud-basic-info`.`user`.`delete_enum` = 'FALSE')