mirror of https://github.com/MISP/MISP
chg: [UI] Cleanup code for event index view
parent
f83b2928d2
commit
1a83d103d3
|
@ -2,7 +2,7 @@
|
|||
<tr>
|
||||
<?php if ($isSiteAdmin): ?>
|
||||
<th>
|
||||
<input class="select_all select" type="checkbox" title="<?php echo __('Select all');?>" role="button" tabindex="0" aria-label="<?php echo __('Select all events on current page');?>" onClick="toggleAllCheckboxes();">
|
||||
<input class="select_all select" type="checkbox" title="<?php echo __('Select all');?>" role="button" tabindex="0" aria-label="<?php echo __('Select all events on current page');?>" onclick="toggleAllCheckboxes();">
|
||||
</th>
|
||||
<?php else: ?>
|
||||
<th style="padding-left:0;padding-right:0;"> </th>
|
||||
|
@ -133,14 +133,14 @@
|
|||
<td class="bold" style="width:30px;">
|
||||
<?php if (!empty($event['Event']['sightings_count'])): ?>
|
||||
<a href="<?php echo $baseurl."/events/view/" . $eventId . '/sighting:1';?>" title="<?php echo (!empty($event['Event']['sightings_count']) ? h($event['Event']['sightings_count']) : '0') . ' sighting(s). Show filtered event with sighting(s) only.';?>">
|
||||
<?php echo h($event['Event']['sightings_count']); ?>
|
||||
<?= intval($event['Event']['sightings_count']) ?>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<?php endif; ?>
|
||||
<?php if (in_array('proposals', $columns, true)): ?>
|
||||
<td class="bold dblclickElement" style="width:30px;" title="<?= __n('%s proposal', '%s proposals', $event['Event']['proposals_count'], $event['Event']['proposals_count']) ?>">
|
||||
<?php echo !empty($event['Event']['proposals_count']) ? h($event['Event']['proposals_count']) : ''; ?>
|
||||
<?= !empty($event['Event']['proposals_count']) ? intval($event['Event']['proposals_count']) : ''; ?>
|
||||
</td>
|
||||
<?php endif;?>
|
||||
<?php if (in_array('discussion', $columns, true)): ?>
|
||||
|
@ -164,7 +164,7 @@
|
|||
</td>
|
||||
<?php endif; ?>
|
||||
<td class="short dblclickElement">
|
||||
<?= $event['Event']['date'] ?>
|
||||
<time><?= $event['Event']['date'] ?></time>
|
||||
</td>
|
||||
<?php if (in_array('timestamp', $columns, true)): ?>
|
||||
<td class="short dblclickElement">
|
||||
|
@ -179,9 +179,9 @@
|
|||
<td class="dblclickElement">
|
||||
<?= nl2br(h($event['Event']['info']), false) ?>
|
||||
</td>
|
||||
<td class="short dblclickElement <?php if ($event['Event']['distribution'] == 0) echo 'privateRedText';?>" title="<?php echo $event['Event']['distribution'] != 3 ? $distributionLevels[$event['Event']['distribution']] : __('All');?>">
|
||||
<td class="short dblclickElement<?php if ($event['Event']['distribution'] == 0) echo ' privateRedText';?>" title="<?php echo $event['Event']['distribution'] != 3 ? $distributionLevels[$event['Event']['distribution']] : __('All');?>">
|
||||
<?php if ($event['Event']['distribution'] == 4):?>
|
||||
<a href="<?php echo $baseurl;?>/sharingGroups/view/<?php echo h($event['SharingGroup']['id']); ?>"><?php echo h($event['SharingGroup']['name']);?></a>
|
||||
<a href="<?php echo $baseurl;?>/sharingGroups/view/<?= intval($event['SharingGroup']['id']); ?>"><?= h($event['SharingGroup']['name']) ?></a>
|
||||
<?php else:
|
||||
echo h($shortDist[$event['Event']['distribution']]);
|
||||
endif;
|
||||
|
|
Loading…
Reference in New Issue