I’m trying to get new site section working…
I’ve got .json part succesfully serving data (http://localhost/faq_categories.json)
But for HTML request (http://localhost/faq_categories) Discourse generates 404 not found “Oops! That page doesn’t exist or is private”. I do have proper erb.html file in place.
I think that routing is working correctly (otherwise there would be error). Is there any part of Discourse application that would prevent me to run this simple code correctly?
Can you please help me to find what am I missing? Thanks a lot…!
get “/faq_categories” => “faq_categories#index”
class FaqCategoriesController < ApplicationController
@faq_categories = FaqCategory.all
respond_to do |format| format.html do render :index end format.json do render_serialized(@faq_categories, FaqCategorySerializer) end end
Frequently Asked Questions`