168 lines
8.0 KiB
PHP
168 lines
8.0 KiB
PHP
|
|
<?php
|
||
|
|
/**
|
||
|
|
* @var \App\View\AppView $this
|
||
|
|
* @var \Cake\Datasource\EntityInterface $state
|
||
|
|
*/
|
||
|
|
?>
|
||
|
|
<div class="row">
|
||
|
|
<aside class="column">
|
||
|
|
<div class="side-nav">
|
||
|
|
<h4 class="heading"><?= __('Actions') ?></h4>
|
||
|
|
<?= $this->Html->link(__('List States'), ['action' => 'index'], ['class' => 'side-nav-item']) ?>
|
||
|
|
</div>
|
||
|
|
</aside>
|
||
|
|
<div class="column column-80">
|
||
|
|
<div class="states view content">
|
||
|
|
<h3><?= h($state->name) ?></h3>
|
||
|
|
<table>
|
||
|
|
<tr>
|
||
|
|
<th><?= __('Name') ?></th>
|
||
|
|
<td><?= h($state->name) ?></td>
|
||
|
|
</tr>
|
||
|
|
<tr>
|
||
|
|
<th><?= __('Country') ?></th>
|
||
|
|
<td><?= $state->hasValue('country') ? $this->Html->link($state->country->name, ['controller' => 'Countries', 'action' => 'view', $state->country->id]) : '' ?></td>
|
||
|
|
</tr>
|
||
|
|
<tr>
|
||
|
|
<th><?= __('Country Code') ?></th>
|
||
|
|
<td><?= h($state->country_code) ?></td>
|
||
|
|
</tr>
|
||
|
|
<tr>
|
||
|
|
<th><?= __('Fips Code') ?></th>
|
||
|
|
<td><?= h($state->fips_code) ?></td>
|
||
|
|
</tr>
|
||
|
|
<tr>
|
||
|
|
<th><?= __('Iso2') ?></th>
|
||
|
|
<td><?= h($state->iso2) ?></td>
|
||
|
|
</tr>
|
||
|
|
<tr>
|
||
|
|
<th><?= __('Type') ?></th>
|
||
|
|
<td><?= h($state->type) ?></td>
|
||
|
|
</tr>
|
||
|
|
<tr>
|
||
|
|
<th><?= __('WikiDataId') ?></th>
|
||
|
|
<td><?= h($state->wikiDataId) ?></td>
|
||
|
|
</tr>
|
||
|
|
<tr>
|
||
|
|
<th><?= __('Id') ?></th>
|
||
|
|
<td><?= $this->Number->format($state->id) ?></td>
|
||
|
|
</tr>
|
||
|
|
<tr>
|
||
|
|
<th><?= __('Latitude') ?></th>
|
||
|
|
<td><?= $state->latitude === null ? '' : $this->Number->format($state->latitude) ?></td>
|
||
|
|
</tr>
|
||
|
|
<tr>
|
||
|
|
<th><?= __('Longitude') ?></th>
|
||
|
|
<td><?= $state->longitude === null ? '' : $this->Number->format($state->longitude) ?></td>
|
||
|
|
</tr>
|
||
|
|
<tr>
|
||
|
|
<th><?= __('Created At') ?></th>
|
||
|
|
<td><?= h($state->created_at) ?></td>
|
||
|
|
</tr>
|
||
|
|
<tr>
|
||
|
|
<th><?= __('Updated At') ?></th>
|
||
|
|
<td><?= h($state->updated_at) ?></td>
|
||
|
|
</tr>
|
||
|
|
<tr>
|
||
|
|
<th><?= __('Flag') ?></th>
|
||
|
|
<td><?= $state->flag ? __('Yes') : __('No'); ?></td>
|
||
|
|
</tr>
|
||
|
|
</table>
|
||
|
|
<div class="related">
|
||
|
|
<h4><?= __('Related Addresses') ?></h4>
|
||
|
|
<?php if (!empty($state->addresses)) : ?>
|
||
|
|
<div class="table-responsive">
|
||
|
|
<table>
|
||
|
|
<tr>
|
||
|
|
<th><?= __('Id') ?></th>
|
||
|
|
<th><?= __('Address Name') ?></th>
|
||
|
|
<th><?= __('Contact Name') ?></th>
|
||
|
|
<th><?= __('Address Line1') ?></th>
|
||
|
|
<th><?= __('Address Line2') ?></th>
|
||
|
|
<th><?= __('City') ?></th>
|
||
|
|
<th><?= __('City Id') ?></th>
|
||
|
|
<th><?= __('State') ?></th>
|
||
|
|
<th><?= __('State Id') ?></th>
|
||
|
|
<th><?= __('Postal Code') ?></th>
|
||
|
|
<th><?= __('Country') ?></th>
|
||
|
|
<th><?= __('Country Id') ?></th>
|
||
|
|
<th><?= __('Phone Number') ?></th>
|
||
|
|
<th><?= __('Email') ?></th>
|
||
|
|
<th><?= __('Notes') ?></th>
|
||
|
|
<th class="actions"><?= __('Actions') ?></th>
|
||
|
|
</tr>
|
||
|
|
<?php foreach ($state->addresses as $addresses) : ?>
|
||
|
|
<tr>
|
||
|
|
<td><?= h($addresses->id) ?></td>
|
||
|
|
<td><?= h($addresses->address_name) ?></td>
|
||
|
|
<td><?= h($addresses->contact_name) ?></td>
|
||
|
|
<td><?= h($addresses->address_line1) ?></td>
|
||
|
|
<td><?= h($addresses->address_line2) ?></td>
|
||
|
|
<td><?= h($addresses->city) ?></td>
|
||
|
|
<td><?= h($addresses->city_id) ?></td>
|
||
|
|
<td><?= h($addresses->state) ?></td>
|
||
|
|
<td><?= h($addresses->state_id) ?></td>
|
||
|
|
<td><?= h($addresses->postal_code) ?></td>
|
||
|
|
<td><?= h($addresses->country) ?></td>
|
||
|
|
<td><?= h($addresses->country_id) ?></td>
|
||
|
|
<td><?= h($addresses->phone_number) ?></td>
|
||
|
|
<td><?= h($addresses->email) ?></td>
|
||
|
|
<td><?= h($addresses->notes) ?></td>
|
||
|
|
<td class="actions">
|
||
|
|
<?= $this->Html->link(__('View'), ['controller' => 'Addresses', 'action' => 'view', $addresses->id]) ?>
|
||
|
|
<?= $this->Html->link(__('Edit'), ['controller' => 'Addresses', 'action' => 'edit', $addresses->id]) ?>
|
||
|
|
<?= $this->Form->postLink(__('Delete'), ['controller' => 'Addresses', 'action' => 'delete', $addresses->id], ['confirm' => __('Are you sure you want to delete # {0}?', $addresses->id)]) ?>
|
||
|
|
</td>
|
||
|
|
</tr>
|
||
|
|
<?php endforeach; ?>
|
||
|
|
</table>
|
||
|
|
</div>
|
||
|
|
<?php endif; ?>
|
||
|
|
</div>
|
||
|
|
<div class="related">
|
||
|
|
<h4><?= __('Related Cities') ?></h4>
|
||
|
|
<?php if (!empty($state->cities)) : ?>
|
||
|
|
<div class="table-responsive">
|
||
|
|
<table>
|
||
|
|
<tr>
|
||
|
|
<th><?= __('Id') ?></th>
|
||
|
|
<th><?= __('Name') ?></th>
|
||
|
|
<th><?= __('State Id') ?></th>
|
||
|
|
<th><?= __('State Code') ?></th>
|
||
|
|
<th><?= __('Country Id') ?></th>
|
||
|
|
<th><?= __('Country Code') ?></th>
|
||
|
|
<th><?= __('Latitude') ?></th>
|
||
|
|
<th><?= __('Longitude') ?></th>
|
||
|
|
<th><?= __('Created At') ?></th>
|
||
|
|
<th><?= __('Updated At') ?></th>
|
||
|
|
<th><?= __('Flag') ?></th>
|
||
|
|
<th><?= __('WikiDataId') ?></th>
|
||
|
|
<th class="actions"><?= __('Actions') ?></th>
|
||
|
|
</tr>
|
||
|
|
<?php foreach ($state->cities as $cities) : ?>
|
||
|
|
<tr>
|
||
|
|
<td><?= h($cities->id) ?></td>
|
||
|
|
<td><?= h($cities->name) ?></td>
|
||
|
|
<td><?= h($cities->state_id) ?></td>
|
||
|
|
<td><?= h($cities->state_code) ?></td>
|
||
|
|
<td><?= h($cities->country_id) ?></td>
|
||
|
|
<td><?= h($cities->country_code) ?></td>
|
||
|
|
<td><?= h($cities->latitude) ?></td>
|
||
|
|
<td><?= h($cities->longitude) ?></td>
|
||
|
|
<td><?= h($cities->created_at) ?></td>
|
||
|
|
<td><?= h($cities->updated_at) ?></td>
|
||
|
|
<td><?= h($cities->flag) ?></td>
|
||
|
|
<td><?= h($cities->wikiDataId) ?></td>
|
||
|
|
<td class="actions">
|
||
|
|
<?= $this->Html->link(__('View'), ['controller' => 'Cities', 'action' => 'view', $cities->id]) ?>
|
||
|
|
</td>
|
||
|
|
</tr>
|
||
|
|
<?php endforeach; ?>
|
||
|
|
</table>
|
||
|
|
</div>
|
||
|
|
<?php endif; ?>
|
||
|
|
</div>
|
||
|
|
</div>
|
||
|
|
</div>
|
||
|
|
</div>
|