sunrise-cms 1.0.3 → 1.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/.gitignore +25 -0
- data/.rubocop.yml +87 -0
- data/.ruby-version +1 -0
- data/CHANGELOG.rdoc +11 -3
- data/Gemfile +49 -0
- data/README.md +6 -0
- data/Rakefile +4 -2
- data/app/assets/images/sunrise/icons/export.svg +4 -0
- data/app/assets/images/sunrise/icons/import.svg +5 -0
- data/app/assets/javascripts/sunrise/application.js +2 -3
- data/app/assets/javascripts/sunrise/jquery-ui-timepicker-addon.js +2143 -831
- data/app/assets/javascripts/sunrise/jquery.dialog.js.coffee +113 -40
- data/app/assets/javascripts/sunrise/jquery.editable.js.coffee +21 -21
- data/app/assets/javascripts/sunrise/manage.js.coffee +29 -28
- data/app/assets/stylesheets/sunrise/application.css +4 -4
- data/app/assets/stylesheets/sunrise/customize.css +7 -16
- data/app/assets/stylesheets/sunrise/jquery-ui-timepicker-addon.css +11 -0
- data/app/assets/stylesheets/sunrise/main.css +883 -606
- data/app/controllers/sunrise/activities_controller.rb +7 -5
- data/app/controllers/sunrise/application_controller.rb +17 -17
- data/app/controllers/sunrise/dashboard_controller.rb +6 -5
- data/app/controllers/sunrise/manager_controller.rb +145 -104
- data/app/controllers/sunrise/settings_controller.rb +5 -3
- data/app/helpers/sunrise/activities_helper.rb +8 -7
- data/app/helpers/sunrise/application_helper.rb +11 -9
- data/app/helpers/sunrise/dashboard_helper.rb +3 -1
- data/app/helpers/sunrise/manager_helper.rb +28 -27
- data/app/helpers/sunrise/structure_helper.rb +11 -8
- data/app/views/layouts/sunrise/application.html.erb +7 -6
- data/app/views/sunrise/manager/buttons/_export.html.erb +9 -2
- data/app/views/sunrise/manager/buttons/_import.html.erb +25 -0
- data/app/views/sunrise/manager/buttons/_sort.html.erb +3 -3
- data/app/views/sunrise/manager/tree/index.html.erb +1 -1
- data/config/locales/defaults/datetime.rb +7 -7
- data/config/locales/defaults/pluralize.rb +5 -3
- data/config/routes.rb +23 -20
- data/db/migrate/20111216144515_create_assets.rb +9 -7
- data/db/migrate/20111216144915_create_structures.rb +14 -12
- data/db/migrate/20111216145015_create_users.rb +20 -18
- data/db/migrate/20120611095315_create_settings.rb +7 -5
- data/lib/generators/sunrise/install_generator.rb +51 -49
- data/lib/generators/sunrise/templates/config/active_record/sunrise.rb +12 -10
- data/lib/generators/sunrise/templates/config/mongoid/sunrise.rb +14 -12
- data/lib/generators/sunrise/templates/config/seeds.rb +7 -7
- data/lib/generators/sunrise/templates/models/active_record/ability.rb +4 -3
- data/lib/generators/sunrise/templates/models/active_record/asset.rb +5 -3
- data/lib/generators/sunrise/templates/models/active_record/attachment_file.rb +4 -2
- data/lib/generators/sunrise/templates/models/active_record/avatar.rb +7 -5
- data/lib/generators/sunrise/templates/models/active_record/picture.rb +6 -4
- data/lib/generators/sunrise/templates/models/active_record/position_type.rb +5 -3
- data/lib/generators/sunrise/templates/models/active_record/role_type.rb +6 -4
- data/lib/generators/sunrise/templates/models/active_record/settings.rb +5 -3
- data/lib/generators/sunrise/templates/models/active_record/structure.rb +3 -1
- data/lib/generators/sunrise/templates/models/active_record/structure_type.rb +7 -5
- data/lib/generators/sunrise/templates/models/active_record/user.rb +5 -3
- data/lib/generators/sunrise/templates/models/mongoid/ability.rb +4 -3
- data/lib/generators/sunrise/templates/models/mongoid/asset.rb +18 -16
- data/lib/generators/sunrise/templates/models/mongoid/attachment_file.rb +4 -2
- data/lib/generators/sunrise/templates/models/mongoid/avatar.rb +7 -5
- data/lib/generators/sunrise/templates/models/mongoid/picture.rb +4 -2
- data/lib/generators/sunrise/templates/models/mongoid/position_type.rb +5 -3
- data/lib/generators/sunrise/templates/models/mongoid/role_type.rb +6 -4
- data/lib/generators/sunrise/templates/models/mongoid/settings.rb +9 -7
- data/lib/generators/sunrise/templates/models/mongoid/structure.rb +12 -10
- data/lib/generators/sunrise/templates/models/mongoid/structure_type.rb +7 -5
- data/lib/generators/sunrise/templates/models/mongoid/user.rb +37 -35
- data/lib/generators/sunrise/templates/models/sunrise/sunrise_navigation.rb +9 -7
- data/lib/generators/sunrise/templates/models/sunrise/sunrise_page.rb +5 -3
- data/lib/generators/sunrise/templates/models/sunrise/sunrise_structure.rb +10 -9
- data/lib/generators/sunrise/templates/models/sunrise/sunrise_user.rb +15 -13
- data/lib/generators/sunrise/templates/spec/controllers/pages_controller_spec.rb +12 -10
- data/lib/generators/sunrise/templates/spec/controllers/welcome_controller_spec.rb +8 -6
- data/lib/generators/sunrise/templates/spec/factories/structure_factory.rb +6 -5
- data/lib/generators/sunrise/templates/spec/factories/user_factory.rb +19 -18
- data/lib/generators/sunrise/templates/spec/spec_helper.rb +9 -7
- data/lib/generators/sunrise/templates/spec/support/helpers/controller_macros.rb +10 -9
- data/lib/generators/sunrise/templates/uploaders/attachment_file_uploader.rb +4 -2
- data/lib/generators/sunrise/templates/uploaders/avatar_uploader.rb +10 -7
- data/lib/generators/sunrise/templates/uploaders/picture_uploader.rb +9 -6
- data/lib/sunrise-cms.rb +2 -0
- data/lib/sunrise.rb +20 -13
- data/lib/sunrise/abstract_model.rb +103 -106
- data/lib/sunrise/carrierwave/base_uploader.rb +43 -46
- data/lib/sunrise/carrierwave/file_size_validator.rb +16 -11
- data/lib/sunrise/carrierwave/glue.rb +9 -9
- data/lib/sunrise/config.rb +14 -12
- data/lib/sunrise/config/association.rb +4 -3
- data/lib/sunrise/config/base.rb +15 -13
- data/lib/sunrise/config/export.rb +5 -3
- data/lib/sunrise/config/field.rb +26 -24
- data/lib/sunrise/config/form.rb +2 -0
- data/lib/sunrise/config/group.rb +9 -6
- data/lib/sunrise/config/has_fields.rb +6 -5
- data/lib/sunrise/config/has_groups.rb +4 -2
- data/lib/sunrise/config/index.rb +9 -7
- data/lib/sunrise/config/model.rb +20 -14
- data/lib/sunrise/config/navigation.rb +21 -19
- data/lib/sunrise/config/navigation_item.rb +7 -5
- data/lib/sunrise/config/nested_field.rb +13 -12
- data/lib/sunrise/config/page_presenter.rb +5 -2
- data/lib/sunrise/config/show.rb +2 -0
- data/lib/sunrise/core_ext.rb +2 -0
- data/lib/sunrise/core_ext/i18n.rb +9 -9
- data/lib/sunrise/core_ext/string.rb +4 -2
- data/lib/sunrise/engine.rb +22 -16
- data/lib/sunrise/hooks/adapters/active_record.rb +3 -1
- data/lib/sunrise/hooks/adapters/mongoid.rb +4 -2
- data/lib/sunrise/models/ability.rb +12 -10
- data/lib/sunrise/models/asset.rb +43 -43
- data/lib/sunrise/models/position_type.rb +7 -6
- data/lib/sunrise/models/role_type.rb +8 -7
- data/lib/sunrise/models/structure.rb +27 -28
- data/lib/sunrise/models/structure_type.rb +7 -6
- data/lib/sunrise/models/user.rb +39 -37
- data/lib/sunrise/utils.rb +16 -17
- data/lib/sunrise/utils/csv_document.rb +23 -23
- data/lib/sunrise/utils/eval_helpers.rb +41 -39
- data/lib/sunrise/utils/search_wrapper.rb +8 -7
- data/lib/sunrise/utils/transliteration.rb +42 -41
- data/lib/sunrise/version.rb +3 -1
- data/lib/sunrise/views/date_time_input.rb +19 -17
- data/lib/sunrise/views/form_builder.rb +15 -13
- data/lib/sunrise/views/helper.rb +32 -32
- data/lib/sunrise/views/search_wrapper.rb +5 -3
- data/lib/tasks/assets.rake +11 -9
- data/sunrise-cms.gemspec +50 -0
- metadata +85 -596
- data/spec/controllers/sunrise/activities_controller_spec.rb +0 -33
- data/spec/controllers/sunrise/manager_controller_spec.rb +0 -64
- data/spec/controllers/sunrise/settings_controller_spec.rb +0 -45
- data/spec/dummy/Rakefile +0 -7
- data/spec/dummy/app/assets/javascripts/application.js +0 -9
- data/spec/dummy/app/assets/javascripts/sunrise/plugins.js +0 -0
- data/spec/dummy/app/assets/javascripts/welcome.js +0 -2
- data/spec/dummy/app/assets/stylesheets/application.css +0 -7
- data/spec/dummy/app/assets/stylesheets/sunrise/plugins.css +0 -0
- data/spec/dummy/app/assets/stylesheets/welcome.css +0 -4
- data/spec/dummy/app/controllers/application_controller.rb +0 -3
- data/spec/dummy/app/controllers/welcome_controller.rb +0 -5
- data/spec/dummy/app/helpers/application_helper.rb +0 -12
- data/spec/dummy/app/helpers/welcome_helper.rb +0 -2
- data/spec/dummy/app/models/active_record/post.rb +0 -18
- data/spec/dummy/app/models/mongoid/post.rb +0 -27
- data/spec/dummy/app/sunrise/sunrise_post.rb +0 -34
- data/spec/dummy/app/views/layouts/application.html.erb +0 -20
- data/spec/dummy/app/views/public_activity/post/_create.html.erb +0 -5
- data/spec/dummy/app/views/public_activity/post/_destroy.html.erb +0 -5
- data/spec/dummy/app/views/public_activity/post/_update.html.erb +0 -5
- data/spec/dummy/app/views/sunrise/manager/users/thumbs/_record.html.erb +0 -34
- data/spec/dummy/app/views/welcome/index.html.erb +0 -2
- data/spec/dummy/config.ru +0 -4
- data/spec/dummy/config/application.rb +0 -55
- data/spec/dummy/config/boot.rb +0 -10
- data/spec/dummy/config/database.yml +0 -42
- data/spec/dummy/config/database.yml.sample +0 -34
- data/spec/dummy/config/environment.rb +0 -5
- data/spec/dummy/config/environments/development.rb +0 -33
- data/spec/dummy/config/environments/production.rb +0 -66
- data/spec/dummy/config/environments/test.rb +0 -41
- data/spec/dummy/config/initializers/backtrace_silencers.rb +0 -7
- data/spec/dummy/config/initializers/devise.rb +0 -216
- data/spec/dummy/config/initializers/inflections.rb +0 -10
- data/spec/dummy/config/initializers/mime_types.rb +0 -5
- data/spec/dummy/config/initializers/secret_token.rb +0 -7
- data/spec/dummy/config/initializers/session_store.rb +0 -8
- data/spec/dummy/config/initializers/sunrise.rb +0 -51
- data/spec/dummy/config/initializers/wrap_parameters.rb +0 -14
- data/spec/dummy/config/locales/en.yml +0 -5
- data/spec/dummy/config/mongoid.yml +0 -80
- data/spec/dummy/config/routes.rb +0 -10
- data/spec/dummy/db/migrate/20111227111941_install_acts_as_audited.rb +0 -28
- data/spec/dummy/db/migrate/20111227143901_create_page_parts.rb +0 -20
- data/spec/dummy/db/migrate/20111228152051_create_posts.rb +0 -14
- data/spec/dummy/db/migrate/20120105114018_create_meta_tags.rb +0 -21
- data/spec/dummy/db/migrate/20130214090723_create_activities.rb +0 -23
- data/spec/dummy/db/schema.rb +0 -90
- data/spec/dummy/log/test.log +0 -235
- data/spec/dummy/public/404.html +0 -26
- data/spec/dummy/public/422.html +0 -26
- data/spec/dummy/public/500.html +0 -26
- data/spec/dummy/public/favicon.ico +0 -0
- data/spec/dummy/script/rails +0 -6
- data/spec/dummy/tmp/cache/696/1F0/settings%3Ato_key +0 -1
- data/spec/dummy/tmp/cache/87C/5D0/settings%3Apersisted%3F +0 -1
- data/spec/dummy/tmp/cache/91C/830/settings%3Asome_setting +0 -1
- data/spec/dummy/tmp/cache/94E/D10/settings%3Asome_setting2 +0 -1
- data/spec/dummy/tmp/cache/assets/test/sass/f4a02ee710d6db0936c29533f2166c1526a55a9e/select2.scssc +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/03bae0b322a9c8706915fdb4f8d50961 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/0a4412d6feb107cf35e452cc82a01134 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/0c538631f0f094ca39bdb1448da8a4bc +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/0c94e795dfbbbf3599fdf312aeb577b9 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/0e7270936d642e566d747ab335c44ec2 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/0f894abd40c0b6114a9dff3a0599af7e +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/0fdc292bf2b2ddb2d0bf079950c8e770 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/10bb80e2753b3d1716765b02ad9a2db3 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/1349c61c2b491567c1632fcae44110a0 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/13e20c0d57b7b851a7f025f5606f833f +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/146ce2f3522fd98d4a8a1501f16c7092 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/172c139e25cc08516d5a8c72c777dd4d +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/18b64b11b8b00cc21a396da25a5ff156 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/197d8d604ec08a638b656e053944b734 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/1b73ae25962d8ff98f9f008b73c64bf4 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/1bdb903463fe67323dbadb0f78337c70 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/1ea532f332f1ff667097010cda704c99 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/20215d59350863282208d478ea94cf08 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/212fc15df4fd708ebdef5bd3be2191c1 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/256dcb01e7f35659d770584fd71a85d2 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/27ec6453d976c5e273e6f2c25830492c +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/3006732de695a5dfe249dcbf6852b543 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/3008328e1cba59ad00ac79ac20275f17 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/31ffcb9d2aba762160a2f4341e5cfd50 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/32ae3cda2e7c692fc9711ab76fcf1c62 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/35948a84ebda6147e5e5b67191ae37d8 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/37766ae8287a873cb196a187f3253e66 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/37b44bd55598f75d532d9edbe8c98336 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/383908afbabb6096b774ab7c1856a102 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/38611f05ed0bf72a4755c136796ff5d4 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/3b99bacd5915b4ff7fb2664bc2aa30d0 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/443ca9dc693ccf91d6e1cecaffe0fa9a +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/45c759123f4f6b42cdcff44b446655a5 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/4ca01587005a9b895bca383881bec87d +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/4cffdba2a7aac80c1765e060b152b382 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/4d38783b41d7c000fed2419b5173f87a +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/51fe2df168cee49df9d4136f59c87872 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/564db16c8d964c3505bfca526e3fccf2 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/56e5bd2f3c94d7a9d0da7c4e05c7ad78 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/5807e61754ed8b16702f6ad7ba34d439 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/593d990734170367188181754939b317 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/5a44970074ecbfeae2cc9798ed7da7aa +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/5e7901fbee32b66040fd6376a8c981d8 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/5ecbfe03cab317594d2bc1c6866d26db +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/609ce9936a503352d73f954f68be7f81 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/65224b6e799d399f4e6cf4bf98155de2 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/6a1e72555b75237fffccb5de8937b4d4 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/6a8187f5c6f2e115d1a1c21ca2ec81a0 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/6c9a2f7ab6f8d1f8e3e4cf1d7d6cc68a +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/6f4f668f70fb14b2132289fed6718f0e +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/727e0f830601f307d4c8b9a76e464c1a +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/749bd767d6654c80265f5ca0959dc8e1 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/7a92952d5fff10f09ce91b852d6a744f +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/7ad564910e515e335bb008989a97efb7 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/7b55037b89f2debe558b43fe7542e409 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/7bb04b7318793726b5414daaa4f049d4 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/7c5f37d1af8a5557b67d6ffb8afcc2b5 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/7f5092f53db371ea56be62557677a506 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/7f9ced6d264f71631c80df15194abf4d +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/80870efa2a2ddb1de325c224daff5712 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/831e225c0e792be993a1d1dc58f20e54 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/83f98047f864c578534b34068cb015e0 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/84361af51e20dcfad7fae0f32f284ab7 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/894aeaae9cc8483fa9f7a5146ff6ff6f +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/89567cbb5e7770a065e88360dcd02833 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/89a5be65dc0d00fa22be4375c029d69c +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/8bf0319a2b612416dfde2d3b939dbf99 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/8cfeb6443a5f7398e67010a202ee2de2 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/8e3769f6378278754105f0924e6dd1ff +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/96c321f84bd796096692021bc4a87eed +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/97e875e2282fba5939cf71198faab1f0 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/9911ee0fc41f519a1c4faa7912547cce +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/9ac84ed11232b2f7fc9f80c18844abc8 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/9ba0cab624f25b68f79447e62fbc6112 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/9e9edfa954375fd0cc6498f70b883e8e +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/a3863764f2fbc185e0d2ea584c7e2174 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/a4c4a00b0d2b8334de3ee3169064adad +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/a744e8f2a7ce02e7af9784f40c711ed5 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/a78a33e8cea959257da93b3e67786300 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/a9956bd25bbe4c811a1a758f71aec748 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/aa4822def20c419f0e50e2a38e73a1df +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/aaa24da6bd0fcf694077519e189b7392 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/b0493d9dbe3afb3268b7ffce2b87bf78 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/b2c398b7a51a65be12ba944bdea13415 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/b81381e4a978aa69cc2ab1f892a40e97 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/b82707486d5133da748e4382c62de995 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/bb83cb3c179681d65c77a41e98f1c70f +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/bbc50f2009705d8fd7b91330bc24dcb8 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/bcb7548b203cc2c5a484ef7649911c2d +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/becade26fead85d486f136be49b45e23 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/bfc0fef30976427a03ddccb1ce78d6e7 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c0dd93a468e038b3653ed4d28874e0cb +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c1d2340cbfe5e80d388f95e7a08698d9 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c25afdb537c84a18bd62fc782164d298 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c3dc3ada4560805584739bfe7c2b24d9 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c4dc50a79ec929d33d9e2835d1926fd9 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c5f990ee58d3727faeb4cfd3f5667e8a +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/c622effcf1aa225bf2920d2b63ca525c +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/d09dc20f2dc66183aa23ce1fd8fc9f2c +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/d60bdefb444e91b75e4cc2f3fc49228b +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/d7c40ebee2fb9471bab352337570ba40 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/d9bc94e1e0cc114986f8760bc4eb42ce +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/da4488b32bd6fb75c655a077956c9034 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/daeb51b1ca3de2a1f2146dea431249d3 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/dd0e13880601ea049b7c6d8c76ea535f +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/dd15d7b9860a8a187c4a6c167dc56547 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/dd8ed9b0203321fd815ba48a5867620e +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/e1e036b04a3a20b2fb589420ad03b926 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/e4f46080338c0c52e3933999a7f8106d +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/e59a3c2ff941e0fdc7987168580bf4cc +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/e6cfe2e09e34ec2b24494a74eed5243a +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/e8e088454cc6f38324bd168e299cf08f +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/e949207f9e9578cfd48ab90bb82ea384 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/ee5a41236d43159aac87f9224a0bcfb8 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/ef5f76363cd723089ce62b8c207415a4 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/f2de4855fd4840abb2f6e80afee5f4ed +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/f5165c4d7cee0e7cb99bc069fd4c09b9 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/f660938bc4a80358883ba6c576e1dd13 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/f7379cc2d3a2fc4b87d64c68d2d8684f +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/f81b83e98592ff24dd8518985baa48cd +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/f94b13174ed1cc7f087a66c0094ef4cf +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/f975cba8c490022ddfc45bab0b512879 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/face6eb5e3ee8802296bdc38e5704d72 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/fc9155176668e1a56a5ca3843febe3c3 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/fd7e46e0b42a510b40f17d1f1bacf80e +0 -0
- data/spec/factories/asset_factory.rb +0 -21
- data/spec/factories/files/rails.png +0 -0
- data/spec/factories/files/silicon_valley.jpg +0 -0
- data/spec/factories/page_factory.rb +0 -10
- data/spec/factories/post_factory.rb +0 -9
- data/spec/factories/structure_factory.rb +0 -22
- data/spec/factories/user_factory.rb +0 -49
- data/spec/generators/install_generator_spec.rb +0 -55
- data/spec/models/avatar_spec.rb +0 -138
- data/spec/models/i18n_backend.rb +0 -30
- data/spec/models/structure_spec.rb +0 -120
- data/spec/models/sunrise/abstract_model_spec.rb +0 -88
- data/spec/models/sunrise/carrierwave/picture_uploader_spec.rb +0 -49
- data/spec/models/sunrise/search_wrapper_spec.rb +0 -21
- data/spec/models/user_spec.rb +0 -63
- data/spec/orm/active_record.rb +0 -5
- data/spec/orm/kaminari/active_record.rb +0 -18
- data/spec/orm/kaminari/mongoid.rb +0 -20
- data/spec/orm/mongoid.rb +0 -15
- data/spec/requests/activities_spec.rb +0 -41
- data/spec/requests/dashboard_spec.rb +0 -35
- data/spec/requests/manager/default/create_spec.rb +0 -43
- data/spec/requests/manager/default/destroy_spec.rb +0 -36
- data/spec/requests/manager/default/edit_spec.rb +0 -72
- data/spec/requests/manager/default/export_spec.rb +0 -121
- data/spec/requests/manager/default/index_spec.rb +0 -67
- data/spec/requests/manager/default/new_spec.rb +0 -59
- data/spec/requests/manager/default/show_spec.rb +0 -41
- data/spec/requests/manager/default/update_spec.rb +0 -73
- data/spec/requests/manager/many/create_spec.rb +0 -52
- data/spec/requests/manager/many/destroy_spec.rb +0 -41
- data/spec/requests/manager/many/edit_spec.rb +0 -43
- data/spec/requests/manager/many/index_spec.rb +0 -54
- data/spec/requests/manager/many/new_spec.rb +0 -40
- data/spec/requests/manager/many/update_spec.rb +0 -55
- data/spec/spec_helper.rb +0 -90
- data/spec/sunrise_spec.rb +0 -29
- data/spec/support/helpers/controller_helper.rb +0 -27
- data/spec/support/helpers/controller_macros.rb +0 -40
- data/spec/support/hooks/structure.rb +0 -5
@@ -1,10 +0,0 @@
|
|
1
|
-
# Be sure to restart your server when you modify this file.
|
2
|
-
|
3
|
-
# Add new inflection rules using the following format
|
4
|
-
# (all these examples are active by default):
|
5
|
-
# ActiveSupport::Inflector.inflections do |inflect|
|
6
|
-
# inflect.plural /^(ox)$/i, '\1en'
|
7
|
-
# inflect.singular /^(ox)en/i, '\1'
|
8
|
-
# inflect.irregular 'person', 'people'
|
9
|
-
# inflect.uncountable %w( fish sheep )
|
10
|
-
# end
|
@@ -1,7 +0,0 @@
|
|
1
|
-
# Be sure to restart your server when you modify this file.
|
2
|
-
|
3
|
-
# Your secret key for verifying the integrity of signed cookies.
|
4
|
-
# If you change this key, all old signed cookies will become invalid!
|
5
|
-
# Make sure the secret is at least 30 characters and all random,
|
6
|
-
# no regular words or you'll be exposed to dictionary attacks.
|
7
|
-
Dummy::Application.config.secret_token = '0f00ace9575b61b2ab24d35217b9c0632cad1dba5e38455b7e8529a0fafa13b3fba539786d70cb30019795bf9debe8ffa75d9e32fcf7cfde6d910b28f5659618'
|
@@ -1,8 +0,0 @@
|
|
1
|
-
# Be sure to restart your server when you modify this file.
|
2
|
-
|
3
|
-
Dummy::Application.config.session_store :cookie_store, key: '_dummy_session'
|
4
|
-
|
5
|
-
# Use the database for sessions instead of the cookie-based default,
|
6
|
-
# which shouldn't be used to store highly confidential information
|
7
|
-
# (create the session table with "rails generate session_migration")
|
8
|
-
# Dummy::Application.config.session_store :active_record_store
|
@@ -1,51 +0,0 @@
|
|
1
|
-
require 'meta_manager/orm/active_record'
|
2
|
-
require 'page_parts/orm/active_record'
|
3
|
-
|
4
|
-
# Use this hook to configure sunrise
|
5
|
-
Sunrise.setup do |config|
|
6
|
-
# Paginate records per page (default: 25)
|
7
|
-
# config.default_items_per_page = 25
|
8
|
-
|
9
|
-
# Display audits events on dashboard (default: 50)
|
10
|
-
# config.activities_per_page = 50
|
11
|
-
|
12
|
-
# By default show latest first (default: :desc)
|
13
|
-
# config.default_sort_mode = :desc
|
14
|
-
|
15
|
-
# The display for a model instance (i.e. a single database record).
|
16
|
-
# config.label_methods = [:title, :name]
|
17
|
-
|
18
|
-
# Defailt list template view (default: "thumbs")
|
19
|
-
# config.default_list_view = "thumbs"
|
20
|
-
|
21
|
-
# Avariable lists views (default: [:list, :thumbs, :table])
|
22
|
-
# config.available_list_view = [:list, :thumbs, :table]
|
23
|
-
|
24
|
-
# Defailt list template view (default: "sort_order")
|
25
|
-
# config.sort_column = "sort_order"
|
26
|
-
|
27
|
-
# Find template before rendering (default: true)
|
28
|
-
# config.scoped_views = true
|
29
|
-
|
30
|
-
# Set available locales in app (default: [])
|
31
|
-
# config.available_locales = []
|
32
|
-
|
33
|
-
# Set transliteration for babosa gem
|
34
|
-
# more info here: https://github.com/norman/babosa (default: :russian)
|
35
|
-
# config.transliteration = :russian
|
36
|
-
|
37
|
-
# Set list toolbar buttons (default: [:delete, :edit, :new, :sort, :export])
|
38
|
-
# config.default_toolbar_buttons = [:delete, :edit, :new, :sort, :export]
|
39
|
-
|
40
|
-
# Lists the formats that should be treated as navigational (default: [:html, :json])
|
41
|
-
# config.navigational_formats = [:html, :json]
|
42
|
-
end
|
43
|
-
|
44
|
-
PublicActivity::Config.set do
|
45
|
-
orm :active_record
|
46
|
-
end
|
47
|
-
|
48
|
-
#if Settings.table_exists?
|
49
|
-
# Settings.defaults[:some_setting] = "value"
|
50
|
-
# Settings.defaults[:some_setting2] = "value2"
|
51
|
-
#end
|
@@ -1,14 +0,0 @@
|
|
1
|
-
# Be sure to restart your server when you modify this file.
|
2
|
-
#
|
3
|
-
# This file contains settings for ActionController::ParamsWrapper which
|
4
|
-
# is enabled by default.
|
5
|
-
|
6
|
-
# Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array.
|
7
|
-
ActiveSupport.on_load(:action_controller) do
|
8
|
-
wrap_parameters format: [:json]
|
9
|
-
end
|
10
|
-
|
11
|
-
# Disable root element in JSON by default.
|
12
|
-
ActiveSupport.on_load(:active_record) do
|
13
|
-
self.include_root_in_json = false
|
14
|
-
end
|
@@ -1,80 +0,0 @@
|
|
1
|
-
development:
|
2
|
-
# Configure available database sessions. (required)
|
3
|
-
sessions:
|
4
|
-
# Defines the default session. (required)
|
5
|
-
default:
|
6
|
-
# Defines the name of the default database that Mongoid can connect to.
|
7
|
-
# (required).
|
8
|
-
database: sunrise_dummy_development
|
9
|
-
# Provides the hosts the default session can connect to. Must be an array
|
10
|
-
# of host:port pairs. (required)
|
11
|
-
hosts:
|
12
|
-
- localhost:27017
|
13
|
-
options:
|
14
|
-
# Change whether the session persists in safe mode by default.
|
15
|
-
# (default: false)
|
16
|
-
# safe: false
|
17
|
-
|
18
|
-
# Change the default consistency model to :eventual or :strong.
|
19
|
-
# :eventual will send reads to secondaries, :strong sends everything
|
20
|
-
# to master. (default: :eventual)
|
21
|
-
# consistency: :eventual
|
22
|
-
|
23
|
-
# How many times Moped should attempt to retry an operation after
|
24
|
-
# failure. (default: 30)
|
25
|
-
# max_retries: 30
|
26
|
-
|
27
|
-
# The time in seconds that Moped should wait before retrying an
|
28
|
-
# operation on failure. (default: 1)
|
29
|
-
# retry_interval: 1
|
30
|
-
# Configure Mongoid specific options. (optional)
|
31
|
-
options:
|
32
|
-
# Configuration for whether or not to allow access to fields that do
|
33
|
-
# not have a field definition on the model. (default: true)
|
34
|
-
# allow_dynamic_fields: true
|
35
|
-
|
36
|
-
# Enable the identity map, needed for eager loading. (default: false)
|
37
|
-
# identity_map_enabled: false
|
38
|
-
|
39
|
-
# Includes the root model name in json serialization. (default: false)
|
40
|
-
# include_root_in_json: false
|
41
|
-
|
42
|
-
# Include the _type field in serializaion. (default: false)
|
43
|
-
# include_type_for_serialization: false
|
44
|
-
|
45
|
-
# Preload all models in development, needed when models use
|
46
|
-
# inheritance. (default: false)
|
47
|
-
# preload_models: false
|
48
|
-
|
49
|
-
# Protect id and type from mass assignment. (default: true)
|
50
|
-
# protect_sensitive_fields: true
|
51
|
-
|
52
|
-
# Raise an error when performing a #find and the document is not found.
|
53
|
-
# (default: true)
|
54
|
-
# raise_not_found_error: true
|
55
|
-
|
56
|
-
# Raise an error when defining a scope with the same name as an
|
57
|
-
# existing method. (default: false)
|
58
|
-
# scope_overwrite_exception: false
|
59
|
-
|
60
|
-
# Skip the database version check, used when connecting to a db without
|
61
|
-
# admin access. (default: false)
|
62
|
-
# skip_version_check: false
|
63
|
-
|
64
|
-
# User Active Support's time zone in conversions. (default: true)
|
65
|
-
# use_activesupport_time_zone: true
|
66
|
-
|
67
|
-
# Ensure all times are UTC in the app side. (default: false)
|
68
|
-
# use_utc: false
|
69
|
-
test:
|
70
|
-
sessions:
|
71
|
-
default:
|
72
|
-
database: sunrise_dummy_test
|
73
|
-
hosts:
|
74
|
-
- localhost:27017
|
75
|
-
options:
|
76
|
-
consistency: :strong
|
77
|
-
# In the test environment we lower the retries and retry interval to
|
78
|
-
# low amounts for fast failures.
|
79
|
-
max_retries: 1
|
80
|
-
retry_interval: 0
|
data/spec/dummy/config/routes.rb
DELETED
@@ -1,28 +0,0 @@
|
|
1
|
-
class InstallActsAsAudited < ActiveRecord::Migration
|
2
|
-
def self.up
|
3
|
-
create_table :audits, :force => true do |t|
|
4
|
-
t.column :auditable_id, :integer
|
5
|
-
t.column :auditable_type, :string
|
6
|
-
t.column :associated_id, :integer
|
7
|
-
t.column :associated_type, :string
|
8
|
-
t.column :user_id, :integer
|
9
|
-
t.column :user_type, :string
|
10
|
-
t.column :username, :string
|
11
|
-
t.column :action, :string
|
12
|
-
t.column :audited_changes, :text
|
13
|
-
t.column :version, :integer, :default => 0
|
14
|
-
t.column :comment, :string
|
15
|
-
t.column :remote_address, :string
|
16
|
-
t.column :created_at, :datetime
|
17
|
-
end
|
18
|
-
|
19
|
-
add_index :audits, [:auditable_id, :auditable_type], :name => 'auditable_index'
|
20
|
-
add_index :audits, [:associated_id, :associated_type], :name => 'associated_index'
|
21
|
-
add_index :audits, [:user_id, :user_type], :name => 'user_index'
|
22
|
-
add_index :audits, :created_at
|
23
|
-
end
|
24
|
-
|
25
|
-
def self.down
|
26
|
-
drop_table :audits
|
27
|
-
end
|
28
|
-
end
|
@@ -1,20 +0,0 @@
|
|
1
|
-
class CreatePageParts < ActiveRecord::Migration
|
2
|
-
def self.up
|
3
|
-
create_table :page_parts do |t|
|
4
|
-
t.string :key, :limit => 10, :null => false
|
5
|
-
t.text :content
|
6
|
-
|
7
|
-
t.integer :partable_id, :null => false
|
8
|
-
t.string :partable_type, :limit => 50, :null => false
|
9
|
-
|
10
|
-
t.timestamps
|
11
|
-
end
|
12
|
-
|
13
|
-
add_index :page_parts, :key
|
14
|
-
add_index :page_parts, [:partable_type, :partable_id]
|
15
|
-
end
|
16
|
-
|
17
|
-
def self.down
|
18
|
-
drop_table :page_parts
|
19
|
-
end
|
20
|
-
end
|
@@ -1,14 +0,0 @@
|
|
1
|
-
class CreatePosts < ActiveRecord::Migration
|
2
|
-
def change
|
3
|
-
create_table :posts do |t|
|
4
|
-
t.string :title, :null => false
|
5
|
-
t.text :content
|
6
|
-
t.boolean :is_visible, :default => true
|
7
|
-
t.integer :structure_id, :null => false
|
8
|
-
|
9
|
-
t.timestamps
|
10
|
-
end
|
11
|
-
|
12
|
-
add_index :posts, :structure_id
|
13
|
-
end
|
14
|
-
end
|
@@ -1,21 +0,0 @@
|
|
1
|
-
class CreateMetaTags < ActiveRecord::Migration
|
2
|
-
def self.up
|
3
|
-
create_table :meta_tags do |t|
|
4
|
-
t.string :name, :limit => 50, :null => false
|
5
|
-
t.text :content
|
6
|
-
t.boolean :is_dynamic, :default => false
|
7
|
-
|
8
|
-
t.integer :taggable_id, :null => false
|
9
|
-
t.string :taggable_type, :limit => 50, :null => false
|
10
|
-
|
11
|
-
t.timestamps
|
12
|
-
end
|
13
|
-
|
14
|
-
add_index :meta_tags, :name
|
15
|
-
add_index :meta_tags, [:taggable_type, :taggable_id]
|
16
|
-
end
|
17
|
-
|
18
|
-
def self.down
|
19
|
-
drop_table :meta_tags
|
20
|
-
end
|
21
|
-
end
|
@@ -1,23 +0,0 @@
|
|
1
|
-
# Migration responsible for creating a table with activities
|
2
|
-
class CreateActivities < ActiveRecord::Migration
|
3
|
-
# Create table
|
4
|
-
def self.up
|
5
|
-
create_table :activities do |t|
|
6
|
-
t.belongs_to :trackable, :polymorphic => true
|
7
|
-
t.belongs_to :owner, :polymorphic => true
|
8
|
-
t.string :key
|
9
|
-
t.text :parameters
|
10
|
-
t.belongs_to :recipient, :polymorphic => true
|
11
|
-
|
12
|
-
t.timestamps
|
13
|
-
end
|
14
|
-
|
15
|
-
add_index :activities, [:trackable_id, :trackable_type]
|
16
|
-
add_index :activities, [:owner_id, :owner_type]
|
17
|
-
add_index :activities, [:recipient_id, :recipient_type]
|
18
|
-
end
|
19
|
-
# Drop table
|
20
|
-
def self.down
|
21
|
-
drop_table :activities
|
22
|
-
end
|
23
|
-
end
|
data/spec/dummy/db/schema.rb
DELETED
@@ -1,90 +0,0 @@
|
|
1
|
-
# encoding: UTF-8
|
2
|
-
# This file is auto-generated from the current state of the database. Instead
|
3
|
-
# of editing this file, please use the migrations feature of Active Record to
|
4
|
-
# incrementally modify your database, and then regenerate this schema definition.
|
5
|
-
#
|
6
|
-
# Note that this schema.rb definition is the authoritative source for your
|
7
|
-
# database schema. If you need to create the application database on another
|
8
|
-
# system, you should be using db:schema:load, not running all the migrations
|
9
|
-
# from scratch. The latter is a flawed and unsustainable approach (the more migrations
|
10
|
-
# you'll amass, the slower it'll run and the greater likelihood for issues).
|
11
|
-
#
|
12
|
-
# It's strongly recommended that you check this file into your version control system.
|
13
|
-
|
14
|
-
ActiveRecord::Schema.define(version: 20130214090723) do
|
15
|
-
|
16
|
-
create_table "activities", force: true do |t|
|
17
|
-
t.integer "trackable_id"
|
18
|
-
t.string "trackable_type"
|
19
|
-
t.integer "owner_id"
|
20
|
-
t.string "owner_type"
|
21
|
-
t.string "key"
|
22
|
-
t.text "parameters"
|
23
|
-
t.integer "recipient_id"
|
24
|
-
t.string "recipient_type"
|
25
|
-
t.datetime "created_at"
|
26
|
-
t.datetime "updated_at"
|
27
|
-
end
|
28
|
-
|
29
|
-
add_index "activities", ["owner_id", "owner_type"], name: "index_activities_on_owner_id_and_owner_type", using: :btree
|
30
|
-
add_index "activities", ["recipient_id", "recipient_type"], name: "index_activities_on_recipient_id_and_recipient_type", using: :btree
|
31
|
-
add_index "activities", ["trackable_id", "trackable_type"], name: "index_activities_on_trackable_id_and_trackable_type", using: :btree
|
32
|
-
|
33
|
-
create_table "audits", force: true do |t|
|
34
|
-
t.integer "auditable_id"
|
35
|
-
t.string "auditable_type"
|
36
|
-
t.integer "associated_id"
|
37
|
-
t.string "associated_type"
|
38
|
-
t.integer "user_id"
|
39
|
-
t.string "user_type"
|
40
|
-
t.string "username"
|
41
|
-
t.string "action"
|
42
|
-
t.text "audited_changes"
|
43
|
-
t.integer "version", default: 0
|
44
|
-
t.string "comment"
|
45
|
-
t.string "remote_address"
|
46
|
-
t.datetime "created_at"
|
47
|
-
end
|
48
|
-
|
49
|
-
add_index "audits", ["associated_id", "associated_type"], name: "associated_index", using: :btree
|
50
|
-
add_index "audits", ["auditable_id", "auditable_type"], name: "auditable_index", using: :btree
|
51
|
-
add_index "audits", ["created_at"], name: "index_audits_on_created_at", using: :btree
|
52
|
-
add_index "audits", ["user_id", "user_type"], name: "user_index", using: :btree
|
53
|
-
|
54
|
-
create_table "meta_tags", force: true do |t|
|
55
|
-
t.string "name", limit: 50, null: false
|
56
|
-
t.text "content"
|
57
|
-
t.boolean "is_dynamic", default: false
|
58
|
-
t.integer "taggable_id", null: false
|
59
|
-
t.string "taggable_type", limit: 50, null: false
|
60
|
-
t.datetime "created_at"
|
61
|
-
t.datetime "updated_at"
|
62
|
-
end
|
63
|
-
|
64
|
-
add_index "meta_tags", ["name"], name: "index_meta_tags_on_name", using: :btree
|
65
|
-
add_index "meta_tags", ["taggable_type", "taggable_id"], name: "index_meta_tags_on_taggable_type_and_taggable_id", using: :btree
|
66
|
-
|
67
|
-
create_table "page_parts", force: true do |t|
|
68
|
-
t.string "key", limit: 10, null: false
|
69
|
-
t.text "content"
|
70
|
-
t.integer "partable_id", null: false
|
71
|
-
t.string "partable_type", limit: 50, null: false
|
72
|
-
t.datetime "created_at"
|
73
|
-
t.datetime "updated_at"
|
74
|
-
end
|
75
|
-
|
76
|
-
add_index "page_parts", ["key"], name: "index_page_parts_on_key", using: :btree
|
77
|
-
add_index "page_parts", ["partable_type", "partable_id"], name: "index_page_parts_on_partable_type_and_partable_id", using: :btree
|
78
|
-
|
79
|
-
create_table "posts", force: true do |t|
|
80
|
-
t.string "title", null: false
|
81
|
-
t.text "content"
|
82
|
-
t.boolean "is_visible", default: true
|
83
|
-
t.integer "structure_id", null: false
|
84
|
-
t.datetime "created_at"
|
85
|
-
t.datetime "updated_at"
|
86
|
-
end
|
87
|
-
|
88
|
-
add_index "posts", ["structure_id"], name: "index_posts_on_structure_id", using: :btree
|
89
|
-
|
90
|
-
end
|
data/spec/dummy/log/test.log
DELETED
@@ -1,235 +0,0 @@
|
|
1
|
-
[1m[36mActiveRecord::SchemaMigration Load (92.8ms)[0m [1mSELECT `schema_migrations`.* FROM `schema_migrations`[0m
|
2
|
-
[1m[35mActiveRecord::SchemaMigration Load (0.2ms)[0m SELECT `schema_migrations`.* FROM `schema_migrations`
|
3
|
-
[1m[36m (11.9ms)[0m [1mSELECT @@FOREIGN_KEY_CHECKS[0m
|
4
|
-
[1m[35m (0.2ms)[0m SET FOREIGN_KEY_CHECKS = 0
|
5
|
-
[1m[36m (11.3ms)[0m [1mSELECT DATABASE() as db[0m
|
6
|
-
[1m[35m (15.4ms)[0m select table_name from information_schema.views where table_schema = 'sunrise_dummy_test'
|
7
|
-
[1m[36m (37.0ms)[0m [1mTRUNCATE TABLE `activities`;[0m
|
8
|
-
[1m[35m (16.0ms)[0m TRUNCATE TABLE `assets`;
|
9
|
-
[1m[36m (14.7ms)[0m [1mTRUNCATE TABLE `audits`;[0m
|
10
|
-
[1m[35m (9.2ms)[0m TRUNCATE TABLE `meta_tags`;
|
11
|
-
[1m[36m (8.1ms)[0m [1mTRUNCATE TABLE `page_parts`;[0m
|
12
|
-
[1m[35m (8.8ms)[0m TRUNCATE TABLE `posts`;
|
13
|
-
[1m[36m (8.1ms)[0m [1mTRUNCATE TABLE `settings`;[0m
|
14
|
-
[1m[35m (13.0ms)[0m TRUNCATE TABLE `structures`;
|
15
|
-
[1m[36m (14.5ms)[0m [1mTRUNCATE TABLE `users`;[0m
|
16
|
-
[1m[35m (0.1ms)[0m SET FOREIGN_KEY_CHECKS = 1
|
17
|
-
[1m[36m (0.1ms)[0m [1mSELECT @@FOREIGN_KEY_CHECKS[0m
|
18
|
-
[1m[35m (0.1ms)[0m SET FOREIGN_KEY_CHECKS = 0
|
19
|
-
[1m[36m (9.8ms)[0m [1mTRUNCATE TABLE `activities`;[0m
|
20
|
-
[1m[35m (9.7ms)[0m TRUNCATE TABLE `assets`;
|
21
|
-
[1m[36m (12.3ms)[0m [1mTRUNCATE TABLE `audits`;[0m
|
22
|
-
[1m[35m (6.5ms)[0m TRUNCATE TABLE `meta_tags`;
|
23
|
-
[1m[36m (11.4ms)[0m [1mTRUNCATE TABLE `page_parts`;[0m
|
24
|
-
[1m[35m (5.3ms)[0m TRUNCATE TABLE `posts`;
|
25
|
-
[1m[36m (7.4ms)[0m [1mTRUNCATE TABLE `settings`;[0m
|
26
|
-
[1m[35m (12.2ms)[0m TRUNCATE TABLE `structures`;
|
27
|
-
[1m[36m (13.8ms)[0m [1mTRUNCATE TABLE `users`;[0m
|
28
|
-
[1m[35m (0.1ms)[0m SET FOREIGN_KEY_CHECKS = 1
|
29
|
-
[1m[36m (0.2ms)[0m [1mBEGIN[0m
|
30
|
-
[1m[35mStructure Load (11.8ms)[0m SELECT `structures`.* FROM `structures` ORDER BY `structures`.`rgt` desc LIMIT 1 FOR UPDATE
|
31
|
-
[1m[36mSQL (17.3ms)[0m [1mINSERT INTO `structures` (`created_at`, `lft`, `position_type_id`, `rgt`, `slug`, `structure_type_id`, `title`, `updated_at`) VALUES ('2014-09-24 09:59:34', 1, 2, 2, 'slug1', 1, 'Structure', '2014-09-24 09:59:34')[0m
|
32
|
-
[1m[35mSQL (0.3ms)[0m INSERT INTO `activities` (`created_at`, `key`, `parameters`, `trackable_id`, `trackable_type`, `updated_at`) VALUES ('2014-09-24 09:59:34', 'structure.create', '--- {}\n', 1, 'Structure', '2014-09-24 09:59:34')
|
33
|
-
[1m[36mStructure Load (0.4ms)[0m [1mSELECT `structures`.* FROM `structures` WHERE `structures`.`id` = 1 LIMIT 1[0m
|
34
|
-
[1m[35mSQL (17.2ms)[0m UPDATE `structures` SET `depth` = 0 WHERE `structures`.`id` = 1 ORDER BY `structures`.`lft`
|
35
|
-
[1m[36m (5.4ms)[0m [1mCOMMIT[0m
|
36
|
-
[1m[35m (0.2ms)[0m BEGIN
|
37
|
-
[1m[36mSQL (1.0ms)[0m [1mINSERT INTO `posts` (`content`, `created_at`, `structure_id`, `title`, `updated_at`) VALUES ('Some post content', '2014-09-24 09:59:34', 1, 'Default title', '2014-09-24 09:59:34')[0m
|
38
|
-
[1m[35mSQL (0.9ms)[0m INSERT INTO `activities` (`created_at`, `key`, `parameters`, `trackable_id`, `trackable_type`, `updated_at`) VALUES ('2014-09-24 09:59:34', 'post.create', '--- {}\n', 1, 'Post', '2014-09-24 09:59:34')
|
39
|
-
[1m[36m (0.9ms)[0m [1mCOMMIT[0m
|
40
|
-
[1m[35m (0.2ms)[0m BEGIN
|
41
|
-
[1m[36mUser Exists (0.5ms)[0m [1mSELECT 1 AS one FROM `users` WHERE `users`.`email` = BINARY 'testing1@example.com' LIMIT 1[0m
|
42
|
-
[1m[35mSQL (0.4ms)[0m INSERT INTO `users` (`confirmed_at`, `created_at`, `email`, `encrypted_password`, `name`, `role_type_id`, `updated_at`) VALUES ('2014-09-24 09:59:35', '2014-09-24 09:59:35', 'testing1@example.com', '$2a$04$uo83KVk5e4Paw7pe.ubAneFNgsgZztlXmO/BFqGz7z09XqOh/C6Qe', 'Redactor', 2, '2014-09-24 09:59:35')
|
43
|
-
[1m[36mSQL (0.3ms)[0m [1mINSERT INTO `activities` (`created_at`, `key`, `parameters`, `trackable_id`, `trackable_type`, `updated_at`) VALUES ('2014-09-24 09:59:35', 'user.create', '--- {}\n', 1, 'User', '2014-09-24 09:59:35')[0m
|
44
|
-
[1m[35m (6.0ms)[0m COMMIT
|
45
|
-
[1m[36m (0.1ms)[0m [1mBEGIN[0m
|
46
|
-
[1m[35mSQL (0.5ms)[0m INSERT INTO `activities` (`created_at`, `key`, `owner_id`, `owner_type`, `parameters`, `trackable_id`, `trackable_type`, `updated_at`) VALUES ('2014-09-24 09:59:35', 'post.create', 1, 'User', '--- {}\n', 1, 'Post', '2014-09-24 09:59:35')
|
47
|
-
[1m[36m (4.9ms)[0m [1mCOMMIT[0m
|
48
|
-
[1m[35m (0.3ms)[0m BEGIN
|
49
|
-
[1m[36mUser Exists (0.4ms)[0m [1mSELECT 1 AS one FROM `users` WHERE `users`.`email` = BINARY 'testing2@example.com' LIMIT 1[0m
|
50
|
-
[1m[35mSQL (0.4ms)[0m INSERT INTO `users` (`confirmed_at`, `created_at`, `email`, `encrypted_password`, `name`, `role_type_id`, `updated_at`) VALUES ('2014-09-24 09:59:35', '2014-09-24 09:59:35', 'testing2@example.com', '$2a$04$Rq4xMJoXmTAXHO.tj6GXcOTwhzrsyUUhIAeQJmCuaHlTWP7cg7LdW', 'Admin', 4, '2014-09-24 09:59:35')
|
51
|
-
[1m[36mSQL (0.3ms)[0m [1mINSERT INTO `activities` (`created_at`, `key`, `parameters`, `trackable_id`, `trackable_type`, `updated_at`) VALUES ('2014-09-24 09:59:35', 'user.create', '--- {}\n', 2, 'User', '2014-09-24 09:59:35')[0m
|
52
|
-
[1m[35m (0.4ms)[0m COMMIT
|
53
|
-
Processing by Sunrise::ActivitiesController#index as HTML
|
54
|
-
[1m[36mUser Load (0.5ms)[0m [1mSELECT `users`.* FROM `users` WHERE `users`.`id` = 2 ORDER BY `users`.`id` ASC LIMIT 1[0m
|
55
|
-
[1m[35mPublicActivity::Activity Load (0.5ms)[0m SELECT `activities`.* FROM `activities` ORDER BY created_at DESC LIMIT 50 OFFSET 0
|
56
|
-
[1m[36mUser Load (0.4ms)[0m [1mSELECT `users`.* FROM `users` WHERE `users`.`id` = 1 LIMIT 1[0m
|
57
|
-
[1m[35mUser Load (0.4ms)[0m SELECT `users`.* FROM `users` WHERE `users`.`id` = 1 LIMIT 1
|
58
|
-
[1m[36mPost Load (0.4ms)[0m [1mSELECT `posts`.* FROM `posts` WHERE `posts`.`id` = 1 LIMIT 1[0m
|
59
|
-
[1m[35mUser Load (0.4ms)[0m SELECT `users`.* FROM `users` WHERE `users`.`id` = 2 LIMIT 1
|
60
|
-
[1m[36mStructure Load (0.3ms)[0m [1mSELECT `structures`.* FROM `structures` WHERE `structures`.`id` = 1 LIMIT 1[0m
|
61
|
-
[1m[35mPost Load (0.5ms)[0m SELECT `posts`.* FROM `posts` WHERE `posts`.`id` = 1 LIMIT 1
|
62
|
-
Rendered /Volumes/Data/mario/www/gems/sunrise/app/views/sunrise/activities/_activity.html.erb (21.4ms)
|
63
|
-
[1m[36m (6.9ms)[0m [1mSELECT COUNT(count_column) FROM (SELECT 1 AS count_column FROM `activities` LIMIT 50 OFFSET 0) subquery_for_count[0m
|
64
|
-
Rendered /Volumes/Data/mario/www/gems/sunrise/app/views/sunrise/activities/index.html.erb within layouts/sunrise/application (168.2ms)
|
65
|
-
Rendered /Volumes/Data/mario/www/gems/sunrise/app/views/sunrise/shared/_panel.html.erb (10.2ms)
|
66
|
-
Rendered /Volumes/Data/mario/www/gems/sunrise/app/views/sunrise/activities/_header.html.erb (8.5ms)
|
67
|
-
Completed 200 OK in 2362ms (Views: 2277.2ms | ActiveRecord: 10.2ms)
|
68
|
-
Processing by Sunrise::ActivitiesController#index as HTML
|
69
|
-
Completed 401 Unauthorized in 0ms
|
70
|
-
Processing by Sunrise::ActivitiesController#index as HTML
|
71
|
-
Completed 401 Unauthorized in 0ms
|
72
|
-
[1m[35m (0.2ms)[0m SELECT @@FOREIGN_KEY_CHECKS
|
73
|
-
[1m[36m (0.1ms)[0m [1mSET FOREIGN_KEY_CHECKS = 0[0m
|
74
|
-
[1m[35m (27.6ms)[0m TRUNCATE TABLE `activities`;
|
75
|
-
[1m[36m (9.9ms)[0m [1mTRUNCATE TABLE `assets`;[0m
|
76
|
-
[1m[35m (11.4ms)[0m TRUNCATE TABLE `audits`;
|
77
|
-
[1m[36m (6.9ms)[0m [1mTRUNCATE TABLE `meta_tags`;[0m
|
78
|
-
[1m[35m (6.8ms)[0m TRUNCATE TABLE `page_parts`;
|
79
|
-
[1m[36m (5.2ms)[0m [1mTRUNCATE TABLE `posts`;[0m
|
80
|
-
[1m[35m (5.8ms)[0m TRUNCATE TABLE `settings`;
|
81
|
-
[1m[36m (9.4ms)[0m [1mTRUNCATE TABLE `structures`;[0m
|
82
|
-
[1m[35m (9.6ms)[0m TRUNCATE TABLE `users`;
|
83
|
-
[1m[36m (0.1ms)[0m [1mSET FOREIGN_KEY_CHECKS = 1[0m
|
84
|
-
[1m[35m (0.2ms)[0m SELECT @@FOREIGN_KEY_CHECKS
|
85
|
-
[1m[36m (0.1ms)[0m [1mSET FOREIGN_KEY_CHECKS = 0[0m
|
86
|
-
[1m[35m (9.4ms)[0m TRUNCATE TABLE `activities`;
|
87
|
-
[1m[36m (9.6ms)[0m [1mTRUNCATE TABLE `assets`;[0m
|
88
|
-
[1m[35m (10.9ms)[0m TRUNCATE TABLE `audits`;
|
89
|
-
[1m[36m (6.6ms)[0m [1mTRUNCATE TABLE `meta_tags`;[0m
|
90
|
-
[1m[35m (12.2ms)[0m TRUNCATE TABLE `page_parts`;
|
91
|
-
[1m[36m (5.7ms)[0m [1mTRUNCATE TABLE `posts`;[0m
|
92
|
-
[1m[35m (5.4ms)[0m TRUNCATE TABLE `settings`;
|
93
|
-
[1m[36m (10.2ms)[0m [1mTRUNCATE TABLE `structures`;[0m
|
94
|
-
[1m[35m (14.0ms)[0m TRUNCATE TABLE `users`;
|
95
|
-
[1m[36m (0.1ms)[0m [1mSET FOREIGN_KEY_CHECKS = 1[0m
|
96
|
-
[1m[35m (0.2ms)[0m BEGIN
|
97
|
-
[1m[36mUser Exists (0.3ms)[0m [1mSELECT 1 AS one FROM `users` WHERE `users`.`email` = BINARY 'testing3@example.com' LIMIT 1[0m
|
98
|
-
[1m[35mSQL (0.3ms)[0m INSERT INTO `users` (`confirmed_at`, `created_at`, `email`, `encrypted_password`, `name`, `role_type_id`, `updated_at`) VALUES ('2014-09-24 09:59:37', '2014-09-24 09:59:37', 'testing3@example.com', '$2a$04$GpHm38ea8NxTjrE0bWcpEeVSULaKMLjnTNwISVKc1sqDaRZitL3Xy', 'Admin', 4, '2014-09-24 09:59:37')
|
99
|
-
[1m[36mSQL (0.2ms)[0m [1mINSERT INTO `activities` (`created_at`, `key`, `owner_id`, `owner_type`, `parameters`, `trackable_id`, `trackable_type`, `updated_at`) VALUES ('2014-09-24 09:59:37', 'user.create', 2, 'User', '--- {}\n', 1, 'User', '2014-09-24 09:59:37')[0m
|
100
|
-
[1m[35m (1.0ms)[0m COMMIT
|
101
|
-
[1m[36m (0.1ms)[0m [1mBEGIN[0m
|
102
|
-
[1m[35mStructure Load (0.3ms)[0m SELECT `structures`.* FROM `structures` ORDER BY `structures`.`rgt` desc LIMIT 1 FOR UPDATE
|
103
|
-
[1m[36mSQL (0.3ms)[0m [1mINSERT INTO `structures` (`created_at`, `lft`, `position_type_id`, `rgt`, `slug`, `structure_type_id`, `title`, `updated_at`) VALUES ('2014-09-24 09:59:37', 1, 1, 2, 'main-page', 3, 'Main page', '2014-09-24 09:59:37')[0m
|
104
|
-
[1m[35mSQL (0.3ms)[0m INSERT INTO `activities` (`created_at`, `key`, `owner_id`, `owner_type`, `parameters`, `trackable_id`, `trackable_type`, `updated_at`) VALUES ('2014-09-24 09:59:37', 'structure.create', 2, 'User', '--- {}\n', 1, 'Structure', '2014-09-24 09:59:37')
|
105
|
-
[1m[36mStructure Load (0.3ms)[0m [1mSELECT `structures`.* FROM `structures` WHERE `structures`.`id` = 1 LIMIT 1[0m
|
106
|
-
[1m[35mSQL (0.3ms)[0m UPDATE `structures` SET `depth` = 0 WHERE `structures`.`id` = 1 ORDER BY `structures`.`lft`
|
107
|
-
[1m[36m (0.3ms)[0m [1mCOMMIT[0m
|
108
|
-
[1m[35m (0.1ms)[0m BEGIN
|
109
|
-
[1m[36mStructure Load (0.3ms)[0m [1mSELECT `structures`.* FROM `structures` ORDER BY `structures`.`rgt` desc LIMIT 1 FOR UPDATE[0m
|
110
|
-
[1m[35mSQL (0.3ms)[0m INSERT INTO `structures` (`created_at`, `lft`, `parent_id`, `position_type_id`, `rgt`, `slug`, `structure_type_id`, `title`, `updated_at`) VALUES ('2014-09-24 09:59:37', 3, 1, 2, 4, 'slug2', 1, 'Structure', '2014-09-24 09:59:37')
|
111
|
-
[1m[36mSQL (0.3ms)[0m [1mINSERT INTO `activities` (`created_at`, `key`, `owner_id`, `owner_type`, `parameters`, `trackable_id`, `trackable_type`, `updated_at`) VALUES ('2014-09-24 09:59:37', 'structure.create', 2, 'User', '--- {}\n', 2, 'Structure', '2014-09-24 09:59:37')[0m
|
112
|
-
[1m[35mStructure Load (0.3ms)[0m SELECT `structures`.* FROM `structures` WHERE `structures`.`id` = 1 ORDER BY `structures`.`lft` LIMIT 1
|
113
|
-
[1m[36mStructure Load (0.3ms)[0m [1mSELECT `structures`.* FROM `structures` WHERE `structures`.`id` = 2 LIMIT 1 FOR UPDATE[0m
|
114
|
-
[1m[35mSQL (1.3ms)[0m UPDATE `structures` SET `lft` = CASE WHEN `lft` BETWEEN 2 AND 2 THEN `lft` + 4 - 2 WHEN `lft` BETWEEN 3 AND 4 THEN `lft` + 2 - 3 ELSE `lft` END, `rgt` = CASE WHEN `rgt` BETWEEN 2 AND 2 THEN `rgt` + 4 - 2 WHEN `rgt` BETWEEN 3 AND 4 THEN `rgt` + 2 - 3 ELSE `rgt` END, `parent_id` = CASE WHEN id = 2 THEN 1 ELSE `parent_id` END WHERE (not (`lft` = CASE WHEN `lft` BETWEEN 2 AND 2 THEN `lft` + 4 - 2 WHEN `lft` BETWEEN 3 AND 4 THEN `lft` + 2 - 3 ELSE `lft` END AND `rgt` = CASE WHEN `rgt` BETWEEN 2 AND 2 THEN `rgt` + 4 - 2 WHEN `rgt` BETWEEN 3 AND 4 THEN `rgt` + 2 - 3 ELSE `rgt` END AND `parent_id` = CASE WHEN id = 2 THEN 1 ELSE `parent_id` END)) ORDER BY `structures`.`lft`
|
115
|
-
[1m[36mStructure Load (0.3ms)[0m [1mSELECT `structures`.* FROM `structures` WHERE `structures`.`id` = 1 LIMIT 1 FOR UPDATE[0m
|
116
|
-
[1m[35mStructure Load (0.2ms)[0m SELECT `structures`.* FROM `structures` WHERE `structures`.`id` = 2 LIMIT 1
|
117
|
-
[1m[36m (0.4ms)[0m [1mSELECT COUNT(*) FROM `structures` WHERE (`structures`.`lft` <= 2 AND `structures`.`rgt` >= 3) AND (`structures`.id != 2)[0m
|
118
|
-
[1m[35mSQL (0.3ms)[0m UPDATE `structures` SET `depth` = 1 WHERE `structures`.`id` = 2 ORDER BY `structures`.`lft`
|
119
|
-
[1m[36m (0.5ms)[0m [1mSELECT COUNT(*) FROM `structures` WHERE (`structures`.`lft` <= 2 AND `structures`.`rgt` >= 3) AND (`structures`.id != 2)[0m
|
120
|
-
[1m[35mStructure Load (0.4ms)[0m SELECT `structures`.* FROM `structures` WHERE (`structures`.`lft` >= 2 AND `structures`.`lft` < 3) AND (`structures`.id != 2) ORDER BY `structures`.`lft`
|
121
|
-
[1m[36mStructure Load (0.3ms)[0m [1mSELECT `structures`.* FROM `structures` WHERE `structures`.`id` = 2 LIMIT 1 FOR UPDATE[0m
|
122
|
-
[1m[35mStructure Load (0.2ms)[0m SELECT `structures`.* FROM `structures` WHERE `structures`.`id` = 2 LIMIT 1
|
123
|
-
[1m[36m (0.3ms)[0m [1mSELECT COUNT(*) FROM `structures` WHERE (`structures`.`lft` <= 2 AND `structures`.`rgt` >= 3) AND (`structures`.id != 2)[0m
|
124
|
-
[1m[35mSQL (0.3ms)[0m UPDATE `structures` SET `depth` = 1 WHERE `structures`.`id` = 2 ORDER BY `structures`.`lft`
|
125
|
-
[1m[36m (0.4ms)[0m [1mSELECT COUNT(*) FROM `structures` WHERE (`structures`.`lft` <= 2 AND `structures`.`rgt` >= 3) AND (`structures`.id != 2)[0m
|
126
|
-
[1m[35m (0.4ms)[0m COMMIT
|
127
|
-
Processing by Sunrise::ManagerController#index as HTML
|
128
|
-
Parameters: {"model_name"=>"structures"}
|
129
|
-
[1m[36mUser Load (0.4ms)[0m [1mSELECT `users`.* FROM `users` WHERE `users`.`id` = 1 ORDER BY `users`.`id` ASC LIMIT 1[0m
|
130
|
-
Completed 200 OK in 29ms (Views: 4.8ms | ActiveRecord: 0.4ms)
|
131
|
-
[1m[35mStructure Load (0.5ms)[0m SELECT `structures`.* FROM `structures` WHERE `structures`.`parent_id` IS NULL ORDER BY `structures`.`lft`
|
132
|
-
Processing by Sunrise::ManagerController#index as HTML
|
133
|
-
Parameters: {"model_name"=>"wrong"}
|
134
|
-
[1m[36mUser Load (0.4ms)[0m [1mSELECT `users`.* FROM `users` WHERE `users`.`id` = 1 ORDER BY `users`.`id` ASC LIMIT 1[0m
|
135
|
-
Error while loading 'SunriseWrong': uninitialized constant SunriseWrong
|
136
|
-
Completed 404 Not Found in 5ms
|
137
|
-
Processing by Sunrise::ManagerController#destroy as HTML
|
138
|
-
Parameters: {"model_name"=>"structures", "id"=>"1"}
|
139
|
-
[1m[35mUser Load (0.4ms)[0m SELECT `users`.* FROM `users` WHERE `users`.`id` = 1 ORDER BY `users`.`id` ASC LIMIT 1
|
140
|
-
[1m[36mStructure Load (0.4ms)[0m [1mSELECT `structures`.* FROM `structures` WHERE `structures`.`id` = 1 LIMIT 1[0m
|
141
|
-
Access denied on destroy #<Structure id: 1, title: "Main page", slug: "main-page", structure_type_id: 3, position_type_id: 1, is_visible: true, redirect_url: nil, parent_id: nil, lft: 1, rgt: 4, depth: 0, created_at: "2014-09-24 09:59:37", updated_at: "2014-09-24 09:59:37">, context: sunrise, user: 1
|
142
|
-
Redirected to http://test.host/
|
143
|
-
Completed 302 Found in 5ms (ActiveRecord: 0.8ms)
|
144
|
-
[1m[35m (0.1ms)[0m BEGIN
|
145
|
-
[1m[36mStructure Load (0.3ms)[0m [1mSELECT `structures`.* FROM `structures` ORDER BY `structures`.`rgt` desc LIMIT 1 FOR UPDATE[0m
|
146
|
-
[1m[35mSQL (0.3ms)[0m INSERT INTO `structures` (`created_at`, `lft`, `position_type_id`, `rgt`, `slug`, `structure_type_id`, `title`, `updated_at`) VALUES ('2014-09-24 09:59:37', 5, 2, 6, 'slug3', 1, 'Structure', '2014-09-24 09:59:37')
|
147
|
-
[1m[36mSQL (0.4ms)[0m [1mINSERT INTO `activities` (`created_at`, `key`, `owner_id`, `owner_type`, `parameters`, `trackable_id`, `trackable_type`, `updated_at`) VALUES ('2014-09-24 09:59:37', 'structure.create', 1, 'User', '--- {}\n', 3, 'Structure', '2014-09-24 09:59:37')[0m
|
148
|
-
[1m[35mStructure Load (0.3ms)[0m SELECT `structures`.* FROM `structures` WHERE `structures`.`id` = 3 LIMIT 1
|
149
|
-
[1m[36mSQL (0.4ms)[0m [1mUPDATE `structures` SET `depth` = 0 WHERE `structures`.`id` = 3 ORDER BY `structures`.`lft`[0m
|
150
|
-
[1m[35m (5.7ms)[0m COMMIT
|
151
|
-
[1m[36m (0.1ms)[0m [1mBEGIN[0m
|
152
|
-
[1m[35mSQL (0.5ms)[0m INSERT INTO `posts` (`content`, `created_at`, `structure_id`, `title`, `updated_at`) VALUES ('Some post content', '2014-09-24 09:59:37', 3, 'Default title', '2014-09-24 09:59:37')
|
153
|
-
[1m[36mSQL (3.9ms)[0m [1mINSERT INTO `activities` (`created_at`, `key`, `owner_id`, `owner_type`, `parameters`, `trackable_id`, `trackable_type`, `updated_at`) VALUES ('2014-09-24 09:59:37', 'post.create', 1, 'User', '--- {}\n', 1, 'Post', '2014-09-24 09:59:37')[0m
|
154
|
-
[1m[35m (5.0ms)[0m COMMIT
|
155
|
-
Processing by Sunrise::ManagerController#index as HTML
|
156
|
-
Parameters: {"model_name"=>"posts"}
|
157
|
-
[1m[36mUser Load (0.5ms)[0m [1mSELECT `users`.* FROM `users` WHERE `users`.`id` = 1 ORDER BY `users`.`id` ASC LIMIT 1[0m
|
158
|
-
Completed 200 OK in 18ms (Views: 1.6ms | ActiveRecord: 0.5ms)
|
159
|
-
[1m[35mPost Load (1.0ms)[0m SELECT `posts`.* FROM `posts` LIMIT 25 OFFSET 0
|
160
|
-
[1m[36m (0.2ms)[0m [1mSELECT @@FOREIGN_KEY_CHECKS[0m
|
161
|
-
[1m[35m (0.2ms)[0m SET FOREIGN_KEY_CHECKS = 0
|
162
|
-
[1m[36m (202.7ms)[0m [1mTRUNCATE TABLE `activities`;[0m
|
163
|
-
[1m[35m (190.3ms)[0m TRUNCATE TABLE `assets`;
|
164
|
-
[1m[36m (93.9ms)[0m [1mTRUNCATE TABLE `audits`;[0m
|
165
|
-
[1m[35m (29.2ms)[0m TRUNCATE TABLE `meta_tags`;
|
166
|
-
[1m[36m (146.8ms)[0m [1mTRUNCATE TABLE `page_parts`;[0m
|
167
|
-
[1m[35m (107.0ms)[0m TRUNCATE TABLE `posts`;
|
168
|
-
[1m[36m (135.5ms)[0m [1mTRUNCATE TABLE `settings`;[0m
|
169
|
-
[1m[35m (93.0ms)[0m TRUNCATE TABLE `structures`;
|
170
|
-
[1m[36m (43.6ms)[0m [1mTRUNCATE TABLE `users`;[0m
|
171
|
-
[1m[35m (0.2ms)[0m SET FOREIGN_KEY_CHECKS = 1
|
172
|
-
[1m[36m (0.2ms)[0m [1mSELECT @@FOREIGN_KEY_CHECKS[0m
|
173
|
-
[1m[35m (0.1ms)[0m SET FOREIGN_KEY_CHECKS = 0
|
174
|
-
[1m[36m (8.8ms)[0m [1mTRUNCATE TABLE `activities`;[0m
|
175
|
-
[1m[35m (9.5ms)[0m TRUNCATE TABLE `assets`;
|
176
|
-
[1m[36m (9.5ms)[0m [1mTRUNCATE TABLE `audits`;[0m
|
177
|
-
[1m[35m (45.0ms)[0m TRUNCATE TABLE `meta_tags`;
|
178
|
-
[1m[36m (10.3ms)[0m [1mTRUNCATE TABLE `page_parts`;[0m
|
179
|
-
[1m[35m (5.7ms)[0m TRUNCATE TABLE `posts`;
|
180
|
-
[1m[36m (5.5ms)[0m [1mTRUNCATE TABLE `settings`;[0m
|
181
|
-
[1m[35m (9.7ms)[0m TRUNCATE TABLE `structures`;
|
182
|
-
[1m[36m (65.5ms)[0m [1mTRUNCATE TABLE `users`;[0m
|
183
|
-
[1m[35m (0.2ms)[0m SET FOREIGN_KEY_CHECKS = 1
|
184
|
-
[1m[36mSettings Load (0.5ms)[0m [1mSELECT `settings`.* FROM `settings` WHERE (thing_type is NULL and thing_id is NULL) AND `settings`.`var` = 'some_setting' ORDER BY `settings`.`id` ASC LIMIT 1[0m
|
185
|
-
[1m[35m (0.4ms)[0m BEGIN
|
186
|
-
[1m[36mSQL (0.6ms)[0m [1mINSERT INTO `settings` (`created_at`, `updated_at`, `value`, `var`) VALUES ('2014-09-24 09:59:39', '2014-09-24 09:59:39', '--- value\n...\n', 'some_setting')[0m
|
187
|
-
[1m[35mSQL (0.5ms)[0m INSERT INTO `activities` (`created_at`, `key`, `owner_id`, `owner_type`, `parameters`, `trackable_id`, `trackable_type`, `updated_at`) VALUES ('2014-09-24 09:59:39', 'settings.create', 1, 'User', '--- {}\n', 1, 'RailsSettings::Settings', '2014-09-24 09:59:39')
|
188
|
-
[1m[36m (6.6ms)[0m [1mCOMMIT[0m
|
189
|
-
[1m[35mSettings Load (0.6ms)[0m SELECT `settings`.* FROM `settings` WHERE (thing_type is NULL and thing_id is NULL) AND `settings`.`var` = 'some_setting2' ORDER BY `settings`.`id` ASC LIMIT 1
|
190
|
-
[1m[36m (0.2ms)[0m [1mBEGIN[0m
|
191
|
-
[1m[35mSQL (0.4ms)[0m INSERT INTO `settings` (`created_at`, `updated_at`, `value`, `var`) VALUES ('2014-09-24 09:59:39', '2014-09-24 09:59:39', '--- value2\n...\n', 'some_setting2')
|
192
|
-
[1m[36mSQL (0.4ms)[0m [1mINSERT INTO `activities` (`created_at`, `key`, `owner_id`, `owner_type`, `parameters`, `trackable_id`, `trackable_type`, `updated_at`) VALUES ('2014-09-24 09:59:39', 'settings.create', 1, 'User', '--- {}\n', 2, 'RailsSettings::Settings', '2014-09-24 09:59:39')[0m
|
193
|
-
[1m[35m (6.0ms)[0m COMMIT
|
194
|
-
[1m[36m (0.2ms)[0m [1mBEGIN[0m
|
195
|
-
[1m[35mUser Exists (0.5ms)[0m SELECT 1 AS one FROM `users` WHERE `users`.`email` = BINARY 'testing4@example.com' LIMIT 1
|
196
|
-
[1m[36mSQL (0.6ms)[0m [1mINSERT INTO `users` (`confirmed_at`, `created_at`, `email`, `encrypted_password`, `name`, `role_type_id`, `updated_at`) VALUES ('2014-09-24 09:59:39', '2014-09-24 09:59:39', 'testing4@example.com', '$2a$04$vOEyeq.PV1f7k6P3amMolutkkPiisAuGZchLT5B9HZyUyjkJcvkX.', 'Admin', 4, '2014-09-24 09:59:39')[0m
|
197
|
-
[1m[35mSQL (0.4ms)[0m INSERT INTO `activities` (`created_at`, `key`, `owner_id`, `owner_type`, `parameters`, `trackable_id`, `trackable_type`, `updated_at`) VALUES ('2014-09-24 09:59:39', 'user.create', 1, 'User', '--- {}\n', 1, 'User', '2014-09-24 09:59:39')
|
198
|
-
[1m[36m (0.7ms)[0m [1mCOMMIT[0m
|
199
|
-
Processing by Sunrise::SettingsController#edit as HTML
|
200
|
-
[1m[35mUser Load (0.5ms)[0m SELECT `users`.* FROM `users` WHERE `users`.`id` = 1 ORDER BY `users`.`id` ASC LIMIT 1
|
201
|
-
[1m[36mSettings Load (5.3ms)[0m [1mSELECT var,value FROM `settings` WHERE (thing_type is NULL and thing_id is NULL)[0m
|
202
|
-
[1m[35mSettings Load (0.5ms)[0m SELECT `settings`.* FROM `settings` WHERE (thing_type is NULL and thing_id is NULL) AND `settings`.`var` = 'to_key' ORDER BY `settings`.`id` ASC LIMIT 1
|
203
|
-
[1m[36mSettings Load (0.9ms)[0m [1mSELECT `settings`.* FROM `settings` WHERE (thing_type is NULL and thing_id is NULL) AND `settings`.`var` = 'persisted?' ORDER BY `settings`.`id` ASC LIMIT 1[0m
|
204
|
-
Rendered /Volumes/Data/mario/www/gems/sunrise/app/views/sunrise/settings/_form.html.erb (81.5ms)
|
205
|
-
Rendered /Volumes/Data/mario/www/gems/sunrise/app/views/sunrise/shared/_panel.html.erb (7.7ms)
|
206
|
-
Rendered /Volumes/Data/mario/www/gems/sunrise/app/views/sunrise/settings/_header_edit.html.erb (4.4ms)
|
207
|
-
Completed 200 OK in 152ms (Views: 125.0ms | ActiveRecord: 7.2ms)
|
208
|
-
Processing by Sunrise::SettingsController#update as HTML
|
209
|
-
Parameters: {"settings"=>{"some_setting"=>"blablabla"}}
|
210
|
-
[1m[35mUser Load (4.0ms)[0m SELECT `users`.* FROM `users` WHERE `users`.`id` = 1 ORDER BY `users`.`id` ASC LIMIT 1
|
211
|
-
[1m[36mSettings Load (0.8ms)[0m [1mSELECT `settings`.* FROM `settings` WHERE (thing_type is NULL and thing_id is NULL) AND `settings`.`var` = 'some_setting' ORDER BY `settings`.`id` ASC LIMIT 1[0m
|
212
|
-
[1m[35m (0.2ms)[0m BEGIN
|
213
|
-
[1m[36mSQL (0.7ms)[0m [1mUPDATE `settings` SET `value` = '--- blablabla\n...\n', `updated_at` = '2014-09-24 09:59:39' WHERE `settings`.`id` = 1[0m
|
214
|
-
[1m[35mSQL (0.5ms)[0m INSERT INTO `activities` (`created_at`, `key`, `owner_id`, `owner_type`, `parameters`, `trackable_id`, `trackable_type`, `updated_at`) VALUES ('2014-09-24 09:59:39', 'settings.update', 1, 'User', '--- {}\n', 1, 'RailsSettings::Settings', '2014-09-24 09:59:39')
|
215
|
-
[1m[36m (5.5ms)[0m [1mCOMMIT[0m
|
216
|
-
Redirected to http://test.host/manage/
|
217
|
-
Completed 302 Found in 40ms (ActiveRecord: 11.7ms)
|
218
|
-
Processing by Sunrise::SettingsController#update as HTML
|
219
|
-
Completed 401 Unauthorized in 1ms
|
220
|
-
Processing by Sunrise::SettingsController#edit as HTML
|
221
|
-
Completed 401 Unauthorized in 1ms
|
222
|
-
Processing by Sunrise::SettingsController#edit as HTML
|
223
|
-
Completed 401 Unauthorized in 1ms
|
224
|
-
[1m[35m (0.2ms)[0m SELECT @@FOREIGN_KEY_CHECKS
|
225
|
-
[1m[36m (0.1ms)[0m [1mSET FOREIGN_KEY_CHECKS = 0[0m
|
226
|
-
[1m[35m (77.1ms)[0m TRUNCATE TABLE `activities`;
|
227
|
-
[1m[36m (9.4ms)[0m [1mTRUNCATE TABLE `assets`;[0m
|
228
|
-
[1m[35m (53.6ms)[0m TRUNCATE TABLE `audits`;
|
229
|
-
[1m[36m (6.4ms)[0m [1mTRUNCATE TABLE `meta_tags`;[0m
|
230
|
-
[1m[35m (7.4ms)[0m TRUNCATE TABLE `page_parts`;
|
231
|
-
[1m[36m (5.3ms)[0m [1mTRUNCATE TABLE `posts`;[0m
|
232
|
-
[1m[35m (5.1ms)[0m TRUNCATE TABLE `settings`;
|
233
|
-
[1m[36m (9.5ms)[0m [1mTRUNCATE TABLE `structures`;[0m
|
234
|
-
[1m[35m (9.1ms)[0m TRUNCATE TABLE `users`;
|
235
|
-
[1m[36m (0.1ms)[0m [1mSET FOREIGN_KEY_CHECKS = 1[0m
|