0
0
Fork 1
Spiegel von https://github.com/paviliondev/discourse-custom-wizard.git synchronisiert 2024-11-22 09:20:29 +01:00

Add integer data type to custom field feature

Dieser Commit ist enthalten in:
Angus McLeod 2020-10-20 18:24:27 +11:00
Ursprung cf8b06bbd0
Commit 4e094edc7b
3 geänderte Dateien mit 3 neuen und 2 gelöschten Zeilen

Datei anzeigen

@ -15,7 +15,7 @@ export default Component.extend({
postSerializers: ['post'], postSerializers: ['post'],
categorySerializers: ['basic_category', 'topic_view', 'topic_list_item'], categorySerializers: ['basic_category', 'topic_view', 'topic_list_item'],
klassContent: generateContent(['topic', 'post', 'group', 'category'], 'klass'), klassContent: generateContent(['topic', 'post', 'group', 'category'], 'klass'),
typeContent: generateContent(['string', 'boolean', 'json'], 'type'), typeContent: generateContent(['string', 'boolean', 'integer', 'json'], 'type'),
showInputs: or('field.new', 'field.edit'), showInputs: or('field.new', 'field.edit'),
@discourseComputed('field.klass') @discourseComputed('field.klass')

Datei anzeigen

@ -290,6 +290,7 @@ en:
label: "Type" label: "Type"
select: "Select a type" select: "Select a type"
string: "String" string: "String"
integer: "Integer"
boolean: "Boolean" boolean: "Boolean"
json: "JSON" json: "JSON"
klass: klass:

Datei anzeigen

@ -4,7 +4,7 @@ class ::CustomWizard::CustomField
CLASSES ||= ["topic", "group", "category", "post"] CLASSES ||= ["topic", "group", "category", "post"]
SERIALIZERS ||= ["topic_view", "topic_list_item", "post", "basic_category"] SERIALIZERS ||= ["topic_view", "topic_list_item", "post", "basic_category"]
TYPES ||= ["string", "boolean", "json"] TYPES ||= ["string", "boolean", "integer", "json"]
ATTRS ||= ["name", "klass", "type", "serializers"] ATTRS ||= ["name", "klass", "type", "serializers"]
KEY ||= "custom_wizard_custom_fields" KEY ||= "custom_wizard_custom_fields"