This commit is contained in:
2020-06-18 21:31:44 +00:00
parent e192ca042b
commit 40b705b75a
7 changed files with 44 additions and 8 deletions

View File

@@ -707,6 +707,9 @@ namespace AyaNova.Core
//TODO: TECHCOUNT - new license causes exceeding count?
if (await AyaNova.Biz.UserBiz.ActiveCountAsync() > ParsedNewKey.GetLicenseFeature(SERVICE_TECHS_FEATURE_NAME).Count)
{
//Ok, the easy thing to do here is just set all techs inactive, but
//a trickier but probably better thing to do is set just enough techs inactive and choose them based
//on the oldest last login datetime first
throw new ApplicationException("E1020 - Can't install key, too many active techs and / or subcontractors in database. Deactivate enough to install key.");
}