Commit 245e7780 by lal

修复BUG

parent 0bf4ba3e
......@@ -22,6 +22,29 @@ public class ClockInTool {
static SimpleDateFormat famt = new SimpleDateFormat("yyyy-MM-dd");
/***
* 去除String数组中的空值
*/
public static String[] deleteArrayNull(String string[]) {
String strArr[] = string;
// step1: 定义一个list列表,并循环赋值
ArrayList<String> strList = new ArrayList<String>();
for (int i = 0; i < strArr.length; i++) {
strList.add(strArr[i]);
}
// step2: 删除list列表中所有的空值
while (strList.remove(null));
while (strList.remove(""));
// step3: 把list列表转换给一个新定义的中间数组,并赋值给它
String strArrLast[] = strList.toArray(new String[strList.size()]);
return strArrLast;
}
/**
* @param timeStr 修改的时间
* @param num 修改数字
......
......@@ -302,16 +302,21 @@
IFNULL(mrtj.duration,'') as balancedays
from kqgl_asso_month_punch_summary sum
LEFT JOIN (
select DISTINCT info.`name` as username ,
select DISTINCT info.`name` as username ,
dkjl.attdate,bcsz.id as bcszid,
bcsz.`name` as bcname,bcsz.sbdk1 as bcsbdk1,bcsz.xbdk1 as bcxbdk1,bcsz.sbdk2 as bcsbdk2,bcsz.xbdk2 as bcxbdk2,bcsz.sbdk3 as bcsbdk3,bcsz.xbdk3 as bcxbdk3,
dkmx.`userid`,dkmx.`data` ,dkmx.`sbdk1`,dkmx.`sbdk1jg`,dkmx.`xbdk1` ,dkmx.`xbdk1jg`,dkmx.`sbdk2` ,dkmx.`sbdk2jg` ,dkmx.`xbdk2` ,
dkmx.`xbdk2jg`,dkmx.`sbdk3` ,dkmx.`sbdk3jg` ,dkmx.`xbdk3`,dkmx.`xbdk3jg` ,dkmx.`ydkcs` ,dkmx.`gzsc` ,dkmx.`qyid`,dkmx.`dksj` ,
dkmx.`yzcdcs` ,dkmx.`yzcdsc` ,dkmx.`kgcdfzs`
from kqgl_asso_dkmx dkmx
LEFT JOIN yggl_main_emp as info on info.emp_num = dkmx.userid and info.org_code = 117
LEFT JOIN kqgl_asso_dkjl as dkjl on dkjl.dkmxid = dkmx.id
LEFT JOIN kqgl_asso_bcsz as bcsz on bcsz.id = dkjl.bcid
LEFT JOIN yggl_main_emp as info on info.emp_num = dkmx.userid and info.org_code = #{param.orgCode}
LEFT JOIN (select * from kqgl_asso_dkjl dkjl
where dkjl.id in (select MAX(dkjl.id) from kqgl_asso_dkjl dkjl
LEFT JOIN kqgl_asso_dkmx as dkmx on dkmx.id = dkjl.dkmxid
where dkmx.qyid = #{param.orgCode}
and dkmx.`data` = #{param.times}
GROUP BY dkjl.user_id)) as dkjl on dkjl.dkmxid = dkmx.id
LEFT JOIN kqgl_asso_bcsz as bcsz on bcsz.id = dkjl.bcid
where dkmx.qyid = #{param.orgCode}
and dkmx.`data` = #{param.times}
) as rtj on rtj.userid = sum.num
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment