OSDN Git Service

m
authoryasushiito <yas@pen-chan.jp>
Sun, 17 Nov 2013 05:47:42 +0000 (14:47 +0900)
committeryasushiito <yas@pen-chan.jp>
Sun, 17 Nov 2013 05:47:42 +0000 (14:47 +0900)
82 files changed:
app/assets/images/balloon.gif [new file with mode: 0644]
app/assets/images/edit.png [new file with mode: 0644]
app/assets/images/ground_color.gif [new file with mode: 0644]
app/assets/images/ground_picture.gif [new file with mode: 0644]
app/assets/images/license.gif [new file with mode: 0644]
app/assets/images/license_group.gif [new file with mode: 0644]
app/assets/images/original_picture.gif [new file with mode: 0644]
app/assets/images/panel_picture.gif [new file with mode: 0644]
app/assets/images/remove.png [new file with mode: 0644]
app/assets/images/resource_picture.gif [new file with mode: 0644]
app/assets/images/sheet_panel.gif [new file with mode: 0644]
app/assets/images/speech.gif [new file with mode: 0644]
app/assets/images/speech_balloon.gif [new file with mode: 0644]
app/assets/images/speech_balloon_template.gif [new file with mode: 0644]
app/assets/images/system_picture.gif [new file with mode: 0644]
app/assets/javascripts/configurations.js.coffee.erb [moved from app/assets/javascripts/configurations.js.coffee with 76% similarity]
app/assets/stylesheets/test.css.scss
app/controllers/artists_controller.rb
app/controllers/authors_controller.rb
app/controllers/balloons_controller.rb
app/controllers/comics_controller.rb
app/controllers/ground_colors_controller.rb
app/controllers/ground_pictures_controller.rb
app/controllers/home_controller.rb
app/controllers/license_groups_controller.rb
app/controllers/licenses_controller.rb
app/controllers/original_pictures_controller.rb
app/controllers/panel_pictures_controller.rb
app/controllers/panels_controller.rb
app/controllers/resource_pictures_controller.rb
app/controllers/scroll_panels_controller.rb
app/controllers/scrolls_controller.rb
app/controllers/sheet_panels_controller.rb
app/controllers/sheets_controller.rb
app/controllers/speech_balloon_templates_controller.rb
app/controllers/speech_balloons_controller.rb
app/controllers/speeches_controller.rb
app/controllers/stories_controller.rb
app/controllers/story_sheets_controller.rb
app/controllers/system_pictures_controller.rb
app/helpers/application_helper.rb
app/models/author.rb
app/models/balloon.rb
app/models/comic.rb
app/models/ground_picture.rb
app/models/license.rb
app/models/original_picture.rb
app/models/panel_picture.rb
app/models/picture.rb
app/models/resource_picture.rb
app/models/scroll.rb
app/models/sheet.rb
app/models/speech.rb
app/models/speech_balloon.rb
app/models/speech_balloon_template.rb
app/models/story.rb
app/models/system_picture.rb
app/views/artists/_summary.html.erb [new file with mode: 0644]
app/views/authors/_summary.html.erb [new file with mode: 0644]
app/views/balloons/_summary.html.erb [new file with mode: 0644]
app/views/ground_colors/_summary.html.erb [new file with mode: 0644]
app/views/ground_colors/_symbol.html.erb [new file with mode: 0644]
app/views/ground_pictures/_summary.html.erb [new file with mode: 0644]
app/views/license_groups/_summary.html.erb [new file with mode: 0644]
app/views/licenses/_summary.html.erb [new file with mode: 0644]
app/views/original_pictures/_publish.html.erb [new file with mode: 0644]
app/views/original_pictures/_summary.html.erb [new file with mode: 0644]
app/views/panel_pictures/_summary.html.erb [new file with mode: 0644]
app/views/panels/_summary.html.erb [new file with mode: 0644]
app/views/resource_pictures/_summary.html.erb [new file with mode: 0644]
app/views/scroll_panels/_summary.html.erb [new file with mode: 0644]
app/views/scrolls/_summary.html.erb [new file with mode: 0644]
app/views/sheet_panels/_summary.html.erb [new file with mode: 0644]
app/views/sheets/_summary.html.erb [new file with mode: 0644]
app/views/speech_balloon_templates/_summary.html.erb [new file with mode: 0644]
app/views/speech_balloons/_summary.html.erb [new file with mode: 0644]
app/views/speeches/_summary.html.erb [new file with mode: 0644]
app/views/stories/_summary.html.erb [new file with mode: 0644]
app/views/story_sheets/_summary.html.erb [new file with mode: 0644]
app/views/system/filer.html.erb [new file with mode: 0644]
app/views/system_pictures/_summary.html.erb [new file with mode: 0644]
config/locales/pettanr.ja.yml

