Skip to content

Commit

Permalink
wip loading tags (currently concats all and explodes, needs column id?
Browse files Browse the repository at this point in the history
  • Loading branch information
hinanaya committed Jun 20, 2024
1 parent 56a44f5 commit 53cfbfe
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions models/media_model.php
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,8 @@ public function get_init_what($args = [])
}

if ($metadata_field['type'] === 'tags') {
// $this->db->what('GROUP_CONCAT(media_tags.tag)', 'metadata_' . $metadata_field['name'], false);
// var_dump($metadata_field['id']); die();
continue;
}

Expand All @@ -274,6 +276,7 @@ public function get_init_join($args = [])
$this->db->leftjoin('languages', 'media.language', 'languages.language_id');
$this->db->leftjoin('countries', 'media.country', 'countries.country_id');
$this->db->leftjoin('media_genres', 'media.genre_id', 'media_genres.id');
$this->db->leftjoin('media_tags', 'media_tags.media_id', 'media.id');
$this->db->leftjoin('users', 'media.owner_id', 'users.id');
}

Expand Down

0 comments on commit 53cfbfe

Please sign in to comment.