carlsednaoui / nycio

NYC Tech Volunteer Database
6 stars 2 forks source link

New Events and Occurrences #38

Open mattjstar opened 10 years ago

mattjstar commented 10 years ago

You shouldn't be able to load events/new or occurrences/new if you don't manage any organizations or organizations with events respectively.

carlsednaoui commented 10 years ago

How should we deal with this? If current_user is not an organization_manager redirect to homepage with alert?

carlsednaoui commented 10 years ago

I just deployed a work-around for this, where organization managers can see new_event_path and new_occurrence_path in their dropdown. Think it'll work for now :)

mattjstar commented 10 years ago

Not to muddy up our Issues, but I'm reopening because we want to force authorization for this.

Right now you could still get to those views, but the dropdowns will have empty Organizations and empty Events respectively. It's not that difficult to implement, I just ran out of time. Should be an easy fix.

carlsednaoui commented 10 years ago

Ok, I'll let you tackle this for then you have time :)

miclovich commented 10 years ago

I did something quick with Event creation not being only possible for Organization owners or members, I think. I redirect occurs if anyone wants to create an event: http://localhost:3000/events/new

carlsednaoui commented 10 years ago

Nice! Was this what you were talking about @mattjstar?

mattjstar commented 10 years ago

yep thanks @miclovich !

Now we just have to do the same for occurrences