diff --git a/src/weaver/haikang/cronjob/FlowLaowuZzService.java b/src/weaver/haikang/cronjob/FlowLaowuZzService.java index 7f133a4..ac83b5e 100644 --- a/src/weaver/haikang/cronjob/FlowLaowuZzService.java +++ b/src/weaver/haikang/cronjob/FlowLaowuZzService.java @@ -76,17 +76,22 @@ public class FlowLaowuZzService { recordSetb_1.executeUpdate(insertsql,1,-1,"HrmCustomFieldByInfoType",uid); log.error("howec:::::::::::::::::5:"+insertsql); }else { - String sqlx = "select "+zzzygxz+" from cus_fielddata where scopeid = -1 and scope = 'HrmCustomFieldByInfoType' and id = "+uid; - log.error("howec:::::::::::::::::6:"+sqlx); - recordSetd1.executeQuery(sqlx); - recordSetd1.next(); - String zzzygxz2 = recordSetd1.getString(zzzygxz); - if(zzzygxz2.length() == 0) { - String sql5 = "update cus_fielddata set "+zzzygxz+" = '1' where scopeid = -1 and scope = 'HrmCustomFieldByInfoType' and id = "+uid; - recordSetd.executeUpdate(sql5); - log.error("sql5 =::::::::::::5:"+sql5); + String sql3 = "select "+zzzrzlx+","+zzzsxrq+" from cus_fielddata where scopeid = 3 and scope = 'HrmCustomFieldByInfoType' and id = "+uid; + log.error("sql3x =::::::::::::3:"+sql3); + recordSetd1.executeQuery(sql3); + while (recordSetd1.next()) { + String zzzrzlx1 = recordSetd1.getString(zzzrzlx);//入职类型 + if(("1".equals(zzzrzlx1))) { + String sql5 = "update cus_fielddata set "+zzzygxz+" = '1' where scopeid = -1 and scope = 'HrmCustomFieldByInfoType' and id = "+uid; + recordSetd.executeUpdate(sql5); + log.error("sql5x =::::::::::::5:"+sql5); + } } } + //更新入职日期 + String rzrqsql = "update hrmresource set companystartdate = '"+date3+"' where id = "+uid; + recordSetd.executeUpdate(rzrqsql); + log.error("sql5-1 =::::::::::::5-1:"+rzrqsql); } } }