disclaimer 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- data/README.rdoc +11 -0
- data/app/assets/javascripts/disclaimer/application.js +0 -3
- data/app/models/disclaimer/document.rb +2 -1
- data/app/views/disclaimer/documents/show.html.erb +0 -1
- data/lib/disclaimer/version.rb +1 -1
- data/test/dummy/db/development.sqlite3 +0 -0
- data/test/dummy/db/test.sqlite3 +0 -0
- data/test/dummy/log/development.log +996 -0
- data/test/dummy/log/test.log +806 -0
- data/test/dummy/tmp/cache/assets/D73/200/sprockets%2Ff550d44b0e67ff62964de563da84c2ab +0 -0
- data/test/dummy/tmp/cache/assets/DD1/600/sprockets%2Fd61c971a175fe64d20ceefe3e7f4e2b3 +0 -0
- data/test/dummy/tmp/cache/assets/DDD/C60/sprockets%2F59ec92d2bcdf9ece368f07a4ca6509c7 +0 -0
- metadata +2 -34
data/README.rdoc
CHANGED
@@ -87,6 +87,17 @@ Segments at /disclaimer/segments. If you wish to modify the controller behaviour
|
|
87
87
|
to the same location in your application, and modify these copies. The versions
|
88
88
|
in your application will take precedence over those in disclaimer.
|
89
89
|
|
90
|
+
== Managing views
|
91
|
+
|
92
|
+
The default views are simple, and you will probably want to modify them.
|
93
|
+
To do this create disclaimer view files in your host app. These will take
|
94
|
+
precedence over the versions located in the gem.
|
95
|
+
|
96
|
+
To create your own disclaimer page, create a new show file within your host
|
97
|
+
rails app. For example:
|
98
|
+
|
99
|
+
/app/views/disclaimer/documents/show.html.erb
|
100
|
+
|
90
101
|
== Into production
|
91
102
|
|
92
103
|
I would recommend using seeding to generate your initial disclaimer documents,
|
@@ -1,11 +1,12 @@
|
|
1
1
|
module Disclaimer
|
2
2
|
class Document < ActiveRecord::Base
|
3
|
-
attr_accessible :footer, :header, :title, :name, :segments
|
3
|
+
attr_accessible :footer, :header, :title, :name, :segments, :segment_ids
|
4
4
|
|
5
5
|
before_save :underscore_name
|
6
6
|
|
7
7
|
has_many :segment_holders, :uniq => true
|
8
8
|
has_many :segments, :through => :segment_holders, :uniq => true
|
9
|
+
accepts_nested_attributes_for :segments
|
9
10
|
|
10
11
|
validates :name, :presence => true
|
11
12
|
|
data/lib/disclaimer/version.rb
CHANGED
Binary file
|
data/test/dummy/db/test.sqlite3
CHANGED
Binary file
|