MultiTenancy Orchard - How to know which tenant is requesting from
I've searched for quite a while, but I haven't found a thread explaining exactly how to figure out which Tenant is current in the code. For example, I want to change some logic based on what is active like so:
IQueryable<ContentPartRecord> getContentPartDates;
if (Tenat == ExampleTenant)
{
getContentPartDates = GetContentPartDates((int)Id)
.Where(ss => ss.SalesStatus == "Guaranteed")
.OrderBy(x => x.start_date);
}else {
getContentPartDates = GetContentPartDates((int) Id).OrderBy(x => x.start_date);
}
What's the best way to do this?
Thanks in advance.
+3
source to share