/// <summary> /// /// </summary> /// <param name="masterCustomerId"></param> /// <param name="subCustomerId"></param> /// <returns></returns> private string[] GetImsroles(string customerToken) { using (var myim = new IMService { Url = PersonifyImsUrl }) { var imsCustomerRoleGetResult = myim.IMSCustomerRoleGet(PersonifyVendorName, PersonifyVendorPassword, customerToken); if (imsCustomerRoleGetResult.CustomerRoles == null) { return new[] { string.Empty } } ; return(imsCustomerRoleGetResult.CustomerRoles.Select(x => x.Value).ToArray()); } }
// Get Roles for user private string[] GetImsroles(string customerToken) { using (var myim = new IMService { Url = _personifyImsUrl }) { var roleList = new List <string>(); var imsCustomerRoleGetResult = myim.IMSCustomerRoleGet(_personifySsoVendorName, _personifySsoVendorPassword, customerToken); if (imsCustomerRoleGetResult.CustomerRoles == null) { return new[] { string.Empty } } ; foreach (var roledetail in imsCustomerRoleGetResult.CustomerRoles) { roleList.Add(roledetail.Value); } return(roleList.ToArray()); } }