diff --git a/app/Livewire/Forms/Studio/Catalog/BottleForm.php b/app/Livewire/Forms/Studio/Catalog/BottleForm.php index c1cfec5..2050028 100644 --- a/app/Livewire/Forms/Studio/Catalog/BottleForm.php +++ b/app/Livewire/Forms/Studio/Catalog/BottleForm.php @@ -103,6 +103,7 @@ private function prepareSavedData(): array 'size' => $this->size, 'cost_price' => replaceCurrency($this->cost_price), 'sale_price' => replaceCurrency($this->sale_price), + 'point_per_ml' => round($this->sale_price / 100), 'description' => $this->description, ]; } diff --git a/app/Livewire/Forms/Studio/Catalog/PerfumeForm.php b/app/Livewire/Forms/Studio/Catalog/PerfumeForm.php index 43d115b..ba26328 100644 --- a/app/Livewire/Forms/Studio/Catalog/PerfumeForm.php +++ b/app/Livewire/Forms/Studio/Catalog/PerfumeForm.php @@ -145,6 +145,7 @@ private function prepareSavedData() 'sku' => $this->sku, 'cost_price' => replaceCurrency($this->cost_price), 'sale_price' => replaceCurrency($this->sale_price), + 'point_per_ml' => round($this->sale_price / 100), 'base_notes' => $this->base_notes, 'middle_notes' => $this->middle_notes, 'top_notes' => $this->top_notes, diff --git a/app/Livewire/Forms/Studio/Catalog/ProductForm.php b/app/Livewire/Forms/Studio/Catalog/ProductForm.php index c8383d2..a9b45f7 100644 --- a/app/Livewire/Forms/Studio/Catalog/ProductForm.php +++ b/app/Livewire/Forms/Studio/Catalog/ProductForm.php @@ -113,6 +113,7 @@ private function prepareSavedData() 'sku' => $this->sku, 'cost_price' => replaceCurrency($this->cost_price), 'sale_price' => replaceCurrency($this->sale_price), + 'point_per_ml' => round($this->sale_price / 100), 'description' => $this->description, 'outlet_ids' => $this->outlet_ids, 'image' => $this->image,