Browse Source

增加楼宇facility字段

jwy
review512jwy@163.com 4 hours ago
parent
commit
9f6af042ae
  1. 69
      data-center-business-dao/src/main/java/com/techsor/datacenter/business/dao/auto/BasicFacilityMapper.java
  2. 222
      data-center-business-dao/src/main/resources/mappers/auto/BasicFacilityMapper.xml
  3. 6
      data-center-business-dao/src/main/resources/mappers/ex/BasicFacilityMapperExt.xml
  4. 5
      data-center-business-dao/src/main/resources/mybatis-generator/generatorConfig.xml
  5. 11
      data-center-business-model/src/main/java/com/techsor/datacenter/business/dto/facility/FacilityAddParam.java
  6. 11
      data-center-business-model/src/main/java/com/techsor/datacenter/business/dto/facility/FacilityEditParam.java
  7. 944
      data-center-business-model/src/main/java/com/techsor/datacenter/business/model/BasicFacility.java
  8. 2530
      data-center-business-model/src/main/java/com/techsor/datacenter/business/model/BasicFacilityExample.java
  9. 11
      data-center-business-model/src/main/java/com/techsor/datacenter/business/vo/facility/FacilityPageVO.java
  10. 8
      data-center-business-service/src/main/java/com/techsor/datacenter/business/service/impl/FacilityServiceImpl.java

69
data-center-business-dao/src/main/java/com/techsor/datacenter/business/dao/auto/BasicFacilityMapper.java

