コード例 #1
0
        /// <summary>
        /// 获取IT角色
        /// </summary>
        /// <returns></returns>
        public static List <ComboboxCommon> GetITRoles()
        {
            List <ComboboxCommon> list = new List <ComboboxCommon>();

            foreach (var item in db.ItRoles.Where(x => x.Status == CommonStatusEnum.Able).ToList())
            {
                ComboboxCommon com = new ComboboxCommon();
                com.id   = item.ID;
                com.text = item.Name;
                list.Add(com);
            }
            return(list);
        }
コード例 #2
0
        /// <summary>
        /// 获取需求信息
        /// </summary>
        /// <returns></returns>
        public static List <ComboboxCommon> GetRequestForms()
        {
            List <ComboboxCommon> list = new List <ComboboxCommon>();

            foreach (var item in db.RequestForms.Where(x => x.Status == CommonStatusEnum.Able).ToList())
            {
                ComboboxCommon com = new ComboboxCommon();
                com.id = item.ID;
                // com.text = "系统:" + item.SysTypeName + "|申请人:" + item.ApplierName + "|需求名称:" + item.Name;
                list.Add(com);
            }
            return(list);
        }
コード例 #3
0
        /// <summary>
        /// 获取需求状态
        /// </summary>
        /// <returns></returns>
        public static List <ComboboxCommon> GetRequestStatus()
        {
            List <ComboboxCommon> list = new List <ComboboxCommon>();

            foreach (var item in Enum.GetValues(typeof(RequestStatusEnum)))
            {
                ComboboxCommon com = new ComboboxCommon();
                com.id   = (int)item;
                com.text = Display.GetEnumBrief((RequestStatusEnum)item);
                list.Add(com);
            }
            return(list);
        }
コード例 #4
0
        /// <summary>
        /// 获取需求任务明细
        /// </summary>
        /// <returns></returns>
        public static List <ComboboxCommon> GetRequestFormTaskLists()
        {
            List <ComboboxCommon> list = new List <ComboboxCommon>();

            foreach (var item in db.RequestFormTaskLists.Where(x => x.Status == CommonStatusEnum.Able).ToList())
            {
                ComboboxCommon com = new ComboboxCommon();
                com.id   = item.ID;
                com.text = "处理人:" + item.Handler;
                list.Add(com);
            }
            return(list);
        }
コード例 #5
0
        /// <summary>
        /// 获取运维信息
        /// </summary>
        /// <returns></returns>
        public static List <ComboboxCommon> GetMaintenances()
        {
            List <ComboboxCommon> list = new List <ComboboxCommon>();

            foreach (var item in db.Maintenances.Where(x => x.Status == CommonStatusEnum.Able).ToList())
            {
                ComboboxCommon com = new ComboboxCommon();
                com.id = item.ID;
                // com.text = "区域:" + item.RegionName + "|申请人:" + item.ApplierName + "|申请状态:" + item.MaintenanceStatusName;
                list.Add(com);
            }
            return(list);
        }
コード例 #6
0
        /// <summary>
        /// 获取申请人
        /// </summary>
        /// <returns></returns>
        public static List <ComboboxCommon> GetPerson()
        {
            List <ComboboxCommon> list = new List <ComboboxCommon>();

            foreach (var item in db.Users.Where(x => x.Status == CommonStatusEnum.Able).ToList())
            {
                ComboboxCommon com = new ComboboxCommon();
                com.id   = item.ID;
                com.text = "员工工号:" + item.ID + "|姓名:" + item.ChineseName;
                list.Add(com);
            }
            return(list);
        }