支行名称改为关联sys_dept表获取

This commit is contained in:
CYQ 2025-10-21 16:45:38 +08:00
parent 4009c675c4
commit 0f7bff9922

View File

@ -52,11 +52,11 @@ public class MarketingValidInvalidProcessor extends AbstractBusinessProcessor {
" ,record_month " + " ,record_month " +
")( " + ")( " +
"select " + "select " +
" dept_name " + " e.dept_name " +
" ,jb_name " + " ,a.jb_name " +
" ,jb_id " + " ,a.jb_id " +
" ,cust_name " + " ,a.cust_name " +
" ,cust_id " + " ,a.cust_id " +
" ,CASE " + " ,CASE " +
" WHEN check_flag='9' " + " WHEN check_flag='9' " +
" then subcategory_name " + " then subcategory_name " +
@ -75,14 +75,15 @@ public class MarketingValidInvalidProcessor extends AbstractBusinessProcessor {
" ,? " + " ,? " +
"from mps_market a " + "from mps_market a " +
"INNER JOIN sys_user b ON a.jb_id = b.mkt_no AND b.del_flag = '0' " + "INNER JOIN sys_user b ON a.jb_id = b.mkt_no AND b.del_flag = '0' " +
"left join sys_dept e ON b.dept_id = e.dept_id " +
"where SUBSTR(a.entry_date,1,7)=? and a.del_flag='0' and a.check_flag<>'0' " + "where SUBSTR(a.entry_date,1,7)=? and a.del_flag='0' and a.check_flag<>'0' " +
"union " + "union " +
"select " + "select " +
" dept_name " + " e.dept_name " +
" ,yx_name " + " ,a.yx_name " +
" ,yx_id " + " ,a.yx_id " +
" ,cust_name " + " ,a.cust_name " +
" ,cust_id " + " ,a.cust_id " +
" ,CASE " + " ,CASE " +
" WHEN check_flag='9' " + " WHEN check_flag='9' " +
" then subcategory_name " + " then subcategory_name " +
@ -101,6 +102,7 @@ public class MarketingValidInvalidProcessor extends AbstractBusinessProcessor {
" ,? " + " ,? " +
"from mps_market a " + "from mps_market a " +
"INNER JOIN sys_user b ON a.yx_id = b.mkt_no AND b.del_flag = '0' " + "INNER JOIN sys_user b ON a.yx_id = b.mkt_no AND b.del_flag = '0' " +
"left join sys_dept e ON b.dept_id = e.dept_id " +
"where SUBSTR(a.entry_date,1,7)=? and a.del_flag='0' and a.check_flag<>'0' " + "where SUBSTR(a.entry_date,1,7)=? and a.del_flag='0' and a.check_flag<>'0' " +
")"; ")";