mirror of
https://github.com/openSUSE/osem.git
synced 2026-08-13 19:54:02 +00:00
Merge pull request #34 from differentreality/admin_events_list
Admin events list
This commit is contained in:
commit
ef556f02ca
3 changed files with 18 additions and 6 deletions
|
|
@ -12,6 +12,7 @@ class Admin::EventsController < ApplicationController
|
||||||
@events = @conference.events
|
@events = @conference.events
|
||||||
@tracks = @conference.tracks
|
@tracks = @conference.tracks
|
||||||
@event_states = @events.state_machine.states.map
|
@event_states = @events.state_machine.states.map
|
||||||
|
@event_types = @conference.event_types
|
||||||
respond_to do |format|
|
respond_to do |format|
|
||||||
format.html
|
format.html
|
||||||
# Explicity call #to_json to avoid the use of EventSerializer
|
# Explicity call #to_json to avoid the use of EventSerializer
|
||||||
|
|
|
||||||
|
|
@ -19,7 +19,7 @@
|
||||||
.dropdown
|
.dropdown
|
||||||
= link_to "#", :class => "dropdown-toggle", :id => "type-dropdown" do
|
= link_to "#", :class => "dropdown-toggle", :id => "type-dropdown" do
|
||||||
- if @event.event_type.nil?
|
- if @event.event_type.nil?
|
||||||
Track
|
Event Type
|
||||||
- else
|
- else
|
||||||
= @event.event_type.title
|
= @event.event_type.title
|
||||||
<b class="caret"></b>
|
<b class="caret"></b>
|
||||||
|
|
|
||||||
|
|
@ -2,8 +2,8 @@
|
||||||
.span
|
.span
|
||||||
.row
|
.row
|
||||||
%h5{:style=>"text-align: right"}
|
%h5{:style=>"text-align: right"}
|
||||||
= link_to "Events Stats", "#", :id => "events-stats1-link", :class => "btn btn-success"
|
= link_to "Events Stats", "#", :id => "events-stats-link", :class => "btn btn-success"
|
||||||
#events-stats1
|
#events-stats
|
||||||
%table.table.table-bordered.table-striped
|
%table.table.table-bordered.table-striped
|
||||||
|
|
||||||
%thead
|
%thead
|
||||||
|
|
@ -134,7 +134,17 @@
|
||||||
- l = link_to "Change", edit_admin_conference_event_speaker_path(@conference.short_title, event), :remote => true
|
- l = link_to "Change", edit_admin_conference_event_speaker_path(@conference.short_title, event), :remote => true
|
||||||
= "(#{l})".html_safe
|
= "(#{l})".html_safe
|
||||||
%td
|
%td
|
||||||
= event.event_type.title
|
.dropdown
|
||||||
|
= link_to "#", :class => "dropdown-toggle", :id => "type-dropdown" do
|
||||||
|
- if event.event_type.nil?
|
||||||
|
Event Type
|
||||||
|
- else
|
||||||
|
= event.event_type.title
|
||||||
|
<b class="caret"></b>
|
||||||
|
%ul.dropdown-menu
|
||||||
|
- @event_types.each do |type|
|
||||||
|
%li= link_to type.title, admin_conference_event_path(@conference.short_title, event, :event_type_id => type.id) ,
|
||||||
|
:method => :put, :event_type_id => type.id
|
||||||
%td
|
%td
|
||||||
.dropdown
|
.dropdown
|
||||||
= link_to "#", :class => "dropdown-toggle", :id => "track-dropdown" do
|
= link_to "#", :class => "dropdown-toggle", :id => "track-dropdown" do
|
||||||
|
|
@ -186,7 +196,8 @@
|
||||||
} );
|
} );
|
||||||
|
|
||||||
$(document).ready( function() {
|
$(document).ready( function() {
|
||||||
$("#events-stats1-link").click(function() {
|
$("#events-stats").hide();
|
||||||
$("#events-stats1").toggle();
|
$("#events-stats-link").click(function() {
|
||||||
|
$("#events-stats").toggle();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue