Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

add rails_admin.

  • Loading branch information...
commit 5bb631344c03d758077108149930b3d836ee316f 1 parent 9af412f
sakomoko authored
2  Gemfile
View
@@ -20,6 +20,8 @@ end
gem 'jquery-rails'
+gem 'rails_admin'
+
# Use unicorn as the web server
# gem 'unicorn'
31 Gemfile.lock
View
@@ -31,6 +31,8 @@ GEM
addressable (2.3.2)
arel (3.0.2)
bcrypt-ruby (3.0.1)
+ bootstrap-sass (2.2.2.0)
+ sass (~> 3.2)
builder (3.0.4)
capybara (2.0.1)
mime-types (>= 1.16)
@@ -67,6 +69,9 @@ GEM
factory_girl (~> 4.1.0)
railties (>= 3.0.0)
ffi (1.2.0)
+ font-awesome-sass-rails (2.0.0.0)
+ railties (>= 3.1.1)
+ sass-rails (>= 3.1.1)
growl (1.0.3)
guard (1.6.1)
listen (>= 0.6.0)
@@ -92,7 +97,13 @@ GEM
jquery-rails (2.1.4)
railties (>= 3.0, < 5.0)
thor (>= 0.14, < 2.0)
+ jquery-ui-rails (2.0.2)
+ jquery-rails
+ railties (>= 3.1.0)
json (1.7.6)
+ kaminari (0.14.1)
+ actionpack (>= 3.0.0)
+ activesupport (>= 3.0.0)
libwebsocket (0.1.7.1)
addressable
websocket
@@ -119,6 +130,7 @@ GEM
multi_json (1.5.0)
named_let (0.1.3)
rspec-core
+ nested_form (0.3.1)
nokogiri (1.5.6)
origin (1.0.11)
orm_adapter (0.4.0)
@@ -130,6 +142,9 @@ GEM
rack (1.4.1)
rack-cache (1.2)
rack (>= 0.4)
+ rack-pjax (0.6.0)
+ nokogiri (~> 1.5)
+ rack (~> 1.3)
rack-ssl (1.3.2)
rack
rack-test (0.6.2)
@@ -142,6 +157,20 @@ GEM
activesupport (= 3.2.9)
bundler (~> 1.0)
railties (= 3.2.9)
+ rails_admin (0.3.0)
+ bootstrap-sass (~> 2.1)
+ builder (~> 3.0)
+ coffee-rails (~> 3.1)
+ font-awesome-sass-rails (~> 2.0)
+ haml (~> 3.1)
+ jquery-rails (~> 2.1)
+ jquery-ui-rails (~> 2.0)
+ kaminari (~> 0.14)
+ nested_form (> 0.2.3, < 0.4.0)
+ rack-pjax (~> 0.6)
+ rails (~> 3.1)
+ remotipart (~> 1.0)
+ sass-rails (~> 3.1)
railties (3.2.9)
actionpack (= 3.2.9)
activesupport (= 3.2.9)
@@ -153,6 +182,7 @@ GEM
rb-fsevent (0.9.2)
rdoc (3.12)
json (~> 1.4)
+ remotipart (1.0.2)
rspec (2.12.0)
rspec-core (~> 2.12.0)
rspec-expectations (~> 2.12.0)
@@ -229,6 +259,7 @@ DEPENDENCIES
mongoid-tree
named_let
rails (~> 3.2)
+ rails_admin
rb-fsevent
rspec-rails
sass-rails (~> 3.2)
3  app/models/character.rb
View
@@ -11,6 +11,7 @@ class Character
before_create :set_default_documents
embeds_one :candy
+
embeds_one :equip
embeds_one :position
embeds_many :assigned_skills
@@ -100,6 +101,8 @@ def remove(item, num = 1)
validates_presence_of :name
validates_uniqueness_of :name, :case_sensitive => true
+ accepts_nested_attributes_for :candy, :equip, :position, :assigned_skills, :belongings
+
def action=(action)
if action.instance_of? Skill
unless self.assigned_skills.where(skill_id: action.id).first
15 app/models/equip.rb
View
@@ -9,13 +9,14 @@ class Equip
belongs_to :boots, class_name: 'Belonging'
belongs_to :accessory, class_name: 'Belonging'
belongs_to :arrow, class_name: 'Belonging'
-end
-def each
- @equips ||= [:weapon, :shield, :head, :armor, :groob, :boots, :accessory, :arrow]
- @equips.each do |key|
- result = self.send key
- next unless result
- yield key, self.send(key)
+ def each
+ @equips ||= [:weapon, :shield, :head, :armor, :groob, :boots, :accessory, :arrow]
+ @equips.each do |key|
+ result = self.send key
+ next unless result
+ yield key, self.send(key)
+ end
end
end
+
2  app/models/skill.rb
View
@@ -8,6 +8,8 @@ class Skill
embeds_one :status_adjustment
embeds_one :status_coefficient
+ accepts_nested_attributes_for :status_adjustment, :status_coefficient
+
belongs_to :system_message, index: true
field :name, :type => String
0  config/initializers/rails_admin.rb
View
No changes.
960 config/initializers/rails_admin.rb.example
View
@@ -0,0 +1,960 @@
+# RailsAdmin config file. Generated on December 31, 2012 16:53
+# See github.com/sferik/rails_admin for more informations
+
+RailsAdmin.config do |config|
+
+
+ ################ Global configuration ################
+
+ # Set the admin name here (optional second array element will appear in red). For example:
+ config.main_app_name = ['Eretheal', 'Admin']
+ # or for a more dynamic name:
+ # config.main_app_name = Proc.new { |controller| [Rails.application.engine_name.titleize, controller.params['action'].titleize] }
+
+ # RailsAdmin may need a way to know who the current user is]
+ config.current_user_method { current_user } # auto-generated
+
+ # If you want to track changes on your models:
+ # config.audit_with :history, 'User'
+
+ # Or with a PaperTrail: (you need to install it first)
+ # config.audit_with :paper_trail, 'User'
+
+ # Display empty fields in show views:
+ # config.compact_show_view = false
+
+ # Number of default rows per-page:
+ # config.default_items_per_page = 20
+
+ # Exclude specific models (keep the others):
+ # config.excluded_models = ['AssignedSkill', 'Attribute', 'Belonging', 'Candy', 'Character', 'Enemy', 'Equip', 'Field', 'Item', 'ItemType', 'Job', 'Position', 'Skill', 'StatusAdjustment', 'StatusCoefficient', 'SystemMessage', 'User']
+
+ # Include specific models (exclude the others):
+ # config.included_models = ['AssignedSkill', 'Attribute', 'Belonging', 'Candy', 'Character', 'Enemy', 'Equip', 'Field', 'Item', 'ItemType', 'Job', 'Position', 'Skill', 'StatusAdjustment', 'StatusCoefficient', 'SystemMessage', 'User']
+
+ # Label methods for model instances:
+ # config.label_methods << :description # Default is [:name, :title]
+
+
+ ################ Model configuration ################
+
+ # Each model configuration can alternatively:
+ # - stay here in a `config.model 'ModelName' do ... end` block
+ # - go in the model definition file in a `rails_admin do ... end` block
+
+ # This is your choice to make:
+ # - This initializer is loaded once at startup (modifications will show up when restarting the application) but all RailsAdmin configuration would stay in one place.
+ # - Models are reloaded at each request in development mode (when modified), which may smooth your RailsAdmin development workflow.
+
+
+ # Now you probably need to tour the wiki a bit: https://github.com/sferik/rails_admin/wiki
+ # Anyway, here is how RailsAdmin saw your application's models when you ran the initializer:
+
+
+
+ ### AssignedSkill ###
+
+ # config.model 'AssignedSkill' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your assigned_skill.rb model definition
+
+ # # Found associations:
+
+ # configure :skill, :belongs_to_association
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :skill_id, :bson_object_id # Hidden
+ # configure :set_number, :integer
+ # configure :sort, :integer
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+
+ ### Attribute ###
+
+ # config.model 'Attribute' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your attribute.rb model definition
+
+ # # Found associations:
+
+ # configure :item_types, :has_many_association
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :name, :string
+ # configure :key, :text
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+
+ ### Belonging ###
+
+ # config.model 'Belonging' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your belonging.rb model definition
+
+ # # Found associations:
+
+ # configure :item, :belongs_to_association
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :created_at, :datetime
+ # configure :updated_at, :datetime
+ # configure :item_id, :bson_object_id # Hidden
+ # configure :durability, :integer
+ # configure :color, :text
+ # configure :num, :integer
+ # configure :sort, :integer
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+
+ ### Candy ###
+
+ # config.model 'Candy' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your candy.rb model definition
+
+ # # Found associations:
+
+
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :red, :integer
+ # configure :blue, :integer
+ # configure :green, :integer
+ # configure :yellow, :integer
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+
+ ### Character ###
+
+ # config.model 'Character' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your character.rb model definition
+
+ # # Found associations:
+
+ # configure :user, :belongs_to_association
+ # configure :job, :belongs_to_association
+ # configure :skills, :has_and_belongs_to_many_association
+ # configure :candy, :has_one_association
+ # configure :equip, :has_one_association
+ # configure :position, :has_one_association
+ # configure :assigned_skills, :has_many_association
+ # configure :belongings, :has_many_association
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :deleted_at, :datetime
+ # configure :created_at, :datetime
+ # configure :updated_at, :datetime
+ # configure :user_id, :bson_object_id # Hidden
+ # configure :job_id, :bson_object_id # Hidden
+ # configure :skill_ids, :serialized # Hidden
+ # configure :name, :string
+ # configure :exp, :integer
+ # configure :level, :integer
+ # configure :skill_point, :integer
+ # configure :stamina, :integer
+ # configure :hp, :integer
+ # configure :mp, :integer
+ # configure :dex, :integer
+ # configure :agi, :integer
+ # configure :str, :integer
+ # configure :int, :integer
+ # configure :mnd, :integer
+ # configure :vit, :integer
+ # configure :sex, :integer
+ # configure :status_point, :integer
+ # configure :total_exp, :integer
+ # configure :bag_size, :integer
+ # configure :count, :integer
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+
+ ### Enemy ###
+
+ # config.model 'Enemy' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your enemy.rb model definition
+
+ # # Found associations:
+
+
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :name, :string
+ # configure :development_type, :text
+ # configure :default_hp, :integer
+ # configure :default_mp, :integer
+ # configure :dex, :integer
+ # configure :agi, :integer
+ # configure :str, :integer
+ # configure :vit, :integer
+ # configure :int, :integer
+ # configure :mnd, :integer
+ # configure :dmg, :integer
+ # configure :def, :integer
+ # configure :magi, :integer
+ # configure :magi_def, :integer
+ # configure :hit, :integer
+ # configure :avoid, :integer
+ # configure :speed, :integer
+ # configure :guard, :integer
+ # configure :critical, :integer
+ # configure :critical_def, :integer
+ # configure :counter, :integer
+ # configure :exp, :integer
+ # configure :color, :text
+ # configure :explain, :text
+ # configure :range, :integer
+ # configure :publicity, :integer
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+
+ ### Equip ###
+
+ # config.model 'Equip' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your equip.rb model definition
+
+ # # Found associations:
+
+ # configure :weapon, :belongs_to_association
+ # configure :shield, :belongs_to_association
+ # configure :head, :belongs_to_association
+ # configure :armor, :belongs_to_association
+ # configure :groob, :belongs_to_association
+ # configure :boots, :belongs_to_association
+ # configure :accessory, :belongs_to_association
+ # configure :arrow, :belongs_to_association
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :weapon_id, :bson_object_id # Hidden
+ # configure :shield_id, :bson_object_id # Hidden
+ # configure :head_id, :bson_object_id # Hidden
+ # configure :armor_id, :bson_object_id # Hidden
+ # configure :groob_id, :bson_object_id # Hidden
+ # configure :boots_id, :bson_object_id # Hidden
+ # configure :accessory_id, :bson_object_id # Hidden
+ # configure :arrow_id, :bson_object_id # Hidden
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+
+ ### Field ###
+
+ # config.model 'Field' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your field.rb model definition
+
+ # # Found associations:
+
+ # configure :parent, :belongs_to_association
+ # configure :link, :belongs_to_association
+ # configure :children, :has_many_association
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :parent_id, :bson_object_id # Hidden
+ # configure :parent_ids, :serialized
+ # configure :position, :integer
+ # configure :link_id, :bson_object_id # Hidden
+ # configure :name, :string
+ # configure :no_image, :boolean
+ # configure :distance, :integer
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+
+ ### Item ###
+
+ # config.model 'Item' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your item.rb model definition
+
+ # # Found associations:
+
+ # configure :item_type, :belongs_to_association
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :deleted_at, :datetime
+ # configure :created_at, :datetime
+ # configure :updated_at, :datetime
+ # configure :item_type_id, :bson_object_id # Hidden
+ # configure :name, :string
+ # configure :power, :integer
+ # configure :speed, :integer
+ # configure :weight, :integer
+ # configure :color, :text
+ # configure :hit, :integer
+ # configure :avoid, :integer
+ # configure :magi, :integer
+ # configure :magi_def, :integer
+ # configure :add_dex, :integer
+ # configure :add_agi, :integer
+ # configure :add_vit, :integer
+ # configure :add_str, :integer
+ # configure :add_int, :integer
+ # configure :add_mnd, :integer
+ # configure :add_hp, :integer
+ # configure :two_handed, :boolean
+ # configure :explain, :text
+ # configure :critical, :integer
+ # configure :stack, :boolean
+ # configure :price, :integer
+ # configure :demand, :integer
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+
+ ### ItemType ###
+
+ # config.model 'ItemType' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your item_type.rb model definition
+
+ # # Found associations:
+
+ # configure :attribute, :belongs_to_association
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :key, :text
+ # configure :name, :string
+ # configure :category, :text
+ # configure :range, :integer
+ # configure :equip, :boolean
+ # configure :attribute_id, :bson_object_id # Hidden
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+
+ ### Job ###
+
+ # config.model 'Job' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your job.rb model definition
+
+ # # Found associations:
+
+
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :deleted_at, :datetime
+ # configure :created_at, :datetime
+ # configure :updated_at, :datetime
+ # configure :name, :string
+ # configure :name_jp, :text
+ # configure :add_dex, :float
+ # configure :add_agi, :float
+ # configure :add_str, :float
+ # configure :add_int, :float
+ # configure :add_vit, :float
+ # configure :add_mnd, :float
+ # configure :dex_up, :integer
+ # configure :agi_up, :integer
+ # configure :str_up, :integer
+ # configure :int_up, :integer
+ # configure :vit_up, :integer
+ # configure :mnd_up, :integer
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+
+ ### Position ###
+
+ # config.model 'Position' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your position.rb model definition
+
+ # # Found associations:
+
+ # configure :field, :belongs_to_association
+ # configure :destination, :belongs_to_association
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :field_id, :bson_object_id # Hidden
+ # configure :destination_id, :bson_object_id # Hidden
+ # configure :distance, :integer
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+
+ ### Skill ###
+
+ # config.model 'Skill' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your skill.rb model definition
+
+ # # Found associations:
+
+ # configure :system_message, :belongs_to_association
+ # configure :status_adjustment, :has_one_association
+ # configure :status_coefficient, :has_one_association
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :deleted_at, :datetime
+ # configure :created_at, :datetime
+ # configure :updated_at, :datetime
+ # configure :system_message_id, :bson_object_id # Hidden
+ # configure :name, :string
+ # configure :key, :text
+ # configure :power, :integer
+ # configure :use_hp, :integer
+ # configure :use_mp, :integer
+ # configure :speed, :integer
+ # configure :delay, :integer
+ # configure :active, :boolean
+ # configure :range, :integer
+ # configure :color, :text
+ # configure :cost, :integer
+ # configure :spell, :boolean
+ # configure :critical, :integer
+ # configure :explain, :text
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+
+ ### StatusAdjustment ###
+
+ # config.model 'StatusAdjustment' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your status_adjustment.rb model definition
+
+ # # Found associations:
+
+
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :dmg, :integer
+ # configure :def, :integer
+ # configure :hit, :integer
+ # configure :avoid, :integer
+ # configure :magi, :integer
+ # configure :magi_def, :integer
+ # configure :dex, :integer
+ # configure :agi, :integer
+ # configure :int, :integer
+ # configure :vit, :integer
+ # configure :str, :integer
+ # configure :mnd, :integer
+ # configure :hp, :integer
+ # configure :mp, :integer
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+
+ ### StatusCoefficient ###
+
+ # config.model 'StatusCoefficient' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your status_coefficient.rb model definition
+
+ # # Found associations:
+
+
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :dex, :float
+ # configure :agi, :float
+ # configure :int, :float
+ # configure :vit, :float
+ # configure :str, :float
+ # configure :mnd, :float
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+
+ ### SystemMessage ###
+
+ # config.model 'SystemMessage' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your system_message.rb model definition
+
+ # # Found associations:
+
+
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :key, :text
+ # configure :message, :text
+ # configure :level, :integer
+ # configure :class, :text
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+
+ ### User ###
+
+ # config.model 'User' do
+
+ # # You can copy this to a 'rails_admin do ... end' block inside your user.rb model definition
+
+ # # Found associations:
+
+ # configure :characters, :has_many_association
+
+ # # Found columns:
+
+ # configure :_type, :text # Hidden
+ # configure :_id, :bson_object_id
+ # configure :deleted_at, :datetime
+ # configure :created_at, :datetime
+ # configure :updated_at, :datetime
+ # configure :email, :text
+ # configure :password, :password # Hidden
+ # configure :password_confirmation, :password # Hidden
+ # configure :reset_password_token, :text # Hidden
+ # configure :reset_password_sent_at, :datetime
+ # configure :remember_created_at, :datetime
+ # configure :sign_in_count, :integer
+ # configure :current_sign_in_at, :datetime
+ # configure :last_sign_in_at, :datetime
+ # configure :current_sign_in_ip, :text
+ # configure :last_sign_in_ip, :text
+ # configure :name, :string
+
+ # # Cross-section configuration:
+
+ # # object_label_method :name # Name of the method called for pretty printing an *instance* of ModelName
+ # # label 'My model' # Name of ModelName (smartly defaults to ActiveRecord's I18n API)
+ # # label_plural 'My models' # Same, plural
+ # # weight 0 # Navigation priority. Bigger is higher.
+ # # parent OtherModel # Set parent model for navigation. MyModel will be nested below. OtherModel will be on first position of the dropdown
+ # # navigation_label # Sets dropdown entry's name in navigation. Only for parents!
+
+ # # Section specific configuration:
+
+ # list do
+ # # filters [:id, :name] # Array of field names which filters should be shown by default in the table header
+ # # items_per_page 100 # Override default_items_per_page
+ # # sort_by :id # Sort column (default is primary key)
+ # # sort_reverse true # Sort direction (default is true for primary key, last created first)
+ # end
+ # show do; end
+ # edit do; end
+ # export do; end
+ # # also see the create, update, modal and nested sections, which override edit in specific cases (resp. when creating, updating, modifying from another model in a popup modal or modifying from another model nested form)
+ # # you can override a cross-section field configuration in any section with the same syntax `configure :field_name do ... end`
+ # # using `field` instead of `configure` will exclude all other fields and force the ordering
+ # end
+
+end
16 config/routes.rb
View
@@ -1,4 +1,20 @@
Eretheal::Application.routes.draw do
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
mount RailsAdmin::Engine => '/admin', :as => 'rails_admin'
get "welcome/index"
Please sign in to comment.
Something went wrong with that request. Please try again.