From 2ee6e8e76db47c24199cf1092a84ae9de849d978 Mon Sep 17 00:00:00 2001 From: Roland Schneider Date: Tue, 7 Jan 2020 20:46:31 +0100 Subject: [PATCH] fix frontend fingerprint gui --- frontend/controllers/FingerprintController.php | 1 + frontend/models/FingerprintSearch.php | 2 +- frontend/views/fingerprint/create.php | 3 +++ frontend/views/fingerprint/index.php | 3 ++- 4 files changed, 7 insertions(+), 2 deletions(-) diff --git a/frontend/controllers/FingerprintController.php b/frontend/controllers/FingerprintController.php index f38d0c5..c43b18e 100644 --- a/frontend/controllers/FingerprintController.php +++ b/frontend/controllers/FingerprintController.php @@ -88,6 +88,7 @@ class FingerprintController extends Controller return $this->redirect(['index', 'FingerprintSearch[id_card]' => $card->id_card]); } return $this->render('create', [ + 'card' => $card, 'model' => $model, ]); diff --git a/frontend/models/FingerprintSearch.php b/frontend/models/FingerprintSearch.php index a2c2452..2878c0e 100644 --- a/frontend/models/FingerprintSearch.php +++ b/frontend/models/FingerprintSearch.php @@ -50,7 +50,7 @@ class FingerprintSearch extends Fingerprint } $this->card = $card; - $customer = Customer::findOne($card->customer); + $customer = Customer::findOne($card->customer->id_customer); if ( !isset($customer)){ throw new NotFoundHttpException('Customer not found'); diff --git a/frontend/views/fingerprint/create.php b/frontend/views/fingerprint/create.php index 119dbd1..aa71e69 100644 --- a/frontend/views/fingerprint/create.php +++ b/frontend/views/fingerprint/create.php @@ -1,5 +1,6 @@ title = 'Ujjlenyomat hozzáadása'; $this->params['breadcrumbs'][] = ['label' => 'Ujjlenyomatok', 'url' => ['index', 'id_customer' => $model->id_customer]]; $this->params['breadcrumbs'][] = $this->title; ?> + $card])?> +

title) ?>

diff --git a/frontend/views/fingerprint/index.php b/frontend/views/fingerprint/index.php index 429bf51..845dc18 100644 --- a/frontend/views/fingerprint/index.php +++ b/frontend/views/fingerprint/index.php @@ -1,10 +1,11 @@ -

Ujjlenyomatok

+ $card])?>