Skip to content

Commit cfc494e

Browse files
authored
Merge pull request #91 from takahashim/fix-booth-assignments
Booth Assignment: show number of requests from accepted and unaccepted sponsors
2 parents 4a6eedc + 8a52cf0 commit cfc494e

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

app/controllers/admin/booth_assignments_controller.rb

+5
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@ class Admin::BoothAssignmentsController < ::Admin::ApplicationController
22
before_action :set_conference
33

44
def show
5+
@not_withdrawn_sponsorships = @conference.sponsorships
6+
.includes(:plan)
7+
.not_withdrawn
8+
.where(booth_requested: true)
9+
.order('plans.booth_size desc, sponsorships.name asc')
510
@sponsorships = @conference.sponsorships
611
.includes(:plan)
712
.active

app/views/admin/booth_assignments/show.html.haml

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
%section
1010
%p
11-
Booth requested: #{@sponsorships.size} sponsors (capacity #{@sponsorships.map(&:booth_size).compact.inject(:+)})
11+
Booth requested: #{@sponsorships.size} sponsors (capacity #{@sponsorships.map(&:booth_size).compact.inject(:+)}) (including non accepted sponsors: #{@not_withdrawn_sponsorships.size})
1212
%br
1313
Booth assigned: #{@exhibitors.size} sponsors (capacity #{@exhibitors.map(&:assigned_booth_size).compact.inject(:+)})
1414

0 commit comments

Comments
 (0)