ohlala_rails_scaffold_templates 0.0.3 → 0.0.4

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,43 @@
1
+ == Ohlala Rails Scaffold Templates
2
+
3
+ These templates were created to fit our custom CMS at {Ohlàlà! Webdesigns}[link:files/actionpack/README_rdoc.html] and are therefore ridiculously opinionated.
4
+
5
+ There are meant to be used with Rails 3.0 or later and a number of specific gems.
6
+
7
+ Its philosophy is that it's easier and faster to remove code than it is to add it and therefore the templates generate by default the code for pagination, url slugs, Globalize3 translation, and other features which one might not need for a specific scaffold.
8
+
9
+ You can fork this gem at github.com to customize the templates to fit your own projects.
10
+
11
+ This gem can also be used to locate the right directories under which the templates should be placed.
12
+
13
+
14
+ == Getting Started
15
+
16
+ 1. Install the gem by adding the following line to your Gemfile:
17
+
18
+ gem "ohlala_rails_scaffold_templates", :group => :development
19
+
20
+ 2. Generate the templates which will be used by Rails scaffold generator:
21
+
22
+ rails g ohlala_templates
23
+
24
+ 3. You can now create customized scaffolds:
25
+
26
+ rails g scaffold resource_name
27
+
28
+
29
+ == Problems
30
+
31
+ Please use the github issues tab to submit
32
+
33
+ * Bug reports.
34
+ * Improvement suggesitions.
35
+
36
+
37
+ == Contributing
38
+
39
+ We encourage you to contribute to this gem by forking it and submitting pull requests.
40
+
41
+ == License
42
+
43
+ Ohlala Rails Scaffold Templates is released under the MIT license.
@@ -6,6 +6,8 @@
6
6
  <%%= raw @<%= singular_table_name %>.body_or_main_text_field %>
7
7
 
8
8
  <%% if current_user && current_user.admin? %>
9
- <hr>
10
- <p><nobr><%%= link_to 'Edit this <%= singular_table_name %>', edit_<%= singular_table_name %>_path(@<%= singular_table_name %>), :class => 'css3b-left pill button' %><%%= link_to 'List all <%= plural_table_name %>', <%= plural_table_name %>_path, :class => 'css3b-right pill button' %></nobr></p>
9
+ <%%= content_for :admin_sidebar do %>
10
+ <p><nobr><%%= link_to 'Edit this <%= singular_table_name %>', edit_<%= singular_table_name %>_path(@<%= singular_table_name %>), :class => 'css3b-left pill button' %><%%= link_to 'List all <%= plural_table_name %>', <%= plural_table_name %>_path, :class => 'css3b-right pill button' %></nobr></p>
11
+ <hr>
12
+ <%% end -%>
11
13
  <%% end %>
@@ -1,3 +1,3 @@
1
1
  module OhlalaRailsScaffoldTemplates
2
- VERSION = "0.0.3"
2
+ VERSION = "0.0.4"
3
3
  end
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: ohlala_rails_scaffold_templates
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.0.3
5
+ version: 0.0.4
6
6
  platform: ruby
7
7
  authors:
8
8
  - Swami Atma
@@ -10,7 +10,7 @@ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
12
 
13
- date: 2011-04-27 00:00:00 Z
13
+ date: 2011-05-13 00:00:00 Z
14
14
  dependencies: []
15
15
 
16
16
  description: "A ridiculously opinionated set of scaffold templates for Rails 3 and later. Meant to be used for the Ohl\xC3\xA0l\xC3\xA0! Webdesigns projects but can be customized to any Rails developer's workflow."
@@ -25,6 +25,7 @@ extra_rdoc_files: []
25
25
  files:
26
26
  - .gitignore
27
27
  - Gemfile
28
+ - README.rdoc
28
29
  - Rakefile
29
30
  - lib/generators/ohlala_templates/USAGE
30
31
  - lib/generators/ohlala_templates/ohlala_templates_generator.rb