예제 #1
0
        private void BindTasks()
        {
            if (IsBeginTask)
            {
                return;
            }
            List <TaskEntity> list = _eDoc2ProcessManager.GetTaskData(IncidentId);
            //合生元流程处理
            var hsyList = new List <TaskEntity>();

            foreach (TaskEntity item in list)
            {
                if (item.Status == "激活")
                {
                    continue;
                }
                if (item.Status == "已完成" && item.StepName == "结束")
                {
                    item.Status = "借阅完成";
                    hsyList.Add(item);
                    continue;
                }
                item.Status = "已提交";
                hsyList.Add(item);
            }
            Tasks.DataSource = hsyList;
            Tasks.DataBind();
        }
예제 #2
0
        /// <summary>
        ///     根据流程实际进度做界面显示(去除Step值判断)
        /// </summary>
        private void InitStepOn()
        {
            List <TaskEntity> list    = EDoc2ProcessManager.GetTaskData(IncidentId);
            TaskEntity        endItem = list.FirstOrDefault(i => i.Status == "已完成" && i.StepName == "结束");

            if (endItem != null)
            {
                Page.Title = FaProcessSteppService.GetStepText(FaProcessStepEnum.Complete);
                Step2.AddCssClass("on");
                return;
            }
            TaskEntity cItem = list.FirstOrDefault(i => i.Status == "激活");

            if (cItem != null)
            {
                FaProcessStepEnum stepEnum = FaProcessSteppService.GetStepVal(cItem.StepName);
                switch (stepEnum)
                {
                case FaProcessStepEnum.Start:
                    Step0.AddCssClass("on");
                    break;

                case FaProcessStepEnum.FaLeader:
                    Step1.AddCssClass("on");
                    break;

                case FaProcessStepEnum.FaDirector:
                    Step2.AddCssClass("on");
                    break;

                case FaProcessStepEnum.Complete:
                    Step3.AddCssClass("on");
                    break;
                }
                Page.Title = FaProcessSteppService.GetStepText(stepEnum);
            }
            else
            {
                Page.Title = FaProcessSteppService.GetStepText(FaProcessStepEnum.Start);
                Step0.AddCssClass("on");
            }
        }