Support for `value_list` in site settings
This commit is contained in:
parent
a7eabade19
commit
b41b176bc6
|
@ -4,7 +4,7 @@ import SiteSetting from 'admin/models/site-setting';
|
|||
import { propertyNotEqual } from 'discourse/lib/computed';
|
||||
import computed from 'ember-addons/ember-computed-decorators';
|
||||
|
||||
const CustomTypes = ['bool', 'enum', 'list', 'url_list', 'host_list', 'category_list'];
|
||||
const CustomTypes = ['bool', 'enum', 'list', 'url_list', 'host_list', 'category_list', 'value_list'];
|
||||
|
||||
export default Ember.Component.extend(BufferedContent, ScrollTop, {
|
||||
classNameBindings: [':row', ':setting', 'setting.overridden', 'typeClass'],
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
{{value-list values=value}}
|
||||
{{setting-validation-message message=validationMessage}}
|
||||
<div class='desc'>{{{unbound setting.description}}}</div>
|
|
@ -21,7 +21,18 @@ module SiteSettingExtension
|
|||
end
|
||||
|
||||
def types
|
||||
@types ||= Enum.new(:string, :time, :fixnum, :float, :bool, :null, :enum, :list, :url_list, :host_list, :category_list)
|
||||
@types ||= Enum.new(:string,
|
||||
:time,
|
||||
:fixnum,
|
||||
:float,
|
||||
:bool,
|
||||
:null,
|
||||
:enum,
|
||||
:list,
|
||||
:url_list,
|
||||
:host_list,
|
||||
:category_list,
|
||||
:value_list)
|
||||
end
|
||||
|
||||
def mutex
|
||||
|
|
Loading…
Reference in New Issue