mirror of https://github.com/MISP/MISP
chg: [decaying:edit] Notice if editing a default model
parent
bfbba4e33b
commit
e421c0684e
|
@ -1206,7 +1206,7 @@ class AppModel extends Model
|
|||
`all_orgs` tinyint(1) NOT NULL DEFAULT 1,
|
||||
`ref` text COLLATE utf8_unicode_ci,
|
||||
`formula` varchar(255) COLLATE utf8_bin NOT NULL,
|
||||
`version` varchar(255) COLLATE utf8_bin NOT NULL
|
||||
`version` varchar(255) COLLATE utf8_bin NOT NULL DEFAULT ''
|
||||
PRIMARY KEY (id)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;";
|
||||
$sqlArray[] = "CREATE TABLE IF NOT EXISTS decaying_model_mappings (
|
||||
|
|
|
@ -3,7 +3,8 @@
|
|||
<fieldset>
|
||||
<legend><?php echo Inflector::humanize($action) . __(' Decaying Model');?></legend>
|
||||
<?php
|
||||
if ($restrictEdition) {
|
||||
if (isset($restrictEdition) && $restrictEdition) {
|
||||
echo '<div class="alert alert-warning">' . __('You are editing a Default Model, only restricted edition is allowed.') . '</div>';
|
||||
echo $this->Form->input('all_orgs', array(
|
||||
'label' => __('Can other organization use this model'),
|
||||
'type' => 'checkbox'
|
||||
|
|
Loading…
Reference in New Issue