mirror of
https://github.com/LaCasemate/fab-manager.git
synced 2025-01-29 18:52:22 +01:00
Merge remote-tracking branch 'origin/hotfixes' into dev
This commit is contained in:
commit
8eda1e673f
@ -8,6 +8,12 @@
|
||||
- Fix a bug: in case of unexpected server error during stripe payment process, the confirm button is not unlocked
|
||||
- [TODO DEPLOY] `rake db:migrate`
|
||||
|
||||
## v4.1.1 2019 september 20
|
||||
|
||||
- Fix a bug: api/reservations#index was using user_id instead of statistic_profile_id
|
||||
- Fix a bug: event_service#date_range method, test on all_day was never truthy
|
||||
- Fix a bug: sidekiq 5 does not have delay_for method anymore, uses perform_in instead
|
||||
|
||||
## v4.1.0 2019 September 12
|
||||
|
||||
- Handling the Strong-Customer Authentication (SCA) for online payments
|
||||
|
@ -213,7 +213,7 @@ GEM
|
||||
kaminari (0.16.3)
|
||||
actionpack (>= 3.0.0)
|
||||
activesupport (>= 3.0.0)
|
||||
libv8 (3.16.14.11)
|
||||
libv8 (3.16.14.19)
|
||||
loofah (2.2.3)
|
||||
crass (~> 1.0.2)
|
||||
nokogiri (>= 1.5.9)
|
||||
|
@ -11,7 +11,10 @@ class API::ReservationsController < API::ApiController
|
||||
if params[:reservable_id] && params[:reservable_type] && params[:user_id]
|
||||
params[:user_id] = current_user.id unless current_user.admin?
|
||||
|
||||
@reservations = Reservation.where(params.permit(:reservable_id, :reservable_type, :user_id))
|
||||
where_clause = params.permit(:reservable_id, :reservable_type).to_h
|
||||
where_clause[:statistic_profile_id] = StatisticProfile.find_by!(user_id: params[:user_id])
|
||||
|
||||
@reservations = Reservation.where(where_clause)
|
||||
elsif params[:reservable_id] && params[:reservable_type] && current_user.admin?
|
||||
@reservations = Reservation.where(params.permit(:reservable_id, :reservable_type))
|
||||
else
|
||||
|
@ -9,7 +9,7 @@ module Project::OpenlabSync
|
||||
after_destroy :openlab_destroy, if: :openlab_sync_active?
|
||||
|
||||
def openlab_create
|
||||
OpenlabWorker.delay_for(2.seconds).perform_async(:create, self.id) if self.published?
|
||||
OpenlabWorker.perform_in(2.seconds, :create, self.id) if self.published?
|
||||
end
|
||||
|
||||
def openlab_update
|
||||
|
@ -32,7 +32,7 @@ class EventService
|
||||
end_date = Time.zone.parse(ending[:date])
|
||||
start_time = Time.parse(starting[:time]) if starting[:time]
|
||||
end_time = Time.parse(ending[:time]) if ending[:time]
|
||||
if all_day == 'true'
|
||||
if all_day
|
||||
start_at = DateTime.new(start_date.year, start_date.month, start_date.day, 0, 0, 0, start_date.zone)
|
||||
end_at = DateTime.new(end_date.year, end_date.month, end_date.day, 23, 59, 59, end_date.zone)
|
||||
else
|
||||
|
Loading…
x
Reference in New Issue
Block a user