0
I have a product that can be registered in 2 stores A and B if I have already registered in A how do pro Dropdownlist
show me only show option B next time it is in register? what would be the logic? using Entityframework and Linq?
[HttpGet]
public IActionResult Create(string businessId)
{
var marketRest = new Rest
.MarketplaceRest(_appSettings.WebApiUrl, _appKeyBase64);
var registerViewModel = new RegisterMarketPlaceViewModel
{
BusinessId = businessId,
};
registerViewModel.MarketNameSelectList =
registerViewModel.GetMarketplaceSelectList(marketRest, _memoryCache);
return View(registerViewModel);
}
I don’t understand very well, you have a dropdown with two items A and B, if product A has already been registered, you want to show that only item B is available is this ?
– LP. Gonçalves
exactly, I just wanted to show B now on the case, but I haven’t been able to come up with a logic so far.
– Cezar Mdlosci
How do you mount this dropdown ? You can show your code?
– LP. Gonçalves
product was just example, I’m using mongoDb I don’t know if you’ve worked with this.
– Cezar Mdlosci
.GetMarketplaceSelectList(marketRest, _memoryCache).Where(x => !x.Vendido)
cannot identify and filter before filling or inside the search method, only return available ?– LP. Gonçalves