Skip to content

Commit f0a9b2c

Browse files
committed
Merge pull request #738 from madd15/patch-4
Fix #737 -Only display comma & address2 if not empty
2 parents 63b1f38 + 1a4f148 commit f0a9b2c

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

app/views/backend/locations/index.blade.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,11 @@
3333
@foreach ($locations as $location)
3434
<tr>
3535
<td>{{{ $location->name }}}</td>
36-
<td>{{{ $location->address }}}, {{{ $location->address2 }}} </td>
36+
<td>{{{ $location->address }}}
37+
@if($location->address2 != '')
38+
, {{{ $location->address2 }}}
39+
@endif
40+
</td>
3741
<td>{{{ $location->city }}}, {{{ strtoupper($location->state) }}} {{{ strtoupper($location->country) }}} </td>
3842
<td>
3943
<a href="{{ route('update/location', $location->id) }}" class="btn btn-warning btn-sm"><i class="fa fa-pencil icon-white"></i></a>

0 commit comments

Comments
 (0)