Beispiel #1
0
        private void suspend()
        {
            TaskInfoManager mgr = new TaskInfoManager();

            List <TaskInfo> lstUsers = new List <TaskInfo>();

            Entity         = new TaskInfo();
            Entity.Task_Id = Convert.ToInt32(EventArgument);
            //if (mgr.validate(Entity, "delete"))
            {
                Entity        = mgr.GetTaskByID(Entity.Task_Id);
                Entity.Status = true;
                mgr.Update(Entity, "suspend");
            }
            //else
            // {
            //     IsValid = false;
            // }
            ValidationErrors = mgr.ValidationErrors;
            if (ValidationErrors.Count > 0)
            {
                IsValid = false;
            }
            ListMode();
        }
Beispiel #2
0
        private void Edit()
        {
            TaskInfoManager mgr = new TaskInfoManager();

            //Entity = mgr.Get(Convert.ToInt32(EventArgument));
            Entity       = mgr.GetTaskByID(Convert.ToInt32(EventArgument));
            Project_Name = Entity.ProjectName;
            Project_Name = GetProjectNamebyID(Entity.Project_ID);
            Manager_Name = GetUserNamebyProjectandTaskID(Entity.Project_ID, Entity.Task_Id);
            if (Entity.Parent_ID > 0)
            {
                Parent_Task   = GetParentTasksbyID(Entity.Parent_ID);
                Parent_TaskID = Entity.Parent_ID;
                IsParentTask  = true;
            }
            {
                IsParentTask = false;
            }
            List <UserInfo> pminfo = mgr.GetProjectManager(Entity.Project_ID);

            IsViewTask = false;
            EditMode();
        }