|
|
@@ -12,8 +12,9 @@ namespace App;
|
|
|
<col style="width: 1%"/>
|
|
|
<col style="width: 20%"/>
|
|
|
<col style="width: 20%"/>
|
|
|
- <col style="width: 40%"/>
|
|
|
- <col style="width: 20%"/>
|
|
|
+ <col style="width: 50%"/>
|
|
|
+ <col style="width: 10%"/>
|
|
|
+ <col style="width: 1%"/>
|
|
|
</colgroup>
|
|
|
<thead>
|
|
|
<tr>
|
|
|
@@ -21,6 +22,7 @@ namespace App;
|
|
|
<th><?=htmlspecialchars(__("Customer"))?></th>
|
|
|
<th><?=htmlspecialchars(__("Name"))?></th>
|
|
|
<th><?=htmlspecialchars(__("Address"))?></th>
|
|
|
+ <th><?=htmlspecialchars(__("Map"))?></th>
|
|
|
<th><?=htmlspecialchars(__("Actions"))?></th>
|
|
|
</tr>
|
|
|
</thead>
|
|
|
@@ -28,6 +30,7 @@ namespace App;
|
|
|
<?php
|
|
|
foreach($locations as $location) {
|
|
|
$customer = $location->getCustomer();
|
|
|
+ $address = $location->getAddress();
|
|
|
?>
|
|
|
<tr>
|
|
|
<td class="text-end"><?=$location->id?></td>
|
|
|
@@ -40,7 +43,21 @@ namespace App;
|
|
|
<?=htmlspecialchars($location->name)?>
|
|
|
</td>
|
|
|
<td>
|
|
|
- <?=htmlspecialchars(implode(", ", $location->getAddress()->getLines()))?>
|
|
|
+ <?=htmlspecialchars(implode(", ", $address->getLines()))?>
|
|
|
+ </td>
|
|
|
+ <td>
|
|
|
+ <?php
|
|
|
+ if($address->hasGeolocation()) {
|
|
|
+ ?>
|
|
|
+ <i class="fa fa-fw fa-check text-success lat-lng-icon" data-latitude="<?=$address->latitude?>" data-longitude="<?=$address->longitude?>" style="cursor: pointer"></i>
|
|
|
+ <?php
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ ?>
|
|
|
+ <i class="fa fa-fw fa-times text-danger"></i>
|
|
|
+ <?php
|
|
|
+ }
|
|
|
+ ?>
|
|
|
</td>
|
|
|
<td class="p-1">
|
|
|
<a class="btn btn-sm btn-primary" href="<?=htmlspecialchars($location->getUrl())?>">
|