public ServiceContextBase(IOrganizationService service) { LogHelper = new LogHelper(Console.WriteLine); AdminOrganizationService = service; OrganizationService = service; var response = (WhoAmIResponse)service.Execute(new WhoAmIRequest()); UserId = response.UserId; InitiatingUserId = response.UserId; BusinessUnitRef = new EntityReference(BusinessUnitDefinition.EntityName, response.BusinessUnitId); }
public ServiceContextBase(IOrganizationService service, IOrganizationService adminService, TraceLogger log) : this(service) { LogHelper = new LogHelper(log); AdminOrganizationService = adminService; }
public void Log(string message, params object[] paramsObject) { LogHelper.LogMethod(message, paramsObject); }