Browse Source

修复查询异常

v1.0
Yen 2 years ago
parent
commit
84cb00b25e
  1. 4
      src/main/java/com/qs/serve/modules/seeyon/SeeYonController.java
  2. 15
      src/main/java/com/qs/serve/modules/seeyon/entity/dto/TodoVoQuery.java
  3. 20
      src/main/java/com/qs/serve/modules/tbs/entity/dto/TbsContractCostSubItem.java
  4. 3
      src/main/java/com/qs/serve/modules/tbs/entity/so/TbsBudgetSo.java
  5. 3
      src/main/java/com/qs/serve/modules/tbs/service/impl/TbsCostApplyServiceImpl.java
  6. 8
      src/main/java/com/qs/serve/modules/third/service/PortalOfCostApplication.java
  7. 7
      src/main/resources/mapper/bms/BmsChannelPointMapper.xml
  8. 401
      src/main/resources/mapper/seeyon/CommonCheckMapper.xml
  9. 5
      src/main/resources/mapper/tbs/TbsBudgetMapper.xml
  10. 2
      src/main/resources/mapper/tbs/TbsCostApplyMapper.xml

4
src/main/java/com/qs/serve/modules/seeyon/SeeYonController.java

@ -75,8 +75,8 @@ public class SeeYonController {
* @return
*/
@GetMapping("pageMyCallback")
public R<PageVo<TodoVO>> pageCallbackList(){
return R.ok(commonCheckService.pageCallback(new TodoVoQuery()));
public R<PageVo<TodoVO>> pageCallbackList(TodoVoQuery todoVoQuery){
return R.ok(commonCheckService.pageCallback(todoVoQuery));
}
/**

15
src/main/java/com/qs/serve/modules/seeyon/entity/dto/TodoVoQuery.java

@ -1,6 +1,9 @@
package com.qs.serve.modules.seeyon.entity.dto;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDate;
/**
* @author YenHex
@ -9,6 +12,18 @@ import lombok.Data;
@Data
public class TodoVoQuery {
private String title;
private String targetType;
private String targetCode;
@DateTimeFormat(pattern = "yyyy-MM-dd")
private LocalDate startDate;
@DateTimeFormat(pattern = "yyyy-MM-dd")
private LocalDate endDate;
private String userId;
private Integer startRow;

20
src/main/java/com/qs/serve/modules/tbs/entity/dto/TbsContractCostSubItem.java

@ -52,4 +52,24 @@ public class TbsContractCostSubItem {
}
@Data
public static class CusCenterRate{
// 季度客户所属成本中心费用金额
private String qtdCusCenterCost;
// 季度客户所属成本中心发货金额
private String qtdCusCenterSend;
// 季度客户所属成本中心费用率
private String qtdCusCenterExpenseRate;
// 季度客户所属成本中心目标费用率
private String qtdCusCenterTargetExpenseRate;
// 年度客户所属成本中心费用金额
private String ytdCusCenterCost;
// 年度客户所属成本中心发货金额
private String ytdCusCenterSend;
// 年度客户所属成本中心费用率
private String ytdCusCenterExpenseRate;
// 年度客户所属成本中心目标费用率
private String ytdCusCenterTargetExpenseRate;
}
}

3
src/main/java/com/qs/serve/modules/tbs/entity/so/TbsBudgetSo.java

@ -34,6 +34,9 @@ public class TbsBudgetSo implements Serializable {
/** 预算编码 */
private String budgetNumber;
/** 审批流程状态 */
private Integer budgetCheckState;
/** 科目编码搜索值 */
private String subjectValue;

3
src/main/java/com/qs/serve/modules/tbs/service/impl/TbsCostApplyServiceImpl.java

@ -697,6 +697,9 @@ public class TbsCostApplyServiceImpl extends ServiceImpl<TbsCostApplyMapper,TbsC
toDoItem.setAgreeCompleteState(costTodo.getFinishedFlag().equals(1)?"已完成":"未完成");
subList.add(toDoItem);
}
//TODO 构造客户维度的 年度、季度合计
List<TbsContractCostSubItem.CusCenterRate> cusCenterRates = new ArrayList<>();
//关联
data.put("sub", subList);
}

8
src/main/java/com/qs/serve/modules/third/service/PortalOfCostApplication.java

