| @@ -0,0 +1,71 @@ | |||
| package com.iformall.domain.po; | |||
| import com.baomidou.mybatisplus.annotation.TableField; | |||
| import com.baomidou.mybatisplus.annotation.TableName; | |||
| import com.iformall.domain.po.base.TenantEntity; | |||
| import com.iformall.enums.EnumFeesShopTimeType; | |||
| import com.iformall.enums.EnumRentContractAgilPriceUnit; | |||
| import com.iformall.enums.EnumRentContractAgilSettingMethod; | |||
| import com.iformall.enums.EnumRentContractAgilTimeUnit; | |||
| import lombok.Data; | |||
| import lombok.EqualsAndHashCode; | |||
| import lombok.ToString; | |||
| import java.util.Date; | |||
| import java.util.List; | |||
| /** | |||
| */ | |||
| @TableName(value = "wx_rent_contract_agile_renevue") | |||
| @Data | |||
| @ToString(callSuper = true) | |||
| @EqualsAndHashCode(callSuper = true) | |||
| public class WxRentContractAgileRenevue extends TenantEntity { | |||
| private static final long serialVersionUID = 7009117540201976664L; | |||
| @io.swagger.annotations.ApiModelProperty(value="id",name="id") | |||
| private Long id; | |||
| @io.swagger.annotations.ApiModelProperty(value="合同编号",name="rentContractId") | |||
| private Long rentContractId; | |||
| @io.swagger.annotations.ApiModelProperty(value="计费周期",name="timePeriod") | |||
| private Integer timePeriod; | |||
| @io.swagger.annotations.ApiModelProperty(value="计费周期单位EnumRentContractAgilTimeUnit",name="timeUnit") | |||
| private Integer timeUnit; | |||
| @TableField(exist = false) | |||
| private String timeUnitName; | |||
| public String getTimeUnitName() { | |||
| if (null != timeUnit) { | |||
| return EnumRentContractAgilTimeUnit.getEnum(timeUnit).getMessage(); | |||
| } | |||
| return null; | |||
| } | |||
| @io.swagger.annotations.ApiModelProperty(value="收费周期",name="calcuteTime") | |||
| private Integer calcuteTime; | |||
| @io.swagger.annotations.ApiModelProperty(value="费用生成规则EnumFeesShopTimeType",name="feesCreateRule") | |||
| private Integer feesCreateRule; | |||
| @TableField(exist = false) | |||
| private String feesCreateRuleName; | |||
| public String getFeesCreateRuleName() { | |||
| if (null != feesCreateRule) { | |||
| return EnumFeesShopTimeType.getEnum(feesCreateRule).getMessage(); | |||
| } | |||
| return null; | |||
| } | |||
| @io.swagger.annotations.ApiModelProperty(value="createTime",name="createTime") | |||
| private Date createtime; | |||
| @io.swagger.annotations.ApiModelProperty(value="updateTime",name="updateTime") | |||
| private Date updatetime; | |||
| @TableField(exist = false) | |||
| private List<WxRentContractAgileUnDepositItem> items; | |||
| } | |||
| @@ -0,0 +1,45 @@ | |||
| package com.iformall.domain.po; | |||
| import com.baomidou.mybatisplus.annotation.TableField; | |||
| import com.baomidou.mybatisplus.annotation.TableName; | |||
| import com.iformall.domain.po.base.TenantEntity; | |||
| import com.iformall.enums.EnumFeesShopTimeType; | |||
| import com.iformall.enums.EnumRentContractAgilPriceUnit; | |||
| import com.iformall.enums.EnumRentContractAgilSettingMethod; | |||
| import com.iformall.enums.EnumRentContractAgilTimeUnit; | |||
| import lombok.Data; | |||
| import lombok.EqualsAndHashCode; | |||
| import lombok.ToString; | |||
| import java.util.Date; | |||
| import java.util.List; | |||
| /** | |||
| */ | |||
| @TableName(value = "wx_rent_contract_agile_renevue_fees") | |||
| @Data | |||
| @ToString(callSuper = true) | |||
| @EqualsAndHashCode(callSuper = true) | |||
| public class WxRentContractAgileRenevueFees extends TenantEntity { | |||
| private static final long serialVersionUID = 7009117540201976664L; | |||
| @io.swagger.annotations.ApiModelProperty(value="id",name="id") | |||
| private Long id; | |||
| @io.swagger.annotations.ApiModelProperty(value="合同编号",name="rentContractId") | |||
| private Long rentContractId; | |||
| @io.swagger.annotations.ApiModelProperty(value="WxRentContractAgileRenevue编号",name="agileRenevueId") | |||
| private Long agileRenevueId; | |||
| @io.swagger.annotations.ApiModelProperty(value="createTime",name="createTime") | |||
| private Date createtime; | |||
| @io.swagger.annotations.ApiModelProperty(value="updateTime",name="updateTime") | |||
| private Date updatetime; | |||
| @io.swagger.annotations.ApiModelProperty(value="占比比率%,默认100",name="rate") | |||
| private String rate; | |||
| } | |||
| @@ -0,0 +1,57 @@ | |||
| package com.iformall.domain.po; | |||
| import com.baomidou.mybatisplus.annotation.TableField; | |||
| import com.baomidou.mybatisplus.annotation.TableName; | |||
| import com.iformall.domain.po.base.TenantEntity; | |||
| import com.iformall.enums.EnumFeesShopTimeType; | |||
| import com.iformall.enums.EnumRentContractAgilPriceUnit; | |||
| import com.iformall.enums.EnumRentContractAgilSettingMethod; | |||
| import com.iformall.enums.EnumRentContractAgilTimeUnit; | |||
| import lombok.Data; | |||
| import lombok.EqualsAndHashCode; | |||
| import lombok.ToString; | |||
| import java.util.Date; | |||
| import java.util.List; | |||
| /** | |||
| */ | |||
| @TableName(value = "wx_rent_contract_agile_renevue_item") | |||
| @Data | |||
| @ToString(callSuper = true) | |||
| @EqualsAndHashCode(callSuper = true) | |||
| public class WxRentContractAgileRenevueItem extends TenantEntity { | |||
| private static final long serialVersionUID = 7009117540201976664L; | |||
| @io.swagger.annotations.ApiModelProperty(value="id",name="id") | |||
| private Long id; | |||
| @io.swagger.annotations.ApiModelProperty(value="合同编号",name="rentContractId") | |||
| private Long rentContractId; | |||
| @io.swagger.annotations.ApiModelProperty(value="费用编号",name="renevueId") | |||
| private Long renevueId; | |||
| @io.swagger.annotations.ApiModelProperty(value="beginTime",name="beginTime") | |||
| private Date beginTime; | |||
| @io.swagger.annotations.ApiModelProperty(value="endTime",name="endTime") | |||
| private Date endTime; | |||
| @io.swagger.annotations.ApiModelProperty(value="抽成比率%",name="rate") | |||
| private String rate; | |||
| @io.swagger.annotations.ApiModelProperty(value="createTime",name="createTime") | |||
| private Date createtime; | |||
| @io.swagger.annotations.ApiModelProperty(value="updateTime",name="updateTime") | |||
| private Date updatetime; | |||
| @io.swagger.annotations.ApiModelProperty(value="是否免租期",name="isFree") | |||
| private Integer isFree; | |||
| @io.swagger.annotations.ApiModelProperty(value="页面用的字段",name="isFree") | |||
| private Integer isFather; | |||
| } | |||
| @@ -46,20 +46,6 @@ public class WxRentContractAgileUnDeposit extends TenantEntity { | |||
| @TableField(exist = false) | |||
| private String feesName; | |||
| @io.swagger.annotations.ApiModelProperty(value="单价",name="price") | |||
| private String price; | |||
| @io.swagger.annotations.ApiModelProperty(value="单价单位EnumRentContractAgilPriceUnit",name="priceUnit") | |||
| private Integer priceUnit; | |||
| @TableField(exist = false) | |||
| private String priceUnitName; | |||
| public String getPriceUnitName() { | |||
| if (null != priceUnit) { | |||
| return EnumRentContractAgilPriceUnit.getEnum(priceUnit).getMessage(); | |||
| } | |||
| return null; | |||
| } | |||
| @io.swagger.annotations.ApiModelProperty(value="计费周期",name="timePeriod") | |||
| private Integer timePeriod; | |||
| @@ -0,0 +1,20 @@ | |||
| package com.iformall.mapper; | |||
| import com.iformall.common.CommonMapper; | |||
| import com.iformall.domain.po.WxRentContractAgileRenevue; | |||
| import com.iformall.domain.po.WxRentContractAgileRenevueFees; | |||
| import org.apache.ibatis.annotations.Param; | |||
| import java.util.List; | |||
| /** | |||
| */ | |||
| public interface WxRentContractAgileRenevueFeesMapper extends CommonMapper<WxRentContractAgileRenevueFees, Long> { | |||
| List<WxRentContractAgileRenevueFees> findList(WxRentContractAgileRenevueFees wxBillRent); | |||
| WxRentContractAgileRenevueFees selectById(@Param("id")Long id,@Param("tenantId")String tenantId); | |||
| List<Long> findIdList(WxRentContractAgileRenevueFees wxBillRent); | |||
| } | |||
| @@ -0,0 +1,21 @@ | |||
| package com.iformall.mapper; | |||
| import com.iformall.common.CommonMapper; | |||
| import com.iformall.domain.po.WxRentContractAgileRenevueItem; | |||
| import org.apache.ibatis.annotations.Param; | |||
| import java.util.List; | |||
| /** | |||
| */ | |||
| public interface WxRentContractAgileRenevueItemMapper extends CommonMapper<WxRentContractAgileRenevueItem, Long> { | |||
| List<WxRentContractAgileRenevueItem> findList(WxRentContractAgileRenevueItem wxBillRent); | |||
| WxRentContractAgileRenevueItem selectById(@Param("id")Long id,@Param("tenantId")String tenantId); | |||
| List<Long> findIdList(WxRentContractAgileRenevueItem wxBillRent); | |||
| void deleteByUnDeposit(WxRentContractAgileRenevueItem wxBillRent); | |||
| } | |||
| @@ -0,0 +1,19 @@ | |||
| package com.iformall.mapper; | |||
| import com.iformall.common.CommonMapper; | |||
| import com.iformall.domain.po.WxRentContractAgileRenevue; | |||
| import org.apache.ibatis.annotations.Param; | |||
| import java.util.List; | |||
| /** | |||
| */ | |||
| public interface WxRentContractAgileRenevueMapper extends CommonMapper<WxRentContractAgileRenevue, Long> { | |||
| List<WxRentContractAgileRenevue> findList(WxRentContractAgileRenevue wxBillRent); | |||
| WxRentContractAgileRenevue selectById(@Param("id")Long id,@Param("tenantId")String tenantId); | |||
| List<Long> findIdList(WxRentContractAgileRenevue wxBillRent); | |||
| } | |||
| @@ -0,0 +1,60 @@ | |||
| <?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.iformall.mapper.WxRentContractAgileRenevueFeesMapper"> | |||
| <resultMap id="BaseResultMap" type="com.iformall.domain.po.WxRentContractAgileRenevueFees"> | |||
| <id column="id" jdbcType="BIGINT" property="id"/> | |||
| <result column="tenant_id" jdbcType="VARCHAR" property="tenantId"/> | |||
| <result column="parent_tenant_id" jdbcType="VARCHAR" property="parentTenantId" /> | |||
| <result column="rent_contract_id" jdbcType="BIGINT" property="rentContractId"/> | |||
| <result column="agile_renevue_id" jdbcType="BIGINT" property="agileRenevueId"/> | |||
| <result column="createtime" jdbcType="TIMESTAMP" property="createtime"/> | |||
| <result column="updatetime" jdbcType="TIMESTAMP" property="updatetime"/> | |||
| <result column="rate" jdbcType="VARCHAR" property="rate" /> | |||
| </resultMap> | |||
| <sql id="allColumns"> | |||
| `id`,`tenant_id`,`parent_tenant_id`,`rent_contract_id`,`agile_renevue_id`, | |||
| `createtime`,`updatetime`,`rate` | |||
| </sql> | |||
| <sql id="dynamicWhereConditions"> | |||
| where 1=1 | |||
| <if test=" null != id ">and `id` = #{id}</if> | |||
| <if test=" null != tenantId and '' != tenantId"> | |||
| and `tenant_id` = #{tenantId} | |||
| </if> | |||
| <if test=" null != parentTenantId and '' != parentTenantId"> | |||
| and `parent_tenant_id` = #{parentTenantId} | |||
| </if> | |||
| <if test=" null != rentContractId ">and `rent_contract_id` = #{rentContractId}</if> | |||
| <if test=" null != agileRenevueId ">and `agile_renevue_id` = #{agileRenevueId}</if> | |||
| <if test=" null != ids "> | |||
| and id in | |||
| <foreach collection="ids" index="index" item="idItem" open="(" separator="," close=")"> | |||
| #{idItem} | |||
| </foreach> | |||
| </if> | |||
| <if test=" null != sortColumns">order by ${sortColumns}</if> | |||
| </sql> | |||
| <select id="findList" parameterType="com.iformall.domain.po.WxRentContractAgileRenevueFees" resultMap="BaseResultMap"> | |||
| select | |||
| <include refid="allColumns"/> | |||
| from wx_rent_contract_agile_renevue_fees | |||
| <include refid="dynamicWhereConditions"/> | |||
| </select> | |||
| <select id="findIdList" parameterType="com.iformall.domain.po.WxRentContractAgileRenevueFees" resultType="Long"> | |||
| select id | |||
| from wx_rent_contract_agile_renevue_fees | |||
| <include refid="dynamicWhereConditions"/> | |||
| </select> | |||
| <select id="selectById" parameterType="HashMap" resultMap="BaseResultMap"> | |||
| select | |||
| <include refid="allColumns"/> | |||
| from wx_rent_contract_agile_renevue_fees where id = #{id} and `tenant_id` = #{tenantId} | |||
| </select> | |||
| </mapper> | |||
| @@ -0,0 +1,69 @@ | |||
| <?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.iformall.mapper.WxRentContractAgileRenevueItemMapper"> | |||
| <resultMap id="BaseResultMap" type="com.iformall.domain.po.WxRentContractAgileRenevueItem"> | |||
| <id column="id" jdbcType="BIGINT" property="id"/> | |||
| <result column="tenant_id" jdbcType="VARCHAR" property="tenantId"/> | |||
| <result column="parent_tenant_id" jdbcType="VARCHAR" property="parentTenantId" /> | |||
| <result column="rent_contract_id" jdbcType="BIGINT" property="rentContractId"/> | |||
| <result column="renevue_id" jdbcType="BIGINT" property="renevueId"/> | |||
| <result column="begin_time" jdbcType="TIMESTAMP" property="beginTime"/> | |||
| <result column="end_time" jdbcType="TIMESTAMP" property="endTime"/> | |||
| <result column="rate" jdbcType="VARCHAR" property="rate"/> | |||
| <result column="createtime" jdbcType="TIMESTAMP" property="createtime"/> | |||
| <result column="updatetime" jdbcType="TIMESTAMP" property="updatetime"/> | |||
| <result column="is_free" jdbcType="INTEGER" property="isFree"/> | |||
| <result column="is_father" jdbcType="INTEGER" property="isFather"/> | |||
| </resultMap> | |||
| <sql id="allColumns"> | |||
| `id`,`tenant_id`,`parent_tenant_id`,`rent_contract_id`,`renevue_id`,`begin_time`,`end_time`,`rate`, | |||
| `createtime`,`updatetime`,`is_free`,`is_father` | |||
| </sql> | |||
| <sql id="dynamicWhereConditions"> | |||
| where 1=1 | |||
| <if test=" null != id ">and `id` = #{id}</if> | |||
| <if test=" null != tenantId and '' != tenantId"> | |||
| and `tenant_id` = #{tenantId} | |||
| </if> | |||
| <if test=" null != parentTenantId and '' != parentTenantId"> | |||
| and `parent_tenant_id` = #{parentTenantId} | |||
| </if> | |||
| <if test=" null != rentContractId ">and `rent_contract_id` = #{rentContractId}</if> | |||
| <if test=" null != renevueId ">and `renevue_id` = #{renevueId}</if> | |||
| <if test=" null != isFather ">and `is_father` = #{isFather}</if> | |||
| <if test=" null != ids "> | |||
| and id in | |||
| <foreach collection="ids" index="index" item="idItem" open="(" separator="," close=")"> | |||
| #{idItem} | |||
| </foreach> | |||
| </if> | |||
| <if test=" null != sortColumns">order by ${sortColumns}</if> | |||
| </sql> | |||
| <select id="findList" parameterType="com.iformall.domain.po.WxRentContractAgileRenevueItem" resultMap="BaseResultMap"> | |||
| select | |||
| <include refid="allColumns"/> | |||
| from wx_rent_contract_agile_renevue_item | |||
| <include refid="dynamicWhereConditions"/> | |||
| </select> | |||
| <select id="findIdList" parameterType="com.iformall.domain.po.WxRentContractAgileRenevueItem" resultType="Long"> | |||
| select id | |||
| from wx_rent_contract_agile_renevue_item | |||
| <include refid="dynamicWhereConditions"/> | |||
| </select> | |||
| <select id="selectById" parameterType="HashMap" resultMap="BaseResultMap"> | |||
| select | |||
| <include refid="allColumns"/> | |||
| from wx_rent_contract_agile_renevue_item where id = #{id} and `tenant_id` = #{tenantId} | |||
| </select> | |||
| <delete id="deleteByUnDeposit" parameterType="com.iformall.domain.po.WxRentContractAgileRenevueItem"> | |||
| delete from wx_rent_contract_agile_renevue_item where `un_deposit_id` = #{unDepositId} | |||
| </delete> | |||
| </mapper> | |||
| @@ -0,0 +1,61 @@ | |||
| <?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.iformall.mapper.WxRentContractAgileRenevueMapper"> | |||
| <resultMap id="BaseResultMap" type="com.iformall.domain.po.WxRentContractAgileRenevue"> | |||
| <id column="id" jdbcType="BIGINT" property="id"/> | |||
| <result column="tenant_id" jdbcType="VARCHAR" property="tenantId"/> | |||
| <result column="parent_tenant_id" jdbcType="VARCHAR" property="parentTenantId" /> | |||
| <result column="rent_contract_id" jdbcType="BIGINT" property="rentContractId"/> | |||
| <result column="time_period" jdbcType="INTEGER" property="timePeriod"/> | |||
| <result column="time_unit" jdbcType="INTEGER" property="timeUnit"/> | |||
| <result column="calcute_time" jdbcType="INTEGER" property="calcuteTime"/> | |||
| <result column="fees_create_rule" jdbcType="INTEGER" property="feesCreateRule"/> | |||
| <result column="createtime" jdbcType="TIMESTAMP" property="createtime"/> | |||
| <result column="updatetime" jdbcType="TIMESTAMP" property="updatetime"/> | |||
| </resultMap> | |||
| <sql id="allColumns"> | |||
| `id`,`tenant_id`,`parent_tenant_id`,`rent_contract_id`, | |||
| `time_period`,`time_unit`,`calcute_time`,`fees_create_rule`,`createtime`,`updatetime` | |||
| </sql> | |||
| <sql id="dynamicWhereConditions"> | |||
| where 1=1 | |||
| <if test=" null != id ">and `id` = #{id}</if> | |||
| <if test=" null != tenantId and '' != tenantId"> | |||
| and `tenant_id` = #{tenantId} | |||
| </if> | |||
| <if test=" null != parentTenantId and '' != parentTenantId"> | |||
| and `parent_tenant_id` = #{parentTenantId} | |||
| </if> | |||
| <if test=" null != rentContractId ">and `rent_contract_id` = #{rentContractId}</if> | |||
| <if test=" null != ids "> | |||
| and id in | |||
| <foreach collection="ids" index="index" item="idItem" open="(" separator="," close=")"> | |||
| #{idItem} | |||
| </foreach> | |||
| </if> | |||
| <if test=" null != sortColumns">order by ${sortColumns}</if> | |||
| </sql> | |||
| <select id="findList" parameterType="com.iformall.domain.po.WxRentContractAgileRenevue" resultMap="BaseResultMap"> | |||
| select | |||
| <include refid="allColumns"/> | |||
| from wx_rent_contract_agile_renevue | |||
| <include refid="dynamicWhereConditions"/> | |||
| </select> | |||
| <select id="findIdList" parameterType="com.iformall.domain.po.WxRentContractAgileRenevue" resultType="Long"> | |||
| select id | |||
| from wx_rent_contract_agile_renevue | |||
| <include refid="dynamicWhereConditions"/> | |||
| </select> | |||
| <select id="selectById" parameterType="HashMap" resultMap="BaseResultMap"> | |||
| select | |||
| <include refid="allColumns"/> | |||
| from wx_rent_contract_agile_renevue where id = #{id} and `tenant_id` = #{tenantId} | |||
| </select> | |||
| </mapper> | |||
| @@ -17,7 +17,7 @@ | |||
| </resultMap> | |||
| <sql id="allColumns"> | |||
| `id`,`tenant_id`,`parent_tenant_id`,`rent_contract_id`,`setting_method`,`fees_id`,`price`,`price_unit`, | |||
| `id`,`tenant_id`,`parent_tenant_id`,`rent_contract_id`,`setting_method`,`fees_id`, | |||
| `time_period`,`time_unit`,`calcute_time`,`fees_create_rule`,`createtime`,`updatetime` | |||
| </sql> | |||