public MethodTest() { DocumentDBRepo <BaseInfo> .Initialize(CollectionBase); DocumentDBRepo <Document> .Initialize(CollectionDocument); BlobStorage.Initialize(); }
public async Task <string> DatabaseTest() { var doc = await DocumentDBRepo <Item> .CreateItemAsync(new Item { Id = Guid.NewGuid().ToString(), Name = "Husk at game i dag!", Description = "Vigtigt for dit helbred.", Completed = false }); return("Works!"); }
public async Task <IEnumerable <Item> > NewItem([FromBody] Item item) { var doc = await DocumentDBRepo <Item> .CreateItemAsync(item); return(await DocumentDBRepo <Item> .GetItemsAsync()); }
public Task <IEnumerable <Item> > GetItems() { return(DocumentDBRepo <Item> .GetItemsAsync()); }
public async Task <ActionResult> DetailsAsync(string id) { Employee emp = await DocumentDBRepo <Employee> .GetIEmpAsync(id); return(View(emp)); }
public async Task <ActionResult> IndexAsync() { var employees = await DocumentDBRepo <Employee> .GetItemsAsync(e => e.FirstName != ""); return(View(employees)); }