beautiful_scaffold 0.3.5 → 2.0.0.pre

Sign up to get free protection for your applications and to get access to all the features.
Files changed (201) hide show
  1. checksums.yaml +7 -0
  2. data/.gitattributes +2 -0
  3. data/.gitignore +1 -0
  4. data/CHANGELOG +66 -1
  5. data/Gemfile +24 -17
  6. data/Gemfile.lock +209 -0
  7. data/README.rdoc +56 -44
  8. data/Rakefile +32 -0
  9. data/beautiful_scaffold.gemspec +8 -5
  10. data/lib/beautiful_scaffold/version.rb +3 -0
  11. data/lib/generators/beautiful_devisecancan_generator.rb +1 -1
  12. data/lib/generators/beautiful_jointable_generator.rb +40 -7
  13. data/lib/generators/beautiful_locale_generator.rb +102 -80
  14. data/lib/generators/beautiful_migration_generator.rb +12 -20
  15. data/lib/generators/beautiful_scaffold_common_methods.rb +88 -29
  16. data/lib/generators/beautiful_scaffold_generator.rb +166 -111
  17. data/lib/generators/templates/app/assets/javascripts/application-bs.js +11 -19
  18. data/lib/generators/templates/app/assets/javascripts/beautiful_scaffold.js +68 -78
  19. data/lib/generators/templates/app/assets/javascripts/bootstrap-datetimepicker-for-beautiful-scaffold.js +23 -42
  20. data/lib/generators/templates/app/assets/javascripts/fixed_menu.js +3 -1
  21. data/lib/generators/templates/app/assets/javascripts/jstree.min.js +6 -0
  22. data/lib/generators/templates/app/assets/stylesheets/application-bs.css +14 -12
  23. data/lib/generators/templates/app/assets/stylesheets/beautiful-scaffold.css.scss +36 -3
  24. data/lib/generators/templates/app/assets/stylesheets/themes/default-dark/32px.png +0 -0
  25. data/lib/generators/templates/app/assets/stylesheets/themes/default-dark/40px.png +0 -0
  26. data/lib/generators/templates/app/assets/stylesheets/themes/default-dark/style.scss +1146 -0
  27. data/lib/generators/templates/app/assets/stylesheets/themes/default-dark/throbber.gif +0 -0
  28. data/lib/generators/templates/app/assets/stylesheets/themes/default/32px.png +0 -0
  29. data/lib/generators/templates/app/assets/stylesheets/themes/default/40px.png +0 -0
  30. data/lib/generators/templates/app/assets/stylesheets/themes/default/style.scss +1102 -0
  31. data/lib/generators/templates/app/assets/stylesheets/themes/default/throbber.gif +0 -0
  32. data/lib/generators/templates/app/controllers/base.rb +32 -15
  33. data/lib/generators/templates/app/controllers/master_base.rb +55 -47
  34. data/lib/generators/templates/app/helpers/beautiful_helper.rb +104 -67
  35. data/lib/generators/templates/app/helpers/model_helper.rb +14 -3
  36. data/lib/generators/templates/app/initializers/link_renderer.rb +24 -17
  37. data/lib/generators/templates/app/initializers/ransack.rb +16 -0
  38. data/lib/generators/templates/app/locales/beautiful_scaffold.ja.yml +50 -0
  39. data/lib/generators/templates/app/models/concerns/fulltext_concern.rb +10 -10
  40. data/lib/generators/templates/app/views/_form.html.erb +5 -2
  41. data/lib/generators/templates/app/views/_form_habtm_tag.html.erb +6 -2
  42. data/lib/generators/templates/app/views/_mass_inserting.html.erb +40 -31
  43. data/lib/generators/templates/app/views/_modal_columns.html.erb +4 -4
  44. data/lib/generators/templates/app/views/edit.html.erb +1 -3
  45. data/lib/generators/templates/app/views/index.html.erb +84 -58
  46. data/lib/generators/templates/app/views/layout.html.erb +29 -47
  47. data/lib/generators/templates/app/views/new.html.erb +0 -2
  48. data/lib/generators/templates/app/views/partials/_forget_password.html.erb +2 -2
  49. data/lib/generators/templates/app/views/partials/_form_field.html.erb +7 -33
  50. data/lib/generators/templates/app/views/partials/_index_batch.html.erb +1 -1
  51. data/lib/generators/templates/app/views/partials/_index_column.html.erb +4 -6
  52. data/lib/generators/templates/app/views/partials/_index_header.html.erb +1 -1
  53. data/lib/generators/templates/app/views/partials/_index_search.html.erb +2 -4
  54. data/lib/generators/templates/app/views/partials/_index_search_default_fields.html.erb +1 -1
  55. data/lib/generators/templates/app/views/partials/_register_form.html.erb +2 -2
  56. data/lib/generators/templates/app/views/partials/_show_field.html.erb +3 -3
  57. data/lib/generators/templates/app/views/partials/_sign_in_form.html.erb +1 -1
  58. data/lib/generators/templates/app/views/partials/_sign_in_sign_out.html.erb +2 -2
  59. data/lib/generators/templates/app/views/show.html.erb +2 -2
  60. data/lib/generators/templates/app/views/treeview.html.erb +8 -5
  61. metadata +43 -188
  62. data/lib/generators/templates/app/assets/javascripts/bootstrap-datepicker.js +0 -834
  63. data/lib/generators/templates/app/assets/javascripts/bootstrap-timepicker.js +0 -797
  64. data/lib/generators/templates/app/assets/javascripts/jquery.jstree.js +0 -4551
  65. data/lib/generators/templates/app/assets/javascripts/jquery.livequery.js +0 -226
  66. data/lib/generators/templates/app/assets/stylesheets/bootstrap_and_overrides.css.less +0 -40
  67. data/lib/generators/templates/app/assets/stylesheets/datepicker.css +0 -224
  68. data/lib/generators/templates/app/assets/stylesheets/reset.css +0 -48
  69. data/lib/generators/templates/app/assets/stylesheets/themes/default/d.gif +0 -0
  70. data/lib/generators/templates/app/assets/stylesheets/themes/default/d.png +0 -0
  71. data/lib/generators/templates/app/assets/stylesheets/themes/default/style.css +0 -74
  72. data/lib/generators/templates/app/assets/stylesheets/timepicker.css +0 -89
  73. data/lib/generators/templates/markitup/jquery.markitup.js +0 -593
  74. data/lib/generators/templates/markitup/sets/bbcode/images/bold.png +0 -0
  75. data/lib/generators/templates/markitup/sets/bbcode/images/clean.png +0 -0
  76. data/lib/generators/templates/markitup/sets/bbcode/images/code.png +0 -0
  77. data/lib/generators/templates/markitup/sets/bbcode/images/fonts.png +0 -0
  78. data/lib/generators/templates/markitup/sets/bbcode/images/italic.png +0 -0
  79. data/lib/generators/templates/markitup/sets/bbcode/images/link.png +0 -0
  80. data/lib/generators/templates/markitup/sets/bbcode/images/list-bullet.png +0 -0
  81. data/lib/generators/templates/markitup/sets/bbcode/images/list-item.png +0 -0
  82. data/lib/generators/templates/markitup/sets/bbcode/images/list-numeric.png +0 -0
  83. data/lib/generators/templates/markitup/sets/bbcode/images/picture.png +0 -0
  84. data/lib/generators/templates/markitup/sets/bbcode/images/preview.png +0 -0
  85. data/lib/generators/templates/markitup/sets/bbcode/images/quotes.png +0 -0
  86. data/lib/generators/templates/markitup/sets/bbcode/images/stroke.png +0 -0
  87. data/lib/generators/templates/markitup/sets/bbcode/images/underline.png +0 -0
  88. data/lib/generators/templates/markitup/sets/bbcode/readme.txt +0 -11
  89. data/lib/generators/templates/markitup/sets/bbcode/set.js +0 -39
  90. data/lib/generators/templates/markitup/sets/bbcode/style.css +0 -47
  91. data/lib/generators/templates/markitup/sets/default/images/bold.png +0 -0
  92. data/lib/generators/templates/markitup/sets/default/images/clean.png +0 -0
  93. data/lib/generators/templates/markitup/sets/default/images/image.png +0 -0
  94. data/lib/generators/templates/markitup/sets/default/images/italic.png +0 -0
  95. data/lib/generators/templates/markitup/sets/default/images/link.png +0 -0
  96. data/lib/generators/templates/markitup/sets/default/images/list-bullet.png +0 -0
  97. data/lib/generators/templates/markitup/sets/default/images/list-numeric.png +0 -0
  98. data/lib/generators/templates/markitup/sets/default/images/picture.png +0 -0
  99. data/lib/generators/templates/markitup/sets/default/images/preview.png +0 -0
  100. data/lib/generators/templates/markitup/sets/default/images/stroke.png +0 -0
  101. data/lib/generators/templates/markitup/sets/default/set.js +0 -30
  102. data/lib/generators/templates/markitup/sets/default/style.css +0 -34
  103. data/lib/generators/templates/markitup/sets/html/images/bold.png +0 -0
  104. data/lib/generators/templates/markitup/sets/html/images/clean.png +0 -0
  105. data/lib/generators/templates/markitup/sets/html/images/h1.png +0 -0
  106. data/lib/generators/templates/markitup/sets/html/images/h2.png +0 -0
  107. data/lib/generators/templates/markitup/sets/html/images/h3.png +0 -0
  108. data/lib/generators/templates/markitup/sets/html/images/h4.png +0 -0
  109. data/lib/generators/templates/markitup/sets/html/images/h5.png +0 -0
  110. data/lib/generators/templates/markitup/sets/html/images/h6.png +0 -0
  111. data/lib/generators/templates/markitup/sets/html/images/image.png +0 -0
  112. data/lib/generators/templates/markitup/sets/html/images/italic.png +0 -0
  113. data/lib/generators/templates/markitup/sets/html/images/link.png +0 -0
  114. data/lib/generators/templates/markitup/sets/html/images/list-bullet.png +0 -0
  115. data/lib/generators/templates/markitup/sets/html/images/list-item.png +0 -0
  116. data/lib/generators/templates/markitup/sets/html/images/list-numeric.png +0 -0
  117. data/lib/generators/templates/markitup/sets/html/images/paragraph.png +0 -0
  118. data/lib/generators/templates/markitup/sets/html/images/picture.png +0 -0
  119. data/lib/generators/templates/markitup/sets/html/images/preview.png +0 -0
  120. data/lib/generators/templates/markitup/sets/html/images/stroke.png +0 -0
  121. data/lib/generators/templates/markitup/sets/html/readme.txt +0 -11
  122. data/lib/generators/templates/markitup/sets/html/set.js +0 -39
  123. data/lib/generators/templates/markitup/sets/html/style.css +0 -59
  124. data/lib/generators/templates/markitup/sets/markdown/images/bold.png +0 -0
  125. data/lib/generators/templates/markitup/sets/markdown/images/code.png +0 -0
  126. data/lib/generators/templates/markitup/sets/markdown/images/h1.png +0 -0
  127. data/lib/generators/templates/markitup/sets/markdown/images/h2.png +0 -0
  128. data/lib/generators/templates/markitup/sets/markdown/images/h3.png +0 -0
  129. data/lib/generators/templates/markitup/sets/markdown/images/h4.png +0 -0
  130. data/lib/generators/templates/markitup/sets/markdown/images/h5.png +0 -0
  131. data/lib/generators/templates/markitup/sets/markdown/images/h6.png +0 -0
  132. data/lib/generators/templates/markitup/sets/markdown/images/italic.png +0 -0
  133. data/lib/generators/templates/markitup/sets/markdown/images/link.png +0 -0
  134. data/lib/generators/templates/markitup/sets/markdown/images/list-bullet.png +0 -0
  135. data/lib/generators/templates/markitup/sets/markdown/images/list-numeric.png +0 -0
  136. data/lib/generators/templates/markitup/sets/markdown/images/picture.png +0 -0
  137. data/lib/generators/templates/markitup/sets/markdown/images/preview.png +0 -0
  138. data/lib/generators/templates/markitup/sets/markdown/images/quotes.png +0 -0
  139. data/lib/generators/templates/markitup/sets/markdown/readme.txt +0 -11
  140. data/lib/generators/templates/markitup/sets/markdown/set.js +0 -52
  141. data/lib/generators/templates/markitup/sets/markdown/style.css +0 -54
  142. data/lib/generators/templates/markitup/sets/textile/images/bold.png +0 -0
  143. data/lib/generators/templates/markitup/sets/textile/images/code.png +0 -0
  144. data/lib/generators/templates/markitup/sets/textile/images/h1.png +0 -0
  145. data/lib/generators/templates/markitup/sets/textile/images/h2.png +0 -0
  146. data/lib/generators/templates/markitup/sets/textile/images/h3.png +0 -0
  147. data/lib/generators/templates/markitup/sets/textile/images/h4.png +0 -0
  148. data/lib/generators/templates/markitup/sets/textile/images/h5.png +0 -0
  149. data/lib/generators/templates/markitup/sets/textile/images/h6.png +0 -0
  150. data/lib/generators/templates/markitup/sets/textile/images/italic.png +0 -0
  151. data/lib/generators/templates/markitup/sets/textile/images/link.png +0 -0
  152. data/lib/generators/templates/markitup/sets/textile/images/list-bullet.png +0 -0
  153. data/lib/generators/templates/markitup/sets/textile/images/list-numeric.png +0 -0
  154. data/lib/generators/templates/markitup/sets/textile/images/paragraph.png +0 -0
  155. data/lib/generators/templates/markitup/sets/textile/images/picture.png +0 -0
  156. data/lib/generators/templates/markitup/sets/textile/images/preview.png +0 -0
  157. data/lib/generators/templates/markitup/sets/textile/images/quotes.png +0 -0
  158. data/lib/generators/templates/markitup/sets/textile/images/stroke.png +0 -0
  159. data/lib/generators/templates/markitup/sets/textile/readme.txt +0 -11
  160. data/lib/generators/templates/markitup/sets/textile/set.js +0 -40
  161. data/lib/generators/templates/markitup/sets/textile/style.css +0 -60
  162. data/lib/generators/templates/markitup/sets/wiki/images/bold.png +0 -0
  163. data/lib/generators/templates/markitup/sets/wiki/images/code.png +0 -0
  164. data/lib/generators/templates/markitup/sets/wiki/images/h1.png +0 -0
  165. data/lib/generators/templates/markitup/sets/wiki/images/h2.png +0 -0
  166. data/lib/generators/templates/markitup/sets/wiki/images/h3.png +0 -0
  167. data/lib/generators/templates/markitup/sets/wiki/images/h4.png +0 -0
  168. data/lib/generators/templates/markitup/sets/wiki/images/h5.png +0 -0
  169. data/lib/generators/templates/markitup/sets/wiki/images/h6.png +0 -0
  170. data/lib/generators/templates/markitup/sets/wiki/images/italic.png +0 -0
  171. data/lib/generators/templates/markitup/sets/wiki/images/link.png +0 -0
  172. data/lib/generators/templates/markitup/sets/wiki/images/list-bullet.png +0 -0
  173. data/lib/generators/templates/markitup/sets/wiki/images/list-numeric.png +0 -0
  174. data/lib/generators/templates/markitup/sets/wiki/images/picture.png +0 -0
  175. data/lib/generators/templates/markitup/sets/wiki/images/preview.png +0 -0
  176. data/lib/generators/templates/markitup/sets/wiki/images/quotes.png +0 -0
  177. data/lib/generators/templates/markitup/sets/wiki/images/stroke.png +0 -0
  178. data/lib/generators/templates/markitup/sets/wiki/images/url.png +0 -0
  179. data/lib/generators/templates/markitup/sets/wiki/readme.txt +0 -11
  180. data/lib/generators/templates/markitup/sets/wiki/set.js +0 -37
  181. data/lib/generators/templates/markitup/sets/wiki/style.css +0 -57
  182. data/lib/generators/templates/markitup/skins/markitup/images/bg-container.png +0 -0
  183. data/lib/generators/templates/markitup/skins/markitup/images/bg-editor-bbcode.png +0 -0
  184. data/lib/generators/templates/markitup/skins/markitup/images/bg-editor-dotclear.png +0 -0
  185. data/lib/generators/templates/markitup/skins/markitup/images/bg-editor-html.png +0 -0
  186. data/lib/generators/templates/markitup/skins/markitup/images/bg-editor-json.png +0 -0
  187. data/lib/generators/templates/markitup/skins/markitup/images/bg-editor-markdown.png +0 -0
  188. data/lib/generators/templates/markitup/skins/markitup/images/bg-editor-textile.png +0 -0
  189. data/lib/generators/templates/markitup/skins/markitup/images/bg-editor-wiki.png +0 -0
  190. data/lib/generators/templates/markitup/skins/markitup/images/bg-editor-xml.png +0 -0
  191. data/lib/generators/templates/markitup/skins/markitup/images/bg-editor.png +0 -0
  192. data/lib/generators/templates/markitup/skins/markitup/images/handle.png +0 -0
  193. data/lib/generators/templates/markitup/skins/markitup/images/menu.png +0 -0
  194. data/lib/generators/templates/markitup/skins/markitup/images/submenu.png +0 -0
  195. data/lib/generators/templates/markitup/skins/markitup/style.css +0 -147
  196. data/lib/generators/templates/markitup/skins/simple/images/handle.png +0 -0
  197. data/lib/generators/templates/markitup/skins/simple/images/menu.png +0 -0
  198. data/lib/generators/templates/markitup/skins/simple/images/submenu.png +0 -0
  199. data/lib/generators/templates/markitup/skins/simple/style.css +0 -118
  200. data/lib/generators/templates/markitup/templates/preview.css +0 -5
  201. data/lib/generators/templates/markitup/templates/preview.html +0 -11
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: b5449d8a941dda266c1fd1277af6ab6ff75754c1393674443b4f94148881fe14
4
+ data.tar.gz: 687cbd191d192abc632c070476585be443dc85388640a54cf505524bcc19cb27
5
+ SHA512:
6
+ metadata.gz: cd6eb226ae5e30a72098b7992270bad5091e1abd9e444818f145bddff12a25f9619c51c19ea0ed9775e9d443cba75b2a3cd55154b26a4a44f7df349248742a69
7
+ data.tar.gz: b74ecf56db7af523a9886ecdf35bfb9950d07276dee3e767ad32148c61d20ac55a9de1c0e9a74e60028c95ad488bf4d05cc6ace427c7e0ec4fc071c239227e31
@@ -0,0 +1,2 @@
1
+ lib/generators/templates/app/assets/stylesheets/* linguist-vendored
2
+ lib/generators/templates/app/assets/javascripts/* linguist-vendored
@@ -0,0 +1 @@
1
+ test/dummy/log/test.log
data/CHANGELOG CHANGED
@@ -1,3 +1,68 @@
1
+ == master
2
+
3
+ * enhancement
4
+
5
+ * bugfix
6
+
7
+ == 2.0.0.pre
8
+
9
+ * enhancement
10
+ * replace chardinjs by driverjs : https://github.com/kamranahmedse/driver.js
11
+ * replace bootstrapdatetimepicker by https://tempusdominus.github.io/bootstrap-4/Usage/
12
+ * Update JStreeview
13
+ * Update Bootstrap 4.2
14
+ * Update FontAwesome 5
15
+ * Generate beautiful scaffold for mountable engine
16
+ * Tests generators works !
17
+ * Refactoring ruby code.
18
+
19
+ * bugfix
20
+ * Bugfix for engine
21
+
22
+ == 1.0.3
23
+
24
+ * enhancement
25
+ * You can generate scaffold in a mountable engine, now. (see README for syntax)
26
+
27
+ * Bugfix
28
+ * I18n translation default value (model.column).
29
+
30
+ == 1.0.2
31
+
32
+ * enhancement
33
+ * Using static twitter bootstrap files
34
+ * UI : button back & submit on the same line
35
+ * Add tests (better late than never :/)
36
+
37
+ * bugfix
38
+ * Fix #18 : Responsive Theme Navbar Overlaps Content When Resizing Below ~979px
39
+ * Fix generator locales
40
+ * Fix icon datetimepicker
41
+ * render nothing: true replace with head :ok
42
+
43
+ == 1.0.1
44
+
45
+ * enhancement
46
+ * Change datetimepicker (eyecon.ro -> eonasdan)
47
+ * Support CamelCase syntaxe for models.
48
+
49
+ * bugfix
50
+ * Change keys symbol into string on session (begin at 0.3.5)
51
+
52
+ == 1.0.0.pre
53
+
54
+ * enhancement
55
+ * Remove Markitup
56
+ * Remove Livequery
57
+ * Compatibility Rails 5
58
+ * Update gem (prawn, ransack, willpaginate)
59
+
60
+ == 0.3.6
61
+
62
+ * enhancement
63
+ * Prevent dbclick on form. Thanks to @fazelmk, again.
64
+ * Replace "create" by "new" for validation. Thanks to @fazelmk
65
+
1
66
  == 0.3.5
2
67
 
3
68
  * enhancement
@@ -160,4 +225,4 @@
160
225
 
161
226
  == Previous versions
162
227
 
163
- * See commits on github
228
+ * See commits on github
data/Gemfile CHANGED
@@ -2,20 +2,27 @@ source "http://rubygems.org"
2
2
 
3
3
  gemspec
4
4
 
5
- gem "rails", "~> 4.0"
6
- # Pagination
7
- gem "will_paginate"
8
- # Search and filter
9
- gem "ransack"
10
- # Pdf
11
- gem 'prawn', '1.0.0.rc2'
12
- # Textile
13
- gem 'RedCloth'
14
- # BBCode
15
- gem 'bb-ruby'
16
- # Markdown
17
- gem 'bluecloth'
18
- # Markdown
19
- gem 'rdiscount'
20
- # Clear html tag
21
- gem 'sanitize'
5
+ gem "rails", "~> 6.0"
6
+
7
+ group :test do
8
+ gem 'sqlite3'
9
+
10
+ gems = {
11
+ 'will_paginate' => nil, # v 3.1.5
12
+ 'ransack' => nil, #'2.3.2',
13
+ 'jquery-ui-rails' => nil,
14
+ 'prawn' => nil, #'2.1.0',
15
+ 'prawn-table' => nil, #'0.2.2',
16
+ 'sanitize' => nil,
17
+ 'bootstrap' => '~> 4.3.1',
18
+ 'font-awesome-rails' => '4.7.0.5',
19
+ 'momentjs-rails' => '>= 2.9.0',
20
+ 'bootstrap4-datetime-picker-rails' => nil,
21
+ 'jquery-rails' => '4.3.1'
22
+ }
23
+
24
+ gems.each{ |gem_to_add, version|
25
+ gem(gem_to_add, version)
26
+ }
27
+ end
28
+
@@ -0,0 +1,209 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ beautiful_scaffold (1.0.3)
5
+
6
+ GEM
7
+ remote: http://rubygems.org/
8
+ specs:
9
+ actioncable (6.0.3.2)
10
+ actionpack (= 6.0.3.2)
11
+ nio4r (~> 2.0)
12
+ websocket-driver (>= 0.6.1)
13
+ actionmailbox (6.0.3.2)
14
+ actionpack (= 6.0.3.2)
15
+ activejob (= 6.0.3.2)
16
+ activerecord (= 6.0.3.2)
17
+ activestorage (= 6.0.3.2)
18
+ activesupport (= 6.0.3.2)
19
+ mail (>= 2.7.1)
20
+ actionmailer (6.0.3.2)
21
+ actionpack (= 6.0.3.2)
22
+ actionview (= 6.0.3.2)
23
+ activejob (= 6.0.3.2)
24
+ mail (~> 2.5, >= 2.5.4)
25
+ rails-dom-testing (~> 2.0)
26
+ actionpack (6.0.3.2)
27
+ actionview (= 6.0.3.2)
28
+ activesupport (= 6.0.3.2)
29
+ rack (~> 2.0, >= 2.0.8)
30
+ rack-test (>= 0.6.3)
31
+ rails-dom-testing (~> 2.0)
32
+ rails-html-sanitizer (~> 1.0, >= 1.2.0)
33
+ actiontext (6.0.3.2)
34
+ actionpack (= 6.0.3.2)
35
+ activerecord (= 6.0.3.2)
36
+ activestorage (= 6.0.3.2)
37
+ activesupport (= 6.0.3.2)
38
+ nokogiri (>= 1.8.5)
39
+ actionview (6.0.3.2)
40
+ activesupport (= 6.0.3.2)
41
+ builder (~> 3.1)
42
+ erubi (~> 1.4)
43
+ rails-dom-testing (~> 2.0)
44
+ rails-html-sanitizer (~> 1.1, >= 1.2.0)
45
+ activejob (6.0.3.2)
46
+ activesupport (= 6.0.3.2)
47
+ globalid (>= 0.3.6)
48
+ activemodel (6.0.3.2)
49
+ activesupport (= 6.0.3.2)
50
+ activerecord (6.0.3.2)
51
+ activemodel (= 6.0.3.2)
52
+ activesupport (= 6.0.3.2)
53
+ activestorage (6.0.3.2)
54
+ actionpack (= 6.0.3.2)
55
+ activejob (= 6.0.3.2)
56
+ activerecord (= 6.0.3.2)
57
+ marcel (~> 0.3.1)
58
+ activesupport (6.0.3.2)
59
+ concurrent-ruby (~> 1.0, >= 1.0.2)
60
+ i18n (>= 0.7, < 2)
61
+ minitest (~> 5.1)
62
+ tzinfo (~> 1.1)
63
+ zeitwerk (~> 2.2, >= 2.2.2)
64
+ autoprefixer-rails (9.8.6.1)
65
+ execjs
66
+ bootstrap (4.3.1)
67
+ autoprefixer-rails (>= 9.1.0)
68
+ popper_js (>= 1.14.3, < 2)
69
+ sassc-rails (>= 2.0.0)
70
+ bootstrap4-datetime-picker-rails (0.3.1)
71
+ jquery-rails (~> 4.2, >= 4.2.0)
72
+ moment-timezone-rails (~> 1.0)
73
+ momentjs-rails (>= 2.10.5, <= 3.0.0)
74
+ builder (3.2.4)
75
+ concurrent-ruby (1.1.7)
76
+ crass (1.0.6)
77
+ erubi (1.9.0)
78
+ execjs (2.7.0)
79
+ ffi (1.13.1)
80
+ font-awesome-rails (4.7.0.5)
81
+ railties (>= 3.2, < 6.1)
82
+ globalid (0.4.2)
83
+ activesupport (>= 4.2.0)
84
+ i18n (1.8.5)
85
+ concurrent-ruby (~> 1.0)
86
+ jquery-rails (4.3.1)
87
+ rails-dom-testing (>= 1, < 3)
88
+ railties (>= 4.2.0)
89
+ thor (>= 0.14, < 2.0)
90
+ jquery-ui-rails (6.0.1)
91
+ railties (>= 3.2.16)
92
+ loofah (2.6.0)
93
+ crass (~> 1.0.2)
94
+ nokogiri (>= 1.5.9)
95
+ mail (2.7.1)
96
+ mini_mime (>= 0.1.1)
97
+ marcel (0.3.3)
98
+ mimemagic (~> 0.3.2)
99
+ method_source (1.0.0)
100
+ mimemagic (0.3.5)
101
+ mini_mime (1.0.2)
102
+ mini_portile2 (2.4.0)
103
+ minitest (5.14.1)
104
+ moment-timezone-rails (1.0.0)
105
+ momentjs-rails (>= 2.10.5, <= 3.0.0)
106
+ momentjs-rails (2.20.1)
107
+ railties (>= 3.1)
108
+ nio4r (2.5.2)
109
+ nokogiri (1.10.10)
110
+ mini_portile2 (~> 2.4.0)
111
+ nokogumbo (2.0.2)
112
+ nokogiri (~> 1.8, >= 1.8.4)
113
+ pdf-core (0.8.1)
114
+ polyamorous (2.3.2)
115
+ activerecord (>= 5.2.1)
116
+ popper_js (1.16.0)
117
+ prawn (2.3.0)
118
+ pdf-core (~> 0.8.1)
119
+ ttfunk (~> 1.6)
120
+ prawn-table (0.2.2)
121
+ prawn (>= 1.3.0, < 3.0.0)
122
+ rack (2.2.3)
123
+ rack-test (1.1.0)
124
+ rack (>= 1.0, < 3)
125
+ rails (6.0.3.2)
126
+ actioncable (= 6.0.3.2)
127
+ actionmailbox (= 6.0.3.2)
128
+ actionmailer (= 6.0.3.2)
129
+ actionpack (= 6.0.3.2)
130
+ actiontext (= 6.0.3.2)
131
+ actionview (= 6.0.3.2)
132
+ activejob (= 6.0.3.2)
133
+ activemodel (= 6.0.3.2)
134
+ activerecord (= 6.0.3.2)
135
+ activestorage (= 6.0.3.2)
136
+ activesupport (= 6.0.3.2)
137
+ bundler (>= 1.3.0)
138
+ railties (= 6.0.3.2)
139
+ sprockets-rails (>= 2.0.0)
140
+ rails-dom-testing (2.0.3)
141
+ activesupport (>= 4.2.0)
142
+ nokogiri (>= 1.6)
143
+ rails-html-sanitizer (1.3.0)
144
+ loofah (~> 2.3)
145
+ railties (6.0.3.2)
146
+ actionpack (= 6.0.3.2)
147
+ activesupport (= 6.0.3.2)
148
+ method_source
149
+ rake (>= 0.8.7)
150
+ thor (>= 0.20.3, < 2.0)
151
+ rake (13.0.1)
152
+ ransack (2.3.2)
153
+ activerecord (>= 5.2.1)
154
+ activesupport (>= 5.2.1)
155
+ i18n
156
+ polyamorous (= 2.3.2)
157
+ sanitize (5.2.1)
158
+ crass (~> 1.0.2)
159
+ nokogiri (>= 1.8.0)
160
+ nokogumbo (~> 2.0)
161
+ sassc (2.4.0)
162
+ ffi (~> 1.9)
163
+ sassc-rails (2.1.2)
164
+ railties (>= 4.0.0)
165
+ sassc (>= 2.0)
166
+ sprockets (> 3.0)
167
+ sprockets-rails
168
+ tilt
169
+ sprockets (3.7.2)
170
+ concurrent-ruby (~> 1.0)
171
+ rack (> 1, < 3)
172
+ sprockets-rails (3.2.1)
173
+ actionpack (>= 4.0)
174
+ activesupport (>= 4.0)
175
+ sprockets (>= 3.0.0)
176
+ sqlite3 (1.4.2)
177
+ thor (0.20.3)
178
+ thread_safe (0.3.6)
179
+ tilt (2.0.10)
180
+ ttfunk (1.6.2.1)
181
+ tzinfo (1.2.7)
182
+ thread_safe (~> 0.1)
183
+ websocket-driver (0.7.3)
184
+ websocket-extensions (>= 0.1.0)
185
+ websocket-extensions (0.1.5)
186
+ will_paginate (3.3.0)
187
+ zeitwerk (2.4.0)
188
+
189
+ PLATFORMS
190
+ ruby
191
+
192
+ DEPENDENCIES
193
+ beautiful_scaffold!
194
+ bootstrap (~> 4.3.1)
195
+ bootstrap4-datetime-picker-rails
196
+ font-awesome-rails (= 4.7.0.5)
197
+ jquery-rails (= 4.3.1)
198
+ jquery-ui-rails
199
+ momentjs-rails (>= 2.9.0)
200
+ prawn
201
+ prawn-table
202
+ rails (~> 6.0)
203
+ ransack
204
+ sanitize
205
+ sqlite3
206
+ will_paginate
207
+
208
+ BUNDLED WITH
209
+ 2.1.4
@@ -2,98 +2,110 @@
2
2
 
3
3
  Beautiful Scaffold is a gem which propose generators for a complete scaffold with paginate, sort and filter.
4
4
  Fully customizable.
5
- More info : http://www.beautiful-scaffold.com/
6
- Demo : http://demo.beautiful-scaffold.com/
5
+ Info : https://github.com/rivsc/Beautiful-Scaffold
6
+ Demo : http://beautiful-scaffold.rivsc.ovh/
7
7
 
8
8
  == Install
9
9
 
10
- === RubyOnRails 4.1
11
-
12
- Add this in your Gemfile :
13
- gem 'beautiful_scaffold', '0.3.4'
14
-
15
- === RubyOnRails 4.2
16
-
17
- Add this in your Gemfile :
18
- gem 'beautiful_scaffold', '0.3.5'
10
+ Add this in the Gemfile of your rails app or engine :
11
+ gem 'beautiful_scaffold'
19
12
 
20
13
  === Next
21
14
 
22
15
  And run
23
- bundle install
16
+
17
+ bundle install
24
18
 
25
19
  == Usage
26
20
 
27
21
  === Scaffold
28
22
 
29
- rails generate beautiful_scaffold model attr:type attr:type... [--namespace=name] [--donttouchgem=name]
23
+ # model : underscore and singular
24
+ # mountable_engine : underscore
25
+ # namespace : underscore
26
+ rails generate beautiful_scaffold model attr:type attr:type... [--namespace=name] [--donttouchgem=yes] [--mountable_engine=name]
30
27
 
31
- type available :
28
+ Types available:
32
29
  * integer
33
30
  * float
34
31
  * text
35
32
  * string
36
33
  * price
37
34
  * color
38
- * richtext
39
35
  * wysiwyg
40
36
 
37
+ (See below #label-Barcodes)
38
+
41
39
  # Example : products
42
- rails g beautiful_scaffold product name:string price:price tva:float description:richtext visible:boolean && rake db:migrate
40
+
41
+ rails g beautiful_scaffold product name:string price:price tva:float description:wysiwyg visible:boolean && rake db:migrate
43
42
 
44
43
  # Example : admin products
45
- rails g beautiful_scaffold product name:string price:price tva:float description:richtext overview_description:richtext visible:boolean --namespace=admin && rake db:migrate
44
+
45
+ rails g beautiful_scaffold product name:string price:price tva:float description:wysiwyg overview_description:wysiwyg visible:boolean --namespace=admin && rake db:migrate
46
+
47
+ # Example (for an engine) :
48
+ # You need to add beautiful-scaffold to the gemfile of the engine (not the gemspec !).
49
+
50
+ rails g beautiful_scaffold user code:string --mountable-engine=faq
51
+ rails g beautiful_scaffold question title:string description:wysiwyg user:references resolved:boolean --mountable-engine=faq
52
+ rails g beautiful_scaffold answer description:wysiwyg user:references up:integer down:integer --mountable-engine=faq
53
+ rails g beautiful_migration AddPositionToFaqAnswers position:integer --mountable-engine=faq
54
+ rails g beautiful_jointable answer tag --mountable-engine=faq
46
55
 
47
56
  === Migration (Use Add[Field]To[ModelPluralize] syntax)
48
57
 
49
- rails g beautiful_migration AddFieldToModels field:type
58
+ rails g beautiful_migration AddFieldToModels field:type
50
59
 
51
60
  === Locale (i18n) (Example)
52
61
 
53
- Run rake db:migrate before rail g beautiful_locale (to get lastest attribute translation)
62
+ Run `rake db:migrate` before `rails g beautiful_locale` (to get lastest attribute translation)
54
63
 
55
- rails g beautiful_locale all
56
- rails g beautiful_locale en
57
- rails g beautiful_locale fr
58
- rails g beautiful_locale de
64
+ rails g beautiful_locale all
65
+ rails g beautiful_locale en
66
+ rails g beautiful_locale fr
67
+ rails g beautiful_locale de
59
68
 
60
69
  === Join Table (has_and_belongs_to_many relation)
61
70
 
62
- rails g beautiful_jointable model1 model2
71
+ rails g beautiful_jointable model1 model2
63
72
 
73
+ TODO replace Devise by Sorcery & Cancan by Cancancan
64
74
  === Install et Configure Devise (authentification) and Cancan (authorization)
65
75
 
66
- rails g beautiful_devisecancan model
76
+ rails g beautiful_devisecancan model
67
77
 
68
78
  === In views
69
79
 
70
80
  ==== Barcodes
71
81
 
72
82
  Set code like this :
73
- <span class="barcode" data-barcode="1234567890128" data-type-barcode="ean13"></span>
83
+
84
+ <span class="barcode" data-barcode="1234567890128" data-type-barcode="ean13"></span>
74
85
 
75
86
  data-type-barcode can be :
76
87
 
77
- codabar
78
- code11 (code 11)
79
- code39 (code 39)
80
- code93 (code 93)
81
- code128 (code 128)
82
- ean8 (ean 8)
83
- ean13 (ean 13)
84
- std25 (standard 2 of 5 - industrial 2 of 5)
85
- int25 (interleaved 2 of 5)
86
- msi
87
- datamatrix (ASCII + extended)
88
+ codabar
89
+ code11 (code 11)
90
+ code39 (code 39)
91
+ code93 (code 93)
92
+ code128 (code 128)
93
+ ean8 (ean 8)
94
+ ean13 (ean 13)
95
+ std25 (standard 2 of 5 - industrial 2 of 5)
96
+ int25 (interleaved 2 of 5)
97
+ msi
98
+ datamatrix (ASCII + extended)
99
+
100
+ ==== Driverjs (overlay instructions)
101
+
102
+ Example : when you click on the #bs-help tag presentation tour display on screen !
88
103
 
89
- ==== Chardinjs (overlay instructions)
104
+ If you want to add 'slide' :
90
105
 
91
- Example : This button triggers chardinjs on element with 'menu' id.
92
- <a href="#" class="bs-chardinjs" data-selector="#menu">Help Menu</a>
106
+ For add instruction to element, add this to your markup :
93
107
 
94
- If you want display all chardinjs :
95
- <a href="#" class="bs-chardinjs" data-selector="body">Help</a>
108
+ id="myunique-id-in-the-page" data-present-title="Title for the slide" data-present-description="Short description" data-present-order="1"
96
109
 
97
- Just add class="bs-chardinjs" in a button / link for trigger chardinjs. Beautiful-Scaffold does the job !
110
+ And Beautiful-Scaffold does the job !
98
111
 
99
- For add instruction to element, read official documentation : https://github.com/heelhook/chardin.js#adding-data-for-the-instructions