enju_event 0.1.19 → 0.2.0.beta.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.rdoc +3 -3
- data/Rakefile +9 -15
- data/app/controllers/concerns/enju_event/controller.rb +13 -0
- data/app/controllers/event_categories_controller.rb +13 -2
- data/app/controllers/event_export_files_controller.rb +13 -3
- data/app/controllers/event_import_files_controller.rb +14 -4
- data/app/controllers/event_import_results_controller.rb +12 -1
- data/app/controllers/events_controller.rb +18 -8
- data/app/controllers/participates_controller.rb +11 -1
- data/app/controllers/places_controller.rb +64 -0
- data/app/jobs/event_export_file_job.rb +7 -0
- data/app/jobs/event_import_file_job.rb +7 -0
- data/app/models/event.rb +6 -5
- data/app/models/event_category.rb +3 -4
- data/app/models/event_export_file.rb +4 -5
- data/app/models/event_export_file_transition.rb +4 -4
- data/app/models/event_import_file.rb +8 -9
- data/app/models/event_import_file_transition.rb +4 -4
- data/app/models/event_import_result.rb +2 -3
- data/app/models/participate.rb +2 -3
- data/app/models/place.rb +18 -0
- data/app/policies/event_category_policy.rb +23 -0
- data/app/policies/event_export_file_policy.rb +21 -0
- data/app/policies/event_import_file_policy.rb +21 -0
- data/app/policies/event_import_result_policy.rb +21 -0
- data/app/policies/event_policy.rb +21 -0
- data/app/policies/participate_policy.rb +21 -0
- data/app/policies/place_policy.rb +21 -0
- data/app/views/event_categories/index.html.erb +4 -4
- data/app/views/event_categories/show.html.erb +1 -1
- data/app/views/events/_calendar.html.erb +1 -1
- data/app/views/events/{index.mobile.erb → index.html+phone.erb} +6 -6
- data/app/views/events/index.html.erb +11 -12
- data/app/views/events/index.rss.builder +2 -2
- data/app/views/events/{show.mobile.erb → show.html+phone.erb} +0 -0
- data/app/views/events/show.html.erb +2 -2
- data/app/views/picture_files/_index_event.html.erb +4 -4
- data/app/views/places/_form.html.erb +37 -0
- data/app/views/places/edit.html.erb +6 -0
- data/app/views/places/index.html.erb +35 -0
- data/app/views/places/new.html.erb +5 -0
- data/app/views/places/show.html.erb +29 -0
- data/config/routes.rb +1 -0
- data/db/migrate/20151128142913_create_places.rb +15 -0
- data/db/migrate/20151201163718_add_place_id_to_event.rb +6 -0
- data/db/migrate/20160703184258_add_most_recent_to_event_import_file_transitions.rb +9 -0
- data/db/migrate/20160703184311_add_most_recent_to_event_export_file_transitions.rb +9 -0
- data/lib/enju_event.rb +0 -19
- data/lib/enju_event/version.rb +1 -1
- data/lib/tasks/enju_event_tasks.rake +1 -1
- data/spec/controllers/event_categories_controller_spec.rb +58 -58
- data/spec/controllers/event_export_files_controller_spec.rb +6 -6
- data/spec/controllers/event_import_files_controller_spec.rb +4 -4
- data/spec/controllers/event_import_results_controller_spec.rb +2 -2
- data/spec/controllers/events_controller_spec.rb +6 -6
- data/spec/controllers/participates_controller_spec.rb +54 -54
- data/spec/dummy/app/controllers/application_controller.rb +8 -4
- data/spec/dummy/app/models/user.rb +2 -2
- data/spec/dummy/config/application.rb +5 -24
- data/spec/dummy/config/environments/development.rb +25 -14
- data/spec/dummy/config/environments/production.rb +50 -31
- data/spec/dummy/config/environments/test.rb +19 -14
- data/spec/dummy/config/routes.rb +3 -0
- data/spec/dummy/db/migrate/20140821151023_create_colors.rb +14 -0
- data/spec/dummy/db/migrate/20150924115059_create_withdraws.rb +13 -0
- data/spec/dummy/db/migrate/20151213070943_add_translation_table_to_library_group.rb +13 -0
- data/spec/dummy/db/migrate/20151213072705_add_footer_banner_to_library_group.rb +9 -0
- data/spec/dummy/db/schema.rb +52 -1
- data/spec/fixtures/event_categories.yml +3 -4
- data/spec/fixtures/event_export_files.yml +4 -4
- data/spec/fixtures/event_import_files.yml +8 -8
- data/spec/fixtures/event_import_results.yml +2 -3
- data/spec/fixtures/events.yml +7 -7
- data/spec/fixtures/participates.yml +2 -3
- data/spec/models/event_category_spec.rb +3 -4
- data/spec/models/event_export_file_spec.rb +5 -5
- data/spec/models/event_import_file_spec.rb +9 -9
- data/spec/models/event_import_result_spec.rb +2 -3
- data/spec/models/event_spec.rb +4 -3
- data/spec/models/participate_spec.rb +2 -3
- data/spec/support/devise.rb +2 -2
- metadata +132 -25
- data/app/models/enju_event/ability.rb +0 -43
- data/app/workers/event_export_file_queue.rb +0 -7
- data/app/workers/event_import_file_queue.rb +0 -7
- data/lib/enju_event/import_file.rb +0 -13
- data/spec/dummy/app/models/ability.rb +0 -41
@@ -1,7 +1,11 @@
|
|
1
1
|
class ApplicationController < ActionController::Base
|
2
2
|
protect_from_forgery
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
3
|
+
include EnjuLeaf::Controller
|
4
|
+
include EnjuBiblio::Controller
|
5
|
+
include EnjuLibrary::Controller
|
6
|
+
include EnjuEvent::Controller
|
7
|
+
before_action :set_paper_trail_whodunnit
|
8
|
+
after_action :verify_authorized
|
9
|
+
|
10
|
+
include Pundit
|
7
11
|
end
|
@@ -2,8 +2,10 @@ require File.expand_path('../boot', __FILE__)
|
|
2
2
|
|
3
3
|
require 'rails/all'
|
4
4
|
|
5
|
-
Bundler.require
|
5
|
+
Bundler.require(*Rails.groups)
|
6
6
|
require 'enju_event'
|
7
|
+
require 'enju_leaf'
|
8
|
+
require 'resque/server'
|
7
9
|
|
8
10
|
module Dummy
|
9
11
|
class Application < Rails::Application
|
@@ -11,16 +13,6 @@ module Dummy
|
|
11
13
|
# Application configuration should go into files in config/initializers
|
12
14
|
# -- all .rb files in that directory are automatically loaded.
|
13
15
|
|
14
|
-
# Custom directories with classes and modules you want to be autoloadable.
|
15
|
-
# config.autoload_paths += %W(#{config.root}/extras)
|
16
|
-
|
17
|
-
# Only load the plugins named here, in the order given (default is alphabetical).
|
18
|
-
# :all can be used as a placeholder for all plugins not explicitly named.
|
19
|
-
# config.plugins = [ :exception_notification, :ssl_requirement, :all ]
|
20
|
-
|
21
|
-
# Activate observers that should always be running.
|
22
|
-
# config.active_record.observers = :cacher, :garbage_collector, :forum_observer
|
23
|
-
|
24
16
|
# Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.
|
25
17
|
# Run "rake -D time" for a list of tasks for finding time zone names. Default is UTC.
|
26
18
|
# config.time_zone = 'Central Time (US & Canada)'
|
@@ -29,19 +21,8 @@ module Dummy
|
|
29
21
|
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
|
30
22
|
# config.i18n.default_locale = :de
|
31
23
|
|
32
|
-
#
|
33
|
-
config.
|
34
|
-
|
35
|
-
# Configure sensitive parameters which will be filtered from the log file.
|
36
|
-
config.filter_parameters += [:password]
|
37
|
-
|
38
|
-
# Enable the asset pipeline
|
39
|
-
config.assets.enabled = true
|
40
|
-
|
41
|
-
# Version of your assets, change this if you want to expire all your assets
|
42
|
-
config.assets.version = '1.0'
|
24
|
+
# Do not swallow errors in after_commit/after_rollback callbacks.
|
25
|
+
config.active_record.raise_in_transactional_callbacks = true
|
43
26
|
end
|
44
27
|
end
|
45
28
|
|
46
|
-
require 'enju_leaf'
|
47
|
-
require 'mobylette'
|
@@ -1,30 +1,41 @@
|
|
1
|
-
|
2
|
-
# Settings specified here will take precedence over those in config/application.rb
|
1
|
+
Rails.application.configure do
|
2
|
+
# Settings specified here will take precedence over those in config/application.rb.
|
3
3
|
|
4
4
|
# In the development environment your application's code is reloaded on
|
5
|
-
# every request.
|
5
|
+
# every request. This slows down response time but is perfect for development
|
6
6
|
# since you don't have to restart the web server when you make code changes.
|
7
7
|
config.cache_classes = false
|
8
8
|
|
9
|
-
#
|
10
|
-
config.
|
9
|
+
# Do not eager load code on boot.
|
10
|
+
config.eager_load = false
|
11
11
|
|
12
|
-
# Show full error reports and disable caching
|
12
|
+
# Show full error reports and disable caching.
|
13
13
|
config.consider_all_requests_local = true
|
14
14
|
config.action_controller.perform_caching = false
|
15
15
|
|
16
|
-
# Don't care if the mailer can't send
|
16
|
+
# Don't care if the mailer can't send.
|
17
17
|
config.action_mailer.raise_delivery_errors = false
|
18
18
|
|
19
|
-
# Print deprecation notices to the Rails logger
|
19
|
+
# Print deprecation notices to the Rails logger.
|
20
20
|
config.active_support.deprecation = :log
|
21
21
|
|
22
|
-
#
|
23
|
-
config.
|
22
|
+
# Raise an error on page load if there are pending migrations.
|
23
|
+
config.active_record.migration_error = :page_load
|
24
24
|
|
25
|
-
#
|
26
|
-
|
27
|
-
|
28
|
-
# Expands the lines which load the assets
|
25
|
+
# Debug mode disables concatenation and preprocessing of assets.
|
26
|
+
# This option may cause significant delays in view rendering with a large
|
27
|
+
# number of complex assets.
|
29
28
|
config.assets.debug = true
|
29
|
+
|
30
|
+
# Asset digests allow you to set far-future HTTP expiration dates on all assets,
|
31
|
+
# yet still be able to expire them through the digest params.
|
32
|
+
config.assets.digest = true
|
33
|
+
|
34
|
+
# Adds additional error checking when serving assets at runtime.
|
35
|
+
# Checks for improperly declared sprockets dependencies.
|
36
|
+
# Raises helpful error messages.
|
37
|
+
config.assets.raise_runtime_errors = true
|
38
|
+
|
39
|
+
# Raises error for missing translations
|
40
|
+
# config.action_view.raise_on_missing_translations = true
|
30
41
|
end
|
@@ -1,60 +1,79 @@
|
|
1
|
-
|
2
|
-
# Settings specified here will take precedence over those in config/application.rb
|
1
|
+
Rails.application.configure do
|
2
|
+
# Settings specified here will take precedence over those in config/application.rb.
|
3
3
|
|
4
|
-
# Code is not reloaded between requests
|
4
|
+
# Code is not reloaded between requests.
|
5
5
|
config.cache_classes = true
|
6
6
|
|
7
|
-
#
|
7
|
+
# Eager load code on boot. This eager loads most of Rails and
|
8
|
+
# your application in memory, allowing both threaded web servers
|
9
|
+
# and those relying on copy on write to perform better.
|
10
|
+
# Rake tasks automatically ignore this option for performance.
|
11
|
+
config.eager_load = true
|
12
|
+
|
13
|
+
# Full error reports are disabled and caching is turned on.
|
8
14
|
config.consider_all_requests_local = false
|
9
15
|
config.action_controller.perform_caching = true
|
10
16
|
|
11
|
-
#
|
12
|
-
|
17
|
+
# Enable Rack::Cache to put a simple HTTP cache in front of your application
|
18
|
+
# Add `rack-cache` to your Gemfile before enabling this.
|
19
|
+
# For large-scale production use, consider using a caching reverse proxy like
|
20
|
+
# NGINX, varnish or squid.
|
21
|
+
# config.action_dispatch.rack_cache = true
|
22
|
+
|
23
|
+
# Disable serving static files from the `/public` folder by default since
|
24
|
+
# Apache or NGINX already handles this.
|
25
|
+
config.serve_static_files = ENV['RAILS_SERVE_STATIC_FILES'].present?
|
13
26
|
|
14
|
-
# Compress JavaScripts and CSS
|
15
|
-
config.assets.
|
27
|
+
# Compress JavaScripts and CSS.
|
28
|
+
config.assets.js_compressor = :uglifier
|
29
|
+
# config.assets.css_compressor = :sass
|
16
30
|
|
17
|
-
#
|
31
|
+
# Do not fallback to assets pipeline if a precompiled asset is missed.
|
18
32
|
config.assets.compile = false
|
19
33
|
|
20
|
-
#
|
34
|
+
# Asset digests allow you to set far-future HTTP expiration dates on all assets,
|
35
|
+
# yet still be able to expire them through the digest params.
|
21
36
|
config.assets.digest = true
|
22
37
|
|
23
|
-
#
|
24
|
-
# config.assets.manifest = YOUR_PATH
|
38
|
+
# `config.assets.precompile` and `config.assets.version` have moved to config/initializers/assets.rb
|
25
39
|
|
26
|
-
# Specifies the header that your server uses for sending files
|
27
|
-
# config.action_dispatch.x_sendfile_header =
|
28
|
-
# config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for
|
40
|
+
# Specifies the header that your server uses for sending files.
|
41
|
+
# config.action_dispatch.x_sendfile_header = 'X-Sendfile' # for Apache
|
42
|
+
# config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for NGINX
|
29
43
|
|
30
44
|
# Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.
|
31
45
|
# config.force_ssl = true
|
32
46
|
|
33
|
-
#
|
34
|
-
#
|
47
|
+
# Use the lowest log level to ensure availability of diagnostic information
|
48
|
+
# when problems arise.
|
49
|
+
config.log_level = :debug
|
35
50
|
|
36
|
-
#
|
37
|
-
# config.
|
51
|
+
# Prepend all log lines with the following tags.
|
52
|
+
# config.log_tags = [ :subdomain, :uuid ]
|
38
53
|
|
39
|
-
# Use a different
|
40
|
-
# config.
|
54
|
+
# Use a different logger for distributed setups.
|
55
|
+
# config.logger = ActiveSupport::TaggedLogging.new(SyslogLogger.new)
|
41
56
|
|
42
|
-
#
|
43
|
-
# config.
|
57
|
+
# Use a different cache store in production.
|
58
|
+
# config.cache_store = :mem_cache_store
|
44
59
|
|
45
|
-
#
|
46
|
-
# config.
|
60
|
+
# Enable serving of images, stylesheets, and JavaScripts from an asset server.
|
61
|
+
# config.action_controller.asset_host = 'http://assets.example.com'
|
47
62
|
|
48
|
-
#
|
63
|
+
# Ignore bad email addresses and do not raise email delivery errors.
|
64
|
+
# Set this to true and configure the email server for immediate delivery to raise delivery errors.
|
49
65
|
# config.action_mailer.raise_delivery_errors = false
|
50
66
|
|
51
|
-
# Enable threaded mode
|
52
|
-
# config.threadsafe!
|
53
|
-
|
54
67
|
# Enable locale fallbacks for I18n (makes lookups for any locale fall back to
|
55
|
-
# the I18n.default_locale when a translation
|
68
|
+
# the I18n.default_locale when a translation cannot be found).
|
56
69
|
config.i18n.fallbacks = true
|
57
70
|
|
58
|
-
# Send deprecation notices to registered listeners
|
71
|
+
# Send deprecation notices to registered listeners.
|
59
72
|
config.active_support.deprecation = :notify
|
73
|
+
|
74
|
+
# Use default logging formatter so that PID and timestamp are not suppressed.
|
75
|
+
config.log_formatter = ::Logger::Formatter.new
|
76
|
+
|
77
|
+
# Do not dump schema after migrations.
|
78
|
+
config.active_record.dump_schema_after_migration = false
|
60
79
|
end
|
@@ -1,5 +1,5 @@
|
|
1
|
-
|
2
|
-
# Settings specified here will take precedence over those in config/application.rb
|
1
|
+
Rails.application.configure do
|
2
|
+
# Settings specified here will take precedence over those in config/application.rb.
|
3
3
|
|
4
4
|
# The test environment is used exclusively to run your application's
|
5
5
|
# test suite. You never need to work with it otherwise. Remember that
|
@@ -7,33 +7,38 @@ Dummy::Application.configure do
|
|
7
7
|
# and recreated between test runs. Don't rely on the data there!
|
8
8
|
config.cache_classes = true
|
9
9
|
|
10
|
-
#
|
11
|
-
|
12
|
-
|
10
|
+
# Do not eager load code on boot. This avoids loading your whole application
|
11
|
+
# just for the purpose of running a single test. If you are using a tool that
|
12
|
+
# preloads Rails for running tests, you may have to set it to true.
|
13
|
+
config.eager_load = false
|
13
14
|
|
14
|
-
#
|
15
|
-
config.
|
15
|
+
# Configure static file server for tests with Cache-Control for performance.
|
16
|
+
config.serve_static_files = true
|
17
|
+
config.static_cache_control = 'public, max-age=3600'
|
16
18
|
|
17
|
-
# Show full error reports and disable caching
|
19
|
+
# Show full error reports and disable caching.
|
18
20
|
config.consider_all_requests_local = true
|
19
21
|
config.action_controller.perform_caching = false
|
20
22
|
|
21
|
-
# Raise exceptions instead of rendering exception templates
|
23
|
+
# Raise exceptions instead of rendering exception templates.
|
22
24
|
config.action_dispatch.show_exceptions = false
|
23
25
|
|
24
|
-
# Disable request forgery protection in test environment
|
25
|
-
config.action_controller.allow_forgery_protection
|
26
|
+
# Disable request forgery protection in test environment.
|
27
|
+
config.action_controller.allow_forgery_protection = false
|
26
28
|
|
27
29
|
# Tell Action Mailer not to deliver emails to the real world.
|
28
30
|
# The :test delivery method accumulates sent emails in the
|
29
31
|
# ActionMailer::Base.deliveries array.
|
30
32
|
config.action_mailer.delivery_method = :test
|
31
33
|
|
32
|
-
#
|
33
|
-
|
34
|
+
# Randomize the order test cases are executed.
|
35
|
+
config.active_support.test_order = :random
|
34
36
|
|
35
|
-
# Print deprecation notices to the stderr
|
37
|
+
# Print deprecation notices to the stderr.
|
36
38
|
config.active_support.deprecation = :stderr
|
37
39
|
|
40
|
+
# Raises error for missing translations
|
41
|
+
# config.action_view.raise_on_missing_translations = true
|
42
|
+
|
38
43
|
config.action_mailer.default_url_options = {:host => 'localhost:3000'}
|
39
44
|
end
|
data/spec/dummy/config/routes.rb
CHANGED
@@ -1,5 +1,8 @@
|
|
1
1
|
Dummy::Application.routes.draw do
|
2
2
|
devise_for :users
|
3
|
+
authenticate :user, lambda {|u| u.role.try(:name) == 'Administrator' } do
|
4
|
+
mount Resque::Server.new, at: "/resque", as: :resque
|
5
|
+
end
|
3
6
|
|
4
7
|
# The priority is based upon order of creation:
|
5
8
|
# first created -> highest priority.
|
@@ -0,0 +1,14 @@
|
|
1
|
+
class CreateColors < ActiveRecord::Migration
|
2
|
+
def change
|
3
|
+
create_table :colors do |t|
|
4
|
+
t.integer :library_group_id
|
5
|
+
t.string :property
|
6
|
+
t.string :code
|
7
|
+
t.integer :position
|
8
|
+
|
9
|
+
t.timestamps
|
10
|
+
end
|
11
|
+
|
12
|
+
add_index :colors, :library_group_id
|
13
|
+
end
|
14
|
+
end
|
@@ -0,0 +1,13 @@
|
|
1
|
+
class CreateWithdraws < ActiveRecord::Migration
|
2
|
+
def change
|
3
|
+
create_table :withdraws do |t|
|
4
|
+
t.integer :basket_id
|
5
|
+
t.integer :item_id
|
6
|
+
t.integer :librarian_id
|
7
|
+
|
8
|
+
t.timestamps null: false
|
9
|
+
end
|
10
|
+
add_index :withdraws, :basket_id
|
11
|
+
add_index :withdraws, :item_id
|
12
|
+
end
|
13
|
+
end
|
@@ -0,0 +1,13 @@
|
|
1
|
+
class AddTranslationTableToLibraryGroup < ActiveRecord::Migration
|
2
|
+
def up
|
3
|
+
LibraryGroup.create_translation_table!({
|
4
|
+
login_banner: :text
|
5
|
+
}, {
|
6
|
+
migrate_data: true
|
7
|
+
})
|
8
|
+
end
|
9
|
+
|
10
|
+
def down
|
11
|
+
LibraryGroup.drop_translation_table! migrate_data: true
|
12
|
+
end
|
13
|
+
end
|
data/spec/dummy/db/schema.rb
CHANGED
@@ -11,7 +11,7 @@
|
|
11
11
|
#
|
12
12
|
# It's strongly recommended that you check this file into your version control system.
|
13
13
|
|
14
|
-
ActiveRecord::Schema.define(version:
|
14
|
+
ActiveRecord::Schema.define(version: 20160703184311) do
|
15
15
|
|
16
16
|
create_table "accepts", force: :cascade do |t|
|
17
17
|
t.integer "basket_id"
|
@@ -309,6 +309,17 @@ ActiveRecord::Schema.define(version: 20150221063719) do
|
|
309
309
|
t.datetime "updated_at"
|
310
310
|
end
|
311
311
|
|
312
|
+
create_table "colors", force: :cascade do |t|
|
313
|
+
t.integer "library_group_id"
|
314
|
+
t.string "property"
|
315
|
+
t.string "code"
|
316
|
+
t.integer "position"
|
317
|
+
t.datetime "created_at"
|
318
|
+
t.datetime "updated_at"
|
319
|
+
end
|
320
|
+
|
321
|
+
add_index "colors", ["library_group_id"], name: "index_colors_on_library_group_id"
|
322
|
+
|
312
323
|
create_table "content_types", force: :cascade do |t|
|
313
324
|
t.string "name", null: false
|
314
325
|
t.text "display_name"
|
@@ -380,6 +391,7 @@ ActiveRecord::Schema.define(version: 20150221063719) do
|
|
380
391
|
t.integer "event_export_file_id"
|
381
392
|
t.datetime "created_at"
|
382
393
|
t.datetime "updated_at"
|
394
|
+
t.boolean "most_recent"
|
383
395
|
end
|
384
396
|
|
385
397
|
add_index "event_export_file_transitions", ["event_export_file_id"], name: "index_event_export_file_transitions_on_file_id"
|
@@ -403,6 +415,7 @@ ActiveRecord::Schema.define(version: 20150221063719) do
|
|
403
415
|
t.integer "event_import_file_id"
|
404
416
|
t.datetime "created_at"
|
405
417
|
t.datetime "updated_at"
|
418
|
+
t.boolean "most_recent"
|
406
419
|
end
|
407
420
|
|
408
421
|
add_index "event_import_file_transitions", ["event_import_file_id"], name: "index_event_import_file_transitions_on_event_import_file_id"
|
@@ -452,10 +465,12 @@ ActiveRecord::Schema.define(version: 20150221063719) do
|
|
452
465
|
t.text "display_name"
|
453
466
|
t.datetime "created_at"
|
454
467
|
t.datetime "updated_at"
|
468
|
+
t.integer "place_id"
|
455
469
|
end
|
456
470
|
|
457
471
|
add_index "events", ["event_category_id"], name: "index_events_on_event_category_id"
|
458
472
|
add_index "events", ["library_id"], name: "index_events_on_library_id"
|
473
|
+
add_index "events", ["place_id"], name: "index_events_on_place_id"
|
459
474
|
|
460
475
|
create_table "exemplifies", force: :cascade do |t|
|
461
476
|
t.integer "manifestation_id", null: false
|
@@ -637,6 +652,18 @@ ActiveRecord::Schema.define(version: 20150221063719) do
|
|
637
652
|
add_index "libraries", ["library_group_id"], name: "index_libraries_on_library_group_id"
|
638
653
|
add_index "libraries", ["name"], name: "index_libraries_on_name", unique: true
|
639
654
|
|
655
|
+
create_table "library_group_translations", force: :cascade do |t|
|
656
|
+
t.integer "library_group_id", null: false
|
657
|
+
t.string "locale", null: false
|
658
|
+
t.datetime "created_at", null: false
|
659
|
+
t.datetime "updated_at", null: false
|
660
|
+
t.text "login_banner"
|
661
|
+
t.text "footer_banner"
|
662
|
+
end
|
663
|
+
|
664
|
+
add_index "library_group_translations", ["library_group_id"], name: "index_library_group_translations_on_library_group_id"
|
665
|
+
add_index "library_group_translations", ["locale"], name: "index_library_group_translations_on_locale"
|
666
|
+
|
640
667
|
create_table "library_groups", force: :cascade do |t|
|
641
668
|
t.string "name", null: false
|
642
669
|
t.text "display_name"
|
@@ -920,6 +947,19 @@ ActiveRecord::Schema.define(version: 20150221063719) do
|
|
920
947
|
|
921
948
|
add_index "picture_files", ["picture_attachable_id", "picture_attachable_type"], name: "index_picture_files_on_picture_attachable_id_and_type"
|
922
949
|
|
950
|
+
create_table "places", force: :cascade do |t|
|
951
|
+
t.string "term"
|
952
|
+
t.text "city"
|
953
|
+
t.integer "country_id"
|
954
|
+
t.float "latitude"
|
955
|
+
t.float "longitude"
|
956
|
+
t.datetime "created_at", null: false
|
957
|
+
t.datetime "updated_at", null: false
|
958
|
+
end
|
959
|
+
|
960
|
+
add_index "places", ["country_id"], name: "index_places_on_country_id"
|
961
|
+
add_index "places", ["term"], name: "index_places_on_term"
|
962
|
+
|
923
963
|
create_table "produce_types", force: :cascade do |t|
|
924
964
|
t.string "name"
|
925
965
|
t.text "display_name"
|
@@ -1444,4 +1484,15 @@ ActiveRecord::Schema.define(version: 20150221063719) do
|
|
1444
1484
|
|
1445
1485
|
add_index "versions", ["item_type", "item_id"], name: "index_versions_on_item_type_and_item_id"
|
1446
1486
|
|
1487
|
+
create_table "withdraws", force: :cascade do |t|
|
1488
|
+
t.integer "basket_id"
|
1489
|
+
t.integer "item_id"
|
1490
|
+
t.integer "librarian_id"
|
1491
|
+
t.datetime "created_at", null: false
|
1492
|
+
t.datetime "updated_at", null: false
|
1493
|
+
end
|
1494
|
+
|
1495
|
+
add_index "withdraws", ["basket_id"], name: "index_withdraws_on_basket_id"
|
1496
|
+
add_index "withdraws", ["item_id"], name: "index_withdraws_on_item_id"
|
1497
|
+
|
1447
1498
|
end
|