private PwsResourceElement[] GetProjectorResource(List <Person> person, string sessionTicket) { PwsResourceRef[] userList = new PwsResourceRef[person.Count]; for (int i = 0; i < person.Count; i++) { userList[i] = new PwsResourceRef() { ResourceDisplayName = person[i].Name }; } PwsGetResourceRq getResourceRq = new PwsGetResourceRq() { SessionTicket = sessionTicket, ResourceIdentities = userList }; return(pwsProjectorServices.PwsGetResource(getResourceRq).Resources); }
private PwsSaveTimeCardsRs SaveTimeCards(PwsTimecardDetail[] timeCards, PwsTimeOffCardDetail[] timeOffCards, PwsResourceRef user, string sessionTicket) { PwsSaveTimeCardsRq saveTimeCardsRq = new PwsSaveTimeCardsRq(); saveTimeCardsRq.SessionTicket = sessionTicket; saveTimeCardsRq.StartDate = DateTime.Now; // Time details need sorted saveTimeCardsRq.EndDate = DateTime.Now; // As above saveTimeCardsRq.ResourceIdentity = user; if (timeCards.Length > 0) { saveTimeCardsRq.SaveTimeCards = timeCards; } if (timeOffCards.Length > 0) { saveTimeCardsRq.SaveTimeOffCards = timeOffCards; } return(pwsProjectorServices.PwsSaveTimeCards(saveTimeCardsRq)); }