open_conference_ware 1.0.0.pre3 → 1.0.0.pre4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data.tar.gz.sig +0 -0
- data/.travis.yml +6 -0
- data/CHANGES.md +13 -0
- data/app/assets/javascripts/open_conference_ware/application.js +2 -0
- data/app/assets/javascripts/open_conference_ware/proposals.js +8 -12
- data/app/assets/stylesheets/open_conference_ware/application.css +1 -0
- data/app/controllers/open_conference_ware/application_controller.rb +8 -6
- data/app/controllers/open_conference_ware/authentications_controller.rb +1 -1
- data/app/controllers/open_conference_ware/events_controller.rb +5 -1
- data/app/controllers/open_conference_ware/proposals_controller.rb +9 -8
- data/app/controllers/open_conference_ware/session_types_controller.rb +2 -2
- data/app/mixins/open_conference_ware/public_attributes_mixin.rb +1 -1
- data/app/models/open_conference_ware/event.rb +7 -4
- data/app/models/open_conference_ware/room.rb +4 -0
- data/app/models/open_conference_ware/track.rb +3 -0
- data/app/models/open_conference_ware/user.rb +20 -10
- data/app/views/layouts/open_conference_ware/_header.html.erb +3 -0
- data/app/views/layouts/open_conference_ware/application.html.erb +1 -22
- data/app/views/open_conference_ware/authentications/_openid.html.erb +24 -10
- data/app/views/open_conference_ware/proposals/_admin_controls.html.erb +1 -1
- data/app/views/open_conference_ware/proposals/_form.html.erb +2 -2
- data/app/views/open_conference_ware/proposals/_list_concise.html.erb +2 -2
- data/app/views/open_conference_ware/proposals/_selector_voting.html.erb +52 -0
- data/app/views/open_conference_ware/proposals/_sub_list.html.erb +1 -1
- data/app/views/open_conference_ware/proposals/_sub_list_for_kind.html.erb +1 -1
- data/app/views/open_conference_ware/proposals/create.html.erb +2 -25
- data/app/views/open_conference_ware/proposals/show.html.erb +1 -53
- data/app/views/open_conference_ware/proposals/stats.html.erb +1 -1
- data/app/views/open_conference_ware/selector_votes/index.html.erb +3 -1
- data/app/views/open_conference_ware/tracks/_form.html.erb +2 -2
- data/app/views/open_conference_ware/users/_account_box.html.erb +1 -1
- data/config/routes.rb +1 -1
- data/gem-public_cert.pem +20 -20
- data/lib/open_conference_ware/version.rb +1 -1
- data/lib/tasks/export.rake +1 -1
- data/open_conference_ware.gemspec +7 -7
- data/spec/controllers/open_conference_ware/proposals_controller_spec.rb +1 -1
- data/util/README.md +3 -0
- data/util/assign_rooms.rb +40 -0
- data/util/seed_schedule.rb +2 -2
- data/util/user_favorites_contention_report.rb +2 -2
- data/vendor/assets/images/openid-selector/openid-providers-en.png +0 -0
- data/vendor/assets/javascripts/openid-selector/openid-en.js +61 -0
- data/vendor/assets/javascripts/openid-selector/openid-jquery.js +201 -0
- data/vendor/assets/stylesheets/openid-selector/openid.css.scss +79 -0
- metadata +55 -61
- metadata.gz.sig +0 -0
- data/vendor/assets/images/idselector/aol.ico +0 -0
- data/vendor/assets/images/idselector/arrow.gif +0 -0
- data/vendor/assets/images/idselector/arrow_white_back.png +0 -0
- data/vendor/assets/images/idselector/arrow_white_forward.png +0 -0
- data/vendor/assets/images/idselector/blogger.ico +0 -0
- data/vendor/assets/images/idselector/claimid.ico +0 -0
- data/vendor/assets/images/idselector/flickr.ico +0 -0
- data/vendor/assets/images/idselector/google.ico +0 -0
- data/vendor/assets/images/idselector/lj.ico +0 -0
- data/vendor/assets/images/idselector/myopenid.ico +0 -0
- data/vendor/assets/images/idselector/openid.ico +0 -0
- data/vendor/assets/images/idselector/technorati.ico +0 -0
- data/vendor/assets/images/idselector/verisign.ico +0 -0
- data/vendor/assets/images/idselector/vidoop2.ico +0 -0
- data/vendor/assets/images/idselector/vox.ico +0 -0
- data/vendor/assets/images/idselector/yahoo.ico +0 -0
data.tar.gz.sig
CHANGED
Binary file
|
data/.travis.yml
CHANGED
@@ -6,10 +6,16 @@ bundler_args: --without debug
|
|
6
6
|
rvm:
|
7
7
|
- 1.9.3
|
8
8
|
- 2.0.0
|
9
|
+
- 2.1.5
|
10
|
+
- 2.2.0
|
11
|
+
matrix:
|
12
|
+
allow_failures:
|
13
|
+
- rvm: 2.2.0
|
9
14
|
env:
|
10
15
|
- DB=mysql
|
11
16
|
- DB=postgresql
|
12
17
|
- DB=sqlite
|
18
|
+
cache: bundler
|
13
19
|
before_script:
|
14
20
|
- sqlite3 --version
|
15
21
|
- mysql --version
|
data/CHANGES.md
CHANGED
@@ -3,7 +3,20 @@
|
|
3
3
|
OpenConferenceWare stable releases and changes included, with latest at top:
|
4
4
|
|
5
5
|
### master
|
6
|
+
|
7
|
+
### v1.0.0.pre3
|
8
|
+
- Added missing database indexes and improved index naming
|
9
|
+
- Fixed image paths in CSS
|
10
|
+
- Fixed some issues with the Ignite-style proposal list
|
11
|
+
- Added a feature flag to enable/disable user favorites
|
12
|
+
- Improved handling of OmniAuth OpenID and failure cases
|
13
|
+
- Removed CacheLookupsMixin
|
14
|
+
- Extracted sensitive configuration values to config/secrets.yml
|
15
|
+
|
16
|
+
### v1.0.0.pre2
|
6
17
|
- Improved gem packaging
|
18
|
+
- Added a generator to copy views from the engine into the host app
|
19
|
+
- Cleaned up file naming and unnecessary files
|
7
20
|
|
8
21
|
### v1.0.0.pre1
|
9
22
|
- Converted to a Rails engine
|
@@ -5,6 +5,8 @@
|
|
5
5
|
//= require jquery.localScroll
|
6
6
|
//= require farbtastic
|
7
7
|
//= require audiojs/audio.min
|
8
|
+
//= require openid-selector/openid-jquery
|
9
|
+
//= require openid-selector/openid-en
|
8
10
|
//= require bootstrap
|
9
11
|
//= require open_conference_ware/base
|
10
12
|
//= require open_conference_ware/util
|
@@ -54,14 +54,6 @@ function bind_proposal_generic_control(kind, elements) {
|
|
54
54
|
if (matcher) {
|
55
55
|
target.html(matcher[1]);
|
56
56
|
}
|
57
|
-
|
58
|
-
// Hide or unhide the room and schedule controls based on the proposal's state
|
59
|
-
var dependent = target.parent().parent().find('.proposal_admin_controls_dependent_on_confirmed_status');
|
60
|
-
if (response['proposal_status'] == 'confirmed') {
|
61
|
-
dependent.show();
|
62
|
-
} else {
|
63
|
-
dependent.hide();
|
64
|
-
}
|
65
57
|
}
|
66
58
|
}
|
67
59
|
});
|
@@ -84,10 +76,14 @@ function bind_proposal_schedule_controls() {
|
|
84
76
|
if(target.parent().find('option:selected[value]').get().length == 3) {
|
85
77
|
|
86
78
|
data = {
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
79
|
+
proposal: {
|
80
|
+
authenticity_token: app.authenticity_token,
|
81
|
+
start_time: {
|
82
|
+
date: target.parent().find('select.date').attr('value'),
|
83
|
+
hour: target.parent().find('select.hour').attr('value'),
|
84
|
+
minute: target.parent().find('select.minute').attr('value')
|
85
|
+
}
|
86
|
+
}
|
91
87
|
};
|
92
88
|
proposal_id = target.parent().attr('id').split('_').pop();
|
93
89
|
format = 'json';
|
@@ -29,6 +29,10 @@ module OpenConferenceWare
|
|
29
29
|
before_filter :log_the_current_user
|
30
30
|
before_filter :log_the_session
|
31
31
|
|
32
|
+
rescue_from ActionController::UnknownFormat do |e|
|
33
|
+
render(text: 'Not Found', status: 404)
|
34
|
+
end
|
35
|
+
|
32
36
|
#---[ Authentication ]--------------------------------------------------
|
33
37
|
|
34
38
|
# Store the given user in the session.
|
@@ -149,9 +153,7 @@ module OpenConferenceWare
|
|
149
153
|
def notify(level, message)
|
150
154
|
level = level.to_sym
|
151
155
|
raise ArgumentError, "Invalid flash notification level: #{level}" unless NOTIFY_LEVELS.include?(level)
|
152
|
-
flash[level]
|
153
|
-
flash[level] << " #{message}".html_safe :
|
154
|
-
flash[level] = "#{message}".html_safe
|
156
|
+
flash[level] = "#{flash[level]} #{message}".strip.html_safe
|
155
157
|
end
|
156
158
|
|
157
159
|
#---[ Access control ]--------------------------------------------------
|
@@ -257,7 +259,7 @@ module OpenConferenceWare
|
|
257
259
|
# Try finding event using params:
|
258
260
|
event_id_key = controller_name == "events" ? :id : :event_id
|
259
261
|
if key = params[event_id_key]
|
260
|
-
if event = Event.
|
262
|
+
if event = Event.find_by_slug(key)
|
261
263
|
return [event, :assigned_to_param]
|
262
264
|
else
|
263
265
|
logger.info "error, couldn't find event from key: #{key}"
|
@@ -469,7 +471,7 @@ module OpenConferenceWare
|
|
469
471
|
if @event
|
470
472
|
if event_tracks? && @event.tracks.size == 0
|
471
473
|
if admin?
|
472
|
-
notify :notice, "This event needs a track, you should #{view_context.link_to 'create one', new_event_track_path(@event)}."
|
474
|
+
notify :notice, "This event needs a track, you should #{view_context.link_to 'create one', new_event_track_path(@event)}.".html_safe
|
473
475
|
else
|
474
476
|
notify :failure, "This event has no tracks, an admin must create at least one."
|
475
477
|
end
|
@@ -477,7 +479,7 @@ module OpenConferenceWare
|
|
477
479
|
|
478
480
|
if event_session_types? && @event.session_types.size == 0
|
479
481
|
if admin?
|
480
|
-
notify :notice, "This event needs a session type, you should #{view_context.link_to 'create one', new_event_session_type_path(@event)}."
|
482
|
+
notify :notice, "This event needs a session type, you should #{view_context.link_to 'create one', new_event_session_type_path(@event)}.".html_safe
|
481
483
|
else
|
482
484
|
notify :failure, "This event has no session types, an admin must create at least one."
|
483
485
|
end
|
@@ -14,6 +14,7 @@ module OpenConferenceWare
|
|
14
14
|
respond_to do |format|
|
15
15
|
format.html
|
16
16
|
format.json { render json: @events }
|
17
|
+
format.xml { render xml: @events }
|
17
18
|
end
|
18
19
|
end
|
19
20
|
|
@@ -21,6 +22,7 @@ module OpenConferenceWare
|
|
21
22
|
respond_to do |format|
|
22
23
|
format.html { redirect_to event_proposals_path(@event) }
|
23
24
|
format.json { render json: @event }
|
25
|
+
format.xml { render xml: @event }
|
24
26
|
end
|
25
27
|
end
|
26
28
|
|
@@ -29,7 +31,9 @@ module OpenConferenceWare
|
|
29
31
|
|
30
32
|
respond_to do |format|
|
31
33
|
format.html
|
32
|
-
format.
|
34
|
+
format.json { render json: @speakers }
|
35
|
+
format.xml { render xml: @speakers }
|
36
|
+
format.csv { render csv: @speakers, style: admin? ? :full : :public }
|
33
37
|
end
|
34
38
|
end
|
35
39
|
end
|
@@ -53,10 +53,10 @@ module OpenConferenceWare
|
|
53
53
|
# index.atom.builder
|
54
54
|
if @event_assignment == :assigned_to_param
|
55
55
|
@cache_key = "proposals_atom,event_#{@event.id}"
|
56
|
-
@proposals = Defer { @event.populated_proposals(:proposals).
|
56
|
+
@proposals = Defer { @event.populated_proposals(:proposals).reorder("submitted_at desc").limit(MAX_FEED_ITEMS) }
|
57
57
|
else
|
58
58
|
@cache_key = "proposals_atom,all"
|
59
|
-
@proposals = Defer { Proposal.populated.
|
59
|
+
@proposals = Defer { Proposal.populated.reorder("submitted_at desc").limit(MAX_FEED_ITEMS) }
|
60
60
|
end
|
61
61
|
}
|
62
62
|
format.csv {
|
@@ -233,11 +233,11 @@ module OpenConferenceWare
|
|
233
233
|
params[:proposal].delete(:title)
|
234
234
|
end
|
235
235
|
|
236
|
-
if params[:start_time] && admin?
|
237
|
-
if params[:start_time][:date].blank? || params[:start_time][:hour].blank? || params[:start_time][:minute].blank?
|
236
|
+
if params[:proposal][:start_time] && admin?
|
237
|
+
if params[:proposal][:start_time][:date].blank? || params[:proposal][:start_time][:hour].blank? || params[:proposal][:start_time][:minute].blank?
|
238
238
|
@proposal.start_time = nil
|
239
239
|
else
|
240
|
-
@proposal.start_time = "#{params[:start_time][:date]} #{params[:start_time][:hour]}:#{params[:start_time][:minute]}"
|
240
|
+
@proposal.start_time = "#{params[:proposal][:start_time][:date]} #{params[:proposal][:start_time][:hour]}:#{params[:proposal][:start_time][:minute]}"
|
241
241
|
end
|
242
242
|
end
|
243
243
|
|
@@ -260,7 +260,7 @@ module OpenConferenceWare
|
|
260
260
|
render(
|
261
261
|
json: {
|
262
262
|
proposal_status: @proposal.status,
|
263
|
-
_transition_control_html: render_to_string(partial: '/proposals/transition_control')
|
263
|
+
_transition_control_html: render_to_string(partial: '/open_conference_ware/proposals/transition_control', formats: [:html])
|
264
264
|
},
|
265
265
|
status: :ok
|
266
266
|
)
|
@@ -357,7 +357,8 @@ module OpenConferenceWare
|
|
357
357
|
:track_id,
|
358
358
|
:session_type_id,
|
359
359
|
:speaking_experience,
|
360
|
-
:audience_level
|
360
|
+
:audience_level,
|
361
|
+
:tag_list]
|
361
362
|
|
362
363
|
permitted += [:status, :room_id, :start_time, :audio_url] if admin?
|
363
364
|
|
@@ -433,7 +434,7 @@ module OpenConferenceWare
|
|
433
434
|
end
|
434
435
|
|
435
436
|
def assert_user_complete_profile
|
436
|
-
if user_profiles?
|
437
|
+
if user_profiles? && logged_in? && !current_user.admin? && !current_user.complete_profile?
|
437
438
|
current_user.complete_profile = true
|
438
439
|
if current_user.valid?
|
439
440
|
current_user.save
|
@@ -53,7 +53,7 @@ module OpenConferenceWare
|
|
53
53
|
|
54
54
|
respond_to do |format|
|
55
55
|
if @session_type.save
|
56
|
-
flash[:notice] = '
|
56
|
+
flash[:notice] = 'Session type was successfully created.'
|
57
57
|
format.html { redirect_to(session_types_path) }
|
58
58
|
format.json { render json: @session_type, status: :created, location: @session_type }
|
59
59
|
format.xml { render xml: @session_type, status: :created, location: @session_type }
|
@@ -70,7 +70,7 @@ module OpenConferenceWare
|
|
70
70
|
def update
|
71
71
|
respond_to do |format|
|
72
72
|
if @session_type.update_attributes(session_type_params)
|
73
|
-
flash[:notice] = '
|
73
|
+
flash[:notice] = 'Session type was successfully updated.'
|
74
74
|
format.html { redirect_to(@session_type) }
|
75
75
|
format.json { head :ok }
|
76
76
|
format.xml { head :ok }
|
@@ -47,7 +47,7 @@ module OpenConferenceWare
|
|
47
47
|
end
|
48
48
|
|
49
49
|
def serializable_hash(options={})
|
50
|
-
if (options.keys & [:only, :except, :methods, :include]).present?
|
50
|
+
if options && (options.keys & [:only, :except, :methods, :include]).present?
|
51
51
|
super(options)
|
52
52
|
else
|
53
53
|
public_attributes
|
@@ -108,9 +108,8 @@ module OpenConferenceWare
|
|
108
108
|
def proposals_for_stats
|
109
109
|
return self.proposals.
|
110
110
|
order("created_at").
|
111
|
-
|
112
|
-
includes(:track, :session_type)
|
113
|
-
all
|
111
|
+
select("open_conference_ware_proposals.id, open_conference_ware_proposals.track_id, open_conference_ware_proposals.created_at, open_conference_ware_proposals.submitted_at, open_conference_ware_proposals.session_type_id, open_conference_ware_proposals.status").
|
112
|
+
includes(:track, :session_type)
|
114
113
|
end
|
115
114
|
|
116
115
|
# Return an array of the Event's ScheduleItems and Proposal sessions that
|
@@ -155,7 +154,11 @@ module OpenConferenceWare
|
|
155
154
|
|
156
155
|
# Return other Event objects.
|
157
156
|
def other_events
|
158
|
-
|
157
|
+
if new_record?
|
158
|
+
self.class.all
|
159
|
+
else
|
160
|
+
self.class.select("id, title").order("title asc").where('id != ?', self.id)
|
161
|
+
end
|
159
162
|
end
|
160
163
|
|
161
164
|
# Return array of Rooms for this event and its parent event.
|
@@ -109,29 +109,35 @@ module OpenConferenceWare
|
|
109
109
|
email
|
110
110
|
end
|
111
111
|
|
112
|
-
|
112
|
+
comma :full do
|
113
|
+
email
|
113
114
|
id
|
114
115
|
first_name
|
115
116
|
last_name
|
116
117
|
affiliation
|
117
118
|
biography
|
118
|
-
photo url: 'Photo'
|
119
119
|
website
|
120
120
|
twitter
|
121
121
|
identica
|
122
122
|
blog_url
|
123
|
-
created_at
|
124
|
-
updated_at
|
123
|
+
created_at 'Created'
|
124
|
+
updated_at 'Updated'
|
125
125
|
proposals ids: 'Session ids'
|
126
|
-
}
|
127
|
-
|
128
|
-
comma :full do
|
129
|
-
email
|
130
|
-
instance_eval &base_comma_attributes
|
131
126
|
end
|
132
127
|
|
133
128
|
comma :public do
|
134
|
-
|
129
|
+
id
|
130
|
+
first_name
|
131
|
+
last_name
|
132
|
+
affiliation
|
133
|
+
biography
|
134
|
+
website
|
135
|
+
twitter
|
136
|
+
identica
|
137
|
+
blog_url
|
138
|
+
created_at 'Created'
|
139
|
+
updated_at 'Updated'
|
140
|
+
proposals ids: 'Session ids'
|
135
141
|
end
|
136
142
|
|
137
143
|
#---[ PaperClip avatar images ]-----------------------------------------
|
@@ -144,6 +150,10 @@ module OpenConferenceWare
|
|
144
150
|
avatar: '48x48#'
|
145
151
|
}
|
146
152
|
|
153
|
+
validates_attachment_content_type :photo,
|
154
|
+
:content_type => /\Aimage\/.*\Z/,
|
155
|
+
:unless => Proc.new{|r| r.photo_content_type.blank? }
|
156
|
+
|
147
157
|
#---[ Methods ]---------------------------------------------------------
|
148
158
|
|
149
159
|
def self.create_from_authentication(auth)
|
@@ -51,6 +51,9 @@
|
|
51
51
|
<% if proposal_statuses? %>
|
52
52
|
<li><%= link_to "Sessions", event_sessions_path(nav_event) %></li>
|
53
53
|
<% end %>
|
54
|
+
<% if proposal_start_times? %>
|
55
|
+
<li><%= link_to "Schedule", event_schedule_path(nav_event) %></li>
|
56
|
+
<% end %>
|
54
57
|
<li><%= link_to "Proposals", event_proposals_path(nav_event) %>
|
55
58
|
<li><%= link_to "- Bulk edit", manage_event_proposals_path(nav_event) %></li>
|
56
59
|
<% unless nav_event.accepting_proposals? %>
|
@@ -89,7 +89,7 @@
|
|
89
89
|
</ul>
|
90
90
|
</li>
|
91
91
|
</ul>
|
92
|
-
©
|
92
|
+
© <%= Date.today.year %> <%= OpenConferenceWare.organization %>
|
93
93
|
</div>
|
94
94
|
</div><!--wrapper -->
|
95
95
|
|
@@ -101,26 +101,5 @@
|
|
101
101
|
<%= yield :javascript %>
|
102
102
|
</script>
|
103
103
|
|
104
|
-
<% if Rails.env == "production" %>
|
105
|
-
<script type="text/javascript">
|
106
|
-
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
|
107
|
-
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
|
108
|
-
</script>
|
109
|
-
<script type="text/javascript">
|
110
|
-
var pageTracker = _gat._getTracker("UA-168427-8");
|
111
|
-
pageTracker._initData();
|
112
|
-
pageTracker._trackPageview();
|
113
|
-
</script>
|
114
|
-
|
115
|
-
<script type="text/javascript">
|
116
|
-
var pkBaseURL = (("https:" == document.location.protocol) ? "https://opensourcebridge.org/stats/piwik/" : "http://opensourcebridge.org/stats/piwik/");
|
117
|
-
document.write(unescape("%3Cscript src='" + pkBaseURL + "piwik.js' type='text/javascript'%3E%3C/script%3E"));
|
118
|
-
</script><script type="text/javascript">
|
119
|
-
piwik_action_name = '';
|
120
|
-
piwik_idsite = 1;
|
121
|
-
piwik_url = pkBaseURL + "piwik.php";
|
122
|
-
piwik_log(piwik_action_name, piwik_idsite, piwik_url);
|
123
|
-
</script>
|
124
|
-
<% end %>
|
125
104
|
</body>
|
126
105
|
</html>
|
@@ -1,11 +1,25 @@
|
|
1
|
-
<div class="auth-provider
|
2
|
-
<h3>OpenID</h3>
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
1
|
+
<div class="auth-provider">
|
2
|
+
<h3>OpenID</h3>
|
3
|
+
|
4
|
+
<%= form_tag(auth_path(:open_id), :id => "openid_form" ) do %>
|
5
|
+
<fieldset>
|
6
|
+
<div id="openid_choice">
|
7
|
+
<p>Please click your account provider:</p>
|
8
|
+
<div id="openid_btns"></div>
|
9
|
+
</div>
|
10
|
+
<div id="openid_input_area" class="form-group">
|
11
|
+
<%= text_field_tag "openid_url", "http://", id: "openid_url", class: 'form-control' %>
|
12
|
+
<%= submit_tag 'Log in', class: 'btn btn-default' %>
|
13
|
+
</div>
|
14
|
+
<noscript>
|
15
|
+
<p><%= snippet_for :login_openid_text %></p>
|
16
|
+
</noscript>
|
17
|
+
</fieldset>
|
18
|
+
<% end %>
|
11
19
|
</div>
|
20
|
+
|
21
|
+
<% run_when_dom_is_ready <<-JS
|
22
|
+
openid.img_path = '/assets/openid-selector/';
|
23
|
+
openid.init('openid_url');
|
24
|
+
JS
|
25
|
+
%>
|