diff --git a/app/Services/StickerPdfService.php b/app/Services/StickerPdfService.php index 06b2816..f4777ec 100644 --- a/app/Services/StickerPdfService.php +++ b/app/Services/StickerPdfService.php @@ -16,9 +16,16 @@ class StickerPdfService $structure = StickerStructureDetail::where('sticker_id', $stickerId) ->first(); - $stickerId = $structure->sticker_id; + // $stickerId = $structure->sticker_id; - $elements = StickerDetail::where('sticker_structure_detail_id', $stickerId)->get(); + // $elements = StickerDetail::where('sticker_structure_detail_id', $stickerId)->get(); + + // dd($elements); + $structureId = $structure->id; + $elements = StickerDetail::where( + 'sticker_structure_detail_id', + $structureId + )->get(); $width = (float) $structure->sticker_width; $height = (float) $structure->sticker_height;