diff --git a/app/assets/images/balloon.gif b/app/assets/images/balloon.gif
new file mode 100644 (file)
index 0000000..84cc1b8
Binary files /dev/null and b/app/assets/images/balloon.gif differ
diff --git a/app/assets/images/edit.png b/app/assets/images/edit.png
new file mode 100644 (file)
index 0000000..6a5f2d2
Binary files /dev/null and b/app/assets/images/edit.png differ
diff --git a/app/assets/images/ground_color.gif b/app/assets/images/ground_color.gif
new file mode 100644 (file)
index 0000000..84cc1b8
Binary files /dev/null and b/app/assets/images/ground_color.gif differ
diff --git a/app/assets/images/ground_picture.gif b/app/assets/images/ground_picture.gif
new file mode 100644 (file)
index 0000000..84cc1b8
Binary files /dev/null and b/app/assets/images/ground_picture.gif differ
diff --git a/app/assets/images/license.gif b/app/assets/images/license.gif
new file mode 100644 (file)
index 0000000..f089247
Binary files /dev/null and b/app/assets/images/license.gif differ
diff --git a/app/assets/images/license_group.gif b/app/assets/images/license_group.gif
new file mode 100644 (file)
index 0000000..6ce9a21
Binary files /dev/null and b/app/assets/images/license_group.gif differ
diff --git a/app/assets/images/original_picture.gif b/app/assets/images/original_picture.gif
new file mode 100644 (file)
index 0000000..a7c63f4
Binary files /dev/null and b/app/assets/images/original_picture.gif differ
diff --git a/app/assets/images/panel_picture.gif b/app/assets/images/panel_picture.gif
new file mode 100644 (file)
index 0000000..84cc1b8
Binary files /dev/null and b/app/assets/images/panel_picture.gif differ
diff --git a/app/assets/images/remove.png b/app/assets/images/remove.png
new file mode 100644 (file)
index 0000000..66bdf49
Binary files /dev/null and b/app/assets/images/remove.png differ
diff --git a/app/assets/images/resource_picture.gif b/app/assets/images/resource_picture.gif
new file mode 100644 (file)
index 0000000..a7c63f4
Binary files /dev/null and b/app/assets/images/resource_picture.gif differ
diff --git a/app/assets/images/sheet_panel.gif b/app/assets/images/sheet_panel.gif
new file mode 100644 (file)
index 0000000..0707502
Binary files /dev/null and b/app/assets/images/sheet_panel.gif differ
diff --git a/app/assets/images/speech.gif b/app/assets/images/speech.gif
new file mode 100644 (file)
index 0000000..84cc1b8
Binary files /dev/null and b/app/assets/images/speech.gif differ
diff --git a/app/assets/images/speech_balloon.gif b/app/assets/images/speech_balloon.gif
new file mode 100644 (file)
index 0000000..84cc1b8
Binary files /dev/null and b/app/assets/images/speech_balloon.gif differ
diff --git a/app/assets/images/speech_balloon_template.gif b/app/assets/images/speech_balloon_template.gif
new file mode 100644 (file)
index 0000000..7b69910
Binary files /dev/null and b/app/assets/images/speech_balloon_template.gif differ
diff --git a/app/assets/images/system_picture.gif b/app/assets/images/system_picture.gif
new file mode 100644 (file)
index 0000000..a7c63f4
Binary files /dev/null and b/app/assets/images/system_picture.gif differ
@@ -1,5 +1,447 @@
 @configurations = {\r
+  filers: {\r
+    scroll: {\r
+      symbol: {\r
+        type: 'image',\r
+        name: '<%= asset_path('item.png') %>',\r
+      },\r
+      caption: {\r
+        type: 'column',\r
+        name: 'title',\r
+        link: {\r
+          type: 'action'\r
+          name: 'play',\r
+        },\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'default',\r
+      },\r
+    },\r
+    scroll_panel: {\r
+      symbol: {\r
+        type: 'image',\r
+        name: '<%= asset_path('item.png') %>',\r
+        link: {\r
+          type: 'none'\r
+        },\r
+      },\r
+      caption: {\r
+        type: 'none',\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'none'\r
+      },\r
+    },\r
+    comic: {\r
+      symbol: {\r
+        type: 'image',\r
+        name: '<%= asset_path('item.png') %>',\r
+      },\r
+      caption: {\r
+        type: 'column',\r
+        name: 'title',\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'default',\r
+      },\r
+    },\r
+    story: {\r
+      symbol: {\r
+        type: 'image',\r
+        name: '<%= asset_path('item.png') %>',\r
+      },\r
+      caption: {\r
+        type: 'method',\r
+        name: 'title_with_t',\r
+        link: {\r
+          type: 'action'\r
+          name: 'play',\r
+        },\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'default',\r
+      },\r
+    },\r
+    story_sheet: {\r
+      symbol: {\r
+        type: 'image',\r
+        name: '<%= asset_path('item.png') %>',\r
+        link: {\r
+          type: 'none'\r
+        },\r
+      },\r
+      caption: {\r
+        type: 'none',\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'none'\r
+      },\r
+    },\r
+    sheet: {\r
+      symbol: {\r
+        type: 'image',\r
+        name: '<%= asset_path('item.png') %>',\r
+      },\r
+      caption: {\r
+        type: 'column',\r
+        name: 'caption',\r
+        link: {\r
+          type: 'action'\r
+          name: 'play',\r
+        },\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'default',\r
+      },\r
+    },\r
+    sheet_panel: {\r
+      symbol: {\r
+        type: 'image',\r
+        name: '<%= asset_path('item.png') %>',\r
+        link: {\r
+          type: 'none'\r
+        },\r
+      },\r
+      caption: {\r
+        type: 'none',\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'none'\r
+      },\r
+    },\r
+    panel: {\r
+      symbol: {\r
+        type: 'image',\r
+        name: '<%= asset_path('item.png') %>',\r
+      },\r
+      caption: {\r
+        type: 'method',\r
+        name: 'plain_scenario',\r
+        link: {\r
+          type: 'none'\r
+        },\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'default',\r
+      },\r
+    },\r
+    panel_picture: {\r
+      symbol: {\r
+        type: 'picture',\r
+        name: 'symbol_option',\r
+      },\r
+      caption: {\r
+        type: 'column',\r
+        name: 'caption',\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'none',\r
+      },\r
+    },\r
+    speech_balloon: {\r
+      symbol: {\r
+        type: 'picture',\r
+        name: 'symbol_option',\r
+      },\r
+      caption: {\r
+        type: 'method',\r
+        name: 'plain_scenario',\r
+        link: {\r
+          type: 'none'\r
+        },\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'none',\r
+      },\r
+    },\r
+    speech: {\r
+      symbol: {\r
+        type: 'picture',\r
+        name: 'symbol_option',\r
+      },\r
+      caption: {\r
+        type: 'column',\r
+        name: 'content',\r
+        link: {\r
+          type: 'none'\r
+        },\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'none',\r
+      },\r
+    },\r
+    balloon: {\r
+      symbol: {\r
+        type: 'picture',\r
+        name: 'symbol_option',\r
+      },\r
+      caption: {\r
+        type: 'none',\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'none',\r
+      },\r
+    },\r
+    ground_picture: {\r
+      symbol: {\r
+        type: 'picture',\r
+        name: 'symbol_option',\r
+      },\r
+      caption: {\r
+        type: 'column',\r
+        name: 'caption',\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'none',\r
+      },\r
+    },\r
+    ground_color: {\r
+      symbol: {\r
+        type: 'template',\r
+        name: 'symbol',\r
+      },\r
+      caption: {\r
+        type: 'column',\r
+        name: 'caption',\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'none',\r
+      },\r
+    },\r
+    original_picture: {\r
+      symbol: {\r
+        type: 'picture',\r
+        name: 'symbol_option',\r
+      },\r
+      caption: {\r
+        type: 'method',\r
+        name: 'revision',\r
+        link: {\r
+          type: 'action'\r
+          name: 'history',\r
+        },\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'template',\r
+        name: 'publish',\r
+      },\r
+    },\r
+    picture: {\r
+    },\r
+    resource_picture: {\r
+      symbol: {\r
+        type: 'picture',\r
+        name: 'symbol_option',\r
+      },\r
+      caption: {\r
+        type: 'none',\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'none',\r
+      },\r
+    },\r
+    speech_balloon_template: {\r
+      symbol: {\r
+        type: 'picture',\r
+        name: 'symbol_option',\r
+      },\r
+      caption: {\r
+        type: 'column',\r
+        name: 'caption',\r
+      },\r
+      summary: {\r
+        type: 'none',\r
+      },\r
+      edit: {\r
+        type: 'none',\r
+      },\r
+    },\r
+    writing_format: {\r
+      symbol: {\r
+        type: 'image',\r
+        name: '<%= asset_path('item.png') %>',\r
+      },\r
+      caption: {\r
+        type: 'column',\r
+        name: 'caption',\r
+      },\r
+      summary: {\r
+        type: 'none',\r
+      },\r
+      edit: {\r
+        type: 'none',\r
+      },\r
+    },\r
+    license_group: {\r
+      symbol: {\r
+        type: 'image',\r
+        name: '<%= asset_path('item.png') %>',\r
+      },\r
+      caption: {\r
+        type: 'column',\r
+        name: 'caption',\r
+        link: {\r
+          type: 'url_column'\r
+          name: 'url',\r
+        },\r
+      },\r
+      summary: {\r
+        type: 'none',\r
+      },\r
+      edit: {\r
+        type: 'none',\r
+      },\r
+    },\r
+    license: {\r
+      symbol: {\r
+        type: 'image',\r
+        name: '<%= asset_path('item.png') %>',\r
+      },\r
+      caption: {\r
+        type: 'method',\r
+        name: 'caption_with_group',\r
+        link: {\r
+          type: 'url_column'\r
+          name: 'url',\r
+        },\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'none',\r
+      },\r
+    },\r
+    author: {\r
+      symbol: {\r
+        type: 'image',\r
+        name: '<%= asset_path('item.png') %>',\r
+      },\r
+      caption: {\r
+        type: 'column',\r
+        name: 'name',\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'account',\r
+      },\r
+    },\r
+    artist: {\r
+      symbol: {\r
+        type: 'image',\r
+        name: '<%= asset_path('item.png') %>',\r
+      },\r
+      caption: {\r
+        type: 'column',\r
+        name: 'name',\r
+      },\r
+      summary: {\r
+        type: 'template',\r
+        name: 'summary',\r
+      },\r
+      edit: {\r
+        type: 'account',\r
+      },\r
+    },\r
+    system_picture: {\r
+      symbol: {\r
+        type: 'picture',\r
+        name: 'symbol_option',\r
+      },\r
+      caption: {\r
+        type: 'none',\r
+      },\r
+      summary: {\r
+        type: 'none',\r
+      },\r
+      edit: {\r
+        type: 'none',\r
+      },\r
+    },\r
+  },\r
   models: {\r
+    Sheet: 'sheet',\r
+    sheet: {\r
+      class_name: 'Sheet',\r
+      table_name: 'sheets',\r
+      attributes: {\r
+        id: {\r
+          type: 'number',\r
+          primary_key: 1,\r
+          rules : {\r
+            number: true,\r
+          }\r
+        },\r
+      }\r
+    },\r
     Panel: 'panel',\r
     panel: {\r
       class_name: 'Panel',\r
index ea390d3..48bdcff 100644 (file)
@@ -356,3 +356,250 @@ font-family : monospace;
 .row_break {
   clear: both;
 }
+
+
+.filer {
+    list-style-type: none;
+    margin: 0;
+    padding: 0;
+}
+
+.filer-head {
+  clear: both;
+  margin: 0;
+  padding: 0;
+  height: 22px; 
+  overflow: hidden;
+  background: #efefef;
+}
+.filer-head div {
+  float: left;
+}
+
+.filer-item {
+  clear: both;
+  margin: 0;
+  padding: 0;
+  height: 66px; 
+  overflow: hidden;
+}
+.filer-item div {
+}
+
+.filer-head-symbol {
+  width: 66px; 
+}
+.filer-head-caption {
+  width: 200px; 
+}
+.filer-head-summary {
+  width: 200px; 
+}
+.filer-head-icon {
+  width: 66px; 
+}
+.filer-head-date {
+  width: 100px; 
+}
+.filer-head-edit {
+  width: 66px; 
+}
+
+.filer-item-symbol {
+  float: left;
+  width: 66px; 
+}
+.filer-item-caption {
+  float: left;
+  width: 200px; 
+}
+.filer-item-summary {
+  float: left;
+  width: 200px; 
+}
+.filer-item-icon {
+  float: left;
+  width: 66px; 
+}
+.filer-item-date {
+  float: left;
+  width: 76px; 
+}
+.filer-item-edit {
+  float: left;
+  width: 76px; 
+}
+
+//scroll
+.filer-head-scroll .filer-head-symbol {
+}
+.filer-head-scroll .filer-head-caption {
+  width: 250px; 
+}
+.filer-head-scroll .filer-head-summary {
+  width: 150px; 
+}
+.filer-head-scroll .filer-head-icon {
+}
+.filer-head-scroll .filer-head-date {
+}
+.filer-head-scroll .filer-head-edit {
+}
+
+.filer-item-scroll .filer-item-caption {
+  width: 250px; 
+}
+.filer-item-scroll .filer-item-summary {
+  width: 150px; 
+}
+
+//comic
+.filer-head-comic .filer-head-caption {
+  width: 250px; 
+}
+.filer-head-comic .filer-head-summary {
+  width: 150px; 
+}
+.filer-item-comic .filer-item-caption {
+  width: 250px; 
+}
+.filer-item-comic .filer-item-summary {
+  width: 150px; 
+}
+
+//story
+.filer-head-story .filer-head-caption {
+  width: 250px; 
+}
+.filer-head-story .filer-head-summary {
+  width: 150px; 
+}
+.filer-item-story .filer-item-caption {
+  width: 250px; 
+}
+.filer-item-story .filer-item-summary {
+  width: 150px; 
+}
+
+//panel
+.filer-head-panel .filer-head-caption {
+  width: 250px; 
+}
+.filer-head-panel .filer-head-summary {
+  width: 150px; 
+}
+.filer-item-panel .filer-item-caption {
+  width: 250px; 
+}
+.filer-item-panel .filer-item-summary {
+  width: 150px; 
+}
+
+//panel_picture
+.filer-head-panel_picture .filer-head-caption {
+  width: 100px; 
+}
+.filer-head-panel_picture .filer-head-summary {
+  width: 300px; 
+}
+.filer-item-panel_picture .filer-item-caption {
+  width: 100px; 
+}
+.filer-item-panel_picture .filer-item-summary {
+  width: 300px; 
+}
+.panel_picture-summary div {
+  float: left;
+}
+
+//speech_balloon
+.filer-head-speech_balloon .filer-head-caption {
+  width: 300px; 
+}
+.filer-head-speech_balloon .filer-head-summary {
+  width: 100px; 
+}
+.filer-item-speech_balloon .filer-item-caption {
+  width: 300px; 
+}
+.filer-item-speech_balloon .filer-item-summary {
+  width: 100px; 
+}
+
+//speech
+.filer-head-speech .filer-head-caption {
+  width: 300px; 
+}
+.filer-head-speech .filer-head-summary {
+  width: 100px; 
+}
+.filer-item-speech .filer-item-caption {
+  width: 300px; 
+}
+.filer-item-speech .filer-item-summary {
+  width: 100px; 
+}
+
+//ground_picture
+.filer-head-ground_picture .filer-head-caption {
+  width: 100px; 
+}
+.filer-head-ground_picture .filer-head-summary {
+  width: 300px; 
+}
+.filer-item-ground_picture .filer-item-caption {
+  width: 100px; 
+}
+.filer-item-ground_picture .filer-item-summary {
+  width: 300px; 
+}
+.ground_picture-summary div {
+  float: left;
+}
+
+//ground_color
+.filer-head-ground_color .filer-head-caption {
+  width: 300px; 
+}
+.filer-head-ground_color .filer-head-summary {
+  width: 100px; 
+}
+.filer-item-ground_color .filer-item-caption {
+  width: 300px; 
+}
+.filer-item-ground_color .filer-item-summary {
+  width: 100px; 
+}
+
+//original_picture
+.filer-head-original_picture .filer-head-caption {
+  width: 50px; 
+}
+.filer-head-original_picture .filer-head-summary {
+  width: 350px; 
+}
+.filer-item-original_picture .filer-item-caption {
+  width: 50px; 
+}
+.filer-item-original_picture .filer-item-summary {
+  width: 350px; 
+}
+.original_picture-summary div {
+  float: left;
+}
+
+//resource_picture
+.filer-head-resource_picture .filer-head-summary {
+  width: 250px; 
+}
+.filer-item-resource_picture .filer-item-summary {
+  width: 250px; 
+}
+
+//speech_balloon_template
+.filer-head-speech_balloon_template .filer-head-caption {
+  width: 400px; 
+}
+.filer-item-speech_balloon_template .filer-item-caption {
+  width: 400px; 
+}
index d6c4a0a..4c523ed 100644 (file)
@@ -18,6 +18,10 @@ class ArtistsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Artist.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @artists, :model => Artist, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render :json => @artists.to_json(Artist.list_json_opt) }
     end
index 345c6eb..117051b 100644 (file)
@@ -18,6 +18,10 @@ class AuthorsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Author.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @authors, :model => Author, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render :json => @authors.to_json(Author.list_json_opt) }
     end
@@ -43,6 +47,10 @@ class AuthorsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Scroll.himlist_paginate(@au, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @scrolls, :model => Scroll, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @scrolls.to_json(Scroll.list_json_opt) }
     end
@@ -58,6 +66,10 @@ class AuthorsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = ScrollPanel.himlist_paginate(@au, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @scroll_panels, :model => ScrollPanel, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @scroll_panels.to_json(ScrollPanel.list_json_opt) }
     end
@@ -73,6 +85,10 @@ class AuthorsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Comic.himlist_paginate(@au, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @comics, :model => Comic, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @comics.to_json(Comic.list_json_opt) }
     end
@@ -88,6 +104,10 @@ class AuthorsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Story.himlist_paginate(@au, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @stories, :model => Story, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @stories.to_json(Story.list_json_opt) }
     end
@@ -103,6 +123,10 @@ class AuthorsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = StorySheet.himlist_paginate(@au, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @story_sheets, :model => StorySheet, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @story_sheets.to_json(StorySheet.list_json_opt) }
     end
@@ -118,6 +142,10 @@ class AuthorsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Sheet.himlist_paginate(@au, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @sheets, :model => Sheet, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @sheets.to_json(Sheet.list_json_opt) }
     end
@@ -133,6 +161,10 @@ class AuthorsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = SheetPanel.himlist_paginate(@au, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @sheet_panels, :model => SheetPanel, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @sheet_panels.to_json(SheetPanel.list_json_opt) }
     end
@@ -148,6 +180,10 @@ class AuthorsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Panel.himlist_paginate(@au, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @panels, :model => Panel, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render text: Panel.list_as_json_text(@panels) }
     end
@@ -163,6 +199,10 @@ class AuthorsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = PanelPicture.himlist_paginate(@au, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @panel_pictures, :model => PanelPicture, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @panel_pictures.to_json(PanelPicture.list_json_opt) }
     end
@@ -178,6 +218,10 @@ class AuthorsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = SpeechBalloon.himlist_paginate(@au, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @speech_balloons, :model => SpeechBalloon, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @speech_balloons.to_json(SpeechBalloon.list_json_opt) }
     end
@@ -193,6 +237,10 @@ class AuthorsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = GroundPicture.himlist_paginate(@au, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @ground_pictures, :model => GroundPicture, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @ground_pictures.to_json(GroundPicture.list_json_opt) }
     end
@@ -208,6 +256,10 @@ class AuthorsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = GroundColor.himlist_paginate(@au, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @ground_colors, :model => GroundColor, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @ground_colors.to_json(GroundColor.list_json_opt) }
     end
index 885e055..eecefdc 100644 (file)
@@ -16,7 +16,13 @@ class BalloonsController < ApplicationController
     @balloons = Balloon.list(@page, @page_size)
 
     respond_to do |format|
-      format.html # index.html.erb
+      format.html {
+        @paginate = Balloon.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @balloons, :model => Balloon, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
+      }
       format.json { render json: @balloons.to_json(Balloon.list_json_opt) }
     end
   end
index d60fd81..789d1a1 100644 (file)
@@ -17,6 +17,10 @@ class ComicsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Comic.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @comics, :model => Comic, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @comics.to_json(Comic.list_json_opt) }
       format.atom 
