@raketa-cloud/admin 0.0.95 → 0.0.97
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/cloud/RaketaClient.js +5 -0
- package/src/cloud/Settings.js +6 -2
- package/src/views/article_revisions/codes/_form.ejs +13 -0
- package/src/views/article_revisions/codes/edit_form.ejs +1 -13
- package/src/views/article_revisions/locks/_form.ejs +11 -0
- package/src/views/article_revisions/locks/create_form.ejs +2 -12
- package/src/views/article_revisions/meta/_form.ejs +15 -0
- package/src/views/article_revisions/meta/edit_form.ejs +2 -16
- package/src/views/article_revisions/tags/_form.ejs +12 -0
- package/src/views/article_revisions/tags/edit_form.ejs +2 -13
- package/src/views/article_revisions/visuals/_form.ejs +12 -0
- package/src/views/article_revisions/visuals/edit_form.ejs +2 -13
- package/src/views/event_revisions/codes/_form.ejs +13 -0
- package/src/views/event_revisions/codes/edit_form.ejs +1 -13
- package/src/views/event_revisions/locks/_form.ejs +11 -0
- package/src/views/event_revisions/locks/create_form.ejs +2 -12
- package/src/views/event_revisions/meta/_form.ejs +15 -0
- package/src/views/event_revisions/meta/edit_form.ejs +2 -16
- package/src/views/event_revisions/tags/_form.ejs +12 -0
- package/src/views/event_revisions/tags/edit_form.ejs +2 -13
- package/src/views/event_revisions/visuals/_form.ejs +12 -0
- package/src/views/event_revisions/visuals/edit_form.ejs +2 -13
- package/src/views/page_revisions/codes/_form.ejs +13 -0
- package/src/views/page_revisions/codes/edit_form.ejs +1 -13
- package/src/views/page_revisions/locks/_form.ejs +11 -0
- package/src/views/page_revisions/locks/create_form.ejs +2 -12
- package/src/views/page_revisions/meta/_form.ejs +15 -0
- package/src/views/page_revisions/meta/edit_form.ejs +1 -15
- package/src/views/page_revisions/tags/_form.ejs +12 -0
- package/src/views/page_revisions/tags/edit_form.ejs +3 -14
- package/src/views/page_revisions/visuals/_form.ejs +12 -0
- package/src/views/page_revisions/visuals/edit_form.ejs +1 -12
package/package.json
CHANGED
package/src/cloud/Settings.js
CHANGED
|
@@ -7,12 +7,16 @@ import {
|
|
|
7
7
|
export default class Settings extends RaketaClient {
|
|
8
8
|
async find(locale) {
|
|
9
9
|
const {
|
|
10
|
-
setting
|
|
10
|
+
setting,
|
|
11
11
|
} = await this.query(SettingDocument, {
|
|
12
12
|
locale,
|
|
13
13
|
});
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
if (!setting?.value) {
|
|
16
|
+
this.logError(`Cannot find settings for ${locale} locale.`)
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
return setting.value;
|
|
16
20
|
}
|
|
17
21
|
|
|
18
22
|
async update(locale, params) {
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<% form_for({ resource }, errors, (f) => { %>
|
|
2
|
+
<form action="<%= `/${_context.locale}/${_context.resourceConfig.articleType}_revisions/${resource.id}/codes` %>" method="POST" class="form">
|
|
3
|
+
<%- render_partial('../../_shared/_scripts_input.ejs', { resource, f }) %>
|
|
4
|
+
<%- render_partial('../../_shared/_structured_json_input.ejs', { resource, f }) %>
|
|
5
|
+
|
|
6
|
+
<div class="form-actions">
|
|
7
|
+
<div class="btn-toolbar">
|
|
8
|
+
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
9
|
+
<a href="<%= `/${_context.locale}/${_context.resourceConfig.articleTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
10
|
+
</div>
|
|
11
|
+
</div>
|
|
12
|
+
</form>
|
|
13
|
+
<% }) %>
|
|
@@ -10,19 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
<div class="grid gap-4 md:grid-cols-3">
|
|
12
12
|
<div>
|
|
13
|
-
|
|
14
|
-
<form action="<%= `/${_context.locale}/${_context.resourceConfig.articleType}_revisions/${resource.id}/codes` %>" method="POST" class="form">
|
|
15
|
-
<%- render_partial('../../_shared/_scripts_input.ejs', { resource, f }) %>
|
|
16
|
-
<%- render_partial('../../_shared/_structured_json_input.ejs', { resource, f }) %>
|
|
17
|
-
|
|
18
|
-
<div class="form-actions">
|
|
19
|
-
<div class="btn-toolbar">
|
|
20
|
-
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
21
|
-
<a href="<%= `/${_context.locale}/${_context.resourceConfig.articleTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
22
|
-
</div>
|
|
23
|
-
</div>
|
|
24
|
-
</form>
|
|
25
|
-
<% }) %>
|
|
13
|
+
<%- render_partial('_form.ejs', { render_partial: render_partial }) %>
|
|
26
14
|
</div>
|
|
27
15
|
</div>
|
|
28
16
|
</div>
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<% form_for({ resource }, errors, (f) => { %>
|
|
2
|
+
<form action="<%= `/${_context.locale}/${_context.resourceConfig.articleType}_revisions/${resource.id}/locks` %>" method="POST" class="form">
|
|
3
|
+
<%- f.field('resource.message', { as: 'textarea', label: 'Lock Message', required: true }) %>
|
|
4
|
+
<div class="form-actions">
|
|
5
|
+
<div class="btn-toolbar">
|
|
6
|
+
<%- f.submit('Lock revision', { class: 'btn-primary' }) %>
|
|
7
|
+
<a href="<%= `/${_context.locale}/${_context.resourceConfig.articleTypePlural}/${resource.originalId}` %>" class="btn-secondary">Cancel</a>
|
|
8
|
+
</div>
|
|
9
|
+
</div>
|
|
10
|
+
</form>
|
|
11
|
+
<% }) %>
|
|
@@ -5,17 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
<div class="grid gap-4 md:grid-cols-3">
|
|
7
7
|
<div>
|
|
8
|
-
|
|
9
|
-
<form action="<%= `/${_context.locale}/${_context.resourceConfig.articleType}_revisions/${resource.id}/locks` %>" method="POST" class="form">
|
|
10
|
-
<%- f.field('resource.message', { as: 'textarea', label: 'Lock Message', required: true }) %>
|
|
11
|
-
<div class="form-actions">
|
|
12
|
-
<div class="btn-toolbar">
|
|
13
|
-
<%- f.submit('Lock revision', { class: 'btn-primary' }) %>
|
|
14
|
-
<a href="<%= `/${_context.locale}/${_context.resourceConfig.articleTypePlural}/${resource.originalId}` %>" class="btn-secondary">Cancel</a>
|
|
15
|
-
</div>
|
|
16
|
-
</div>
|
|
17
|
-
</form>
|
|
18
|
-
<% }) %>
|
|
8
|
+
<%- render_partial('_form.ejs') %>
|
|
19
9
|
</div>
|
|
20
10
|
|
|
21
11
|
<div>
|
|
@@ -34,4 +24,4 @@
|
|
|
34
24
|
</div>
|
|
35
25
|
</div>
|
|
36
26
|
</div>
|
|
37
|
-
</div>
|
|
27
|
+
</div>
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
<% form_for({ resource }, errors, (f) => { %>
|
|
2
|
+
<form action="<%= `/${_context.locale}/${_context.resourceConfig.articleType}_revisions/${resource.id}/meta` %>" method="POST" class="form">
|
|
3
|
+
<%- f.field('resource.settings.meta.title', { required: true, label: "Meta title", hint: "Used for both meta and OpenGraph" }) %>
|
|
4
|
+
<%- f.field('resource.settings.meta.description', { as: "textarea", required: true, label: "Meta description", hint: "Used for both meta and OpenGraph" }) %>
|
|
5
|
+
|
|
6
|
+
<raketa-image-picker name="resource[settings][meta][image]" value="<%= JSON.stringify(resource.settings?.meta?.image || {}) %>" label="OpenGraph image"></raketa-image-picker>
|
|
7
|
+
|
|
8
|
+
<div class="form-actions">
|
|
9
|
+
<div class="btn-toolbar">
|
|
10
|
+
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
11
|
+
<a href="<%= `/${_context.locale}/${_context.resourceConfig.articleTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
12
|
+
</div>
|
|
13
|
+
</div>
|
|
14
|
+
</form>
|
|
15
|
+
<% }) %>
|
|
@@ -10,21 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
<div class="grid gap-4 md:grid-cols-3">
|
|
12
12
|
<div>
|
|
13
|
-
|
|
14
|
-
<form action="<%= `/${_context.locale}/${_context.resourceConfig.articleType}_revisions/${resource.id}/meta` %>" method="POST" class="form">
|
|
15
|
-
<%- f.field('resource.settings.meta.title', { required: true, label: "Meta title", hint: "Used for both meta and OpenGraph" }) %>
|
|
16
|
-
<%- f.field('resource.settings.meta.description', { as: "textarea", required: true, label: "Meta description", hint: "Used for both meta and OpenGraph" }) %>
|
|
17
|
-
|
|
18
|
-
<raketa-image-picker name="resource[settings][meta][image]" value="<%= JSON.stringify(resource.settings?.meta?.image || {}) %>" label="OpenGraph image"></raketa-image-picker>
|
|
19
|
-
|
|
20
|
-
<div class="form-actions">
|
|
21
|
-
<div class="btn-toolbar">
|
|
22
|
-
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
23
|
-
<a href="<%= `/${_context.locale}/${_context.resourceConfig.articleTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
24
|
-
</div>
|
|
25
|
-
</div>
|
|
26
|
-
</form>
|
|
27
|
-
<% }) %>
|
|
13
|
+
<%- render_partial('_form.ejs') %>
|
|
28
14
|
</div>
|
|
29
15
|
</div>
|
|
30
|
-
</div>
|
|
16
|
+
</div>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<% form_for({ resource }, errors, (f) => { %>
|
|
2
|
+
<form action="<%= `/${_context.locale}/${_context.resourceConfig.articleType}_revisions/${resource.id}/tags` %>" method="POST" class="form">
|
|
3
|
+
<%- f.field('resource.tags', { as: 'checkbox_group', options: tags.map(tag => [tag.id, tag.name]) }) %>
|
|
4
|
+
|
|
5
|
+
<div class="form-actions">
|
|
6
|
+
<div class="btn-toolbar">
|
|
7
|
+
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
8
|
+
<a href="<%= `/${_context.locale}/${_context.resourceConfig.articleTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
9
|
+
</div>
|
|
10
|
+
</div>
|
|
11
|
+
</form>
|
|
12
|
+
<% }) %>
|
|
@@ -10,18 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
<div class="grid gap-4 md:grid-cols-3">
|
|
12
12
|
<div>
|
|
13
|
-
|
|
14
|
-
<form action="<%= `/${_context.locale}/${_context.resourceConfig.articleType}_revisions/${resource.id}/tags` %>" method="POST" class="form">
|
|
15
|
-
<%- f.field('resource.tags', { as: 'checkbox_group', options: tags.map(tag => [tag.id, tag.name]) }) %>
|
|
16
|
-
|
|
17
|
-
<div class="form-actions">
|
|
18
|
-
<div class="btn-toolbar">
|
|
19
|
-
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
20
|
-
<a href="<%= `/${_context.locale}/${_context.resourceConfig.articleTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
21
|
-
</div>
|
|
22
|
-
</div>
|
|
23
|
-
</form>
|
|
24
|
-
<% }) %>
|
|
13
|
+
<%- render_partial('_form.ejs', { tags: tags }) %>
|
|
25
14
|
</div>
|
|
26
15
|
</div>
|
|
27
|
-
</div>
|
|
16
|
+
</div>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<% form_for({ resource }, errors, (f) => { %>
|
|
2
|
+
<form action="<%= `/${_context.locale}/${_context.resourceConfig.articleType}_revisions/${resource.id}/visuals` %>" method="POST" class="form">
|
|
3
|
+
<%- include('../../_shared/_layout_input.ejs', { f }) %>
|
|
4
|
+
|
|
5
|
+
<div class="form-actions">
|
|
6
|
+
<div class="btn-toolbar">
|
|
7
|
+
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
8
|
+
<a href="<%= `/${_context.locale}/${_context.resourceConfig.articleTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
9
|
+
</div>
|
|
10
|
+
</div>
|
|
11
|
+
</form>
|
|
12
|
+
<% }) %>
|
|
@@ -10,18 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
<div class="grid gap-4 md:grid-cols-3">
|
|
12
12
|
<div>
|
|
13
|
-
|
|
14
|
-
<form action="<%= `/${_context.locale}/${_context.resourceConfig.articleType}_revisions/${resource.id}/visuals` %>" method="POST" class="form">
|
|
15
|
-
<%- include('../../_shared/_layout_input.ejs', { f }) %>
|
|
16
|
-
|
|
17
|
-
<div class="form-actions">
|
|
18
|
-
<div class="btn-toolbar">
|
|
19
|
-
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
20
|
-
<a href="<%= `/${_context.locale}/${_context.resourceConfig.articleTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
21
|
-
</div>
|
|
22
|
-
</div>
|
|
23
|
-
</form>
|
|
24
|
-
<% }) %>
|
|
13
|
+
<%- render_partial('_form.ejs') %>
|
|
25
14
|
</div>
|
|
26
15
|
</div>
|
|
27
|
-
</div>
|
|
16
|
+
</div>
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<% form_for({ resource }, errors, (f) => { %>
|
|
2
|
+
<form action="<%= `/${_context.locale}/${_context.resourceConfig.eventType}_revisions/${resource.id}/codes` %>" method="POST" class="form">
|
|
3
|
+
<%- render_partial('../../_shared/_scripts_input.ejs', { resource, f }) %>
|
|
4
|
+
<%- render_partial('../../_shared/_structured_json_input.ejs', { resource, f }) %>
|
|
5
|
+
|
|
6
|
+
<div class="form-actions">
|
|
7
|
+
<div class="btn-toolbar">
|
|
8
|
+
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
9
|
+
<a href="<%= `/${_context.locale}/${_context.resourceConfig.eventTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
10
|
+
</div>
|
|
11
|
+
</div>
|
|
12
|
+
</form>
|
|
13
|
+
<% }) %>
|
|
@@ -10,19 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
<div class="grid gap-4 md:grid-cols-3">
|
|
12
12
|
<div>
|
|
13
|
-
|
|
14
|
-
<form action="<%= `/${_context.locale}/${_context.resourceConfig.eventType}_revisions/${resource.id}/codes` %>" method="POST" class="form">
|
|
15
|
-
<%- render_partial('../../_shared/_scripts_input.ejs', { resource, f }) %>
|
|
16
|
-
<%- render_partial('../../_shared/_structured_json_input.ejs', { resource, f }) %>
|
|
17
|
-
|
|
18
|
-
<div class="form-actions">
|
|
19
|
-
<div class="btn-toolbar">
|
|
20
|
-
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
21
|
-
<a href="<%= `/${_context.locale}/${_context.resourceConfig.eventTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
22
|
-
</div>
|
|
23
|
-
</div>
|
|
24
|
-
</form>
|
|
25
|
-
<% }) %>
|
|
13
|
+
<%- render_partial('_form.ejs', { render_partial: render_partial }) %>
|
|
26
14
|
</div>
|
|
27
15
|
</div>
|
|
28
16
|
</div>
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<% form_for({ resource }, errors, (f) => { %>
|
|
2
|
+
<form action="<%= `/${_context.locale}/${_context.resourceConfig.eventType}_revisions/${resource.id}/locks` %>" method="POST" class="form">
|
|
3
|
+
<%- f.field('resource.message', { as: 'textarea', label: 'Lock Message', required: true }) %>
|
|
4
|
+
<div class="form-actions">
|
|
5
|
+
<div class="btn-toolbar">
|
|
6
|
+
<%- f.submit('Lock revision', { class: 'btn-primary' }) %>
|
|
7
|
+
<a href="<%= `/${_context.locale}/${_context.resourceConfig.eventTypePlural}/${resource.originalId}` %>" class="btn-secondary">Cancel</a>
|
|
8
|
+
</div>
|
|
9
|
+
</div>
|
|
10
|
+
</form>
|
|
11
|
+
<% }) %>
|
|
@@ -5,17 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
<div class="grid gap-4 md:grid-cols-3">
|
|
7
7
|
<div>
|
|
8
|
-
|
|
9
|
-
<form action="<%= `/${_context.locale}/${_context.resourceConfig.eventType}_revisions/${resource.id}/locks` %>" method="POST" class="form">
|
|
10
|
-
<%- f.field('resource.message', { as: 'textarea', label: 'Lock Message', required: true }) %>
|
|
11
|
-
<div class="form-actions">
|
|
12
|
-
<div class="btn-toolbar">
|
|
13
|
-
<%- f.submit('Lock revision', { class: 'btn-primary' }) %>
|
|
14
|
-
<a href="<%= `/${_context.locale}/${_context.resourceConfig.eventTypePlural}/${resource.originalId}` %>" class="btn-secondary">Cancel</a>
|
|
15
|
-
</div>
|
|
16
|
-
</div>
|
|
17
|
-
</form>
|
|
18
|
-
<% }) %>
|
|
8
|
+
<%- render_partial('_form.ejs') %>
|
|
19
9
|
</div>
|
|
20
10
|
|
|
21
11
|
<div>
|
|
@@ -34,4 +24,4 @@
|
|
|
34
24
|
</div>
|
|
35
25
|
</div>
|
|
36
26
|
</div>
|
|
37
|
-
</div>
|
|
27
|
+
</div>
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
<% form_for({ resource }, errors, (f) => { %>
|
|
2
|
+
<form action="<%= `/${_context.locale}/${_context.resourceConfig.eventType}_revisions/${resource.id}/meta` %>" method="POST" class="form">
|
|
3
|
+
<%- f.field('resource.settings.meta.title', { required: true, label: "Meta title", hint: "Used for both meta and OpenGraph" }) %>
|
|
4
|
+
<%- f.field('resource.settings.meta.description', { as: "textarea", required: true, label: "Meta description", hint: "Used for both meta and OpenGraph" }) %>
|
|
5
|
+
|
|
6
|
+
<raketa-image-picker name="resource[settings][meta][image]" value="<%= JSON.stringify(resource.settings?.meta?.image || {}) %>" label="OpenGraph image"></raketa-image-picker>
|
|
7
|
+
|
|
8
|
+
<div class="form-actions">
|
|
9
|
+
<div class="btn-toolbar">
|
|
10
|
+
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
11
|
+
<a href="<%= `/${_context.locale}/${_context.resourceConfig.eventTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
12
|
+
</div>
|
|
13
|
+
</div>
|
|
14
|
+
</form>
|
|
15
|
+
<% }) %>
|
|
@@ -10,21 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
<div class="grid gap-4 md:grid-cols-3">
|
|
12
12
|
<div>
|
|
13
|
-
|
|
14
|
-
<form action="<%= `/${_context.locale}/${_context.resourceConfig.eventType}_revisions/${resource.id}/meta` %>" method="POST" class="form">
|
|
15
|
-
<%- f.field('resource.settings.meta.title', { required: true, label: "Meta title", hint: "Used for both meta and OpenGraph" }) %>
|
|
16
|
-
<%- f.field('resource.settings.meta.description', { as: "textarea", required: true, label: "Meta description", hint: "Used for both meta and OpenGraph" }) %>
|
|
17
|
-
|
|
18
|
-
<raketa-image-picker name="resource[settings][meta][image]" value="<%= JSON.stringify(resource.settings?.meta?.image || {}) %>" label="OpenGraph image"></raketa-image-picker>
|
|
19
|
-
|
|
20
|
-
<div class="form-actions">
|
|
21
|
-
<div class="btn-toolbar">
|
|
22
|
-
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
23
|
-
<a href="<%= `/${_context.locale}/${_context.resourceConfig.eventTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
24
|
-
</div>
|
|
25
|
-
</div>
|
|
26
|
-
</form>
|
|
27
|
-
<% }) %>
|
|
13
|
+
<%- render_partial('_form.ejs') %>
|
|
28
14
|
</div>
|
|
29
15
|
</div>
|
|
30
|
-
</div>
|
|
16
|
+
</div>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<% form_for({ resource }, errors, (f) => { %>
|
|
2
|
+
<form action="<%= `/${_context.locale}/${_context.resourceConfig.eventType}_revisions/${resource.id}/tags` %>" method="POST" class="form">
|
|
3
|
+
<%- f.field('resource.tags', { as: 'checkbox_group', options: tags.map(tag => [tag.id, tag.name]) }) %>
|
|
4
|
+
|
|
5
|
+
<div class="form-actions">
|
|
6
|
+
<div class="btn-toolbar">
|
|
7
|
+
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
8
|
+
<a href="<%= `/${_context.locale}/${_context.resourceConfig.eventTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
9
|
+
</div>
|
|
10
|
+
</div>
|
|
11
|
+
</form>
|
|
12
|
+
<% }) %>
|
|
@@ -10,18 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
<div class="grid gap-4 md:grid-cols-3">
|
|
12
12
|
<div>
|
|
13
|
-
|
|
14
|
-
<form action="<%= `/${_context.locale}/${_context.resourceConfig.eventType}_revisions/${resource.id}/tags` %>" method="POST" class="form">
|
|
15
|
-
<%- f.field('resource.tags', { as: 'checkbox_group', options: tags.map(tag => [tag.id, tag.name]) }) %>
|
|
16
|
-
|
|
17
|
-
<div class="form-actions">
|
|
18
|
-
<div class="btn-toolbar">
|
|
19
|
-
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
20
|
-
<a href="<%= `/${_context.locale}/${_context.resourceConfig.eventTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
21
|
-
</div>
|
|
22
|
-
</div>
|
|
23
|
-
</form>
|
|
24
|
-
<% }) %>
|
|
13
|
+
<%- render_partial('_form.ejs', { tags: tags }) %>
|
|
25
14
|
</div>
|
|
26
15
|
</div>
|
|
27
|
-
</div>
|
|
16
|
+
</div>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<% form_for({ resource }, errors, (f) => { %>
|
|
2
|
+
<form action="<%= `/${_context.locale}/${_context.resourceConfig.eventType}_revisions/${resource.id}/visuals` %>" method="POST" class="form">
|
|
3
|
+
<%- include('../../_shared/_layout_input.ejs', { f }) %>
|
|
4
|
+
|
|
5
|
+
<div class="form-actions">
|
|
6
|
+
<div class="btn-toolbar">
|
|
7
|
+
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
8
|
+
<a href="<%= `/${_context.locale}/${_context.resourceConfig.eventTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
9
|
+
</div>
|
|
10
|
+
</div>
|
|
11
|
+
</form>
|
|
12
|
+
<% }) %>
|
|
@@ -10,18 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
<div class="grid gap-4 md:grid-cols-3">
|
|
12
12
|
<div>
|
|
13
|
-
|
|
14
|
-
<form action="<%= `/${_context.locale}/${_context.resourceConfig.eventType}_revisions/${resource.id}/visuals` %>" method="POST" class="form">
|
|
15
|
-
<%- include('../../_shared/_layout_input.ejs', { f }) %>
|
|
16
|
-
|
|
17
|
-
<div class="form-actions">
|
|
18
|
-
<div class="btn-toolbar">
|
|
19
|
-
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
20
|
-
<a href="<%= `/${_context.locale}/${_context.resourceConfig.eventTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
21
|
-
</div>
|
|
22
|
-
</div>
|
|
23
|
-
</form>
|
|
24
|
-
<% }) %>
|
|
13
|
+
<%- render_partial('_form.ejs') %>
|
|
25
14
|
</div>
|
|
26
15
|
</div>
|
|
27
|
-
</div>
|
|
16
|
+
</div>
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<% form_for({ resource }, errors, (f) => { %>
|
|
2
|
+
<form action="<%= `/${_context.locale}/${_context.resourceConfig.pageType}_revisions/${resource.id}/codes` %>" method="POST" class="form">
|
|
3
|
+
<%- render_partial('../../_shared/_scripts_input.ejs', { resource, f }) %>
|
|
4
|
+
<%- render_partial('../../_shared/_structured_json_input.ejs', { resource, f }) %>
|
|
5
|
+
|
|
6
|
+
<div class="form-actions">
|
|
7
|
+
<div class="btn-toolbar">
|
|
8
|
+
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
9
|
+
<a href="<%= `/${_context.locale}/${_context.resourceConfig.pageTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
10
|
+
</div>
|
|
11
|
+
</div>
|
|
12
|
+
</form>
|
|
13
|
+
<% }) %>
|
|
@@ -10,19 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
<div class="grid gap-4 md:grid-cols-3">
|
|
12
12
|
<div>
|
|
13
|
-
|
|
14
|
-
<form action="<%= `/${_context.locale}/${_context.resourceConfig.pageType}_revisions/${resource.id}/codes` %>" method="POST" class="form">
|
|
15
|
-
<%- render_partial('../../_shared/_scripts_input.ejs', { resource, f }) %>
|
|
16
|
-
<%- render_partial('../../_shared/_structured_json_input.ejs', { resource, f }) %>
|
|
17
|
-
|
|
18
|
-
<div class="form-actions">
|
|
19
|
-
<div class="btn-toolbar">
|
|
20
|
-
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
21
|
-
<a href="<%= `/${_context.locale}/${_context.resourceConfig.pageTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
22
|
-
</div>
|
|
23
|
-
</div>
|
|
24
|
-
</form>
|
|
25
|
-
<% }) %>
|
|
13
|
+
<%- render_partial('_form.ejs', { render_partial: render_partial }) %>
|
|
26
14
|
</div>
|
|
27
15
|
</div>
|
|
28
16
|
</div>
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<% form_for({ resource }, errors, (f) => { %>
|
|
2
|
+
<form action="<%= `/${_context.locale}/${_context.resourceConfig.pageType}_revisions/${resource.id}/locks` %>" method="POST" class="form">
|
|
3
|
+
<%- f.field('resource.message', { as: 'textarea', label: 'Lock Message', required: true }) %>
|
|
4
|
+
<div class="form-actions">
|
|
5
|
+
<div class="btn-toolbar">
|
|
6
|
+
<%- f.submit('Lock revision', { class: 'btn-primary' }) %>
|
|
7
|
+
<a href="<%= `/${_context.locale}/${_context.resourceConfig.pageTypePlural}/${resource.originalId}` %>" class="btn-secondary">Cancel</a>
|
|
8
|
+
</div>
|
|
9
|
+
</div>
|
|
10
|
+
</form>
|
|
11
|
+
<% }) %>
|
|
@@ -5,17 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
<div class="grid gap-4 md:grid-cols-3">
|
|
7
7
|
<div>
|
|
8
|
-
|
|
9
|
-
<form action="<%= `/${_context.locale}/${_context.resourceConfig.pageType}_revisions/${resource.id}/locks` %>" method="POST" class="form">
|
|
10
|
-
<%- f.field('resource.message', { as: 'textarea', label: 'Lock Message', required: true }) %>
|
|
11
|
-
<div class="form-actions">
|
|
12
|
-
<div class="btn-toolbar">
|
|
13
|
-
<%- f.submit('Lock revision', { class: 'btn-primary' }) %>
|
|
14
|
-
<a href="<%= `/${_context.locale}/${_context.resourceConfig.pageTypePlural}/${resource.originalId}` %>" class="btn-secondary">Cancel</a>
|
|
15
|
-
</div>
|
|
16
|
-
</div>
|
|
17
|
-
</form>
|
|
18
|
-
<% }) %>
|
|
8
|
+
<%- render_partial('_form.ejs') %>
|
|
19
9
|
</div>
|
|
20
10
|
|
|
21
11
|
<div>
|
|
@@ -34,4 +24,4 @@
|
|
|
34
24
|
</div>
|
|
35
25
|
</div>
|
|
36
26
|
</div>
|
|
37
|
-
</div>
|
|
27
|
+
</div>
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
<% form_for({ resource }, errors, (f) => { %>
|
|
2
|
+
<form action="<%= `/${_context.locale}/${_context.resourceConfig.pageType}_revisions/${resource.id}/meta` %>" method="POST" class="form">
|
|
3
|
+
<%- f.field('resource.settings.meta.title', { required: true, label: "Meta title", hint: "Used for both meta and OpenGraph" }) %>
|
|
4
|
+
<%- f.field('resource.settings.meta.description', { as: "textarea", required: true, label: "Meta description", hint: "Used for both meta and OpenGraph" }) %>
|
|
5
|
+
|
|
6
|
+
<raketa-image-picker name="resource[settings][meta][image]" value="<%= JSON.stringify(resource.settings?.meta?.image || {}) %>" label="OpenGraph image"></raketa-image-picker>
|
|
7
|
+
|
|
8
|
+
<div class="form-actions">
|
|
9
|
+
<div class="btn-toolbar">
|
|
10
|
+
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
11
|
+
<a href="<%= `/${_context.locale}/${_context.resourceConfig.pageTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
12
|
+
</div>
|
|
13
|
+
</div>
|
|
14
|
+
</form>
|
|
15
|
+
<% }) %>
|
|
@@ -10,21 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
<div class="grid gap-4 md:grid-cols-3">
|
|
12
12
|
<div>
|
|
13
|
-
|
|
14
|
-
<form action="<%= `/${_context.locale}/${_context.resourceConfig.pageType}_revisions/${resource.id}/meta` %>" method="POST" class="form">
|
|
15
|
-
<%- f.field('resource.settings.meta.title', { required: true, label: "Meta title", hint: "Used for both meta and OpenGraph" }) %>
|
|
16
|
-
<%- f.field('resource.settings.meta.description', { as: "textarea", required: true, label: "Meta description", hint: "Used for both meta and OpenGraph" }) %>
|
|
17
|
-
|
|
18
|
-
<raketa-image-picker name="resource[settings][meta][image]" value="<%= JSON.stringify(resource.settings?.meta?.image || {}) %>" label="OpenGraph image"></raketa-image-picker>
|
|
19
|
-
|
|
20
|
-
<div class="form-actions">
|
|
21
|
-
<div class="btn-toolbar">
|
|
22
|
-
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
23
|
-
<a href="<%= `/${_context.locale}/${_context.resourceConfig.pageTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
24
|
-
</div>
|
|
25
|
-
</div>
|
|
26
|
-
</form>
|
|
27
|
-
<% }) %>
|
|
13
|
+
<%- render_partial('_form.ejs') %>
|
|
28
14
|
</div>
|
|
29
15
|
</div>
|
|
30
16
|
</div>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<% form_for({ resource }, errors, (f) => { %>
|
|
2
|
+
<form action="<%= `/${_context.locale}/${_context.resourceConfig.pageType}_revisions/${resource.id}/tags` %>" method="POST" class="form">
|
|
3
|
+
<%- f.field('resource.tags', { as: 'checkbox_group', options: tags.map(tag => [tag.id, tag.name]) }) %>
|
|
4
|
+
|
|
5
|
+
<div class="form-actions">
|
|
6
|
+
<div class="btn-toolbar">
|
|
7
|
+
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
8
|
+
<a href="<%= `/${_context.locale}/${_context.resourceConfig.pageTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
9
|
+
</div>
|
|
10
|
+
</div>
|
|
11
|
+
</form>
|
|
12
|
+
<% }) %>
|
|
@@ -11,22 +11,11 @@
|
|
|
11
11
|
<div class="grid gap-4 md:grid-cols-3">
|
|
12
12
|
<div>
|
|
13
13
|
<% if(defaultLocaleTags?.length) {%>
|
|
14
|
-
|
|
15
|
-
|
|
14
|
+
<div class="font-bold text-sm">Original tags (<%= defaultLocaleName %>)</div>
|
|
15
|
+
<div class="mb-4 opacity-50"><%= defaultLocaleTags.map((tag) => tag.name).join(", ")%></div>
|
|
16
16
|
<% }%>
|
|
17
17
|
|
|
18
|
-
|
|
19
|
-
<form action="<%= `/${_context.locale}/${_context.resourceConfig.pageType}_revisions/${resource.id}/tags` %>" method="POST" class="form">
|
|
20
|
-
<%- f.field('resource.tags', { as: 'checkbox_group', options: tags.map(tag => [tag.id, tag.name]) }) %>
|
|
21
|
-
|
|
22
|
-
<div class="form-actions">
|
|
23
|
-
<div class="btn-toolbar">
|
|
24
|
-
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
25
|
-
<a href="<%= `/${_context.locale}/${_context.resourceConfig.pageTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
26
|
-
</div>
|
|
27
|
-
</div>
|
|
28
|
-
</form>
|
|
29
|
-
<% }) %>
|
|
18
|
+
<%- render_partial('_form.ejs', { tags: tags }) %>
|
|
30
19
|
</div>
|
|
31
20
|
</div>
|
|
32
21
|
</div>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<% form_for({ resource }, errors, (f) => { %>
|
|
2
|
+
<form action="<%= `/${_context.locale}/${_context.resourceConfig.pageType}_revisions/${resource.id}/visuals` %>" method="POST" class="form">
|
|
3
|
+
<%- include('../../_shared/_layout_input.ejs', { f }) %>
|
|
4
|
+
|
|
5
|
+
<div class="form-actions">
|
|
6
|
+
<div class="btn-toolbar">
|
|
7
|
+
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
8
|
+
<a href="<%= `/${_context.locale}/${_context.resourceConfig.pageTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
9
|
+
</div>
|
|
10
|
+
</div>
|
|
11
|
+
</form>
|
|
12
|
+
<% }) %>
|
|
@@ -10,18 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
<div class="grid gap-4 md:grid-cols-3">
|
|
12
12
|
<div>
|
|
13
|
-
|
|
14
|
-
<form action="<%= `/${_context.locale}/${_context.resourceConfig.pageType}_revisions/${resource.id}/visuals` %>" method="POST" class="form">
|
|
15
|
-
<%- include('../../_shared/_layout_input.ejs', { f }) %>
|
|
16
|
-
|
|
17
|
-
<div class="form-actions">
|
|
18
|
-
<div class="btn-toolbar">
|
|
19
|
-
<%- f.submit('Save changes', { class: 'btn-primary' }) %>
|
|
20
|
-
<a href="<%= `/${_context.locale}/${_context.resourceConfig.pageTypePlural}/${resource.originalId}` %>" class="btn-secondary">Back</a>
|
|
21
|
-
</div>
|
|
22
|
-
</div>
|
|
23
|
-
</form>
|
|
24
|
-
<% }) %>
|
|
13
|
+
<%- render_partial('_form.ejs') %>
|
|
25
14
|
</div>
|
|
26
15
|
</div>
|
|
27
16
|
</div>
|