Exemplo n.º 1
0
        private void btnBack_Click(object sender, EventArgs e)
        {
            //LoginForm frmMain = new LoginForm();
            //frmMain.Show();
            //this.Close();

            LoginFormNew loginFormNew = new LoginFormNew();

            loginFormNew.Show();
            Close();
        }
Exemplo n.º 2
0
        //保存问卷设置并跳转页面
        public void SaveSettings()
        {
            //保存医生账号及名称等
            Properties.Settings.Default.DoctorId     = _doctorId;
            Properties.Settings.Default.DoctorName   = _doctorName;
            Properties.Settings.Default.txtDrAccount = _txtDrAccount;
            //Properties.Settings.Default.Save();

            //保存活动Id及名称等
            Properties.Settings.Default.ActivityId     = _activityId;
            Properties.Settings.Default.txtActivName   = _txtActivName;
            Properties.Settings.Default.ActivityName   = _activityName;
            Properties.Settings.Default.ActivityAdress = _activityAdress;

            if (_activityStartDate.HasValue)
            {
                Properties.Settings.Default.ActivityStartDate = Convert.ToDateTime(_activityStartDate);
            }
            if (_activityEndDate.HasValue)
            {
                Properties.Settings.Default.ActivityEndDate = Convert.ToDateTime(_activityEndDate);
            }
            //Properties.Settings.Default.Save();

            //保存小屋Id及名称
            Properties.Settings.Default.CottageOrgId   = _cottageOrgId;
            Properties.Settings.Default.txtCottageName = _txtCottageName;
            Properties.Settings.Default.Save();

            //将所选择活动设为专项活动
            if (Properties.Settings.Default.ActivityId > 0)
            {
                //screeningServiceClient.UpdateCottageActivityTypeTo1(
                //    Properties.Settings.Default.ActivityId,
                //    1,
                //    _doctorId);
                screenWebapiClient.UpdateCottageActivityTypeTo1(
                    Properties.Settings.Default.ActivityId,
                    1,
                    _doctorId);
            }


            //保存问卷设置并跳转页面
            if (rdAD.Checked)
            {
                Properties.Settings.Default.ScreenSet = 1;
            }
            if (rdNaocz.Checked)
            {
                Properties.Settings.Default.ScreenSet = 2;
            }
            if (rdZaoai.Checked)
            {
                Properties.Settings.Default.ScreenSet = 3;
            }
            if (rdKangfu.Checked)
            {
                Properties.Settings.Default.ScreenSet = 4;
            }
            //其他
            if (rdOther.Checked)
            {
                Properties.Settings.Default.ScreenSet = 5;
            }
            Properties.Settings.Default.Save();

            BaseForm selectForm     = null;
            int      iWhichQuestion = Properties.Settings.Default.ScreenSet;

            switch (iWhichQuestion)
            {
            case 1:    //老年痴呆筛查
                selectForm = new AD.FirstFrm();
                break;

            case 2:     //脑卒中筛查
                selectForm = new Naocuzhong.FirstFrm();
                break;

            case 3:    //早癌筛查
                selectForm = new Zaoai.ScreeningZaoaiSelect();
                break;

            case 4:    //工伤康复筛查
                selectForm = new Kangfu.ScreeningSelect();
                break;

            case 5:
                selectForm = new Other.ScreenOtherSelect();
                break;

            default:
                break;
            }

            LoginFormNew loginFormNew = new LoginFormNew(selectForm);

            //LoginForm loginFormNew = new LoginForm(selectForm);
            loginFormNew.Show();
            this.Hide();
        }
Exemplo n.º 3
0
        //结束/下一位
        private void btnQuit_Click(object sender, EventArgs e)
        {
            //
            if (_questionForm != null)
            {
                _questionForm.Close();
            }
            Close();
            return;

            //end


            //清空排尿异常一二题选择标识
            Properties.Settings.Default.QuesSelFlag = string.Empty;
            //清空问卷记录Id
            Properties.Settings.Default.QuestionnaireRecodId = 0;
            //清空同天内做的同份问卷记录Id
            Properties.Settings.Default.LastTimeQuestionnaireRecodId = 0;
            Properties.Settings.Default.Save();

            //清空登录信息
            ClientInfo.Logout();
            //回到登录界面

            BaseForm selectForm     = null;
            int      iWhichQuestion = Properties.Settings.Default.ScreenSet;

            switch (iWhichQuestion)
            {
            case 1:    //老年痴呆筛查
                selectForm = new AD.FirstFrm();
                break;

            case 2:     //脑卒中筛查
                selectForm = new Naocuzhong.FirstFrm();
                break;

            case 3:    //早癌筛查
                selectForm = new Zaoai.ScreeningZaoaiSelect();
                break;

            case 4:    //工伤康复筛查
                selectForm = new Kangfu.ScreeningSelect();
                break;

            case 5:
                selectForm = new Other.ScreenOtherSelect();
                break;

            default:
                break;
            }

            LoginFormNew loginFormNew = new LoginFormNew(selectForm);

            loginFormNew.Show();
            if (_questionForm != null)
            {
                _questionForm.Close();
            }
            Close();
        }