Change condition in Campaign from and to
This commit is contained in:
parent
a146fd3239
commit
c88ece26e6
@ -141,8 +141,8 @@
|
||||
var userCampaignList = await _context.Rules
|
||||
.OfType<UserLocationRule>()
|
||||
.Include(c => c.Campaign)
|
||||
.Where(c => c.Campaign.From >= DateTime.Now
|
||||
&& c.Campaign.To <= DateTime.Now
|
||||
.Where(c => c.Campaign.From <= DateTime.Now
|
||||
&& c.Campaign.To >= DateTime.Now
|
||||
&& c.LocationId == userLocation.LocationId)
|
||||
.Select(c => c.Campaign)
|
||||
.ToListAsync();
|
||||
|
Loading…
x
Reference in New Issue
Block a user