From 53f2914d27c99ec2ab9c95faf37bc0170ed76ac6 Mon Sep 17 00:00:00 2001 From: developer Date: Fri, 3 Apr 2026 12:02:02 +0800 Subject: [PATCH] =?UTF-8?q?plan7=20selector=20-=20=D0=B4=D0=BE=D0=B1=D0=B0?= =?UTF-8?q?=D0=B2=D0=BB=D0=B5=D0=BD=D0=B0=20=D0=B0=D0=B4=D0=BC=D0=B8=D0=BD?= =?UTF-8?q?=D0=BA=D0=B0=20=D0=B4=D0=BB=D1=8F=20=D1=81=D0=BE=D1=85=D1=80?= =?UTF-8?q?=D0=B0=D0=BD=D0=B5=D0=BD=D0=B8=D1=8F=20api=20=D0=B4=D0=B0=D0=BD?= =?UTF-8?q?=D0=BD=D1=8B=D1=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Plan7/Http/Livewire/Plan7SelectorLivewire.php | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/app/Modules/Plan7/Http/Livewire/Plan7SelectorLivewire.php b/app/Modules/Plan7/Http/Livewire/Plan7SelectorLivewire.php index c39bcb4..0548c88 100644 --- a/app/Modules/Plan7/Http/Livewire/Plan7SelectorLivewire.php +++ b/app/Modules/Plan7/Http/Livewire/Plan7SelectorLivewire.php @@ -25,6 +25,9 @@ class Plan7SelectorLivewire extends Component public function mount() { $this->containerId = $this->containerId . '__' . $this->complexId; + $this->load(); + } + public function load() { if ($plan7ApiData = Complex::find($this->complexId)->getPlan7ApiData()) { $this->apiSummary = 'https://plan7.ru/catalog/exp/json/summary/?token=' . $plan7ApiData->token . '&zk=' . $plan7ApiData->zk; $this->apiAll = 'https://plan7.ru/catalog/exp/json/?token=' . $plan7ApiData->token . '&zk=' . $plan7ApiData->zk; @@ -32,10 +35,10 @@ public function mount() $this->getData(); } } - public function updated($property, $value) + public function updating($property, $value) { - if ($property === 'complexId') { - $this->mount(); + if ($property == 'complexId') { + $this->load(); } }