Beispiel #1
0
        private void LoadForm()
        {
            DeleteMetaFile();
            util = new DrawMainPageUtil(info);

            pictureBox1.Width  = GetPageWidth();
            pictureBox1.Height = GetPageHeight();
            pictureBox2.Width  = GetPageWidth();
            pictureBox2.Height = GetPageHeight();

            pictureBox1.BackgroundImage = util.MF1;
            pictureBox2.BackgroundImage = util.MF2;

            pictureBox1.BackgroundImageLayout = ImageLayout.Stretch;
            pictureBox2.BackgroundImageLayout = ImageLayout.Stretch;

            ReLocationPicture();
            BindParentFormCloseEvent();

            if (this.Parent != null)
            {
                if (this.Parent.AccessibleName != null && this.Parent.AccessibleName.Trim() != "")//父窗体的AccessibleName不为空则表示没有编辑的权限
                {
                    simpleButton1.Visible = false;
                    simpleButton2.Visible = false;
                    simpleButton3.Visible = false;
                    simpleButton4.Visible = false;
                    simpleButton5.Visible = false;
                    simpleButton6.Visible = false;
                }
            }

            Employee emp = new Employee(m_Host.User.Id);

            emp.ReInitializeProperties();

            if (emp.Grade.Trim() != "")
            {
                DoctorGrade grade = (DoctorGrade)Enum.Parse(typeof(DoctorGrade), emp.Grade);
                if (grade == DoctorGrade.Nurse)
                {
                    simpleButton3.Enabled = false;
                    simpleButton4.Enabled = false;
                    simpleButton5.Enabled = false;
                    simpleButton6.Enabled = false;
                }
            }
            else
            {
                simpleButton1.Enabled = false;
                simpleButton2.Enabled = false;
                simpleButton3.Enabled = false;
                simpleButton4.Enabled = false;
                simpleButton5.Enabled = false;
                simpleButton6.Enabled = false;
            }
        }
Beispiel #2
0
        private void LoadForm()
        {
            util = new DrawMainPageUtil(info);

            pictureBox1.Width  = GetPageWidth();
            pictureBox1.Height = GetPageHeight();
            pictureBox2.Width  = GetPageWidth();
            pictureBox2.Height = GetPageHeight();
            ma = util.GetPrintImage();
            pictureBox1.BackgroundImage = ma[0];
            pictureBox2.BackgroundImage = ma[1];

            pictureBox1.BackgroundImageLayout = ImageLayout.Stretch;
            pictureBox2.BackgroundImageLayout = ImageLayout.Stretch;

            ReLocationPicture();

            if (this.Parent != null)
            {
                if (this.Parent.AccessibleName != null &&
                    this.Parent.AccessibleName.Trim() != "")   //父窗体的AccessibleName不为空则表示没有编辑的权限
                {
                    btnBaseInfo.Visible   = false;
                    btnDialogInfo.Visible = false;
                    btnOperInfo.Visible   = false;
                    btnFeeInfo.Visible    = false;
                    btnExcInfo.Visible    = false;
                }
            }

            Employee emp = new Employee(m_Host.User.Id);

            emp.ReInitializeProperties();
            if (emp.Grade.Trim() != "")
            {
                DoctorGrade grade = (DoctorGrade)Enum.Parse(typeof(DoctorGrade), emp.Grade);
                if (grade == DoctorGrade.Nurse)
                {
                    btnDialogInfo.Enabled = false;
                    btnOperInfo.Enabled   = false;
                    btnFeeInfo.Enabled    = false;
                    btnExcInfo.Enabled    = false;
                }
            }
            else
            {
                btnBaseInfo.Enabled   = false;
                btnDialogInfo.Enabled = false;
                btnOperInfo.Enabled   = false;
                btnFeeInfo.Enabled    = false;
                btnExcInfo.Enabled    = false;
            }
        }
Beispiel #3
0
        private void LoadForm2()
        {
            manger                      = new IemMainPageManger(m_Host, CurrentInpatient);
            util                        = new DrawMainPageUtil(info);
            ma                          = util.GetPrintImage();
            pictureBox1.Width           = GetPageWidth();
            pictureBox1.Height          = GetPageHeight();
            pictureBox2.Width           = GetPageWidth();
            pictureBox2.Height          = GetPageHeight();
            pictureBox1.BackgroundImage = ma[0];
            pictureBox2.BackgroundImage = ma[1];

            ReLocationPicture();
        }
