Beispiel #1
0
        private void RegisterServer(object ob)
        {
            if (IsInstall() == false)
            {
                return;
            }
            if (yws == null)
            {
                yws = new YWSUI.YWS();
            }

            string ss = "";

            try
            {
                Doctor doctor = (Doctor)ob;
                ss = "<?xml version='1.0' ?><base_xml><source>HIS</source><hosp_code>" + FrmMdiMain.Jgbm + "</hosp_code><dept_code>" + FrmMdiMain.CurrentDept.DeptId + "</dept_code><dept_name>" + FrmMdiMain.CurrentDept.DeptName + "</dept_name><doct><code>" + FrmMdiMain.CurrentUser.EmployeeId + "</code><name>" + FrmMdiMain.CurrentUser.Name + "</name><type>" + doctor.TypeID + "</type><type_name>" + doctor.ZcjbMc + "</type_name ></doct></base_xml>";
            }
            catch
            {
                ss = "<?xml version='1.0' ?><base_xml><source>HIS</source><hosp_code>" + FrmMdiMain.Jgbm + "</hosp_code><dept_code>" + FrmMdiMain.CurrentDept.DeptId + "</dept_code><dept_name>" + FrmMdiMain.CurrentDept.DeptName + "</dept_name><doct><code>" + FrmMdiMain.CurrentUser.EmployeeId + "</code><name>" + FrmMdiMain.CurrentUser.Name + "</name><type>" + "" + "</type><type_name>" + "" + "</type_name ></doct></base_xml>";
            }
            string refss = "";

            yws.YWS_UI(1, ss, "", ref refss);
        }
Beispiel #2
0
        void HlyyInterface.SaveXml(StringBuilder sb)
        {
            if (IsInstall() == false)
            {
                return;
            }
            if (yws == null)
            {
                yws = new YWSUI.YWS();
            }

            string ss = "";

            try
            {
                Doctor doctor = new Doctor(FrmMdiMain.CurrentUser.EmployeeId, FrmMdiMain.Database);
                ss = "<?xml version='1.0' ?><base_xml><source>HIS</source><hosp_code>" + FrmMdiMain.Jgbm + "</hosp_code><dept_code>" + FrmMdiMain.CurrentDept.DeptId + "</dept_code><dept_name>" + FrmMdiMain.CurrentDept.DeptName + "</dept_name><doct><code>" + FrmMdiMain.CurrentUser.EmployeeId + "</code><name>" + FrmMdiMain.CurrentUser.Name + "</name><type>" + doctor.TypeID + "</type><type_name>" + doctor.ZcjbMc + "</type_name ></doct></base_xml>";
            }
            catch
            {
                ss = "<?xml version='1.0' ?><base_xml><source>HIS</source><hosp_code>" + FrmMdiMain.Jgbm + "</hosp_code><dept_code>" + FrmMdiMain.CurrentDept.DeptId + "</dept_code><dept_name>" + FrmMdiMain.CurrentDept.DeptName + "</dept_name><doct><code>" + FrmMdiMain.CurrentUser.EmployeeId + "</code><name>" + FrmMdiMain.CurrentUser.Name + "</name><type>" + "" + "</type><type_name>" + "" + "</type_name ></doct></base_xml>";
            }
            string refss = "";

            yws.YWS_UI(11, ss, "<?xml version='1.0' ?>" + sb.ToString(), ref refss);
        }
