improve events

This commit is contained in:
Torsten
2023-06-12 15:47:54 +03:00
parent d2eaacaaad
commit 15ccc5eedb
19 changed files with 100 additions and 49 deletions

View File

@ -9,21 +9,6 @@
%button.bg-red-200.mr-3.inline-block.rounded-lg.px-4.py-3.text-md.font-medium.border.border-gray-400{type: :submit}
Delete Profile
.flex.flex-col.justify-center
=link_to profile_path(profile) do
.my-2.px-2.py-2.text-center.bg-gray-200
%h1.text-xl.font-bold.tracking-tight.sm:text-4xl
Your Events
-if event = profile.events.length >0
%div
Your last Event:
= profile.events.first.name
=link_to event_path(profile.events.first) do
%button.mr-3.inline-block.rounded-lg.px-4.py-3.text-md.font-medium.border.border-gray-400
View
= link_to edit_event_path(profile.events.first) do
%button.bg-cyan-200.mr-3.inline-block.rounded-lg.px-4.py-3.text-md.font-medium.border.border-gray-400
Edit
= link_to new_event_path(profile: profile.kind) do
%button.bg-cyan-200.mr-3.inline-block.rounded-lg.px-4.py-3.text-md.font-medium.border.border-gray-400
New Event

View File

@ -1,7 +1,7 @@
= paginate @members
.flex.justify-center
.grid.grid-cols-4
.grid.grid-cols-1.md:grid-cols-2.lg:grid-cols-4
- @members.each do |member|
.fex.flex-col.overflow-hidden.rounded-lg.border.border-gray-100.shadow-sm.m-10
=link_to member do

View File

@ -5,10 +5,10 @@
Settings and profiles
%h4.text-xl.mt-4.md:text-2xl
View and edit your profiles, and change settings
.grid.grid-cols-1.mx-8.gap-8.md:grid-cols-2.mx-12.gap-12.lg:grid-cols-3.mx-16.gap-16
.grid.grid-cols-1.mx-8.gap-8.md:grid-cols-2.mx-12.gap-12.lg:grid-cols-4.mx-16.gap-16
.flex.flex-col.justify-between
%h3.text-2xl.bg-gray-200.p-4.text-center Settings
.flex.justify-beteen.flex-wrap
.flex.justify-center.flex-col
= form_tag( destroy_member_session_path , {method: :delete } ) do
%button.m-4.bg-cyan-200.mr-3.inline-block.rounded-lg.px-4.py-3.text-md.font-medium.border.border-gray-400{type: :submit}
Sign out
@ -18,7 +18,7 @@
= link_to members_edit_email_path do
%button.m-4.bg-cyan-200.mr-3.inline-block.rounded-lg.px-4.py-3.text-md.font-medium.border.border-gray-400{type: :submit}
Change Email
.grid.grid-cols-6.gap-4.mt-10.mx-10
.grid.grid-cols-3.gap-4.mt-10.mx-10
-@member.entities.each do |entity|
%div= entity.type
%div= entity.name
@ -44,3 +44,14 @@
- Profile.kinds.each do |kind|
- if profile = @member.profile(kind)
%div= render "#{kind}_profile" , profile: profile
-if (events = @member.future_events).length > 0
- events.each do |event|
%div
= render "events/event_small" , event: event
=link_to event_path(event) do
%button.ml-10.mr-5.inline-block.rounded-lg.px-4.py-2.text-md.font-medium.border.border-gray-400
View
= link_to edit_event_path(event) do
%button.bg-cyan-200.mr-3.inline-block.rounded-lg.px-4.py-2.text-md.font-medium.border.border-gray-400
Edit