public override void Initialize(bool isPostBack)
        {
            _ITemplatePaperView.ResultMessage     = string.Empty;
            _ITemplatePaperView.ValidatePaperName = string.Empty;
            _ITemplatePaperView.QuestionItems     = _ITrainFacade.GetFBQuestionByConditon(string.Empty, -1);

            _ITemplatePaperView.ActionButtonEvent += AddEvent;

            FeedBackQuestionEditor itemEditor = new FeedBackQuestionEditor(_ITemplatePaperView);

            _ITemplatePaperView.btnCopyEvent      += itemEditor.btnCopyEvent;
            _ITemplatePaperView.btnPasteEvent     += itemEditor.btnPasteEvent;
            _ITemplatePaperView.CancelButtonEvent += CancelEvent;
            _ITemplatePaperView.ddlAssessItemChangedForAddEvent    += itemEditor.ddlChangedForAddEvent;
            _ITemplatePaperView.ddlAssessItemChangedForUpdateEvent += itemEditor.ddlChangedForUpdateEvent;
            _ITemplatePaperView.ddlAssessItemChangedForDeleteEvent += itemEditor.ddlChangedForDeleteEvent;
            _ITemplatePaperView.ddlAssessItemChangedForAddAtEvent  += itemEditor.ddlAssessItemChangedForAddAtEvent;
            _ITemplatePaperView.ddlAssessItemChangedForUpEvent     += itemEditor.ddlAssessItemChangedForUpEvent;
            _ITemplatePaperView.ddlAssessItemChangedForDownEvent   += itemEditor.ddlAssessItemChangedForDownEvent;

            if (!isPostBack)
            {
                _ITemplatePaperView.OperationInfo     = "新增反馈问卷";
                _ITemplatePaperView.OperationType     = "Add";
                _ITemplatePaperView.TemplatePaperName = string.Empty;

                List <TrainFBQuestion> items = new List <TrainFBQuestion>();
                items.Add(new TrainFBQuestion(-1, string.Empty, new TrainFBQuesType(-1, string.Empty), new List <TrainFBItem>()));
                _ITemplatePaperView.QuestionList = items;
            }
            _ITemplatePaperView.SetbtnPasteVisible = _ITemplatePaperView.SessionCopyPaper != null;
        }
示例#2
0
        public override void Initialize(bool isPostBack)
        {
            _ITemplatePaperView.ResultMessage     = string.Empty;
            _ITemplatePaperView.ValidatePaperName = string.Empty;
            _ITemplatePaperView.QuestionItems     = _ITrainFacade.GetFBQuestionByConditon(string.Empty, -1);

            _ITemplatePaperView.ActionButtonEvent += CancelEvent;
            _ITemplatePaperView.CancelButtonEvent += CancelEvent;

            FeedBackQuestionEditor itemEditor = new FeedBackQuestionEditor(_ITemplatePaperView);

            _ITemplatePaperView.btnCopyEvent += itemEditor.btnCopyEvent;

            if (!isPostBack)
            {
                _ITemplatePaperView.OperationInfo = "²é¿´·´À¡Îʾí";
                _ITemplatePaperView.OperationType = "Detail";

                Model.FeedBackPaper paper = _IPaperFacade.GetFeedBackPaperById(_PaperId);
                _ITemplatePaperView.TemplatePaperName = paper.FeedBackPaperName;
                _ITemplatePaperView.QuestionList      = paper.FBQuestions;
                _ITemplatePaperView.SetFormReadOnly   = true;
            }
        }