strBuffer.append("status='已核准' and nextdate < dbo.GetLocalDate(DEFAULT) ").append(" and (frequnit not in ('NOON','6.乙','7.丙') ").append(" or (frequnit='NOON' and DATENAME(HOUR, dbo.GetLocalDate(DEFAULT))>=12) ").append(" or (frequnit='6.乙' and DATENAME(HOUR, dbo.GetLocalDate(DEFAULT))>=13) ").append(" or (frequnit='7.丙' and DATENAME(HOUR, dbo.GetLocalDate(DEFAULT))>=19) ) ").append(" and (not exists(select 1 from timeline where num=rtinspcplan.rtinsplnum and siteid=rtinspcplan.siteid) ").append("\t\tor exists(select 1 from timeline where num=rtinspcplan.rtinsplnum and siteid=rtinspcplan.siteid ").append("\t\tand flag=0 and (rtinspcplan.nextdate-0.02084+substring( convert(varchar,starttime,120),12,16))<(dbo.GetLocalDate(DEFAULT))) ").append("\t) ");
strBuffer.append("status='已核准' and nextdate < dbo.GetLocalDate(DEFAULT) ").append(" and (frequnit not in ('NOON','6.乙','7.丙') ").append(" or (frequnit='NOON' and DATENAME(HOUR, dbo.GetLocalDate(DEFAULT))>=12) ").append(" or (frequnit='6.乙' and DATENAME(HOUR, dbo.GetLocalDate(DEFAULT))>=13) ").append(" or (frequnit='7.丙' and DATENAME(HOUR, dbo.GetLocalDate(DEFAULT))>=19) ) ").append(" and (not exists(select 1 from timeline where num=rtinspcplan.rtinsplnum and siteid=rtinspcplan.siteid) ").append("\t\tor exists(select 1 from timeline where num=rtinspcplan.rtinsplnum and siteid=rtinspcplan.siteid ").append("\t\tand flag=0 and (rtinspcplan.nextdate-0.02084+substring( convert(varchar,starttime,120),12,16))<(dbo.GetLocalDate(DEFAULT))) ").append("\t) ");
rtInspcSet.setWhere("RTINSPLNUM is not null and not exists(select 1 from wfassignment where ownerid=rtinspection.routinginspectionid and ownertable='RTINSPECTION' and assignstatus='ACTIVE') and historyflag=0 and status in ('草稿','已核准') and datediff(day,rtinspcdate,dbo.GetLocalDate(DEFAULT))<=1");
rtInspcSet.setWhere("RTINSPLNUM is not null and not exists(select 1 from wfassignment where ownerid=rtinspection.routinginspectionid and ownertable='RTINSPECTION' and assignstatus='ACTIVE') and historyflag=0 and status in ('草稿','已核准') and datediff(day,rtinspcdate,dbo.GetLocalDate(DEFAULT))<=1");
MboSetRemotewfment=this.getMboSet("$wfassignment","wfassignment","ownerid='"+this.getInt("rfqid")+"' and assignstatus='ACTIVE' and assigncode='"+this.getUserInfo().getPersonId().toUpperCase()+"' and ownertable='"+this.getName().toUpperCase()+"'");
MboSetRemoteprSet=this.getMboSet("$rfq","rfq","custcode=(select custcode from rfq,(select '%'+max(SUBSTRING(custcode,14,3)) b from rfq where siteid='"+siteid+"')a where custcode like a.b)");
synchronized(this){
MboSetRemoteprSet=getMboSet("$rfq","rfq","custcode=(select custcode from rfq,(select '%'+max(SUBSTRING(custcode,14,3)) b from rfq where siteid='"+siteid+"')a where custcode like a.b)");
System.out.println("custcode=(select custcode from rfq,(select '%'+max(SUBSTRING(custcode,14,3)) b from rfq where siteid='"+siteid+"')a where custcode like a.b)");
@@ -22,7 +22,7 @@ public class CustPjobehaviornoDataBean extends MultiselectDataBean{
RemoteException{
DataBeanappBean=app.getAppBean();
MboRemotegroupMbo=appBean.getMbo();
MboSetRemotems=super.getMboSetRemote();;
MboSetRemotems=super.getMboSetRemote();
System.out.println(" behaviortype=2 and TREATMENTMETHOD = 2 and (wonum is NULL or wonum ='') and pjoobservationid ='"+groupMbo.getLong("PJOOBSERVATIONID")+"'");
ms.setWhere(" behaviortype=2 and TREATMENTMETHOD = 2 and (wonum is NULL or wonum ='') and pjoobservationid ='"+groupMbo.getLong("PJOOBSERVATIONID")+"'");
returnms;
...
...
@@ -37,8 +37,13 @@ public class CustPjobehaviornoDataBean extends MultiselectDataBean{