|
|
@ -193,3 +193,36 @@ class CalendarAdjustmentConfig(EditorTextPreferences): |
|
|
required = False |
|
|
required = False |
|
|
verbose_name = 'Calendar Adjustment Config' |
|
|
verbose_name = 'Calendar Adjustment Config' |
|
|
default = '' |
|
|
default = '' |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
about_us_dobodi = { |
|
|
|
|
|
"type": "object", |
|
|
|
|
|
"format": "table", |
|
|
|
|
|
"title": "", |
|
|
|
|
|
"required_by_default": 1, |
|
|
|
|
|
"required": ['arabic_text', 'translated_text', 'title', 'content'], |
|
|
|
|
|
"properties": { |
|
|
|
|
|
"arabic_text": {"type": "string", "title": "text arabic"}, |
|
|
|
|
|
"translated_text": {"type": "string", "title": "translated text"}, |
|
|
|
|
|
"title": {"type": "string", "title": "title"}, |
|
|
|
|
|
"content": {"type": "string", "format": "textarea", "title": "Content", "rows": 8}, |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class JsonFieldAbout(BasePreferenceType): |
|
|
|
|
|
field_class = forms.JSONField |
|
|
|
|
|
serializer = JsonSerializer |
|
|
|
|
|
widget = JsonEditorWidget(attrs={'schema': about_us_dobodi}) |
|
|
|
|
|
|
|
|
|
|
|
@global_preferences_registry.register |
|
|
|
|
|
class SupportConfig(JsonFieldAbout): |
|
|
|
|
|
section = Section('about_us_dobodi', verbose_name='about Us Detail') |
|
|
|
|
|
name = 'about_us_dobodi' |
|
|
|
|
|
required = False |
|
|
|
|
|
verbose_name = 'About Us Dobodi' |
|
|
|
|
|
default = {} |
|
|
|
|
|
|
|
|
|
|
|
|