mirror of https://github.com/wallabag/wallabag.git
multiple tag entry displayed fix, issue #474
This commit is contained in:
parent
b4fd2154fe
commit
e83cf5a787
|
@ -345,7 +345,7 @@ class Database {
|
||||||
}
|
}
|
||||||
|
|
||||||
public function retrieveAllTags($user_id) {
|
public function retrieveAllTags($user_id) {
|
||||||
$sql = "SELECT tags.* FROM tags
|
$sql = "SELECT DISTINCT tags.* FROM tags
|
||||||
LEFT JOIN tags_entries ON tags_entries.tag_id=tags.id
|
LEFT JOIN tags_entries ON tags_entries.tag_id=tags.id
|
||||||
LEFT JOIN entries ON tags_entries.entry_id=entries.id
|
LEFT JOIN entries ON tags_entries.entry_id=entries.id
|
||||||
WHERE entries.user_id=?";
|
WHERE entries.user_id=?";
|
||||||
|
@ -357,7 +357,7 @@ class Database {
|
||||||
|
|
||||||
public function retrieveTag($id, $user_id) {
|
public function retrieveTag($id, $user_id) {
|
||||||
$tag = NULL;
|
$tag = NULL;
|
||||||
$sql = "SELECT tags.* FROM tags
|
$sql = "SELECT DISTINCT tags.* FROM tags
|
||||||
LEFT JOIN tags_entries ON tags_entries.tag_id=tags.id
|
LEFT JOIN tags_entries ON tags_entries.tag_id=tags.id
|
||||||
LEFT JOIN entries ON tags_entries.entry_id=entries.id
|
LEFT JOIN entries ON tags_entries.entry_id=entries.id
|
||||||
WHERE tags.id=? AND entries.user_id=?";
|
WHERE tags.id=? AND entries.user_id=?";
|
||||||
|
|
Loading…
Reference in New Issue