示例#1
0
 [OperationContract]//删除代理设置
 public bool DeleteAgentSet(string[] AgentSetId)
 {
     using (ProxySettingsBLL psbll = new ProxySettingsBLL())
     {
         return(psbll.DeleteAgentSet(AgentSetId));
     }
 }
示例#2
0
 [OperationContract]//删除代理设置
 public bool DeleteAgentSet(string[] AgentSetId)
 {
     using (ProxySettingsBLL psbll = new ProxySettingsBLL())
     {
         return psbll.DeleteAgentSet(AgentSetId);
     }
 }
示例#3
0
 public T_OA_AGENTSET GetAgentSetBysId(string AgentSetId)
 {
     using (ProxySettingsBLL psbll = new ProxySettingsBLL())
     {
         T_OA_AGENTSET AgentSetById = psbll.GetAgentSetBysId(AgentSetId);
         return AgentSetById == null ? null : AgentSetById;
     }
 }
示例#4
0
 public T_OA_AGENTSET GetAgentSetBysId(string AgentSetId)
 {
     using (ProxySettingsBLL psbll = new ProxySettingsBLL())
     {
         T_OA_AGENTSET AgentSetById = psbll.GetAgentSetBysId(AgentSetId);
         return(AgentSetById == null ? null : AgentSetById);
     }
 }
示例#5
0
        public List<T_OA_AGENTSET> GetAgentSetListById(int pageIndex, int pageSize, string sort, string filterString, object[] paras, ref int pageCount, LoginUserInfo loginUserInfo)
        {
            using (ProxySettingsBLL psbll = new ProxySettingsBLL())
            {
                List<T_OA_AGENTSET> ArchivesList = psbll.GetAgentSetInfo(pageIndex, pageSize, sort, filterString, paras, ref  pageCount, loginUserInfo.userID);

                return ArchivesList != null ? ArchivesList.ToList() : null;
            }
        }
示例#6
0
        public List <T_OA_AGENTSET> GetAgentSetListById(int pageIndex, int pageSize, string sort, string filterString, object[] paras, ref int pageCount, LoginUserInfo loginUserInfo)
        {
            using (ProxySettingsBLL psbll = new ProxySettingsBLL())
            {
                List <T_OA_AGENTSET> ArchivesList = psbll.GetAgentSetInfo(pageIndex, pageSize, sort, filterString, paras, ref pageCount, loginUserInfo.userID);

                return(ArchivesList != null?ArchivesList.ToList() : null);
            }
        }
示例#7
0
 [OperationContract]//更新代理设置
 public string UpdateAgentSet(T_OA_AGENTSET AgentSet)
 {
     using (ProxySettingsBLL psbll = new ProxySettingsBLL())
     {
         string returnStr = "";
         if (!psbll.UpdateAgentSet(AgentSet))
         {
             returnStr = "更新数据失败!";
         }
         return returnStr;
     }
 }
示例#8
0
 [OperationContract]//更新代理设置
 public string UpdateAgentSet(T_OA_AGENTSET AgentSet)
 {
     using (ProxySettingsBLL psbll = new ProxySettingsBLL())
     {
         string returnStr = "";
         if (!psbll.UpdateAgentSet(AgentSet))
         {
             returnStr = "更新数据失败!";
         }
         return(returnStr);
     }
 }
示例#9
0
 [OperationContract]//添加代理设置信息
 public string AgentSetAdd(T_OA_AGENTSET AgentSet)
 {
     using (ProxySettingsBLL psbll = new ProxySettingsBLL())
     {
         string returnStr = "";
         if (!psbll.IsExistAgentSet(AgentSet.SYSCODE, AgentSet.MODELCODE))
         {
             if (!psbll.AgentSetAdd(AgentSet))
             {
                 returnStr = "添加数据失败";
             }
         }
         else
         {
             returnStr = "该代理设置已经存在,添加数据失败";
         }
         return returnStr;
     }
 }
示例#10
0
 [OperationContract]//添加代理设置信息
 public string AgentSetAdd(T_OA_AGENTSET AgentSet)
 {
     using (ProxySettingsBLL psbll = new ProxySettingsBLL())
     {
         string returnStr = "";
         if (!psbll.IsExistAgentSet(AgentSet.SYSCODE, AgentSet.MODELCODE))
         {
             if (!psbll.AgentSetAdd(AgentSet))
             {
                 returnStr = "添加数据失败";
             }
         }
         else
         {
             returnStr = "该代理设置已经存在,添加数据失败";
         }
         return(returnStr);
     }
 }
示例#11
0
        public T_HR_EMPLOYEE GetQueryAgent(string UserId, string ModCode)
        {
            ProxySettingsBLL       psbll = new ProxySettingsBLL();
            PersonnelServiceClient psc   = new PersonnelServiceClient();

            if (psbll.IsExistAGENTForUser(UserId))
            {
                T_OA_AGENTSET AgentList = psbll.GetQueryAgent(UserId, ModCode);

                T_HR_EMPLOYEE employee = null;

                if (AgentList != null)
                {
                    T_HR_EMPLOYEEPOST[] tmps = psc.GetEmployeePostByPostID(AgentList.AGENTPOSTID);
                    if (tmps != null && tmps.Count() > 0)
                    {
                        employee = tmps[0].T_HR_EMPLOYEE;
                    }
                    else
                    {
                        T_HR_EMPLOYEE[] tmp = psc.GetEmployeeLeader(UserId, 0);
                        if (tmp != null && tmp.Count() > 0)
                        {
                            employee = tmp[0];//返回该岗位员工的直接上级
                        }
                    }
                }
                else
                {
                    T_HR_EMPLOYEE[] tmp = psc.GetEmployeeLeader(UserId, 0);
                    if (tmp != null && tmp.Count() > 0)
                    {
                        employee = tmp[0];//返回该岗位员工的直接上级
                    }
                }
                return(employee);
            }
            return(null);
        }
示例#12
0
        public T_HR_EMPLOYEE GetQueryAgent(string UserId, string ModCode)
        {
            ProxySettingsBLL psbll = new ProxySettingsBLL();
            PersonnelServiceClient psc = new PersonnelServiceClient();

            if (psbll.IsExistAGENTForUser(UserId))
            {
                T_OA_AGENTSET AgentList = psbll.GetQueryAgent(UserId, ModCode);

                T_HR_EMPLOYEE employee = null;

                if (AgentList != null)
                {
                    T_HR_EMPLOYEEPOST[] tmps = psc.GetEmployeePostByPostID(AgentList.AGENTPOSTID);
                    if (tmps != null && tmps.Count() > 0)
                    {
                        employee = tmps[0].T_HR_EMPLOYEE;
                    }
                    else
                    {
                        T_HR_EMPLOYEE[] tmp = psc.GetEmployeeLeader(UserId, 0);
                        if (tmp != null && tmp.Count() > 0)
                        {
                            employee = tmp[0];//返回该岗位员工的直接上级
                        }
                    }
                }
                else
                {
                    T_HR_EMPLOYEE[] tmp = psc.GetEmployeeLeader(UserId, 0);
                    if (tmp != null && tmp.Count() > 0)
                    {
                        employee = tmp[0];//返回该岗位员工的直接上级
                    }
                }
                return employee;
            }
            return null;
        }