-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #6 from betacraft/development
Fixes
- Loading branch information
Showing
17 changed files
with
232 additions
and
103 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,3 +18,6 @@ config/database.yml | |
.rvmrc | ||
.idea | ||
.env | ||
.generators | ||
.byebug_history | ||
.ruby-version |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,44 +1,54 @@ | ||
# ActiveAdmin::Dashboards.build do | ||
# | ||
# # Define your dashboard sections here. Each block will be | ||
# # rendered on the dashboard in the context of the view. So just | ||
# # return the content which you would like to display. | ||
# | ||
# # == Simple Dashboard Section | ||
# # Here is an example of a simple dashboard section | ||
# # | ||
# # section "Recent Posts" do | ||
# # ul do | ||
# # Post.recent(5).collect do |post| | ||
# # li link_to(post.title, admin_post_path(post)) | ||
# # end | ||
# # end | ||
# # end | ||
# | ||
# # == Render Partial Section | ||
# # The block is rendered within the context of the view, so you can | ||
# # easily render a partial rather than build content in ruby. | ||
# # | ||
# # section "Recent Posts" do | ||
# # div do | ||
# # render 'recent_posts' # => this will render /app/views/admin/dashboard/_recent_posts.html.erb | ||
# # end | ||
# # end | ||
# | ||
# # == Section Ordering | ||
# # The dashboard sections are ordered by a given priority from top left to | ||
# # bottom right. The default priority is 10. By giving a section numerically lower | ||
# # priority it will be sorted higher. For example: | ||
# # | ||
# # section "Recent Posts", :priority => 10 | ||
# # section "Recent User", :priority => 1 | ||
# # | ||
# # Will render the "Recent Users" then the "Recent Posts" sections on the dashboard. | ||
# | ||
# # == Conditionally Display | ||
# # Provide a method name or Proc object to conditionally render a section at run time. | ||
# # | ||
# # section "Membership Summary", :if => :memberships_enabled? | ||
# # section "Membership Summary", :if => Proc.new { current_admin_user.account.memberships.any? } | ||
# | ||
# end | ||
ActiveAdmin.register_page "Dashboard" do | ||
menu priority: 1, label: proc { I18n.t("active_admin.dashboard") } | ||
|
||
content title: proc { I18n.t("active_admin.dashboard") } do | ||
div class: "blank_slate_container", id: "dashboard_default_message" do | ||
span class: "blank_slate" do | ||
span I18n.t("active_admin.dashboard_welcome.welcome") | ||
small I18n.t("active_admin.dashboard_welcome.call_to_action") | ||
end | ||
end | ||
|
||
# Define your dashboard sections here. Each block will be | ||
# rendered on the dashboard in the context of the view. So just | ||
# return the content which you would like to display. | ||
|
||
# == Simple Dashboard Section | ||
# Here is an example of a simple dashboard section | ||
# | ||
# section "Recent Posts" do | ||
# ul do | ||
# Post.recent(5).collect do |post| | ||
# li link_to(post.title, admin_post_path(post)) | ||
# end | ||
# end | ||
# end | ||
|
||
# == Render Partial Section | ||
# The block is rendered within the context of the view, so you can | ||
# easily render a partial rather than build content in ruby. | ||
# | ||
# section "Recent Posts" do | ||
# div do | ||
# render 'recent_posts' # => this will render /app/views/admin/dashboard/_recent_posts.html.erb | ||
# end | ||
# end | ||
|
||
# == Section Ordering | ||
# The dashboard sections are ordered by a given priority from top left to | ||
# bottom right. The default priority is 10. By giving a section numerically lower | ||
# priority it will be sorted higher. For example: | ||
# | ||
# section "Recent Posts", :priority => 10 | ||
# section "Recent User", :priority => 1 | ||
# | ||
# Will render the "Recent Users" then the "Recent Posts" sections on the dashboard. | ||
|
||
# == Conditionally Display | ||
# Provide a method name or Proc object to conditionally render a section at run time. | ||
# | ||
# section "Membership Summary", :if => :memberships_enabled? | ||
# section "Membership Summary", :if => Proc.new { current_admin_user.account.memberships.any? } | ||
|
||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,7 +12,7 @@ | |
l.likes.count | ||
end | ||
column :created_at | ||
default_actions | ||
actions | ||
end | ||
|
||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,7 +13,7 @@ | |
column :likes do |user| | ||
user.likes.count | ||
end | ||
default_actions | ||
actions | ||
end | ||
|
||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.