From: Nicolas LÅ“uillet Date: Thu, 29 Dec 2016 09:54:07 +0000 (+0100) Subject: Merge pull request #2702 from wallabag/add-index-uuid X-Git-Tag: 2.2.0~3^2~16 X-Git-Url: https://git.immae.eu/?a=commitdiff_plain;h=8527238846b0ea307ba68ca8a831eb0884c68d4a;hp=7239082a5e290dada1d393f7a25acebb09ace2de;p=github%2Fwallabag%2Fwallabag.git Merge pull request #2702 from wallabag/add-index-uuid Added index on entry.uuid --- diff --git a/src/Wallabag/CoreBundle/Controller/TagController.php b/src/Wallabag/CoreBundle/Controller/TagController.php index 52707cb8..8a093289 100644 --- a/src/Wallabag/CoreBundle/Controller/TagController.php +++ b/src/Wallabag/CoreBundle/Controller/TagController.php @@ -143,7 +143,7 @@ class TagController extends Controller 'form' => null, 'entries' => $entries, 'currentPage' => $page, - 'tag' => $tag->getLabel(), + 'tag' => $tag->getSlug(), ]); } } diff --git a/src/Wallabag/CoreBundle/DataFixtures/ORM/LoadTagData.php b/src/Wallabag/CoreBundle/DataFixtures/ORM/LoadTagData.php index 09e99f36..6de561e0 100644 --- a/src/Wallabag/CoreBundle/DataFixtures/ORM/LoadTagData.php +++ b/src/Wallabag/CoreBundle/DataFixtures/ORM/LoadTagData.php @@ -15,7 +15,7 @@ class LoadTagData extends AbstractFixture implements OrderedFixtureInterface public function load(ObjectManager $manager) { $tag1 = new Tag(); - $tag1->setLabel('foo'); + $tag1->setLabel('foo bar'); $manager->persist($tag1); diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/_card_actions.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/_card_actions.html.twig index 56442116..d278da1b 100644 --- a/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/_card_actions.html.twig +++ b/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/_card_actions.html.twig @@ -1,8 +1,6 @@
- timer - {{ entry.readingTime / app.user.config.readingSpeed|round }} min  - + {% include "@WallabagCore/themes/material/Entry/_reading_time.html.twig" with {'entry': entry} only %} today  {{ entry.createdAt|date('Y-m-d') }} diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/_reading_time.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/_reading_time.html.twig new file mode 100644 index 00000000..1a932a9f --- /dev/null +++ b/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/_reading_time.html.twig @@ -0,0 +1,7 @@ +{% set readingTime = entry.readingTime / app.user.config.readingSpeed %} +timer +{% if readingTime > 0 %} + {{ 'entry.list.reading_time_minutes_short'|trans({'%readingTime%': readingTime|round}) }} +{% else %} + {{ 'entry.list.reading_time_less_one_minute_short'|trans|raw }} +{% endif %} diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entry.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entry.html.twig index 0cbf1999..46f89e19 100644 --- a/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entry.html.twig +++ b/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entry.html.twig @@ -214,13 +214,7 @@