cd2_catton_cms 1.1.10
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/Rakefile +37 -0
- data/app/assets/config/c_manifest.js +2 -0
- data/app/assets/images/c/drag_handle.gif +0 -0
- data/app/assets/images/c/login_background.jpg +0 -0
- data/app/assets/images/c/main_application/hero.jpg +0 -0
- data/app/assets/images/c/main_application/search.png +0 -0
- data/app/assets/images/c/placeholder_product_image.png +0 -0
- data/app/assets/images/c/select_arrow_down_blk.png +0 -0
- data/app/assets/images/c/small_icon.png +0 -0
- data/app/assets/images/c/vendor/chosen-sprite.png +0 -0
- data/app/assets/javascripts/c/application.js +59 -0
- data/app/assets/javascripts/c/change_tag.js +49 -0
- data/app/assets/javascripts/c/chosen.js +2 -0
- data/app/assets/javascripts/c/confirm_delete.js +55 -0
- data/app/assets/javascripts/c/draggable_tree.js +223 -0
- data/app/assets/javascripts/c/dropzone_init.js +98 -0
- data/app/assets/javascripts/c/fake_table.js +87 -0
- data/app/assets/javascripts/c/master_form2/collection.js +180 -0
- data/app/assets/javascripts/c/master_form2/eu_cookie.js +1 -0
- data/app/assets/javascripts/c/master_form2/jrecord.js +116 -0
- data/app/assets/javascripts/c/master_form2/master_form.coffee +4 -0
- data/app/assets/javascripts/c/split_buttons.js.erb +15 -0
- data/app/assets/javascripts/c/things_to_be_done.js +138 -0
- data/app/assets/javascripts/c/unloadevent.js +35 -0
- data/app/assets/stylesheets/c/_core.sass +237 -0
- data/app/assets/stylesheets/c/_engine.sass +4 -0
- data/app/assets/stylesheets/c/_variables.sass +32 -0
- data/app/assets/stylesheets/c/_vendor.sass +6 -0
- data/app/assets/stylesheets/c/application/checkout/_cart.sass +85 -0
- data/app/assets/stylesheets/c/application/checkout/_checkout.sass +87 -0
- data/app/assets/stylesheets/c/application/elements/buttons.sass +34 -0
- data/app/assets/stylesheets/c/application/elements/forms.sass +135 -0
- data/app/assets/stylesheets/c/application/elements/shadows.sass +23 -0
- data/app/assets/stylesheets/c/application/partials/_breadcrumbs.sass +10 -0
- data/app/assets/stylesheets/c/application/partials/_categories_sidebars/_1.sass +53 -0
- data/app/assets/stylesheets/c/application/partials/_categories_sidebars/_2.sass +77 -0
- data/app/assets/stylesheets/c/application/partials/_footer.sass +43 -0
- data/app/assets/stylesheets/c/application/partials/_header.sass +317 -0
- data/app/assets/stylesheets/c/engine/_draggable_trees.sass +68 -0
- data/app/assets/stylesheets/c/engine/_form_pages.sass +153 -0
- data/app/assets/stylesheets/c/engine/_header_bar.sass +29 -0
- data/app/assets/stylesheets/c/engine/_index_header.sass +17 -0
- data/app/assets/stylesheets/c/engine/_layout.sass +15 -0
- data/app/assets/stylesheets/c/engine/_login.sass +38 -0
- data/app/assets/stylesheets/c/engine/_navbar.sass +19 -0
- data/app/assets/stylesheets/c/engine/_pagination.sass +16 -0
- data/app/assets/stylesheets/c/engine/_settings.sass +5 -0
- data/app/assets/stylesheets/c/engine/_sidebar.sass +20 -0
- data/app/assets/stylesheets/c/engine/_tables.sass +76 -0
- data/app/assets/stylesheets/c/engine/flash_messages.sass +2 -0
- data/app/assets/stylesheets/c/print_application.sass +167 -0
- data/app/assets/stylesheets/c/vendor/_flex_mixins.scss +394 -0
- data/app/assets/stylesheets/c/vendor/_normalize.sass +340 -0
- data/app/controllers/c/admin/blogs_controller.rb +57 -0
- data/app/controllers/c/admin/devise/passwords_controller.rb +5 -0
- data/app/controllers/c/admin/devise/sessions_controller.rb +5 -0
- data/app/controllers/c/admin/documents_controller.rb +50 -0
- data/app/controllers/c/admin/enquiries_controller.rb +22 -0
- data/app/controllers/c/admin/images_controller.rb +21 -0
- data/app/controllers/c/admin/locations_controller.rb +63 -0
- data/app/controllers/c/admin/menu_items_controller.rb +49 -0
- data/app/controllers/c/admin/pages_controller.rb +94 -0
- data/app/controllers/c/admin/projects_controller.rb +55 -0
- data/app/controllers/c/admin/redirects_controller.rb +55 -0
- data/app/controllers/c/admin/roles_controller.rb +49 -0
- data/app/controllers/c/admin/slides_controller.rb +50 -0
- data/app/controllers/c/admin/slideshows_controller.rb +34 -0
- data/app/controllers/c/admin/team_members_controller.rb +61 -0
- data/app/controllers/c/admin/testimonials_controller.rb +43 -0
- data/app/controllers/c/admin/users_controller.rb +51 -0
- data/app/controllers/c/admin_controller.rb +43 -0
- data/app/controllers/c/application_controller.rb +15 -0
- data/app/controllers/c/errors_controller.rb +12 -0
- data/app/controllers/c/front/devise/passwords_controller.rb +6 -0
- data/app/controllers/c/front/devise/registrations_controller.rb +32 -0
- data/app/controllers/c/front/devise/sessions_controller.rb +27 -0
- data/app/controllers/c/front/mailchimp_controller.rb +32 -0
- data/app/controllers/c/front_controller.rb +7 -0
- data/app/controllers/c/front_end/blogs_controller.rb +21 -0
- data/app/controllers/c/front_end/enquiries_controller.rb +32 -0
- data/app/controllers/c/front_end/pages_controller.rb +19 -0
- data/app/controllers/c/main_application_controller.rb +22 -0
- data/app/helpers/c/application_helper.rb +51 -0
- data/app/helpers/c/blogs_helper.rb +113 -0
- data/app/helpers/c/c_form_builder.rb +43 -0
- data/app/helpers/c/link_to_helper.rb +25 -0
- data/app/helpers/c/navigation_helper.rb +28 -0
- data/app/helpers/c/pages_helper.rb +27 -0
- data/app/helpers/c/storefront_helper.rb +63 -0
- data/app/mailers/c/application_mailer.rb +7 -0
- data/app/mailers/c/enquiries_mailer.rb +10 -0
- data/app/models/c/ability.rb +21 -0
- data/app/models/c/application_record.rb +6 -0
- data/app/models/c/author_record.rb +13 -0
- data/app/models/c/blog.rb +43 -0
- data/app/models/c/document.rb +17 -0
- data/app/models/c/enquiry.rb +95 -0
- data/app/models/c/image.rb +11 -0
- data/app/models/c/location.rb +18 -0
- data/app/models/c/menu_item.rb +35 -0
- data/app/models/c/non_delete.rb +10 -0
- data/app/models/c/page.rb +48 -0
- data/app/models/c/page_info.rb +16 -0
- data/app/models/c/permission.rb +9 -0
- data/app/models/c/permission_subject.rb +12 -0
- data/app/models/c/project.rb +20 -0
- data/app/models/c/redirect.rb +33 -0
- data/app/models/c/role.rb +18 -0
- data/app/models/c/slide.rb +16 -0
- data/app/models/c/slideshow.rb +23 -0
- data/app/models/c/team_member.rb +33 -0
- data/app/models/c/testimonial.rb +42 -0
- data/app/models/c/user.rb +42 -0
- data/app/models/c/user_role.rb +7 -0
- data/app/models/c/weight.rb +10 -0
- data/app/models/concerns/c/authorable.rb +18 -0
- data/app/models/concerns/c/documentable.rb +18 -0
- data/app/models/concerns/c/imageable.rb +49 -0
- data/app/models/concerns/c/non_deletable.rb +30 -0
- data/app/models/concerns/c/orderable.rb +30 -0
- data/app/models/concerns/c/previewable.rb +20 -0
- data/app/models/concerns/c/site_page.rb +89 -0
- data/app/uploaders/c/file_uploader.rb +9 -0
- data/app/uploaders/c/image_uploader.rb +39 -0
- data/app/views/c/admin/_background_jobs_dropdown.html.haml +18 -0
- data/app/views/c/admin/_bread_crumbs.html.haml +7 -0
- data/app/views/c/admin/_ebay_categories.html.haml +20 -0
- data/app/views/c/admin/_flash_messages.html.haml +5 -0
- data/app/views/c/admin/_header_bar.html.haml +18 -0
- data/app/views/c/admin/_index_table.html.haml +113 -0
- data/app/views/c/admin/_index_table_data.html.haml +17 -0
- data/app/views/c/admin/_navigation_bar.html.haml +1 -0
- data/app/views/c/admin/_preview_image.html.haml +2 -0
- data/app/views/c/admin/_preview_upload.html.haml +18 -0
- data/app/views/c/admin/_seo.html.haml +11 -0
- data/app/views/c/admin/_side_menu.html.haml +26 -0
- data/app/views/c/admin/_uploaded_images_new.html.haml +13 -0
- data/app/views/c/admin/blogs/_form.html.haml +58 -0
- data/app/views/c/admin/blogs/index.html.haml +9 -0
- data/app/views/c/admin/confirm_destroy.html.haml +6 -0
- data/app/views/c/admin/confirm_mass_destroy.html.haml +10 -0
- data/app/views/c/admin/documents/_form.html.haml +8 -0
- data/app/views/c/admin/documents/index.html.haml +9 -0
- data/app/views/c/admin/edit.html.haml +15 -0
- data/app/views/c/admin/enquiries/index.html.haml +14 -0
- data/app/views/c/admin/locations/_form.html.haml +58 -0
- data/app/views/c/admin/locations/index.html.haml +9 -0
- data/app/views/c/admin/menu_items/_form.html.haml +44 -0
- data/app/views/c/admin/menu_items/_menu_item_list_item.html.haml +10 -0
- data/app/views/c/admin/menu_items/index.html.haml +10 -0
- data/app/views/c/admin/new.html.haml +8 -0
- data/app/views/c/admin/pages/_form.html.haml +93 -0
- data/app/views/c/admin/pages/_page_list_item.html.haml +10 -0
- data/app/views/c/admin/pages/dashboard.html.erb +0 -0
- data/app/views/c/admin/pages/index.html.haml +11 -0
- data/app/views/c/admin/projects/_form.html.haml +46 -0
- data/app/views/c/admin/projects/index.html.haml +9 -0
- data/app/views/c/admin/quick_edit.js.erb +6 -0
- data/app/views/c/admin/redirects/_form.html.haml +14 -0
- data/app/views/c/admin/redirects/index.html.haml +9 -0
- data/app/views/c/admin/reload_images.js.erb +2 -0
- data/app/views/c/admin/roles/_form.html.haml +42 -0
- data/app/views/c/admin/roles/index.html.haml +17 -0
- data/app/views/c/admin/set_preview_image.js.erb +1 -0
- data/app/views/c/admin/show.html.haml +1 -0
- data/app/views/c/admin/slides/_form.html.haml +19 -0
- data/app/views/c/admin/slideshows/_form.html.haml +25 -0
- data/app/views/c/admin/slideshows/index.html.haml +8 -0
- data/app/views/c/admin/team_members/_form.html.haml +20 -0
- data/app/views/c/admin/team_members/index.html.haml +10 -0
- data/app/views/c/admin/testimonials/_form.html.haml +13 -0
- data/app/views/c/admin/testimonials/index.html.haml +8 -0
- data/app/views/c/admin/users/_form.html.haml +17 -0
- data/app/views/c/admin/users/index.html.haml +12 -0
- data/app/views/c/enquiries_mailer/new_enquiry.html.haml +14 -0
- data/app/views/c/enquiries_mailer/new_enquiry.text.haml +9 -0
- data/app/views/c/errors/404.html.haml +5 -0
- data/app/views/c/errors/500.html.haml +5 -0
- data/app/views/c/front/application/_category_item.html.haml +2 -0
- data/app/views/c/front/application/_menu_item.html.haml +4 -0
- data/app/views/c/front/application/_sales_highlight.html.haml +1 -0
- data/app/views/c/front/application/_slide.html.haml +6 -0
- data/app/views/c/front/blogs/_archive_filter_month.html.haml +2 -0
- data/app/views/c/front/blogs/_archive_filter_year.html.haml +1 -0
- data/app/views/c/front/blogs/_menu_item.html.haml +2 -0
- data/app/views/c/front_end/enquiries/new.html.haml +23 -0
- data/app/views/c/front_end/enquiries/thanks.html.haml +5 -0
- data/app/views/c/front_end/pages/_sales_highlight.html.haml +7 -0
- data/app/views/c/front_end/pages/about.html.haml +8 -0
- data/app/views/c/front_end/pages/home.html.haml +19 -0
- data/app/views/c/front_end/pages/search.html.haml +16 -0
- data/app/views/c/front_end/pages/show.html.haml +7 -0
- data/app/views/c/front_end/pages/sitemap.xml.builder +25 -0
- data/app/views/c/mailchimp/_signup_newsletter.html.haml +4 -0
- data/app/views/c/main_application/_application_bar.html.haml +22 -0
- data/app/views/c/main_application/_breadcrumbs.html.haml +7 -0
- data/app/views/c/main_application/_contact_info.html.haml +5 -0
- data/app/views/c/main_application/_footer.html.haml +49 -0
- data/app/views/c/main_application/_front_head_tags.html.haml +3 -0
- data/app/views/c/main_application/_header.html.haml +55 -0
- data/app/views/c/main_application/_site_search.html.haml +3 -0
- data/app/views/c/main_application/_yield.html.haml +5 -0
- data/app/views/devise/confirmations/new.html.erb +16 -0
- data/app/views/devise/mailer/confirmation_instructions.html.erb +5 -0
- data/app/views/devise/mailer/password_change.html.erb +3 -0
- data/app/views/devise/mailer/reset_password_instructions.html.erb +8 -0
- data/app/views/devise/mailer/unlock_instructions.html.erb +7 -0
- data/app/views/devise/passwords/edit.html.haml +26 -0
- data/app/views/devise/passwords/new.html.haml +14 -0
- data/app/views/devise/registrations/edit.html.haml +40 -0
- data/app/views/devise/registrations/new.html.haml +24 -0
- data/app/views/devise/sessions/new.html.haml +20 -0
- data/app/views/devise/shared/_links.html.erb +25 -0
- data/app/views/devise/unlocks/new.html.erb +16 -0
- data/app/views/layouts/c/application.html.haml +18 -0
- data/app/views/layouts/c/cms_login_layout.html.haml +18 -0
- data/app/views/layouts/c/mailer.html.erb +245 -0
- data/app/views/layouts/c/mailer.text.erb +3 -0
- data/app/views/layouts/c/main_application.html.haml +13 -0
- data/config/environment.rb +0 -0
- data/config/initializers/carrierwave.rb +18 -0
- data/config/initializers/devise.rb +283 -0
- data/config/initializers/rack_profiler.rb +8 -0
- data/config/locales/devise.en.yml +62 -0
- data/config/locales/en.yml +17 -0
- data/config/routes.rb +150 -0
- data/db/migrate/20160819000000_migrate_schema.rb +273 -0
- data/db/seed_data/countries.txt +227 -0
- data/lib/c/engine.rb +38 -0
- data/lib/c/version.rb +4 -0
- data/lib/cd2_catton_cms.rb +51 -0
- data/lib/tasks/c_tasks.rake +28 -0
- data/spec/dummy/Gemfile +4 -0
- data/spec/dummy/Gemfile.lock +20 -0
- data/spec/dummy/Rakefile +6 -0
- data/spec/dummy/app/assets/config/manifest.js +5 -0
- data/spec/dummy/app/assets/images/placeholder.png +0 -0
- data/spec/dummy/app/assets/javascripts/application.js +26 -0
- data/spec/dummy/app/assets/javascripts/cable.js +13 -0
- data/spec/dummy/app/assets/javascripts/pages.coffee +3 -0
- data/spec/dummy/app/assets/stylesheets/application.sass +13 -0
- data/spec/dummy/app/assets/stylesheets/c/application.sass +2 -0
- data/spec/dummy/app/controllers/application_controller.rb +10 -0
- data/spec/dummy/app/controllers/blogs_controller.rb +11 -0
- data/spec/dummy/app/controllers/pages_controller.rb +13 -0
- data/spec/dummy/app/models/application_record.rb +4 -0
- data/spec/dummy/app/models/page.rb +3 -0
- data/spec/dummy/bin/bundle +4 -0
- data/spec/dummy/bin/rails +5 -0
- data/spec/dummy/bin/rake +5 -0
- data/spec/dummy/bin/setup +35 -0
- data/spec/dummy/bin/update +30 -0
- data/spec/dummy/config/application.rb +17 -0
- data/spec/dummy/config/boot.rb +6 -0
- data/spec/dummy/config/cable.yml +9 -0
- data/spec/dummy/config/database.travis.yml +3 -0
- data/spec/dummy/config/database.yml +85 -0
- data/spec/dummy/config/environment.rb +6 -0
- data/spec/dummy/config/environments/development.rb +61 -0
- data/spec/dummy/config/environments/production.rb +87 -0
- data/spec/dummy/config/environments/test.rb +43 -0
- data/spec/dummy/config/initializers/application_controller_renderer.rb +7 -0
- data/spec/dummy/config/initializers/assets.rb +21 -0
- data/spec/dummy/config/initializers/backtrace_silencers.rb +8 -0
- data/spec/dummy/config/initializers/carrierwave.rb +15 -0
- data/spec/dummy/config/initializers/commercity.rb +4 -0
- data/spec/dummy/config/initializers/cookies_serializer.rb +6 -0
- data/spec/dummy/config/initializers/filter_parameter_logging.rb +5 -0
- data/spec/dummy/config/initializers/inflections.rb +17 -0
- data/spec/dummy/config/initializers/mime_types.rb +5 -0
- data/spec/dummy/config/initializers/new_framework_defaults.rb +25 -0
- data/spec/dummy/config/initializers/session_store.rb +4 -0
- data/spec/dummy/config/initializers/wrap_parameters.rb +15 -0
- data/spec/dummy/config/locales/en.yml +23 -0
- data/spec/dummy/config/puma.rb +48 -0
- data/spec/dummy/config/routes.rb +4 -0
- data/spec/dummy/config/secrets.yml +22 -0
- data/spec/dummy/config/sidekiq.yml +6 -0
- data/spec/dummy/config/spring.rb +7 -0
- data/spec/dummy/config.ru +5 -0
- data/spec/dummy/db/schema.rb +1110 -0
- data/spec/dummy/lib/tasks/reprocess_images.rake +12 -0
- data/spec/dummy/lib/tasks/reset_all.rake +44 -0
- data/spec/dummy/lib/tasks/seeds/seed_blogs.rake +8 -0
- data/spec/dummy/lib/tasks/seeds/seed_pages.rake +24 -0
- data/spec/dummy/public/404.html +67 -0
- data/spec/dummy/public/422.html +67 -0
- data/spec/dummy/public/500.html +66 -0
- data/spec/dummy/public/apple-touch-icon-precomposed.png +0 -0
- data/spec/dummy/public/apple-touch-icon.png +0 -0
- data/spec/dummy/public/favicon.ico +0 -0
- data/spec/dummy/seed/highlight1.png +0 -0
- data/spec/dummy/seed/highlight2.png +0 -0
- data/spec/dummy/seed/images/1/main.jpg +0 -0
- data/spec/dummy/seed/images/1/thumb.JPG +0 -0
- data/spec/dummy/seed/images/1/thumb2.jpg +0 -0
- data/spec/dummy/seed/images/2/main.jpeg +0 -0
- data/spec/dummy/seed/images/2/thumb.JPG +0 -0
- data/spec/dummy/seed/images/2/thumb2.JPG +0 -0
- data/spec/dummy/spec/models/redirect_spec.rb +57 -0
- data/spec/dummy/spec/support/factory_girl.rb +8 -0
- data/spec/dummy/spec/support/seed/images/product_image.png +0 -0
- data/spec/rails_helper.rb +49 -0
- data/spec/spec_helper.rb +52 -0
- metadata +734 -0
@@ -0,0 +1,273 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
class MigrateSchema < ActiveRecord::Migration[5.0]
|
3
|
+
def up
|
4
|
+
if ActiveRecord::Base.connection.table_exists? 'c_menu_items'
|
5
|
+
puts 'Faking the migration...'
|
6
|
+
return
|
7
|
+
end
|
8
|
+
|
9
|
+
# These are extensions that must be enabled in order to support this database
|
10
|
+
enable_extension 'plpgsql'
|
11
|
+
|
12
|
+
create_table 'c_author_records', force: :cascade do |t|
|
13
|
+
t.integer 'user_id'
|
14
|
+
t.string 'authored_type'
|
15
|
+
t.integer 'authored_id'
|
16
|
+
t.datetime 'created_at', null: false
|
17
|
+
t.datetime 'updated_at', null: false
|
18
|
+
t.index %w(authored_type authored_id), name: 'index_c_author_records_on_authored_type_and_authored_id', using: :btree
|
19
|
+
t.index ['user_id'], name: 'index_c_author_records_on_user_id', using: :btree
|
20
|
+
end
|
21
|
+
|
22
|
+
create_table 'c_blogs', force: :cascade do |t|
|
23
|
+
t.string 'name'
|
24
|
+
t.text 'body'
|
25
|
+
t.datetime 'created_at', null: false
|
26
|
+
t.datetime 'updated_at', null: false
|
27
|
+
t.string 'url_alias'
|
28
|
+
t.text 'preview_body'
|
29
|
+
t.index ['created_at'], name: 'index_c_blogs_on_created_at', using: :btree
|
30
|
+
end
|
31
|
+
|
32
|
+
create_table 'c_documents', force: :cascade do |t|
|
33
|
+
t.string 'name'
|
34
|
+
t.string 'document'
|
35
|
+
t.string 'documentable_type'
|
36
|
+
t.integer 'documentable_id'
|
37
|
+
t.datetime 'created_at', null: false
|
38
|
+
t.datetime 'updated_at', null: false
|
39
|
+
end
|
40
|
+
|
41
|
+
create_table 'c_enquiries', force: :cascade do |t|
|
42
|
+
t.string 'name'
|
43
|
+
t.string 'email'
|
44
|
+
t.text 'body'
|
45
|
+
t.datetime 'created_at', null: false
|
46
|
+
t.datetime 'updated_at', null: false
|
47
|
+
end
|
48
|
+
|
49
|
+
create_table 'c_images', force: :cascade do |t|
|
50
|
+
t.string 'image'
|
51
|
+
t.string 'alt'
|
52
|
+
t.string 'caption'
|
53
|
+
t.integer 'imageable_id'
|
54
|
+
t.string 'imageable_type'
|
55
|
+
t.boolean 'featured_image', default: false
|
56
|
+
t.datetime 'created_at', null: false
|
57
|
+
t.datetime 'updated_at', null: false
|
58
|
+
t.boolean 'preview_image', default: false
|
59
|
+
end
|
60
|
+
|
61
|
+
create_table 'c_locations', force: :cascade do |t|
|
62
|
+
t.string 'name'
|
63
|
+
t.text 'body'
|
64
|
+
t.datetime 'created_at', null: false
|
65
|
+
t.datetime 'updated_at', null: false
|
66
|
+
t.string 'url_alias'
|
67
|
+
end
|
68
|
+
|
69
|
+
create_table 'c_menu_item_hierarchies', id: false, force: :cascade do |t|
|
70
|
+
t.integer 'ancestor_id', null: false
|
71
|
+
t.integer 'descendant_id', null: false
|
72
|
+
t.integer 'generations', null: false
|
73
|
+
t.index %w(ancestor_id descendant_id generations), name: 'menu_item_anc_desc_idx', unique: true, using: :btree
|
74
|
+
t.index ['descendant_id'], name: 'menu_item_desc_idx', using: :btree
|
75
|
+
end
|
76
|
+
|
77
|
+
create_table 'c_menu_items', force: :cascade do |t|
|
78
|
+
t.string 'name'
|
79
|
+
t.string 'link'
|
80
|
+
t.boolean 'visible', default: true
|
81
|
+
t.integer 'parent_id'
|
82
|
+
t.integer 'weight'
|
83
|
+
t.string 'machine_name'
|
84
|
+
t.integer 'page_id'
|
85
|
+
t.datetime 'created_at', null: false
|
86
|
+
t.datetime 'updated_at', null: false
|
87
|
+
t.string 'target'
|
88
|
+
t.index ['page_id'], name: 'index_c_menu_items_on_page_id', using: :btree
|
89
|
+
end
|
90
|
+
|
91
|
+
create_table 'c_non_deletes', force: :cascade do |t|
|
92
|
+
t.boolean 'deleted', default: false
|
93
|
+
t.string 'non_deletable_type'
|
94
|
+
t.integer 'non_deletable_id'
|
95
|
+
t.datetime 'created_at', null: false
|
96
|
+
t.datetime 'updated_at', null: false
|
97
|
+
t.index %w(non_deletable_type non_deletable_id), name: 'index_c_non_deletes_on_non_deletable_type_and_non_deletable_id', using: :btree
|
98
|
+
end
|
99
|
+
|
100
|
+
create_table 'c_page_hierarchies', id: false, force: :cascade do |t|
|
101
|
+
t.integer 'ancestor_id', null: false
|
102
|
+
t.integer 'descendant_id', null: false
|
103
|
+
t.integer 'generations', null: false
|
104
|
+
t.index %w(ancestor_id descendant_id generations), name: 'page_anc_desc_idx', unique: true, using: :btree
|
105
|
+
t.index ['descendant_id'], name: 'page_desc_idx', using: :btree
|
106
|
+
end
|
107
|
+
|
108
|
+
create_table 'c_page_infos', force: :cascade do |t|
|
109
|
+
t.string 'title'
|
110
|
+
t.text 'meta_description'
|
111
|
+
t.string 'url_alias'
|
112
|
+
t.boolean 'published', default: true
|
113
|
+
t.boolean 'protected', default: false
|
114
|
+
t.string 'page_type'
|
115
|
+
t.integer 'page_id'
|
116
|
+
t.boolean 'home_page', default: false
|
117
|
+
t.integer 'order'
|
118
|
+
t.datetime 'created_at', null: false
|
119
|
+
t.datetime 'updated_at', null: false
|
120
|
+
t.index %w(page_type page_id), name: 'index_c_page_infos_on_page_type_and_page_id', using: :btree
|
121
|
+
t.index ['url_alias'], name: 'index_c_page_infos_on_url_alias', using: :btree
|
122
|
+
end
|
123
|
+
|
124
|
+
create_table 'c_pages', force: :cascade do |t|
|
125
|
+
t.string 'name'
|
126
|
+
t.text 'body'
|
127
|
+
t.string 'layout'
|
128
|
+
t.boolean 'in_menu'
|
129
|
+
t.string 'menu_item'
|
130
|
+
t.datetime 'created_at', null: false
|
131
|
+
t.datetime 'updated_at', null: false
|
132
|
+
t.string 'url_alias'
|
133
|
+
t.text 'preview_body'
|
134
|
+
t.integer 'parent_id'
|
135
|
+
t.integer 'weight'
|
136
|
+
end
|
137
|
+
|
138
|
+
create_table 'c_permission_subjects', force: :cascade do |t|
|
139
|
+
t.string 'name'
|
140
|
+
t.text 'body'
|
141
|
+
t.string 'subject_type'
|
142
|
+
t.integer 'subject_id'
|
143
|
+
t.datetime 'created_at', null: false
|
144
|
+
t.datetime 'updated_at', null: false
|
145
|
+
end
|
146
|
+
|
147
|
+
create_table 'c_permissions', force: :cascade do |t|
|
148
|
+
t.integer 'role_id'
|
149
|
+
t.integer 'permission_subject_id'
|
150
|
+
t.boolean 'read'
|
151
|
+
t.boolean 'new'
|
152
|
+
t.boolean 'edit'
|
153
|
+
t.boolean 'remove'
|
154
|
+
t.datetime 'created_at', null: false
|
155
|
+
t.datetime 'updated_at', null: false
|
156
|
+
t.index ['permission_subject_id'], name: 'index_c_permissions_on_permission_subject_id', using: :btree
|
157
|
+
t.index ['role_id'], name: 'index_c_permissions_on_role_id', using: :btree
|
158
|
+
end
|
159
|
+
|
160
|
+
create_table 'c_projects', force: :cascade do |t|
|
161
|
+
t.string 'name'
|
162
|
+
t.text 'body'
|
163
|
+
t.string 'url_alias'
|
164
|
+
t.datetime 'created_at', null: false
|
165
|
+
t.datetime 'updated_at', null: false
|
166
|
+
end
|
167
|
+
|
168
|
+
create_table 'c_redirects', force: :cascade do |t|
|
169
|
+
t.string 'old_url'
|
170
|
+
t.string 'new_url'
|
171
|
+
t.datetime 'last_used'
|
172
|
+
t.integer 'used_counter', default: 0
|
173
|
+
t.datetime 'created_at', null: false
|
174
|
+
t.datetime 'updated_at', null: false
|
175
|
+
end
|
176
|
+
|
177
|
+
create_table 'c_roles', force: :cascade do |t|
|
178
|
+
t.string 'name'
|
179
|
+
t.text 'body'
|
180
|
+
t.datetime 'created_at', null: false
|
181
|
+
t.datetime 'updated_at', null: false
|
182
|
+
end
|
183
|
+
|
184
|
+
create_table 'c_slides', force: :cascade do |t|
|
185
|
+
t.string 'name'
|
186
|
+
t.string 'url'
|
187
|
+
t.string 'image'
|
188
|
+
t.integer 'slideshow_id'
|
189
|
+
t.datetime 'created_at', null: false
|
190
|
+
t.datetime 'updated_at', null: false
|
191
|
+
t.index ['slideshow_id'], name: 'index_c_slides_on_slideshow_id', using: :btree
|
192
|
+
end
|
193
|
+
|
194
|
+
create_table 'c_slideshows', force: :cascade do |t|
|
195
|
+
t.string 'name'
|
196
|
+
t.string 'machine_name'
|
197
|
+
t.datetime 'created_at', null: false
|
198
|
+
t.datetime 'updated_at', null: false
|
199
|
+
t.text 'body'
|
200
|
+
end
|
201
|
+
|
202
|
+
create_table 'c_team_members', force: :cascade do |t|
|
203
|
+
t.string 'name'
|
204
|
+
t.string 'role'
|
205
|
+
t.string 'image'
|
206
|
+
t.text 'body'
|
207
|
+
t.datetime 'created_at', null: false
|
208
|
+
t.datetime 'updated_at', null: false
|
209
|
+
end
|
210
|
+
|
211
|
+
create_table 'c_testimonials', force: :cascade do |t|
|
212
|
+
t.text 'quote'
|
213
|
+
t.string 'author'
|
214
|
+
t.integer 'project_id'
|
215
|
+
t.datetime 'created_at', null: false
|
216
|
+
t.datetime 'updated_at', null: false
|
217
|
+
end
|
218
|
+
|
219
|
+
create_table 'c_user_roles', force: :cascade do |t|
|
220
|
+
t.integer 'user_id'
|
221
|
+
t.integer 'role_id'
|
222
|
+
t.datetime 'created_at', null: false
|
223
|
+
t.datetime 'updated_at', null: false
|
224
|
+
t.index ['role_id'], name: 'index_c_user_roles_on_role_id', using: :btree
|
225
|
+
t.index ['user_id'], name: 'index_c_user_roles_on_user_id', using: :btree
|
226
|
+
end
|
227
|
+
|
228
|
+
create_table 'c_users', force: :cascade do |t|
|
229
|
+
t.string 'name'
|
230
|
+
t.string 'email', default: '', null: false
|
231
|
+
t.string 'encrypted_password', default: '', null: false
|
232
|
+
t.string 'reset_password_token'
|
233
|
+
t.datetime 'reset_password_sent_at'
|
234
|
+
t.datetime 'remember_created_at'
|
235
|
+
t.integer 'sign_in_count', default: 0, null: false
|
236
|
+
t.datetime 'current_sign_in_at'
|
237
|
+
t.datetime 'last_sign_in_at'
|
238
|
+
t.string 'current_sign_in_ip'
|
239
|
+
t.string 'last_sign_in_ip'
|
240
|
+
t.datetime 'created_at', null: false
|
241
|
+
t.datetime 'updated_at', null: false
|
242
|
+
t.boolean 'cd2admin', default: false
|
243
|
+
t.index ['email'], name: 'index_c_users_on_email', unique: true, using: :btree
|
244
|
+
t.index ['reset_password_token'], name: 'index_c_users_on_reset_password_token', unique: true, using: :btree
|
245
|
+
end
|
246
|
+
|
247
|
+
create_table 'c_weights', force: :cascade do |t|
|
248
|
+
t.integer 'value'
|
249
|
+
t.string 'orderable_type'
|
250
|
+
t.integer 'orderable_id'
|
251
|
+
t.datetime 'created_at', null: false
|
252
|
+
t.datetime 'updated_at', null: false
|
253
|
+
t.index %w(orderable_type orderable_id), name: 'index_c_weights_on_orderable_type_and_orderable_id', using: :btree
|
254
|
+
end
|
255
|
+
|
256
|
+
create_table 'ckeditor_assets', force: :cascade do |t|
|
257
|
+
t.string 'data_file_name', null: false
|
258
|
+
t.string 'data_content_type'
|
259
|
+
t.integer 'data_file_size'
|
260
|
+
t.integer 'assetable_id'
|
261
|
+
t.string 'assetable_type', limit: 30
|
262
|
+
t.string 'type', limit: 30
|
263
|
+
t.integer 'width'
|
264
|
+
t.integer 'height'
|
265
|
+
t.datetime 'created_at', null: false
|
266
|
+
t.datetime 'updated_at', null: false
|
267
|
+
t.index %w(assetable_type assetable_id), name: 'idx_ckeditor_assetable', using: :btree
|
268
|
+
t.index %w(assetable_type type assetable_id), name: 'idx_ckeditor_assetable_type', using: :btree
|
269
|
+
end
|
270
|
+
|
271
|
+
add_foreign_key 'c_menu_items', 'c_menu_items', column: 'parent_id', on_delete: :nullify
|
272
|
+
end
|
273
|
+
end
|
@@ -0,0 +1,227 @@
|
|
1
|
+
AD AND Andorra EU .ad EUR 4
|
2
|
+
AE ARE United Arab Emirates AS .ae AED 8
|
3
|
+
AF AFG Afghanistan AS .af AFN 10
|
4
|
+
AG ATG Antigua and Barbuda NA .ag XCD 10
|
5
|
+
AI AIA Anguilla NA .ai XCD 10
|
6
|
+
AL ALB Albania EU .al ALL 5
|
7
|
+
AM ARM Armenia AS .am AMD 10
|
8
|
+
AO AGO Angola AF .ao AOA 10
|
9
|
+
AR ARG Argentina SA .ar ARS 10
|
10
|
+
AS ASM American Samoa OC .as USD 10
|
11
|
+
AT AUT Austria EU .at EUR 3
|
12
|
+
AU AUS Australia OC .au AUD 8
|
13
|
+
AW ABW Aruba NA .aw AWG 10
|
14
|
+
AZ AZE Azerbaijan AS .az AZN 10
|
15
|
+
BA BIH Bosnia and Herzegovina EU .ba BAM 5
|
16
|
+
BB BRB Barbados NA .bb BBD 10
|
17
|
+
BD BGD Bangladesh AS .bd BDT 10
|
18
|
+
BE BEL Belgium EU .be EUR 1
|
19
|
+
BF BFA Burkina Faso AF .bf XOF 10
|
20
|
+
BG BGR Bulgaria EU .bg BGN 4
|
21
|
+
BH BHR Bahrain AS .bh BHD 9
|
22
|
+
BI BDI Burundi AF .bi BIF 10
|
23
|
+
BJ BEN Benin AF .bj XOF 10
|
24
|
+
BL BLM Saint Barthelemy NA .gp EUR 10
|
25
|
+
BM BMU Bermuda NA .bm BMD 10
|
26
|
+
BN BRN Brunei AS .bn BND 9
|
27
|
+
BO BOL Bolivia SA .bo BOB 10
|
28
|
+
BQ BES Bonaire, Saint Eustatius and Saba NA .bq USD 10
|
29
|
+
BR BRA Brazil SA .br BRL 10
|
30
|
+
BS BHS Bahamas NA .bs BSD 10
|
31
|
+
BT BTN Bhutan AS .bt BTN 10
|
32
|
+
BW BWA Botswana AF .bw BWP 10
|
33
|
+
BY BLR Belarus EU .by BYR 5
|
34
|
+
BZ BLZ Belize NA .bz BZD 10
|
35
|
+
CA CAN Canada NA .ca CAD 7
|
36
|
+
CD COD Democratic Republic of the Congo AF .cd CDF 10
|
37
|
+
CF CAF Central African Republic AF .cf XAF 10
|
38
|
+
CG COG Republic of the Congo AF .cg XAF 10
|
39
|
+
CH CHE Switzerland EU .ch CHF 5
|
40
|
+
CI CIV Ivory Coast AF .ci XOF 10
|
41
|
+
CK COK Cook Islands OC .ck NZD 10
|
42
|
+
CL CHL Chile SA .cl CLP 10
|
43
|
+
CM CMR Cameroon AF .cm XAF 10
|
44
|
+
CN CHN China AS .cn CNY 8
|
45
|
+
CO COL Colombia SA .co COP 10
|
46
|
+
CR CRI Costa Rica NA .cr CRC 10
|
47
|
+
CU CUB Cuba NA .cu CUP 10
|
48
|
+
CV CPV Cape Verde AF .cv CVE 10
|
49
|
+
CW CUW Curacao NA .cw ANG 10
|
50
|
+
CY CYP Cyprus EU .cy EUR 4
|
51
|
+
CZ CZE Czech Republic EU .cz CZK 4
|
52
|
+
DE DEU Germany EU .de EUR 1
|
53
|
+
DJ DJI Djibouti AF .dj DJF 10
|
54
|
+
DK DNK Denmark EU .dk DKK 3
|
55
|
+
DM DMA Dominica NA .dm XCD 10
|
56
|
+
DO DOM Dominican Republic NA .do DOP 10
|
57
|
+
DZ DZA Algeria AF .dz DZD 10
|
58
|
+
EC ECU Ecuador SA .ec USD 10
|
59
|
+
EE EST Estonia EU .ee EUR 4
|
60
|
+
EG EGY Egypt AF .eg EGP 10
|
61
|
+
ER ERI Eritrea AF .er ERN 10
|
62
|
+
ES ESP Spain EU .es EUR 3
|
63
|
+
ET ETH Ethiopia AF .et ETB 10
|
64
|
+
FI FIN Finland EU .fi EUR 3
|
65
|
+
FJ FJI Fiji OC .fj FJD 10
|
66
|
+
FK FLK Falkland Islands SA .fk FKP 10
|
67
|
+
FM FSM Micronesia OC .fm USD 10
|
68
|
+
FO FRO Faroe Islands EU .fo DKK 5
|
69
|
+
FR FRA France EU .fr EUR 2
|
70
|
+
GA GAB Gabon AF .ga XAF 10
|
71
|
+
GB GBR United Kingdom EU .uk GBP 0
|
72
|
+
GD GRD Grenada NA .gd XCD 10
|
73
|
+
GE GEO Georgia AS .ge GEL 10
|
74
|
+
GF GUF French Guiana SA .gf EUR 10
|
75
|
+
GH GHA Ghana AF .gh GHS 10
|
76
|
+
GI GIB Gibraltar EU .gi GIP 5
|
77
|
+
GL GRL Greenland NA .gl DKK 5
|
78
|
+
GM GMB Gambia AF .gm GMD 10
|
79
|
+
GN GIN Guinea AF .gn GNF 10
|
80
|
+
GP GLP Guadeloupe NA .gp EUR 10
|
81
|
+
GQ GNQ Equatorial Guinea AF .gq XAF 10
|
82
|
+
GR GRC Greece EU .gr EUR 4
|
83
|
+
GT GTM Guatemala NA .gt GTQ 10
|
84
|
+
GU GUM Guam OC .gu USD 10
|
85
|
+
GW GNB Guinea-Bissau AF .gw XOF 10
|
86
|
+
GY GUY Guyana SA .gy GYD 10
|
87
|
+
HK HKG Hong Kong AS .hk HKD 8
|
88
|
+
HN HND Honduras NA .hn HNL 10
|
89
|
+
HR HRV Croatia EU .hr HRK 4
|
90
|
+
HT HTI Haiti NA .ht HTG 10
|
91
|
+
HU HUN Hungary EU .hu HUF 4
|
92
|
+
ID IDN Indonesia AS .id IDR 8
|
93
|
+
IE IRL Ireland EU .ie EUR 1
|
94
|
+
IL ISR Israel AS .il ILS 10
|
95
|
+
IN IND India AS .in INR 8
|
96
|
+
IQ IRQ Iraq AS .iq IQD 10
|
97
|
+
IR IRN Iran AS .ir IRR 10
|
98
|
+
IS ISL Iceland EU .is ISK 5
|
99
|
+
IT ITA Italy EU .it EUR 3
|
100
|
+
JM JAM Jamaica NA .jm JMD 10
|
101
|
+
JO JOR Jordan AS .jo JOD 9
|
102
|
+
JP JPN Japan AS .jp JPY 8
|
103
|
+
KE KEN Kenya AF .ke KES 10
|
104
|
+
KG KGZ Kyrgyzstan AS .kg KGS 10
|
105
|
+
KH KHM Cambodia AS .kh KHR 10
|
106
|
+
KI KIR Kiribati OC .ki AUD 10
|
107
|
+
KM COM Comoros AF .km KMF 10
|
108
|
+
KN KNA Saint Kitts and Nevis NA .kn XCD 10
|
109
|
+
KP PRK North Korea AS .kp KPW 10
|
110
|
+
KR KOR South Korea AS .kr KRW 8
|
111
|
+
XK XKX Kosovo EU EUR 5
|
112
|
+
KW KWT Kuwait AS .kw KWD 9
|
113
|
+
KY CYM Cayman Islands NA .ky KYD 5
|
114
|
+
KZ KAZ Kazakhstan AS .kz KZT 10
|
115
|
+
LA LAO Laos AS .la LAK 10
|
116
|
+
LB LBN Lebanon AS .lb LBP 10
|
117
|
+
LC LCA Saint Lucia NA .lc XCD 10
|
118
|
+
LI LIE Liechtenstein EU .li CHF 5
|
119
|
+
LK LKA Sri Lanka AS .lk LKR 10
|
120
|
+
LR LBR Liberia AF .lr LRD 10
|
121
|
+
LS LSO Lesotho AF .ls LSL 10
|
122
|
+
LT LTU Lithuania EU .lt LTL 4
|
123
|
+
LU LUX Luxembourg EU .lu EUR 1
|
124
|
+
LV LVA Latvia EU .lv LVL 4
|
125
|
+
LY LBY Libya AF .ly LYD 10
|
126
|
+
MA MAR Morocco AF .ma MAD 10
|
127
|
+
MC MCO Monaco EU .mc EUR 2
|
128
|
+
MD MDA Moldova EU .md MDL 5
|
129
|
+
ME MNE Montenegro EU .me EUR 5
|
130
|
+
MF MAF Saint Martin NA .gp EUR 10
|
131
|
+
MG MDG Madagascar AF .mg MGA 10
|
132
|
+
MH MHL Marshall Islands OC .mh USD 10
|
133
|
+
MK MKD Macedonia EU .mk MKD 5
|
134
|
+
ML MLI Mali AF .ml XOF 10
|
135
|
+
MM MMR Myanmar AS .mm MMK 10
|
136
|
+
MN MNG Mongolia AS .mn MNT 10
|
137
|
+
MO MAC Macao AS .mo MOP 10
|
138
|
+
MQ MTQ Martinique NA .mq EUR 10
|
139
|
+
MR MRT Mauritania AF .mr MRO 10
|
140
|
+
MS MSR Montserrat NA .ms XCD 10
|
141
|
+
MT MLT Malta EU .mt EUR 4
|
142
|
+
MU MUS Mauritius AF .mu MUR 10
|
143
|
+
MV MDV Maldives AS .mv MVR 10
|
144
|
+
MW MWI Malawi AF .mw MWK 10
|
145
|
+
MX MEX Mexico NA .mx MXN 7
|
146
|
+
MY MYS Malaysia AS .my MYR 8
|
147
|
+
MZ MOZ Mozambique AF .mz MZN 10
|
148
|
+
NA NAM Namibia AF .na NAD 10
|
149
|
+
NC NCL New Caledonia OC .nc XPF 10
|
150
|
+
NE NER Niger AF .ne XOF 10
|
151
|
+
NG NGA Nigeria AF .ng NGN 10
|
152
|
+
NI NIC Nicaragua NA .ni NIO 10
|
153
|
+
NL NLD Netherlands EU .nl EUR 1
|
154
|
+
NO NOR Norway EU .no NOK 5
|
155
|
+
NP NPL Nepal AS .np NPR 10
|
156
|
+
NR NRU Nauru OC .nr AUD 10
|
157
|
+
NU NIU Niue OC .nu NZD 10
|
158
|
+
NZ NZL New Zealand OC .nz NZD 9
|
159
|
+
OM OMN Oman AS .om OMR 9
|
160
|
+
PA PAN Panama NA .pa PAB 10
|
161
|
+
PE PER Peru SA .pe PEN 10
|
162
|
+
PG PNG Papua New Guinea OC .pg PGK 10
|
163
|
+
PH PHL Philippines AS .ph PHP 8
|
164
|
+
PK PAK Pakistan AS .pk PKR 10
|
165
|
+
PL POL Poland EU .pl PLN 4
|
166
|
+
PR PRI Puerto Rico NA .pr USD 10
|
167
|
+
PT PRT Portugal EU .pt EUR 3
|
168
|
+
PW PLW Palau OC .pw USD 10
|
169
|
+
PY PRY Paraguay SA .py PYG 10
|
170
|
+
QA QAT Qatar AS .qa QAR 9
|
171
|
+
RE REU Reunion AF .re EUR 10
|
172
|
+
RO ROU Romania EU .ro RON 4
|
173
|
+
RS SRB Serbia EU .rs RSD 5
|
174
|
+
RU RUS Russia EU .ru RUB 5
|
175
|
+
RW RWA Rwanda AF .rw RWF 10
|
176
|
+
SA SAU Saudi Arabia AS .sa SAR 9
|
177
|
+
SB SLB Solomon Islands OC .sb SBD 9
|
178
|
+
SC SYC Seychelles AF .sc SCR 10
|
179
|
+
SD SDN Sudan AF .sd SDG 10
|
180
|
+
SS SSD South Sudan AF SSP 10
|
181
|
+
SE SWE Sweden EU .se SEK 3
|
182
|
+
SG SGP Singapore AS .sg SGD 8
|
183
|
+
SH SHN Saint Helena AF .sh SHP 10
|
184
|
+
SI SVN Slovenia EU .si EUR 4
|
185
|
+
SK SVK Slovakia EU .sk EUR 4
|
186
|
+
SL SLE Sierra Leone AF .sl SLL 10
|
187
|
+
SM SMR San Marino EU .sm EUR 3
|
188
|
+
SN SEN Senegal AF .sn XOF 10
|
189
|
+
SO SOM Somalia AF .so SOS 10
|
190
|
+
SR SUR Suriname SA .sr SRD 10
|
191
|
+
ST STP Sao Tome and Principe AF .st STD 10
|
192
|
+
SV SLV El Salvador NA .sv USD 10
|
193
|
+
SX SXM Sint Maarten NA .sx ANG 10
|
194
|
+
SY SYR Syria AS .sy SYP 10
|
195
|
+
SZ SWZ Swaziland AF .sz SZL 10
|
196
|
+
TC TCA Turks and Caicos Islands NA .tc USD 10
|
197
|
+
TD TCD Chad AF .td XAF 10
|
198
|
+
TG TGO Togo AF .tg XOF 10
|
199
|
+
TH THA Thailand AS .th THB 8
|
200
|
+
TJ TJK Tajikistan AS .tj TJS 10
|
201
|
+
TL TLS East Timor OC .tl USD 10
|
202
|
+
TN TUN Tunisia AF .tn TND 10
|
203
|
+
TO TON Tonga OC .to TOP 10
|
204
|
+
TR TUR Turkey AS .tr TRY 5
|
205
|
+
TT TTO Trinidad and Tobago NA .tt TTD 10
|
206
|
+
TV TUV Tuvalu OC .tv AUD 10
|
207
|
+
TW TWN Taiwan AS .tw TWD 8
|
208
|
+
TZ TZA Tanzania AF .tz TZS 10
|
209
|
+
UA UKR Ukraine EU .ua UAH 5
|
210
|
+
UG UGA Uganda AF .ug UGX 10
|
211
|
+
US USA United States NA .us USD 6
|
212
|
+
UY URY Uruguay SA .uy UYU 10
|
213
|
+
UZ UZB Uzbekistan AS .uz UZS 10
|
214
|
+
VC VCT Saint Vincent and the Grenadines NA .vc XCD 10
|
215
|
+
VE VEN Venezuela SA .ve VEF 10
|
216
|
+
VG VGB British Virgin Islands NA .vg USD 10
|
217
|
+
VI VIR U.S. Virgin Islands NA .vi USD 10
|
218
|
+
VN VNM Vietnam AS .vn VND 8
|
219
|
+
VU VUT Vanuatu OC .vu VUV 10
|
220
|
+
WS WSM Samoa OC .ws WST 10
|
221
|
+
YE YEM Yemen AS .ye YER 9
|
222
|
+
YT MYT Mayotte AF .yt EUR 10
|
223
|
+
ZA ZAF South Africa AF .za ZAR 9
|
224
|
+
ZM ZMB Zambia AF .zm ZMK 10
|
225
|
+
ZW ZWE Zimbabwe AF .zw ZWL 10
|
226
|
+
CS SCG Serbia and Montenegro EU .cs RSD 5
|
227
|
+
AN ANT Netherlands Antilles NA .an ANG 10
|
data/lib/c/engine.rb
ADDED
@@ -0,0 +1,38 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
module C
|
3
|
+
class Engine < ::Rails::Engine
|
4
|
+
isolate_namespace C
|
5
|
+
|
6
|
+
config.generators do |g|
|
7
|
+
g.test_framework :rspec, fixture: false
|
8
|
+
g.fixture_replacement :factory_girl, dir: 'spec/factories'
|
9
|
+
g.assets false
|
10
|
+
g.helper false
|
11
|
+
end
|
12
|
+
|
13
|
+
initializer :append_migrations do |app|
|
14
|
+
config.paths['db/migrate'].expanded.each do |expanded_path|
|
15
|
+
app.config.paths['db/migrate'] << expanded_path
|
16
|
+
end
|
17
|
+
end
|
18
|
+
|
19
|
+
initializer 'my_engine.action_controller' do
|
20
|
+
end
|
21
|
+
|
22
|
+
# TODO: this puts an error class on fields - is this the best place for it?
|
23
|
+
ActionView::Base.field_error_proc = proc do |html_tag, _instance|
|
24
|
+
class_attr_index = html_tag.index 'class="'
|
25
|
+
if class_attr_index
|
26
|
+
html_tag.insert class_attr_index + 7, 'error'
|
27
|
+
else
|
28
|
+
html_tag.insert html_tag.index('>'), ' class="error"'
|
29
|
+
end
|
30
|
+
end
|
31
|
+
|
32
|
+
# Date
|
33
|
+
Date::DATE_FORMATS[:default] = '%d/%m/%Y'
|
34
|
+
|
35
|
+
# Time
|
36
|
+
Time::DATE_FORMATS[:default] = '%H:%M - %d/%m/%Y'
|
37
|
+
end
|
38
|
+
end
|
data/lib/c/version.rb
ADDED
@@ -0,0 +1,51 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
require 'rubygems'
|
3
|
+
require 'fog/aws'
|
4
|
+
Gem.loaded_specs['cd2_catton_cms'].dependencies.each do |d|
|
5
|
+
require d.name unless ['fog-aws', 'google_currency'].include?(d.name)
|
6
|
+
end
|
7
|
+
|
8
|
+
require 'c/engine'
|
9
|
+
|
10
|
+
module C
|
11
|
+
class << self
|
12
|
+
mattr_accessor :store_name
|
13
|
+
self.store_name = 'Name'
|
14
|
+
|
15
|
+
mattr_accessor :domain_name
|
16
|
+
self.domain_name = 'example.com'
|
17
|
+
|
18
|
+
mattr_accessor :email, :enquiries_email, :errors_email, :order_notification_email
|
19
|
+
self.email = 'web@example.org'
|
20
|
+
self.enquiries_email = 'web@example.org'
|
21
|
+
self.errors_email = 'web@example.org'
|
22
|
+
self.order_notification_email = 'recipient@example.com'
|
23
|
+
|
24
|
+
mattr_accessor :external_logo_url
|
25
|
+
self.external_logo_url = ''
|
26
|
+
|
27
|
+
mattr_accessor :primary_color
|
28
|
+
self.primary_color = '#5C5C5C'
|
29
|
+
|
30
|
+
mattr_accessor :admin_mount
|
31
|
+
self.admin_mount = 'admin'
|
32
|
+
|
33
|
+
mattr_accessor :account_mount
|
34
|
+
self.account_mount = 'account'
|
35
|
+
|
36
|
+
mattr_accessor :commerce
|
37
|
+
self.commerce = true
|
38
|
+
|
39
|
+
mattr_accessor :content_sections
|
40
|
+
self.content_sections = [:pages, :services, :projects, :locations, :blogs, :testimonials, :slideshows, :team]
|
41
|
+
|
42
|
+
# specify channel name to display first channel image on index tables
|
43
|
+
mattr_accessor :display_thumbnail
|
44
|
+
self.display_thumbnail = nil
|
45
|
+
end
|
46
|
+
|
47
|
+
# this function maps the vars from your app into your engine
|
48
|
+
def self.setup(*)
|
49
|
+
yield self
|
50
|
+
end
|
51
|
+
end
|
@@ -0,0 +1,28 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
namespace :c do
|
3
|
+
task install: [:environment] do
|
4
|
+
C::User.create!(name: 'Admin', email: 'web@example.org', password: 'password', cd2admin: true)
|
5
|
+
Rake::Task['c:create_permission_subjects'].invoke
|
6
|
+
Rake::Task['c:create_admin_role'].invoke
|
7
|
+
end
|
8
|
+
|
9
|
+
task create_permission_subjects: :environment do
|
10
|
+
C::PermissionSubject.create(name: 'User', subject_type: 'C::User')
|
11
|
+
C::PermissionSubject.create(name: 'Category', subject_type: 'C::Category')
|
12
|
+
C::PermissionSubject.create(name: 'Roles', subject_type: 'C::Role')
|
13
|
+
C::PermissionSubject.create(name: 'Countries', subject_type: 'C::Countries')
|
14
|
+
C::PermissionSubject.create(name: 'Settings', subject_type: 'C::Setting')
|
15
|
+
end
|
16
|
+
|
17
|
+
task create_admin_role: [:environment, :create_permission_subjects] do
|
18
|
+
role = C::Role.create(name: 'Admin', body: 'Main administrator of the store')
|
19
|
+
role.build_or_find_permissions
|
20
|
+
role.permissions.each do |permission|
|
21
|
+
permission.read = true
|
22
|
+
permission.new = true
|
23
|
+
permission.edit = true
|
24
|
+
permission.remove = true
|
25
|
+
end
|
26
|
+
role.save!
|
27
|
+
end
|
28
|
+
end
|
data/spec/dummy/Gemfile
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
GEM
|
2
|
+
remote: https://rubygems.org/
|
3
|
+
specs:
|
4
|
+
rails_12factor (0.0.3)
|
5
|
+
rails_serve_static_assets
|
6
|
+
rails_stdout_logging
|
7
|
+
rails_serve_static_assets (0.0.5)
|
8
|
+
rails_stdout_logging (0.0.5)
|
9
|
+
|
10
|
+
PLATFORMS
|
11
|
+
ruby
|
12
|
+
|
13
|
+
DEPENDENCIES
|
14
|
+
rails_12factor
|
15
|
+
|
16
|
+
RUBY VERSION
|
17
|
+
ruby 2.4.0p0
|
18
|
+
|
19
|
+
BUNDLED WITH
|
20
|
+
1.14.6
|
data/spec/dummy/Rakefile
ADDED
Binary file
|