Beispiel #4
0
        public void Print()
        {
            //PrintForm printForm = new PrintForm(info);
            UCMainForm.IsSpecialPrintAgeOpen = true;   //判断是否打印开启

            if (GetConfigValueByKey("SpecialIEMMainPageAgePrint") == "1")
            {
                util = new DrawMainPageUtil(info);
            }
            PrintForm printForm = new PrintForm(util);

            printForm.WindowState = FormWindowState.Maximized;
            printForm.ShowDialog();
            UCMainForm.IsSpecialPrintAgeOpen = false;
        }
Beispiel #5
0
        private void LoadForm2()
        {
            manger = new IemMainPageManger(m_Host, CurrentInpatient);
            DeleteMetaFile();
            util = new DrawMainPageUtil(info);

            pictureBox1.Width  = GetPageWidth();
            pictureBox1.Height = GetPageHeight();
            pictureBox2.Width  = GetPageWidth();
            pictureBox2.Height = GetPageHeight();

            pictureBox1.BackgroundImage = util.MF1;
            pictureBox2.BackgroundImage = util.MF2;

            ReLocationPicture();
            BindParentFormCloseEvent();
        }
Beispiel #6
0
 public PrintForm(DrawMainPageUtil dmpu)
 {
     InitializeComponent();
     util = dmpu;
 }
Beispiel #7
0
        private void LoadForm()
        {
            //manger = new IemMainPageManger(m_Host);
            //info = manger.GetIemInfo();
            DeleteMetaFile();
            util = new DrawMainPageUtil(info);

            pictureBox1.Width  = GetPageWidth();
            pictureBox1.Height = GetPageHeight();
            pictureBox2.Width  = GetPageWidth();
            pictureBox2.Height = GetPageHeight();

            pictureBox1.BackgroundImage = util.MF1;
            pictureBox2.BackgroundImage = util.MF2;

            pictureBox1.BackgroundImageLayout = ImageLayout.Stretch;
            pictureBox2.BackgroundImageLayout = ImageLayout.Stretch;

            ReLocationPicture();
            BindParentFormCloseEvent();

            if (this.Parent != null)
            {
                if (this.Parent.AccessibleName != null &&
                    this.Parent.AccessibleName.Trim() != "")  //父窗体的AccessibleName不为空则表示没有编辑的权限
                {
                    simpleButton1.Visible = false;
                    simpleButton2.Visible = false;
                    simpleButton3.Visible = false;
                    simpleButton4.Visible = false;
                    simpleButton5.Visible = false;// addby ywk 2013年1月30日13:34:00
                    simpleButton6.Visible = false;
                }
            }

            Employee emp = new Employee(m_Host.User.Id);

            emp.ReInitializeProperties();
            DataHelper help    = new DataHelper();
            string     hoscode = help.GetConfigValueByKey("HosCode");

            if (hoscode == "1")
            {
                string static_save = help.GetStatic_SaveValue(info.IemBasicInfo.NoOfInpat);
                if (static_save == "1")
                {
                    simpleButton1.Enabled = false;
                    simpleButton2.Enabled = false;
                    simpleButton3.Enabled = false;
                    simpleButton4.Enabled = false;
                    simpleButton5.Enabled = false;
                    simpleButton6.Enabled = false;
                }
            }
            if (emp.Grade.Trim() != "")
            {
                DoctorGrade grade = (DoctorGrade)Enum.Parse(typeof(DoctorGrade), emp.Grade);
                if (grade == DoctorGrade.Nurse)
                {
                    simpleButton3.Enabled = false;
                    simpleButton4.Enabled = false;
                    simpleButton5.Enabled = false;
                    simpleButton6.Enabled = false;
                }
            }
            else
            {
                simpleButton1.Enabled = false;
                simpleButton2.Enabled = false;
                simpleButton3.Enabled = false;
                simpleButton4.Enabled = false;
                simpleButton5.Enabled = false;
                simpleButton6.Enabled = false;
            }
        }