Ejemplo n.º 1
0
        private void method_0(object sender, RoutedEventArgs e)
        {
            this.MySurveyId            = SurveyHelper.SurveyID;
            this.CurPageId             = SurveyHelper.NavCurPage;
            SurveyHelper.PageStartTime = DateTime.Now;
            QDisplay qdisplay = new QDisplay();

            qdisplay.Init(this.CurPageId, 0);
            new SurveyBiz().ClearPageAnswer(this.MySurveyId, SurveyHelper.SurveySequence);
            string navOperation = SurveyHelper.NavOperation;

            this.MyNav.GroupLevel = qdisplay.QDefine.GROUP_LEVEL;
            if (this.MyNav.GroupLevel != "")
            {
                this.MyNav.GroupPageType  = qdisplay.QDefine.GROUP_PAGE_TYPE;
                this.MyNav.GroupCodeA     = qdisplay.QDefine.GROUP_CODEA;
                this.MyNav.CircleACurrent = SurveyHelper.CircleACurrent;
                this.MyNav.CircleACount   = SurveyHelper.CircleACount;
                if (navOperation == "Back")
                {
                    if (this.MyNav.GroupLevel == "A" && this.MyNav.CircleACurrent > 1)
                    {
                        this.MyNav.CircleACurrent = this.MyNav.CircleACurrent - 1;
                    }
                }
                else if (this.MyNav.GroupLevel == "A" && this.MyNav.CircleACurrent == 0)
                {
                    this.MyNav.CircleACurrent = 1;
                }
                this.MyNav.GetCircleInfo(this.MySurveyId);
            }
            string[] array = new LogicEngine
            {
                SurveyID        = this.MySurveyId,
                CircleBCode     = this.MyNav.CircleBCode,
                CircleACode     = this.MyNav.CircleACode,
                CircleACodeText = this.MyNav.CircleCodeTextA,
                CircleACount    = this.MyNav.CircleACount,
                CircleACurrent  = this.MyNav.CircleACurrent,
                CircleBCodeText = this.MyNav.CircleCodeTextB,
                CircleBCount    = this.MyNav.CircleBCount,
                CircleBCurrent  = this.MyNav.CircleBCurrent
            }.CircleGuideLogic(this.CurPageId, 1);
            if (array.Count <string>() > 0 && array[0].ToString() != "")
            {
                new RandomBiz().RebuildCircleGuide(this.MySurveyId, qdisplay.QDefine.QUESTION_NAME, array, qdisplay.QDefine.IS_RANDOM);
            }
            int page_COUNT_DOWN = qdisplay.QDefine.PAGE_COUNT_DOWN;

            if (page_COUNT_DOWN > 0)
            {
                Thread.Sleep(page_COUNT_DOWN);
            }
            if (navOperation == "Back")
            {
                this.method_2();
                SurveyHelper.NavOperation = "Back";
                return;
            }
            this.method_1();
        }