Browse Source

重新生成工时表

master
陈裕财 4 years ago
parent
commit
7151faf167
  1. 49
      xm-core/src/main/java/com/xm/core/entity/XmTaskSbillDetail.java
  2. 20
      xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmTaskSbillDetailMapper.xml
  3. 4
      xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmTaskWorkloadMapper.xml

49
xm-core/src/main/java/com/xm/core/entity/XmTaskSbillDetail.java

@ -8,9 +8,9 @@ import java.math.BigDecimal;
/** /**
* 组织 com 顶级模块 xm 大模块 core 小模块 <br> * 组织 com 顶级模块 xm 大模块 core 小模块 <br>
* 实体 XmTaskSbillDetail所有属性名: <br> * 实体 XmTaskSbillDetail所有属性名: <br>
* userid,username,ctime,taskId,bizDate,remark,id,sbillId,stime,sstatus,amt,samt,workload,projectId,sworkload,bizMonth,budgetAt,budgetWorkload,initWorkload,quoteAt,quoteWorkload,sschemel,uniPrice,qendTime,qstartTime,actEndTime,actStartTime,oshare,shareFee,sfee,sfeeRate,cpId,cpName,cpType;<br>
* userid,username,ctime,taskId,bizDate,remark,id,sbillId,stime,sstatus,amt,samt,workload,projectId,sworkload,bizMonth,budgetAt,budgetWorkload,initWorkload,quoteAt,quoteWorkload,sschemel,uniPrice,qendTime,qstartTime,actEndTime,actStartTime,oshare,shareFee,sfee,sfeeRate,cpId,cpName,cpType,distUserid,distUsername,shareKey;<br>
* xm_task_sbill_detail 工时登记表的所有字段名: <br> * xm_task_sbill_detail 工时登记表的所有字段名: <br>
* userid,username,ctime,task_id,biz_date,remark,id,sbill_id,stime,sstatus,amt,samt,workload,project_id,sworkload,biz_month,budget_at,budget_workload,init_workload,quote_at,quote_workload,sschemel,uni_price,qend_time,qstart_time,act_end_time,act_start_time,oshare,share_fee,sfee,sfee_rate,cp_id,cp_name,cp_type;<br>
* userid,username,ctime,task_id,biz_date,remark,id,sbill_id,stime,sstatus,amt,samt,workload,project_id,sworkload,biz_month,budget_at,budget_workload,init_workload,quote_at,quote_workload,sschemel,uni_price,qend_time,qstart_time,act_end_time,act_start_time,oshare,share_fee,sfee,sfee_rate,cp_id,cp_name,cp_type,dist_userid,dist_username,share_key;<br>
* 当前主键(包括多主键):<br> * 当前主键(包括多主键):<br>
* id;<br> * id;<br>
*/ */
@ -121,6 +121,15 @@ public class XmTaskSbillDetail implements java.io.Serializable {
@ApiModelProperty(notes="相对方类型1-个人,2-企业",allowEmptyValue=true,example="",allowableValues="") @ApiModelProperty(notes="相对方类型1-个人,2-企业",allowEmptyValue=true,example="",allowableValues="")
String cpType; String cpType;
@ApiModelProperty(notes="推荐人编号",allowEmptyValue=true,example="",allowableValues="")
String distUserid;
@ApiModelProperty(notes="推荐人姓名",allowEmptyValue=true,example="",allowableValues="")
String distUsername;
@ApiModelProperty(notes="分享码",allowEmptyValue=true,example="",allowableValues="")
String shareKey;
/**主键**/ /**主键**/
public XmTaskSbillDetail(String id) { public XmTaskSbillDetail(String id) {
@ -335,6 +344,24 @@ public class XmTaskSbillDetail implements java.io.Serializable {
public void setCpType(String cpType) { public void setCpType(String cpType) {
this.cpType = cpType; this.cpType = cpType;
} }
/**
* 推荐人编号
**/
public void setDistUserid(String distUserid) {
this.distUserid = distUserid;
}
/**
* 推荐人姓名
**/
public void setDistUsername(String distUsername) {
this.distUsername = distUsername;
}
/**
* 分享码
**/
public void setShareKey(String shareKey) {
this.shareKey = shareKey;
}
/** /**
* 员工编号 * 员工编号
@ -540,5 +567,23 @@ public class XmTaskSbillDetail implements java.io.Serializable {
public String getCpType() { public String getCpType() {
return this.cpType; return this.cpType;
} }
/**
* 推荐人编号
**/
public String getDistUserid() {
return this.distUserid;
}
/**
* 推荐人姓名
**/
public String getDistUsername() {
return this.distUsername;
}
/**
* 分享码
**/
public String getShareKey() {
return this.shareKey;
}
} }

20
xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmTaskSbillDetailMapper.xml

@ -76,7 +76,7 @@
insert into xm_task_sbill_detail( insert into xm_task_sbill_detail(
<include refid="columns"/> <include refid="columns"/>
) values ( ) values (
#{userid},#{username},#{ctime},#{taskId},#{bizDate},#{remark},#{id},#{sbillId},#{stime},#{sstatus},#{amt},#{samt},#{workload},#{projectId},#{sworkload},#{bizMonth},#{budgetAt},#{budgetWorkload},#{initWorkload},#{quoteAt},#{quoteWorkload},#{sschemel},#{uniPrice},#{qendTime},#{qstartTime},#{actEndTime},#{actStartTime},#{oshare},#{shareFee},#{sfee},#{sfeeRate},#{cpId},#{cpName},#{cpType}
#{userid},#{username},#{ctime},#{taskId},#{bizDate},#{remark},#{id},#{sbillId},#{stime},#{sstatus},#{amt},#{samt},#{workload},#{projectId},#{sworkload},#{bizMonth},#{budgetAt},#{budgetWorkload},#{initWorkload},#{quoteAt},#{quoteWorkload},#{sschemel},#{uniPrice},#{qendTime},#{qstartTime},#{actEndTime},#{actStartTime},#{oshare},#{shareFee},#{sfee},#{sfeeRate},#{cpId},#{cpName},#{cpType},#{distUserid},#{distUsername},#{shareKey}
) )
</insert> </insert>
@ -151,7 +151,7 @@
<!--sql片段 列--> <!--sql片段 列-->
<sql id="columns"> <sql id="columns">
userid,username,ctime,task_id,biz_date,remark,id,sbill_id,stime,sstatus,amt,samt,workload,project_id,sworkload,biz_month,budget_at,budget_workload,init_workload,quote_at,quote_workload,sschemel,uni_price,qend_time,qstart_time,act_end_time,act_start_time,oshare,share_fee,sfee,sfee_rate,cp_id,cp_name,cp_type
userid,username,ctime,task_id,biz_date,remark,id,sbill_id,stime,sstatus,amt,samt,workload,project_id,sworkload,biz_month,budget_at,budget_workload,init_workload,quote_at,quote_workload,sschemel,uni_price,qend_time,qstart_time,act_end_time,act_start_time,oshare,share_fee,sfee,sfee_rate,cp_id,cp_name,cp_type,dist_userid,dist_username,share_key
</sql> </sql>
<!--sql片段 动态条件 YYYY-MM-DD HH24:MI:SS--> <!--sql片段 动态条件 YYYY-MM-DD HH24:MI:SS-->
@ -190,6 +190,9 @@
<if test="cpId != null and cpId != ''"> and res.cp_id = #{cpId} </if> <if test="cpId != null and cpId != ''"> and res.cp_id = #{cpId} </if>
<if test="cpName != null and cpName != ''"> and res.cp_name = #{cpName} </if> <if test="cpName != null and cpName != ''"> and res.cp_name = #{cpName} </if>
<if test="cpType != null and cpType != ''"> and res.cp_type = #{cpType} </if> <if test="cpType != null and cpType != ''"> and res.cp_type = #{cpType} </if>
<if test="distUserid != null and distUserid != ''"> and res.dist_userid = #{distUserid} </if>
<if test="distUsername != null and distUsername != ''"> and res.dist_username = #{distUsername} </if>
<if test="shareKey != null and shareKey != ''"> and res.share_key = #{shareKey} </if>
</sql> </sql>
<!--sql片段 更新字段 --> <!--sql片段 更新字段 -->
<sql id="set"> <sql id="set">
@ -225,7 +228,10 @@
sfee_rate = #{sfeeRate}, sfee_rate = #{sfeeRate},
cp_id = #{cpId}, cp_id = #{cpId},
cp_name = #{cpName}, cp_name = #{cpName},
cp_type = #{cpType}
cp_type = #{cpType},
dist_userid = #{distUserid},
dist_username = #{distUsername},
share_key = #{shareKey}
</sql> </sql>
<sql id="someFieldSet"> <sql id="someFieldSet">
<if test="userid != null and userid != ''"> userid = #{userid}, </if> <if test="userid != null and userid != ''"> userid = #{userid}, </if>
@ -261,6 +267,9 @@
<if test="cpId != null and cpId != ''"> cp_id = #{cpId}, </if> <if test="cpId != null and cpId != ''"> cp_id = #{cpId}, </if>
<if test="cpName != null and cpName != ''"> cp_name = #{cpName}, </if> <if test="cpName != null and cpName != ''"> cp_name = #{cpName}, </if>
<if test="cpType != null and cpType != ''"> cp_type = #{cpType}, </if> <if test="cpType != null and cpType != ''"> cp_type = #{cpType}, </if>
<if test="distUserid != null and distUserid != ''"> dist_userid = #{distUserid}, </if>
<if test="distUsername != null and distUsername != ''"> dist_username = #{distUsername}, </if>
<if test="shareKey != null and shareKey != ''"> share_key = #{shareKey}, </if>
</sql> </sql>
<!--sql片段 批量更新 --> <!--sql片段 批量更新 -->
<sql id="batchSet"> <sql id="batchSet">
@ -296,6 +305,9 @@
sfee_rate = #{item.sfeeRate}, sfee_rate = #{item.sfeeRate},
cp_id = #{item.cpId}, cp_id = #{item.cpId},
cp_name = #{item.cpName}, cp_name = #{item.cpName},
cp_type = #{item.cpType}
cp_type = #{item.cpType},
dist_userid = #{item.distUserid},
dist_username = #{item.distUsername},
share_key = #{item.shareKey}
</sql> </sql>
</mapper> </mapper>

4
xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmTaskWorkloadMapper.xml

@ -138,8 +138,8 @@
<!--查询待结算工时--> <!--查询待结算工时-->
<select id="ListGroupByTaskIdAndUseridToSet" parameterType="HashMap" resultType="HashMap"> <select id="ListGroupByTaskIdAndUseridToSet" parameterType="HashMap" resultType="HashMap">
select res.*, task.project_name,task.name as task_name,task.budget_workload,task.act_workload,task_state,task_out,uni_inner_price,uni_out_price,settle_schemel as sschemel,task.budget_at,
e.quote_workload,e.quote_amount as quote_at,e.exec_user_branch_id,e.quote_end_time,e.quote_start_time,e.dist_userid,e.dist_username
select res.*, task.project_name,task.name as task_name,task.budget_workload,task.act_workload,task_state,task_out,uni_inner_price,uni_out_price,settle_schemel as sschemel,task.budget_at,task.oshare,task.share_fee,
e.quote_workload,e.quote_amount as quote_at,e.exec_user_branch_id,e.quote_end_time,e.quote_start_time,e.dist_userid,e.dist_username,e.exec_user_branch_id as cp_id,e.share_key
from xm_task task from xm_task task
inner join ( inner join (
select res.project_id,res.task_id,res.userid, select res.project_id,res.task_id,res.userid,

Loading…
Cancel
Save