<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<activity id="__GXGz8oGpxJIpMJQInRt">
  <name>审核不通过</name>
  <parentId>__la9YgIPe4fruZaIQJkV</parentId>
  <applicationid>__LgZds5MVHW3o08T7UcX</applicationid>
  <type>13</type>
  <onActionFlow></onActionFlow>
  <onActionPrint></onActionPrint>
  <colorType>danger</colorType>
  <beforeActionScript><![CDATA[]]></beforeActionScript>
  <afterActionScript><![CDATA[]]></afterActionScript>
  <retractBeforeActionScript><![CDATA[]]></retractBeforeActionScript>
  <retractAfterActionScript><![CDATA[]]></retractAfterActionScript>
  <hiddenScript><![CDATA[]]></hiddenScript>
  <readonlyScript><![CDATA[(function(){
var trainingInstitutionAuditStatus = getItemValueAsString("trainingInstitutionAuditStatus"); 
if("0".equals(trainingInstitutionAuditStatus)){
    return false;
}else{
  return true;
}

})()]]></readonlyScript>
  <startFlowScript><![CDATA[							]]></startFlowScript>
  <editMode>0</editMode>
  <fileNameScript><![CDATA[]]></fileNameScript>
  <iconurl></iconurl>
  <orderno>2</orderno>
  <stateToShow></stateToShow>
  <parentForm>__la9YgIPe4fruZaIQJkV</parentForm>
  <jumpType>0</jumpType>
  <expSub>false</expSub>
  <icon></icon>
  <disableFlowNode>false</disableFlowNode>
  <changeFlowOperator>false</changeFlowOperator>
  <changeFlowCc>false</changeFlowCc>
  <multiLanguageLabel></multiLanguageLabel>
  <dispatcherMode>0</dispatcherMode>
  <dispatcherUrl><![CDATA[]]></dispatcherUrl>
  <dispatcherParams><![CDATA[[{"paramKey":"","paramValue":""}]]]></dispatcherParams>
  <jumpMode>0</jumpMode>
  <jumpActOpenType>0</jumpActOpenType>
  <withOld>false</withOld>
  <actionType>0</actionType>
  <actionDispatcherUrlScript><![CDATA[]]></actionDispatcherUrlScript>
  <actionSelection>0</actionSelection>
  <relatedFormId>选择</relatedFormId>
  <actionScript><![CDATA[(function(){   
  var loginno=getWebUser().getLoginno();
	var usid = getUserIdByLoginno(loginno);
  var internshipTime=getItemValueAsString("internshipTime"); 
   var idCardNo=getItemValueAsString("idCardNo"); 
   var appName = "考试管理";
   var appId=getApplication();
  var subject="";
  
   subject += "您" + internshipTime + "提交的实习记录培训学校审核不通过！" ;
var examId = getId();  
var process = getDocumentProcess();
var securityCompanyAuditStatus=getItemValueAsString("securityCompanyAuditStatus"); 
//println("jjjjjjjjjjjjjjjjjjjjjjjjjj"+securityCompanyAuditStatus);
var updateInfoDoc=findDocument(examId); 
updateInfoDoc.findItem("trainingInstitutionAuditStatus").setValue("2");
updateInfoDoc.findItem("trainingInstitutionAuditors").setValue(userName);
updateInfoDoc.findItem("internshipRecordStatus").setValue("2");
process.doUpdate(updateInfoDoc);
 
   var sqlsa="SELECT * from tlk_grade_registration where ITEM_IDCARDNO='"+idCardNo+"'";
  println("sqls====="+sqlsa);

  var datassa = queryByDSName("tms",sqlsa);
  if(datassa!=null){
   for(var iteratorsa = datassa.iterator();iteratorsa.hasNext();){
       var map2a = iteratorsa.next();//取值
       var learnId = map2a.get("ITEM_learnId");
      println("learnId====="+learnId);
     
     var sqlsb="select * from t_user where FIELD12='"+idCardNo+"'and DOMAINID='"+learnId+"'";
  println("sqlsb====="+sqlsb);

  var datassb = queryByDSName("obpm2",sqlsb);
  if(datassb!=null){
   for(var iteratorsb = datassb.iterator();iteratorsb.hasNext();){
       var map2b = iteratorsb.next();//取值
       var ids = map2b.get("ID");
      println("ids====="+ids);
     
   }}}}
  				var content = "";
     var texts ="";
     texts += "您" + internshipTime + "提交的实习记录培训学校审核不通过，不通过原因：[原因]。" ;
  				var appAvatar = "https://bcxin-saas-prod.obs.cn-north-1.myhuaweicloud.com:443/upload%2F2021-11-01%2F1635755240828768236.png";
  				var title = "";
  				var titleImg = "";
  				var actionName = "";
   				var actionUrl = "";
   				 content += "appName=" + appName + "&&;" ; //应用名称
   content += "appId=" + appId + "&&;" ;  //应用id
  content += "appAvatar=" + appAvatar + "&&;" ;  //应用图标
        content += "title=" + title + "&&;" ; //标题
        content += "titleImg=" + titleImg + "&&;" ;  //标题图标
        content += "actionName=" + actionName + "&&;" ;   //操作名称
        content += "actionUrl=" + actionUrl + "&&;" ;   //操作链接
          content += "content=" + texts + ""; 
 println("usid==>" + usid);
     println("ids======>" + ids);
     println("subject==>" + subject);
sendMessage(usid,ids,subject,content);
})()]]></actionScript>
  <workFlowType>0</workFlowType>
  <contextMenu>false</contextMenu>
  <showInToolbar>true</showInToolbar>
  <transpond>选择</transpond>
  <targetList>ism1EiHqAkpLpSd2Zr7|</targetList>
  <label><![CDATA[]]></label>
</activity>