index f990f24..e98c710 100644 (file)
@@ -17,6 +17,10 @@ class GroundColorsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = GroundColor.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @ground_colors, :model => GroundColor, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render :json => @ground_colors.to_json(GroundColor.list_json_opt) }
     end
index 16989a0..04b164f 100644 (file)
@@ -17,6 +17,10 @@ class GroundPicturesController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = GroundPicture.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @ground_pictures, :model => GroundPicture, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render :json => @ground_pictures.to_json(GroundPicture.list_json_opt) }
     end
index a09252f..7c74642 100644 (file)
@@ -48,6 +48,10 @@ class HomeController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Scroll.mylist_paginate(@author, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @scrolls, :model => Scroll, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @scrolls.to_json(Scroll.list_json_opt) }
     end
@@ -61,6 +65,10 @@ class HomeController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = ScrollPanel.mylist_paginate(@author, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @scroll_panels, :model => ScrollPanel, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @scroll_panels.to_json(ScrollPanel.list_json_opt) }
     end
@@ -74,6 +82,10 @@ class HomeController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Comic.mylist_paginate(@author, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @comics, :model => Comic, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @comics.to_json(Comic.list_json_opt) }
     end
@@ -87,6 +99,10 @@ class HomeController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Story.mylist_paginate(@author, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @stories, :model => Story, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @stories.to_json(Story.list_json_opt) }
     end
