Skip to content

Commit 298b998

Browse files
Merge pull request codebar#1792 from codebar/update-grid-container-on-admin-ban-member-portal-feedback-pages
Update grid container on admin ban, member, feedback and portal pages
2 parents 12ae9b1 + eb5b026 commit 298b998

File tree

11 files changed

+74
-160
lines changed

11 files changed

+74
-160
lines changed

app/assets/stylesheets/partials/_admin_member.scss

Lines changed: 0 additions & 85 deletions
This file was deleted.

app/views/admin/bans/_ban.html.haml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,18 @@
11
.row.d-flex.suspension
22
.col-2.col-md-1
3-
%span.fa-stack
3+
%span.fa-stack.text-danger
44
%i.fas.fa-user.fa-stack-1x
5-
%i.fas.fa-ban.fa-stack-2x.warning
5+
%i.fas.fa-ban.fa-stack-2x
66
.col-9.col-md-11.details
77
%strong
88
- if action.permanent?
99
Suspended indefinitely
1010
- else
1111
Suspended until #{l(action.expires_at, format: :default_date)}
1212
by #{link_to(action.added_by.full_name, action.added_by)}
13-
%em= action.reason
14-
%blockquote
13+
%div
14+
%em= action.reason
15+
%p.mb-0
1516
= action.note
1617
- if action.explanation.present?
1718
.explanation

app/views/admin/bans/new.html.haml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
.container-fluid.pt-3
1+
.container.py-4.py-lg-5
22
.row.mb-4
33
.col
4-
%nav
5-
%ol.breadcrumb.ml0
6-
%li.breadcrumb-item= link_to @member.full_name, admin_member_path(@member), class: 'border-0'
4+
%nav{'aria-label': 'breadcrumb'}
5+
%ol.breadcrumb.ml-0
6+
%li.breadcrumb-item= link_to @member.full_name, admin_member_path(@member)
77
%li.breadcrumb-item.active=t('.title')
88

99
.row

app/views/admin/feedback/index.html.haml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
.container-fluid.pt-3
1+
.container.py-4.py-lg-5
22
- if @feedback.any?
33
.row
44
.col

app/views/admin/members/_actions.html.haml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
.container-fluid.p-0.mb-4
1+
.container-fluid.p-0
22
.btn-group.d-flex
33
= link_to '#', class: 'btn btn-primary d-block py-4 rounded-0', 'data-toggle': 'modal', 'data-target': "#note-modal" do
44
%i.fas.fa-pencil-alt.mr-2

app/views/admin/members/_profile.html.haml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
#profile
2-
= image_tag(@member.avatar(200), title: @member.full_name, alt: @member.full_name)
3-
%span.d-block= @member.full_name
4-
%span.d-block= mail_to @member.email, @member.email
5-
%span.d-block= @member&.mobile
2+
= image_tag(@member.avatar(200), title: @member.full_name, alt: @member.full_name, class: 'mb-4 rounded-circle')
3+
%span.d-block.mb-2= @member.full_name
4+
%span.d-block.mb-2= mail_to @member.email, @member.email
5+
%span.d-block.mb-2= @member&.mobile
66
%span.d-block
77
%p.lead= @member.about_you
88

Lines changed: 22 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,24 @@
1-
#admin-member
2-
= render 'actions'
3-
.container-fluid.mb-4.mb-md-0
4-
.row
5-
.col-12.col-md-3
6-
= render 'profile'
7-
.col-12.col-md-9
8-
%p
9-
=link_to admin_member_path(@member) do
10-
%i.fas.fa-arrow-left
11-
Back to member summary
12-
- if @member.upcoming_rsvps.any?
13-
%h3 Upcoming RSVPs
14-
- @member.upcoming_rsvps.each do |invitation|
15-
= render EventPresenter.decorate(invitation.event), invitation: invitation
1+
= render 'actions'
2+
.container.py-4.py-lg-5
3+
.row
4+
.col-12.col-md-3
5+
= render 'profile'
6+
.col-12.col-md-9
7+
%p
8+
=link_to admin_member_path(@member) do
9+
%i.fas.fa-arrow-left
10+
Back to member summary
11+
- if @member.upcoming_rsvps.any?
12+
%h3 Upcoming RSVPs
13+
- @member.upcoming_rsvps.each do |invitation|
14+
= render EventPresenter.decorate(invitation.event), invitation: invitation
1615

17-
- if @member.past_rsvps.any?
18-
%h3 Past RSVPs
19-
.digg_pagination.mb-3
20-
.page_info
21-
= page_entries_info(@member.past_rsvps.paginate(per_page: 20, page: params['page']), model: 'past events')
22-
= will_paginate(@member.past_rsvps.paginate(per_page: 20, page: params['page']))
16+
- if @member.past_rsvps.any?
17+
%h3 Past RSVPs
18+
.digg_pagination.mb-3
19+
.page_info
20+
= page_entries_info(@member.past_rsvps.paginate(per_page: 20, page: params['page']), model: 'past events')
21+
= will_paginate(@member.past_rsvps.paginate(per_page: 20, page: params['page']))
2322

