From 20078c6e3132579339411b7f81cdb374c1dab2f1 Mon Sep 17 00:00:00 2001 From: David Bomba Date: Thu, 2 Jul 2020 20:56:10 +1000 Subject: [PATCH] Add ability to set country_id by country code and currency_id by currency code --- app/Http/Requests/Client/StoreClientRequest.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/Http/Requests/Client/StoreClientRequest.php b/app/Http/Requests/Client/StoreClientRequest.php index cea5c9ee22eb..3bda4d98fb38 100644 --- a/app/Http/Requests/Client/StoreClientRequest.php +++ b/app/Http/Requests/Client/StoreClientRequest.php @@ -138,6 +138,10 @@ class StoreClientRequest extends Request $input['country_id'] = $this->getCountryCode($input['country_code']); } + if(isset($input['shipping_country_code'])) { + $input['shipping_country_id'] = $this->getCountryCode($input['shipping_country_code']); + } + $this->replace($input); }