appdoc 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- data/app/views/documents/_documents.html.haml +2 -1
- data/app/views/documents/_form.html.haml +1 -19
- data/app/views/documents/_index_aside.html.haml +8 -2
- data/app/views/documents/index.html.haml +6 -0
- data/app/views/documents/show.html.haml +11 -1
- data/lib/appdoc.rb +0 -1
- data/lib/appdoc/version.rb +1 -1
- data/lib/generators/appdoc/appdoc_generator.rb +0 -5
- data/lib/generators/appdoc/templates/migration.rb +1 -1
- metadata +27 -16
@@ -1,21 +1,3 @@
|
|
1
|
-
-content_for(:head) do
|
2
|
-
=javascript_include_tag('jquery-ui')
|
3
|
-
=javascript_include_tag('SmartTextBox')
|
4
|
-
=stylesheet_link_tag('jquery/smart_text_box/SmartTextBox')
|
5
|
-
:javascript
|
6
|
-
$(document).ready(function() {
|
7
|
-
// Tagging
|
8
|
-
$('#document_tag_list').smartTextBox({
|
9
|
-
submitChars: [#{Appdoc.delimiter.to_json}],
|
10
|
-
separator: ", ",
|
11
|
-
autocompleteValues: #{Appdoc.autocompleteValues.to_json},
|
12
|
-
minSearchLength: #{Appdoc.minSearchLength},
|
13
|
-
placeholder: #{Appdoc.placeholder.to_json}
|
14
|
-
});
|
15
|
-
});
|
16
|
-
|
17
|
-
=render('shared/wysiwyg')
|
18
|
-
|
19
1
|
=form_for(@document) do |f|
|
20
2
|
%dl
|
21
3
|
%dt.name=f.label :name
|
@@ -24,7 +6,7 @@
|
|
24
6
|
%dd.slug=f.text_field :slug
|
25
7
|
%dt.tags=f.label :tag_list, 'Tags'
|
26
8
|
%dd.tags
|
27
|
-
=f.text_field :tag_list
|
9
|
+
=f.text_field :tag_list
|
28
10
|
%span.help_text Lower case and separated by spaces
|
29
11
|
%dt.content=f.label :content
|
30
12
|
%dd.content=f.text_area :content
|
@@ -1,5 +1,11 @@
|
|
1
1
|
-content_for(:aside) do
|
2
|
-
-if
|
2
|
+
-if respond_to? :permitted_to?
|
3
|
+
-if permitted_to? :create, :documents
|
4
|
+
%h2 Actions
|
5
|
+
.box
|
6
|
+
%h3.add= link_to('New document', new_document_path)
|
7
|
+
|
8
|
+
-else
|
3
9
|
%h2 Actions
|
4
10
|
.box
|
5
|
-
%h3.add
|
11
|
+
%h3.add=link_to('New document', new_document_path)
|
@@ -10,3 +10,9 @@
|
|
10
10
|
!=render('documents', :documents => @documents)
|
11
11
|
|
12
12
|
!=render('index_aside')
|
13
|
+
|
14
|
+
-if respond_to? :permitted_to?
|
15
|
+
-if permitted_to? :create, :documents
|
16
|
+
=link_to('New document', new_document_path, :id=>'new_document_link')
|
17
|
+
-else
|
18
|
+
=link_to('New document', new_document_path, :id=>'new_document_link')
|
@@ -5,4 +5,14 @@
|
|
5
5
|
%ul.tags
|
6
6
|
-@document.tags.each do |tag|
|
7
7
|
%li!=link_to(tag, {:controller=>'documents', :tag=>tag.to_s})
|
8
|
-
|
8
|
+
|
9
|
+
-#!=action_links @document
|
10
|
+
|
11
|
+
-if respond_to? :permitted_to?
|
12
|
+
-if permitted_to? :edit, :documents
|
13
|
+
= link_to 'Edit', edit_document_path(@document)
|
14
|
+
-if permitted_to? :destroy, :documents
|
15
|
+
= link_to 'Destroy', @document, :confirm => 'Are you sure?', :method => :delete
|
16
|
+
-else
|
17
|
+
= link_to 'Edit', edit_document_path(@document)
|
18
|
+
= link_to 'Destroy', @document, :confirm => 'Are you sure?', :method => :delete
|
data/lib/appdoc.rb
CHANGED
data/lib/appdoc/version.rb
CHANGED
@@ -23,9 +23,4 @@ class AppdocGenerator < Rails::Generators::Base
|
|
23
23
|
template 'appdoc_config.rb', 'config/initializers/appdoc_config.rb'
|
24
24
|
end
|
25
25
|
|
26
|
-
def copy_related_files
|
27
|
-
copy_file 'public/stylesheets/jquery/smart_text_box/SmartTextBox.css', 'public/stylesheets/jquery/smart_text_box/SmartTextBox.css'
|
28
|
-
copy_file 'public/stylesheets/jquery/smart_text_box/imgs/close.gif', 'public/stylesheets/jquery/smart_text_box/imgs/close.gif'
|
29
|
-
copy_file 'public/javascripts/SmartTextBox.js', 'public/javascripts/SmartTextBox.js'
|
30
|
-
end
|
31
26
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: appdoc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,11 +9,11 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2011-09-
|
12
|
+
date: 2011-09-24 00:00:00.000000000Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: acts-as-taggable-on
|
16
|
-
requirement: &
|
16
|
+
requirement: &88628470 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ! '>='
|
@@ -21,10 +21,10 @@ dependencies:
|
|
21
21
|
version: 2.0.0
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *88628470
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
26
|
name: haml
|
27
|
-
requirement: &
|
27
|
+
requirement: &88628070 !ruby/object:Gem::Requirement
|
28
28
|
none: false
|
29
29
|
requirements:
|
30
30
|
- - ! '>='
|
@@ -32,10 +32,10 @@ dependencies:
|
|
32
32
|
version: 3.0.0
|
33
33
|
type: :runtime
|
34
34
|
prerelease: false
|
35
|
-
version_requirements: *
|
35
|
+
version_requirements: *88628070
|
36
36
|
- !ruby/object:Gem::Dependency
|
37
37
|
name: kaminari
|
38
|
-
requirement: &
|
38
|
+
requirement: &88624020 !ruby/object:Gem::Requirement
|
39
39
|
none: false
|
40
40
|
requirements:
|
41
41
|
- - ! '>='
|
@@ -43,7 +43,18 @@ dependencies:
|
|
43
43
|
version: 0.10.0
|
44
44
|
type: :runtime
|
45
45
|
prerelease: false
|
46
|
-
version_requirements: *
|
46
|
+
version_requirements: *88624020
|
47
|
+
- !ruby/object:Gem::Dependency
|
48
|
+
name: meta_search
|
49
|
+
requirement: &88623710 !ruby/object:Gem::Requirement
|
50
|
+
none: false
|
51
|
+
requirements:
|
52
|
+
- - ! '>='
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: 1.0.0
|
55
|
+
type: :runtime
|
56
|
+
prerelease: false
|
57
|
+
version_requirements: *88623710
|
47
58
|
description: Allows you to add documents and documentation to your app
|
48
59
|
email:
|
49
60
|
- ryan.e.hall@biola.edu
|
@@ -52,23 +63,23 @@ extensions: []
|
|
52
63
|
extra_rdoc_files: []
|
53
64
|
files:
|
54
65
|
- app/models/document.rb
|
55
|
-
- app/views/documents/show.html.haml
|
56
66
|
- app/views/documents/new.html.haml
|
67
|
+
- app/views/documents/edit.html.haml
|
68
|
+
- app/views/documents/show.html.haml
|
69
|
+
- app/views/documents/index.html.haml
|
57
70
|
- app/views/documents/_documents.html.haml
|
58
71
|
- app/views/documents/_form.html.haml
|
59
|
-
- app/views/documents/index.html.haml
|
60
72
|
- app/views/documents/_index_aside.html.haml
|
61
|
-
- app/views/documents/edit.html.haml
|
62
73
|
- app/controllers/documents_controller.rb
|
63
|
-
- lib/
|
74
|
+
- lib/appdoc/version.rb
|
75
|
+
- lib/appdoc/engine.rb
|
76
|
+
- lib/generators/appdoc/appdoc_generator.rb
|
64
77
|
- lib/generators/appdoc/templates/public/stylesheets/jquery/smart_text_box/imgs/close.gif
|
65
78
|
- lib/generators/appdoc/templates/public/stylesheets/jquery/smart_text_box/SmartTextBox.css
|
79
|
+
- lib/generators/appdoc/templates/public/javascripts/SmartTextBox.js
|
66
80
|
- lib/generators/appdoc/templates/migration.rb
|
67
81
|
- lib/generators/appdoc/templates/appdoc_config.rb
|
68
|
-
- lib/generators/appdoc/appdoc_generator.rb
|
69
82
|
- lib/appdoc.rb
|
70
|
-
- lib/appdoc/version.rb
|
71
|
-
- lib/appdoc/engine.rb
|
72
83
|
- config/routes.rb
|
73
84
|
homepage: https://github.com/biola/appdoc
|
74
85
|
licenses: []
|
@@ -90,7 +101,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
90
101
|
version: '0'
|
91
102
|
requirements: []
|
92
103
|
rubyforge_project: appdoc
|
93
|
-
rubygems_version: 1.8.
|
104
|
+
rubygems_version: 1.8.10
|
94
105
|
signing_key:
|
95
106
|
specification_version: 3
|
96
107
|
summary: Documentation for your app
|