24-
- @member.past_rsvps.paginate(per_page: 20, page: params['page']).each do |invitation|
25-
= render EventPresenter.decorate(invitation.event), invitation: invitation
23+
- @member.past_rsvps.paginate(per_page: 20, page: params['page']).each do |invitation|
24+
= render EventPresenter.decorate(invitation.event), invitation: invitation
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
.container-fluid
1+
.container.py-4.py-lg-5
22
.row.mb-4
33
.col
44
%h1 Members Directory
55
.row.mb-4
66
.col-12.col-md-6
77
= select_tag 'member_lookup_id', options_for_select(@members.collect{ |u| [u.full_name, u.id] }), { class: 'chosen-select' }
8-
.row.mb-4
8+
.row
99
.col
1010
= link_to 'View Profile', '#', { class: 'btn btn-primary', id: 'view_profile' }
Lines changed: 27 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,31 @@
1-
#admin-member
2-
= render 'actions'
3-
.container-fluid.mb-4
4-
.row
5-
.col-12.col-md-3
6-
= render 'profile'
7-
.col-12.col-md-9
8-
.row
9-
.col
10-
%ul.list-unstyled.m-1#actions
11-
- @actions.each do |action|
12-
%li.border-bottom.border-light.mb-3= render action, action: action
1+
= render 'actions'
2+
.container.py-4.py-lg-5
3+
.row
4+
.col-12.col-md-3
5+
= render 'profile'
6+
.col-12.col-md-9
7+
.row
8+
.col
9+
%ul.list-unstyled#actions
10+
- @actions.each do |action|
11+
%li.border-bottom.mb-3.pb-3= render action, action: action
1312

14-
.row.d-flex.align-items-center
15-
.col-2.col-md-1
16-
%span.fa-stack.text-success
17-
%i.fas.fa-circle.fa-stack-2x
18-
%i.fas.fa-user-plus.fa-stack-1x.fa-inverse
19-
.col-9.col-md-11
20-
%strong Signed up
21-
= l(@member.created_at, format: :website_format)
13+
.row.d-flex.align-items-center
14+
.col-2.col-md-1
15+
%span.fa-stack.text-success
16+
%i.fas.fa-circle.fa-stack-2x
17+
%i.fas.fa-user-plus.fa-stack-1x.fa-inverse
18+
.col-9.col-md-11
19+
%strong Signed up
20+
= l(@member.created_at, format: :website_format)
2221

2322

24-
- if @member.upcoming_rsvps.any?
25-
.row
26-
.col
27-
%h3.mt-4 Upcoming RSVPs
28-
- @member.upcoming_rsvps.each do |invitation|
29-
= render EventPresenter.decorate(invitation.event), invitation: invitation
30-
.row.mt-4
23+
- if @member.upcoming_rsvps.any?
24+
.row
3125
.col
32-
= link_to 'View all RSVPS', admin_member_events_path(@member), class: 'btn btn-primary btn-block'
26+
%h3.mt-4 Upcoming RSVPs
27+
- @member.upcoming_rsvps.each do |invitation|
28+
= render EventPresenter.decorate(invitation.event), invitation: invitation
29+
.row.mt-4
30+
.col
31+
= link_to 'View all RSVPS', admin_member_events_path(@member), class: 'btn btn-primary btn-block'

app/views/admin/portal/guide.html.haml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
.container-fluid
1+
.container.py-4.py-lg-5
22
.row
3-
.col
4-
%h2 Using the codebar application
3+
.col.col-md-10.col-lg-8
4+
%h1 Using the codebar application
55

6-
%h3 Managing admin privileges
6+
%h2 Managing admin privileges
77

88
%p To manage roles, we use the Rolify gem. At the moment, the only way to add and remove privileges is through Rails console. There are three types of special roles: chapter organisers, meeting organisers and admins.
99

app/views/admin/portal/index.html.haml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
1-
.container-fluid
1+
.container.py-4.py-lg-5
22
.row
33
.col-12.col-md-3
44
%h3.mb-3 Chapters
55
%ul.list-unstyled.m-0
66
- @chapters.each do |chapter|
77
%li.pb-2.mb-3.border-bottom.border-dark
8-
= link_to chapter.name, [ :admin, chapter ], class: 'border-0 pl-2'
8+
= link_to chapter.name, [ :admin, chapter ], class: 'pl-2'
99
.col-12.col-md-5
1010
%h3.mb-3 Upcoming Workshops
1111
%ul.list-unstyled.m-0
1212
- @workshops.each do |workshop|
1313
%li.border-bottom.border-dark.pb-2.mb-3
14-
= link_to admin_workshop_path(workshop), class: 'border-0' do
14+
= link_to admin_workshop_path(workshop) do
1515
%strong= workshop.chapter.name
1616
%br
1717
= humanize_date(workshop.date_and_time, with_time: true)
@@ -28,7 +28,7 @@
2828
%ul.list-unstyled.m-0
2929
- @groups.each do |group|
3030
%li.border-bottom.border-dark.pb-2.mb-3
31-
= link_to [:admin, group], class: 'border-0' do
31+
= link_to [:admin, group] do
3232
#{group.name} (#{group.chapter.name})
3333

3434
.col-12.col-md-9

0 commit comments

Comments
 (0)