@ -577,6 +577,10 @@ public class PortalOfCostApplication {
String activityCode = costCode;
if(StringUtils.hasText(activityCode)){
activityCode = CodeGenUtil.generate(CodeGenUtil.SourceKey.Activity);
}
String activityTitle = createBo.getActivityTitle();
if(!StringUtils.hasText(activityTitle)){
activityTitle = "由核销API生成的活动";
@ -761,7 +765,7 @@ public class PortalOfCostApplication {
//保存核销申请
VtbVerification verification = new VtbVerification();
verification.setVerificationCode("HX"+ CodeGenUtil.generate(CodeGenUtil.SourceKey.Verification));
verification.setVerificationCode("MHX"+ CodeGenUtil.generate(CodeGenUtil.SourceKey.Verification));
verification.setCostApplyId(costApply.getId());
verification.setFinishedTime(nowTime);
verification.setVerificationState(VtbVerificationState.Finished.getCode());
@ -812,7 +816,7 @@ public class PortalOfCostApplication {
tv.setMoney(totalAmount);
//tv.setCreateUser();
tv.setCreateTime(timeString);
tv.setCheckUser(user.getName());
//tv.setCheckUser(user.getName());
tv.setCheckTime(timeString);
tv.setCusCode(supplier.getCode());
tv.setCusName(supplier.getName());

7
src/main/resources/mapper/bms/BmsChannelPointMapper.xml

@ -66,11 +66,14 @@
bms_channel_point.`update_by` </sql>
<select id="selectChannelPointList" parameterType="com.qs.serve.modules.bms.entity.BmsChannelPoint" resultMap="bmsChannelPointMap">
SELECT <include refid="bmsChannelPointSql"/>
SELECT
<include refid="bmsChannelPointSql"/>,
bms_channel.channel_type
FROM `bms_channel_point` `bms_channel_point`
<if test="query.supplierId!=null and query.supplierId!=''">
LEFT JOIN bms_supplier_channel ON bms_supplier_channel.`channel_id` = `bms_channel_point`.`channel_id`
</if>
LEFT JOIN bms_channel ON bms_channel.`id` = `bms_channel_point`.`channel_id`
<where>
and `bms_channel_point`.`del_flag` = 0
<if test="query.supplierId!=null and query.supplierId!=''">
@ -84,7 +87,9 @@
</if>
<if test="query.id != null"> and `bms_channel_point`.`id` = #{query.id}</if>
<if test="query.channelId != null"> and `bms_channel_point`.`channel_id` = #{query.channelId}</if>
<if test="query.channelType != null and query.channelType != ''"> and `bms_channel`.`channel_type` like concat('%',#{query.channelType},'%') </if>
<if test="query.channelName != null and query.channelName != ''"> and `bms_channel_point`.`channel_name` like concat('%',#{query.channelName},'%') </if>
<if test="query.channelCode != null and query.channelCode != ''"> and `bms_channel_point`.`channel_code` like concat('%',#{query.channelCode},'%') </if>
<if test="query.pointCode != null and query.pointCode != ''"> and `bms_channel_point`.`point_code` like concat('%',#{query.pointCode},'%') </if>
<if test="query.pointName != null and query.pointName != ''"> and `bms_channel_point`.`point_name` like concat('%',#{query.pointName},'%') </if>
<if test="query.shopArea != null and query.shopArea != ''"> and `bms_channel_point`.`shop_area` = #{query.shopArea}</if>

401
src/main/resources/mapper/seeyon/CommonCheckMapper.xml

@ -5,82 +5,381 @@
<mapper namespace="com.qs.serve.modules.seeyon.mapper.CommonCheckMapper">
<select id="pageCallbackList" resultType="com.qs.serve.modules.seeyon.entity.vo.TodoVO">
select
<if test="query.targetType == 'CostBill'">
select
'CostBill' as target_type,
cost.id as target_id,
cost.`code` as target_code,
cost.charge_theme as title,
cost.submit_time
from tbs_cost_apply cost where cost.charge_state = 4 and cost.user_id = #{query.userId} and cost.del_flag = 0
UNION
select
cost.submit_time as `time`
from tbs_cost_apply cost where cost.charge_state = 4 and cost.user_id = #{query.userId} and cost.del_flag = 0
<if test="query.title !=null and query.title != ''">
and cost.charge_theme like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and cost.code like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and cost.submit_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and cost.submit_time &lt;= #{query.endDate}
</if>
</if>
<if test="query.targetType == 'ReleasePolicy'">
select
'ReleasePolicy' as target_type,
policy.id as target_id,
policy.policy_code as target_code,
policy.title,
policy.submit_time
from tzc_policy policy where policy.policy_status = 4 and policy.user_id = #{query.userId} and policy.del_flag = 0
UNION
select
policy.submit_time as `time`
from tzc_policy policy where policy.policy_status = 4 and policy.user_id = #{query.userId} and policy.del_flag = 0
<if test="query.title !=null and query.title != ''">
and policy.title like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and policy.policy_code like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and policy.submit_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and policy.submit_time &lt;= #{query.endDate}
</if>
</if>
<if test="query.targetType == 'CheckCost'">
select
'CheckCost' as target_type,
vtb.id as target_id,
vtb.`verification_code` as target_code,
act.act_title as title,
vtb.create_time as submit_time
from vtb_verification vtb
left join tbs_activity act on vtb.activity_id = act.id
where vtb.verification_state = 3 and vtb.user_id = #{query.userId} and act.del_flag = 0 and vtb.del_flag = 0
UNION
select
vtb.create_time as `time`
from vtb_verification vtb
left join tbs_activity act on vtb.activity_id = act.id
where vtb.verification_state = 3 and vtb.user_id = #{query.userId} and act.del_flag = 0 and vtb.del_flag = 0
<if test="query.title !=null and query.title != ''">
and act.act_title like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and vtb.`verification_code` like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and vtb.create_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and vtb.create_time &lt;= #{query.endDate}
</if>
</if>
<if test="query.targetType == 'budgetAdjust'">
select
'budgetAdjust' as target_type,
budget.id as target_id,
budget.budget_number as target_code,
budget.budget_code as title,
budget.submit_time
from tbs_budget budget
where budget.budget_check_state = 3 and budget.user_id = #{query.userId} and budget.del_flag = 0
UNION
select
budget.submit_time as `time`
from tbs_budget budget
where budget.budget_check_state = 3 and budget.user_id = #{query.userId} and budget.del_flag = 0
<if test="query.title !=null and query.title != ''">
and budget.budget_code like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and budget.budget_number like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and budget.submit_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and budget.submit_time &lt;= #{query.endDate}
</if>
</if>
<if test="query.targetType == 'budgetAdjust2'">
select
'budgetAdjust2' as target_type,
budget_change.id as target_id,
budget_change.change_code as target_code,
budget_change.budget_title as title,
budget_change.submit_time
from tbs_budget_change budget_change
where budget_change.budget_check_state = 3 and budget_change.user_id = #{query.userId} and budget_change.del_flag = 0
budget_change.submit_time as `time`
from tbs_budget_change budget_change
where budget_change.budget_check_state = 3 and budget_change.user_id = #{query.userId} and budget_change.del_flag = 0
<if test="query.title !=null and query.title != ''">
and budget_change.budget_title like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and budget_change.change_code like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and budget_change.submit_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and budget_change.submit_time &lt;= #{query.endDate}
</if>
</if>
<if test="query.targetType == null ">
select
'CostBill' as target_type,
cost.id as target_id,
cost.`code` as target_code,
cost.charge_theme as title,
cost.submit_time as `time`
from tbs_cost_apply cost where cost.charge_state = 4 and cost.user_id = #{query.userId} and cost.del_flag = 0
<if test="query.title !=null and query.title != ''">
and cost.charge_theme like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and cost.code like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and cost.submit_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and cost.submit_time &lt;= #{query.endDate}
</if>
UNION
select
'ReleasePolicy' as target_type,
policy.id as target_id,
policy.policy_code as target_code,
policy.title,
policy.submit_time
from tzc_policy policy where policy.policy_status = 4 and policy.user_id = #{query.userId} and policy.del_flag = 0
<if test="query.title !=null and query.title != ''">
and policy.title like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and policy.policy_code like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and policy.submit_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and policy.submit_time &lt;= #{query.endDate}
</if>
UNION
select
'CheckCost' as target_type,
vtb.id as target_id,
vtb.`verification_code` as target_code,
act.act_title as title,
vtb.create_time as `time`
from vtb_verification vtb
left join tbs_activity act on vtb.activity_id = act.id
where vtb.verification_state = 3 and vtb.user_id = #{query.userId} and act.del_flag = 0 and vtb.del_flag = 0
<if test="query.title !=null and query.title != ''">
and act.act_title like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and vtb.`verification_code` like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and vtb.create_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and vtb.create_time &lt;= #{query.endDate}
</if>
UNION
select
'budgetAdjust' as target_type,
budget.id as target_id,
budget.budget_number as target_code,
budget.budget_code as title,
budget.submit_time as `time`
from tbs_budget budget
where budget.budget_check_state = 3 and budget.user_id = #{query.userId} and budget.del_flag = 0
<if test="query.title !=null and query.title != ''">
and budget.budget_code like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and budget.budget_number like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and budget.submit_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and budget.submit_time &lt;= #{query.endDate}
</if>
UNION
select
'budgetAdjust2' as target_type,
budget_change.id as target_id,
budget_change.change_code as target_code,
budget_change.budget_title as title,
budget_change.submit_time as `time`
from tbs_budget_change budget_change
where budget_change.budget_check_state = 3 and budget_change.user_id = #{query.userId} and budget_change.del_flag = 0
<if test="query.title !=null and query.title != ''">
and budget_change.budget_title like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and budget_change.change_code like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and budget_change.submit_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and budget_change.submit_time &lt;= #{query.endDate}
</if>
</if>
limit #{query.startRow},#{query.pageSize}
</select>
<select id="countCallback" resultType="java.lang.Long">
select count(0) from (
select
'CostBill' as target_type,
cost.id as target_id
from tbs_cost_apply cost where cost.charge_state = 4 and cost.user_id = #{query.userId} and cost.del_flag = 0
UNION
select
'ReleasePolicy' as target_type,
policy.id as target_id
from tzc_policy policy where policy.policy_status = 4 and policy.user_id = #{query.userId} and policy.del_flag = 0
UNION
select
'CheckCost' as target_type,
vtb.id as target_id
from vtb_verification vtb
left join tbs_activity act on vtb.activity_id = act.id
where vtb.verification_state = 3 and vtb.user_id = #{query.userId} and vtb.del_flag = 0
UNION
select
'budgetAdjust' as target_type,
budget.id as target_id
from tbs_budget budget
where budget.budget_check_state = 3 and budget.user_id = #{query.userId} and budget.del_flag = 0
UNION
select
'budgetAdjust2' as target_type,
budget_change.id as target_id
from tbs_budget_change budget_change
where budget_change.budget_check_state = 3 and budget_change.user_id = #{query.userId} and budget_change.del_flag = 0
<if test="query.targetType == 'CostBill'">
select
'CostBill' as target_type,
cost.id as target_id
from tbs_cost_apply cost where cost.charge_state = 4 and cost.user_id = #{query.userId} and cost.del_flag = 0
<if test="query.title !=null and query.title != ''">
and cost.charge_theme like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and cost.code like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and cost.submit_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and cost.submit_time &lt;= #{query.endDate}
</if>
</if>
<if test="query.targetType == 'ReleasePolicy'">
select
'ReleasePolicy' as target_type,
policy.id as target_id
from tzc_policy policy where policy.policy_status = 4 and policy.user_id = #{query.userId} and policy.del_flag = 0
<if test="query.title !=null and query.title != ''">
and policy.title like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and policy.policy_code like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and policy.submit_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and policy.submit_time &lt;= #{query.endDate}
</if>
</if>
<if test="query.targetType == 'CheckCost'">
select
'CheckCost' as target_type,
vtb.id as target_id
from vtb_verification vtb
left join tbs_activity act on vtb.activity_id = act.id
where vtb.verification_state = 3 and vtb.user_id = #{query.userId} and vtb.del_flag = 0
</if>
<if test="query.targetType == 'budgetAdjust'">
select
'budgetAdjust' as target_type,
budget.id as target_id
from tbs_budget budget
where budget.budget_check_state = 3 and budget.user_id = #{query.userId} and budget.del_flag = 0
</if>
<if test="query.targetType == 'budgetAdjust2'">
select
'budgetAdjust2' as target_type,
budget_change.id as target_id
from tbs_budget_change budget_change
where budget_change.budget_check_state = 3 and budget_change.user_id = #{query.userId} and budget_change.del_flag = 0
</if>
<if test="query.targetType == null ">
select
'CostBill' as target_type,
cost.id as target_id
from tbs_cost_apply cost where cost.charge_state = 4 and cost.user_id = #{query.userId} and cost.del_flag = 0
<if test="query.title !=null and query.title != ''">
and cost.charge_theme like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and cost.code like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and cost.submit_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and cost.submit_time &lt;= #{query.endDate}
</if>
union
select
'ReleasePolicy' as target_type,
policy.id as target_id
from tzc_policy policy where policy.policy_status = 4 and policy.user_id = #{query.userId} and policy.del_flag = 0
<if test="query.title !=null and query.title != ''">
and policy.title like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and policy.policy_code like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and policy.submit_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and policy.submit_time &lt;= #{query.endDate}
</if>
union
select
'CheckCost' as target_type,
vtb.id as target_id
from vtb_verification vtb
left join tbs_activity act on vtb.activity_id = act.id
where vtb.verification_state = 3 and vtb.user_id = #{query.userId} and vtb.del_flag = 0
<if test="query.title !=null and query.title != ''">
and act.act_title like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and vtb.`verification_code` like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and vtb.create_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and vtb.create_time &lt;= #{query.endDate}
</if>
union
select
'budgetAdjust' as target_type,
budget.id as target_id
from tbs_budget budget
where budget.budget_check_state = 3 and budget.user_id = #{query.userId} and budget.del_flag = 0
<if test="query.title !=null and query.title != ''">
and budget.budget_code like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and budget.budget_number like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and budget.submit_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and budget.submit_time &lt;= #{query.endDate}
</if>
union
select
'budgetAdjust2' as target_type,
budget_change.id as target_id
from tbs_budget_change budget_change
where budget_change.budget_check_state = 3 and budget_change.user_id = #{query.userId} and budget_change.del_flag = 0
<if test="query.title !=null and query.title != ''">
and budget_change.budget_title like concat('%',#{query.title},'%')
</if>
<if test="query.targetCode !=null and query.targetCode != ''">
and budget_change.change_code like concat('%',#{query.targetCode},'%')
</if>
<if test="query.startDate !=null">
and budget_change.submit_time &gt;= #{query.startDate}
</if>
<if test="query.endDate !=null">
and budget_change.submit_time &lt;= #{query.endDate}
</if>
</if>
) tmp_tb
</select>

5
src/main/resources/mapper/tbs/TbsBudgetMapper.xml

@ -79,8 +79,9 @@
#{selectId}
</foreach>
</if>
<if test="query.budgetNumber !=null "> and `tbs_budget`.`budget_number` like concat('%',#{query.budgetNumber},'%')</if>
<if test="query.budgetNumber !=null and query.budgetNumber !='' "> and `tbs_budget`.`budget_number` like concat('%',#{query.budgetNumber},'%')</if>
<if test="query.budgetState !=null "> and `tbs_budget`.`budget_state` = #{query.budgetState}</if>
<if test="query.budgetCheckState !=null "> and `tbs_budget`.`budget_check_state` = #{query.budgetCheckState}</if>
<if test="query.budgetCode != null and query.budgetCode != ''"> and `tbs_budget`.`budget_code` like concat('%',#{query.budgetCode},'%')</if>
<if test="query.subjectValue != null and query.subjectValue != ''">
and (
@ -98,7 +99,7 @@
</if>
<if test="query.scheduleId != null"> and `tbs_budget`.`schedule_id` = #{query.scheduleId}</if>
<if test="query.scheduleCode != null and query.scheduleCode != ''"> and `tbs_budget`.`schedule_code` = #{query.scheduleCode}</if>
<if test="query.scheduleName != null and query.scheduleName != ''"> and `tbs_budget`.`schedule_name` = #{query.scheduleName}</if>
<if test="query.scheduleName != null and query.scheduleName != ''"> and `tbs_budget`.`schedule_name` like concat('%',#{query.scheduleName},'%') </if>
<if test="query.brandValue != null and query.brandValue != ''">
and (
`tbs_budget_condition`.`target_type` = 'brand'

2
src/main/resources/mapper/tbs/TbsCostApplyMapper.xml

@ -51,6 +51,7 @@
tbs_cost_apply.`supplier_biz_region_second_name`,
tbs_cost_apply.`supplier_biz_region_third_name`,
tbs_cost_apply.`charge_state`,
tbs_cost_apply.`check_state`,
tbs_cost_apply.`submit_time`,
tbs_cost_apply.`pass_time`,
tbs_cost_apply.`remark`,
@ -142,6 +143,7 @@
<sql id="baseWhere4CostApply">
<if test="query.checkState != null"> and `tbs_cost_apply`.`check_state` = #{query.checkState}</if>
<if test="query.id != null"> and `tbs_cost_apply`.`id` = #{query.id}</if>
<if test="query.code != null and query.code != ''"> and `tbs_cost_apply`.`code` like concat('%', #{query.code},'%')</if>
<if test="query.chargeTheme != null and query.chargeTheme != ''"> and `tbs_cost_apply`.`charge_theme` like concat('%', #{query.chargeTheme},'%')</if>

Loading…
Cancel
Save