fixes GMaps usage & Command creation

This commit is contained in:
2019-09-01 01:31:55 +01:00
parent cec790b71e
commit 5a3fdada8f
12 changed files with 194 additions and 271 deletions

View File

@ -705,7 +705,7 @@ namespace Yavsc.Controllers
var uid = User.GetUserId();
var user = await _dbContext.Users.Include(u=>u.PostalAddress).SingleAsync(u=>u.Id==uid);
ViewBag.GoogleSettings = _googleSettings;
return View (new Yavsc.ViewModels.Manage.SetAddressViewModel { Street1 = user.PostalAddress?.Address } );
return View (user.PostalAddress ?? new Location());
}
[HttpPost]
@ -727,7 +727,7 @@ namespace Yavsc.Controllers
return RedirectToAction(nameof(Index), new { Message = ManageMessageId.SetAddressSuccess });
}
ViewBag.GoogleSettings = _googleSettings;
return View(new Yavsc.ViewModels.Manage.SetAddressViewModel { Street1 = model.Address});
return View(model);
}
public async Task<IActionResult> PaymentInfo (string id)
{