@@ -100,6 +116,10 @@ class HomeController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = StorySheet.mylist_paginate(@author, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @story_sheets, :model => StorySheet, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @story_sheets.to_json(StorySheet.list_json_opt) }
     end
@@ -113,6 +133,10 @@ class HomeController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Sheet.mylist_paginate(@author, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @sheets, :model => Sheet, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @sheets.to_json(Sheet.list_json_opt) }
     end
@@ -126,6 +150,10 @@ class HomeController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = SheetPanel.mylist_paginate(@author, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @sheet_panels, :model => SheetPanel, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @sheet_panels.to_json(SheetPanel.list_json_opt) }
     end
@@ -139,6 +167,10 @@ class HomeController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Panel.mylist_paginate(@author, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @panels, :model => Panel, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render text: Panel.list_as_json_text(@panels) }
     end
@@ -152,6 +184,10 @@ class HomeController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = PanelPicture.mylist_paginate(@author, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @panel_pictures, :model => PanelPicture, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @panel_pictures.to_json(PanelPicture.list_json_opt) }
     end
@@ -165,6 +201,10 @@ class HomeController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = SpeechBalloon.mylist_paginate(@author, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @speech_balloons, :model => SpeechBalloon, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @speech_balloons.to_json(SpeechBalloon.list_json_opt) }
     end
@@ -178,6 +218,10 @@ class HomeController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = GroundPicture.mylist_paginate(@author, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @ground_pictures, :model => GroundPicture, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @ground_pictures.to_json(GroundPicture.list_json_opt) }
     end
@@ -191,6 +235,10 @@ class HomeController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = GroundColor.mylist_paginate(@author, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @ground_colors, :model => GroundColor, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @ground_colors.to_json(GroundColor.list_json_opt) }
     end
@@ -204,6 +252,10 @@ class HomeController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = ResourcePicture.mylist_paginate(@author, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @resource_pictures, :model => ResourcePicture, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @resource_pictures.to_json(ResourcePicture.list_json_opt) }
     end
index 5e652a1..41787c2 100644 (file)
@@ -8,7 +8,12 @@ class LicenseGroupsController < ApplicationController
     @license_groups = LicenseGroup.list()
 
     respond_to do |format|
-      format.html # index.html.erb
+      format.html {
+        render :template => 'system/filer', :locals => {
+          :items => @license_groups, :model => LicenseGroup, 
+          :roles => [@user, @admin], :pager => nil
+        }
+      }
       format.json { render json: @license_groups.to_json(LicenseGroup.list_json_opt) }
     end
   end
index 49e1112..2754dd2 100644 (file)
@@ -8,7 +8,12 @@ class LicensesController < ApplicationController
     @licenses = License.list()
 
     respond_to do |format|
-      format.html # index.html.erb
+      format.html {
+        render :template => 'system/filer', :locals => {
+          :items => @licenses, :model => License, 
+          :roles => [@user, @admin], :pager => nil
+        }
+      }
       format.json { render json: @licenses.to_json(License.list_json_opt) }
     end
   end
index 6f70a0e..63f5129 100644 (file)
@@ -14,6 +14,10 @@ class OriginalPicturesController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = OriginalPicture.mylist_paginate(@artist, @page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @original_pictures, :model => OriginalPicture, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @original_pictures.to_json(OriginalPicture.list_json_opt) }
     end
index 69f7cb5..b48915b 100644 (file)
@@ -18,6 +18,10 @@ class PanelPicturesController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = PanelPicture.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @panel_pictures, :model => PanelPicture, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render :json => @panel_pictures.to_json(PanelPicture.list_json_opt) }
     end
index 51f7b63..df0028c 100644 (file)
@@ -20,6 +20,12 @@ class PanelsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Panel.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @panels, :model => Panel, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
+      }
+      format.html {
       }
       format.json { render text: Panel.list_as_json_text(@panels) }
       format.atom 
index ae83fbd..1188090 100644 (file)
@@ -18,6 +18,10 @@ class ResourcePicturesController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = ResourcePicture.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @resource_pictures, :model => ResourcePicture, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render :json => @resource_pictures.to_json(ResourcePicture.list_json_opt) }
     end
index 305638c..2fb8d04 100644 (file)
@@ -18,6 +18,10 @@ class ScrollPanelsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = ScrollPanel.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @scroll_panels, :model => ScrollPanel, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render :json => @scroll_panels.to_json(ScrollPanel.list_json_opt) }
     end
index 9c255bd..ff43f46 100644 (file)
@@ -17,6 +17,10 @@ class ScrollsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Scroll.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @scrolls, :model => Scroll, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @scrolls.to_json(Scroll.list_json_opt) }
       format.atom 
index d7a7961..d95f77e 100644 (file)
@@ -18,6 +18,10 @@ class SheetPanelsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = SheetPanel.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @sheet_panels, :model => SheetPanel, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render :json => @sheet_panels.to_json(SheetPanel.list_json_opt) }
     end
index b7cf892..1d7505b 100644 (file)
@@ -17,6 +17,10 @@ class SheetsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Sheet.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @sheets, :model => Sheet, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @sheets.to_json(Sheet.list_json_opt) }
       format.atom 
index eb8d883..6494e04 100644 (file)
@@ -8,19 +8,20 @@ class SpeechBalloonTemplatesController < ApplicationController
   end
   before_filter :authenticate_admin!, :only => [:list, :browse, :destroy]
 
-  # GET /speech_balloon_templates
-  # GET /speech_balloon_templates.json
   def index
     @speech_balloon_templates = SpeechBalloonTemplate.enable_list
 
     respond_to do |format|
-      format.html # index.html.erb
+      format.html {
+        render :template => 'system/filer', :locals => {
+          :items => @speech_balloon_templates, :model => SpeechBalloonTemplate, 
+          :roles => [@user, @admin], :pager => nil
+        }
+      }
       format.json { render json: @speech_balloon_templates.to_json(SpeechBalloonTemplate.list_json_opt) }
     end
   end
 
-  # GET /speech_balloon_templates/1
-  # GET /speech_balloon_templates/1.json
   def show
     @speech_balloon_template = SpeechBalloonTemplate.show(params[:id], [@user, @admin])
 
@@ -54,8 +55,6 @@ class SpeechBalloonTemplatesController < ApplicationController
     end
   end
 
-  # DELETE /speech_balloon_templates/1
-  # DELETE /speech_balloon_templates/1.json
   def destroy
     @speech_balloon_template = SpeechBalloonTemplate.find(params[:id])
     @speech_balloon_template.destroy
index 9350511..8bfe140 100644 (file)
@@ -18,6 +18,10 @@ class SpeechBalloonsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = SpeechBalloon.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @speech_balloons, :model => SpeechBalloon, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render json: @speech_balloons.to_json(SpeechBalloon.list_json_opt) }
     end
index 24ca971..8aa7789 100644 (file)
@@ -16,7 +16,13 @@ class SpeechesController < ApplicationController
     @speeches = Speech.list(@page, @page_size)
 
     respond_to do |format|
-      format.html # index.html.erb
+      format.html {
+        @paginate = Speech.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @speeches, :model => Speech, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
+      }
       format.json { render json: @speeches.to_json(Speech.list_json_opt) }
     end
   end
index fba32e6..f27fa68 100644 (file)
@@ -18,6 +18,10 @@ class StoriesController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = Story.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @stories, :model => Story, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render :json => @stories.to_json(Story.list_json_opt) }
     end
index 020fee1..66e7fe9 100644 (file)
@@ -18,6 +18,10 @@ class StorySheetsController < ApplicationController
     respond_to do |format|
       format.html {
         @paginate = StorySheet.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @story_sheets, :model => StorySheet, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
       }
       format.json { render :json => @story_sheets.to_json(StorySheet.list_json_opt) }
     end
