Commit dea4a31a authored by kongfm's avatar kongfm

更新FLC相关代码

parent ebb9d743
......@@ -36,4 +36,10 @@ public class UnitInfoApproveDto extends BaseDto {
@ApiModelProperty(value = "0 注册审批 1 变更审批")
private Integer approveType;
@ApiModelProperty(value = "企业入驻时间")
private Date approvedTime;
@ApiModelProperty(value = "提交时间")
private Date submitTime;
}
......@@ -142,10 +142,10 @@ public class UnitInfoDto extends BaseDto {
private Boolean isChange;
@ApiModelProperty(value = "提交时间开始")
private Date submitTimeStart ;
private String submitTimeStart ;
@ApiModelProperty(value = "接警时间结束")
private Date submitTimeEnd ;
@ApiModelProperty(value = "提交时间结束")
private String submitTimeEnd ;
@ApiModelProperty(value = "分类名称")
private String typeStr;
......@@ -156,6 +156,13 @@ public class UnitInfoDto extends BaseDto {
@ApiModelProperty(value = "企业二维码")
private List<AttachmentDto> qrcode;
@ApiModelProperty(value = "详细地址全部")
private String fullAddress;
@ApiModelProperty(value = "企业入驻时间")
private Date approvedTime;
@ApiModelProperty(value = "提交时间")
private Date submitTime;
}
......@@ -245,4 +245,16 @@ public class UnitInfo extends BaseEntity {
@TableField(value = "is_change")
private Boolean isChange;
/**
* 企业入驻时间
*/
@TableField("approved_time")
private Date approvedTime;
/**
* 提交时间
*/
@TableField("submit_time")
private Date submitTime;
}
......@@ -214,4 +214,17 @@ public class UnitInfoChange extends BaseEntity {
@TableField("unit_status")
private Integer unitStatus;
/**
* 企业入驻时间
*/
@TableField("approved_time")
private Date approvedTime;
/**
* 提交时间
*/
@TableField("submit_time")
private Date submitTime;
}
......@@ -265,6 +265,8 @@ public class BeanDtoVoUtils {
} else if(2 == item.getUnitStatus()) {
target.setStatusStr("已驳回");
}
target.setFullAddress(item.getProvince() + item.getCity() + item.getDistrict() + item.getStree() + item.getCommunity() + item.getAddress());
return target;
} catch (Exception e) {
return null;
......
......@@ -295,7 +295,7 @@ public class UnitInfoController extends BaseController {
queryWrapper.orderByDesc(RedisKey.humpToLine(date[0]));
}
}else {
queryWrapper.orderByDesc("rec_date");
queryWrapper.orderByDesc("submit_time");
}
if (!ValidationUtil.isEmpty(unitInfoDto.getIsChange())) { // 分类 注册 / 信息变更 0 注册 1 变更
......@@ -304,11 +304,11 @@ public class UnitInfoController extends BaseController {
}
if(!ValidationUtil.isEmpty(unitInfoDto.getSubmitTimeStart())) { // 提交时间
queryWrapper.ge("rec_date",unitInfoDto.getSubmitTimeStart());
queryWrapper.ge("submit_time",unitInfoDto.getSubmitTimeStart());
}
if(!ValidationUtil.isEmpty(unitInfoDto.getSubmitTimeEnd())) { // 提交时间
queryWrapper.le("rec_date",unitInfoDto.getSubmitTimeEnd());
queryWrapper.le("submit_time",unitInfoDto.getSubmitTimeEnd());
}
if(!ValidationUtil.isEmpty(unitInfoDto.getUnitTypeCode())) { // 单位类型
......@@ -330,6 +330,16 @@ public class UnitInfoController extends BaseController {
if(!ValidationUtil.isEmpty(unitInfoDto.getUnitStatus())) { // 审核状态
queryWrapper.like("unit_status",unitInfoDto.getUnitStatus());
}
if(!ValidationUtil.isEmpty(unitInfoDto.getLegalPerson())) { // 法人
queryWrapper.like("legal_person",unitInfoDto.getLegalPerson());
}
if(!ValidationUtil.isEmpty(unitInfoDto.getLegalPersonTel())) { // 法人电话
queryWrapper.like("legal_person_tel",unitInfoDto.getLegalPersonTel());
}
return queryWrapper;
}
......
......@@ -40,6 +40,7 @@ import org.typroject.tyboot.core.rdbms.service.BaseService;
import org.typroject.tyboot.core.restful.exception.instance.BadRequest;
import java.util.ArrayList;
import java.util.Date;
import java.util.HashMap;
import java.util.HashSet;
import java.util.List;
......@@ -86,6 +87,7 @@ public class UnitInfoServiceImpl extends BaseService<UnitInfoDto, UnitInfo, Unit
public UnitInfoDto saveUnitInfo(UnitInfoDto model) {
tzsAuthServiceImpl.setRequestContext();
model.setUnitStatus(0);// 设置为待审核状态
model.setSubmitTime(new Date()); // 提交时间
model.setIsChange(false);// 新增状态不是变更状态
// 处理单位类型
String unitTypeCode = model.getUnitTypeCode();
......@@ -161,7 +163,7 @@ public class UnitInfoServiceImpl extends BaseService<UnitInfoDto, UnitInfo, Unit
} else { // 如果是审批单 创建用户 创建组织机构 赋权等
sourceUnit.setApprovedTime(new Date());
// 创建用户 创建组织机构 平台组织机构及 org_user表中 赋权
String adminUserName = sourceUnit.getAdminName();
String loginName = sourceUnit.getAdminLoginName();
......@@ -240,6 +242,9 @@ public class UnitInfoServiceImpl extends BaseService<UnitInfoDto, UnitInfo, Unit
org.setBizOrgCode(TreeParser.genTreeCode());
org.setBizOrgType(CommonConstant.BIZ_ORG_TYPE_COMPANY);
org.setBizOrgName(sourceUnit.getOrgName());
org.setRecDate(new Date());
org.setRecUserId(userResult.getResult().getUserId());
org.setRecUserName(userResult.getResult().getUserName());
if(!iOrgUsrService.save(org)) {
throw new BadRequest("org单位注册失败");
}
......@@ -314,6 +319,7 @@ public class UnitInfoServiceImpl extends BaseService<UnitInfoDto, UnitInfo, Unit
}
}
target.setFullAddress(source.getProvince() + source.getCity() + source.getDistrict() + source.getStree() + source.getCommunity() + source.getAddress());
return target;
}
......@@ -342,7 +348,7 @@ public class UnitInfoServiceImpl extends BaseService<UnitInfoDto, UnitInfo, Unit
}
}
target.setFullAddress(source.getProvince() + source.getCity() + source.getDistrict() + source.getStree() + source.getCommunity() + source.getAddress());
return target;
}
......
......@@ -105,10 +105,7 @@
<changeSet author="kongfm" id="2021-11-17-01">
<preConditions onFail="MARK_RAN">
<tableExists tableName="cb_data_dictionary"/>
<not>
<primaryKeyExists primaryKeyName="sequence_nbr" tableName="cb_data_dictionary"/>
</not>
</preConditions>
<comment>add data_dictionary </comment>
<sql>
......@@ -143,7 +140,9 @@
<changeSet author="kongfm" id="2021-11-17-02">
<preConditions onFail="MARK_RAN">
<tableExists tableName="tz_flc_unit_info"/>
<not>
<tableExists tableName="tz_flc_unit_info"/>
</not>
</preConditions>
<comment>add tz_flc_unit_info table</comment>
<sql>
......@@ -190,6 +189,8 @@
`rec_date` datetime NULL DEFAULT NULL COMMENT '更新时间',
`is_delete` bit(1) NULL DEFAULT b'0' COMMENT '是否删除(0:未删除,1:已删除)',
`is_change` bit(1) NULL DEFAULT NULL COMMENT '是否变更(0:未变更,1:变更中)',
`approved_time` datetime NULL DEFAULT NULL COMMENT '企业入驻时间',
`submit_time` datetime NULL DEFAULT NULL COMMENT '提交时间',
PRIMARY KEY (`sequence_nbr`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 1460504125366816771 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '企业信息表' ROW_FORMAT = Dynamic;
</sql>
......@@ -197,7 +198,9 @@
<changeSet author="kongfm" id="2021-11-17-03">
<preConditions onFail="MARK_RAN">
<not>
<tableExists tableName="tz_flc_unit_info_approve"/>
</not>
</preConditions>
<comment>add tz_flc_unit_info_approve table</comment>
<sql>
......@@ -219,7 +222,9 @@
<changeSet author="kongfm" id="2021-11-17-04">
<preConditions onFail="MARK_RAN">
<not>
<tableExists tableName="tz_flc_unit_info_change"/>
</not>
</preConditions>
<comment>add tz_flc_unit_info_change table</comment>
<sql>
......@@ -261,6 +266,8 @@
`rec_date` datetime NULL DEFAULT NULL COMMENT '更新时间',
`is_delete` bit(1) NULL DEFAULT b'0' COMMENT '是否删除(0:未删除,1:已删除)',
`organization_code` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '组织机构编码',
`approved_time` datetime NULL DEFAULT NULL COMMENT '企业入驻时间',
`submit_time` datetime NULL DEFAULT NULL COMMENT '提交时间',
PRIMARY KEY (`sequence_nbr`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 1458311353490657283 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '企业信息变更表' ROW_FORMAT = Dynamic;
</sql>
......
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