Browse Source

添加节点类型、标签等

master
陈裕财 4 years ago
parent
commit
804dc8224c
  1. 19
      xm-core/src/main/java/com/xm/core/entity/XmProduct.java
  2. 12
      xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmProductMapper.xml

19
xm-core/src/main/java/com/xm/core/entity/XmProduct.java

@ -7,9 +7,9 @@ import java.util.Date;
/**
* 组织 com 顶级模块 xm 大模块 core 小模块 <br>
* 实体 XmProduct所有属性名: <br>
* id,productName,branchId,remark,version,pmUserid,pmUsername,ctime,deptid,pstatus,startTime,endTime,deptName,admUserid,admUsername,assistantUserid,assistantUsername,bizProcInstId,bizFlowState,isTpl,baselineId,baseTime;<br>
* id,productName,branchId,remark,version,pmUserid,pmUsername,ctime,deptid,pstatus,startTime,endTime,deptName,admUserid,admUsername,assistantUserid,assistantUsername,bizProcInstId,bizFlowState,isTpl,baselineId,baseTime,code;<br>
* xm_product 产品表的所有字段名: <br>
* id,product_name,branch_id,remark,version,pm_userid,pm_username,ctime,deptid,pstatus,start_time,end_time,dept_name,adm_userid,adm_username,assistant_userid,assistant_username,biz_proc_inst_id,biz_flow_state,is_tpl,baseline_id,base_time;<br>
* id,product_name,branch_id,remark,version,pm_userid,pm_username,ctime,deptid,pstatus,start_time,end_time,dept_name,adm_userid,adm_username,assistant_userid,assistant_username,biz_proc_inst_id,biz_flow_state,is_tpl,baseline_id,base_time,code;<br>
* 当前主键(包括多主键):<br>
* id;<br>
*/
@ -84,6 +84,9 @@ public class XmProduct implements java.io.Serializable {
@ApiModelProperty(notes="基线时间",allowEmptyValue=true,example="",allowableValues="")
Date baseTime;
@ApiModelProperty(notes="产品编码",allowEmptyValue=true,example="",allowableValues="")
String code;
/**产品编号**/
public XmProduct(String id) {
@ -226,6 +229,12 @@ public class XmProduct implements java.io.Serializable {
public void setBaseTime(Date baseTime) {
this.baseTime = baseTime;
}
/**
* 产品编码
**/
public void setCode(String code) {
this.code = code;
}
/**
* 产品编号
@ -359,5 +368,11 @@ public class XmProduct implements java.io.Serializable {
public Date getBaseTime() {
return this.baseTime;
}
/**
* 产品编码
**/
public String getCode() {
return this.code;
}
}

12
xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmProductMapper.xml

@ -99,7 +99,7 @@
insert into xm_product(
<include refid="columns"/>
) values (
#{id},#{productName},#{branchId},#{remark},#{version},#{pmUserid},#{pmUsername},#{ctime},#{deptid},#{pstatus},#{startTime},#{endTime},#{deptName},#{admUserid},#{admUsername},#{assistantUserid},#{assistantUsername},#{bizProcInstId},#{bizFlowState},#{isTpl},#{baselineId},#{baseTime}
#{id},#{productName},#{branchId},#{remark},#{version},#{pmUserid},#{pmUsername},#{ctime},#{deptid},#{pstatus},#{startTime},#{endTime},#{deptName},#{admUserid},#{admUsername},#{assistantUserid},#{assistantUsername},#{bizProcInstId},#{bizFlowState},#{isTpl},#{baselineId},#{baseTime},#{code}
)
</insert>
@ -162,7 +162,7 @@
<!--sql片段 列-->
<sql id="columns">
id,product_name,branch_id,remark,version,pm_userid,pm_username,ctime,deptid,pstatus,start_time,end_time,dept_name,adm_userid,adm_username,assistant_userid,assistant_username,biz_proc_inst_id,biz_flow_state,is_tpl,baseline_id,base_time
id,product_name,branch_id,remark,version,pm_userid,pm_username,ctime,deptid,pstatus,start_time,end_time,dept_name,adm_userid,adm_username,assistant_userid,assistant_username,biz_proc_inst_id,biz_flow_state,is_tpl,baseline_id,base_time,code
</sql>
<!--sql片段 动态条件 YYYY-MM-DD HH24:MI:SS-->
@ -189,6 +189,7 @@
<if test="isTpl != null and isTpl != ''"> and res.is_tpl = #{isTpl} </if>
<if test="baselineId != null and baselineId != ''"> and res.baseline_id = #{baselineId} </if>
<if test="baseTime != null"> and date_format(res.base_time,'%Y-%m-%d') = date_format(#{baseTime},'%Y-%m-%d') </if>
<if test="code != null and code != ''"> and res.code = #{code} </if>
</sql>
<!--sql片段 更新字段 -->
<sql id="set">
@ -212,7 +213,8 @@
biz_flow_state = #{bizFlowState},
is_tpl = #{isTpl},
baseline_id = #{baselineId},
base_time = #{baseTime}
base_time = #{baseTime},
code = #{code}
</sql>
<sql id="someFieldSet">
<if test="productName != null and productName != ''"> product_name = #{productName}, </if>
@ -236,6 +238,7 @@
<if test="isTpl != null and isTpl != ''"> is_tpl = #{isTpl}, </if>
<if test="baselineId != null and baselineId != ''"> baseline_id = #{baselineId}, </if>
<if test="baseTime != null"> base_time = #{baseTime}, </if>
<if test="code != null and code != ''"> code = #{code}, </if>
</sql>
<!--sql片段 批量更新 -->
<sql id="batchSet">
@ -259,6 +262,7 @@
biz_flow_state = #{item.bizFlowState},
is_tpl = #{item.isTpl},
baseline_id = #{item.baselineId},
base_time = #{item.baseTime}
base_time = #{item.baseTime},
code = #{item.code}
</sql>
</mapper>
Loading…
Cancel
Save