Add check asset connection auth flag
MODIFY
src/server/rest/v1/service/AuthorizationService.ts
src/server/rest/v1/service/AuthorizationService.ts
@@ -1154,6 +1154,7 @@ export default class AuthorizationService {
setting.canSyncRefund = await AuthorizationService.canPerformAuthorizationAction(tenant, userToken, Entity.TRANSACTION, Action.SYNCHRONIZE_REFUNDED_TRANSACTION, authorizationFilter);
setting.canCheckBillingConnection = await AuthorizationService.canPerformAuthorizationAction(tenant, userToken, Entity.BILLING, Action.CHECK_CONNECTION, authorizationFilter);
setting.canCheckSmartChargingConnection = await AuthorizationService.canPerformAuthorizationAction(tenant, userToken, Entity.SMART_CHARGING, Action.CHECK_CONNECTION, authorizationFilter);
+ setting.canCheckAssetConnection = await AuthorizationService.canPerformAuthorizationAction(tenant, userToken, Entity.ASSET, Action.CHECK_CONNECTION, authorizationFilter);
// Remove auth flags set to false
Utils.removeCanPropertiesWithFalseValue(setting);
}

MODIFY
src/types/Authorization.ts
src/types/Authorization.ts
@@ -365,6 +365,7 @@ export interface SettingAuthorizationActions extends AuthorizationActions {
canSyncRefund?: boolean;
canCheckBillingConnection?: boolean;
canCheckSmartChargingConnection?: boolean;
+ canCheckAssetConnection?: boolean;
}
export enum DynamicAuthorizationFilterName {

Add check asset connection auth flag