// 获取菜单树的值
        public static string GetTreeValue(string employeeID, Dictionary <string, int> selectedIDs)
        {
            List <string> allUsers = new List <string>();

            allUsers = GenesysBLL.Proc_GetCfgAdmin().Select(item => item.employee_id).ToList();

            if (!string.IsNullOrEmpty(employeeID))
            {
                allUsers = allUsers.FindAll(id => id.IndexOf(employeeID, StringComparison.CurrentCultureIgnoreCase) != -1);
            }
            string root = "所有用户";

            if (root == null)
            {
                return(string.Empty);
            }

            JSONTree tree = new JSONTree(root, root);

            string parent = null;

            foreach (string eid in allUsers)
            {
                parent = root;
                int checkedSign = 0;
                if (selectedIDs.ContainsKey(eid))
                {
                    checkedSign = selectedIDs[eid];
                }
                tree.Root.AppendNode(parent, eid, eid, eid, true, true, checkedSign);
            }
            return(tree.ToString());
        }
        public static string GetQueueMsg(int enterID)
        {
            var info = GenesysBLL.EnterID2Skill(enterID).FirstOrDefault();

            if (info == null)
            {
                throw new Exception("没有找到对应的队列");
            }
            return(info.QueueMsg0);
        }
Beispiel #3
0
        public static int Proc_PersonExists(string employee_id)
        {
            //using (var db = Tele.DataLibrary.DCHelper.SPhoneContext())
            //{
            //    var r = db.Proc_PersonExists(employee_id).FirstOrDefault();
            //    if (r != null)
            //    {
            //        return r.Value;
            //    }
            //    return 0;
            //}

            var r = GenesysBLL.Proc_PersonExists(employee_id).FirstOrDefault();

            if (r != null)
            {
                return(r.Value);
            }
            return(0);
        }
Beispiel #4
0
 public static List <SoftPhone.Entity.Genesys.cfg.Proc_GetCfgAdmin_Result> Proc_GetCfgAdmin()
 {
     return(GenesysBLL.Proc_GetCfgAdmin().ToList());
 }
Beispiel #5
0
        public static List <SoftPhone.Entity.Genesys.cfg.Proc_GetPersonSkills_Result> Proc_GetPersonSkills(int person_dbid)
        {
            var r = GenesysBLL.Proc_GetPersonSkills(person_dbid);

            return(r.ToList());
        }
Beispiel #6
0
 public static Proc_GetPersonAgentInfo_Result Proc_GetPersonAgentInfo(string employee_id)
 {
     return(GenesysBLL.Proc_GetPersonAgentInfo(employee_id).FirstOrDefault());
 }
Beispiel #7
0
 //获取管理人员
 public static List <string> GetCfgAdminList()
 {
     return(GenesysBLL.Proc_GetCfgAdmin().Select(x => x.employee_id).ToList());
 }
Beispiel #8
0
 //获取队列
 public static List <string> GetCfgSkillList()
 {
     return(GenesysBLL.Proc_GetCfgSkill().Select(x => x.name).ToList());
 }