diff --git a/xm-core/src/main/java/com/xm/core/entity/XmProduct.java b/xm-core/src/main/java/com/xm/core/entity/XmProduct.java
index aeda4d3a..550b3a0a 100644
--- a/xm-core/src/main/java/com/xm/core/entity/XmProduct.java
+++ b/xm-core/src/main/java/com/xm/core/entity/XmProduct.java
@@ -8,9 +8,9 @@ import java.math.BigDecimal;
/**
* 组织 com 顶级模块 xm 大模块 core 小模块
* 实体 XmProduct所有属性名:
- * id,productName,branchId,remark,version,pmUserid,pmUsername,ctime,deptid,pstatus,startTime,endTime,deptName,admUserid,admUsername,assistantUserid,assistantUsername,bizProcInstId,bizFlowState,isTpl,baselineId,baseTime,code,pbudgetWorkload,pbudgetAmount,pmenuBudgetWorkload,pmenuBudgetAmount;
+ * id,productName,branchId,remark,version,pmUserid,pmUsername,ctime,deptid,pstatus,startTime,endTime,deptName,admUserid,admUsername,assUserid,assUsername,bizProcInstId,bizFlowState,isTpl,baselineId,baseTime,code,pbudgetWorkload,pbudgetAmount,pmenuBudgetWorkload,pmenuBudgetAmount;
* 表 xm_product 产品表的所有字段名:
- * 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,pbudget_workload,pbudget_amount,pmenu_budget_workload,pmenu_budget_amount;
+ * id,product_name,branch_id,remark,version,pm_userid,pm_username,ctime,deptid,pstatus,start_time,end_time,dept_name,adm_userid,adm_username,ass_userid,ass_username,biz_proc_inst_id,biz_flow_state,is_tpl,baseline_id,base_time,code,pbudget_workload,pbudget_amount,pmenu_budget_workload,pmenu_budget_amount;
* 当前主键(包括多主键):
* id;
*/
@@ -66,10 +66,10 @@ public class XmProduct implements java.io.Serializable {
String admUsername;
@ApiModelProperty(notes="副经理编号",allowEmptyValue=true,example="",allowableValues="")
- String assistantUserid;
+ String assUserid;
@ApiModelProperty(notes="副经理名称",allowEmptyValue=true,example="",allowableValues="")
- String assistantUsername;
+ String assUsername;
@ApiModelProperty(notes="当前流程实例编号",allowEmptyValue=true,example="",allowableValues="")
String bizProcInstId;
@@ -203,14 +203,14 @@ public class XmProduct implements java.io.Serializable {
/**
* 副经理编号
**/
- public void setAssistantUserid(String assistantUserid) {
- this.assistantUserid = assistantUserid;
+ public void setAssUserid(String assUserid) {
+ this.assUserid = assUserid;
}
/**
* 副经理名称
**/
- public void setAssistantUsername(String assistantUsername) {
- this.assistantUsername = assistantUsername;
+ public void setAssUsername(String assUsername) {
+ this.assUsername = assUsername;
}
/**
* 当前流程实例编号
@@ -366,14 +366,14 @@ public class XmProduct implements java.io.Serializable {
/**
* 副经理编号
**/
- public String getAssistantUserid() {
- return this.assistantUserid;
+ public String getAssUserid() {
+ return this.assUserid;
}
/**
* 副经理名称
**/
- public String getAssistantUsername() {
- return this.assistantUsername;
+ public String getAssUsername() {
+ return this.assUsername;
}
/**
* 当前流程实例编号
diff --git a/xm-core/src/main/java/com/xm/core/entity/XmProject.java b/xm-core/src/main/java/com/xm/core/entity/XmProject.java
index 7366e752..6c4735b0 100644
--- a/xm-core/src/main/java/com/xm/core/entity/XmProject.java
+++ b/xm-core/src/main/java/com/xm/core/entity/XmProject.java
@@ -8,9 +8,9 @@ import java.math.BigDecimal;
/**
* 组织 com 顶级模块 xm 大模块 core 小模块
* 实体 XmProject所有属性名:
- * id,code,name,xmType,startTime,endTime,urgent,priority,description,createUserid,createUsername,createTime,assess,assessRemarks,status,branchId,planTotalCost,bizProcInstId,bizFlowState,planNouserAt,planInnerUserAt,planOutUserAt,locked,baseTime,baseRemark,baselineId,planWorkload,totalReceivables,budgetMarginRate,contractAmt,planInnerUserPrice,planOutUserPrice,planOutUserCnt,planInnerUserCnt,planWorkingHours,taxRate,planInnerUserWorkload,planOutUserWorkload,fromTplId,budgetCtrl,deptid,showOut,isTpl;
+ * id,code,name,xmType,startTime,endTime,urgent,priority,description,createUserid,createUsername,createTime,assess,assessRemarks,status,branchId,planTotalCost,bizProcInstId,bizFlowState,planNouserAt,planInnerUserAt,planOutUserAt,locked,baseTime,baseRemark,baselineId,planWorkload,totalReceivables,budgetMarginRate,contractAmt,planInnerUserPrice,planOutUserPrice,planOutUserCnt,planInnerUserCnt,planWorkingHours,taxRate,planInnerUserWorkload,planOutUserWorkload,fromTplId,budgetCtrl,deptid,showOut,isTpl,pmUserid,pmUsername,assUserid,assUsername,admUserid,admUsername;
* 表 xm_project xm_project的所有字段名:
- * id,code,name,xm_type,start_time,end_time,urgent,priority,description,create_userid,create_username,create_time,assess,assess_remarks,status,branch_id,plan_total_cost,biz_proc_inst_id,biz_flow_state,plan_nouser_at,plan_inner_user_at,plan_out_user_at,locked,base_time,base_remark,baseline_id,plan_workload,total_receivables,budget_margin_rate,contract_amt,plan_inner_user_price,plan_out_user_price,plan_out_user_cnt,plan_inner_user_cnt,plan_working_hours,tax_rate,plan_inner_user_workload,plan_out_user_workload,from_tpl_id,budget_ctrl,deptid,show_out,is_tpl;
+ * id,code,name,xm_type,start_time,end_time,urgent,priority,description,create_userid,create_username,create_time,assess,assess_remarks,status,branch_id,plan_total_cost,biz_proc_inst_id,biz_flow_state,plan_nouser_at,plan_inner_user_at,plan_out_user_at,locked,base_time,base_remark,baseline_id,plan_workload,total_receivables,budget_margin_rate,contract_amt,plan_inner_user_price,plan_out_user_price,plan_out_user_cnt,plan_inner_user_cnt,plan_working_hours,tax_rate,plan_inner_user_workload,plan_out_user_workload,from_tpl_id,budget_ctrl,deptid,show_out,is_tpl,pm_userid,pm_username,ass_userid,ass_username,adm_userid,adm_username;
* 当前主键(包括多主键):
* id;
*/
@@ -62,16 +62,7 @@ public class XmProject implements java.io.Serializable {
@ApiModelProperty(notes="考核备注",allowEmptyValue=true,example="",allowableValues="")
String assessRemarks;
- @ApiModelProperty(notes="项目状态,0|初始\n" +
- "1|售前\n" +
- "2|立项中\n" +
- "3|实施中\n" +
- "4|暂停中\n" +
- "5|结项中\n" +
- "6|已结项\n" +
- "7|售后\n" +
- "8|已完成\n" +
- "9|已关闭",allowEmptyValue=true,example="",allowableValues="")
+ @ApiModelProperty(notes="0|初始",allowEmptyValue=true,example="",allowableValues="")
String status;
@ApiModelProperty(notes="机构编号",allowEmptyValue=true,example="",allowableValues="")
@@ -86,13 +77,13 @@ public class XmProject implements java.io.Serializable {
@ApiModelProperty(notes="当前流程状态0初始1审批中2审批通过3审批不通过4流程取消或者删除",allowEmptyValue=true,example="",allowableValues="")
String bizFlowState;
- @ApiModelProperty(notes="非人力成本总预算-应该大于或等于计划非人力总成本",allowEmptyValue=true,example="",allowableValues="")
+ @ApiModelProperty(notes="非人力成本总预算-应该大于或等于阶段计划非人力总成本",allowEmptyValue=true,example="",allowableValues="")
BigDecimal planNouserAt;
- @ApiModelProperty(notes="内部人力成本总预算-应该大于或等于计划内部人力总成本",allowEmptyValue=true,example="",allowableValues="")
+ @ApiModelProperty(notes="内部人力成本总预算-应该大于或等于阶段计划内部人力总成本",allowEmptyValue=true,example="",allowableValues="")
BigDecimal planInnerUserAt;
- @ApiModelProperty(notes="外购人力成本总预算-应该大于或等于计划外购人力总成本",allowEmptyValue=true,example="",allowableValues="")
+ @ApiModelProperty(notes="外购人力成本总预算-应该大于或等于阶段计划外购人力总成本",allowEmptyValue=true,example="",allowableValues="")
BigDecimal planOutUserAt;
@ApiModelProperty(notes="是否锁定整个项目不允许变化0否1是",allowEmptyValue=true,example="",allowableValues="")
@@ -107,7 +98,7 @@ public class XmProject implements java.io.Serializable {
@ApiModelProperty(notes="基线主键",allowEmptyValue=true,example="",allowableValues="")
String baselineId;
- @ApiModelProperty(notes="总预算工作量-应该大于或等于计划总工作量",allowEmptyValue=true,example="",allowableValues="")
+ @ApiModelProperty(notes="总预算工作量-应该大于或等于阶段计划总工作量",allowEmptyValue=true,example="",allowableValues="")
BigDecimal planWorkload;
@ApiModelProperty(notes="总预计收款金额",allowEmptyValue=true,example="",allowableValues="")
@@ -137,10 +128,10 @@ public class XmProject implements java.io.Serializable {
@ApiModelProperty(notes="税率",allowEmptyValue=true,example="",allowableValues="")
BigDecimal taxRate;
- @ApiModelProperty(notes="内部人力总工作量-应该大于或等于计划内部人力总成本",allowEmptyValue=true,example="",allowableValues="")
+ @ApiModelProperty(notes="内部人力总工作量-应该大于或等于阶段计划内部人力总成本",allowEmptyValue=true,example="",allowableValues="")
BigDecimal planInnerUserWorkload;
- @ApiModelProperty(notes="外购人力总工作量-应该大于或等于计划外购人力总成本",allowEmptyValue=true,example="",allowableValues="")
+ @ApiModelProperty(notes="外购人力总工作量-应该大于或等于阶段计划外购人力总成本",allowEmptyValue=true,example="",allowableValues="")
BigDecimal planOutUserWorkload;
@ApiModelProperty(notes="关联模板编号",allowEmptyValue=true,example="",allowableValues="")
@@ -157,6 +148,24 @@ public class XmProject implements java.io.Serializable {
@ApiModelProperty(notes="是否为模板",allowEmptyValue=true,example="",allowableValues="")
String isTpl;
+
+ @ApiModelProperty(notes="项目经理编号",allowEmptyValue=true,example="",allowableValues="")
+ String pmUserid;
+
+ @ApiModelProperty(notes="项目经理名称",allowEmptyValue=true,example="",allowableValues="")
+ String pmUsername;
+
+ @ApiModelProperty(notes="助理、副经理编号",allowEmptyValue=true,example="",allowableValues="")
+ String assUserid;
+
+ @ApiModelProperty(notes="助理、副经理姓名",allowEmptyValue=true,example="",allowableValues="")
+ String assUsername;
+
+ @ApiModelProperty(notes="主管领导编号",allowEmptyValue=true,example="",allowableValues="")
+ String admUserid;
+
+ @ApiModelProperty(notes="主管领导姓名",allowEmptyValue=true,example="",allowableValues="")
+ String admUsername;
/**项目编号**/
public XmProject(String id) {
@@ -252,17 +261,7 @@ public class XmProject implements java.io.Serializable {
this.assessRemarks = assessRemarks;
}
/**
- * 项目状态,
* 0|初始
- * 1|售前
- * 2|立项中
- * 3|实施中
- * 4|暂停中
- * 5|结项中
- * 6|已结项
- * 7|售后
- * 8|已完成
- * 9|已关闭
**/
public void setStatus(String status) {
this.status = status;
@@ -292,19 +291,19 @@ public class XmProject implements java.io.Serializable {
this.bizFlowState = bizFlowState;
}
/**
- * 非人力成本总预算-应该大于或等于计划非人力总成本
+ * 非人力成本总预算-应该大于或等于阶段计划非人力总成本
**/
public void setPlanNouserAt(BigDecimal planNouserAt) {
this.planNouserAt = planNouserAt;
}
/**
- * 内部人力成本总预算-应该大于或等于计划内部人力总成本
+ * 内部人力成本总预算-应该大于或等于阶段计划内部人力总成本
**/
public void setPlanInnerUserAt(BigDecimal planInnerUserAt) {
this.planInnerUserAt = planInnerUserAt;
}
/**
- * 外购人力成本总预算-应该大于或等于计划外购人力总成本
+ * 外购人力成本总预算-应该大于或等于阶段计划外购人力总成本
**/
public void setPlanOutUserAt(BigDecimal planOutUserAt) {
this.planOutUserAt = planOutUserAt;
@@ -334,7 +333,7 @@ public class XmProject implements java.io.Serializable {
this.baselineId = baselineId;
}
/**
- * 总预算工作量-应该大于或等于计划总工作量
+ * 总预算工作量-应该大于或等于阶段计划总工作量
**/
public void setPlanWorkload(BigDecimal planWorkload) {
this.planWorkload = planWorkload;
@@ -394,13 +393,13 @@ public class XmProject implements java.io.Serializable {
this.taxRate = taxRate;
}
/**
- * 内部人力总工作量-应该大于或等于计划内部人力总成本
+ * 内部人力总工作量-应该大于或等于阶段计划内部人力总成本
**/
public void setPlanInnerUserWorkload(BigDecimal planInnerUserWorkload) {
this.planInnerUserWorkload = planInnerUserWorkload;
}
/**
- * 外购人力总工作量-应该大于或等于计划外购人力总成本
+ * 外购人力总工作量-应该大于或等于阶段计划外购人力总成本
**/
public void setPlanOutUserWorkload(BigDecimal planOutUserWorkload) {
this.planOutUserWorkload = planOutUserWorkload;
@@ -435,6 +434,42 @@ public class XmProject implements java.io.Serializable {
public void setIsTpl(String isTpl) {
this.isTpl = isTpl;
}
+ /**
+ * 项目经理编号
+ **/
+ public void setPmUserid(String pmUserid) {
+ this.pmUserid = pmUserid;
+ }
+ /**
+ * 项目经理名称
+ **/
+ public void setPmUsername(String pmUsername) {
+ this.pmUsername = pmUsername;
+ }
+ /**
+ * 助理、副经理编号
+ **/
+ public void setAssUserid(String assUserid) {
+ this.assUserid = assUserid;
+ }
+ /**
+ * 助理、副经理姓名
+ **/
+ public void setAssUsername(String assUsername) {
+ this.assUsername = assUsername;
+ }
+ /**
+ * 主管领导编号
+ **/
+ public void setAdmUserid(String admUserid) {
+ this.admUserid = admUserid;
+ }
+ /**
+ * 主管领导姓名
+ **/
+ public void setAdmUsername(String admUsername) {
+ this.admUsername = admUsername;
+ }
/**
* 项目编号
@@ -521,17 +556,7 @@ public class XmProject implements java.io.Serializable {
return this.assessRemarks;
}
/**
- * 项目状态,
* 0|初始
- * 1|售前
- * 2|立项中
- * 3|实施中
- * 4|暂停中
- * 5|结项中
- * 6|已结项
- * 7|售后
- * 8|已完成
- * 9|已关闭
**/
public String getStatus() {
return this.status;
@@ -561,19 +586,19 @@ public class XmProject implements java.io.Serializable {
return this.bizFlowState;
}
/**
- * 非人力成本总预算-应该大于或等于计划非人力总成本
+ * 非人力成本总预算-应该大于或等于阶段计划非人力总成本
**/
public BigDecimal getPlanNouserAt() {
return this.planNouserAt;
}
/**
- * 内部人力成本总预算-应该大于或等于计划内部人力总成本
+ * 内部人力成本总预算-应该大于或等于阶段计划内部人力总成本
**/
public BigDecimal getPlanInnerUserAt() {
return this.planInnerUserAt;
}
/**
- * 外购人力成本总预算-应该大于或等于计划外购人力总成本
+ * 外购人力成本总预算-应该大于或等于阶段计划外购人力总成本
**/
public BigDecimal getPlanOutUserAt() {
return this.planOutUserAt;
@@ -603,7 +628,7 @@ public class XmProject implements java.io.Serializable {
return this.baselineId;
}
/**
- * 总预算工作量-应该大于或等于计划总工作量
+ * 总预算工作量-应该大于或等于阶段计划总工作量
**/
public BigDecimal getPlanWorkload() {
return this.planWorkload;
@@ -663,13 +688,13 @@ public class XmProject implements java.io.Serializable {
return this.taxRate;
}
/**
- * 内部人力总工作量-应该大于或等于计划内部人力总成本
+ * 内部人力总工作量-应该大于或等于阶段计划内部人力总成本
**/
public BigDecimal getPlanInnerUserWorkload() {
return this.planInnerUserWorkload;
}
/**
- * 外购人力总工作量-应该大于或等于计划外购人力总成本
+ * 外购人力总工作量-应该大于或等于阶段计划外购人力总成本
**/
public BigDecimal getPlanOutUserWorkload() {
return this.planOutUserWorkload;
@@ -704,5 +729,41 @@ public class XmProject implements java.io.Serializable {
public String getIsTpl() {
return this.isTpl;
}
+ /**
+ * 项目经理编号
+ **/
+ public String getPmUserid() {
+ return this.pmUserid;
+ }
+ /**
+ * 项目经理名称
+ **/
+ public String getPmUsername() {
+ return this.pmUsername;
+ }
+ /**
+ * 助理、副经理编号
+ **/
+ public String getAssUserid() {
+ return this.assUserid;
+ }
+ /**
+ * 助理、副经理姓名
+ **/
+ public String getAssUsername() {
+ return this.assUsername;
+ }
+ /**
+ * 主管领导编号
+ **/
+ public String getAdmUserid() {
+ return this.admUserid;
+ }
+ /**
+ * 主管领导姓名
+ **/
+ public String getAdmUsername() {
+ return this.admUsername;
+ }
}
\ No newline at end of file
diff --git a/xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmProductMapper.xml b/xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmProductMapper.xml
index 2b9383e4..35e8032e 100644
--- a/xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmProductMapper.xml
+++ b/xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmProductMapper.xml
@@ -106,7 +106,7 @@
insert into xm_product(
) values (
- #{id},#{productName},#{branchId},#{remark},#{version},#{pmUserid},#{pmUsername},#{ctime},#{deptid},#{pstatus},#{startTime},#{endTime},#{deptName},#{admUserid},#{admUsername},#{assistantUserid},#{assistantUsername},#{bizProcInstId},#{bizFlowState},#{isTpl},#{baselineId},#{baseTime},#{code},#{pbudgetWorkload},#{pbudgetAmount},#{pmenuBudgetWorkload},#{pmenuBudgetAmount}
+ #{id},#{productName},#{branchId},#{remark},#{version},#{pmUserid},#{pmUsername},#{ctime},#{deptid},#{pstatus},#{startTime},#{endTime},#{deptName},#{admUserid},#{admUsername},#{assUserid},#{assUsername},#{bizProcInstId},#{bizFlowState},#{isTpl},#{baselineId},#{baseTime},#{code},#{pbudgetWorkload},#{pbudgetAmount},#{pmenuBudgetWorkload},#{pmenuBudgetAmount}
)
@@ -169,7 +169,7 @@
- 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,pbudget_workload,pbudget_amount,pmenu_budget_workload,pmenu_budget_amount
+ id,product_name,branch_id,remark,version,pm_userid,pm_username,ctime,deptid,pstatus,start_time,end_time,dept_name,adm_userid,adm_username,ass_userid,ass_username,biz_proc_inst_id,biz_flow_state,is_tpl,baseline_id,base_time,code,pbudget_workload,pbudget_amount,pmenu_budget_workload,pmenu_budget_amount
@@ -189,8 +189,8 @@
and res.dept_name = #{deptName}
and res.adm_userid = #{admUserid}
and res.adm_username = #{admUsername}
- and res.assistant_userid = #{assistantUserid}
- and res.assistant_username = #{assistantUsername}
+ and res.ass_userid = #{assUserid}
+ and res.ass_username = #{assUsername}
and res.biz_proc_inst_id = #{bizProcInstId}
and res.biz_flow_state = #{bizFlowState}
and res.is_tpl = #{isTpl}
@@ -218,8 +218,8 @@
dept_name = #{deptName},
adm_userid = #{admUserid},
adm_username = #{admUsername},
- assistant_userid = #{assistantUserid},
- assistant_username = #{assistantUsername},
+ ass_userid = #{assUserid},
+ ass_username = #{assUsername},
biz_proc_inst_id = #{bizProcInstId},
biz_flow_state = #{bizFlowState},
is_tpl = #{isTpl},
@@ -246,8 +246,8 @@
dept_name = #{deptName},
adm_userid = #{admUserid},
adm_username = #{admUsername},
- assistant_userid = #{assistantUserid},
- assistant_username = #{assistantUsername},
+ ass_userid = #{assUserid},
+ ass_username = #{assUsername},
biz_proc_inst_id = #{bizProcInstId},
biz_flow_state = #{bizFlowState},
is_tpl = #{isTpl},
@@ -275,8 +275,8 @@
dept_name = #{item.deptName},
adm_userid = #{item.admUserid},
adm_username = #{item.admUsername},
- assistant_userid = #{item.assistantUserid},
- assistant_username = #{item.assistantUsername},
+ ass_userid = #{item.assUserid},
+ ass_username = #{item.assUsername},
biz_proc_inst_id = #{item.bizProcInstId},
biz_flow_state = #{item.bizFlowState},
is_tpl = #{item.isTpl},
diff --git a/xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmProjectMapper.xml b/xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmProjectMapper.xml
index 18ca0714..4c5e995f 100644
--- a/xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmProjectMapper.xml
+++ b/xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmProjectMapper.xml
@@ -3,43 +3,101 @@
-
-
+
-
+
+ and (res.id) in
+
+ ( #{item})
+
+
+ and (
+ date_format(start_time,'%Y') = #{startYear}
+ or date_format(end_time,'%Y') = #{startYear}
+ or ( date_format(start_time,'%Y') < #{startYear} and date_format(end_time,'%Y') > #{startYear} )
+ )
+
+
+
+ and res.status != #{hideStatus}
+
+
+
+ and ( exists ( select 1 from xm_project_group g,XM.xm_project_group_user gu where gu.group_id=g.id and gu.userid=#{userid} and g.project_id=res.id )
+ or res.create_userid=#{compete}
+ or exists ( select 1 from xm_task_execuser exe where exe.project_id=res.id and exe.userid=#{compete} )
+ )
+
+
+
+ and exists ( select 1 from xm_project_group g,XM.xm_project_group_user gu where gu.group_id=g.id and gu.userid=#{userid} and g.project_id=res.id
+ and g.pg_type_id in
+
+ #{item}
+
+ )
+
+
+
+ and exists ( select 1 from xm_task_execuser exe where exe.project_id=res.id and exe.userid=#{userid}
+
+ and exe.status=#{myExecuserStatus}
+
+ )
+
+
+
+ and exists ( select 1 from xm_my_focus f where f.userid=#{userid} and f.project_id=res.id )
+
+
+ and exists( select 1 from xm_product_project_link ppl
+ where ppl.product_id=#{productId} and ppl.project_id=res.id
+ )
+
+
+ and exists( select 1 from xm_iteration_product_link ipl inner join xm_product_project_link ppl
+ on ipl.product_id=ppl.product_id
+ where ppl.project_id =res.id and ipl.iteration_id=#{iterationId}
+ )
+
+ and res.name like #{key}
+
+ and (res.branch_id in( #{platformBranchId},#{myBranchId}) and res.is_tpl='1')
+
+
+ parameterType="HashMap"
+ useGeneratedKeys="false" keyProperty="id">
insert into xm_project_process_approva (
- id,project_id,flow_branch_id,agree,act_id,task_name,proc_inst_id,main_title,comment_msg,flow_last_time,event_name,biz_key,model_key,assignee,start_userid,proc_def_id
+ id,project_id,flow_branch_id,agree,act_id,task_name,proc_inst_id,main_title,comment_msg,flow_last_time,event_name,biz_key,model_key,assignee,start_userid,proc_def_id
) values (
- #{id},#{projectId},#{flowBranchId},#{agree},#{actId},#{taskName},#{procInstId},#{mainTitle},#{commentMsg},#{flowLastTime},#{eventName},#{bizKey},#{modelKey},#{assignee},#{startUserid},#{procDefId}
+ #{id},#{projectId},#{flowBranchId},#{agree},#{actId},#{taskName},#{procInstId},#{mainTitle},#{commentMsg},#{flowLastTime},#{eventName},#{bizKey},#{modelKey},#{assignee},#{startUserid},#{procDefId}
)
-
+
+ parameterType="HashMap">
update xm_project b ,XM.xm_project_process_approva pa
-
- pa.agree = #{agree},
- pa.act_id = #{actId},
- pa.assignee = #{assignee},
- pa.assignee_name = #{assigneeName},
- pa.task_name = #{taskName},
- pa.comment_msg = #{commentMsg},
- pa.flow_last_time = now(),
- pa.event_name = #{eventName},
- pa.flow_state=#{flowState},
- b.biz_flow_state=#{bizFlowState},
- b.biz_proc_inst_id=#{bizProcInstId},
-
+
+ pa.agree = #{agree},
+ pa.act_id = #{actId},
+ pa.assignee = #{assignee},
+ pa.assignee_name = #{assigneeName},
+ pa.task_name = #{taskName},
+ pa.comment_msg = #{commentMsg},
+ pa.flow_last_time = now(),
+ pa.event_name = #{eventName},
+ pa.flow_state=#{flowState},
+ b.biz_flow_state=#{bizFlowState},
+ b.biz_proc_inst_id=#{bizProcInstId},
+
where pa.proc_inst_id = #{procInstId} and pa.flow_branch_id=#{flowBranchId}
- and b.id=pa.project_id
+ and b.id=pa.project_id
+ parameterType="HashMap">
update xm_project_process_approva pa set pa.flow_state='2'
where pa.proc_inst_id = #{procInstId} and pa.flow_branch_id=#{flowBranchId}
@@ -47,7 +105,7 @@
delete from xm_project
- where biz_proc_inst_id=#{procInstId}
+ where biz_proc_inst_id=#{procInstId}
@@ -57,79 +115,18 @@
@@ -166,7 +163,7 @@
insert into xm_project(
) values (
- #{id},#{code},#{name},#{xmType},#{startTime},#{endTime},#{urgent},#{priority},#{description},#{createUserid},#{createUsername},#{createTime},#{assess},#{assessRemarks},#{status},#{branchId},#{planTotalCost},#{bizProcInstId},#{bizFlowState},#{planNouserAt},#{planInnerUserAt},#{planOutUserAt},#{locked},#{baseTime},#{baseRemark},#{baselineId},#{planWorkload},#{totalReceivables},#{budgetMarginRate},#{contractAmt},#{planInnerUserPrice},#{planOutUserPrice},#{planOutUserCnt},#{planInnerUserCnt},#{planWorkingHours},#{taxRate},#{planInnerUserWorkload},#{planOutUserWorkload},#{fromTplId},#{budgetCtrl},#{deptid},#{showOut},#{isTpl}
+ #{id},#{code},#{name},#{xmType},#{startTime},#{endTime},#{urgent},#{priority},#{description},#{createUserid},#{createUsername},#{createTime},#{assess},#{assessRemarks},#{status},#{branchId},#{planTotalCost},#{bizProcInstId},#{bizFlowState},#{planNouserAt},#{planInnerUserAt},#{planOutUserAt},#{locked},#{baseTime},#{baseRemark},#{baselineId},#{planWorkload},#{totalReceivables},#{budgetMarginRate},#{contractAmt},#{planInnerUserPrice},#{planOutUserPrice},#{planOutUserCnt},#{planInnerUserCnt},#{planWorkingHours},#{taxRate},#{planInnerUserWorkload},#{planOutUserWorkload},#{fromTplId},#{budgetCtrl},#{deptid},#{showOut},#{isTpl},#{pmUserid},#{pmUsername},#{assUserid},#{assUsername},#{admUserid},#{admUsername}
)
@@ -229,7 +226,7 @@
- id,code,name,xm_type,start_time,end_time,urgent,priority,description,create_userid,create_username,create_time,assess,assess_remarks,status,branch_id,plan_total_cost,biz_proc_inst_id,biz_flow_state,plan_nouser_at,plan_inner_user_at,plan_out_user_at,locked,base_time,base_remark,baseline_id,plan_workload,total_receivables,budget_margin_rate,contract_amt,plan_inner_user_price,plan_out_user_price,plan_out_user_cnt,plan_inner_user_cnt,plan_working_hours,tax_rate,plan_inner_user_workload,plan_out_user_workload,from_tpl_id,budget_ctrl,deptid,show_out,is_tpl
+ id,code,name,xm_type,start_time,end_time,urgent,priority,description,create_userid,create_username,create_time,assess,assess_remarks,status,branch_id,plan_total_cost,biz_proc_inst_id,biz_flow_state,plan_nouser_at,plan_inner_user_at,plan_out_user_at,locked,base_time,base_remark,baseline_id,plan_workload,total_receivables,budget_margin_rate,contract_amt,plan_inner_user_price,plan_out_user_price,plan_out_user_cnt,plan_inner_user_cnt,plan_working_hours,tax_rate,plan_inner_user_workload,plan_out_user_workload,from_tpl_id,budget_ctrl,deptid,show_out,is_tpl,pm_userid,pm_username,ass_userid,ass_username,adm_userid,adm_username
@@ -277,6 +274,12 @@
and res.deptid = #{deptid}
and res.show_out = #{showOut}
and res.is_tpl = #{isTpl}
+ and res.pm_userid = #{pmUserid}
+ and res.pm_username = #{pmUsername}
+ and res.ass_userid = #{assUserid}
+ and res.ass_username = #{assUsername}
+ and res.adm_userid = #{admUserid}
+ and res.adm_username = #{admUsername}
@@ -321,7 +324,13 @@
budget_ctrl = #{budgetCtrl},
deptid = #{deptid},
show_out = #{showOut},
- is_tpl = #{isTpl}
+ is_tpl = #{isTpl},
+ pm_userid = #{pmUserid},
+ pm_username = #{pmUsername},
+ ass_userid = #{assUserid},
+ ass_username = #{assUsername},
+ adm_userid = #{admUserid},
+ adm_username = #{admUsername}
code = #{code},
@@ -366,6 +375,12 @@
deptid = #{deptid},
show_out = #{showOut},
is_tpl = #{isTpl},
+ pm_userid = #{pmUserid},
+ pm_username = #{pmUsername},
+ ass_userid = #{assUserid},
+ ass_username = #{assUsername},
+ adm_userid = #{admUserid},
+ adm_username = #{admUsername},
@@ -410,6 +425,12 @@
budget_ctrl = #{item.budgetCtrl},
deptid = #{item.deptid},
show_out = #{item.showOut},
- is_tpl = #{item.isTpl}
+ is_tpl = #{item.isTpl},
+ pm_userid = #{item.pmUserid},
+ pm_username = #{item.pmUsername},
+ ass_userid = #{item.assUserid},
+ ass_username = #{item.assUsername},
+ adm_userid = #{item.admUserid},
+ adm_username = #{item.admUsername}
\ No newline at end of file