Beispiel #3
0
        int HlyyInterface.SaveDrug(StringBuilder sb, int ZyOrMz)
        {
            if (IsInstall() == false)
            {
                return(0);
            }
            if (yws == null)
            {
                yws = new YWSUI.YWS();
            }

            string ss = "";

            try
            {
                Doctor doctor = new Doctor(FrmMdiMain.CurrentUser.EmployeeId, FrmMdiMain.Database);
                ss = "<?xml version='1.0' ?><base_xml><source>HIS</source><hosp_code>" + FrmMdiMain.Jgbm + "</hosp_code><dept_code>" + FrmMdiMain.CurrentDept.DeptId + "</dept_code><dept_name>" + FrmMdiMain.CurrentDept.DeptName + "</dept_name><doct><code>" + FrmMdiMain.CurrentUser.EmployeeId + "</code><name>" + FrmMdiMain.CurrentUser.Name + "</name><type>" + doctor.TypeID + "</type><type_name>" + doctor.ZcjbMc + "</type_name ></doct></base_xml>";
            }
            catch
            {
                ss = "<?xml version='1.0' ?><base_xml><source>HIS</source><hosp_code>" + FrmMdiMain.Jgbm + "</hosp_code><dept_code>" + FrmMdiMain.CurrentDept.DeptId + "</dept_code><dept_name>" + FrmMdiMain.CurrentDept.DeptName + "</dept_name><doct><code>" + FrmMdiMain.CurrentUser.EmployeeId + "</code><name>" + FrmMdiMain.CurrentUser.Name + "</name><type>" + "" + "</type><type_name>" + "" + "</type_name ></doct></base_xml>";
            }
            string refss = "";

            try
            {
                XmlDocument xdoc = new XmlDocument();
                xdoc.LoadXml(sb.ToString());
                XmlNode xmlnoe = xdoc.SelectSingleNode("//diagnose");

                // 创建节点
                xmlnoe.Attributes[0].Value = "2";
                sb = new StringBuilder(xdoc.OuterXml);
            }
            catch { }
            int i = Convert.ToInt32(yws.YWS_UI(8, ss, "<?xml version='1.0' ?>" + sb.ToString(), ref refss));

            //5-	0.无问题	1.其他问题2.一般问题严重问
            if (i == 1 || i == 2)
            {
                i = 1;
            }
            //3是有严重问题
            if (i == 3)
            {
                i = 2;
            }

            if (i == 8)
            {
                i = 2;
            }
            return(i);
        }
Beispiel #4
0
        /// <summary>
        /// 结果分析
        /// </summary>
        /// <param name="sb"></param>
        /// <param name="ZyOrMz"></param>
        /// <returns></returns>
        int HlyyInterface.DrugAnalysis(StringBuilder sb, int ZyOrMz)
        {
            int        offset = 0;
            StackTrace st     = new StackTrace();
            StackFrame frame  = new StackFrame(offset++);
            int        kk     = st.GetFrames().Length;
            string     ss1    = "";

            for (int ix = 0; ix < kk; ix++)
            {
                if (st.GetFrames()[ix].GetMethod().Name.Trim() == "FrmYZGL_Load")
                {
                    return(0);
                }
            }
            if (IsInstall() == false)
            {
                return(0);
            }
            if (yws == null)
            {
                yws = new YWSUI.YWS();
            }

            string ss = "";

            try
            {
                Doctor doctor = new Doctor(FrmMdiMain.CurrentUser.EmployeeId, FrmMdiMain.Database);
                ss = "<?xml version='1.0' ?><base_xml><source>HIS</source><hosp_code>" + FrmMdiMain.Jgbm + "</hosp_code><dept_code>" + FrmMdiMain.CurrentDept.DeptId + "</dept_code><dept_name>" + FrmMdiMain.CurrentDept.DeptName + "</dept_name><doct><code>" + FrmMdiMain.CurrentUser.EmployeeId + "</code><name>" + FrmMdiMain.CurrentUser.Name + "</name><type>" + doctor.TypeID + "</type><type_name>" + doctor.ZcjbMc + "</type_name ></doct></base_xml>";
            }
            catch
            {
                ss = "<?xml version='1.0' ?><base_xml><source>HIS</source><hosp_code>" + FrmMdiMain.Jgbm + "</hosp_code><dept_code>" + FrmMdiMain.CurrentDept.DeptId + "</dept_code><dept_name>" + FrmMdiMain.CurrentDept.DeptName + "</dept_name><doct><code>" + FrmMdiMain.CurrentUser.EmployeeId + "</code><name>" + FrmMdiMain.CurrentUser.Name + "</name><type>" + "" + "</type><type_name>" + "" + "</type_name ></doct></base_xml>";
            }
            string refss = "";

            try
            {
                XmlDocument xdoc = new XmlDocument();
                xdoc.LoadXml(sb.ToString());
                XmlNode xmlnoe = xdoc.SelectSingleNode("//diagnose");

                // 创建节点
                xmlnoe.Attributes[0].Value = "2";
                sb = new StringBuilder(xdoc.OuterXml);
            }
            catch { }
            int i = Convert.ToInt32(yws.YWS_UI(6, ss, "<?xml version='1.0' ?>" + sb.ToString(), ref refss));

            return(i);
        }
