Compare commits

...

10 Commits

Author SHA1 Message Date
bterkuile 6f2193a5e5 Merge pull request #29 from bterkuile/dependabot/bundler/rack-3.2.6
Bump rack from 3.2.5 to 3.2.6
2026-04-02 23:10:11 +02:00
dependabot[bot] ced8976cc9 Bump rack from 3.2.5 to 3.2.6
Bumps [rack](https://github.com/rack/rack) from 3.2.5 to 3.2.6.
- [Release notes](https://github.com/rack/rack/releases)
- [Changelog](https://github.com/rack/rack/blob/main/CHANGELOG.md)
- [Commits](https://github.com/rack/rack/compare/v3.2.5...v3.2.6)

---
updated-dependencies:
- dependency-name: rack
  dependency-version: 3.2.6
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-04-02 18:59:13 +00:00
bterkuile 4efe7b5d5f Merge pull request #24 from bterkuile/dependabot/bundler/devise-5.0.3
Bump devise from 4.9.4 to 5.0.3
2026-03-19 19:19:41 -05:00
dependabot[bot] 80d136e595 Bump devise from 4.9.4 to 5.0.3
Bumps [devise](https://github.com/heartcombo/devise) from 4.9.4 to 5.0.3.
- [Release notes](https://github.com/heartcombo/devise/releases)
- [Changelog](https://github.com/heartcombo/devise/blob/main/CHANGELOG.md)
- [Commits](https://github.com/heartcombo/devise/compare/v4.9.4...v5.0.3)

---
updated-dependencies:
- dependency-name: devise
  dependency-version: 5.0.3
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-03-20 00:19:18 +00:00
bterkuile 30952dd9d6 Merge pull request #25 from bterkuile/dependabot/bundler/bcrypt-3.1.22
Bump bcrypt from 3.1.20 to 3.1.22
2026-03-19 19:16:38 -05:00
dependabot[bot] e04f379041 Bump bcrypt from 3.1.20 to 3.1.22
Bumps [bcrypt](https://github.com/bcrypt-ruby/bcrypt-ruby) from 3.1.20 to 3.1.22.
- [Release notes](https://github.com/bcrypt-ruby/bcrypt-ruby/releases)
- [Changelog](https://github.com/bcrypt-ruby/bcrypt-ruby/blob/master/CHANGELOG)
- [Commits](https://github.com/bcrypt-ruby/bcrypt-ruby/compare/v3.1.20...v3.1.22)

---
updated-dependencies:
- dependency-name: bcrypt
  dependency-version: 3.1.22
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-03-19 18:55:36 +00:00
bterkuile 1a1edf675b ensure return even if not found does not return tru 2026-02-08 20:02:27 -05:00
bterkuile 69a0291ab7 Forgot to commit long used code, see what happens 2026-02-04 14:25:50 -05:00
bterkuile 647cc38bad Better ruby3 forwarding for localization and have a default locale of en 2025-09-25 17:47:17 -05:00
bterkuile 557763877c update local bundle 2025-08-30 09:53:29 -05:00
7 changed files with 372 additions and 228 deletions
+2 -2
View File
@@ -21,10 +21,10 @@ group :assets do
gem 'momentjs-rails'
end
gem 'simply_stored' , github: 'bterkuile/simply_stored'
gem 'simply_stored' , github: 'bterkuile/simply_stored', branch: 'master'
#gem 'orm_adapter', github: 'bterkuile/orm_adapter'
gem 'devise'
gem 'devise_simply_stored', github: 'bterkuile/devise_simply_stored'
gem 'devise_simply_stored', github: 'bterkuile/devise_simply_stored', branch: 'master'
gem 'slim-rails'
gem 'paperclip', ['>= 3.4', '!= 4.3.0']
gem 'email_validator'
+343 -200
View File
@@ -1,13 +1,15 @@
GIT
remote: git://github.com/bterkuile/devise_simply_stored.git
revision: 86f93782c607958e7f99a6fdbae5566e17047273
remote: https://github.com/bterkuile/devise_simply_stored.git
revision: d40020669b22bbb14fa40dc4521b2f072eb96e84
branch: master
specs:
devise_simply_stored (0.3.0)
devise
GIT
remote: git://github.com/bterkuile/simply_stored.git
revision: 7633d88a62972cee6aea49d7d2a175bf07906236
remote: https://github.com/bterkuile/simply_stored.git
revision: 284607e973802ef46d7b47409bcf4beed7c0984c
branch: master
specs:
simply_stored (1.0.0)
activesupport
@@ -16,256 +18,397 @@ GIT
PATH
remote: .
specs:
cmtool (2.0.0)
cmtool (3.0.0)
ace-rails-ap
bourbon
email_validator
font-awesome-rails
foundation-rails
jquery-rails
momentjs-rails
paperclip
pickadate-rails
slim-rails
tinymce-rails
GEM
remote: http://rubygems.org/
specs:
ace-rails-ap (4.1.2)
actionmailer (4.2.7.1)
actionpack (= 4.2.7.1)
actionview (= 4.2.7.1)
activejob (= 4.2.7.1)
mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 1.0, >= 1.0.5)
actionpack (4.2.7.1)
actionview (= 4.2.7.1)
activesupport (= 4.2.7.1)
rack (~> 1.6)
rack-test (~> 0.6.2)
rails-dom-testing (~> 1.0, >= 1.0.5)
rails-html-sanitizer (~> 1.0, >= 1.0.2)
actionview (4.2.7.1)
activesupport (= 4.2.7.1)
ace-rails-ap (4.5)
actioncable (8.0.2.1)
actionpack (= 8.0.2.1)
activesupport (= 8.0.2.1)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
zeitwerk (~> 2.6)
actionmailbox (8.0.2.1)
actionpack (= 8.0.2.1)
activejob (= 8.0.2.1)
activerecord (= 8.0.2.1)
activestorage (= 8.0.2.1)
activesupport (= 8.0.2.1)
mail (>= 2.8.0)
actionmailer (8.0.2.1)
actionpack (= 8.0.2.1)
actionview (= 8.0.2.1)
activejob (= 8.0.2.1)
activesupport (= 8.0.2.1)
mail (>= 2.8.0)
rails-dom-testing (~> 2.2)
actionpack (8.0.2.1)
actionview (= 8.0.2.1)
activesupport (= 8.0.2.1)
nokogiri (>= 1.8.5)
rack (>= 2.2.4)
rack-session (>= 1.0.1)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.2)
rails-html-sanitizer (~> 1.6)
useragent (~> 0.16)
actiontext (8.0.2.1)
actionpack (= 8.0.2.1)
activerecord (= 8.0.2.1)
activestorage (= 8.0.2.1)
activesupport (= 8.0.2.1)
globalid (>= 0.6.0)
nokogiri (>= 1.8.5)
actionview (8.0.2.1)
activesupport (= 8.0.2.1)
builder (~> 3.1)
erubis (~> 2.7.0)
rails-dom-testing (~> 1.0, >= 1.0.5)
rails-html-sanitizer (~> 1.0, >= 1.0.2)
activejob (4.2.7.1)
activesupport (= 4.2.7.1)
globalid (>= 0.3.0)
activemodel (4.2.7.1)
activesupport (= 4.2.7.1)
builder (~> 3.1)
activerecord (4.2.7.1)
activemodel (= 4.2.7.1)
activesupport (= 4.2.7.1)
arel (~> 6.0)
activesupport (4.2.7.1)
i18n (~> 0.7)
json (~> 1.7, >= 1.7.7)
minitest (~> 5.1)
thread_safe (~> 0.3, >= 0.3.4)
tzinfo (~> 1.1)
addressable (2.5.0)
public_suffix (~> 2.0, >= 2.0.2)
arel (6.0.4)
bcrypt (3.1.11)
bourbon (4.3.2)
sass (~> 3.4)
thor (~> 0.19)
builder (3.2.3)
capybara (2.12.0)
erubi (~> 1.11)
rails-dom-testing (~> 2.2)
rails-html-sanitizer (~> 1.6)
activejob (8.0.2.1)
activesupport (= 8.0.2.1)
globalid (>= 0.3.6)
activemodel (8.0.2.1)
activesupport (= 8.0.2.1)
activerecord (8.0.2.1)
activemodel (= 8.0.2.1)
activesupport (= 8.0.2.1)
timeout (>= 0.4.0)
activestorage (8.0.2.1)
actionpack (= 8.0.2.1)
activejob (= 8.0.2.1)
activerecord (= 8.0.2.1)
activesupport (= 8.0.2.1)
marcel (~> 1.0)
activesupport (8.0.2.1)
base64
benchmark (>= 0.3)
bigdecimal
concurrent-ruby (~> 1.0, >= 1.3.1)
connection_pool (>= 2.2.5)
drb
i18n (>= 1.6, < 2)
logger (>= 1.4.2)
minitest (>= 5.1)
securerandom (>= 0.3)
tzinfo (~> 2.0, >= 2.0.5)
uri (>= 0.13.1)
addressable (2.8.7)
public_suffix (>= 2.0.2, < 7.0)
base64 (0.3.0)
bcrypt (3.1.22)
benchmark (0.5.0)
bigdecimal (4.0.1)
builder (3.3.0)
capybara (3.40.0)
addressable
mime-types (>= 1.16)
nokogiri (>= 1.3.3)
rack (>= 1.0.0)
rack-test (>= 0.5.4)
xpath (~> 2.0)
climate_control (0.1.0)
matrix
mini_mime (>= 0.1.3)
nokogiri (~> 1.11)
rack (>= 1.6.0)
rack-test (>= 0.6.3)
regexp_parser (>= 1.5, < 3.0)
xpath (~> 3.2)
childprocess (5.1.0)
logger (~> 1.5)
climate_control (0.2.0)
cliver (0.3.2)
cocaine (0.5.8)
climate_control (>= 0.0.3, < 1.0)
coderay (1.1.1)
coderay (1.1.3)
coffee-script (2.4.1)
coffee-script-source
execjs
coffee-script-source (1.12.2)
concurrent-ruby (1.0.4)
couch_potato (1.7.0)
activemodel (~> 4.0)
couchrest (~> 2.0.0.rc3)
json (~> 1.6)
concurrent-ruby (1.3.6)
connection_pool (3.0.2)
couch_potato (1.19.2)
activemodel (>= 7.2, < 8.1)
couchrest (~> 2.0.0)
json (~> 2.3)
couchrest (2.0.1)
httpclient (~> 2.8)
mime-types (>= 1.15)
multi_json (~> 1.7)
daemons (1.2.4)
devise (4.2.0)
crass (1.0.6)
daemons (1.4.1)
date (3.5.1)
devise (5.0.3)
bcrypt (~> 3.0)
orm_adapter (~> 0.1)
railties (>= 4.1.0, < 5.1)
railties (>= 7.0)
responders
warden (~> 1.2.3)
diff-lcs (1.3)
email_validator (1.6.0)
diff-lcs (1.6.2)
drb (2.2.3)
email_validator (2.2.4)
activemodel
erubis (2.7.0)
eventmachine (1.2.2)
execjs (2.7.0)
factory_girl (4.8.0)
erb (6.0.2)
erubi (1.13.1)
eventmachine (1.2.7)
execjs (2.10.0)
factory_girl (4.9.0)
activesupport (>= 3.0.0)
factory_girl_rails (4.8.0)
factory_girl (~> 4.8.0)
factory_girl_rails (4.9.0)
factory_girl (~> 4.9.0)
railties (>= 3.0.0)
font-awesome-rails (4.7.0.1)
railties (>= 3.2, < 5.1)
ffi (1.17.2-aarch64-linux-gnu)
ffi (1.17.2-aarch64-linux-musl)
ffi (1.17.2-arm-linux-gnu)
ffi (1.17.2-arm-linux-musl)
ffi (1.17.2-arm64-darwin)
ffi (1.17.2-x86_64-darwin)
ffi (1.17.2-x86_64-linux-gnu)
ffi (1.17.2-x86_64-linux-musl)
font-awesome-rails (4.7.0.9)
railties (>= 3.2, < 9.0)
foundation-rails (5.5.3.2)
railties (>= 3.1.0)
sass (>= 3.3.0, < 3.5)
globalid (0.3.7)
activesupport (>= 4.1.0)
httpclient (2.8.3)
i18n (0.8.0)
jquery-rails (4.2.2)
globalid (1.2.1)
activesupport (>= 6.1)
httpclient (2.9.0)
mutex_m
i18n (1.14.8)
concurrent-ruby (~> 1.0)
io-console (0.8.2)
irb (1.17.0)
pp (>= 0.6.0)
prism (>= 1.3.0)
rdoc (>= 4.0.0)
reline (>= 0.4.2)
jquery-rails (4.6.0)
rails-dom-testing (>= 1, < 3)
railties (>= 4.2.0)
thor (>= 0.14, < 2.0)
json (1.8.6)
launchy (2.4.3)
addressable (~> 2.3)
loofah (2.0.3)
nokogiri (>= 1.5.9)
mail (2.6.4)
mime-types (>= 1.16, < 4)
method_source (0.8.2)
mime-types (3.1)
mime-types-data (~> 3.2015)
mime-types-data (3.2016.0521)
mimemagic (0.3.2)
mini_portile2 (2.1.0)
minitest (5.10.1)
multi_json (1.12.1)
nokogiri (1.7.0.1)
mini_portile2 (~> 2.1.0)
json (2.13.2)
launchy (3.1.1)
addressable (~> 2.8)
childprocess (~> 5.0)
logger (~> 1.6)
logger (1.7.0)
loofah (2.25.1)
crass (~> 1.0.2)
nokogiri (>= 1.12.0)
mail (2.8.1)
mini_mime (>= 0.1.1)
net-imap
net-pop
net-smtp
marcel (1.0.4)
matrix (0.4.3)
method_source (1.1.0)
mime-types (3.7.0)
logger
mime-types-data (~> 3.2025, >= 3.2025.0507)
mime-types-data (3.2025.0826)
mimemagic (0.3.10)
nokogiri (~> 1)
rake
mini_mime (1.1.5)
minitest (6.0.2)
drb (~> 2.0)
prism (~> 1.5)
momentjs-rails (2.29.4.1)
railties (>= 3.1)
multi_json (1.17.0)
mutex_m (0.3.0)
net-imap (0.5.10)
date
net-protocol
net-pop (0.1.2)
net-protocol
net-protocol (0.2.2)
timeout
net-smtp (0.5.1)
net-protocol
nio4r (2.7.4)
nokogiri (1.19.2-aarch64-linux-gnu)
racc (~> 1.4)
nokogiri (1.19.2-aarch64-linux-musl)
racc (~> 1.4)
nokogiri (1.19.2-arm-linux-gnu)
racc (~> 1.4)
nokogiri (1.19.2-arm-linux-musl)
racc (~> 1.4)
nokogiri (1.19.2-arm64-darwin)
racc (~> 1.4)
nokogiri (1.19.2-x86_64-darwin)
racc (~> 1.4)
nokogiri (1.19.2-x86_64-linux-gnu)
racc (~> 1.4)
nokogiri (1.19.2-x86_64-linux-musl)
racc (~> 1.4)
orm_adapter (0.5.0)
paperclip (5.1.0)
paperclip (6.1.0)
activemodel (>= 4.2.0)
activesupport (>= 4.2.0)
cocaine (~> 0.5.5)
mime-types
mimemagic (~> 0.3.0)
pickadate-rails (3.5.6.0)
terrapin (~> 0.6.0)
pickadate-rails (3.5.6.1)
railties (>= 3.1.0)
poltergeist (1.13.0)
capybara (~> 2.1)
poltergeist (1.18.1)
capybara (>= 2.1, < 4)
cliver (~> 0.3.1)
websocket-driver (>= 0.2.0)
pry (0.10.4)
coderay (~> 1.1.0)
method_source (~> 0.8.1)
slop (~> 3.4)
pry-rails (0.3.5)
pry (>= 0.9.10)
public_suffix (2.0.5)
rack (1.6.5)
rack-test (0.6.3)
rack (>= 1.0)
rails (4.2.7.1)
actionmailer (= 4.2.7.1)
actionpack (= 4.2.7.1)
actionview (= 4.2.7.1)
activejob (= 4.2.7.1)
activemodel (= 4.2.7.1)
activerecord (= 4.2.7.1)
activesupport (= 4.2.7.1)
bundler (>= 1.3.0, < 2.0)
railties (= 4.2.7.1)
pp (0.6.3)
prettyprint
prettyprint (0.2.0)
prism (1.9.0)
pry (0.15.2)
coderay (~> 1.1)
method_source (~> 1.0)
pry-rails (0.3.11)
pry (>= 0.13.0)
psych (5.3.1)
date
stringio
public_suffix (6.0.2)
racc (1.8.1)
rack (3.2.6)
rack-session (2.1.1)
base64 (>= 0.1.0)
rack (>= 3.0.0)
rack-test (2.2.0)
rack (>= 1.3)
rackup (2.3.1)
rack (>= 3)
rails (8.0.2.1)
actioncable (= 8.0.2.1)
actionmailbox (= 8.0.2.1)
actionmailer (= 8.0.2.1)
actionpack (= 8.0.2.1)
actiontext (= 8.0.2.1)
actionview (= 8.0.2.1)
activejob (= 8.0.2.1)
activemodel (= 8.0.2.1)
activerecord (= 8.0.2.1)
activestorage (= 8.0.2.1)
activesupport (= 8.0.2.1)
bundler (>= 1.15.0)
railties (= 8.0.2.1)
rails-dom-testing (2.3.0)
activesupport (>= 5.0.0)
minitest
nokogiri (>= 1.6)
rails-html-sanitizer (1.7.0)
loofah (~> 2.25)
nokogiri (>= 1.15.7, != 1.16.7, != 1.16.6, != 1.16.5, != 1.16.4, != 1.16.3, != 1.16.2, != 1.16.1, != 1.16.0.rc1, != 1.16.0)
railties (8.0.2.1)
actionpack (= 8.0.2.1)
activesupport (= 8.0.2.1)
irb (~> 1.13)
rackup (>= 1.0.0)
rake (>= 12.2)
thor (~> 1.0, >= 1.2.2)
zeitwerk (~> 2.6)
rake (13.3.1)
rdoc (7.2.0)
erb
psych (>= 4.0.0)
tsort
regexp_parser (2.11.2)
reline (0.6.3)
io-console (~> 0.5)
responders (3.2.0)
actionpack (>= 7.0)
railties (>= 7.0)
rspec-core (3.13.5)
rspec-support (~> 3.13.0)
rspec-expectations (3.13.5)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.13.0)
rspec-its (2.0.0)
rspec-core (>= 3.13.0)
rspec-expectations (>= 3.13.0)
rspec-mocks (3.13.5)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.13.0)
rspec-rails (8.0.2)
actionpack (>= 7.2)
activesupport (>= 7.2)
railties (>= 7.2)
rspec-core (~> 3.13)
rspec-expectations (~> 3.13)
rspec-mocks (~> 3.13)
rspec-support (~> 3.13)
rspec-support (3.13.5)
sass (3.4.25)
sass-rails (6.0.0)
sassc-rails (~> 2.1, >= 2.1.1)
sassc (2.4.0)
ffi (~> 1.9)
sassc-rails (2.1.2)
railties (>= 4.0.0)
sassc (>= 2.0)
sprockets (> 3.0)
sprockets-rails
rails-deprecated_sanitizer (1.0.3)
activesupport (>= 4.2.0.alpha)
rails-dom-testing (1.0.8)
activesupport (>= 4.2.0.beta, < 5.0)
nokogiri (~> 1.6)
rails-deprecated_sanitizer (>= 1.0.1)
rails-html-sanitizer (1.0.3)
loofah (~> 2.0)
railties (4.2.7.1)
actionpack (= 4.2.7.1)
activesupport (= 4.2.7.1)
rake (>= 0.8.7)
thor (>= 0.18.1, < 2.0)
rake (12.0.0)
responders (2.3.0)
railties (>= 4.2.0, < 5.1)
rspec-core (3.5.4)
rspec-support (~> 3.5.0)
rspec-expectations (3.5.0)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.5.0)
rspec-its (1.2.0)
rspec-core (>= 3.0.0)
rspec-expectations (>= 3.0.0)
rspec-mocks (3.5.0)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.5.0)
rspec-rails (3.5.2)
actionpack (>= 3.0)
activesupport (>= 3.0)
railties (>= 3.0)
rspec-core (~> 3.5.0)
rspec-expectations (~> 3.5.0)
rspec-mocks (~> 3.5.0)
rspec-support (~> 3.5.0)
rspec-support (3.5.0)
sass (3.4.23)
sass-rails (5.0.6)
railties (>= 4.0.0, < 6)
sass (~> 3.1)
sprockets (>= 2.8, < 4.0)
sprockets-rails (>= 2.0, < 4.0)
tilt (>= 1.1, < 3)
slim (3.0.7)
temple (~> 0.7.6)
tilt (>= 1.3.3, < 2.1)
slim-rails (3.1.1)
tilt
securerandom (0.4.1)
slim (5.2.1)
temple (~> 0.10.0)
tilt (>= 2.1.0)
slim-rails (3.7.0)
actionpack (>= 3.1)
railties (>= 3.1)
slim (~> 3.0)
slop (3.6.0)
sprockets (3.7.1)
slim (>= 3.0, < 6.0, != 5.0.0)
sprockets (4.2.2)
concurrent-ruby (~> 1.0)
rack (> 1, < 3)
sprockets-rails (3.2.0)
actionpack (>= 4.0)
activesupport (>= 4.0)
logger
rack (>= 2.2.4, < 4)
sprockets-rails (3.5.2)
actionpack (>= 6.1)
activesupport (>= 6.1)
sprockets (>= 3.0.0)
temple (0.7.7)
thin (1.7.0)
stringio (3.2.0)
temple (0.10.4)
terrapin (0.6.0)
climate_control (>= 0.0.3, < 1.0)
thin (2.0.1)
daemons (~> 1.0, >= 1.0.9)
eventmachine (~> 1.0, >= 1.0.4)
rack (>= 1, < 3)
thor (0.19.4)
thread_safe (0.3.5)
tilt (2.0.6)
tinymce-rails (4.5.3)
railties (>= 3.1.1)
tzinfo (1.2.2)
thread_safe (~> 0.1)
warden (1.2.7)
rack (>= 1.0)
websocket-driver (0.6.5)
logger
rack (>= 1, < 4)
thor (1.5.0)
tilt (2.6.1)
timeout (0.4.3)
tsort (0.2.0)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
uri (1.1.1)
useragent (0.16.11)
warden (1.2.9)
rack (>= 2.0.9)
websocket-driver (0.8.0)
base64
websocket-extensions (>= 0.1.0)
websocket-extensions (0.1.2)
xpath (2.0.0)
nokogiri (~> 1.3)
websocket-extensions (0.1.5)
xpath (3.2.0)
nokogiri (~> 1.8)
zeitwerk (2.7.5)
PLATFORMS
ruby
aarch64-linux-gnu
aarch64-linux-musl
arm-linux-gnu
arm-linux-musl
arm64-darwin
x86_64-darwin
x86_64-linux-gnu
x86_64-linux-musl
DEPENDENCIES
ace-rails-ap
bourbon
capybara
cmtool!
coffee-script
@@ -277,18 +420,18 @@ DEPENDENCIES
foundation-rails (~> 5.5)
jquery-rails
launchy
momentjs-rails
paperclip (>= 3.4, != 4.3.0)
pickadate-rails
poltergeist
pry-rails
rails (~> 4.2.3)
rails (~> 8.0.1)
rspec-its
rspec-rails
sass-rails
simply_stored!
slim-rails
thin
tinymce-rails
BUNDLED WITH
1.13.6
2.7.1
+2 -2
View File
@@ -15,9 +15,9 @@ module Cmtool
end
# overwrite i18n l, to handle nil values
def l(*args)
def l(*args, **options)
return '' unless args.first
super(*args)
super(*args, **options)
end
def site_title
+1
View File
@@ -5,6 +5,7 @@ require 'cmtool/includes/user'
require 'cmtool/includes/page'
require 'cmtool/includes/pages_controller'
require 'cmtool/menu'
require 'email_validator'
module Cmtool
end
+22 -22
View File
@@ -13,28 +13,28 @@ require 'bourbon'
module Cmtool
class Engine < ::Rails::Engine
isolate_namespace Cmtool
initializer 'cmtool.build_menu', after: 'load_config_initializers' do |app|
require 'email_validator'
#require 'bourbon'
require 'slim-rails'
require 'paperclip'
require 'devise'
require 'devise_simply_stored'
require 'jquery-rails'
# require 'tinymce-rails'
require 'page' # app/models/page.rb
require 'user' # app/models/user.rb
require 'cmtool/yml_file'
require 'cmtool/keyword'
require 'cmtool/news'
require 'cmtool/faq'
require 'cmtool/quote'
require 'cmtool/contact_form'
require 'cmtool/newsletter_subscription'
require 'cmtool/image'
require 'cmtool/directory'
end
# initializer 'cmtool.build_menu', after: 'load_config_initializers' do |app|
# require 'email_validator'
# #require 'bourbon'
# require 'slim-rails'
# require 'paperclip'
# require 'devise'
# require 'devise_simply_stored'
# require 'jquery-rails'
# # require 'tinymce-rails'
#
# require 'page' # app/models/page.rb
# require 'user' # app/models/user.rb
# require 'cmtool/yml_file'
# require 'cmtool/keyword'
# require 'cmtool/news'
# require 'cmtool/faq'
# require 'cmtool/quote'
# require 'cmtool/contact_form'
# require 'cmtool/newsletter_subscription'
# require 'cmtool/image'
# require 'cmtool/directory'
# end
config.after_initialize do
Cmtool::Menu.register do
+1 -1
View File
@@ -66,7 +66,7 @@ module Cmtool
end
def locales
Rails.configuration.i18n.available_locales.presence || []
Rails.configuration.i18n.available_locales.presence || [:en]
end
def default_locale
+1 -1
View File
@@ -13,7 +13,7 @@ module Cmtool
# General catcher for pages
def show
@page = ::Page.find_by_name_and_locale(params[:name], I18n.locale.to_s)
not_found and return unless @page
return not_found unless @page
@sub_pages = [@page] + @page.children.select{|child| child.in_menu.present? }
template = "pages/#{@page.name}"