From f03f99175983cfb87dad22e9e4e50bcc626c2bcb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juan=20Ruiti=C3=B1a?= Date: Mon, 29 Apr 2024 16:01:45 +0200 Subject: [PATCH 1/2] Add status field --- vanilla/templates/static/decap/config.yml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/vanilla/templates/static/decap/config.yml b/vanilla/templates/static/decap/config.yml index 9daa7cc..e28035f 100644 --- a/vanilla/templates/static/decap/config.yml +++ b/vanilla/templates/static/decap/config.yml @@ -42,6 +42,18 @@ collections: widget: object fields: - {label: 'Title', name: 'title', widget: 'string'} + - label: 'Status' + name: 'status' + widget: 'select' + options: + - { label: 'Braindump', value: 'braindump' } + - { label: 'Draft', value: 'draft' } + - { label: 'Pending review', value: 'review' } + - { label: 'Approved', value: 'approved' } + - { label: 'Completed', value: 'completed' } + - { label: 'Rejected', value: 'rejected' } + - { label: 'Outdated', value: 'outdated' } + - { label: 'Deprecated', value: 'deprecated' } - {label: 'Body', name: 'body', widget: 'markdown'} summary: '{{dirname}}' meta: {path: {widget: string, label: 'Path', index_file: 'index'}} From 16de2483790770515db43ed254039909f4e6387b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juan=20Ruiti=C3=B1a?= Date: Mon, 29 Apr 2024 16:07:40 +0200 Subject: [PATCH 2/2] Move status under context --- vanilla/templates/static/decap/config.yml | 24 +++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/vanilla/templates/static/decap/config.yml b/vanilla/templates/static/decap/config.yml index e28035f..fa9ec31 100644 --- a/vanilla/templates/static/decap/config.yml +++ b/vanilla/templates/static/decap/config.yml @@ -42,18 +42,18 @@ collections: widget: object fields: - {label: 'Title', name: 'title', widget: 'string'} - - label: 'Status' - name: 'status' - widget: 'select' - options: - - { label: 'Braindump', value: 'braindump' } - - { label: 'Draft', value: 'draft' } - - { label: 'Pending review', value: 'review' } - - { label: 'Approved', value: 'approved' } - - { label: 'Completed', value: 'completed' } - - { label: 'Rejected', value: 'rejected' } - - { label: 'Outdated', value: 'outdated' } - - { label: 'Deprecated', value: 'deprecated' } + - label: 'Status' + name: 'status' + widget: 'select' + options: + - { label: 'Braindump', value: 'braindump' } + - { label: 'Draft', value: 'draft' } + - { label: 'Pending review', value: 'review' } + - { label: 'Approved', value: 'approved' } + - { label: 'Completed', value: 'completed' } + - { label: 'Rejected', value: 'rejected' } + - { label: 'Outdated', value: 'outdated' } + - { label: 'Deprecated', value: 'deprecated' } - {label: 'Body', name: 'body', widget: 'markdown'} summary: '{{dirname}}' meta: {path: {widget: string, label: 'Path', index_file: 'index'}}