Beispiel #5
0
        /// <summary>
        /// 显示药点提示
        /// </summary>
        /// <param name="sb"></param>
        void HlyyInterface.ShowPoint(StringBuilder sb)
        {
            if (IsInstall() == false)
            {
                return;
            }
            int    offset = 0;
            string str    = "";

            // StackTrace st = new StackTrace();
            // StackFrame frame = new StackFrame(offset++);
            //int kk=st.GetFrames().Length;
            // for (int i = 0; i <kk ; i++)
            // {
            //    if( st.GetFrames()[i].GetMethod().Name.Trim()=="GetCardData")
            //        return ;
            // }

            //   if (frame.GetMethod() == null) break;
            // str += frame.GetMethod().Name + "\r\n";
            //如果偏移位置没有函数时,则GetMethod方法返回null



            if (yws == null)
            {
                yws = new YWSUI.YWS();
            }

            string ss = "";

            try
            {
                Doctor doctor = new Doctor(FrmMdiMain.CurrentUser.EmployeeId, FrmMdiMain.Database);
                ss = "<?xml version='1.0' ?><base_xml><source>HIS</source><hosp_code>" + FrmMdiMain.Jgbm + "</hosp_code><dept_code>" + FrmMdiMain.CurrentDept.DeptId + "</dept_code><dept_name>" + FrmMdiMain.CurrentDept.DeptName + "</dept_name><doct><code>" + FrmMdiMain.CurrentUser.EmployeeId + "</code><name>" + FrmMdiMain.CurrentUser.Name + "</name><type>" + doctor.TypeID + "</type><type_name>" + doctor.ZcjbMc + "</type_name ></doct></base_xml>";
            }
            catch
            {
                ss = "<?xml version='1.0' ?><base_xml><source>HIS</source><hosp_code>" + FrmMdiMain.Jgbm + "</hosp_code><dept_code>" + FrmMdiMain.CurrentDept.DeptId + "</dept_code><dept_name>" + FrmMdiMain.CurrentDept.DeptName + "</dept_name><doct><code>" + FrmMdiMain.CurrentUser.EmployeeId + "</code><name>" + FrmMdiMain.CurrentUser.Name + "</name><type>" + "" + "</type><type_name>" + "" + "</type_name ></doct></base_xml>";
            }
            string refss = "";

            yws.YWS_UI(5, ss, sb.ToString(), ref refss);
        }
Beispiel #6
0
        int HlyyInterface.RegisterServer_fun(object[] _values)
        {
            if (IsInstall() == false)
            {
                return(1);
            }
            if (yws == null)
            {
                yws = new YWSUI.YWS();
            }

            string ss = "";

            try
            {
                Doctor doctor = new Doctor(FrmMdiMain.CurrentUser.EmployeeId, FrmMdiMain.Database);;
                ss = "<?xml version='1.0' ?><base_xml><source>HIS</source><hosp_code>" + FrmMdiMain.Jgbm + "</hosp_code><dept_code>" + FrmMdiMain.CurrentDept.DeptId + "</dept_code><dept_name>" + FrmMdiMain.CurrentDept.DeptName + "</dept_name><doct><code>" + FrmMdiMain.CurrentUser.EmployeeId + "</code><name>" + FrmMdiMain.CurrentUser.Name + "</name><type>" + doctor.TypeID + "</type><type_name>" + doctor.ZcjbMc + "</type_name ></doct></base_xml>";
            }
            catch
            {
                ss = "<?xml version='1.0' ?><base_xml><source>HIS</source><hosp_code>" + FrmMdiMain.Jgbm + "</hosp_code><dept_code>" + FrmMdiMain.CurrentDept.DeptId + "</dept_code><dept_name>" + FrmMdiMain.CurrentDept.DeptName + "</dept_name><doct><code>" + FrmMdiMain.CurrentUser.EmployeeId + "</code><name>" + FrmMdiMain.CurrentUser.Name + "</name><type>" + "" + "</type><type_name>" + "" + "</type_name ></doct></base_xml>";
            }
            string refss = "";

            yws.YWS_UI(1, ss, "", ref refss);

            //RelationalDatabase Database = new MsSqlServer();
            //Database.Initialize(FrmMdiMain.Database.ConnectionString);
            //Doctor doctor = new Doctor(FrmMdiMain.CurrentUser.EmployeeId, Database);
            //Database.Close();
            //Database.Dispose();
            // Invkoe d = new Invkoe(RegisterServer);
            //    AsyncCallback d1 = new AsyncCallback(ht);
            //    IAsyncResult hh = d.BeginInvoke(doctor,d1,null );

            return(1);
        }