Exemple #1
0
        public void SetupOrcidIds()
        {
            var sp = EmployeeCache.GetEmployee(SnumberAty.PadLeft(6, '0'));

            if (sp != null)
            {
                OrcidIdAty = sp.OrcidId;
            }

            sp = EmployeeCache.GetEmployee(SnumberAe.PadLeft(6, '0'));
            if (sp != null)
            {
                OrcidIdAe = sp.OrcidId;
            }
        }
Exemple #2
0
        public bool SetNames(string EmployeeId)
        {
            var person = EmployeeCache.GetEmployee(EmployeeId, true);

            if (person != null)
            {
                Name       = person.PreferredName;
                Phone      = person.PhoneNumber;
                OrcidId    = person.OrcidId;
                Location   = person.WorkLocation;
                EmployeeId = person.EmployeeId;
                WorkOrg    = person.WorkOrginization;

                return(true);
            }

            return(false);
        }
Exemple #3
0
 public JsonResult GetUserName(string id)
 {
     return(Json(EmployeeCache.GetName(id)));
 }
Exemple #4
0
        public List <OrgListObject> GetUserOrgs(string employeeId)
        {
            var org = EmployeeCache.GetHomeOrg(employeeId) == null?EmployeeCache.GetWorkOrg(employeeId).Substring(0, 2).ToUpper() : EmployeeCache.GetHomeOrg(employeeId).Substring(0, 2).ToUpper();

            return(Config.EmployeeConn.Query <OrgListObject>("SELECT * FROM Orgs WHERE Org = @Org", new { Org = org }).ToList());
        }