@ -6,26 +6,91 @@ import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface BasicFacilityMapper {
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table basic_facility
*
* @mbg.generated
*/
long countByExample(BasicFacilityExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table basic_facility
*
* @mbg.generated
*/
int deleteByExample(BasicFacilityExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table basic_facility
*
* @mbg.generated
*/
int deleteByPrimaryKey(Long facilityId);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table basic_facility
*
* @mbg.generated
*/
int insert(BasicFacility record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table basic_facility
*
* @mbg.generated
*/
int insertSelective(BasicFacility record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table basic_facility
*
* @mbg.generated
*/
List<BasicFacility> selectByExample(BasicFacilityExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table basic_facility
*
* @mbg.generated
*/
BasicFacility selectByPrimaryKey(Long facilityId);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table basic_facility
*
* @mbg.generated
*/
int updateByExampleSelective(@Param("record") BasicFacility record, @Param("example") BasicFacilityExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table basic_facility
*
* @mbg.generated
*/
int updateByExample(@Param("record") BasicFacility record, @Param("example") BasicFacilityExample example);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table basic_facility
*
* @mbg.generated
*/
int updateByPrimaryKeySelective(BasicFacility record);
/**
* This method was generated by MyBatis Generator.
* This method corresponds to the database table basic_facility
*
* @mbg.generated
*/
int updateByPrimaryKey(BasicFacility record);
}
}

222
data-center-business-dao/src/main/resources/mappers/auto/BasicFacilityMapper.xml

@ -1,8 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.techsor.datacenter.business.dao.auto.BasicFacilityMapper">
<resultMap id="BaseResultMap" type="com.techsor.datacenter.business.model.BasicFacility">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
<id column="facility_id" jdbcType="BIGINT" property="facilityId" />
<result column="building_id" jdbcType="BIGINT" property="buildingId" />
<result column="company_id" jdbcType="BIGINT" property="companyId" />
@ -33,9 +36,16 @@
<result column="creator_id" jdbcType="BIGINT" property="creatorId" />
<result column="modify_time" jdbcType="BIGINT" property="modifyTime" />
<result column="modifier_id" jdbcType="BIGINT" property="modifierId" />
<result column="security_start_time" jdbcType="VARCHAR" property="securityStartTime" />
<result column="security_end_time" jdbcType="VARCHAR" property="securityEndTime" />
<result column="resident_direct_tel" jdbcType="VARCHAR" property="residentDirectTel" />
<result column="equipment_staff_tel" jdbcType="VARCHAR" property="equipmentStaffTel" />
</resultMap>
<sql id="Example_Where_Clause">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
<where>
<foreach collection="oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
@ -64,8 +74,11 @@
</foreach>
</where>
</sql>
<sql id="Update_By_Example_Where_Clause">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
<where>
<foreach collection="example.oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
@ -94,21 +107,29 @@
</foreach>
</where>
</sql>
<sql id="Base_Column_List">
facility_id, building_id, company_id, security_company_name, machine_security_company,
machine_security_tel, machine_security_customer_code, night_shift_type, night_guard_count,
security_switch_time, security_phs, mall_security_tel, facility_side_type, ad_direct_tel,
alarm_reception_note, escalation_flow, contract_start_date, open_date, contract_end_date,
legacy_address, legacy_property_flag, name_change_history, communication_info, nap_time,
note_updated_by, flag, create_time, creator_id, modify_time, modifier_id
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
facility_id, building_id, company_id, security_company_name, machine_security_company,
machine_security_tel, machine_security_customer_code, night_shift_type, night_guard_count,
security_switch_time, security_phs, mall_security_tel, facility_side_type, ad_direct_tel,
alarm_reception_note, escalation_flow, contract_start_date, open_date, contract_end_date,
legacy_address, legacy_property_flag, name_change_history, communication_info, nap_time,
note_updated_by, flag, create_time, creator_id, modify_time, modifier_id, security_start_time,
security_end_time, resident_direct_tel, equipment_staff_tel
</sql>
<select id="selectByExample" resultMap="BaseResultMap">
<select id="selectByExample" parameterType="com.techsor.datacenter.business.model.BasicFacilityExample" resultMap="BaseResultMap">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
select
<if test="distinct">
distinct
</if>
'true' as QUERYID,
<include refid="Base_Column_List" />
from basic_facility
<if test="_parameter != null">
@ -118,50 +139,71 @@
order by ${orderByClause}
</if>
</select>
<select id="selectByPrimaryKey" resultMap="BaseResultMap">
select
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
select
<include refid="Base_Column_List" />
from basic_facility
where facility_id = #{facilityId,jdbcType=BIGINT}
</select>
<delete id="deleteByPrimaryKey">
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
delete from basic_facility
where facility_id = #{facilityId,jdbcType=BIGINT}
</delete>
<delete id="deleteByExample">
<delete id="deleteByExample" parameterType="com.techsor.datacenter.business.model.BasicFacilityExample">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
delete from basic_facility
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="com.techsor.datacenter.business.model.BasicFacility">
insert into basic_facility (facility_id, building_id, company_id,
security_company_name, machine_security_company, machine_security_tel,
machine_security_customer_code, night_shift_type, night_guard_count,
security_switch_time, security_phs, mall_security_tel,
facility_side_type, ad_direct_tel, alarm_reception_note,
escalation_flow, contract_start_date, open_date,
contract_end_date, legacy_address, legacy_property_flag,
name_change_history, communication_info, nap_time,
note_updated_by, flag, create_time,
creator_id, modify_time, modifier_id)
values (#{facilityId,jdbcType=BIGINT}, #{buildingId,jdbcType=BIGINT}, #{companyId,jdbcType=BIGINT},
#{securityCompanyName,jdbcType=VARCHAR}, #{machineSecurityCompany,jdbcType=VARCHAR}, #{machineSecurityTel,jdbcType=VARCHAR},
#{machineSecurityCustomerCode,jdbcType=VARCHAR}, #{nightShiftType,jdbcType=VARCHAR}, #{nightGuardCount,jdbcType=INTEGER},
#{securitySwitchTime,jdbcType=VARCHAR}, #{securityPhs,jdbcType=VARCHAR}, #{mallSecurityTel,jdbcType=VARCHAR},
#{facilitySideType,jdbcType=VARCHAR}, #{adDirectTel,jdbcType=VARCHAR}, #{alarmReceptionNote,jdbcType=VARCHAR},
#{escalationFlow,jdbcType=VARCHAR}, #{contractStartDate,jdbcType=DATE}, #{openDate,jdbcType=DATE},
#{contractEndDate,jdbcType=DATE}, #{legacyAddress,jdbcType=VARCHAR}, #{legacyPropertyFlag,jdbcType=TINYINT},
#{nameChangeHistory,jdbcType=VARCHAR}, #{communicationInfo,jdbcType=VARCHAR}, #{napTime,jdbcType=VARCHAR},
#{noteUpdatedBy,jdbcType=VARCHAR}, #{flag,jdbcType=INTEGER}, #{createTime,jdbcType=BIGINT},
#{creatorId,jdbcType=BIGINT}, #{modifyTime,jdbcType=BIGINT}, #{modifierId,jdbcType=BIGINT})
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
insert into basic_facility (facility_id, building_id, company_id,
security_company_name, machine_security_company,
machine_security_tel, machine_security_customer_code,
night_shift_type, night_guard_count, security_switch_time,
security_phs, mall_security_tel, facility_side_type,
ad_direct_tel, alarm_reception_note, escalation_flow,
contract_start_date, open_date, contract_end_date,
legacy_address, legacy_property_flag, name_change_history,
communication_info, nap_time, note_updated_by,
flag, create_time, creator_id,
modify_time, modifier_id, security_start_time,
security_end_time, resident_direct_tel, equipment_staff_tel
)
values (#{facilityId,jdbcType=BIGINT}, #{buildingId,jdbcType=BIGINT}, #{companyId,jdbcType=BIGINT},
#{securityCompanyName,jdbcType=VARCHAR}, #{machineSecurityCompany,jdbcType=VARCHAR},
#{machineSecurityTel,jdbcType=VARCHAR}, #{machineSecurityCustomerCode,jdbcType=VARCHAR},
#{nightShiftType,jdbcType=VARCHAR}, #{nightGuardCount,jdbcType=INTEGER}, #{securitySwitchTime,jdbcType=VARCHAR},
#{securityPhs,jdbcType=VARCHAR}, #{mallSecurityTel,jdbcType=VARCHAR}, #{facilitySideType,jdbcType=VARCHAR},
#{adDirectTel,jdbcType=VARCHAR}, #{alarmReceptionNote,jdbcType=VARCHAR}, #{escalationFlow,jdbcType=VARCHAR},
#{contractStartDate,jdbcType=DATE}, #{openDate,jdbcType=DATE}, #{contractEndDate,jdbcType=DATE},
#{legacyAddress,jdbcType=VARCHAR}, #{legacyPropertyFlag,jdbcType=TINYINT}, #{nameChangeHistory,jdbcType=VARCHAR},
#{communicationInfo,jdbcType=VARCHAR}, #{napTime,jdbcType=VARCHAR}, #{noteUpdatedBy,jdbcType=VARCHAR},
#{flag,jdbcType=INTEGER}, #{createTime,jdbcType=BIGINT}, #{creatorId,jdbcType=BIGINT},
#{modifyTime,jdbcType=BIGINT}, #{modifierId,jdbcType=BIGINT}, #{securityStartTime,jdbcType=VARCHAR},
#{securityEndTime,jdbcType=VARCHAR}, #{residentDirectTel,jdbcType=VARCHAR}, #{equipmentStaffTel,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.techsor.datacenter.business.model.BasicFacility">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
insert into basic_facility
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="facilityId != null">
@ -254,6 +296,18 @@
<if test="modifierId != null">
modifier_id,
</if>
<if test="securityStartTime != null">
security_start_time,
</if>
<if test="securityEndTime != null">
security_end_time,
</if>
<if test="residentDirectTel != null">
resident_direct_tel,
</if>
<if test="equipmentStaffTel != null">
equipment_staff_tel,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="facilityId != null">
@ -346,17 +400,35 @@
<if test="modifierId != null">
#{modifierId,jdbcType=BIGINT},
</if>
<if test="securityStartTime != null">
#{securityStartTime,jdbcType=VARCHAR},
</if>
<if test="securityEndTime != null">
#{securityEndTime,jdbcType=VARCHAR},
</if>
<if test="residentDirectTel != null">
#{residentDirectTel,jdbcType=VARCHAR},
</if>
<if test="equipmentStaffTel != null">
#{equipmentStaffTel,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<select id="countByExample" resultType="java.lang.Long">
<select id="countByExample" parameterType="com.techsor.datacenter.business.model.BasicFacilityExample" resultType="java.lang.Long">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
select count(*) from basic_facility
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</select>
<update id="updateByExampleSelective">
<update id="updateByExampleSelective" parameterType="map">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
update basic_facility
<set>
<if test="record.facilityId != null">
@ -449,13 +521,28 @@
<if test="record.modifierId != null">
modifier_id = #{record.modifierId,jdbcType=BIGINT},
</if>
<if test="record.securityStartTime != null">
security_start_time = #{record.securityStartTime,jdbcType=VARCHAR},
</if>
<if test="record.securityEndTime != null">
security_end_time = #{record.securityEndTime,jdbcType=VARCHAR},
</if>
<if test="record.residentDirectTel != null">
resident_direct_tel = #{record.residentDirectTel,jdbcType=VARCHAR},
</if>
<if test="record.equipmentStaffTel != null">
equipment_staff_tel = #{record.equipmentStaffTel,jdbcType=VARCHAR},
</if>
</set>
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByExample">
<update id="updateByExample" parameterType="map">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
update basic_facility
set facility_id = #{record.facilityId,jdbcType=BIGINT},
building_id = #{record.buildingId,jdbcType=BIGINT},
@ -486,13 +573,20 @@
create_time = #{record.createTime,jdbcType=BIGINT},
creator_id = #{record.creatorId,jdbcType=BIGINT},
modify_time = #{record.modifyTime,jdbcType=BIGINT},
modifier_id = #{record.modifierId,jdbcType=BIGINT}
modifier_id = #{record.modifierId,jdbcType=BIGINT},
security_start_time = #{record.securityStartTime,jdbcType=VARCHAR},
security_end_time = #{record.securityEndTime,jdbcType=VARCHAR},
resident_direct_tel = #{record.residentDirectTel,jdbcType=VARCHAR},
equipment_staff_tel = #{record.equipmentStaffTel,jdbcType=VARCHAR}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective">
<update id="updateByPrimaryKeySelective" parameterType="com.techsor.datacenter.business.model.BasicFacility">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
update basic_facility
<set>
<if test="buildingId != null">
@ -582,11 +676,26 @@
<if test="modifierId != null">
modifier_id = #{modifierId,jdbcType=BIGINT},
</if>
<if test="securityStartTime != null">
security_start_time = #{securityStartTime,jdbcType=VARCHAR},
</if>
<if test="securityEndTime != null">
security_end_time = #{securityEndTime,jdbcType=VARCHAR},
</if>
<if test="residentDirectTel != null">
resident_direct_tel = #{residentDirectTel,jdbcType=VARCHAR},
</if>
<if test="equipmentStaffTel != null">
equipment_staff_tel = #{equipmentStaffTel,jdbcType=VARCHAR},
</if>
</set>
where facility_id = #{facilityId,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKey">
<update id="updateByPrimaryKey" parameterType="com.techsor.datacenter.business.model.BasicFacility">
<!--
WARNING - @mbg.generated
This element is automatically generated by MyBatis Generator, do not modify.
-->
update basic_facility
set building_id = #{buildingId,jdbcType=BIGINT},
company_id = #{companyId,jdbcType=BIGINT},
@ -616,8 +725,11 @@
create_time = #{createTime,jdbcType=BIGINT},
creator_id = #{creatorId,jdbcType=BIGINT},
modify_time = #{modifyTime,jdbcType=BIGINT},
modifier_id = #{modifierId,jdbcType=BIGINT}
modifier_id = #{modifierId,jdbcType=BIGINT},
security_start_time = #{securityStartTime,jdbcType=VARCHAR},
security_end_time = #{securityEndTime,jdbcType=VARCHAR},
resident_direct_tel = #{residentDirectTel,jdbcType=VARCHAR},
equipment_staff_tel = #{equipmentStaffTel,jdbcType=VARCHAR}
where facility_id = #{facilityId,jdbcType=BIGINT}
</update>
</mapper>
</mapper>

6
data-center-business-dao/src/main/resources/mappers/ex/BasicFacilityMapperExt.xml

@ -29,7 +29,11 @@
bf.name_change_history as nameChangeHistory,
bf.communication_info as communicationInfo,
bf.nap_time as napTime,
bf.note_updated_by as noteUpdatedBy
bf.note_updated_by as noteUpdatedBy,
bf.security_start_time as securityStartTime,
bf.security_end_time as securityEndTime,
bf.resident_direct_tel as residentDirectTel,
bf.equipment_staff_tel as equipmentStaffTel
from
basic_facility bf
left join basic_building bb on bf.building_id = bb.building_id

5
data-center-business-dao/src/main/resources/mybatis-generator/generatorConfig.xml

@ -354,5 +354,10 @@
<property name="useActualColumnNames" value="false" />
</table>
<!-- <table tableName="basic_facility" domainObjectName="BasicFacility" enableCountByExample="true" enableUpdateByExample="true" enableDeleteByExample="true" enableSelectByExample="true" selectByExampleQueryId="true">-->
<!-- <property name="useActualColumnNames" value="false" />-->
<!-- <generatedKey column="id" sqlStatement="Mysql" identity="true" />-->
<!-- </table>-->
</context>
</generatorConfiguration>

11
data-center-business-model/src/main/java/com/techsor/datacenter/business/dto/facility/FacilityAddParam.java

@ -74,4 +74,15 @@ public class FacilityAddParam {
@Schema(description = "记载者/更新日", example = "张三")
private String noteUpdatedBy;
private String securityStartTime;
/** 警备结束 */
private String securityEndTime;
/** 常驻直通TEL */
private String residentDirectTel;
/** 設備員TEL */
private String equipmentStaffTel;
}

11
data-center-business-model/src/main/java/com/techsor/datacenter/business/dto/facility/FacilityEditParam.java

@ -77,4 +77,15 @@ public class FacilityEditParam {
@Schema(description = "记载者/更新日", example = "张三")
private String noteUpdatedBy;
private String securityStartTime;
/** 警备结束 */
private String securityEndTime;
/** 常驻直通TEL */
private String residentDirectTel;
/** 設備員TEL */
private String equipmentStaffTel;
}

944
data-center-business-model/src/main/java/com/techsor/datacenter/business/model/BasicFacility.java

File diff suppressed because it is too large

2530
data-center-business-model/src/main/java/com/techsor/datacenter/business/model/BasicFacilityExample.java

File diff suppressed because it is too large

11
data-center-business-model/src/main/java/com/techsor/datacenter/business/vo/facility/FacilityPageVO.java

@ -83,4 +83,15 @@ public class FacilityPageVO {
@Schema(description = "记载者/更新日")
private String noteUpdatedBy;
private String securityStartTime;
/** 警备结束 */
private String securityEndTime;
/** 常驻直通TEL */
private String residentDirectTel;
/** 設備員TEL */
private String equipmentStaffTel;
}

8
data-center-business-service/src/main/java/com/techsor/datacenter/business/service/impl/FacilityServiceImpl.java

@ -79,6 +79,10 @@ public class FacilityServiceImpl implements FacilityService {
insertObj.setAdDirectTel(param.getAdDirectTel());
insertObj.setAlarmReceptionNote(param.getAlarmReceptionNote());
insertObj.setEscalationFlow(param.getEscalationFlow());
insertObj.setSecurityStartTime(param.getSecurityStartTime());
insertObj.setSecurityEndTime(param.getSecurityEndTime());
insertObj.setResidentDirectTel(param.getResidentDirectTel());
insertObj.setEquipmentStaffTel(param.getEquipmentStaffTel());
if (StringUtils.isNotBlank(param.getContractStartDate())) {
try {
insertObj.setContractStartDate(DATE_FORMAT.parse(param.getContractStartDate()));
@ -159,6 +163,10 @@ public class FacilityServiceImpl implements FacilityService {
updateObj.setAdDirectTel(param.getAdDirectTel());
updateObj.setAlarmReceptionNote(param.getAlarmReceptionNote());
updateObj.setEscalationFlow(param.getEscalationFlow());
updateObj.setSecurityStartTime(param.getSecurityStartTime());
updateObj.setSecurityEndTime(param.getSecurityEndTime());
updateObj.setResidentDirectTel(param.getResidentDirectTel());
updateObj.setEquipmentStaffTel(param.getEquipmentStaffTel());
if (StringUtils.isNotBlank(param.getContractStartDate())) {
try {
updateObj.setContractStartDate(DATE_FORMAT.parse(param.getContractStartDate()));

Loading…
Cancel
Save