/// <summary> /// 处方分析 /// </summary> private string AnalysisPresResult() { PresInfo presInfo = GetPresInfo(); string analysisResult = drugMonitor.AnalysisPres(presInfo); return(analysisResult); }
/// <summary> /// 分析医嘱用药的合理情况 /// </summary> /// <param name="ent4BannerDTO">banner数据</param> /// <param name="ciords">待校验用药合理性的医嘱</param> /// <param name="msg">验证结果的提示信息</param> /// <returns>验证状态 0 无问题,1 一般问题, 2 严重问题</returns> public override int AnalysisPresResult(CiEnContextDTO ctxDTO, CiOrderDO[] ciords, out string msg) { drugMonitor.BeginNewPres(); msg = ""; if (ciords == null || ciords.Length == 0) { return(DaTongConstant.RS_NOT_VERIFIED); } List <CiOrderDO> ciordList = new List <CiOrderDO>(); List <string> idOrList = new List <string>(); // 遍历医嘱,只需要校验药品的医嘱 foreach (CiOrderDO ciorder in ciords) { if (ciorder.Sd_srvtp.StartsWith(BdSrvDictCodeConst.SD_SRVTP_DRUG)) // 药品的进行检查 { ciordList.Add(ciorder); idOrList.Add(ciorder.Id_or); } } // 如果不存在药品,返回不需要验证 if (ciordList.Count == 0) { return(DaTongConstant.RS_NOT_VERIFIED); } PresInfo presInfo = GetPresInfo(ctxDTO, idOrList); // 进行处方分析 return(drugMonitor.AnalysisPres(presInfo, out msg)); }