incline 0.1.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (303) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +13 -0
  3. data/Gemfile +17 -0
  4. data/Gemfile.lock +186 -0
  5. data/MIT-LICENSE +20 -0
  6. data/README.rdoc +208 -0
  7. data/Rakefile +37 -0
  8. data/app/assets/fonts/incline/.keep +0 -0
  9. data/app/assets/images/incline/.keep +0 -0
  10. data/app/assets/images/incline/barcode-B.svg +181 -0
  11. data/app/assets/javascripts/incline/activate_classed_items.js +11 -0
  12. data/app/assets/javascripts/incline/application.js +30 -0
  13. data/app/assets/javascripts/incline/bootstrap-datepicker.js +1800 -0
  14. data/app/assets/javascripts/incline/datatables.js +22193 -0
  15. data/app/assets/javascripts/incline/escapeHtml.js +10 -0
  16. data/app/assets/javascripts/incline/inline_actions.js +479 -0
  17. data/app/assets/javascripts/incline/jquery.doubleScroll.js +112 -0
  18. data/app/assets/javascripts/incline/jquery.number.js +764 -0
  19. data/app/assets/javascripts/incline/regexMask.js +27 -0
  20. data/app/assets/javascripts/incline/select2/i18n/en.js +3 -0
  21. data/app/assets/javascripts/incline/select2/select2.full.js +6436 -0
  22. data/app/assets/stylesheets/incline/application.css +18 -0
  23. data/app/assets/stylesheets/incline/bootstrap-theme.min.css +5 -0
  24. data/app/assets/stylesheets/incline/custom.scss +279 -0
  25. data/app/assets/stylesheets/incline/datatables.css +494 -0
  26. data/app/assets/stylesheets/incline/datepicker3.css +790 -0
  27. data/app/assets/stylesheets/incline/select2.css +484 -0
  28. data/app/controllers/incline/access_groups_controller.rb +127 -0
  29. data/app/controllers/incline/access_test_controller.rb +30 -0
  30. data/app/controllers/incline/account_activations_controller.rb +28 -0
  31. data/app/controllers/incline/application_controller.rb +11 -0
  32. data/app/controllers/incline/contact_controller.rb +34 -0
  33. data/app/controllers/incline/password_resets_controller.rb +113 -0
  34. data/app/controllers/incline/security_controller.rb +100 -0
  35. data/app/controllers/incline/sessions_controller.rb +50 -0
  36. data/app/controllers/incline/users_controller.rb +304 -0
  37. data/app/controllers/incline/welcome_controller.rb +19 -0
  38. data/app/helpers/incline/.keep +0 -0
  39. data/app/mailers/incline/application_mailer_base.rb +11 -0
  40. data/app/mailers/incline/contact_form.rb +19 -0
  41. data/app/mailers/incline/user_mailer.rb +45 -0
  42. data/app/models/incline/access_group.rb +121 -0
  43. data/app/models/incline/access_group_group_member.rb +12 -0
  44. data/app/models/incline/access_group_user_member.rb +10 -0
  45. data/app/models/incline/action_group.rb +12 -0
  46. data/app/models/incline/action_security.rb +222 -0
  47. data/app/models/incline/contact_message.rb +37 -0
  48. data/app/models/incline/disable_info.rb +20 -0
  49. data/app/models/incline/password_reset.rb +14 -0
  50. data/app/models/incline/password_reset_request.rb +14 -0
  51. data/app/models/incline/user.rb +437 -0
  52. data/app/models/incline/user_login_history.rb +30 -0
  53. data/app/views/incline/access_groups/_details.json.jbuilder +10 -0
  54. data/app/views/incline/access_groups/_form.html.erb +19 -0
  55. data/app/views/incline/access_groups/_list.html.erb +60 -0
  56. data/app/views/incline/access_groups/_messages.json.jbuilder +6 -0
  57. data/app/views/incline/access_groups/edit.html.erb +2 -0
  58. data/app/views/incline/access_groups/index.html.erb +6 -0
  59. data/app/views/incline/access_groups/index.json.jbuilder +16 -0
  60. data/app/views/incline/access_groups/new.html.erb +2 -0
  61. data/app/views/incline/access_groups/show.html.erb +9 -0
  62. data/app/views/incline/access_groups/show.json.jbuilder +11 -0
  63. data/app/views/incline/contact/new.html.erb +22 -0
  64. data/app/views/incline/contact_form/contact.html.erb +16 -0
  65. data/app/views/incline/contact_form/contact.text.erb +13 -0
  66. data/app/views/incline/password_resets/edit.html.erb +16 -0
  67. data/app/views/incline/password_resets/new.html.erb +12 -0
  68. data/app/views/incline/security/_details.json.jbuilder +7 -0
  69. data/app/views/incline/security/_form.html.erb +20 -0
  70. data/app/views/incline/security/_list.html.erb +89 -0
  71. data/app/views/incline/security/_messages.json.jbuilder +6 -0
  72. data/app/views/incline/security/edit.html.erb +2 -0
  73. data/app/views/incline/security/index.html.erb +6 -0
  74. data/app/views/incline/security/index.json.jbuilder +16 -0
  75. data/app/views/incline/security/show.html.erb +31 -0
  76. data/app/views/incline/security/show.json.jbuilder +11 -0
  77. data/app/views/incline/sessions/new.html.erb +26 -0
  78. data/app/views/incline/user_mailer/account_activation.html.erb +7 -0
  79. data/app/views/incline/user_mailer/account_activation.text.erb +6 -0
  80. data/app/views/incline/user_mailer/invalid_password_reset.html.erb +3 -0
  81. data/app/views/incline/user_mailer/invalid_password_reset.text.erb +5 -0
  82. data/app/views/incline/user_mailer/password_reset.html.erb +8 -0
  83. data/app/views/incline/user_mailer/password_reset.text.erb +7 -0
  84. data/app/views/incline/users/_details.json.jbuilder +32 -0
  85. data/app/views/incline/users/_form.html.erb +21 -0
  86. data/app/views/incline/users/_list.html.erb +102 -0
  87. data/app/views/incline/users/_messages.json.jbuilder +6 -0
  88. data/app/views/incline/users/disable_confirm.html.erb +19 -0
  89. data/app/views/incline/users/edit.html.erb +5 -0
  90. data/app/views/incline/users/index.html.erb +6 -0
  91. data/app/views/incline/users/index.json.jbuilder +16 -0
  92. data/app/views/incline/users/new.html.erb +5 -0
  93. data/app/views/incline/users/show.html.erb +12 -0
  94. data/app/views/incline/users/show.json.jbuilder +11 -0
  95. data/app/views/incline/welcome/home.html.erb +5 -0
  96. data/app/views/layouts/application.html.erb +1 -0
  97. data/app/views/layouts/incline/_account_menu.html.erb +18 -0
  98. data/app/views/layouts/incline/_app_menu_anon.html.erb +1 -0
  99. data/app/views/layouts/incline/_app_menu_authenticated.html.erb +1 -0
  100. data/app/views/layouts/incline/_footer.html.erb +13 -0
  101. data/app/views/layouts/incline/_header.html.erb +21 -0
  102. data/app/views/layouts/incline/_html_mailer.html.erb +5 -0
  103. data/app/views/layouts/incline/_incline_app.html.erb +25 -0
  104. data/app/views/layouts/incline/_messages.html.erb +3 -0
  105. data/app/views/layouts/incline/_shim.html.erb +3 -0
  106. data/app/views/layouts/incline/_text_mailer.text.erb +1 -0
  107. data/app/views/layouts/incline/application.html.erb +1 -0
  108. data/app/views/layouts/mailer.html.erb +2 -0
  109. data/app/views/layouts/mailer.text.erb +2 -0
  110. data/bin/rails +12 -0
  111. data/bin/test_scaffold.sh +10 -0
  112. data/config/routes.rb +61 -0
  113. data/db/migrate/20170511230126_create_incline_users.rb +26 -0
  114. data/db/migrate/20170515003052_create_incline_access_groups.rb +10 -0
  115. data/db/migrate/20170515003221_create_incline_user_login_histories.rb +12 -0
  116. data/db/migrate/20170515150908_create_incline_access_group_user_members.rb +11 -0
  117. data/db/migrate/20170515151058_create_incline_access_group_group_members.rb +11 -0
  118. data/db/migrate/20170517193432_add_comments_to_incline_user.rb +5 -0
  119. data/db/migrate/20170622132700_create_incline_action_securities.rb +16 -0
  120. data/db/migrate/20170622172712_create_incline_action_groups.rb +11 -0
  121. data/db/migrate/20170622195742_add_non_standard_to_action_security.rb +5 -0
  122. data/db/migrate/20170622230422_add_visible_to_action_security.rb +5 -0
  123. data/db/seeds.rb +81 -0
  124. data/exe/new_incline_app +42 -0
  125. data/lib/generators/incline/install_generator.rb +259 -0
  126. data/lib/generators/incline/templates/_app_menu_anon.html.erb +1 -0
  127. data/lib/generators/incline/templates/_app_menu_authenticated.html.erb +1 -0
  128. data/lib/generators/incline/templates/incline_application.css +17 -0
  129. data/lib/generators/incline/templates/incline_application.html.erb +1 -0
  130. data/lib/generators/incline/templates/incline_application.js +12 -0
  131. data/lib/generators/incline/templates/incline_database.yml +25 -0
  132. data/lib/generators/incline/templates/incline_email.yml +20 -0
  133. data/lib/generators/incline/templates/incline_mailer.html.erb +2 -0
  134. data/lib/generators/incline/templates/incline_mailer.text.erb +2 -0
  135. data/lib/generators/incline/templates/incline_users.yml +64 -0
  136. data/lib/generators/incline/templates/incline_version.rb +3 -0
  137. data/lib/incline/auth_engine_base.rb +52 -0
  138. data/lib/incline/data_tables_request.rb +336 -0
  139. data/lib/incline/date_time_formats.rb +6 -0
  140. data/lib/incline/engine.rb +212 -0
  141. data/lib/incline/errors.rb +15 -0
  142. data/lib/incline/extensions/action_controller_base.rb +526 -0
  143. data/lib/incline/extensions/action_mailer_base.rb +66 -0
  144. data/lib/incline/extensions/action_view_base.rb +489 -0
  145. data/lib/incline/extensions/active_record_base.rb +308 -0
  146. data/lib/incline/extensions/application.rb +137 -0
  147. data/lib/incline/extensions/application_configuration.rb +50 -0
  148. data/lib/incline/extensions/connection_adapter.rb +55 -0
  149. data/lib/incline/extensions/date_time_value.rb +123 -0
  150. data/lib/incline/extensions/date_value.rb +77 -0
  151. data/lib/incline/extensions/decimal_value.rb +55 -0
  152. data/lib/incline/extensions/erb_scaffold_generator.rb +31 -0
  153. data/lib/incline/extensions/float_value.rb +59 -0
  154. data/lib/incline/extensions/form_builder.rb +617 -0
  155. data/lib/incline/extensions/integer_value.rb +54 -0
  156. data/lib/incline/extensions/jbuilder_generator.rb +38 -0
  157. data/lib/incline/extensions/jbuilder_template.rb +39 -0
  158. data/lib/incline/extensions/main_app.rb +40 -0
  159. data/lib/incline/extensions/numeric.rb +63 -0
  160. data/lib/incline/extensions/object.rb +31 -0
  161. data/lib/incline/extensions/resource_route_generator.rb +53 -0
  162. data/lib/incline/extensions/session.rb +113 -0
  163. data/lib/incline/extensions/string.rb +50 -0
  164. data/lib/incline/extensions/test_case.rb +764 -0
  165. data/lib/incline/extensions/time_zone_converter.rb +40 -0
  166. data/lib/incline/global_status.rb +236 -0
  167. data/lib/incline/helpers/route_hash_formatter.rb +46 -0
  168. data/lib/incline/json_log_formatter.rb +96 -0
  169. data/lib/incline/json_logger.rb +17 -0
  170. data/lib/incline/log.rb +153 -0
  171. data/lib/incline/number_formats.rb +17 -0
  172. data/lib/incline/recaptcha.rb +346 -0
  173. data/lib/incline/user_manager.rb +212 -0
  174. data/lib/incline/validators/email_validator.rb +45 -0
  175. data/lib/incline/validators/ip_address_validator.rb +32 -0
  176. data/lib/incline/validators/recaptcha_validator.rb +37 -0
  177. data/lib/incline/validators/safe_name_validator.rb +31 -0
  178. data/lib/incline/version.rb +3 -0
  179. data/lib/incline/work_path.rb +75 -0
  180. data/lib/incline.rb +197 -0
  181. data/lib/tasks/incline_tasks.rake +4 -0
  182. data/lib/templates/erb/scaffold/_form.html.erb +43 -0
  183. data/lib/templates/erb/scaffold/_list.html.erb +81 -0
  184. data/lib/templates/erb/scaffold/edit.html.erb +1 -0
  185. data/lib/templates/erb/scaffold/index.html.erb +6 -0
  186. data/lib/templates/erb/scaffold/new.html.erb +1 -0
  187. data/lib/templates/erb/scaffold/show.html.erb +34 -0
  188. data/lib/templates/jbuilder/scaffold/_details.json.jbuilder +20 -0
  189. data/lib/templates/jbuilder/scaffold/index.json.jbuilder +16 -0
  190. data/lib/templates/jbuilder/scaffold/show.json.jbuilder +16 -0
  191. data/lib/templates/rails/scaffold_controller/controller.rb +128 -0
  192. data/test/controllers/incline/access_groups_controller_test.rb +65 -0
  193. data/test/controllers/incline/access_test_controller_test.rb +53 -0
  194. data/test/controllers/incline/contact_controller_test.rb +32 -0
  195. data/test/controllers/incline/security_controller_test.rb +39 -0
  196. data/test/controllers/incline/welcome_controller_test.rb +16 -0
  197. data/test/dummy/README.rdoc +28 -0
  198. data/test/dummy/Rakefile +6 -0
  199. data/test/dummy/app/assets/images/.keep +0 -0
  200. data/test/dummy/app/assets/javascripts/application.js +12 -0
  201. data/test/dummy/app/assets/stylesheets/application.css +17 -0
  202. data/test/dummy/app/controllers/application_controller.rb +5 -0
  203. data/test/dummy/app/controllers/concerns/.keep +0 -0
  204. data/test/dummy/app/helpers/application_helper.rb +2 -0
  205. data/test/dummy/app/mailers/.keep +0 -0
  206. data/test/dummy/app/models/.keep +0 -0
  207. data/test/dummy/app/models/concerns/.keep +0 -0
  208. data/test/dummy/app/views/layouts/application.html.erb +1 -0
  209. data/test/dummy/app/views/layouts/incline/_app_menu_anon.html.erb +1 -0
  210. data/test/dummy/app/views/layouts/incline/_app_menu_authenticated.html.erb +1 -0
  211. data/test/dummy/app/views/layouts/mailer.html.erb +2 -0
  212. data/test/dummy/app/views/layouts/mailer.text.erb +2 -0
  213. data/test/dummy/bin/bundle +3 -0
  214. data/test/dummy/bin/rails +4 -0
  215. data/test/dummy/bin/rake +4 -0
  216. data/test/dummy/bin/setup +29 -0
  217. data/test/dummy/config/application.rb +38 -0
  218. data/test/dummy/config/boot.rb +5 -0
  219. data/test/dummy/config/database.yml +34 -0
  220. data/test/dummy/config/email.yml +24 -0
  221. data/test/dummy/config/environment.rb +5 -0
  222. data/test/dummy/config/environments/development.rb +45 -0
  223. data/test/dummy/config/environments/production.rb +85 -0
  224. data/test/dummy/config/environments/test.rb +44 -0
  225. data/test/dummy/config/initializers/assets.rb +11 -0
  226. data/test/dummy/config/initializers/backtrace_silencers.rb +7 -0
  227. data/test/dummy/config/initializers/cookies_serializer.rb +3 -0
  228. data/test/dummy/config/initializers/filter_parameter_logging.rb +4 -0
  229. data/test/dummy/config/initializers/inflections.rb +16 -0
  230. data/test/dummy/config/initializers/mime_types.rb +4 -0
  231. data/test/dummy/config/initializers/session_store.rb +3 -0
  232. data/test/dummy/config/initializers/to_time_preserves_timezone.rb +10 -0
  233. data/test/dummy/config/initializers/wrap_parameters.rb +14 -0
  234. data/test/dummy/config/locales/en.yml +23 -0
  235. data/test/dummy/config/routes.rb +6 -0
  236. data/test/dummy/config.ru +4 -0
  237. data/test/dummy/db/schema.rb +108 -0
  238. data/test/dummy/lib/assets/.keep +0 -0
  239. data/test/dummy/log/.keep +0 -0
  240. data/test/dummy/public/404.html +67 -0
  241. data/test/dummy/public/422.html +67 -0
  242. data/test/dummy/public/500.html +66 -0
  243. data/test/dummy/public/favicon.ico +0 -0
  244. data/test/extensions/action_controller_base_extensions_test.rb +21 -0
  245. data/test/extensions/action_mailer_base_extensions_test.rb +20 -0
  246. data/test/extensions/action_view_base_extensions_test.rb +267 -0
  247. data/test/extensions/active_record_extensions_test.rb +173 -0
  248. data/test/extensions/application_configuration_extensions_test.rb +46 -0
  249. data/test/extensions/application_extensions_test.rb +23 -0
  250. data/test/extensions/connection_adapter_extensions_test.rb +54 -0
  251. data/test/extensions/date_time_value_extensions_test.rb +104 -0
  252. data/test/extensions/date_value_extensions_test.rb +102 -0
  253. data/test/extensions/decimal_value_extensions_test.rb +85 -0
  254. data/test/extensions/erb_scaffold_generator_extensions_test.rb +17 -0
  255. data/test/extensions/float_value_extensions_test.rb +78 -0
  256. data/test/extensions/form_builder_extensions_test.rb +28 -0
  257. data/test/extensions/integer_value_extensions_test.rb +78 -0
  258. data/test/extensions/jbuilder_generator_extensions_test.rb +21 -0
  259. data/test/extensions/jbuilder_template_extensions_test.rb +47 -0
  260. data/test/extensions/main_app_extensions_test.rb +55 -0
  261. data/test/extensions/numeric_extensions_test.rb +76 -0
  262. data/test/extensions/object_extensions_test.rb +104 -0
  263. data/test/extensions/session_extensions_test.rb +69 -0
  264. data/test/extensions/string_extensions_test.rb +32 -0
  265. data/test/extensions/test_case_extensions_test.rb +538 -0
  266. data/test/extensions/time_zone_converter_extensions_test.rb +10 -0
  267. data/test/fixtures/incline/access_group_group_members.yml +1 -0
  268. data/test/fixtures/incline/access_group_user_members.yml +1 -0
  269. data/test/fixtures/incline/access_groups.yml +13 -0
  270. data/test/fixtures/incline/action_groups.yml +6 -0
  271. data/test/fixtures/incline/action_securities.yml +18 -0
  272. data/test/fixtures/incline/user_login_histories.yml +1 -0
  273. data/test/fixtures/incline/users.yml +64 -0
  274. data/test/incline_test.rb +63 -0
  275. data/test/integration/incline/users_edit_test.rb +180 -0
  276. data/test/integration/incline/users_login_test.rb +105 -0
  277. data/test/integration/incline/users_signup_test.rb +147 -0
  278. data/test/integration/navigation_test.rb +11 -0
  279. data/test/lib/data_tables_request_test.rb +245 -0
  280. data/test/lib/date_time_formats_test.rb +111 -0
  281. data/test/lib/global_status_test.rb +89 -0
  282. data/test/lib/json_log_formatter_test.rb +43 -0
  283. data/test/lib/log_test.rb +36 -0
  284. data/test/lib/recaptcha_test.rb +75 -0
  285. data/test/lib/user_manager_test.rb +47 -0
  286. data/test/lib/work_path_test.rb +18 -0
  287. data/test/models/incline/access_group_group_member_test.rb +30 -0
  288. data/test/models/incline/access_group_test.rb +60 -0
  289. data/test/models/incline/access_group_user_member_test.rb +29 -0
  290. data/test/models/incline/action_group_test.rb +27 -0
  291. data/test/models/incline/action_security_test.rb +176 -0
  292. data/test/models/incline/contact_message_test.rb +66 -0
  293. data/test/models/incline/disable_info_test.rb +29 -0
  294. data/test/models/incline/password_reset_request_test.rb +35 -0
  295. data/test/models/incline/password_reset_test.rb +51 -0
  296. data/test/models/incline/user_login_history_test.rb +31 -0
  297. data/test/models/incline/user_test.rb +91 -0
  298. data/test/test_helper.rb +42 -0
  299. data/test/validators/email_validator_test.rb +102 -0
  300. data/test/validators/ip_address_validator_test.rb +107 -0
  301. data/test/validators/recaptcha_validator_test.rb +57 -0
  302. data/test/validators/safe_name_validator_test.rb +101 -0
  303. metadata +584 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 031e478baf366cdebf99cb4659498632374a87cc
