Ejemplo n.º 1
0
        /// <summary>
        /// 添加科室类型包含的科室
        /// </summary>
        /// <param name="type"></param>
        /// <param name="parent"></param>
        /// <param name="current"></param>
        /// <returns></returns>
        private int addDepts(string type, TreeNode parent, ref TreeNode current)
        {
            try
            {
                //获取type类型科室
                ArrayList depts = deptManager.GetDeptmentByType(type);
                if (depts == null)
                {
                    return(0);
                }
                //添加科室
                foreach (Neusoft.HISFC.Models.Base.Department dept in depts)
                {
                    TreeNode child = new TreeNode();
                    child.Text               = dept.Name;
                    child.Tag                = dept;
                    child.ImageIndex         = 40;
                    child.SelectedImageIndex = 40;

                    if (dept.ID == var.Dept.ID)
                    {
                        current = parent;
                    }

                    parent.Nodes.Add(child);
                }
            }
            catch (Exception e)
            {
                MessageBox.Show("获取科室列表出错!" + e.Message, "提示");
                return(-1);
            }
            return(0);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// 初始化
        /// </summary>
        public void InitWin()
        {
            if (this.m_objOpsApp == null)
            {
                return;
            }
            //姓名
            this.txtName.Text = this.m_objOpsApp.PatientInfo.Name;
            //科室
            this.txtDept.Text = deptManager.GetDepartment(m_objOpsApp.PatientInfo.PVisit.PatientLocation.Dept.ID.ToString()).Name;
            //住院号/门诊号
            this.txtPatientNo.Text = m_objOpsApp.PatientInfo.PID.ID.ToString();
            //原手术室
            if (m_objOpsApp.OperateRoom != null)
            {
                this.txtOldOpsRoom.Tag  = m_objOpsApp.OperateRoom.ID.ToString();
                this.txtOldOpsRoom.Text = m_objOpsApp.OperateRoom.Name;
                strNewOpsRoomID         = m_objOpsApp.OperateRoom.ID.ToString();
            }
            else
            {
                this.txtOldOpsRoom.Text = Environment.GetDept(m_objOpsApp.PatientInfo.PVisit.PatientLocation.Dept.ID).Name;
                //this.txtOldOpsRoom.Text = dept.GetDeptmentById(this.var.User.Dept.ID.ToString()).Name;
                //this.txtOldOpsRoom.Tag = this.var.User.Dept.ID.ToString();
                this.txtOldOpsRoom.Tag = m_objOpsApp.PatientInfo.PVisit.PatientLocation.Dept.ID;
            }
            //手术预约时间
            if (m_objOpsApp.PreDate != DateTime.MinValue)
            {
                this.dtpPreDate.Value = m_objOpsApp.PreDate;
            }
            else
            {
                this.dtpPreDate.Value = this.m_objOpsManager.GetDateTimeFromSysDateTime();
            }
            //手术室combox列表
            this.cmbOpsRoom.Items.Clear();
            ArrayList OpsRoomAl = new ArrayList();

            OpsRoomAl = deptManager.GetDeptmentByType("1");//"1"表示手术类型的科室
            this.cmbOpsRoom.AddItems(OpsRoomAl);
            //缺省选中原手术室
            this.cmbOpsRoom.Tag = this.m_objOpsApp.OperateRoom.ID.ToString();
            //手术台类型combox列表
            ArrayList alTableType = new ArrayList();

            //neusoft.neNeusoft.HISFC.Components.Object.neuObject obj = new neusoft.neNeusoft.HISFC.Components.Object.neuObject();
            Neusoft.FrameWork.Models.NeuObject obj = new Neusoft.FrameWork.Models.NeuObject();
            obj.ID   = "1";
            obj.Name = "正台";
            alTableType.Add(obj.Clone());
            obj.ID   = "2";
            obj.Name = "加台";
            alTableType.Add(obj.Clone());
            obj.ID   = "3";
            obj.Name = "点台";
            alTableType.Add(obj.Clone());
            this.cmbTableType.AddItems((ArrayList)(alTableType.Clone()));
            //缺省选中“正台”
            cmbTableType.SelectedIndex = 0;
        }