index ad83b27..7b6da92 100644 (file)
@@ -18,7 +18,13 @@ class SystemPicturesController < ApplicationController
     @system_pictures = SystemPicture.list(@page, @page_size)
 
     respond_to do |format|
-      format.html # index.html.erb
+      format.html {
+        @paginate = SystemPicture.list_paginate(@page, @page_size)
+        render :template => 'system/filer', :locals => {
+          :items => @system_pictures, :model => SystemPicture, 
+          :roles => [@user, @admin], :pager => @paginate
+        }
+      }
       format.json { render json: @system_pictures.to_json(SystemPicture.list_json_opt) }
     end
   end
index ce88098..6c04d1c 100644 (file)
@@ -90,7 +90,448 @@ module ApplicationHelper
   def configurations
     JSON.parse(<<HD
 {
+    "filers": {
+        "scroll": {
+            "symbol": {
+                "type": "image",
+                "name": "/assets/item.png"
+            },
+            "caption": {
+                "type": "column",
+                "name": "title",
+                "link": {
+                    "type": "action",
+                    "name": "play"
+                }
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "default"
+            }
+        },
+        "scroll_panel": {
+            "symbol": {
+                "type": "image",
+                "name": "/assets/item.png",
+                "link": {
+                    "type": "none"
+                }
+            },
+            "caption": {
+                "type": "none"
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "none"
+            }
+        },
+        "comic": {
+            "symbol": {
+                "type": "image",
+                "name": "/assets/item.png"
+            },
+            "caption": {
+                "type": "column",
+                "name": "title"
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "default"
+            }
+        },
+        "story": {
+            "symbol": {
+                "type": "image",
+                "name": "/assets/item.png"
+            },
+            "caption": {
+                "type": "method",
+                "name": "title_with_t",
+                "link": {
+                    "type": "action",
+                    "name": "play"
+                }
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "default"
+            }
+        },
+        "story_sheet": {
+            "symbol": {
+                "type": "image",
+                "name": "/assets/item.png",
+                "link": {
+                    "type": "none"
+                }
+            },
+            "caption": {
+                "type": "none"
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "none"
+            }
+        },
+        "sheet": {
+            "symbol": {
+                "type": "image",
+                "name": "/assets/item.png"
+            },
+            "caption": {
+                "type": "column",
+                "name": "caption",
+                "link": {
+                    "type": "action",
+                    "name": "play"
+                }
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "default"
+            }
+        },
+        "sheet_panel": {
+            "symbol": {
+                "type": "image",
+                "name": "/assets/item.png",
+                "link": {
+                    "type": "none"
+                }
+            },
+            "caption": {
+                "type": "none"
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "none"
+            }
+        },
+        "panel": {
+            "symbol": {
+                "type": "image",
+                "name": "/assets/item.png"
+            },
+            "caption": {
+                "type": "method",
+                "name": "plain_scenario",
+                "link": {
+                    "type": "none"
+                }
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "default"
+            }
+        },
+        "panel_picture": {
+            "symbol": {
+                "type": "picture",
+                "name": "symbol_option"
+            },
+            "caption": {
+                "type": "column",
+                "name": "caption"
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "none"
+            }
+        },
+        "speech_balloon": {
+            "symbol": {
+                "type": "picture",
+                "name": "symbol_option"
+            },
+            "caption": {
+                "type": "method",
+                "name": "plain_scenario",
+                "link": {
+                    "type": "none"
+                }
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "none"
+            }
+        },
+        "speech": {
+            "symbol": {
+                "type": "picture",
+                "name": "symbol_option"
+            },
+            "caption": {
+                "type": "column",
+                "name": "content",
+                "link": {
+                    "type": "none"
+                }
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "none"
+            }
+        },
+        "balloon": {
+            "symbol": {
+                "type": "picture",
+                "name": "symbol_option"
+            },
+            "caption": {
+                "type": "none"
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "none"
+            }
+        },
+        "ground_picture": {
+            "symbol": {
+                "type": "picture",
+                "name": "symbol_option"
+            },
+            "caption": {
+                "type": "column",
+                "name": "caption"
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "none"
+            }
+        },
+        "ground_color": {
+            "symbol": {
+                "type": "template",
+                "name": "symbol"
+            },
+            "caption": {
+                "type": "column",
+                "name": "caption"
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "none"
+            }
+        },
+        "original_picture": {
+            "symbol": {
+                "type": "picture",
+                "name": "symbol_option"
+            },
+            "caption": {
+                "type": "method",
+                "name": "revision",
+                "link": {
+                    "type": "action",
+                    "name": "history"
+                }
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "template",
+                "name": "publish"
+            }
+        },
+        "picture": {},
+        "resource_picture": {
+            "symbol": {
+                "type": "picture",
+                "name": "symbol_option"
+            },
+            "caption": {
+                "type": "none"
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "none"
+            }
+        },
+        "speech_balloon_template": {
+            "symbol": {
+                "type": "picture",
+                "name": "symbol_option"
+            },
+            "caption": {
+                "type": "column",
+                "name": "caption"
+            },
+            "summary": {
+                "type": "none"
+            },
+            "edit": {
+                "type": "none"
+            }
+        },
+        "writing_format": {
+            "symbol": {
+                "type": "image",
+                "name": "/assets/item.png"
+            },
+            "caption": {
+                "type": "column",
+                "name": "caption"
+            },
+            "summary": {
+                "type": "none"
+            },
+            "edit": {
+                "type": "none"
+            }
+        },
+        "license_group": {
+            "symbol": {
+                "type": "image",
+                "name": "/assets/item.png"
+            },
+            "caption": {
+                "type": "column",
+                "name": "caption",
+                "link": {
+                    "type": "url_column",
+                    "name": "url"
+                }
+            },
+            "summary": {
+                "type": "none"
+            },
+            "edit": {
+                "type": "none"
+            }
+        },
+        "license": {
+            "symbol": {
+                "type": "image",
+                "name": "/assets/item.png"
+            },
+            "caption": {
+                "type": "method",
+                "name": "caption_with_group",
+                "link": {
+                    "type": "url_column",
+                    "name": "url"
+                }
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "none"
+            }
+        },
+        "author": {
+            "symbol": {
+                "type": "image",
+                "name": "/assets/item.png"
+            },
+            "caption": {
+                "type": "column",
+                "name": "name"
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "account"
+            }
+        },
+        "artist": {
+            "symbol": {
+                "type": "image",
+                "name": "/assets/item.png"
+            },
+            "caption": {
+                "type": "column",
+                "name": "name"
+            },
+            "summary": {
+                "type": "template",
+                "name": "summary"
+            },
+            "edit": {
+                "type": "account"
+            }
+        },
+        "system_picture": {
+            "symbol": {
+                "type": "picture",
+                "name": "symbol_option"
+            },
+            "caption": {
+                "type": "none"
+            },
+            "summary": {
+                "type": "none"
+            },
+            "edit": {
+                "type": "none"
+            }
+        }
+    },
     "models": {
+        "Sheet": "sheet",
+        "sheet": {
+            "class_name": "Sheet",
+            "table_name": "sheets",
+            "attributes": {
+                "id": {
+                    "type": "number",
+                    "primary_key": 1,
+                    "rules": {
+                        "number": true
+                    }
+                }
+            }
+        },
         "Panel": "panel",
         "panel": {
             "class_name": "Panel",
index 40d0c1d..460d2e8 100644 (file)
@@ -2,6 +2,8 @@ class Author < ActiveRecord::Base
   has_one :artist
   belongs_to :user
   has_many :scrolls
+  has_many :comics
+  has_many :stories
   has_many :sheets
   has_many :panels
   belongs_to :working_panel, :class_name => "Panel"
index fbfc8bf..110a3aa 100644 (file)
@@ -53,6 +53,10 @@ class Balloon < ActiveRecord::Base
 self.system_picture_id = 1
   end
   
+  def symbol_option
+    self.get_parent.speech_balloon_template.symbol_option
+  end
+  
   def get_parent
     self.speech_balloon || @new_parent
   end
@@ -82,16 +86,20 @@ self.system_picture_id = 1
     page_size
   end
   
+  def self.list_where
+    'panels.publish > 0'
+  end
+  
   def self.list page = 1, page_size = self.default_page_size
-    opt = {}
-    opt.merge!(Balloon.list_opt)
-    opt.merge!({:limit => page_size, :offset => (page -1) * page_size}) if page_size > 0
-    opt.merge!({:conditions => 'panels.publish > 0', :order => 'balloons.updated_at desc'})
-    Balloon.find(:all, opt)
+    Balloon.where(self.list_where()).includes(Balloon.list_opt).order('balloons.updated_at desc').offset((page -1) * page_size).limit(page_size)
+  end
+  
+  def self.list_paginate page = 1, page_size = self.default_page_size
+    Kaminari.paginate_array(Array.new(Balloon.where(self.list_where()).includes(Balloon.list_opt).count, nil)).page(page).per(page_size)
   end
   
   def self.list_opt
-    {:include => {:speech_balloon => {:panel => {:author => {}}, :speech => {}, :speech_balloon_template => {} }}}
+    {:speech_balloon => {:panel => {:author => {}}, :speech => {}, :speech_balloon_template => {} }}
   end
   
   def self.list_json_opt
index 187385a..3a27abc 100644 (file)
@@ -42,6 +42,13 @@ class Comic < ActiveRecord::Base
     self.visible > 0
   end
   
+  def comic_stories_count
+    Story.where(['stories.comic_id = ?', self.id]).count
+  end
+  
+  def symbol_filename
+  end
+  
   def self.default_page_size
     25
   end
index 4f0dc4a..3740a9f 100644 (file)
@@ -83,6 +83,10 @@ class GroundPicture < ActiveRecord::Base
     {:src => self.picture.url, :width => tw, :height => th, :alt => self.caption}
   end
   
+  def symbol_option
+    self.tmb_opt_img_tag
+  end
+  
   def boost
   end
   
index ab72aab..f98d601 100644 (file)
@@ -24,6 +24,10 @@ class License < ActiveRecord::Base
   def overwrite
   end
   
+  def caption_with_group
+    self.license_group.caption + '/' + self.caption
+  end
+  
   def self.list
     opt = {}
     opt.merge!(License.list_opt)
index 28bf7b6..db52744 100644 (file)
@@ -52,6 +52,14 @@ class OriginalPicture < ActiveRecord::Base
     {:src => self.url, :width => tw, :height => th}
   end
   
+  def symbol_option
+    self.tmb_opt_img_tag
+  end
+  
+  def revision
+    self.history.first.revision
+  end
+  
   def unpublished?
     self.published_at == nil and self.stopped_at == nil
   end
index 32468bc..de574a7 100644 (file)
@@ -118,6 +118,10 @@ class PanelPicture < ActiveRecord::Base
     {:src => self.url, :width => tw, :height => th, :alt => self.caption}
   end
   
+  def symbol_option
+    self.picture.symbol_option
+  end
+  
   def boost
   end
   
index 46a0de4..f0cc995 100644 (file)
@@ -89,6 +89,10 @@ class Picture < ActiveRecord::Base
     {:src => img, :width => tw, :height => th}
   end
   
+  def symbol_option
+    self.tmb_opt_img_tag
+  end
+  
   def new_revision
     Picture.maximum(:revision, :conditions => ['original_picture_id = ?', self.original_picture_id]).to_i + 1
   end
index 30eb7e6..992be9f 100644 (file)
@@ -87,6 +87,10 @@ class ResourcePicture < ActiveRecord::Base
     {:src => self.url('full'), :width => self.width, :height => self.height}
   end
   
+  def symbol_option
+    self.tmb_opt_img_tag
+  end
+  
   def self.default_page_size
     25
   end
index 73409de..b51aff3 100644 (file)
@@ -41,6 +41,10 @@ class Scroll < ActiveRecord::Base
     self.visible > 0
   end
   
+  def scroll_panels_count
+    ScrollPanel.where(['scroll_panels.scroll_id = ?', self.id]).count
+  end
+  
   def self.default_page_size
     25
   end
index b24e920..c891593 100644 (file)
@@ -69,6 +69,9 @@ class Sheet < ActiveRecord::Base
     visible? au
   end
   
+  def symbol_filename
+  end
+  
   def tag_id
     'sheet' + self.tag_sheet_id
   end
index 3622ff9..2b33f65 100644 (file)
@@ -51,6 +51,10 @@ class Speech < ActiveRecord::Base
     self.speech_balloon.panel.visible? roles
   end
   
+  def symbol_option
+    self.get_parent.speech_balloon_template.symbol_option
+  end
+  
   def get_parent
     self.speech_balloon || @new_parent
   end
@@ -84,16 +88,20 @@ class Speech < ActiveRecord::Base
     page_size
   end
   
+  def self.list_where
+    'panels.publish > 0'
+  end
+  
   def self.list page = 1, page_size = self.default_page_size
-    opt = {}
-    opt.merge!(Speech.list_opt)
-    opt.merge!({:limit => page_size, :offset => (page -1) * page_size}) if page_size > 0
-    opt.merge!({:conditions => 'panels.publish > 0', :order => 'speeches.updated_at desc'})
-    Speech.find(:all, opt)
+    Speech.where(self.list_where()).includes(Speech.list_opt).order('speeches.updated_at desc').offset((page -1) * page_size).limit(page_size)
+  end
+  
+  def self.list_paginate page = 1, page_size = self.default_page_size
+    Kaminari.paginate_array(Array.new(Speech.where(self.list_where()).includes(Speech.list_opt).count, nil)).page(page).per(page_size)
   end
   
   def self.list_opt
-    {:include => {:speech_balloon => {:panel => {:author => {}}, :balloon => {}, :speech_balloon_template => {}} }}
+    {:speech_balloon => {:panel => {:author => {}}, :balloon => {}, :speech_balloon_template => {}} }
   end
   
   def self.list_json_opt
index 8aabc7a..8c6423f 100644 (file)
@@ -72,6 +72,10 @@ class SpeechBalloon < ActiveRecord::Base
     self.panel.visible? roles
   end
   
+  def symbol_option
+    self.speech_balloon_template.symbol_option
+  end
+  
   def new_balloon
     @new_balloon
   end
index 62b5c5f..a6c6f75 100644 (file)
@@ -30,6 +30,10 @@ class SpeechBalloonTemplate < ActiveRecord::Base
     true
   end
   
+  def symbol_option
+    self.system_picture.tmb_opt_img_tag
+  end
+  
   def self.list
     opt = {}
     opt.merge!(self.list_opt)
index 7fadd62..804c586 100644 (file)
@@ -46,6 +46,18 @@ class Story < ActiveRecord::Base
     self.t + 1
   end
   
+  def disp_t_by_text
+    I18n.t('stories.show.t', :t => self.disp_t)
+  end
+  
+  def title_with_t
+    self.disp_t_by_text  + ':' + self.title
+  end
+  
+  def story_sheets_count
+    StorySheet.where(['story_sheets.story_id = ?', self.id]).count
+  end
+  
   def self.default_page_size
     25
   end
index 50e6ec3..1d090bc 100644 (file)
@@ -53,6 +53,10 @@ class SystemPicture < ActiveRecord::Base
     {:src => self.url, :width => tw, :height => th}
   end
   
+  def symbol_option
+    self.tmb_opt_img_tag
+  end
+  
   def self.default_page_size
     25
   end
@@ -74,12 +78,16 @@ class SystemPicture < ActiveRecord::Base
     page_size
   end
   
+  def self.list_where
+    nil
+  end
+  
   def self.list page = 1, page_size = self.default_page_size
-    opt = {}
-    opt.merge!(self.list_opt)
-    opt.merge!({:limit => page_size, :offset => (page -1) * page_size}) if page_size > 0
-    opt.merge!({:order => 'system_pictures.updated_at desc'})
-    SystemPicture.find(:all, opt)
+    SystemPicture.where(self.list_where()).includes(SystemPicture.list_opt).order('system_pictures.updated_at desc').offset((page -1) * page_size).limit(page_size)
+  end
+  
+  def self.list_paginate page = 1, page_size = self.default_page_size
+    Kaminari.paginate_array(Array.new(SystemPicture.where(self.list_where()).count, nil)).page(page).per(page_size)
   end
   
   def self.list_opt
diff --git a/app/views/artists/_summary.html.erb b/app/views/artists/_summary.html.erb
new file mode 100644 (file)
index 0000000..f9175d4
--- /dev/null
@@ -0,0 +1,4 @@
+<div>
+  P.
+  <%= item.resource_pictures.size %>
+</div>
diff --git a/app/views/authors/_summary.html.erb b/app/views/authors/_summary.html.erb
new file mode 100644 (file)
index 0000000..dc1e39f
--- /dev/null
@@ -0,0 +1,10 @@
+<div>
+  C.
+  <%= link_to item.comics.size, comics_author_path(item)  %>
+  S.
+  <%= link_to item.scrolls.size, scrolls_author_path(item) %>
+  S.
+  <%= link_to item.stories.size, stories_author_path(item) %>
+  P.
+  <%= link_to item.panels.size, panels_author_path(item) %>
+</div>
diff --git a/app/views/balloons/_summary.html.erb b/app/views/balloons/_summary.html.erb
new file mode 100644 (file)
index 0000000..92be2ad
--- /dev/null
@@ -0,0 +1,4 @@
+<div>
+  <%= link_to panel_icon(:object => item, :size => 32), panel_path(item.get_parent.get_panel) %>
+  <%= link_to h(truncate(item.get_parent.get_panel.author.name, :length => 12)), author_path(item.get_parent.get_panel.author) %>
+</div>
diff --git a/app/views/ground_colors/_summary.html.erb b/app/views/ground_colors/_summary.html.erb
new file mode 100644 (file)
index 0000000..a5c4b17
--- /dev/null
@@ -0,0 +1,4 @@
+<div>
+  <%= link_to panel_icon(:object => item, :size => 32), panel_path(item.panel) %>
+  <%= link_to h(truncate(item.panel.author.name, :length => 12)), author_path(item.panel.author) %>
+</div>
diff --git a/app/views/ground_colors/_symbol.html.erb b/app/views/ground_colors/_symbol.html.erb
new file mode 100644 (file)
index 0000000..20c1b89
--- /dev/null
@@ -0,0 +1,3 @@
+<div style="width: 64px;height: 64px;color: #<%= format("%06x", item.code ^ 0xffffff) -%>; background-color: #<%= format("%06x", item.code) -%>;">
+  <%= link_to format("%06x", item.code ^ 0xffffff), item %>
+</div>
diff --git a/app/views/ground_pictures/_summary.html.erb b/app/views/ground_pictures/_summary.html.erb
new file mode 100644 (file)
index 0000000..3dfc680
--- /dev/null
@@ -0,0 +1,10 @@
+<div class="ground_picture-summary">
+  <div>
+    <%= render item.picture.credit_template, :picture => item.picture %>
+  </div>
+  <div>
+    <%= link_to panel_icon(:object => item, :size => 32), panel_path(item.panel) %>
+  </div>
+</div>
+<div class="row_break">
+</div>
diff --git a/app/views/license_groups/_summary.html.erb b/app/views/license_groups/_summary.html.erb
new file mode 100644 (file)
index 0000000..d58db9e
--- /dev/null
@@ -0,0 +1,2 @@
+<div>
+</div>
diff --git a/app/views/licenses/_summary.html.erb b/app/views/licenses/_summary.html.erb
new file mode 100644 (file)
index 0000000..de53f88
--- /dev/null
@@ -0,0 +1,6 @@
+<div>
+  <%= link_to h(item.license_group.caption), license_group_path(item.license_group) %>
+</div>
+<div>
+  <%= link_to tag(:img, :src => item.system_picture.url), item.url %>
+</div>
diff --git a/app/views/original_pictures/_publish.html.erb b/app/views/original_pictures/_publish.html.erb
new file mode 100644 (file)
index 0000000..a523ad3
--- /dev/null
@@ -0,0 +1,8 @@
+<div>
+  <% if item.resource_picture %>
+    <%= link_to t('original_pictures.index.stop'), item.resource_picture, confirm: 'Are you sure?', method: :delete %>
+  <% else %>
+  <% end %>
+  <%= link_to tag(:img, :src => asset_path('edit.png'), :width => 32, :height => 32), edit_original_picture_path(item) %>
+  <%= link_to tag(:img, :src => asset_path('remove.png'), :width => 32, :height => 32), item, confirm: 'Are you sure?', :method => :delete %>
+</div>
diff --git a/app/views/original_pictures/_summary.html.erb b/app/views/original_pictures/_summary.html.erb
new file mode 100644 (file)
index 0000000..8ce850c
--- /dev/null
@@ -0,0 +1,23 @@
+<div class="original_picture-summary">
+  <div>
+    <% case true %>
+    <% when item.unpublished? %>
+      <%= t('original_pictures.unpublished') %>
+    <% when item.unlicensed? %>
+      <%= t('original_pictures.unlicensed') %>
+    <% when item.stopped? %>
+      <%= t('original_pictures.stopped') %>
+    <% when item.published? %>
+      <%= t('original_pictures.published') %>
+    <% end %>
+  </div>
+  <% if item.resource_picture %>
+    <div>
+      <%= link_to tag(:img, item.resource_picture.tmb_opt_img_tag), item.resource_picture %>
+    </div>
+    <div>
+      <%= render item.resource_picture.credit_template, :picture => item.resource_picture %>
+    </div>
+  <% else %>
+  <% end %>
+</div>
diff --git a/app/views/panel_pictures/_summary.html.erb b/app/views/panel_pictures/_summary.html.erb
new file mode 100644 (file)
index 0000000..9816479
--- /dev/null
@@ -0,0 +1,10 @@
+<div class="panel_picture-summary">
+  <div>
+    <%= render item.picture.credit_template, :picture => item.picture %>
+  </div>
+  <div>
+    <%= link_to panel_icon(:object => item, :size => 32), panel_path(item.panel) %>
+  </div>
+</div>
+<div class="row_break">
+</div>
diff --git a/app/views/panels/_summary.html.erb b/app/views/panels/_summary.html.erb
new file mode 100644 (file)
index 0000000..bab55d7
--- /dev/null
@@ -0,0 +1,6 @@
+<div>
+  <%= t_selected_item('panel_visible_items', item.publish) %>
+</div>
+<div>
+  <%= link_to h(truncate(item.author.name, :length => 12)), author_path(item.author) %>
+</div>
diff --git a/app/views/resource_pictures/_summary.html.erb b/app/views/resource_pictures/_summary.html.erb
new file mode 100644 (file)
index 0000000..fcc9da7
--- /dev/null
@@ -0,0 +1,4 @@
+<div>
+  <%= link_to h(truncate(item.artist.name, :length => 12)), artist_path(item.artist) %>
+  <%= render item.credit_template, :picture => item %>
+</div>
diff --git a/app/views/scroll_panels/_summary.html.erb b/app/views/scroll_panels/_summary.html.erb
new file mode 100644 (file)
index 0000000..7347a12
--- /dev/null
@@ -0,0 +1,9 @@
+<div>
+  <%= link_to scroll_icon(:object => item.scroll, :size => 32), scroll_path(item.scroll) %>
+  <% if item.panel %>
+    <%= link_to panel_icon(:object => item.panel, :size => 32), panel_path(item.panel) %>
+  <% end %>
+</div>
+<div>
+  <%= link_to h(truncate(item.author.name, :length => 12)), author_path(item.author) %>
+</div>
diff --git a/app/views/scrolls/_summary.html.erb b/app/views/scrolls/_summary.html.erb
new file mode 100644 (file)
index 0000000..38b81b3
--- /dev/null
@@ -0,0 +1,7 @@
+<div>
+  <%= t_selected_item('scroll_visible_items', item.visible) %>
+  <%= t('scrolls.scroll_panels_count', :c => item.scroll_panels_count) %>
+</div>
+<div>
+  <%= link_to h(truncate(item.author.name, :length => 12)), author_path(item.author) %>
+</div>
diff --git a/app/views/sheet_panels/_summary.html.erb b/app/views/sheet_panels/_summary.html.erb
new file mode 100644 (file)
index 0000000..c8e9a25
--- /dev/null
@@ -0,0 +1,9 @@
+<div>
+  <%= link_to sheet_icon(:object => item.sheet, :size => 32), sheet_path(item.sheet) %>
+  <% if item.panel %>
+    <%= link_to panel_icon(:object => item.panel, :size => 32), panel_path(item.panel) %>
+  <% end %>
+</div>
+<div>
+  <%= link_to h(truncate(item.author.name, :length => 12)), author_path(item.author) %>
+</div>
diff --git a/app/views/sheets/_summary.html.erb b/app/views/sheets/_summary.html.erb
new file mode 100644 (file)
index 0000000..635dea8
--- /dev/null
@@ -0,0 +1,6 @@
+<div>
+  <%= t_selected_item('sheet_visible_items', item.visible) %>
+</div>
+<div>
+  <%= link_to h(truncate(item.author.name, :length => 12)), author_path(item.author) %>
+</div>
diff --git a/app/views/speech_balloon_templates/_summary.html.erb b/app/views/speech_balloon_templates/_summary.html.erb
new file mode 100644 (file)
index 0000000..d300ee6
--- /dev/null
@@ -0,0 +1,3 @@
+<div>
+  <%= link_to h(truncate(item.author.name, :length => 12)), author_path(item.author) %>
+</div>
diff --git a/app/views/speech_balloons/_summary.html.erb b/app/views/speech_balloons/_summary.html.erb
new file mode 100644 (file)
index 0000000..43a78d1
--- /dev/null
@@ -0,0 +1,3 @@
+<div>
+  <%= link_to panel_icon(:object => item, :size => 32), panel_path(item.panel) %>
+</div>
diff --git a/app/views/speeches/_summary.html.erb b/app/views/speeches/_summary.html.erb
new file mode 100644 (file)
index 0000000..92be2ad
--- /dev/null
@@ -0,0 +1,4 @@
+<div>
+  <%= link_to panel_icon(:object => item, :size => 32), panel_path(item.get_parent.get_panel) %>
+  <%= link_to h(truncate(item.get_parent.get_panel.author.name, :length => 12)), author_path(item.get_parent.get_panel.author) %>
+</div>
diff --git a/app/views/stories/_summary.html.erb b/app/views/stories/_summary.html.erb
new file mode 100644 (file)
index 0000000..9d05abc
--- /dev/null
@@ -0,0 +1,8 @@
+<div>
+  <%= t_selected_item('story_visible_items', item.visible) %>
+  <%= t('stories.story_sheets_count', :c => item.story_sheets_count) %>
+  <%= link_to h(item.comic.title), comic_path(item.comic) %>
+</div>
+<div>
+  <%= link_to h(truncate(item.comic.author.name, :length => 12)), author_path(item.comic.author) %>
+</div>
diff --git a/app/views/story_sheets/_summary.html.erb b/app/views/story_sheets/_summary.html.erb
new file mode 100644 (file)
index 0000000..c3c9cd7
--- /dev/null
@@ -0,0 +1,9 @@
+<div>
+  <%= link_to story_icon(:object => item.story, :size => 32), story_path(item.story) %>
+  <% if item.sheet %>
+    <%= link_to sheet_icon(:object => item.sheet, :size => 32), sheet_path(item.sheet) %>
+  <% end %>
+</div>
+<div>
+  <%= link_to h(truncate(item.author.name, :length => 12)), author_path(item.author) %>
+</div>
diff --git a/app/views/system/filer.html.erb b/app/views/system/filer.html.erb
new file mode 100644 (file)
index 0000000..a29d8a2
--- /dev/null
@@ -0,0 +1,147 @@
+<% model_name = model.to_s.underscore %>
+<% path_name = model.to_s.tableize %>
+<% filer_configurations = configurations['filers'][model.to_s.underscore] || {} %>
+<% symbol = filer_configurations['symbol'] || {} %>
+<% symbol_type = symbol['type'] || 'src' %>
+<% caption = filer_configurations['caption'] || {} %>
+<% caption_type = caption['type'] || 'column' %>
+<% summary = filer_configurations['summary'] || {} %>
+<% summary_type = summary['type'] || 'none' %>
+<% edit = filer_configurations['edit'] || {} %>
+<% edit_type = edit['type'] || 'default' %>
+<ul class="filer">
+  <li id="" class="filer-head filer-head-<%= model.to_s.underscore -%>">
+    <div id="" class="filer-head-symbol">
+      symbol
+    </div>
+    <% unless caption_type == 'none' %>
+      <div id="" class="filer-head-caption">
+        caption
+      </div>
+    <% end %>
+    <% unless summary_type == 'none' %>
+      <div id="" class="filer-head-summary">
+        summary
+      </div>
+    <% end %>
+    <div id="" class="filer-head-icon">
+      icon
+    </div>
+    <div id="" class="filer-head-date">
+      date
+    </div>
+    <% unless edit_type == 'none' %>
+      <div id="" class="filer-head-edit">
+        edit
+      </div>
+    <% end %>
+  </li>
+  <% items.each do |item| %>
+    <li id="" class="filer-item filer-item-<%= model.to_s.underscore -%>">
+      <div id="" class="filer-item-symbol">
+        <% link = symbol['link'] || {'type' => 'action', 'name' => 'show'} %>
+        <% path = case link['type'] %>
+        <% when 'action' %>
+          <% case link['name'] %>
+          <% when 'show' %>
+            <% polymorphic_path(item) %>
+          <% else %>
+            <% polymorphic_path(item, :action => link['name']) %>
+          <% end %>
+        <% when 'none' %>
+          <% '' %>
+        <% when 'url_column' %>
+          <% item.__send__(link['name']).to_s %>
+        <% else %>
+          <% '' %>
+        <% end %>
+        <% str = case symbol_type %>
+        <% when 'image' %>
+          <% tag(:img, :src => symbol['name'], :width => 64, :height => 64) %>
+        <% when 'picture' %>
+          <% tag(:img, item.__send__(symbol['name'])) %>
+        <% when 'template' %>
+          <%= render path_name + '/' + symbol['name'], :item => item %>
+          <% nil %>
+        <% else %>
+          <% 'no.png' %>
+        <% end %>
+        <% unless str.blank? %>
+          <%= link_to_unless path.blank?, str, path %>
+        <% end %>
+      </div>
+      <% unless caption_type == 'none' %>
+        <div id="" class="filer-item-caption">
+          <% link = caption['link'] || {'type' => 'action', 'name' => 'show'} %>
+          <% path = case link['type'] %>
+          <% when 'action' %>
+            <% case link['name'] %>
+            <% when 'show' %>
+              <% polymorphic_path(item) %>
+            <% else %>
+              <% polymorphic_path(item, :action => link['name']) %>
+            <% end %>
+          <% when 'none' %>
+            <% '' %>
+          <% when 'url_column' %>
+            <% item.__send__(link['name']).to_s %>
+          <% else %>
+            <% polymorphic_path(item) %>
+          <% end %>
+          <% str = case caption_type %>
+          <% when 'column' %>
+            <% item.attributes[caption['name']] %>
+          <% when 'method' %>
+            <% item.__send__(caption['name']).to_s %>
+          <% else %>
+            <% 'no caption' %>
+          <% end %>
+          <% str = 'no caption' if str.blank? %>
+          <% unless str.blank? %>
+            <%= link_to_unless path.blank?, str, path %>
+          <% end %>
+        </div>
+      <% end %>
+      <% unless summary_type == 'none' %>
+        <div id="" class="filer-item-summary">
+          <% case summary_type %>
+          <% when 'template' %>
+            <%= render path_name + '/' + summary['name'], :item => item %>
+          <% else %>
+            <% 'no config' %>
+          <% end %>
+        </div>
+      <% end %>
+      <div id="" class="filer-item-icon">
+        <%= link_to icon_tag(item.class.to_s, :object => item, :size => 64), polymorphic_path(item, :format => :prof) %>
+      </div>
+      <div id="" class="filer-item-date">
+        <%= distance_of_time_in_words_to_now item.updated_at %>
+      </div>
+      <% unless edit_type == 'none' %>
+        <div id="" class="filer-item-edit">
+          <% case edit_type %>
+          <% when 'default' %>
+            <% if item.own? roles %>
+              <%= link_to tag(:img, :src => asset_path('edit.png'), :width => 32, :height => 32), polymorphic_path(item, :action => :edit) %>
+              <%= link_to tag(:img, :src => asset_path('remove.png'), :width => 32, :height => 32), item, confirm: 'Are you sure?', :method => :delete %>
+            <% end %>
+          <% when 'account' %>
+            <% if item.own? roles %>
+              <%= link_to tag(:img, :src => asset_path('edit.png'), :width => 32, :height => 32), '/home/configure' %>
+            <% end %>
+         <% when 'template' %>
+            <%= render path_name + '/' + edit['name'], :item => item %>
+         <% else %>
+            <% 'no config' %>
+          <% end %>
+        </div>
+      <% end %>
+    </li>
+  <% end %>
+</ul>
+<div class="row_break">
+</div>
+<% if pager %>
+  <%= paginate(pager) %>
+<% end %>
diff --git a/app/views/system_pictures/_summary.html.erb b/app/views/system_pictures/_summary.html.erb
new file mode 100644 (file)
index 0000000..d300ee6
--- /dev/null
@@ -0,0 +1,3 @@
+<div>
+  <%= link_to h(truncate(item.author.name, :length => 12)), author_path(item.author) %>
+</div>
index 9fc3344..82c0d52 100644 (file)
@@ -534,6 +534,7 @@ ja:
     system_resources: システムリソースから
     return: シンプル版に戻る
   scrolls:
+    scroll_panels_count: '%{c}コマ'
     index:
       title: スクロール一覧
       new: 新刊
@@ -583,6 +584,7 @@ ja:
       new_scrolls: 最近作成したスクロール
       fresh_scrolls: 最近更新したスクロール
   comics:
+    comic_stories_count: '%{c}話'
     index:
       title: コミック一覧
       new: 新刊
@@ -603,6 +605,7 @@ ja:
     browse:
       title: コミック 生単票
   stories:
+    story_sheets_count: '%{c}P'
     index:
       title: ストーリー一覧
       new: 新ストーリー