public static function getTableBelongsToFields(Table $table): array
    {
        $fields = [];
        $belongsToModels = Configure::read('RolesCapabilities.accessCheck.belongsToModels');

        foreach ($table->associations() as $association) {
            // skip non-assignation models
            if (!in_array($association->className(), $belongsToModels)) {
                continue;
            }

            $fields[] = $association->foreignKey();
        }

        return $fields;
    }