Merge branch 'dev' into staging
This commit is contained in:
commit
02c4f92165
@ -130,7 +130,11 @@ export default class UserController extends ApiController {
|
||||
|
||||
if(!isSubscribed && userHydrated.role?.name === "admin" || userHydrated.role?.name === "super-admin"){
|
||||
const manageSubscriptionRulesEntity = await this.rulesGroupsService.get({ where: { name: "Gestion de l'abonnement" }, include: { rules: true } });
|
||||
console.log("manageSubscriptionRulesEntity", manageSubscriptionRulesEntity);
|
||||
|
||||
const manageSubscriptionRules = RulesGroup.hydrateArray<RulesGroup>(manageSubscriptionRulesEntity, { strategy: "excludeAll" });
|
||||
console.log("manageSubscriptionRules", manageSubscriptionRules);
|
||||
|
||||
if(!manageSubscriptionRules[0]) return;
|
||||
|
||||
payload.rules = manageSubscriptionRules[0].rules!.map((rule) => rule.name) || [];
|
||||
|
Loading…
x
Reference in New Issue
Block a user