From 782b4bfa0f15c627797ffa3fd51d48386cee6f60 Mon Sep 17 00:00:00 2001 From: Sylvain Date: Fri, 3 Mar 2023 16:37:14 +0100 Subject: [PATCH 1/2] (bug) unable to reserve an event --- CHANGELOG.md | 2 ++ app/models/reservation.rb | 2 +- app/services/subscriptions/expire_service.rb | 3 +++ app/services/subscriptions/extension_after_reservation.rb | 3 +++ 4 files changed, 9 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index bfb92c5e5..289f5a12f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,7 @@ # Changelog Fab-manager +- Fix a bug: unable to reserve an event + ## v5.8.0 2023 March 03 - OpenAPI events endpoint returns category, theme and age_range diff --git a/app/models/reservation.rb b/app/models/reservation.rb index c3a07e700..8140cd7b3 100644 --- a/app/models/reservation.rb +++ b/app/models/reservation.rb @@ -121,7 +121,7 @@ def slots_not_locked end def extend_subscription - Subscriptions::ExtensionAfterReservation.new(self).extend_subscription_if_eligible + ::Subscriptions::ExtensionAfterReservation.new(self).extend_subscription_if_eligible end def notify_member_create_reservation diff --git a/app/services/subscriptions/expire_service.rb b/app/services/subscriptions/expire_service.rb index 7eaa1adbf..e84d8c8f4 100644 --- a/app/services/subscriptions/expire_service.rb +++ b/app/services/subscriptions/expire_service.rb @@ -1,5 +1,8 @@ # frozen_string_literal: true +# Services around subscriptions +module Subscriptions; end + # Expire the given subscription class Subscriptions::ExpireService class << self diff --git a/app/services/subscriptions/extension_after_reservation.rb b/app/services/subscriptions/extension_after_reservation.rb index b6d9f77ab..0bd7463bf 100644 --- a/app/services/subscriptions/extension_after_reservation.rb +++ b/app/services/subscriptions/extension_after_reservation.rb @@ -1,5 +1,8 @@ # frozen_string_literal: true +# Services around subscriptions +module Subscriptions; end + # Extend the user's current subscription after his first training reservation if # he subscribed to a rolling plan class Subscriptions::ExtensionAfterReservation From 3bbca47d19fbcdcb04e54827381c4ddd72e96d80 Mon Sep 17 00:00:00 2001 From: Sylvain Date: Fri, 3 Mar 2023 16:38:32 +0100 Subject: [PATCH 2/2] Version 5.8.1 --- CHANGELOG.md | 2 ++ package.json | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 289f5a12f..02114db3a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,7 @@ # Changelog Fab-manager +## v5.8.1 2023 March 03 + - Fix a bug: unable to reserve an event ## v5.8.0 2023 March 03 diff --git a/package.json b/package.json index bc88ecae5..a79ef55e6 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "fab-manager", - "version": "5.8.0", + "version": "5.8.1", "description": "Fab-manager is the FabLab management solution. It provides a comprehensive, web-based, open-source tool to simplify your administrative tasks and your marker's projects.", "keywords": [ "fablab",