diff options
author | Nicolas Lœuillet <nicolas@loeuillet.org> | 2020-04-20 19:00:58 +0200 |
---|---|---|
committer | Nicolas Lœuillet <nicolas@loeuillet.org> | 2020-04-20 19:00:58 +0200 |
commit | 4b997bc8b27fc25efd1f7a0797b78ee666ef9688 (patch) | |
tree | c75d7900ee1c30a7ee323efbf760d6389916b1b9 | |
parent | 7443da479f5289c2ceebb96c0cd4273f6445ca37 (diff) | |
download | wallabag-4b997bc8b27fc25efd1f7a0797b78ee666ef9688.tar.gz wallabag-4b997bc8b27fc25efd1f7a0797b78ee666ef9688.tar.zst wallabag-4b997bc8b27fc25efd1f7a0797b78ee666ef9688.zip |
Added route to list entries with annotations
23 files changed, 89 insertions, 4 deletions
diff --git a/app/config/security.yml b/app/config/security.yml index 760b2550..894bb83f 100644 --- a/app/config/security.yml +++ b/app/config/security.yml | |||
@@ -69,11 +69,11 @@ security: | |||
69 | - { path: ^/logout, roles: [IS_AUTHENTICATED_ANONYMOUSLY, IS_AUTHENTICATED_2FA_IN_PROGRESS] } | 69 | - { path: ^/logout, roles: [IS_AUTHENTICATED_ANONYMOUSLY, IS_AUTHENTICATED_2FA_IN_PROGRESS] } |
70 | - { path: ^/register, role: IS_AUTHENTICATED_ANONYMOUSLY } | 70 | - { path: ^/register, role: IS_AUTHENTICATED_ANONYMOUSLY } |
71 | - { path: ^/resetting, role: IS_AUTHENTICATED_ANONYMOUSLY } | 71 | - { path: ^/resetting, role: IS_AUTHENTICATED_ANONYMOUSLY } |
72 | - { path: /(unread|starred|archive|all).xml$, roles: IS_AUTHENTICATED_ANONYMOUSLY } | 72 | - { path: /(unread|starred|archive|with_annotations|all).xml$, roles: IS_AUTHENTICATED_ANONYMOUSLY } |
73 | - { path: ^/locale, role: IS_AUTHENTICATED_ANONYMOUSLY } | 73 | - { path: ^/locale, role: IS_AUTHENTICATED_ANONYMOUSLY } |
74 | - { path: /tags/(.*).xml$, roles: IS_AUTHENTICATED_ANONYMOUSLY } | 74 | - { path: /tags/(.*).xml$, roles: IS_AUTHENTICATED_ANONYMOUSLY } |
75 | - { path: ^/feed, roles: IS_AUTHENTICATED_ANONYMOUSLY } | 75 | - { path: ^/feed, roles: IS_AUTHENTICATED_ANONYMOUSLY } |
76 | - { path: /(unread|starred|archive).xml$, roles: IS_AUTHENTICATED_ANONYMOUSLY } # For backwards compatibility | 76 | - { path: /(unread|starred|archive|with_annotations).xml$, roles: IS_AUTHENTICATED_ANONYMOUSLY } # For backwards compatibility |
77 | - { path: ^/share, roles: IS_AUTHENTICATED_ANONYMOUSLY } | 77 | - { path: ^/share, roles: IS_AUTHENTICATED_ANONYMOUSLY } |
78 | - { path: ^/settings, roles: ROLE_SUPER_ADMIN } | 78 | - { path: ^/settings, roles: ROLE_SUPER_ADMIN } |
79 | - { path: ^/annotations, roles: ROLE_USER } | 79 | - { path: ^/annotations, roles: ROLE_USER } |
diff --git a/src/Wallabag/CoreBundle/Controller/EntryController.php b/src/Wallabag/CoreBundle/Controller/EntryController.php index ba5bfbe2..2c4b5536 100644 --- a/src/Wallabag/CoreBundle/Controller/EntryController.php +++ b/src/Wallabag/CoreBundle/Controller/EntryController.php | |||
@@ -236,11 +236,25 @@ class EntryController extends Controller | |||
236 | } | 236 | } |
237 | 237 | ||
238 | /** | 238 | /** |
239 | * Shows entries with annotations for current user. | ||
240 | * | ||
241 | * @param int $page | ||
242 | * | ||
243 | * @Route("/with_annotations/list/{page}", name="with_annotations", defaults={"page" = "1"}) | ||
244 | * | ||
245 | * @return \Symfony\Component\HttpFoundation\Response | ||
246 | */ | ||
247 | public function showWithAnnotationsEntriesAction(Request $request, $page) | ||
248 | { | ||
249 | return $this->showEntries('with_annotations', $request, $page); | ||
250 | } | ||
251 | |||
252 | /** | ||
239 | * Shows random entry depending on the given type. | 253 | * Shows random entry depending on the given type. |
240 | * | 254 | * |
241 | * @param string $type | 255 | * @param string $type |
242 | * | 256 | * |
243 | * @Route("/{type}/random", name="random_entry", requirements={"type": "unread|starred|archive|untagged|all"}) | 257 | * @Route("/{type}/random", name="random_entry", requirements={"type": "unread|starred|archive|untagged|with_annotations|all"}) |
244 | * | 258 | * |
245 | * @return \Symfony\Component\HttpFoundation\RedirectResponse | 259 | * @return \Symfony\Component\HttpFoundation\RedirectResponse |
246 | */ | 260 | */ |
@@ -503,6 +517,9 @@ class EntryController extends Controller | |||
503 | case 'archive': | 517 | case 'archive': |
504 | $qb = $repository->getBuilderForArchiveByUser($this->getUser()->getId()); | 518 | $qb = $repository->getBuilderForArchiveByUser($this->getUser()->getId()); |
505 | break; | 519 | break; |
520 | case 'with_annotations': | ||
521 | $qb = $repository->getBuilderForAnnotationsByUser($this->getUser()->getId()); | ||
522 | break; | ||
506 | case 'unread': | 523 | case 'unread': |
507 | $qb = $repository->getBuilderForUnreadByUser($this->getUser()->getId()); | 524 | $qb = $repository->getBuilderForUnreadByUser($this->getUser()->getId()); |
508 | break; | 525 | break; |
diff --git a/src/Wallabag/CoreBundle/Controller/ExportController.php b/src/Wallabag/CoreBundle/Controller/ExportController.php index cec8d499..8517e7a9 100644 --- a/src/Wallabag/CoreBundle/Controller/ExportController.php +++ b/src/Wallabag/CoreBundle/Controller/ExportController.php | |||
@@ -47,7 +47,7 @@ class ExportController extends Controller | |||
47 | * | 47 | * |
48 | * @Route("/export/{category}.{format}", name="export_entries", requirements={ | 48 | * @Route("/export/{category}.{format}", name="export_entries", requirements={ |
49 | * "format": "epub|mobi|pdf|json|xml|txt|csv", | 49 | * "format": "epub|mobi|pdf|json|xml|txt|csv", |
50 | * "category": "all|unread|starred|archive|tag_entries|untagged|search" | 50 | * "category": "all|unread|starred|archive|tag_entries|untagged|search|with_annotations" |
51 | * }) | 51 | * }) |
52 | * | 52 | * |
53 | * @return \Symfony\Component\HttpFoundation\Response | 53 | * @return \Symfony\Component\HttpFoundation\Response |
@@ -80,6 +80,13 @@ class ExportController extends Controller | |||
80 | ->getResult(); | 80 | ->getResult(); |
81 | 81 | ||
82 | $title = 'Search ' . $searchTerm; | 82 | $title = 'Search ' . $searchTerm; |
83 | } elseif ('with_annotations' === $category) { | ||
84 | $entries = $repository->getBuilderForAnnotationsByUser( | ||
85 | $this->getUser()->getId() | ||
86 | )->getQuery() | ||
87 | ->getResult(); | ||
88 | |||
89 | $title = 'With annotations'; | ||
83 | } else { | 90 | } else { |
84 | $entries = $repository | 91 | $entries = $repository |
85 | ->$methodBuilder($this->getUser()->getId()) | 92 | ->$methodBuilder($this->getUser()->getId()) |
diff --git a/src/Wallabag/CoreBundle/Repository/EntryRepository.php b/src/Wallabag/CoreBundle/Repository/EntryRepository.php index bfd07937..9f25ad4c 100644 --- a/src/Wallabag/CoreBundle/Repository/EntryRepository.php +++ b/src/Wallabag/CoreBundle/Repository/EntryRepository.php | |||
@@ -116,6 +116,21 @@ class EntryRepository extends EntityRepository | |||
116 | } | 116 | } |
117 | 117 | ||
118 | /** | 118 | /** |
119 | * Retrieve entries with annotations for a user. | ||
120 | * | ||
121 | * @param int $userId | ||
122 | * | ||
123 | * @return QueryBuilder | ||
124 | */ | ||
125 | public function getBuilderForAnnotationsByUser($userId) | ||
126 | { | ||
127 | return $this | ||
128 | ->getSortedQueryBuilderByUser($userId) | ||
129 | ->innerJoin('e.annotations', 'a') | ||
130 | ; | ||
131 | } | ||
132 | |||
133 | /** | ||
119 | * Retrieve untagged entries for a user. | 134 | * Retrieve untagged entries for a user. |
120 | * | 135 | * |
121 | * @param int $userId | 136 | * @param int $userId |
@@ -520,6 +535,10 @@ class EntryRepository extends EntityRepository | |||
520 | $qb->leftJoin('e.tags', 't'); | 535 | $qb->leftJoin('e.tags', 't'); |
521 | $qb->andWhere('t.id is null'); | 536 | $qb->andWhere('t.id is null'); |
522 | break; | 537 | break; |
538 | case 'with_annotations': | ||
539 | $qb->leftJoin('e.annotations', 'a'); | ||
540 | $qb->andWhere('a.id is not null'); | ||
541 | break; | ||
523 | } | 542 | } |
524 | 543 | ||
525 | $ids = $qb->getQuery()->getArrayResult(); | 544 | $ids = $qb->getQuery()->getArrayResult(); |
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.da.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.da.yml index 4d525979..b233789f 100644 --- a/src/Wallabag/CoreBundle/Resources/translations/messages.da.yml +++ b/src/Wallabag/CoreBundle/Resources/translations/messages.da.yml | |||
@@ -20,6 +20,7 @@ menu: | |||
20 | starred: 'Favoritter' | 20 | starred: 'Favoritter' |
21 | archive: 'Arkiv' | 21 | archive: 'Arkiv' |
22 | all_articles: 'Alle artikler' | 22 | all_articles: 'Alle artikler' |
23 | # with_annotations: 'With annotations' | ||
23 | config: 'Opsætning' | 24 | config: 'Opsætning' |
24 | tags: 'Tags' | 25 | tags: 'Tags' |
25 | # internal_settings: 'Internal Settings' | 26 | # internal_settings: 'Internal Settings' |
@@ -194,6 +195,7 @@ entry: | |||
194 | # starred: 'Starred entries' | 195 | # starred: 'Starred entries' |
195 | # archived: 'Archived entries' | 196 | # archived: 'Archived entries' |
196 | # filtered: 'Filtered entries' | 197 | # filtered: 'Filtered entries' |
198 | # with_annotations: 'Entries with annotations' | ||
197 | # filtered_tags: 'Filtered by tags:' | 199 | # filtered_tags: 'Filtered by tags:' |
198 | # filtered_search: 'Filtered by search:' | 200 | # filtered_search: 'Filtered by search:' |
199 | # untagged: 'Untagged entries' | 201 | # untagged: 'Untagged entries' |
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.de.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.de.yml index cd70c99f..d955c046 100644 --- a/src/Wallabag/CoreBundle/Resources/translations/messages.de.yml +++ b/src/Wallabag/CoreBundle/Resources/translations/messages.de.yml | |||
@@ -20,6 +20,7 @@ menu: | |||
20 | starred: 'Favoriten' | 20 | starred: 'Favoriten' |
21 | archive: 'Archiv' | 21 | archive: 'Archiv' |
22 | all_articles: 'Alle Artikel' | 22 | all_articles: 'Alle Artikel' |
23 | # with_annotations: 'With annotations' | ||
23 | config: 'Konfiguration' | 24 | config: 'Konfiguration' |
24 | tags: 'Tags' | 25 | tags: 'Tags' |
25 | internal_settings: 'Interne Einstellungen' | 26 | internal_settings: 'Interne Einstellungen' |
@@ -194,6 +195,7 @@ entry: | |||
194 | starred: 'Favorisierte Einträge' | 195 | starred: 'Favorisierte Einträge' |
195 | archived: 'Archivierte Einträge' | 196 | archived: 'Archivierte Einträge' |
196 | filtered: 'Gefilterte Einträge' | 197 | filtered: 'Gefilterte Einträge' |
198 | # with_annotations: 'Entries with annotations' | ||
197 | filtered_tags: 'Gefiltert nach Tags:' | 199 | filtered_tags: 'Gefiltert nach Tags:' |
198 | filtered_search: 'Gefiltert nach Suche:' | 200 | filtered_search: 'Gefiltert nach Suche:' |
199 | untagged: 'Nicht getaggte Einträge' | 201 | untagged: 'Nicht getaggte Einträge' |
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.en.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.en.yml index 1bc32423..6e7f5693 100644 --- a/src/Wallabag/CoreBundle/Resources/translations/messages.en.yml +++ b/src/Wallabag/CoreBundle/Resources/translations/messages.en.yml | |||
@@ -20,6 +20,7 @@ menu: | |||
20 | starred: 'Starred' | 20 | starred: 'Starred' |
21 | archive: 'Archive' | 21 | archive: 'Archive' |
22 | all_articles: 'All entries' | 22 | all_articles: 'All entries' |
23 | with_annotations: 'With annotations' | ||
23 | config: 'Config' | 24 | config: 'Config' |
24 | tags: 'Tags' | 25 | tags: 'Tags' |
25 | internal_settings: 'Internal Settings' | 26 | internal_settings: 'Internal Settings' |
@@ -194,6 +195,7 @@ entry: | |||
194 | starred: 'Starred entries' | 195 | starred: 'Starred entries' |
195 | archived: 'Archived entries' | 196 | archived: 'Archived entries' |
196 | filtered: 'Filtered entries' | 197 | filtered: 'Filtered entries' |
198 | with_annotations: 'Entries with annotations' | ||
197 | filtered_tags: 'Filtered by tags:' | 199 | filtered_tags: 'Filtered by tags:' |
198 | filtered_search: 'Filtered by search:' | 200 | filtered_search: 'Filtered by search:' |
199 | untagged: 'Untagged entries' | 201 | untagged: 'Untagged entries' |
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.es.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.es.yml index bced72e9..2164a618 100644 --- a/src/Wallabag/CoreBundle/Resources/translations/messages.es.yml +++ b/src/Wallabag/CoreBundle/Resources/translations/messages.es.yml | |||
@@ -20,6 +20,7 @@ menu: | |||
20 | starred: 'Favoritos' | 20 | starred: 'Favoritos' |
21 | archive: 'Archivo' | 21 | archive: 'Archivo' |
22 | all_articles: 'Todos los artículos' | 22 | all_articles: 'Todos los artículos' |
23 | # with_annotations: 'With annotations' | ||
23 | config: 'Configuración' | 24 | config: 'Configuración' |
24 | tags: 'Etiquetas' | 25 | tags: 'Etiquetas' |
25 | internal_settings: 'Configuración interna' | 26 | internal_settings: 'Configuración interna' |
@@ -194,6 +195,7 @@ entry: | |||
194 | starred: 'Artículos favoritos' | 195 | starred: 'Artículos favoritos' |
195 | archived: 'Artículos archivados' | 196 | archived: 'Artículos archivados' |
196 | filtered: 'Artículos filtrados' | 197 | filtered: 'Artículos filtrados' |
198 | # with_annotations: 'Entries with annotations' | ||
197 | filtered_tags: 'Filtrado por etiquetas:' | 199 | filtered_tags: 'Filtrado por etiquetas:' |
198 | filtered_search: 'Filtrado por búsqueda:' | 200 | filtered_search: 'Filtrado por búsqueda:' |
199 | untagged: 'Artículos sin etiquetas' | 201 | untagged: 'Artículos sin etiquetas' |
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.fa.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.fa.yml index 0704204a..be14f53d 100644 --- a/src/Wallabag/CoreBundle/Resources/translations/messages.fa.yml +++ b/src/Wallabag/CoreBundle/Resources/translations/messages.fa.yml | |||
@@ -20,6 +20,7 @@ menu: | |||
20 | starred: 'برگزیده' | 20 | starred: 'برگزیده' |
21 | archive: 'بایگانی' | 21 | archive: 'بایگانی' |
22 | all_articles: 'همه' | 22 | all_articles: 'همه' |
23 | # with_annotations: 'With annotations' | ||
23 | config: 'پیکربندی' | 24 | config: 'پیکربندی' |
24 | tags: 'برچسبها' | 25 | tags: 'برچسبها' |
25 | internal_settings: 'تنظیمات درونی' | 26 | internal_settings: 'تنظیمات درونی' |
@@ -194,6 +195,7 @@ entry: | |||
194 | starred: 'مقالههای برگزیده' | 195 | starred: 'مقالههای برگزیده' |
195 | archived: 'مقالههای بایگانیشده' | 196 | archived: 'مقالههای بایگانیشده' |
196 | filtered: 'مقالههای فیلترشده' | 197 | filtered: 'مقالههای فیلترشده' |
198 | # with_annotations: 'Entries with annotations' | ||
197 | # filtered_tags: 'Filtered by tags:' | 199 | # filtered_tags: 'Filtered by tags:' |
198 | # filtered_search: 'Filtered by search:' | 200 | # filtered_search: 'Filtered by search:' |
199 | # untagged: 'Untagged entries' | 201 | # untagged: 'Untagged entries' |
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.fr.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.fr.yml index 5d5878eb..65a87710 100644 --- a/src/Wallabag/CoreBundle/Resources/translations/messages.fr.yml +++ b/src/Wallabag/CoreBundle/Resources/translations/messages.fr.yml | |||
@@ -20,6 +20,7 @@ menu: | |||
20 | starred: "Favoris" | 20 | starred: "Favoris" |
21 | archive: "Lus" | 21 | archive: "Lus" |
22 | all_articles: "Tous les articles" | 22 | all_articles: "Tous les articles" |
23 | with_annotations: 'Avec annotations' | ||
23 | config: "Configuration" | 24 | config: "Configuration" |
24 | tags: "Tags" | 25 | tags: "Tags" |
25 | internal_settings: "Configuration interne" | 26 | internal_settings: "Configuration interne" |
@@ -194,6 +195,7 @@ entry: | |||
194 | starred: "Articles favoris" | 195 | starred: "Articles favoris" |
195 | archived: "Articles lus" | 196 | archived: "Articles lus" |
196 | filtered: "Articles filtrés" | 197 | filtered: "Articles filtrés" |
198 | with_annotations: 'Articles avec annotations' | ||
197 | filtered_tags: "Articles filtrés par tags :" | 199 | filtered_tags: "Articles filtrés par tags :" |
198 | filtered_search: "Articles filtrés par recherche :" | 200 | filtered_search: "Articles filtrés par recherche :" |
199 | untagged: "Article sans tag" | 201 | untagged: "Article sans tag" |
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.it.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.it.yml index 23e72f20..ef1f0d9f 100644 --- a/src/Wallabag/CoreBundle/Resources/translations/messages.it.yml +++ b/src/Wallabag/CoreBundle/Resources/translations/messages.it.yml | |||
@@ -20,6 +20,7 @@ menu: | |||
20 | starred: 'Preferiti' | 20 | starred: 'Preferiti' |
21 | archive: 'Archivio' | 21 | archive: 'Archivio' |
22 | all_articles: 'Tutti' | 22 | all_articles: 'Tutti' |
23 | # with_annotations: 'With annotations' | ||
23 | config: 'Configurazione' | 24 | config: 'Configurazione' |
24 | tags: 'Etichette' | 25 | tags: 'Etichette' |
25 | internal_settings: 'Strumenti' | 26 | internal_settings: 'Strumenti' |
@@ -194,6 +195,7 @@ entry: | |||
194 | starred: 'Contenuti preferiti' | 195 | starred: 'Contenuti preferiti' |
195 | archived: 'Contenuti archiviati' | 196 | archived: 'Contenuti archiviati' |
196 | filtered: 'Contenuti filtrati' | 197 | filtered: 'Contenuti filtrati' |
198 | # with_annotations: 'Entries with annotations' | ||
197 | filtered_tags: 'Filtrati per etichetta:' | 199 | filtered_tags: 'Filtrati per etichetta:' |
198 | filtered_search: 'Filtrati per ricerca:' | 200 | filtered_search: 'Filtrati per ricerca:' |
199 | untagged: 'Articoli non etichettati' | 201 | untagged: 'Articoli non etichettati' |
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.ja.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.ja.yml index f6530a83..d1a2d055 100644 --- a/src/Wallabag/CoreBundle/Resources/translations/messages.ja.yml +++ b/src/Wallabag/CoreBundle/Resources/translations/messages.ja.yml | |||
@@ -20,6 +20,7 @@ menu: | |||
20 | starred: 'お気に入り' | 20 | starred: 'お気に入り' |
21 | archive: 'アーカイブ済み' | 21 | archive: 'アーカイブ済み' |
22 | all_articles: '全ての記事' | 22 | all_articles: '全ての記事' |
23 | # with_annotations: 'With annotations' | ||
23 | config: '設定' | 24 | config: '設定' |
24 | tags: 'タグ' | 25 | tags: 'タグ' |
25 | internal_settings: '内部設定' | 26 | internal_settings: '内部設定' |
@@ -194,6 +195,7 @@ entry: | |||
194 | starred: 'お気に入りの記事' | 195 | starred: 'お気に入りの記事' |
195 | archived: 'アーカイブ済みの記事' | 196 | archived: 'アーカイブ済みの記事' |
196 | filtered: '記事の絞り込み' | 197 | filtered: '記事の絞り込み' |
198 | # with_annotations: 'Entries with annotations' | ||
197 | filtered_tags: 'タグ検索:' | 199 | filtered_tags: 'タグ検索:' |
198 | filtered_search: '単語検索:' | 200 | filtered_search: '単語検索:' |
199 | untagged: 'タグの無い記事' | 201 | untagged: 'タグの無い記事' |
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.oc.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.oc.yml index 6ddff6ea..f4409ddd 100644 --- a/src/Wallabag/CoreBundle/Resources/translations/messages.oc.yml +++ b/src/Wallabag/CoreBundle/Resources/translations/messages.oc.yml | |||
@@ -20,6 +20,7 @@ menu: | |||
20 | starred: 'Favorits' | 20 | starred: 'Favorits' |
21 | archive: 'Legits' | 21 | archive: 'Legits' |
22 | all_articles: 'Totes los articles' | 22 | all_articles: 'Totes los articles' |
23 | # with_annotations: 'With annotations' | ||
23 | config: 'Configuracion' | 24 | config: 'Configuracion' |
24 | tags: 'Etiquetas' | 25 | tags: 'Etiquetas' |
25 | internal_settings: 'Configuracion intèrna' | 26 | internal_settings: 'Configuracion intèrna' |
@@ -194,6 +195,7 @@ entry: | |||
194 | starred: 'Articles favorits' | 195 | starred: 'Articles favorits' |
195 | archived: 'Articles legits' | 196 | archived: 'Articles legits' |
196 | filtered: 'Articles filtrats' | 197 | filtered: 'Articles filtrats' |
198 | # with_annotations: 'Entries with annotations' | ||
197 | filtered_tags: 'Articles filtrats per etiquetas :' | 199 | filtered_tags: 'Articles filtrats per etiquetas :' |
198 | filtered_search: 'Articles filtrats per recèrca :' | 200 | filtered_search: 'Articles filtrats per recèrca :' |
199 | untagged: 'Articles sens etiqueta' | 201 | untagged: 'Articles sens etiqueta' |
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.pl.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.pl.yml index 770477c9..d595796f 100644 --- a/src/Wallabag/CoreBundle/Resources/translations/messages.pl.yml +++ b/src/Wallabag/CoreBundle/Resources/translations/messages.pl.yml | |||
@@ -20,6 +20,7 @@ menu: | |||
20 | starred: 'Oznaczone gwiazdką' | 20 | starred: 'Oznaczone gwiazdką' |
21 | archive: 'Archiwum' | 21 | archive: 'Archiwum' |
22 | all_articles: 'Wszystkie' | 22 | all_articles: 'Wszystkie' |
23 | # with_annotations: 'With annotations' | ||
23 | config: 'Konfiguracja' | 24 | config: 'Konfiguracja' |
24 | tags: 'Tagi' | 25 | tags: 'Tagi' |
25 | internal_settings: 'Wewnętrzne ustawienia' | 26 | internal_settings: 'Wewnętrzne ustawienia' |
@@ -194,6 +195,7 @@ entry: | |||
194 | starred: 'Wpisy oznaczone gwiazdką' | 195 | starred: 'Wpisy oznaczone gwiazdką' |
195 | archived: 'Zarchiwizowane wpisy' | 196 | archived: 'Zarchiwizowane wpisy' |
196 | filtered: 'Odfiltrowane wpisy' | 197 | filtered: 'Odfiltrowane wpisy' |
198 | # with_annotations: 'Entries with annotations' | ||
197 | filtered_tags: 'Filtrowane po tagach:' | 199 | filtered_tags: 'Filtrowane po tagach:' |
198 | filtered_search: 'Filtrowanie po wyszukiwaniu:' | 200 | filtered_search: 'Filtrowanie po wyszukiwaniu:' |
199 | untagged: 'Odtaguj wpisy' | 201 | untagged: 'Odtaguj wpisy' |
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.pt.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.pt.yml index d993cb05..dcd0b89b 100644 --- a/src/Wallabag/CoreBundle/Resources/translations/messages.pt.yml +++ b/src/Wallabag/CoreBundle/Resources/translations/messages.pt.yml | |||
@@ -20,6 +20,7 @@ menu: | |||
20 | starred: 'Destacado' | 20 | starred: 'Destacado' |
21 | archive: 'Arquivo' | 21 | archive: 'Arquivo' |
22 | all_articles: 'Todos os artigos' | 22 | all_articles: 'Todos os artigos' |
23 | # with_annotations: 'With annotations' | ||
23 | config: 'Configurações' | 24 | config: 'Configurações' |
24 | tags: 'Tags' | 25 | tags: 'Tags' |
25 | internal_settings: 'Configurações Internas' | 26 | internal_settings: 'Configurações Internas' |
@@ -194,6 +195,7 @@ entry: | |||
194 | starred: 'Artigos destacados' | 195 | starred: 'Artigos destacados' |
195 | archived: 'Artigos arquivados' | 196 | archived: 'Artigos arquivados' |
196 | filtered: 'Artigos filtrados' | 197 | filtered: 'Artigos filtrados' |
198 | # with_annotations: 'Entries with annotations' | ||
197 | filtered_tags: 'Filtrar por tags:' | 199 | filtered_tags: 'Filtrar por tags:' |
198 | filtered_search: 'Filtrar por busca:' | 200 | filtered_search: 'Filtrar por busca:' |
199 | untagged: 'Entradas sem tags' | 201 | untagged: 'Entradas sem tags' |
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.ro.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.ro.yml index bc8b72e0..d699a749 100644 --- a/src/Wallabag/CoreBundle/Resources/translations/messages.ro.yml +++ b/src/Wallabag/CoreBundle/Resources/translations/messages.ro.yml | |||
@@ -20,6 +20,7 @@ menu: | |||
20 | starred: 'Cu steluță' | 20 | starred: 'Cu steluță' |
21 | archive: 'Arhivă' | 21 | archive: 'Arhivă' |
22 | all_articles: 'Toate' | 22 | all_articles: 'Toate' |
23 | # with_annotations: 'With annotations' | ||
23 | config: 'Configurație' | 24 | config: 'Configurație' |
24 | tags: 'Tag-uri' | 25 | tags: 'Tag-uri' |
25 | # internal_settings: 'Internal Settings' | 26 | # internal_settings: 'Internal Settings' |
@@ -194,6 +195,7 @@ entry: | |||
194 | # starred: 'Starred entries' | 195 | # starred: 'Starred entries' |
195 | # archived: 'Archived entries' | 196 | # archived: 'Archived entries' |
196 | # filtered: 'Filtered entries' | 197 | # filtered: 'Filtered entries' |
198 | # with_annotations: 'Entries with annotations' | ||
197 | # filtered_tags: 'Filtered by tags:' | 199 | # filtered_tags: 'Filtered by tags:' |
198 | # filtered_search: 'Filtered by search:' | 200 | # filtered_search: 'Filtered by search:' |
199 | # untagged: 'Untagged entries' | 201 | # untagged: 'Untagged entries' |
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.ru.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.ru.yml index 2f7f55e5..13a257ef 100644 --- a/src/Wallabag/CoreBundle/Resources/translations/messages.ru.yml +++ b/src/Wallabag/CoreBundle/Resources/translations/messages.ru.yml | |||
@@ -20,6 +20,7 @@ menu: | |||
20 | starred: 'Помеченные' | 20 | starred: 'Помеченные' |
21 | archive: 'Архивные' | 21 | archive: 'Архивные' |
22 | all_articles: 'Все записи' | 22 | all_articles: 'Все записи' |
23 | # with_annotations: 'With annotations' | ||
23 | config: 'Настройки' | 24 | config: 'Настройки' |
24 | tags: 'Теги' | 25 | tags: 'Теги' |
25 | internal_settings: 'Внутренние настройки' | 26 | internal_settings: 'Внутренние настройки' |
@@ -194,6 +195,7 @@ entry: | |||
194 | starred: 'Помеченные записи' | 195 | starred: 'Помеченные записи' |
195 | archived: 'Архивные записи' | 196 | archived: 'Архивные записи' |
196 | filtered: 'Отфильтрованные записи' | 197 | filtered: 'Отфильтрованные записи' |
198 | # with_annotations: 'Entries with annotations' | ||
197 | filtered_tags: 'Отфильтрованные по тегу:' | 199 | filtered_tags: 'Отфильтрованные по тегу:' |
198 | filtered_search: 'Отфильтрованные по поиску:' | 200 | filtered_search: 'Отфильтрованные по поиску:' |
199 | untagged: 'Записи без тегов' | 201 | untagged: 'Записи без тегов' |
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.th.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.th.yml index 48e1c34a..495f9337 100644 --- a/src/Wallabag/CoreBundle/Resources/translations/messages.th.yml +++ b/src/Wallabag/CoreBundle/Resources/translations/messages.th.yml | |||
@@ -20,6 +20,7 @@ menu: | |||
20 | starred: 'ทำการแสดง' | 20 | starred: 'ทำการแสดง' |
21 | archive: 'เอกสาร' | 21 | archive: 'เอกสาร' |
22 | all_articles: 'รายการทั้งหมด' | 22 | all_articles: 'รายการทั้งหมด' |
23 | # with_annotations: 'With annotations' | ||
23 | config: 'กำหนดค่า' | 24 | config: 'กำหนดค่า' |
24 | tags: 'แท็ก' | 25 | tags: 'แท็ก' |
25 | internal_settings: 'ตั้งค่าภายใน' | 26 | internal_settings: 'ตั้งค่าภายใน' |
@@ -194,6 +195,7 @@ entry: | |||
194 | starred: 'รายการที่แสดง' | 195 | starred: 'รายการที่แสดง' |
195 | archived: 'รายการเอกสาร' | 196 | archived: 'รายการเอกสาร' |
196 | filtered: 'รายการที่กลั่นกรอง' | 197 | filtered: 'รายการที่กลั่นกรอง' |
198 | # with_annotations: 'Entries with annotations' | ||
197 | filtered_tags: 'แท็กทีกลั่นกรอง่:' | 199 | filtered_tags: 'แท็กทีกลั่นกรอง่:' |
198 | filtered_search: 'การค้นหาที่กลั่นกรอง:' | 200 | filtered_search: 'การค้นหาที่กลั่นกรอง:' |
199 | untagged: 'รายการที่ไม่ได้แท็ก' | 201 | untagged: 'รายการที่ไม่ได้แท็ก' |
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.tr.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.tr.yml index 19029c0b..163dc1d1 100644 --- a/src/Wallabag/CoreBundle/Resources/translations/messages.tr.yml +++ b/src/Wallabag/CoreBundle/Resources/translations/messages.tr.yml | |||
@@ -20,6 +20,7 @@ menu: | |||
20 | starred: 'Favoriler' | 20 | starred: 'Favoriler' |
21 | archive: 'Arşiv' | 21 | archive: 'Arşiv' |
22 | all_articles: 'Hepsi' | 22 | all_articles: 'Hepsi' |
23 | # with_annotations: 'With annotations' | ||
23 | config: 'Yapılandırma' | 24 | config: 'Yapılandırma' |
24 | tags: 'Etiketler' | 25 | tags: 'Etiketler' |
25 | # internal_settings: 'Internal Settings' | 26 | # internal_settings: 'Internal Settings' |
@@ -194,6 +195,7 @@ entry: | |||
194 | # starred: 'Starred entries' | 195 | # starred: 'Starred entries' |
195 | # archived: 'Archived entries' | 196 | # archived: 'Archived entries' |
196 | # filtered: 'Filtered entries' | 197 | # filtered: 'Filtered entries' |
198 | # with_annotations: 'Entries with annotations' | ||
197 | # filtered_tags: 'Filtered by tags:' | 199 | # filtered_tags: 'Filtered by tags:' |
198 | # filtered_search: 'Filtered by search:' | 200 | # filtered_search: 'Filtered by search:' |
199 | # untagged: 'Untagged entries' | 201 | # untagged: 'Untagged entries' |
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.zh.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.zh.yml index f48ce37a..115701da 100644 --- a/src/Wallabag/CoreBundle/Resources/translations/messages.zh.yml +++ b/src/Wallabag/CoreBundle/Resources/translations/messages.zh.yml | |||
@@ -20,6 +20,7 @@ menu: | |||
20 | starred: '星标' | 20 | starred: '星标' |
21 | archive: '存档' | 21 | archive: '存档' |
22 | all_articles: '所有项目' | 22 | all_articles: '所有项目' |
23 | # with_annotations: 'With annotations' | ||
23 | config: '配置' | 24 | config: '配置' |
24 | tags: '标签' | 25 | tags: '标签' |
25 | internal_settings: '内部设置' | 26 | internal_settings: '内部设置' |
@@ -194,6 +195,7 @@ entry: | |||
194 | starred: '星标项目' | 195 | starred: '星标项目' |
195 | archived: '存档项目' | 196 | archived: '存档项目' |
196 | filtered: '筛选后项目' | 197 | filtered: '筛选后项目' |
198 | # with_annotations: 'Entries with annotations' | ||
197 | filtered_tags: '根据标签筛选:' | 199 | filtered_tags: '根据标签筛选:' |
198 | filtered_search: '根据搜索筛选:' | 200 | filtered_search: '根据搜索筛选:' |
199 | untagged: '无标签项目' | 201 | untagged: '无标签项目' |
diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/common/Entry/_title.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/common/Entry/_title.html.twig index 5c17e9f7..d93e5a67 100644 --- a/src/Wallabag/CoreBundle/Resources/views/themes/common/Entry/_title.html.twig +++ b/src/Wallabag/CoreBundle/Resources/views/themes/common/Entry/_title.html.twig | |||
@@ -12,6 +12,8 @@ | |||
12 | {{ 'entry.page_titles.filtered_tags'|trans }} {{ filter }} | 12 | {{ 'entry.page_titles.filtered_tags'|trans }} {{ filter }} |
13 | {% elseif currentRoute == 'untagged' %} | 13 | {% elseif currentRoute == 'untagged' %} |
14 | {{ 'entry.page_titles.untagged'|trans }} | 14 | {{ 'entry.page_titles.untagged'|trans }} |
15 | {% elseif currentRoute == 'with_annotations' %} | ||
16 | {{ 'entry.page_titles.with_annotations'|trans }} | ||
15 | {% else %} | 17 | {% else %} |
16 | {{ 'entry.page_titles.unread'|trans }} | 18 | {{ 'entry.page_titles.unread'|trans }} |
17 | {% endif %} | 19 | {% endif %} |
diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/material/layout.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/material/layout.html.twig index c51d07fc..6c4ae40b 100644 --- a/src/Wallabag/CoreBundle/Resources/views/themes/material/layout.html.twig +++ b/src/Wallabag/CoreBundle/Resources/views/themes/material/layout.html.twig | |||
@@ -40,6 +40,8 @@ | |||
40 | {% set activeRoute = null %} | 40 | {% set activeRoute = null %} |
41 | {% if currentRoute == 'all' or currentRouteFromQueryParams == 'all' %} | 41 | {% if currentRoute == 'all' or currentRouteFromQueryParams == 'all' %} |
42 | {% set activeRoute = 'all' %} | 42 | {% set activeRoute = 'all' %} |
43 | {% elseif currentRoute == 'with_annotations' or currentRouteFromQueryParams == 'with_annotations' %} | ||
44 | {% set activeRoute = 'with_annotations' %} | ||
43 | {% elseif currentRoute == 'archive' or currentRouteFromQueryParams == 'archive' %} | 45 | {% elseif currentRoute == 'archive' or currentRouteFromQueryParams == 'archive' %} |
44 | {% set activeRoute = 'archive' %} | 46 | {% set activeRoute = 'archive' %} |
45 | {% elseif currentRoute == 'starred' or currentRouteFromQueryParams == 'starred' %} | 47 | {% elseif currentRoute == 'starred' or currentRouteFromQueryParams == 'starred' %} |
@@ -59,6 +61,9 @@ | |||
59 | <li class="bold {% if activeRoute == 'archive' %}active{% endif %}"> | 61 | <li class="bold {% if activeRoute == 'archive' %}active{% endif %}"> |
60 | <a class="waves-effect" href="{{ path('archive') }}">{{ 'menu.left.archive'|trans }} <span class="numberItems grey-text">{{ count_entries('archive') }}</span></a> | 62 | <a class="waves-effect" href="{{ path('archive') }}">{{ 'menu.left.archive'|trans }} <span class="numberItems grey-text">{{ count_entries('archive') }}</span></a> |
61 | </li> | 63 | </li> |
64 | <li class="bold {% if activeRoute == 'with_annotations' %}active{% endif %}"> | ||
65 | <a class="waves-effect" href="{{ path('with_annotations') }}">{{ 'menu.left.with_annotations'|trans }} <span class="numberItems grey-text">{{ count_entries('with_annotations') }}</span></a> | ||
66 | </li> | ||
62 | <li class="bold {% if activeRoute == 'all' %}active{% endif %}"> | 67 | <li class="bold {% if activeRoute == 'all' %}active{% endif %}"> |
63 | <a class="waves-effect" href="{{ path('all') }}">{{ 'menu.left.all_articles'|trans }} <span class="numberItems grey-text">{{ count_entries('all') }}</span></a> | 68 | <a class="waves-effect" href="{{ path('all') }}">{{ 'menu.left.all_articles'|trans }} <span class="numberItems grey-text">{{ count_entries('all') }}</span></a> |
64 | </li> | 69 | </li> |
diff --git a/src/Wallabag/CoreBundle/Twig/WallabagExtension.php b/src/Wallabag/CoreBundle/Twig/WallabagExtension.php index 47af3c8e..e0f67375 100644 --- a/src/Wallabag/CoreBundle/Twig/WallabagExtension.php +++ b/src/Wallabag/CoreBundle/Twig/WallabagExtension.php | |||
@@ -94,6 +94,9 @@ class WallabagExtension extends AbstractExtension implements GlobalsInterface | |||
94 | case 'unread': | 94 | case 'unread': |
95 | $qb = $this->entryRepository->getBuilderForUnreadByUser($user->getId()); | 95 | $qb = $this->entryRepository->getBuilderForUnreadByUser($user->getId()); |
96 | break; | 96 | break; |
97 | case 'with_annotations': | ||
98 | $qb = $this->entryRepository->getBuilderForAnnotationsByUser($user->getId()); | ||
99 | break; | ||
97 | case 'all': | 100 | case 'all': |
98 | $qb = $this->entryRepository->getBuilderForAllByUser($user->getId()); | 101 | $qb = $this->entryRepository->getBuilderForAllByUser($user->getId()); |
99 | break; | 102 | break; |