event_cal 1.2.5 → 1.3.0
Sign up to get free protection for your applications and to get access to all the features.
- data/app/views/shared/event_cal/_calendar.html.haml +9 -0
- data/app/views/{event_cal → shared/event_cal}/_date.html.haml +1 -1
- data/app/views/{event_cal → shared/event_cal}/_event_details.html.haml +1 -1
- data/lib/event_cal/calendar_helper.rb +5 -5
- data/lib/event_cal/version.rb +1 -1
- metadata +7 -7
- data/app/views/event_cal/_calendar.html.haml +0 -9
@@ -0,0 +1,9 @@
|
|
1
|
+
.calendar.monthly{ :data => { :'base-date' => calendar.base_date }}
|
2
|
+
%h1= t('date.abbr_month_names')[calendar.base_date.month]
|
3
|
+
= link_to '', path_to_previous_month(calendar), :class => 'navigation previous'
|
4
|
+
= link_to '', path_to_next_month(calendar), :class => 'navigation next'
|
5
|
+
= link_to '', path_to_today(calendar), :class => 'navigation today'
|
6
|
+
%ul.dates
|
7
|
+
- (calendar.start_on .. calendar.start_on + 6.days).each do |date|
|
8
|
+
%li.date.wday_header= t('date.abbr_day_names')[date.wday]
|
9
|
+
= render :partial => 'shared/event_cal/date', :collection => calendar.dates, :locals => { :calendar => calendar }
|
@@ -1,4 +1,4 @@
|
|
1
1
|
%ul.event_details.calendar
|
2
2
|
- events.each do |event|
|
3
3
|
%li{ :class => "event_detail #{event.class.to_s.underscore}", :data => { :'event-date' => event.held_on }}
|
4
|
-
= render "event_cal/#{event.class.to_s.underscore}_detail", :event => event
|
4
|
+
= render "shared/event_cal/#{event.class.to_s.underscore}_detail", :event => event
|
@@ -20,18 +20,18 @@ module EventCal
|
|
20
20
|
classes
|
21
21
|
end
|
22
22
|
|
23
|
-
def
|
23
|
+
def path_to_previous_month(calendar)
|
24
24
|
end
|
25
25
|
|
26
|
-
def
|
26
|
+
def path_to_next_month(calendar)
|
27
27
|
end
|
28
28
|
|
29
|
-
def
|
29
|
+
def path_to_today(calendar)
|
30
30
|
end
|
31
31
|
|
32
32
|
def render_monthly(calendar)
|
33
33
|
render(
|
34
|
-
{ :partial => 'event_cal/calendar',
|
34
|
+
{ :partial => 'shared/event_cal/calendar',
|
35
35
|
:format => :html,
|
36
36
|
:locals => { :calendar => calendar },
|
37
37
|
}
|
@@ -40,7 +40,7 @@ module EventCal
|
|
40
40
|
|
41
41
|
def render_event_details(events)
|
42
42
|
render(
|
43
|
-
{ :partial => 'event_cal/event_details',
|
43
|
+
{ :partial => 'shared/event_cal/event_details',
|
44
44
|
:format => :html,
|
45
45
|
:locals => { :events => events }
|
46
46
|
}
|
data/lib/event_cal/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: event_cal
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.3.0
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-02-
|
12
|
+
date: 2013-02-06 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rails
|
@@ -210,9 +210,9 @@ executables: []
|
|
210
210
|
extensions: []
|
211
211
|
extra_rdoc_files: []
|
212
212
|
files:
|
213
|
-
- app/views/event_cal/_calendar.html.haml
|
214
|
-
- app/views/event_cal/_date.html.haml
|
215
|
-
- app/views/event_cal/_event_details.html.haml
|
213
|
+
- app/views/shared/event_cal/_calendar.html.haml
|
214
|
+
- app/views/shared/event_cal/_date.html.haml
|
215
|
+
- app/views/shared/event_cal/_event_details.html.haml
|
216
216
|
- lib/event_cal/calendar.rb
|
217
217
|
- lib/event_cal/calendar_helper.rb
|
218
218
|
- lib/event_cal/engine.rb
|
@@ -257,7 +257,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
257
257
|
version: '0'
|
258
258
|
segments:
|
259
259
|
- 0
|
260
|
-
hash:
|
260
|
+
hash: 3055257193317479361
|
261
261
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
262
262
|
none: false
|
263
263
|
requirements:
|
@@ -266,7 +266,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
266
266
|
version: '0'
|
267
267
|
segments:
|
268
268
|
- 0
|
269
|
-
hash:
|
269
|
+
hash: 3055257193317479361
|
270
270
|
requirements: []
|
271
271
|
rubyforge_project:
|
272
272
|
rubygems_version: 1.8.24
|
@@ -1,9 +0,0 @@
|
|
1
|
-
.calendar.monthly{ :data => { :'base-date' => calendar.base_date }}
|
2
|
-
%h1= t('date.abbr_month_names')[calendar.base_date.month]
|
3
|
-
= link_to '', previous_month_path(calendar), :class => 'navigation previous'
|
4
|
-
= link_to '', next_month_path(calendar), :class => 'navigation next'
|
5
|
-
= link_to '', today_path(calendar), :class => 'navigation today'
|
6
|
-
%ul.dates
|
7
|
-
- (calendar.start_on .. calendar.start_on + 6.days).each do |date|
|
8
|
-
%li.date.wday_header= t('date.abbr_day_names')[date.wday]
|
9
|
-
= render :partial => 'event_cal/date', :collection => calendar.dates, :locals => { :calendar => calendar }
|