diff --git a/app/models/activity.rb b/app/models/activity.rb
index 464af9e..869ec68 100644
--- a/app/models/activity.rb
+++ b/app/models/activity.rb
@@ -72,6 +72,8 @@ class Activity
fields_to_show.collect do |t|
if t == "activity_title"
pd_data << { "data_title" => "#{p.send(t)}" }
+ elsif t.include?("date")
+ pd_data << { "data_title" => (p.send(t).strftime('%Y-%m-%d') rescue p.send(t)) }
else
pd_data << { "data_title" => p.send(t) }
end
@@ -97,9 +99,9 @@ class Activity
when 'activity_area'
value = self.activity_area rescue ''
when 'activity_start_date'
- value = self.activity_start_date rescue ''
+ value = self.activity_start_date.strftime('%Y-%m-%d') rescue ''
when 'activity_end_date'
- value = self.activity_end_date rescue ''
+ value = self.activity_end_date.strftime('%Y-%m-%d') rescue ''
when 'year'
value = self.year rescue ''
when 'note'
diff --git a/modules/personal_activity/index.html.erb b/modules/personal_activity/index.html.erb
new file mode 100644
index 0000000..6f6d760
--- /dev/null
+++ b/modules/personal_activity/index.html.erb
@@ -0,0 +1,35 @@
+
+ {{widget-title}}
+
+
+ {{year}} |
+ {{activity_name}} |
+ {{activity_organizer}} |
+ {{activity_area}} |
+ {{activity_start_date}} |
+ {{activity_end_date}} |
+ {{note}} |
+
+
+
+
+ {{year}} |
+ {{activity_name}} |
+ {{activity_organizer}} |
+ {{activity_area}} |
+ {{activity_start_date}} |
+ {{activity_end_date}} |
+ {{note}} |
+
+
+
+{{pagination_goes_here}}
+
+
diff --git a/modules/personal_activity/index_search1.html.erb b/modules/personal_activity/index_search1.html.erb
new file mode 100644
index 0000000..fff8713
--- /dev/null
+++ b/modules/personal_activity/index_search1.html.erb
@@ -0,0 +1,62 @@
+
+
+
+
+
+ {{widget-title}}
+
+
+ {{year}} |
+ {{activity_name}} |
+ {{activity_organizer}} |
+ {{activity_area}} |
+ {{activity_start_date}} |
+ {{activity_end_date}} |
+ {{note}} |
+
+
+
+
+ {{year}} |
+ {{activity_name}} |
+ {{activity_organizer}} |
+ {{activity_area}} |
+ {{activity_start_date}} |
+ {{activity_end_date}} |
+ {{note}} |
+
+
+
+{{pagination_goes_here}}
+
+
+
diff --git a/modules/personal_activity/info.json b/modules/personal_activity/info.json
new file mode 100644
index 0000000..cda3d13
--- /dev/null
+++ b/modules/personal_activity/info.json
@@ -0,0 +1,12 @@
+{
+ "frontend": [
+ {
+ "filename" : "index",
+ "name" : {
+ "zh_tw" : "1. 列表",
+ "en" : "1. List"
+ },
+ "thumbnail" : "thumb.png"
+ }
+ ]
+}
\ No newline at end of file
diff --git a/modules/personal_activity/show.html.erb b/modules/personal_activity/show.html.erb
new file mode 100644
index 0000000..b183818
--- /dev/null
+++ b/modules/personal_activity/show.html.erb
@@ -0,0 +1,8 @@
+
+
+
+ {{title}} |
+ {{value}} |
+
+
+
diff --git a/modules/personal_activity/thumbs/thumb.png b/modules/personal_activity/thumbs/thumb.png
new file mode 100644
index 0000000..266af56
Binary files /dev/null and b/modules/personal_activity/thumbs/thumb.png differ