相关方人员字段增加
parent
ed851fd8e7
commit
0728fd588e
|
|
@ -121,6 +121,15 @@ public class UserController {
|
||||||
return SingleResponse.buildSuccess();
|
return SingleResponse.buildSuccess();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ApiOperation("修改")
|
||||||
|
@PutMapping("/editData")
|
||||||
|
public SingleResponse editData (UserQryCmd userUpdateCmd) {
|
||||||
|
userService.editData(userUpdateCmd);
|
||||||
|
return SingleResponse.buildSuccess();
|
||||||
|
}
|
||||||
|
|
||||||
@ApiOperation("导出用户列表")
|
@ApiOperation("导出用户列表")
|
||||||
@GetMapping("/exportUserTable")
|
@GetMapping("/exportUserTable")
|
||||||
public void exportUserTable(@RequestParam(value = "ids") Long[] ids, HttpServletResponse httpServletResponse) {
|
public void exportUserTable(@RequestParam(value = "ids") Long[] ids, HttpServletResponse httpServletResponse) {
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,7 @@ import com.zcloud.basic.info.command.convertor.ImgFilesCoConvertor;
|
||||||
import com.zcloud.basic.info.domain.config.DaHuaConfig;
|
import com.zcloud.basic.info.domain.config.DaHuaConfig;
|
||||||
import com.zcloud.basic.info.domain.gateway.ImgFilesGateway;
|
import com.zcloud.basic.info.domain.gateway.ImgFilesGateway;
|
||||||
import com.zcloud.basic.info.domain.model.ImgFilesE;
|
import com.zcloud.basic.info.domain.model.ImgFilesE;
|
||||||
|
import com.zcloud.basic.info.domain.utils.ImageCompressUtil;
|
||||||
import com.zcloud.basic.info.dto.ImgFilesAddCmd;
|
import com.zcloud.basic.info.dto.ImgFilesAddCmd;
|
||||||
import com.zcloud.basic.info.dto.clientobject.ImgFilesCO;
|
import com.zcloud.basic.info.dto.clientobject.ImgFilesCO;
|
||||||
import com.zcloud.basic.info.dto.clientobject.ImgFilesInfoCO;
|
import com.zcloud.basic.info.dto.clientobject.ImgFilesInfoCO;
|
||||||
|
|
@ -60,6 +61,7 @@ public class ImgFilesAddExe {
|
||||||
throw new RuntimeException(e);
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
SSOUser ssoUser = AuthContext.getCurrentUser();
|
SSOUser ssoUser = AuthContext.getCurrentUser();
|
||||||
Long tenantId = 1L;
|
Long tenantId = 1L;
|
||||||
if (ssoUser != null && ssoUser.getTenantId() != null){
|
if (ssoUser != null && ssoUser.getTenantId() != null){
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,7 @@ import com.alibaba.cola.dto.MultiResponse;
|
||||||
import com.alibaba.cola.dto.Response;
|
import com.alibaba.cola.dto.Response;
|
||||||
import com.alibaba.cola.dto.SingleResponse;
|
import com.alibaba.cola.dto.SingleResponse;
|
||||||
import com.alibaba.cola.exception.BizException;
|
import com.alibaba.cola.exception.BizException;
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
import com.jjb.saas.framework.auth.utils.AuthContext;
|
import com.jjb.saas.framework.auth.utils.AuthContext;
|
||||||
import com.jjb.saas.system.client.user.facade.UserFacade;
|
import com.jjb.saas.system.client.user.facade.UserFacade;
|
||||||
import com.jjb.saas.system.client.user.request.RoleDeptAddCmd;
|
import com.jjb.saas.system.client.user.request.RoleDeptAddCmd;
|
||||||
|
|
@ -32,11 +33,14 @@ import org.apache.dubbo.config.annotation.DubboReference;
|
||||||
import org.springframework.beans.BeanUtils;
|
import org.springframework.beans.BeanUtils;
|
||||||
import org.springframework.stereotype.Component;
|
import org.springframework.stereotype.Component;
|
||||||
import org.springframework.transaction.annotation.Transactional;
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
import org.springframework.util.ObjectUtils;
|
||||||
|
|
||||||
import java.time.LocalDateTime;
|
import java.time.LocalDateTime;
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
|
import static dm.jdbc.util.DriverUtil.log;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* web-app
|
* web-app
|
||||||
|
|
@ -201,6 +205,165 @@ public class UserUpdateExe {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public void editData(UserQryCmd userUpdateCmd) {
|
||||||
|
List<UserDO> userDOList = new ArrayList<>();
|
||||||
|
if (!ObjectUtils.isEmpty(userUpdateCmd.getPostId())){
|
||||||
|
Long[] dd = new Long[]{
|
||||||
|
2044063902693593088L
|
||||||
|
|
||||||
|
|
||||||
|
};
|
||||||
|
QueryWrapper queryWrapper = new QueryWrapper();
|
||||||
|
queryWrapper.in("id", dd);
|
||||||
|
userDOList = userRepository.list(queryWrapper);
|
||||||
|
} else {
|
||||||
|
|
||||||
|
Long[] dd = new Long[]{
|
||||||
|
2044063128479600640L,
|
||||||
|
2044063130157322240L,
|
||||||
|
2044063131436584960L,
|
||||||
|
2044063134028664832L,
|
||||||
|
2044063136746573824L,
|
||||||
|
2044063145072267264L,
|
||||||
|
2044063151921565696L,
|
||||||
|
2044063153364406272L,
|
||||||
|
2044063154748526592L,
|
||||||
|
2044063158569537536L,
|
||||||
|
2044063159794274304L,
|
||||||
|
2044063505375563776L,
|
||||||
|
2044063507149754368L,
|
||||||
|
2044063511138537472L,
|
||||||
|
2044063513051140096L,
|
||||||
|
2044063514351374336L,
|
||||||
|
2044063516767293440L,
|
||||||
|
2044063519271292928L,
|
||||||
|
2044063527332745216L,
|
||||||
|
2044063535813627904L,
|
||||||
|
2044063538644783104L,
|
||||||
|
2044063546525880320L,
|
||||||
|
2044063547779977216L,
|
||||||
|
2044063551496130560L,
|
||||||
|
2044063552787976192L,
|
||||||
|
2044063555484913664L,
|
||||||
|
2044063559549194240L,
|
||||||
|
2044063560841039872L,
|
||||||
|
2044063564733353984L,
|
||||||
|
2044063565995839488L,
|
||||||
|
2044063571540709376L,
|
||||||
|
2044063576691314688L,
|
||||||
|
2044063577895079936L,
|
||||||
|
2044063579174342656L,
|
||||||
|
2044063581690925056L,
|
||||||
|
2044063582928244736L,
|
||||||
|
2044063584132009984L,
|
||||||
|
2044063585360941056L,
|
||||||
|
2044063586602455040L,
|
||||||
|
2044063590578655232L,
|
||||||
|
2044063594949120000L,
|
||||||
|
2044063599084703744L,
|
||||||
|
2044063607523643392L,
|
||||||
|
2044063611885719552L,
|
||||||
|
2044063613093679104L,
|
||||||
|
2044063623411666944L,
|
||||||
|
2044063625815003136L,
|
||||||
|
2044063628503552000L,
|
||||||
|
2044063631099826176L,
|
||||||
|
2044063632467169280L,
|
||||||
|
2044063633733849088L,
|
||||||
|
2044063639136112640L,
|
||||||
|
2044063648980144128L,
|
||||||
|
2044063650494287872L,
|
||||||
|
2044063659780476928L,
|
||||||
|
2044063664595537920L,
|
||||||
|
2044063671021211648L,
|
||||||
|
2044063672275308544L,
|
||||||
|
2044063673516822528L,
|
||||||
|
2044063677522382848L,
|
||||||
|
2044063679988633600L,
|
||||||
|
2044063681330810880L,
|
||||||
|
2044063687605489664L,
|
||||||
|
2044063689023164416L,
|
||||||
|
2044063690205958144L,
|
||||||
|
2044063693968248832L,
|
||||||
|
2044063695633387520L,
|
||||||
|
2044063703455764480L,
|
||||||
|
2044063704818913280L,
|
||||||
|
2044063707205472256L,
|
||||||
|
2044063708413431808L,
|
||||||
|
2044063719578669056L,
|
||||||
|
2044063720748879872L,
|
||||||
|
2044063723148021760L,
|
||||||
|
2044063725744295936L,
|
||||||
|
2044063727140999168L,
|
||||||
|
2044063733457620992L,
|
||||||
|
2044063736095838208L,
|
||||||
|
2044063741267415040L,
|
||||||
|
2044063748087353344L,
|
||||||
|
2044063750650073088L,
|
||||||
|
2044063753124712448L,
|
||||||
|
2044063756840865792L,
|
||||||
|
2044063758342426624L,
|
||||||
|
2044063762184409088L,
|
||||||
|
2044063764914900992L,
|
||||||
|
2044063767288877056L,
|
||||||
|
2044063770472353792L,
|
||||||
|
2044063773106376704L,
|
||||||
|
2044063779485913088L,
|
||||||
|
2044063783692800000L,
|
||||||
|
2044063796250546176L,
|
||||||
|
2044063800348381184L,
|
||||||
|
2044063801703141376L,
|
||||||
|
2044063802873352192L,
|
||||||
|
2044063805343797248L,
|
||||||
|
2044063808971870208L,
|
||||||
|
2044063810133692416L,
|
||||||
|
2044063812587360256L,
|
||||||
|
2044063813782736896L,
|
||||||
|
2044063816211238912L,
|
||||||
|
2044063817599553536L,
|
||||||
|
2044063818908176384L,
|
||||||
|
2044063826499866624L,
|
||||||
|
2044063827678466048L,
|
||||||
|
2044063830190854144L,
|
||||||
|
2044063831386230784L,
|
||||||
|
2044063833957339136L,
|
||||||
|
2044063839128915968L,
|
||||||
|
2044063843293859840L,
|
||||||
|
2044063844522790912L,
|
||||||
|
2044063849832779776L,
|
||||||
|
2044063855088242688L,
|
||||||
|
2044063865225875456L,
|
||||||
|
2044063869009137664L,
|
||||||
|
2044063873304104960L,
|
||||||
|
2044063907684814848L,
|
||||||
|
2044063911543574528L
|
||||||
|
|
||||||
|
};
|
||||||
|
QueryWrapper queryWrapper = new QueryWrapper();
|
||||||
|
queryWrapper.in("id", dd);
|
||||||
|
userDOList = userRepository.list(queryWrapper);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
for (UserDO userDO : userDOList){
|
||||||
|
com.jjb.saas.system.client.user.request.UserUpdateCmd updateCmd = new com.jjb.saas.system.client.user.request.UserUpdateCmd();
|
||||||
|
updateCmd.setId(userDO.getId());
|
||||||
|
updateCmd.setAccount(userDO.getUsername());
|
||||||
|
updateCmd.setMobile(userDO.getPhone());
|
||||||
|
RoleDeptAddCmd roleDeptAddCmd = new RoleDeptAddCmd();
|
||||||
|
roleDeptAddCmd.setRoleId(2008483240551297026L);
|
||||||
|
roleDeptAddCmd.setDeptId(userDO.getDepartmentId());
|
||||||
|
List<RoleDeptAddCmd> roleDeptAddCmdList = Collections.singletonList(roleDeptAddCmd);
|
||||||
|
updateCmd.setRoleDepts(roleDeptAddCmdList);
|
||||||
|
log.info("GBS修改用户开始,用户信息:{}", JSONUtil.toJsonStr(updateCmd));
|
||||||
|
Response response = userFacade.update(updateCmd);
|
||||||
|
log.info("GBS修改用户结束,用户id:{},结果:{}", JSONUtil.toJsonStr(response));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
@Transactional(rollbackFor = Exception.class)
|
@Transactional(rollbackFor = Exception.class)
|
||||||
public boolean executePasswordRecover(AppUserRegisterCmd cmd) {
|
public boolean executePasswordRecover(AppUserRegisterCmd cmd) {
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -103,6 +103,11 @@ public class UserServiceImpl implements UserServiceI {
|
||||||
userUpdateExe.execute(userUpdateCmd);
|
userUpdateExe.execute(userUpdateCmd);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void editData(UserQryCmd userUpdateCmd) {
|
||||||
|
userUpdateExe.editData(userUpdateCmd);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void exportUserTable(HttpServletResponse httpServletResponse, Long[] ids, Long corpinfoId) {
|
public void exportUserTable(HttpServletResponse httpServletResponse, Long[] ids, Long corpinfoId) {
|
||||||
userQueryExe.exportUserTable(httpServletResponse, ids, corpinfoId);
|
userQueryExe.exportUserTable(httpServletResponse, ids, corpinfoId);
|
||||||
|
|
|
||||||
|
|
@ -41,6 +41,7 @@ public interface UserServiceI {
|
||||||
SingleResponse<UserCO> addXgf(UserXgfAddCmd cmd);
|
SingleResponse<UserCO> addXgf(UserXgfAddCmd cmd);
|
||||||
|
|
||||||
void edit(UserUpdateCmd cmd);
|
void edit(UserUpdateCmd cmd);
|
||||||
|
void editData(UserQryCmd cmd);
|
||||||
|
|
||||||
void exportUserTable(HttpServletResponse httpServletResponse, Long[] ids, Long corpinfoId);
|
void exportUserTable(HttpServletResponse httpServletResponse, Long[] ids, Long corpinfoId);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -97,7 +97,10 @@ public class CorpInfoUpdateCmd extends Command {
|
||||||
private String areaName;
|
private String areaName;
|
||||||
@ApiModelProperty(value = "所属区域编码")
|
@ApiModelProperty(value = "所属区域编码")
|
||||||
private String areaCode;
|
private String areaCode;
|
||||||
|
@ApiModelProperty(value = "开户银行")
|
||||||
|
private String depositBank;
|
||||||
|
@ApiModelProperty(value = "开户银行账号")
|
||||||
|
private String depositBankAccount;
|
||||||
@ApiModelProperty(value = "法定代表人", name = "lrName", required = true)
|
@ApiModelProperty(value = "法定代表人", name = "lrName", required = true)
|
||||||
private String lrName;
|
private String lrName;
|
||||||
@ApiModelProperty(value = "法人手机号", name = "lrMobile", required = true)
|
@ApiModelProperty(value = "法人手机号", name = "lrMobile", required = true)
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
package com.zcloud.basic.info.dto;
|
package com.zcloud.basic.info.dto;
|
||||||
|
|
||||||
import com.alibaba.cola.dto.Command;
|
import com.alibaba.cola.dto.Command;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
|
|
@ -9,6 +10,7 @@ import lombok.NoArgsConstructor;
|
||||||
|
|
||||||
import javax.validation.constraints.NotEmpty;
|
import javax.validation.constraints.NotEmpty;
|
||||||
import javax.validation.constraints.NotNull;
|
import javax.validation.constraints.NotNull;
|
||||||
|
import java.time.LocalDate;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* web-client
|
* web-client
|
||||||
|
|
@ -133,5 +135,29 @@ public class UserAddCmd extends Command {
|
||||||
@ApiModelProperty(value = "微信openid")
|
@ApiModelProperty(value = "微信openid")
|
||||||
private String openId;
|
private String openId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "是否特殊工种")
|
||||||
|
private Integer isSpecialJob;
|
||||||
|
@ApiModelProperty(value = "是否为部门负责人")
|
||||||
|
private Integer isDepaRrtmentHead;
|
||||||
|
@ApiModelProperty(value = "是否参加三级安全培训")
|
||||||
|
private Integer isLevelThree;
|
||||||
|
@ApiModelProperty(value = "是否签订劳动合同")
|
||||||
|
private Integer isSignLabor;
|
||||||
|
@ApiModelProperty(value = "是否缴纳商业保险")
|
||||||
|
private Integer isPay;
|
||||||
|
@ApiModelProperty(value = "是否缴纳社保")
|
||||||
|
private Integer isSocial;
|
||||||
|
@ApiModelProperty(value = "社会保障号码")
|
||||||
|
private String socialNumber;
|
||||||
|
@ApiModelProperty(value = "是否按期缴纳工伤保险")
|
||||||
|
private Integer isInjuriesPay;
|
||||||
|
@ApiModelProperty(value = "工伤保险有效期")
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
private LocalDate isInjuriesPayTime;
|
||||||
|
@ApiModelProperty(value = "商业保险单号")
|
||||||
|
private String payNumber;
|
||||||
|
@ApiModelProperty(value = "是否缴纳其他人身伤害保险")
|
||||||
|
private Integer isBf;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
package com.zcloud.basic.info.dto;
|
package com.zcloud.basic.info.dto;
|
||||||
|
|
||||||
import com.alibaba.cola.dto.Command;
|
import com.alibaba.cola.dto.Command;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
|
|
@ -9,6 +10,7 @@ import lombok.NoArgsConstructor;
|
||||||
|
|
||||||
import javax.validation.constraints.NotEmpty;
|
import javax.validation.constraints.NotEmpty;
|
||||||
import javax.validation.constraints.NotNull;
|
import javax.validation.constraints.NotNull;
|
||||||
|
import java.time.LocalDate;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* web-client
|
* web-client
|
||||||
|
|
@ -95,5 +97,29 @@ public class UserUpdateCmd extends Command {
|
||||||
// 微信openid
|
// 微信openid
|
||||||
@ApiModelProperty(value = "微信openid")
|
@ApiModelProperty(value = "微信openid")
|
||||||
private String openId;
|
private String openId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "是否特殊工种")
|
||||||
|
private Integer isSpecialJob;
|
||||||
|
@ApiModelProperty(value = "是否为部门负责人")
|
||||||
|
private Integer isDepaRrtmentHead;
|
||||||
|
@ApiModelProperty(value = "是否参加三级安全培训")
|
||||||
|
private Integer isLevelThree;
|
||||||
|
@ApiModelProperty(value = "是否签订劳动合同")
|
||||||
|
private Integer isSignLabor;
|
||||||
|
@ApiModelProperty(value = "是否缴纳商业保险")
|
||||||
|
private Integer isPay;
|
||||||
|
@ApiModelProperty(value = "是否缴纳社保")
|
||||||
|
private Integer isSocial;
|
||||||
|
@ApiModelProperty(value = "社会保障号码")
|
||||||
|
private String socialNumber;
|
||||||
|
@ApiModelProperty(value = "是否按期缴纳工伤保险")
|
||||||
|
private Integer isInjuriesPay;
|
||||||
|
@ApiModelProperty(value = "工伤保险有效期")
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
private LocalDate isInjuriesPayTime;
|
||||||
|
@ApiModelProperty(value = "商业保险单号")
|
||||||
|
private String payNumber;
|
||||||
|
@ApiModelProperty(value = "是否缴纳其他人身伤害保险")
|
||||||
|
private Integer isBf;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
package com.zcloud.basic.info.dto;
|
package com.zcloud.basic.info.dto;
|
||||||
|
|
||||||
import com.alibaba.cola.dto.Command;
|
import com.alibaba.cola.dto.Command;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
|
|
@ -9,6 +10,7 @@ import lombok.NoArgsConstructor;
|
||||||
|
|
||||||
import javax.validation.constraints.NotEmpty;
|
import javax.validation.constraints.NotEmpty;
|
||||||
import javax.validation.constraints.NotNull;
|
import javax.validation.constraints.NotNull;
|
||||||
|
import java.time.LocalDate;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* web-client
|
* web-client
|
||||||
|
|
@ -132,5 +134,30 @@ public class UserXgfAddCmd extends Command {
|
||||||
// 入职状态
|
// 入职状态
|
||||||
@ApiModelProperty(value = "是否流动人员,1-流动,0-固定人员")
|
@ApiModelProperty(value = "是否流动人员,1-流动,0-固定人员")
|
||||||
private Integer flowFlag;
|
private Integer flowFlag;
|
||||||
|
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "是否特殊工种")
|
||||||
|
private Integer isSpecialJob;
|
||||||
|
@ApiModelProperty(value = "是否为部门负责人")
|
||||||
|
private Integer isDepaRrtmentHead;
|
||||||
|
@ApiModelProperty(value = "是否参加三级安全培训")
|
||||||
|
private Integer isLevelThree;
|
||||||
|
@ApiModelProperty(value = "是否签订劳动合同")
|
||||||
|
private Integer isSignLabor;
|
||||||
|
@ApiModelProperty(value = "是否缴纳商业保险")
|
||||||
|
private Integer isPay;
|
||||||
|
@ApiModelProperty(value = "是否缴纳社保")
|
||||||
|
private Integer isSocial;
|
||||||
|
@ApiModelProperty(value = "社会保障号码")
|
||||||
|
private String socialNumber;
|
||||||
|
@ApiModelProperty(value = "是否按期缴纳工伤保险")
|
||||||
|
private Integer isInjuriesPay;
|
||||||
|
@ApiModelProperty(value = "工伤保险有效期")
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
private LocalDate isInjuriesPayTime;
|
||||||
|
@ApiModelProperty(value = "商业保险单号")
|
||||||
|
private String payNumber;
|
||||||
|
@ApiModelProperty(value = "是否缴纳其他人身伤害保险")
|
||||||
|
private Integer isBf;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -120,6 +120,12 @@ public class CorpInfoCO extends ClientObject {
|
||||||
@ApiModelProperty(value = "所属区域编码")
|
@ApiModelProperty(value = "所属区域编码")
|
||||||
private String areaCode;
|
private String areaCode;
|
||||||
|
|
||||||
|
//开户银行
|
||||||
|
@ApiModelProperty(value = "开户银行")
|
||||||
|
private String depositBank;
|
||||||
|
//开户银行账号
|
||||||
|
@ApiModelProperty(value = "开户银行账号")
|
||||||
|
private String depositBankAccount;
|
||||||
//法定代表人
|
//法定代表人
|
||||||
@ApiModelProperty(value = "法定代表人")
|
@ApiModelProperty(value = "法定代表人")
|
||||||
private String lrName;
|
private String lrName;
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,7 @@ import com.zcloud.gbscommon.translateaop.ZCloudTranslates;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.time.LocalDate;
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -192,5 +193,30 @@ public class UserCO extends ClientObject {
|
||||||
// 微信openid
|
// 微信openid
|
||||||
@ApiModelProperty(value = "微信openid")
|
@ApiModelProperty(value = "微信openid")
|
||||||
private String openId;
|
private String openId;
|
||||||
|
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "是否特殊工种")
|
||||||
|
private Integer isSpecialJob;
|
||||||
|
@ApiModelProperty(value = "是否为部门负责人")
|
||||||
|
private Integer isDepaRrtmentHead;
|
||||||
|
@ApiModelProperty(value = "是否参加三级安全培训")
|
||||||
|
private Integer isLevelThree;
|
||||||
|
@ApiModelProperty(value = "是否签订劳动合同")
|
||||||
|
private Integer isSignLabor;
|
||||||
|
@ApiModelProperty(value = "是否缴纳商业保险")
|
||||||
|
private Integer isPay;
|
||||||
|
@ApiModelProperty(value = "是否缴纳社保")
|
||||||
|
private Integer isSocial;
|
||||||
|
@ApiModelProperty(value = "社会保障号码")
|
||||||
|
private String socialNumber;
|
||||||
|
@ApiModelProperty(value = "是否按期缴纳工伤保险")
|
||||||
|
private Integer isInjuriesPay;
|
||||||
|
@ApiModelProperty(value = "工伤保险有效期")
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
private LocalDate isInjuriesPayTime;
|
||||||
|
@ApiModelProperty(value = "商业保险单号")
|
||||||
|
private String payNumber;
|
||||||
|
@ApiModelProperty(value = "是否缴纳其他人身伤害保险")
|
||||||
|
private Integer isBf;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -89,6 +89,12 @@ public class CorpInfoE extends BaseE {
|
||||||
//纬度
|
//纬度
|
||||||
private String latitude;
|
private String latitude;
|
||||||
|
|
||||||
|
|
||||||
|
//开户银行
|
||||||
|
private String depositBank;
|
||||||
|
//开户银行账号
|
||||||
|
private String depositBankAccount;
|
||||||
|
|
||||||
private String areaName;
|
private String areaName;
|
||||||
|
|
||||||
private String areaCode;
|
private String areaCode;
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
package com.zcloud.basic.info.domain.model;
|
package com.zcloud.basic.info.domain.model;
|
||||||
|
|
||||||
import com.jjb.saas.framework.domain.model.BaseE;
|
import com.jjb.saas.framework.domain.model.BaseE;
|
||||||
|
import com.zcloud.basic.info.domain.utils.ImageCompressUtil;
|
||||||
import com.zcloud.basic.info.domain.utils.Smb;
|
import com.zcloud.basic.info.domain.utils.Smb;
|
||||||
import com.zcloud.gbscommon.utils.DateUtil;
|
import com.zcloud.gbscommon.utils.DateUtil;
|
||||||
import com.zcloud.gbscommon.utils.Tools;
|
import com.zcloud.gbscommon.utils.Tools;
|
||||||
|
|
@ -92,7 +93,8 @@ public class ImgFilesE extends BaseE {
|
||||||
MultipartFile[] files = baseImgFilesE.getFiles();
|
MultipartFile[] files = baseImgFilesE.getFiles();
|
||||||
Long corpinfoId = ObjectUtils.isEmpty(baseImgFilesE.getCorpinfoId()) ? tenantId : baseImgFilesE.getCorpinfoId();
|
Long corpinfoId = ObjectUtils.isEmpty(baseImgFilesE.getCorpinfoId()) ? tenantId : baseImgFilesE.getCorpinfoId();
|
||||||
if (dockFlag == 1 && (baseImgFilesE.getType() == 608 || baseImgFilesE.getType() == 13)){
|
if (dockFlag == 1 && (baseImgFilesE.getType() == 608 || baseImgFilesE.getType() == 13)){
|
||||||
String resultFilePath = Smb.saveDaHuaFile(files[0], baseImgFilesE.getDaHuaFilePath());
|
MultipartFile targetFile = ImageCompressUtil.compressToJpg(files[0]);
|
||||||
|
String resultFilePath = Smb.saveDaHuaFile(targetFile, baseImgFilesE.getDaHuaFilePath());
|
||||||
return resultFilePath;
|
return resultFilePath;
|
||||||
} else {
|
} else {
|
||||||
String filePath = corpinfoId.toString() + "/" + DateUtil.getMonth() + "/" + baseImgFilesE.getPath();
|
String filePath = corpinfoId.toString() + "/" + DateUtil.getMonth() + "/" + baseImgFilesE.getPath();
|
||||||
|
|
@ -142,8 +144,9 @@ public class ImgFilesE extends BaseE {
|
||||||
int lastSlash = entry.getKey().lastIndexOf("/");
|
int lastSlash = entry.getKey().lastIndexOf("/");
|
||||||
// String dirPath = entry.getKey().substring(0, lastSlash + 1);
|
// String dirPath = entry.getKey().substring(0, lastSlash + 1);
|
||||||
String fileName = entry.getKey().substring(lastSlash + 1);
|
String fileName = entry.getKey().substring(lastSlash + 1);
|
||||||
|
MultipartFile targetFile = ImageCompressUtil.compressToJpg(entry.getValue());
|
||||||
// 文件上传并获取上传路径
|
// 文件上传并获取上传路径
|
||||||
String resultFilePath = Smb.saveDaHuaFile(entry.getValue(), entry.getKey());
|
String resultFilePath = Smb.saveDaHuaFile(targetFile, entry.getKey());
|
||||||
imgFile.setImgFilesId(Tools.get32UUID());
|
imgFile.setImgFilesId(Tools.get32UUID());
|
||||||
imgFile.setFilePath(resultFilePath);
|
imgFile.setFilePath(resultFilePath);
|
||||||
imgFile.setType(baseImgFilesE.getType());
|
imgFile.setType(baseImgFilesE.getType());
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,7 @@ import cn.hutool.core.collection.CollUtil;
|
||||||
import com.alibaba.cola.dto.Response;
|
import com.alibaba.cola.dto.Response;
|
||||||
import com.alibaba.cola.exception.BizException;
|
import com.alibaba.cola.exception.BizException;
|
||||||
import com.baomidou.mybatisplus.annotation.TableField;
|
import com.baomidou.mybatisplus.annotation.TableField;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
import com.jjb.saas.framework.auth.utils.AuthContext;
|
import com.jjb.saas.framework.auth.utils.AuthContext;
|
||||||
import com.jjb.saas.framework.domain.model.BaseE;
|
import com.jjb.saas.framework.domain.model.BaseE;
|
||||||
import com.jjb.saas.framework.utils.DataEncryptDecryptUtil;
|
import com.jjb.saas.framework.utils.DataEncryptDecryptUtil;
|
||||||
|
|
@ -26,6 +27,7 @@ import org.springframework.web.multipart.MultipartFile;
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import java.time.LocalDate;
|
||||||
import java.time.LocalDateTime;
|
import java.time.LocalDateTime;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
|
|
@ -133,7 +135,17 @@ public class UserE extends BaseE {
|
||||||
private String politicalAffiliation;
|
private String politicalAffiliation;
|
||||||
//政治面貌名称
|
//政治面貌名称
|
||||||
private String politicalAffiliationName;
|
private String politicalAffiliationName;
|
||||||
|
private Integer isSpecialJob;
|
||||||
|
private Integer isDepaRrtmentHead;
|
||||||
|
private Integer isLevelThree;
|
||||||
|
private Integer isSignLabor;
|
||||||
|
private Integer isPay;
|
||||||
|
private Integer isSocial;
|
||||||
|
private String socialNumber;
|
||||||
|
private Integer isInjuriesPay;
|
||||||
|
private LocalDate isInjuriesPayTime;
|
||||||
|
private String payNumber;
|
||||||
|
private Integer isBf;
|
||||||
//密码
|
//密码
|
||||||
private String password;
|
private String password;
|
||||||
//密码
|
//密码
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,276 @@
|
||||||
|
package com.zcloud.basic.info.domain.utils;
|
||||||
|
|
||||||
|
import com.alibaba.cola.exception.BizException;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
|
||||||
|
import javax.imageio.IIOImage;
|
||||||
|
import javax.imageio.ImageIO;
|
||||||
|
import javax.imageio.ImageWriteParam;
|
||||||
|
import javax.imageio.ImageWriter;
|
||||||
|
import javax.imageio.stream.ImageInputStream;
|
||||||
|
import javax.imageio.stream.ImageOutputStream;
|
||||||
|
import java.awt.*;
|
||||||
|
import java.awt.image.BufferedImage;
|
||||||
|
import java.io.ByteArrayInputStream;
|
||||||
|
import java.io.ByteArrayOutputStream;
|
||||||
|
import java.io.File;
|
||||||
|
import java.io.IOException;
|
||||||
|
import java.io.InputStream;
|
||||||
|
import java.nio.file.Files;
|
||||||
|
import java.util.Iterator;
|
||||||
|
import java.util.Locale;
|
||||||
|
|
||||||
|
public class ImageCompressUtil {
|
||||||
|
|
||||||
|
private static final String JPG_SUFFIX = ".jpg";
|
||||||
|
private static final String JPG_CONTENT_TYPE = "image/jpeg";
|
||||||
|
private static final long DEFAULT_MAX_SIZE_KB = 100L;
|
||||||
|
private static final float MIN_QUALITY = 0.05F;
|
||||||
|
private static final float MAX_QUALITY = 1.0F;
|
||||||
|
private static final int QUALITY_SEARCH_TIMES = 8;
|
||||||
|
private static final double RESIZE_SCALE = 0.9D;
|
||||||
|
|
||||||
|
private ImageCompressUtil() {
|
||||||
|
}
|
||||||
|
|
||||||
|
public static MultipartFile compressToJpg(MultipartFile file) throws IOException {
|
||||||
|
return compressToJpg(file, DEFAULT_MAX_SIZE_KB);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static MultipartFile compressToJpg(MultipartFile file, long maxSizeKb) {
|
||||||
|
try {
|
||||||
|
if (file == null || file.isEmpty()) {
|
||||||
|
throw new IllegalArgumentException("file can not be null or empty");
|
||||||
|
}
|
||||||
|
if (maxSizeKb <= 0) {
|
||||||
|
throw new IllegalArgumentException("maxSizeKb must be greater than 0");
|
||||||
|
}
|
||||||
|
|
||||||
|
long maxSizeBytes = maxSizeKb * 1024L;
|
||||||
|
byte[] sourceBytes = file.getBytes();
|
||||||
|
String formatName = getFormatName(sourceBytes);
|
||||||
|
if (isTargetJpg(file, formatName, maxSizeBytes)) {
|
||||||
|
return file;
|
||||||
|
}
|
||||||
|
|
||||||
|
BufferedImage bufferedImage = ImageIO.read(new ByteArrayInputStream(sourceBytes));
|
||||||
|
if (bufferedImage == null) {
|
||||||
|
throw new IllegalArgumentException("file is not a supported image");
|
||||||
|
}
|
||||||
|
|
||||||
|
BufferedImage rgbImage = toRgbImage(bufferedImage);
|
||||||
|
byte[] compressedBytes = compress(rgbImage, maxSizeBytes);
|
||||||
|
String targetFileName = toJpgFileName(file.getOriginalFilename(), file.getName());
|
||||||
|
return new ByteArrayMultipartFile(file.getName(), targetFileName, JPG_CONTENT_TYPE, compressedBytes);
|
||||||
|
} catch (Exception e){
|
||||||
|
e.printStackTrace();
|
||||||
|
throw new BizException(e.getMessage());
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private static boolean isTargetJpg(MultipartFile file, String formatName, long maxSizeBytes) {
|
||||||
|
return file.getSize() <= maxSizeBytes
|
||||||
|
&& isJpgFormat(formatName)
|
||||||
|
&& hasJpgSuffix(file.getOriginalFilename());
|
||||||
|
}
|
||||||
|
|
||||||
|
private static boolean isJpgFormat(String formatName) {
|
||||||
|
if (formatName == null) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
String lowerFormatName = formatName.toLowerCase(Locale.ROOT);
|
||||||
|
return "jpg".equals(lowerFormatName) || "jpeg".equals(lowerFormatName);
|
||||||
|
}
|
||||||
|
|
||||||
|
private static boolean hasJpgSuffix(String fileName) {
|
||||||
|
if (fileName == null) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return fileName.toLowerCase(Locale.ROOT).endsWith(JPG_SUFFIX);
|
||||||
|
}
|
||||||
|
|
||||||
|
private static String getFormatName(byte[] sourceBytes) throws IOException {
|
||||||
|
try (ImageInputStream imageInputStream = ImageIO.createImageInputStream(new ByteArrayInputStream(sourceBytes))) {
|
||||||
|
Iterator<ImageWriter> writers = ImageIO.getImageWritersByFormatName("jpg");
|
||||||
|
if (!writers.hasNext()) {
|
||||||
|
throw new IOException("jpg writer not found");
|
||||||
|
}
|
||||||
|
Iterator<javax.imageio.ImageReader> readers = ImageIO.getImageReaders(imageInputStream);
|
||||||
|
if (!readers.hasNext()) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
javax.imageio.ImageReader imageReader = readers.next();
|
||||||
|
try {
|
||||||
|
return imageReader.getFormatName();
|
||||||
|
} finally {
|
||||||
|
imageReader.dispose();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private static BufferedImage toRgbImage(BufferedImage sourceImage) {
|
||||||
|
if (sourceImage.getType() == BufferedImage.TYPE_INT_RGB) {
|
||||||
|
return sourceImage;
|
||||||
|
}
|
||||||
|
BufferedImage rgbImage = new BufferedImage(sourceImage.getWidth(), sourceImage.getHeight(), BufferedImage.TYPE_INT_RGB);
|
||||||
|
Graphics2D graphics = rgbImage.createGraphics();
|
||||||
|
try {
|
||||||
|
graphics.setColor(Color.WHITE);
|
||||||
|
graphics.fillRect(0, 0, sourceImage.getWidth(), sourceImage.getHeight());
|
||||||
|
graphics.drawImage(sourceImage, 0, 0, null);
|
||||||
|
} finally {
|
||||||
|
graphics.dispose();
|
||||||
|
}
|
||||||
|
return rgbImage;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static byte[] compress(BufferedImage image, long maxSizeBytes) throws IOException {
|
||||||
|
BufferedImage currentImage = image;
|
||||||
|
while (true) {
|
||||||
|
byte[] compressedBytes = searchBestQuality(currentImage, maxSizeBytes);
|
||||||
|
if (compressedBytes != null) {
|
||||||
|
return compressedBytes;
|
||||||
|
}
|
||||||
|
if (currentImage.getWidth() == 1 && currentImage.getHeight() == 1) {
|
||||||
|
throw new IOException("can not compress image to target size");
|
||||||
|
}
|
||||||
|
currentImage = resize(currentImage, RESIZE_SCALE);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private static byte[] searchBestQuality(BufferedImage image, long maxSizeBytes) throws IOException {
|
||||||
|
byte[] maxQualityBytes = writeJpg(image, MAX_QUALITY);
|
||||||
|
if (maxQualityBytes.length <= maxSizeBytes) {
|
||||||
|
return maxQualityBytes;
|
||||||
|
}
|
||||||
|
|
||||||
|
byte[] minQualityBytes = writeJpg(image, MIN_QUALITY);
|
||||||
|
if (minQualityBytes.length > maxSizeBytes) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
byte[] bestBytes = minQualityBytes;
|
||||||
|
float low = MIN_QUALITY;
|
||||||
|
float high = MAX_QUALITY;
|
||||||
|
for (int i = 0; i < QUALITY_SEARCH_TIMES; i++) {
|
||||||
|
float mid = (low + high) / 2;
|
||||||
|
byte[] currentBytes = writeJpg(image, mid);
|
||||||
|
if (currentBytes.length <= maxSizeBytes) {
|
||||||
|
bestBytes = currentBytes;
|
||||||
|
low = mid;
|
||||||
|
} else {
|
||||||
|
high = mid;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return bestBytes;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static byte[] writeJpg(BufferedImage image, float quality) throws IOException {
|
||||||
|
Iterator<ImageWriter> writers = ImageIO.getImageWritersByFormatName("jpg");
|
||||||
|
if (!writers.hasNext()) {
|
||||||
|
throw new IOException("jpg writer not found");
|
||||||
|
}
|
||||||
|
|
||||||
|
ImageWriter imageWriter = writers.next();
|
||||||
|
ByteArrayOutputStream outputStream = new ByteArrayOutputStream();
|
||||||
|
try (ImageOutputStream imageOutputStream = ImageIO.createImageOutputStream(outputStream)) {
|
||||||
|
imageWriter.setOutput(imageOutputStream);
|
||||||
|
ImageWriteParam writeParam = imageWriter.getDefaultWriteParam();
|
||||||
|
if (writeParam.canWriteCompressed()) {
|
||||||
|
writeParam.setCompressionMode(ImageWriteParam.MODE_EXPLICIT);
|
||||||
|
writeParam.setCompressionQuality(quality);
|
||||||
|
}
|
||||||
|
imageWriter.write(null, new IIOImage(image, null, null), writeParam);
|
||||||
|
} finally {
|
||||||
|
imageWriter.dispose();
|
||||||
|
}
|
||||||
|
return outputStream.toByteArray();
|
||||||
|
}
|
||||||
|
|
||||||
|
private static BufferedImage resize(BufferedImage sourceImage, double scale) {
|
||||||
|
int targetWidth = Math.max(1, (int) Math.round(sourceImage.getWidth() * scale));
|
||||||
|
int targetHeight = Math.max(1, (int) Math.round(sourceImage.getHeight() * scale));
|
||||||
|
BufferedImage resizedImage = new BufferedImage(targetWidth, targetHeight, BufferedImage.TYPE_INT_RGB);
|
||||||
|
Graphics2D graphics = resizedImage.createGraphics();
|
||||||
|
try {
|
||||||
|
graphics.setRenderingHint(RenderingHints.KEY_INTERPOLATION, RenderingHints.VALUE_INTERPOLATION_BICUBIC);
|
||||||
|
graphics.setRenderingHint(RenderingHints.KEY_RENDERING, RenderingHints.VALUE_RENDER_QUALITY);
|
||||||
|
graphics.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
|
||||||
|
graphics.drawImage(sourceImage, 0, 0, targetWidth, targetHeight, null);
|
||||||
|
} finally {
|
||||||
|
graphics.dispose();
|
||||||
|
}
|
||||||
|
return resizedImage;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static String toJpgFileName(String originalFileName, String fallbackName) {
|
||||||
|
String fileName = originalFileName;
|
||||||
|
if (fileName == null || fileName.trim().isEmpty()) {
|
||||||
|
fileName = fallbackName;
|
||||||
|
}
|
||||||
|
if (fileName == null || fileName.trim().isEmpty()) {
|
||||||
|
fileName = "image";
|
||||||
|
}
|
||||||
|
int dotIndex = fileName.lastIndexOf('.');
|
||||||
|
if (dotIndex > -1) {
|
||||||
|
fileName = fileName.substring(0, dotIndex);
|
||||||
|
}
|
||||||
|
return fileName + JPG_SUFFIX;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static class ByteArrayMultipartFile implements MultipartFile {
|
||||||
|
|
||||||
|
private final String name;
|
||||||
|
private final String originalFilename;
|
||||||
|
private final String contentType;
|
||||||
|
private final byte[] content;
|
||||||
|
|
||||||
|
private ByteArrayMultipartFile(String name, String originalFilename, String contentType, byte[] content) {
|
||||||
|
this.name = name;
|
||||||
|
this.originalFilename = originalFilename;
|
||||||
|
this.contentType = contentType;
|
||||||
|
this.content = content;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String getOriginalFilename() {
|
||||||
|
return originalFilename;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String getContentType() {
|
||||||
|
return contentType;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isEmpty() {
|
||||||
|
return content.length == 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public long getSize() {
|
||||||
|
return content.length;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public byte[] getBytes() {
|
||||||
|
return content;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public InputStream getInputStream() {
|
||||||
|
return new ByteArrayInputStream(content);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void transferTo(File dest) throws IOException, IllegalStateException {
|
||||||
|
Files.write(dest.toPath(), content);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -182,6 +182,14 @@ public class CorpInfoDO extends BaseDO {
|
||||||
private String village;
|
private String village;
|
||||||
|
|
||||||
|
|
||||||
|
//开户银行
|
||||||
|
@ApiModelProperty(value = "开户银行")
|
||||||
|
private String depositBank;
|
||||||
|
//开户银行账号
|
||||||
|
@ApiModelProperty(value = "开户银行账号")
|
||||||
|
private String depositBankAccount;
|
||||||
|
|
||||||
|
|
||||||
//营业执照开始时间
|
//营业执照开始时间
|
||||||
@ApiModelProperty(value = "营业执照开始时间")
|
@ApiModelProperty(value = "营业执照开始时间")
|
||||||
private LocalDate licenseStart;
|
private LocalDate licenseStart;
|
||||||
|
|
|
||||||
|
|
@ -2,12 +2,16 @@ package com.zcloud.basic.info.persistence.dataobject;
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.annotation.TableField;
|
import com.baomidou.mybatisplus.annotation.TableField;
|
||||||
import com.baomidou.mybatisplus.annotation.TableName;
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
import com.jjb.saas.framework.repository.basedo.BaseDO;
|
import com.jjb.saas.framework.repository.basedo.BaseDO;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import io.swagger.models.auth.In;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
import lombok.EqualsAndHashCode;
|
import lombok.EqualsAndHashCode;
|
||||||
import lombok.NoArgsConstructor;
|
import lombok.NoArgsConstructor;
|
||||||
|
|
||||||
|
import java.time.LocalDate;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* web-infrastructure
|
* web-infrastructure
|
||||||
*
|
*
|
||||||
|
|
@ -161,6 +165,43 @@ public class UserDO extends BaseDO {
|
||||||
private String openId;
|
private String openId;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "是否特殊工种")
|
||||||
|
private Integer isSpecialJob;
|
||||||
|
@ApiModelProperty(value = "是否为部门负责人")
|
||||||
|
private Integer isDepaRrtmentHead;
|
||||||
|
@ApiModelProperty(value = "是否参加三级安全培训")
|
||||||
|
private Integer isLevelThree;
|
||||||
|
@ApiModelProperty(value = "是否签订劳动合同")
|
||||||
|
private Integer isSignLabor;
|
||||||
|
@ApiModelProperty(value = "是否缴纳商业保险")
|
||||||
|
private Integer isPay;
|
||||||
|
@ApiModelProperty(value = "是否缴纳社保")
|
||||||
|
private Integer isSocial;
|
||||||
|
@ApiModelProperty(value = "社会保障号码")
|
||||||
|
private String socialNumber;
|
||||||
|
@ApiModelProperty(value = "是否按期缴纳工伤保险")
|
||||||
|
private Integer isInjuriesPay;
|
||||||
|
@ApiModelProperty(value = "工伤保险有效期")
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
private LocalDate isInjuriesPayTime;
|
||||||
|
@ApiModelProperty(value = "商业保险单号")
|
||||||
|
private String payNumber;
|
||||||
|
@ApiModelProperty(value = "是否缴纳其他人身伤害保险")
|
||||||
|
private Integer isBf;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public UserDO(String userId) {
|
public UserDO(String userId) {
|
||||||
this.userId = userId;
|
this.userId = userId;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -325,6 +325,18 @@
|
||||||
u.employment_flag,
|
u.employment_flag,
|
||||||
u.flow_flag,
|
u.flow_flag,
|
||||||
u.rz_flag,
|
u.rz_flag,
|
||||||
|
u.is_special_job,
|
||||||
|
u.is_depa_rrtment_head,
|
||||||
|
u.is_level_three,
|
||||||
|
u.is_sign_labor,
|
||||||
|
u.is_pay,
|
||||||
|
u.is_social,
|
||||||
|
u.social_number,
|
||||||
|
u.is_injuries_pay,
|
||||||
|
u.is_injuries_pay_time,
|
||||||
|
u.pay_number,
|
||||||
|
u.is_bf,
|
||||||
|
|
||||||
CASE
|
CASE
|
||||||
WHEN LENGTH(FROM_BASE64(u.user_id_card)) > 0
|
WHEN LENGTH(FROM_BASE64(u.user_id_card)) > 0
|
||||||
AND MOD(SUBSTRING(FROM_BASE64(u.user_id_card), 17, 1), 2) = 1 THEN
|
AND MOD(SUBSTRING(FROM_BASE64(u.user_id_card), 17, 1), 2) = 1 THEN
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue