diff options
author | Nicolas LÅ“uillet <nicolas@loeuillet.org> | 2015-08-12 08:22:30 +0200 |
---|---|---|
committer | Nicolas LÅ“uillet <nicolas.loeuillet@smile.fr> | 2015-08-12 09:52:36 +0200 |
commit | 053b9568b2e3d032720d405bc1c2b71eccb36714 (patch) | |
tree | 1bd4241ce05c42d924f0baf34a3d1872ef6a7a4f /src/Wallabag/CoreBundle/Resources/views/themes/material/Entry | |
parent | fedaf005377e6d62ff0986f7f54afef3287a6451 (diff) | |
download | wallabag-053b9568b2e3d032720d405bc1c2b71eccb36714.tar.gz wallabag-053b9568b2e3d032720d405bc1c2b71eccb36714.tar.zst wallabag-053b9568b2e3d032720d405bc1c2b71eccb36714.zip |
add new post form in material header
Diffstat (limited to 'src/Wallabag/CoreBundle/Resources/views/themes/material/Entry')
-rw-r--r-- | src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/new.html.twig | 35 | ||||
-rw-r--r-- | src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/new_form.html.twig | 14 |
2 files changed, 15 insertions, 34 deletions
diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/new.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/new.html.twig index cac9a96b..95ed0785 100644 --- a/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/new.html.twig +++ b/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/new.html.twig | |||
@@ -3,38 +3,5 @@ | |||
3 | {% block title %}{% trans %}Save new entry{% endtrans %}{% endblock %} | 3 | {% block title %}{% trans %}Save new entry{% endtrans %}{% endblock %} |
4 | 4 | ||
5 | {% block content %} | 5 | {% block content %} |
6 | <div class="row"> | 6 | {{ render(controller( "WallabagCoreBundle:Entry:addEntryForm" )) }} |
7 | <div class="col s12"> | ||
8 | <div class="card-panel"> | ||
9 | |||
10 | <form name="entry" method="post" action=""> | ||
11 | <div class="card-content"> | ||
12 | |||
13 | {% if form_errors(form) %} | ||
14 | <span class="black-text">{{ form_errors(form) }}</span> | ||
15 | {% endif %} | ||
16 | |||
17 | {% if form_errors(form.url) %} | ||
18 | <span class="black-text">{{ form_errors(form.url) }}</span> | ||
19 | {% endif %} | ||
20 | |||
21 | <div class="input-field s12"> | ||
22 | {{ form_label(form.url) }} | ||
23 | {{ form_widget(form.url) }} | ||
24 | </div> | ||
25 | |||
26 | <button class="btn waves-effect waves-light" type="submit" name="entry[save]"> | ||
27 | {% trans %}Save{% endtrans %} | ||
28 | <i class="mdi-content-send right"></i> | ||
29 | </button> | ||
30 | </div> | ||
31 | <div class="hidden">{{ form_rest(form) }}</div> | ||
32 | </form> | ||
33 | |||
34 | |||
35 | {{ form(form) }} | ||
36 | |||
37 | </div> | ||
38 | </div> | ||
39 | </div> | ||
40 | {% endblock %} | 7 | {% endblock %} |
diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/new_form.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/new_form.html.twig new file mode 100644 index 00000000..1a3ab86d --- /dev/null +++ b/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/new_form.html.twig | |||
@@ -0,0 +1,14 @@ | |||
1 | <form name="entry" method="post" action="{{ path('new_entry')}}"> | ||
2 | |||
3 | {% if form_errors(form) %} | ||
4 | <span class="black-text">{{ form_errors(form) }}</span> | ||
5 | {% endif %} | ||
6 | |||
7 | {% if form_errors(form.url) %} | ||
8 | <span class="black-text">{{ form_errors(form.url) }}</span> | ||
9 | {% endif %} | ||
10 | |||
11 | {{ form_widget(form.url) }} | ||
12 | |||
13 | <div class="hidden">{{ form_rest(form) }}</div> | ||
14 | </form> | ||