mirror of
https://github.com/jbcr/core.git
synced 2026-04-26 01:58:15 +02:00
Working!
This commit is contained in:
@@ -91,6 +91,11 @@ aside {
|
||||
}
|
||||
}
|
||||
|
||||
.ui.form input.large {
|
||||
font-size: 140%;
|
||||
padding: 11px 16px;
|
||||
}
|
||||
|
||||
td.listing-thumb img {
|
||||
// Get rid of extra space because of the baseline
|
||||
display: block;
|
||||
|
||||
@@ -254,6 +254,7 @@ blocks:
|
||||
type: text
|
||||
class: large
|
||||
group: "Block"
|
||||
label: De Titel
|
||||
slug:
|
||||
type: slug
|
||||
uses: [ title ]
|
||||
|
||||
@@ -57,7 +57,7 @@ class EditRecordController extends AbstractController
|
||||
//
|
||||
// $form->handleRequest($request);
|
||||
|
||||
return $this->render('bolt/edit/edit.twig', [
|
||||
return $this->render('bolt/editcontent/edit.twig', [
|
||||
'record' => $record,
|
||||
]);
|
||||
}
|
||||
|
||||
@@ -112,7 +112,7 @@ class FrontendController extends AbstractController
|
||||
*
|
||||
* @return Response
|
||||
*/
|
||||
protected function render(string $view, array $parameters = [], Response $response = null): Response
|
||||
protected function render($view, array $parameters = [], Response $response = null): Response
|
||||
{
|
||||
$themepath = sprintf(
|
||||
'%s/%s',
|
||||
|
||||
@@ -1,11 +0,0 @@
|
||||
{% extends 'bolt/base.html.twig' %}
|
||||
|
||||
{% block title %}
|
||||
Edit » <strong>{{ record.title|default('New') }}</strong>
|
||||
{% endblock %}
|
||||
|
||||
{% block body %}
|
||||
|
||||
{{ dump(record) }}
|
||||
|
||||
{% endblock %}
|
||||
@@ -0,0 +1,36 @@
|
||||
{% extends 'bolt/base.html.twig' %}
|
||||
|
||||
{% block title %}
|
||||
Edit » <strong>{{ record.title|default('New') }}</strong>
|
||||
{% endblock %}
|
||||
|
||||
{% block body %}
|
||||
|
||||
{{ dump(record) }}
|
||||
|
||||
<form method="post" class="ui form">
|
||||
|
||||
<!-- fixed stuff -->
|
||||
<input type="text" name="id" value="{{ record.id }}">
|
||||
{#<input type="text" name="author" value="{{ record.author }}">#}
|
||||
<input type="text" name="status" value="{{ record.status }}">
|
||||
|
||||
<input type="text" name="createdAt" value="{{ record.createdAt|date(format='r', timezone='GMT') }}">
|
||||
<input type="text" name="modifiedAt" value="{{ record.modifiedAt|date(format='r', timezone='GMT') }}">
|
||||
<input type="text" name="publishedAt" value="{{ record.publishedAt|date(format='r', timezone='GMT') }}">
|
||||
<input type="text" name="depublishedAt" value="{{ record.depublishedAt|date(format='r', timezone='GMT') }}">
|
||||
|
||||
|
||||
<!-- fields -->
|
||||
{% for field in record.fields %}
|
||||
|
||||
{% set type = field.definition.type %}
|
||||
|
||||
{% include ['bolt/editcontent/fields/' ~ type ~ '.twig', 'bolt/editcontent/fields/generic.twig' ] with { 'field': field} %}
|
||||
|
||||
{% endfor %}
|
||||
|
||||
<input type="submit" class="ui button primary" value="Save">
|
||||
|
||||
</form>
|
||||
{% endblock %}
|
||||
@@ -0,0 +1,6 @@
|
||||
<div class="field">
|
||||
<label>{{ field.definition.label|default(field.name) }}</label>
|
||||
<input name="field[{{ field.name }}]" placeholder="First Name" type="text" value="{{ field }}"
|
||||
{% if field.definition.class %}class="{{ field.definition.class }}"{% endif %}>
|
||||
</div>
|
||||
{#{{ dump(field) }}#}
|
||||
@@ -0,0 +1,6 @@
|
||||
<div class="field">
|
||||
<label>{{ field.definition.label|default(field.name) }}</label>
|
||||
<textarea name="field[{{ field.name }}]" {% if field.definition.class %}class="{{ field.definition.class }}"{% endif %}>
|
||||
{{ field }}
|
||||
</textarea>
|
||||
</div>
|
||||
@@ -0,0 +1,5 @@
|
||||
<div class="field">
|
||||
<label>{{ field.definition.label|default(field.name) }}</label>
|
||||
<input name="field[{{ field.name }}]" placeholder="First Name" type="text" value="{{ field }}"
|
||||
{% if field.definition.class %}class="{{ field.definition.class }}"{% endif %}>
|
||||
</div>
|
||||
@@ -0,0 +1,6 @@
|
||||
<div class="field">
|
||||
<label>{{ field.definition.label|default(field.name) }}</label>
|
||||
<textarea name="field[{{ field.name }}]" {% if field.definition.class %}class="{{ field.definition.class }}"{% endif %}>
|
||||
{{ field }}
|
||||
</textarea>
|
||||
</div>
|
||||
Reference in New Issue
Block a user