Add content to the Remote Census Configuration tab
- Render remote census configuration content on settings index. - Update type method from Setting On Admin::SettingsController#index we are using 'all_settings' to group all settings by 'type' method. 'type' method return the first part of key when split by '.' To allow use by example: all_settings["remote_census.general"] and recover only settings related with this key we have added new 'elsif' on 'type' method.
This commit is contained in:
@@ -10,6 +10,8 @@ class Setting < ApplicationRecord
|
||||
def type
|
||||
if %w[feature process proposals map html homepage uploads].include? prefix
|
||||
prefix
|
||||
elsif %w[remote_census].include? prefix
|
||||
key.rpartition(".").first
|
||||
else
|
||||
"configuration"
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user