Implement forum topic voting and tag change pruning (#3580)
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
# Be sure to restart your server when you modify this file.
|
||||
|
||||
# Specify a serializer for the signed and encrypted cookie jars.
|
||||
# Valid options are :json, :marshal, and :hybrid.
|
||||
Rails.application.config.action_dispatch.cookies_serializer = :json
|
||||
|
||||
16
config/initializers/cors.rb
Normal file
16
config/initializers/cors.rb
Normal file
@@ -0,0 +1,16 @@
|
||||
# Be sure to restart your server when you modify this file.
|
||||
|
||||
# Avoid CORS issues when API is called from the frontend app.
|
||||
# Handle Cross-Origin Resource Sharing (CORS) in order to accept cross-origin AJAX requests.
|
||||
|
||||
# Read more: https://github.com/cyu/rack-cors
|
||||
|
||||
# Rails.application.config.middleware.insert_before 0, Rack::Cors do
|
||||
# allow do
|
||||
# origins 'example.com'
|
||||
#
|
||||
# resource '*',
|
||||
# headers: :any,
|
||||
# methods: [:get, :post, :put, :patch, :delete, :options, :head]
|
||||
# end
|
||||
# end
|
||||
@@ -5,6 +5,8 @@ en:
|
||||
hello: "Hello world"
|
||||
activerecord:
|
||||
attributes:
|
||||
forum_post_vote:
|
||||
creator_id: "Your vote"
|
||||
post:
|
||||
approver: "You"
|
||||
approver_id: "You"
|
||||
|
||||
@@ -132,6 +132,7 @@ Rails.application.routes.draw do
|
||||
resource :order, :only => [:edit], :controller => "favorite_group_orders"
|
||||
end
|
||||
resources :forum_posts do
|
||||
resource :votes, controller: "forum_post_votes"
|
||||
member do
|
||||
post :undelete
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user