public IProviderData DocumentManagementProviderInstance() { Type typetoreturn = Type.GetType("DocumentManagement.Provider.DAL.MySQLDAO.Provider_MySqlDao,DocumentManagement.Provider"); IProviderData oRetorno = (IProviderData)Activator.CreateInstance(typetoreturn); return(oRetorno); }
public string ServirBoisson([FromServices] IProviderData providerData, [FromBody] Commande commande) { if (commande.BadgeId != 0) { providerData.SaveCommande(commande); } return("\nBoisson en cours de préparation ... "); }
public async Task UpdateIntegrationAsync(string userId, Provider provider, IProviderData providerData) { var entities = await QueryIntegrationsAsync($"SELECT * FROM i WHERE i.UserId = '{userId}' AND i.Provider = '{provider}'"); var entity = entities.FirstOrDefault(); entity.ProviderData = providerData; Container container = GetIntegrationsContainer(); await container.UpsertItemAsync(entity, new PartitionKey(userId)); }
internal DefaultProviderAccountRequest(IProviderData providerData) { if (providerData == null) { throw new ArgumentNullException(nameof(providerData)); } if (string.IsNullOrEmpty(providerData.ProviderId)) { throw new ArgumentException($"{nameof(providerData.ProviderId)} within ProviderData instance must be specified."); } this.providerData = providerData; }
public async Task <Integration> CreateIntegrationAsync(string userId, Provider provider, string providerUserId, IProviderData data) { Container container = GetIntegrationsContainer(); var entity = new IntegrationEntity { Id = Guid.NewGuid().ToString(), UserId = userId, Provider = provider, ProviderUserId = providerUserId, ProviderData = data }; ItemResponse <IntegrationEntity> response = await container.CreateItemAsync(entity, new PartitionKey(entity.UserId)); return(response.Resource.Map()); }
void IProviderAccountAccess.SetProviderData(IProviderData providerData) => this.SetProperty(ProviderDataPropertyName, providerData);
public ProviderDataController() { ProviderDataFactory factory = new ProviderDataFactory(); DataFactory = factory.DocumentManagementProviderInstance(); }
public Commande ProposingBoisson([FromServices] IProviderData providerData, [FromBody] int badgeId) { Commande commande = providerData.GetLastCommande(badgeId); return(commande); }
public Task UpdateIntegrationAsync(string userId, Provider provider, IProviderData integrationData) => throw new System.NotImplementedException();
public Task <Integration> CreateIntegrationAsync(string userId, Provider provider, string providerUserId, IProviderData data) => throw new System.NotImplementedException();
public TestsModel(IConfiguration config, IInventoryData inventoryData, IProviderData providerData) { this.config = config; this.inventoryData = inventoryData; this.providerData = providerData; }