Fix photos

This commit is contained in:
Alan
2026-02-16 22:38:47 +03:00
parent a755a8e5c4
commit b4bc91f545
6 changed files with 43 additions and 5 deletions

View File

@@ -80,7 +80,7 @@ class RepairsPostAdmin extends Simpla
$this->design->assign('post', $post);
$this->db->query("SELECT * FROM __repairs_photo WHERE repair_id='" . $post->id . "' ORDER BY position, id DESC");
$this->db->query("SELECT * FROM __repair_photo WHERE repair_id='" . $post->id . "' ORDER BY position, id DESC");
$photos = $this->db->results();
foreach($photos as $ph) $ph->img = Img::get('files/post/' . $ph->img, array('width'=>120, 'height'=>120));
$this->design->assign('repair_photos', $photos);