4
+ data.tar.gz: a25cdc96040f97b41ba24b637b1a580d27a655e5
5
+ SHA512:
6
+ metadata.gz: 8bf9dbd8fe73f9dba8e04fa2c1b43642e22ae62de37edb212ce88e7557b9ed8c5148bfd208a35c9b4368cdd8015299b5122969592cf838917640decf47b53aa8
7
+ data.tar.gz: 1be0ccdb1ead2ea1008378d1e0a231c4ffe40023a5f0b13985f3d2bbf1db8f543c0ca19a2a2637cb74db48b30df8c08976086363279d3f266942499a934ce15b
data/.gitignore ADDED
@@ -0,0 +1,13 @@
1
+ .bundle/
2
+ log/*.log
3
+ pkg/
4
+ tmp/
5
+ config/secrets.yml
6
+ test/dummy/db/*.sqlite3
7
+ test/dummy/db/*.sqlite3-journal
8
+ test/dummy/log/*.log
9
+ test/dummy/log/*.log.*
10
+ test/dummy/tmp/
11
+ test/dummy/.sass-cache
12
+ test/dummy/config/secrets.yml
13
+
data/Gemfile ADDED
@@ -0,0 +1,17 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Declare your gem's dependencies in incline.gemspec.
4
+ # Bundler will treat runtime dependencies like base dependencies, and
5
+ # development dependencies will be added by default to the :development group.
6
+ gemspec
7
+
8
+ group :development do
9
+ gem 'byebug'
10
+ end
11
+
12
+ group :test do
13
+ gem 'byebug'
14
+ gem 'tiny_tds', '~> 1.3.0'
15
+ gem 'activerecord-sqlserver-adapter', '~> 4.2.18'
16
+ end
17
+
data/Gemfile.lock ADDED
@@ -0,0 +1,186 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ incline (0.1.5)
5
+ ansi (~> 1.5.0)
6
+ bcrypt
7
+ bootstrap-sass
8
+ coffee-rails
9
+ exception_notification (~> 4.2.1)
10
+ jbuilder
11
+ jquery-rails
12
+ nokogiri
13
+ rails (~> 4.2.8)
14
+ redcarpet (~> 3.4.0)
15
+ sass-rails (~> 5.0.6)
16
+ shells (~> 0.1.9)
17
+ spawnling (~> 2.1.6)
18
+ uglifier
19
+
20
+ GEM
21
+ remote: https://rubygems.org/
22
+ specs:
23
+ actionmailer (4.2.8)
24
+ actionpack (= 4.2.8)
25
+ actionview (= 4.2.8)
26
+ activejob (= 4.2.8)
27
+ mail (~> 2.5, >= 2.5.4)
28
+ rails-dom-testing (~> 1.0, >= 1.0.5)
29
+ actionpack (4.2.8)
30
+ actionview (= 4.2.8)
31
+ activesupport (= 4.2.8)
32
+ rack (~> 1.6)
33
+ rack-test (~> 0.6.2)
34
+ rails-dom-testing (~> 1.0, >= 1.0.5)
35
+ rails-html-sanitizer (~> 1.0, >= 1.0.2)
36
+ actionview (4.2.8)
37
+ activesupport (= 4.2.8)
38
+ builder (~> 3.1)
39
+ erubis (~> 2.7.0)
40
+ rails-dom-testing (~> 1.0, >= 1.0.5)
41
+ rails-html-sanitizer (~> 1.0, >= 1.0.3)
42
+ activejob (4.2.8)
43
+ activesupport (= 4.2.8)
44
+ globalid (>= 0.3.0)
45
+ activemodel (4.2.8)
46
+ activesupport (= 4.2.8)
47
+ builder (~> 3.1)
48
+ activerecord (4.2.8)
49
+ activemodel (= 4.2.8)
50
+ activesupport (= 4.2.8)
51
+ arel (~> 6.0)
52
+ activerecord-sqlserver-adapter (4.2.18)
53
+ activerecord (~> 4.2.1)
54
+ activesupport (4.2.8)
55
+ i18n (~> 0.7)
56
+ minitest (~> 5.1)
57
+ thread_safe (~> 0.3, >= 0.3.4)
58
+ tzinfo (~> 1.1)
59
+ ansi (1.5.0)
60
+ arel (6.0.4)
61
+ autoprefixer-rails (7.1.2.2)
62
+ execjs
63
+ bcrypt (3.1.11)
64
+ bootstrap-sass (3.3.7)
65
+ autoprefixer-rails (>= 5.2.1)
66
+ sass (>= 3.3.4)
67
+ builder (3.2.3)
68
+ byebug (9.0.6)
69
+ coffee-rails (4.2.2)
70
+ coffee-script (>= 2.2.0)
71
+ railties (>= 4.0.0)
72
+ coffee-script (2.4.1)
73
+ coffee-script-source
74
+ execjs
75
+ coffee-script-source (1.12.2)
76
+ concurrent-ruby (1.0.5)
77
+ debug_inspector (0.0.3)
78
+ erubis (2.7.0)
79
+ exception_notification (4.2.1)
80
+ actionmailer (>= 4.0, < 6)
81
+ activesupport (>= 4.0, < 6)
82
+ execjs (2.7.0)
83
+ faker (1.7.3)
84
+ i18n (~> 0.5)
85
+ ffi (1.9.18)
86
+ globalid (0.4.0)
87
+ activesupport (>= 4.2.0)
88
+ i18n (0.8.1)
89
+ jbuilder (2.7.0)
90
+ activesupport (>= 4.2.0)
91
+ multi_json (>= 1.2)
92
+ jquery-rails (4.3.1)
93
+ rails-dom-testing (>= 1, < 3)
94
+ railties (>= 4.2.0)
95
+ thor (>= 0.14, < 2.0)
96
+ loofah (2.0.3)
97
+ nokogiri (>= 1.5.9)
98
+ mail (2.6.6)
99
+ mime-types (>= 1.16, < 4)
100
+ mime-types (3.1)
101
+ mime-types-data (~> 3.2015)
102
+ mime-types-data (3.2016.0521)
103
+ mini_portile2 (2.1.0)
104
+ minitest (5.10.2)
105
+ multi_json (1.12.1)
106
+ net-ssh (3.0.2)
107
+ nokogiri (1.7.2)
108
+ mini_portile2 (~> 2.1.0)
109
+ rack (1.6.8)
110
+ rack-test (0.6.3)
111
+ rack (>= 1.0)
112
+ rails (4.2.8)
113
+ actionmailer (= 4.2.8)
114
+ actionpack (= 4.2.8)
115
+ actionview (= 4.2.8)
116
+ activejob (= 4.2.8)
117
+ activemodel (= 4.2.8)
118
+ activerecord (= 4.2.8)
119
+ activesupport (= 4.2.8)
120
+ bundler (>= 1.3.0, < 2.0)
121
+ railties (= 4.2.8)
122
+ sprockets-rails
123
+ rails-deprecated_sanitizer (1.0.3)
124
+ activesupport (>= 4.2.0.alpha)
125
+ rails-dom-testing (1.0.8)
126
+ activesupport (>= 4.2.0.beta, < 5.0)
127
+ nokogiri (~> 1.6)
128
+ rails-deprecated_sanitizer (>= 1.0.1)
129
+ rails-html-sanitizer (1.0.3)
130
+ loofah (~> 2.0)
131
+ railties (4.2.8)
132
+ actionpack (= 4.2.8)
133
+ activesupport (= 4.2.8)
134
+ rake (>= 0.8.7)
135
+ thor (>= 0.18.1, < 2.0)
136
+ rake (12.0.0)
137
+ redcarpet (3.4.0)
138
+ rubyserial (0.4.0)
139
+ ffi (~> 1.9, >= 1.9.3)
140
+ sass (3.4.25)
141
+ sass-rails (5.0.6)
142
+ railties (>= 4.0.0, < 6)
143
+ sass (~> 3.1)
144
+ sprockets (>= 2.8, < 4.0)
145
+ sprockets-rails (>= 2.0, < 4.0)
146
+ tilt (>= 1.1, < 3)
147
+ shells (0.1.9)
148
+ net-ssh (~> 3.0.2)
149
+ rubyserial (~> 0.4.0)
150
+ spawnling (2.1.6)
151
+ sprockets (3.7.1)
152
+ concurrent-ruby (~> 1.0)
153
+ rack (> 1, < 3)
154
+ sprockets-rails (3.2.0)
155
+ actionpack (>= 4.0)
156
+ activesupport (>= 4.0)
157
+ sprockets (>= 3.0.0)
158
+ sqlite3 (1.3.13)
159
+ thor (0.19.4)
160
+ thread_safe (0.3.6)
161
+ tilt (2.0.7)
162
+ tiny_tds (1.3.0)
163
+ mini_portile2 (~> 2.0)
164
+ tzinfo (1.2.3)
165
+ thread_safe (~> 0.1)
166
+ uglifier (3.2.0)
167
+ execjs (>= 0.3.0, < 3)
168
+ web-console (3.3.0)
169
+ activemodel (>= 4.2)
170
+ debug_inspector
171
+ railties (>= 4.2)
172
+
173
+ PLATFORMS
174
+ ruby
175
+
176
+ DEPENDENCIES
177
+ activerecord-sqlserver-adapter (~> 4.2.18)
178
+ byebug
179
+ faker (~> 1.7.3)
180
+ incline!
181
+ sqlite3 (~> 1.3.13)
182
+ tiny_tds (~> 1.3.0)
183
+ web-console (~> 3.3.0)
184
+
185
+ BUNDLED WITH
186
+ 1.14.6
data/MIT-LICENSE ADDED
@@ -0,0 +1,20 @@
1
+ Copyright 2017 Beau Barker
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining
4
+ a copy of this software and associated documentation files (the
5
+ "Software"), to deal in the Software without restriction, including
6
+ without limitation the rights to use, copy, modify, merge, publish,
7
+ distribute, sublicense, and/or sell copies of the Software, and to
8
+ permit persons to whom the Software is furnished to do so, subject to
9
+ the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be
12
+ included in all copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.rdoc ADDED
@@ -0,0 +1,208 @@
1
+ = Incline
2
+
3
+ Rails is a great framework and is very general in design.
4
+ Inclines are railed devices designed to get from the bottom of a hill to the top. There are two left in Pittsburgh,
5
+ I can't speak for the rest of the world. The point is they are designed to do one thing and they do it pretty well.
6
+
7
+ This library builds on the Rails framework to quickly get to a certain point. That certain point is an application
8
+ with a fairly simple layout, built-in authentication and authorization, and quite a few helper methods bolted onto
9
+ the various Rails classes (e.g. - ActiveRecord::Base, ActionView::Base, ActionController::Base, etc).
10
+
11
+ The scaffold generator has also been updated to be more useful out of the box by scaffolding with bootstrap themed
12
+ views and the DataTables (https://datatables.net) library being used for the index views.
13
+
14
+ Incline is currently locked to Rails 4.2, specifically 4.2.8 or higher. It has not been tested against Rails 5.
15
+
16
+ == Installation
17
+
18
+ The easiest way to get started with Incline:
19
+ $ gem install incline
20
+ $ new_incline_app my_app
21
+
22
+ This will create an application depending on Incline, configure the application, generate a database, and initialize
23
+ a local git repository for the application.
24
+
25
+ You could also manually perform the necessary steps by creating a rails app and adding Incline to your Gemfile.
26
+ gem 'incline'
27
+
28
+ Followed by running bundle and then the 'incline:install' generator.
29
+ $ bundle
30
+ $ bundle exec rails generate incline:install
31
+
32
+ == Usage
33
+
34
+ Where to get started. If you use 'new_incline_app' or the 'incline:install' generator, your Rails app will now be
35
+ setup with a basic, yet powerful, security model. All users are either standard users or system admins. There must
36
+ always be at least one system admin. A system admin can promote other users to system admin or demote them back to
37
+ standard users. A system admin has automatic access to everything that does not require an anonymous user. Standard
38
+ users gain access through Access Groups. Users are defined in the Incline::User model.
39
+
40
+ Access Groups are completely customizable. You can create however many you want. Each access group can contain any
41
+ number of other access groups or users. Any user who is a member of an access group added to another access group is
42
+ also a member of the other access group. For instance. Group A includes Group B, so members of Group B are
43
+ automatically members of Group A. Access Groups are defined in the Incline::AccessGroup model.
44
+
45
+ The final part of the security model is the Action Security objects. Each routed action in the application has an
46
+ Action Security object. The object asks the controller for any hard settings for the action. The hard settings would
47
+ be 'allow_anon' (grants access to everyone), 'require_anon' (requires an anonymous user), and 'require_admin' (requires
48
+ a system admin). If any of the hard settings are flagged, 'require_admin' takes precedence, followed by 'require_anon'
49
+ and finally 'allow_anon'. Access Groups can be added to Action Security objects with no hard settings. Action
50
+ Security objects are defined in the Incline::ActionSecurity model.
51
+
52
+ class FirstController < ActionController::Base
53
+ allow_anon :index, :show
54
+ require_anon :new, :create
55
+ require_admin :edit, :update, :destroy
56
+ end
57
+
58
+ class SecondController < ActionController::Base
59
+ require_admin true
60
+ end
61
+
62
+ When a user requests an action, the controller will end up taking one of these 10 actions:
63
+
64
+ 1. If 'require_admin' is set and no user is logged in, redirect to login page.
65
+ 2. If 'require_admin' is set and a non-admin is logged in, redirect to root page with error.
66
+ 3. If 'require_admin' is set and an admin is logged in, grant access.
67
+ 4. If 'require_anon' is set and no user is logged in, grant access.
68
+ 5. If 'require_anon' is set and any user is logged in, redirect to root page with error.
69
+ 6. If 'allow_anon' is set for the action, grant access.
70
+ 7. If no user is logged in, redirect to login page.
71
+ 8. If no groups are assign to the action, grant access.
72
+ 9. If the user is a member of at least one group assigned to the action, grant access.
73
+ 10. Redirect to root page with error.
74
+
75
+ ---
76
+
77
+ There are ways to override this behavior, and the Incline::UsersController actually does by redefining the #valid_user?
78
+ method. The Incline::UsersController allows the user to review and edit their own details, and it allows system admins
79
+ to add new users. Without overriding this method, users would not be able to view or update their own details, and
80
+ system admins would not be able to add new users since they are obviously already logged in.
81
+
82
+ When #valid_user? or #authorize! are redefined by a controller, the Action Security model will take notice of that fact
83
+ and mark them as non-standard. Non-standard controllers will be treated the same when defining security, but may not
84
+ behave the same as standard controllers. Going back to the Incline::UsersController, it doesn't behave the way the
85
+ standard security model expects because of the exceptions created for a few actions.
86
+
87
+ If you do decide to redefine security for a controller, redefine #valid_user? and leave #authorize! alone unless you
88
+ have a good reason. At the end of your #valid_user? method, you should call super to allow the standard security
89
+ model to handle any non-exception cases. The #valid_user? method should return true or redirect as appropriate and
90
+ return false.
91
+
92
+ def valid_user?
93
+ action = params[:action].to_sym
94
+
95
+ # In order to delete resources, the user must be a member of 'super user' or 'can delete'.
96
+ if action == :destroy && !current_user.has_any_group?('super user', 'can delete')
97
+ redirect_to root_url
98
+ return false
99
+ end
100
+
101
+ # Members of the 'super user' group are granted access to all actions of this controller.
102
+ return true if current_user.has_any_group?('super user')
103
+
104
+ # Fall back on standard processing for everything else.
105
+ super
106
+ end
107
+
108
+ ---
109
+
110
+ So now you've seen how to setup security for your controllers and actions, how do you best access them? With a menu
111
+ of course. Two such files are included in any application that has had the 'incline:install' generator run.
112
+
113
+ [app/views/layouts/incline/_app_menu_anon.html.erb]
114
+ This file defines the menu made available to everyone. It is a standard ERB file and therefore can contain embedded
115
+ Ruby to customize the menu even more. For instance you may only want a link displayed to a resource if
116
+ current_user.anonymous? is true.
117
+
118
+ [app/views/layouts/incline/_app_menu_authenticated.html.erb]
119
+ This file defines the menu made available to users logged into the system. Just like the anonymous file, it is a
120
+ standard ERB file and you can use Ruby to customize the menu more.
121
+
122
+ ---
123
+
124
+ reCAPTCHA support is built into the library. To enable the support, you have to define the "recaptcha_public" and
125
+ "recaptcha_private" values to be your site key and secret key from Google. If these are both defined, the gem will
126
+ enable the reCAPTCHA functionality and force users to complete the challenges. If either of these are blank, the gem
127
+ disables the reCAPTCHA functionality and silently passes the challenges.
128
+
129
+ You can use reCAPTCHA in two ways. The first way is via a validated model attribute and then using the form builder
130
+ to include the necessary code in the form.
131
+
132
+ class MyModel < ActiveRecord::Base
133
+ attr_accessor :recaptcha_field
134
+ validates :recaptcha_field, 'incline/recaptcha' => true
135
+ ...
136
+ end
137
+
138
+ <%= form_for @my_model do |f| %>
139
+ ...
140
+ <%= f.recaptcha :recaptcha_field %>
141
+ <% end %>
142
+
143
+ Nice and simple.
144
+
145
+ The second way reCAPTCHA can be used is by explicitly including the challenge on a form and then explicitly checking
146
+ the result on submission.
147
+
148
+ <%= form_for @another_model do |f| %>
149
+ ...
150
+ <%= Incline::Recaptcha.add %>
151
+ <% end %>
152
+
153
+ def update
154
+ unless Incline::Recaptcha.verify(request)
155
+ @another_model.errors[:base] << 'You must complete the reCAPTCHA challenge.'
156
+ end
157
+ end
158
+
159
+ Still pretty simple.
160
+
161
+ ---
162
+
163
+ Email support is also built into the library. This is of course configuring email for use with SMTP. SMTP allows for
164
+ a more consistent experience across platforms, so I generally find myself adding SMTP configuration to an application.
165
+ Incline handles that configuration for you by reading from a simple to use 'email.yml' file. The default 'email.yml'
166
+ from the 'incline:install' generator includes all of the necessary configuration information and shows how to utilize
167
+ 'secrets.yml' to store the login credentials.
168
+ (The 'incline:install' generator also adds a line to '.gitignore' to exclude 'secrets.yml' from the git repo.)
169
+
170
+ For email, generally port 465 is used with the ssl parameter set to true and port 587 is used with start_tls parameter
171
+ set to true. It is not recommended to utilize SMTP without some form of encryption.
172
+
173
+ If for some reason you don't want to use the SMTP configuration support, simply delete the 'email.yml' file from
174
+ your configuration directory.
175
+
176
+ ---
177
+
178
+ Migrations and seeds from the Incline gem are included into your application automatically. They do not get copied into
179
+ your application and you should not copy them local since they may be overridden in the future. You shouldn't add onto
180
+ Incline models directly unless you are sure about what you are doing. A future Incline upgrade may conflict with fields
181
+ you add on. Instead of adding on, you may want to define a related model.
182
+
183
+ class CreateUserDetails < ActiveRecord::Migration
184
+ def change
185
+ create_table :user_details do |t|
186
+ t.integer :user_id, null: false
187
+ t.string :full_name
188
+ t.string :address1
189
+ t.string :address2
190
+ t.string :city
191
+ t.string :state
192
+ t.string :zip_code
193
+ t.string :phone_number
194
+ end
195
+ add_index :user_details, :user_id, :unique => true
196
+ end
197
+ end
198
+
199
+ class UserDetails < ActiveRecord::Base
200
+ belongs_to :user, class_name: 'Incline::User'
201
+
202
+ ::Incline::User.has_one :details, :class_name => 'UserDetail', :foreign_key => 'user_id', :dependent => :destroy
203
+ end
204
+
205
+
206
+ == License
207
+
208
+ This gem is released under the MIT license.
data/Rakefile ADDED
@@ -0,0 +1,37 @@
1
+ begin
2
+ require 'bundler/setup'
3
+ rescue LoadError
4
+ puts 'You must `gem install bundler` and `bundle install` to run rake tasks'
5
+ end
6
+
7
+ require 'rdoc/task'
8
+
9
+ RDoc::Task.new(:rdoc) do |rdoc|
10
+ rdoc.rdoc_dir = 'rdoc'
11
+ rdoc.title = 'Incline'
12
+ rdoc.options << '--line-numbers'
13
+ rdoc.rdoc_files.include('README.rdoc')
14
+ rdoc.rdoc_files.include('lib/**/*.rb')
15
+ end
16
+
17
+ APP_RAKEFILE = File.expand_path("../test/dummy/Rakefile", __FILE__)
18
+ load 'rails/tasks/engine.rake'
19
+
20
+
21
+ load 'rails/tasks/statistics.rake'
22
+
23
+
24
+
25
+ Bundler::GemHelper.install_tasks
26
+
27
+ require 'rake/testtask'
28
+
29
+ Rake::TestTask.new(:test) do |t|
30
+ t.libs << 'lib'
31
+ t.libs << 'test'
32
+ t.pattern = 'test/**/*_test.rb'
33
+ t.verbose = false
34
+ end
35
+
36
+
37
+ task default: :test
File without changes
File without changes
@@ -0,0 +1,181 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <svg
3
+ version="1.1"
4
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
5
+ xmlns:cc="http://creativecommons.org/ns#"
6
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
7
+ xmlns:svg="http://www.w3.org/2000/svg"
8
+ xmlns:xlink="http://www.w3.org/1999/xlink"
9
+ xmlns="http://www.w3.org/2000/svg"
10
+ width="250.56"
11
+ height="250.56"
12
+ viewBox="0, 0, 250.56, 250.56"
13
+ preserveAspectRatio="none"
14
+ id="svg2">
15
+ <defs
16
+ id="defs_2903A6EC"/>
17
+ <metadata
18
+ id="metadata7">
19
+ <rdf:RDF>
20
+ <cc:Work
21
+ rdf:about="">
22
+ <dc:format>image/svg+xml</dc:format>
23
+ <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage"/>
24
+ <dc:title></dc:title>
25
+ </cc:Work>
26
+ </rdf:RDF>
27
+ </metadata>
28
+ <g
29
+ id="layer_Paper"
30
+ style="fill:#000000;fill-opacity:1;stroke:#000000;stroke-opacity:1;fill-rule:nonzero;stroke-linecap:square;stroke-linejoin:miter;stroke-width:1;stroke-miterlimit:10">
31
+ <path
32
+ style="fill:#2400FF;stroke:none"
33
+ id="4BCF0CDB"
34
+ d="M159.091597222,18.36 C160.421064815,18.36 161.750532407,18.36 163.08,18.36 C189.72,18.36 216.36,45 216.36,71.64 C216.36,72.12 216.36,72.6 216.36,73.08 C216.36,99.72 189.72,126.36 163.08,126.36 C161.734618056,126.36 160.389236111,126.36 159.043854167,126.36
35
+ C158.901927083,126.36 158.76,126.218072917 158.76,126.076145833 C158.76,90.2812962963 158.76,54.4864467593 158.76,18.6915972222 C158.76,18.5257986111 158.925798611,18.36 159.091597222,18.36 z"/>
36
+ <path
37
+ style="fill:#2400FF;stroke:none"
38
+ id="FD5252EB"
39
+ d="M159.091597222,119.16 C162.821064815,119.16 166.550532407,119.16 170.28,119.16 C198.72,119.16 227.16,147.6 227.16,176.04 C227.16,176.52 227.16,177 227.16,177.48 C227.16,205.92 198.72,234.36 170.28,234.36
40
+ C166.534618056,234.36 162.789236111,234.36 159.043854167,234.36 C158.901927083,234.36 158.76,234.218072917 158.76,234.076145833 C158.76,195.881296296 158.76,157.686446759 158.76,119.491597222 C158.76,119.325798611 158.925798611,119.16 159.091597222,119.16
41
+ z"/>
42
+ <path
43
+ style="fill:none;stroke:#2400FF;stroke-width:3.6"
44
+ id="7E706A0C"
45
+ d="M19.8,1.8 C90.12,1.8 160.44,1.8 230.76,1.8 C239.76,1.8 248.76,10.8 248.76,19.8 C248.76,90.12 248.76,160.44 248.76,230.76 C248.76,239.76 239.76,248.76 230.76,248.76 C160.44,248.76 90.12,248.76 19.8,248.76
46
+ C10.8,248.76 1.8,239.76 1.8,230.76 C1.8,160.44 1.8,90.12 1.8,19.8 C1.8,10.8 10.8,1.8 19.8,1.8 z"/>
47
+ <rect
48
+ style="fill:#003CFF;stroke:none"
49
+ id="BA7610AC"
50
+ x="25.56"
51
+ y="18.36"
52
+ width="3.6"
53
+ height="216"/>
54
+ <rect
55
+ style="fill:#003CFF;stroke:none"
56
+ id="43594FCC"
57
+ x="31.32"
58
+ y="18.36"
59
+ width="2.16"
60
+ height="216"/>
61
+ <rect
62
+ style="fill:#003CFF;stroke:none"
63
+ id="111A00DC"
64
+ x="39.96"
65
+ y="18.36"
66
+ width="2.16"
67
+ height="216"/>
68
+ <rect
69
+ style="fill:#003CFF;stroke:none"
70
+ id="2BE5B0DC"
71
+ x="45"
72
+ y="18.36"
73
+ width="2.16"
74
+ height="216"/>
75
+ <rect
76
+ style="fill:#003CFF;stroke:none"
77
+ id="242361DC"
78
+ x="52.92"
79
+ y="18.36"
80
+ width="3.6"
81
+ height="216"/>
82
+ <rect
83
+ style="fill:#003CFF;stroke:none"
84
+ id="0B9402DC"
85
+ x="57.96"
86
+ y="18.36"
87
+ width="2.16"
88
+ height="216"/>
89
+ <rect
90
+ style="fill:#003CFF;stroke:none"
91
+ id="E51B82DC"
92
+ x="65.16"
93
+ y="18.36"
94
+ width="3.6"
95
+ height="216"/>
96
+ <rect
97
+ style="fill:#003CFF;stroke:none"
98
+ id="DE6733DC"
99
+ x="70.56"
100
+ y="18.36"
101
+ width="5.76"
102
+ height="216"/>
103
+ <rect
104
+ style="fill:#003CFF;stroke:none"
105
+ id="4BB8A3DC"
106
+ x="78.12"
107
+ y="18.36"
108
+ width="2.16"
109
+ height="216"/>
110
+ <rect
111
+ style="fill:#003CFF;stroke:none"
112
+ id="301134DC"
113
+ x="85.32"
114
+ y="18.36"
115
+ width="3.6"
116
+ height="216"/>
117
+ <rect
118
+ style="fill:#003CFF;stroke:none"
119
+ id="5492B4DC"
120
+ x="90.36"
121
+ y="18.36"
122
+ width="5.76"
123
+ height="216"/>
124
+ <rect
125
+ style="fill:#003CFF;stroke:none"
126
+ id="E72525DC"
127
+ x="101.16"
128
+ y="18.36"
129
+ width="2.16"
130
+ height="216"/>
131
+ <rect
132
+ style="fill:#003CFF;stroke:none"
133
+ id="390495DC"
134
+ x="104.76"
135
+ y="18.36"
136
+ width="3.6"
137
+ height="216"/>
138
+ <rect
139
+ style="fill:#003CFF;stroke:none"
140
+ id="65A516DC"
141
+ x="110.16"
142
+ y="18.36"
143
+ width="3.6"
144
+ height="216"/>
145
+ <rect
146
+ style="fill:#003CFF;stroke:none"
147
+ id="ACA986DC"
148
+ x="115.56"
149
+ y="18.36"
150
+ width="7.2"
151
+ height="216"/>
152
+ <rect
153
+ style="fill:#003CFF;stroke:none"
154
+ id="D941F6DC"
155
+ x="124.92"
156
+ y="18.36"
157
+ width="3.6"
158
+ height="216"/>
159
+ <rect
160
+ style="fill:#003CFF;stroke:none"
161
+ id="A1C6A7DC"
162
+ x="133.56"
163
+ y="18.36"
164
+ width="5.76"
165
+ height="216"/>
166
+ <rect
167
+ style="fill:#003CFF;stroke:none"
168
+ id="E57708DC"
169
+ x="140.76"
170
+ y="18.36"
171
+ width="2.16"
172
+ height="216"/>
173
+ <rect
174
+ style="fill:#003CFF;stroke:none"
175
+ id="662388DC"
176
+ x="144.36"
177
+ y="18.36"
178
+ width="3.6"
179
+ height="216"/>
180
+ </g>
181
+ </svg>
@@ -0,0 +1,11 @@
1
+
2
+ function activateClassedItems(base) {
3
+ if (base === undefined) base = $(document);
4
+ base.find('div.date').datepicker({ format: "mm/dd/yyyy", todayBtn: "linked", todayHighlight: true, clearBtn: true });
5
+ base.find('input.float').regexMask('float');
6
+ base.find('input.integer').regexMask('integer');
7
+ base.find('.double-scroll').doubleScroll({ onlyIfScroll: true, resetOnWindowResize: true });
8
+ base.find('select.select2').select2();
9
+ base.find('a.inline_action').inlineAction();
10
+ base.find('a.inline_form').inlineForm();
11
+ }