private async Task InitializeAdmin() { if (!await _databaseContext.Users.AnyAsync()) { Guid pointGuid = await _pointService.Create(new DeliveryPointInfo { Name = "Admin Point", WorksSchedule = new List <WorkTime>() }); await _userService.CreateAdmin(_options.AdminEmail, _options.AdminPassword, pointGuid); } }
public async Task <Guid> CreateDeliveryPoint([FromBody] DeliveryPointInfo model) { return(await _deliveryPointService.Create(model)); }