mirror of https://github.com/MISP/MISP
Small errors with the merge corrected
- some errors managed to slip through during the merge, should be fixedpull/64/merge
parent
4396cec8ea
commit
b98818ebfb
|
@ -85,7 +85,7 @@ class AttributesController extends AppController {
|
|||
$this->Attribute->recursive = 0;
|
||||
$this->set('isSearch', 0);
|
||||
|
||||
$this->set('attributes', $this->paginate);
|
||||
$this->set('attributes', $this->paginate());
|
||||
|
||||
$this->set('attrDescriptions', $this->Attribute->fieldDescriptions);
|
||||
$this->set('typeDefinitions', $this->Attribute->typeDefinitions);
|
||||
|
@ -708,6 +708,7 @@ class AttributesController extends AppController {
|
|||
// search on the value field
|
||||
if (isset($keyword)) {
|
||||
$keywordArray = explode("\n", $keyword);
|
||||
$this->set('keywordArray', $keywordArray);
|
||||
$i = 1;
|
||||
$temp = array();
|
||||
foreach ($keywordArray as $keywordArrayElement) {
|
||||
|
|
|
@ -114,10 +114,7 @@ class EventsController extends AppController {
|
|||
// list the events
|
||||
$this->Event->recursive = 0;
|
||||
|
||||
$paginated = $this->paginate();
|
||||
$events = $paginated;
|
||||
$this->set('events', $events);
|
||||
|
||||
$this->set('events', $this->paginate());
|
||||
if (!$this->Auth->user('gpgkey')) {
|
||||
$this->Session->setFlash(__('No GPG key set in your profile. To receive emails, submit your public key in your profile.'));
|
||||
}
|
||||
|
|
|
@ -22,8 +22,8 @@ class ShadowAttribute extends AppModel {
|
|||
//'change' => 'full'),
|
||||
'Trim',
|
||||
'Containable',
|
||||
//'Regexp' => array('fields' => array('value', 'value2')),
|
||||
//'Blacklist' => array('fields' => array('value'))
|
||||
'Regexp' => array('fields' => array('value', 'value2')),
|
||||
'Blacklist' => array('fields' => array('value'))
|
||||
);
|
||||
|
||||
/**
|
||||
|
@ -256,19 +256,14 @@ class ShadowAttribute extends AppModel {
|
|||
|
||||
public function __construct($id = false, $table = null, $ds = null) {
|
||||
parent::__construct($id, $table, $ds);
|
||||
|
||||
if ('true' == Configure::read('CyDefSIG.private')) {
|
||||
|
||||
$this->virtualFields = Set::merge($this->virtualFields,array(
|
||||
//'distribution' => 'IF (Attribute.private=true, "Your organization only", IF (Attribute.cluster=true, "This Community-only", "All communities"))',
|
||||
//'distribution' => 'IF (ShadowAttribute.private=true AND ShadowAttribute.cluster=false, "Your organization only", IF (ShadowAttribute.private=true AND ShadowAttribute.cluster=true, "This server-only", IF (ShadowAttribute.private=false AND ShadowAttribute.cluster=true, "This Community-only", IF (ShadowAttribute.communitie=true, "Connected communities" , "All communities"))))',
|
||||
));
|
||||
|
||||
$this->fieldDescriptions = Set::merge($this->fieldDescriptions,array(
|
||||
//'distribution' => array('desc' => 'This fields indicates the intended distribution of the attribute (same as when adding an event, see Add Event)'),
|
||||
));
|
||||
}
|
||||
}
|
||||
|
||||
//The Associations below have been created with all possible keys, those that are not needed can be removed
|
||||
|
||||
|
|
|
@ -57,7 +57,6 @@ foreach ($attributes as $attribute):
|
|||
<?php echo h($attribute['Attribute']['type']); ?> </td>
|
||||
<td onclick="document.location ='<?php echo $this->Html->url(array('controller' => 'events', 'action' => 'view', $attribute['Attribute']['event_id']), true);?>';">
|
||||
<?php
|
||||
$sigDisplay = nl2br($attribute['Attribute']['value']);
|
||||
$sigDisplay = nl2br(h($attribute['Attribute']['value']));
|
||||
if ($isSearch == 1 && !empty($replacePairs)) {
|
||||
// highlight the keywords if there are any
|
||||
|
|
|
@ -13,8 +13,8 @@
|
|||
foreach ($list as $item): ?>
|
||||
<tr>
|
||||
<td class="short"><?php echo h($item['Role']['id']); ?> </td>
|
||||
<td class="short"><?php echo $item['Role']['name']; ?> </td>
|
||||
<td class="short"><?php echo $options[$item['Role']['permission']]; ?> </td>
|
||||
<td class="short"><?php echo h($item['Role']['name']); ?> </td>
|
||||
<td class="short"><?php echo h($options[$item['Role']['permission']]); ?> </td>
|
||||
<td class="short"><?php echo h($item['Role']['perm_sync']); ?> </td>
|
||||
<td class="short"><?php echo h($item['Role']['perm_admin']); ?> </td>
|
||||
<td class="short"><?php echo h($item['Role']['perm_audit']); ?> </td>
|
||||
|
|
|
@ -1,6 +1,3 @@
|
|||
<?php
|
||||
$mayModify = true;
|
||||
?>
|
||||
<div class="shadowAttributes form">
|
||||
<?php echo $this->Form->create('ShadowAttribute');?>
|
||||
<fieldset>
|
||||
|
|
Loading…
Reference in New Issue