@@ -123,8 +123,7 @@ |
||
123 | 123 | ->addresses() |
124 | 124 | ->whereId($id) |
125 | 125 | ->firstOrFail(); |
126 | - } |
|
127 | - catch (ModelNotFoundException $e) |
|
126 | + } catch (ModelNotFoundException $e) |
|
128 | 127 | { |
129 | 128 | throw new AddressNotFoundException('Address not found.'); |
130 | 129 | } |
@@ -50,10 +50,11 @@ |
||
50 | 50 | $paths = request()->segments(); |
51 | 51 | if (count($paths) > 1) { |
52 | 52 | foreach ($paths as $key => $pah) { |
53 | - if ($key == 1) |
|
54 | - $breadcumb[] = ["name" => ucfirst($pah), "url" => request()->getBaseUrl() . "/" . $paths[0] . "/" . $paths[$key], 'icon' => config("module.admin." . $pah . ".icon")]; |
|
55 | - elseif ($key == 2) |
|
56 | - $breadcumb[] = ["name" => ucfirst($pah), "url" => request()->getBaseUrl() . "/" . $paths[0] . "/" . $paths[1] . "/" . $paths[$key], 'icon' => config("module.admin." . $pah . ".icon")]; |
|
53 | + if ($key == 1) { |
|
54 | + $breadcumb[] = ["name" => ucfirst($pah), "url" => request()->getBaseUrl() . "/" . $paths[0] . "/" . $paths[$key], 'icon' => config("module.admin." . $pah . ".icon")]; |
|
55 | + } elseif ($key == 2) { |
|
56 | + $breadcumb[] = ["name" => ucfirst($pah), "url" => request()->getBaseUrl() . "/" . $paths[0] . "/" . $paths[1] . "/" . $paths[$key], 'icon' => config("module.admin." . $pah . ".icon")]; |
|
57 | + } |
|
57 | 58 | } |
58 | 59 | } |
59 | 60 | $view->with( |
@@ -144,8 +144,7 @@ |
||
144 | 144 | if ($address->orders()->exists()) { |
145 | 145 | $address->status=0; |
146 | 146 | $address->save(); |
147 | - } |
|
148 | - else { |
|
147 | + } else { |
|
149 | 148 | $address->delete(); |
150 | 149 | } |
151 | 150 | return redirect()->route('accounts', ['tab' => 'address']) |