Skip to content

Commit 31143b7

Browse files
author
Till Brehm
committed
Fixed: FS#3271 - Bug with installer/interface
1 parent 494da45 commit 31143b7

File tree

3 files changed

+38
-38
lines changed

3 files changed

+38
-38
lines changed

install/sql/ispconfig3.sql

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,7 @@ CREATE TABLE `client` (
229229
`language` char(2) NOT NULL DEFAULT 'en',
230230
`usertheme` varchar(32) NOT NULL DEFAULT 'default',
231231
`template_master` int(11) unsigned NOT NULL DEFAULT '0',
232-
`template_additional` text NOT NULL DEFAULT '',
232+
`template_additional` text NOT NULL,
233233
`created_at` bigint(20) DEFAULT NULL,
234234
`locked` enum('n','y') NOT NULL DEFAULT 'n',
235235
`canceled` enum('n','y') NOT NULL DEFAULT 'n',
@@ -736,8 +736,8 @@ CREATE TABLE `mail_domain` (
736736
`server_id` int(11) unsigned NOT NULL default '0',
737737
`domain` varchar(255) NOT NULL default '',
738738
`dkim` ENUM( 'n', 'y' ) NOT NULL default 'n',
739-
`dkim_private` mediumtext NOT NULL default '',
740-
`dkim_public` mediumtext NOT NULL default '',
739+
`dkim_private` mediumtext NOT NULL,
740+
`dkim_public` mediumtext NOT NULL,
741741
`active` enum('n','y') NOT NULL,
742742
PRIMARY KEY (`domain_id`),
743743
KEY `server_id` (`server_id`,`domain`),
@@ -1689,7 +1689,7 @@ CREATE TABLE `sys_user` (
16891689
`typ` varchar(16) NOT NULL default 'user',
16901690
`active` tinyint(1) NOT NULL default '1',
16911691
`language` varchar(2) NOT NULL default 'en',
1692-
`groups` TEXT NOT NULL default '',
1692+
`groups` TEXT NOT NULL,
16931693
`default_group` int(11) unsigned NOT NULL default '0',
16941694
`client_id` int(11) unsigned NOT NULL default '0',
16951695
`id_rsa` VARCHAR( 2000 ) NOT NULL default '',

interface/web/sites/web_domain_edit.php

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -518,15 +518,15 @@ function onSubmit() {
518518
$client_group_id = $app->functions->intval($_SESSION["s"]["user"]["default_group"]);
519519
$client = $app->db->queryOneRecord("SELECT limit_traffic_quota, limit_web_domain, default_webserver, parent_client_id, limit_web_quota, client." . implode(", client.", $read_limits) . " FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
520520

521-
if($client['limit_cgi'] != 'y') $this->dataRecord['cgi'] = '-';
522-
if($client['limit_ssi'] != 'y') $this->dataRecord['ssi'] = '-';
523-
if($client['limit_perl'] != 'y') $this->dataRecord['perl'] = '-';
524-
if($client['limit_ruby'] != 'y') $this->dataRecord['ruby'] = '-';
525-
if($client['limit_python'] != 'y') $this->dataRecord['python'] = '-';
521+
if($client['limit_cgi'] != 'y') $this->dataRecord['cgi'] = 'n';
522+
if($client['limit_ssi'] != 'y') $this->dataRecord['ssi'] = 'n';
523+
if($client['limit_perl'] != 'y') $this->dataRecord['perl'] = 'n';
524+
if($client['limit_ruby'] != 'y') $this->dataRecord['ruby'] = 'n';
525+
if($client['limit_python'] != 'y') $this->dataRecord['python'] = 'n';
526526
if($client['force_suexec'] == 'y') $this->dataRecord['suexec'] = 'y';
527-
if($client['limit_hterror'] != 'y') $this->dataRecord['errordocs'] = '-';
528-
if($client['limit_wildcard'] != 'y' && $this->dataRecord['subdomain'] == '*') $this->dataRecord['subdomain'] = '-';
529-
if($client['limit_ssl'] != 'y') $this->dataRecord['ssl'] = '-';
527+
if($client['limit_hterror'] != 'y') $this->dataRecord['errordocs'] = 'n';
528+
if($client['limit_wildcard'] != 'y' && $this->dataRecord['subdomain'] == '*') $this->dataRecord['subdomain'] = 'n';
529+
if($client['limit_ssl'] != 'y') $this->dataRecord['ssl'] = 'n';
530530

531531
// only generate quota and traffic warnings if value has changed
532532
if($this->id > 0) {
@@ -611,15 +611,15 @@ function onSubmit() {
611611
$this->dataRecord["server_id"] = $tmp["server_id"];
612612

613613
// set the settings to current if not provided (or cleared due to limits)
614-
if($this->dataRecord['cgi'] == '-') $this->dataRecord['cgi'] = $tmp['cgi'];
615-
if($this->dataRecord['ssi'] == '-') $this->dataRecord['ssi'] = $tmp['ssi'];
616-
if($this->dataRecord['perl'] == '-') $this->dataRecord['perl'] = $tmp['perl'];
617-
if($this->dataRecord['ruby'] == '-') $this->dataRecord['ruby'] = $tmp['ruby'];
618-
if($this->dataRecord['python'] == '-') $this->dataRecord['python'] = $tmp['python'];
619-
if($this->dataRecord['suexec'] == '-') $this->dataRecord['suexec'] = $tmp['suexec'];
620-
if($this->dataRecord['errordocs'] == '-') $this->dataRecord['errordocs'] = $tmp['errordocs'];
621-
if($this->dataRecord['subdomain'] == '-') $this->dataRecord['subdomain'] = $tmp['subdomain'];
622-
if($this->dataRecord['ssl'] == '-') $this->dataRecord['ssl'] = $tmp['ssl'];
614+
if($this->dataRecord['cgi'] == 'n') $this->dataRecord['cgi'] = $tmp['cgi'];
615+
if($this->dataRecord['ssi'] == 'n') $this->dataRecord['ssi'] = $tmp['ssi'];
616+
if($this->dataRecord['perl'] == 'n') $this->dataRecord['perl'] = $tmp['perl'];
617+
if($this->dataRecord['ruby'] == 'n') $this->dataRecord['ruby'] = $tmp['ruby'];
618+
if($this->dataRecord['python'] == 'n') $this->dataRecord['python'] = $tmp['python'];
619+
if($this->dataRecord['suexec'] == 'n') $this->dataRecord['suexec'] = $tmp['suexec'];
620+
if($this->dataRecord['errordocs'] == 'n') $this->dataRecord['errordocs'] = $tmp['errordocs'];
621+
if($this->dataRecord['subdomain'] == 'n') $this->dataRecord['subdomain'] = $tmp['subdomain'];
622+
if($this->dataRecord['ssl'] == 'n') $this->dataRecord['ssl'] = $tmp['ssl'];
623623

624624
unset($tmp);
625625
// When the record is inserted

interface/web/sites/web_vhost_subdomain_edit.php

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -394,15 +394,15 @@ function onSubmit() {
394394
$client_group_id = $app->functions->intval($_SESSION["s"]["user"]["default_group"]);
395395
$client = $app->db->queryOneRecord("SELECT limit_traffic_quota, limit_web_subdomain, default_webserver, parent_client_id, limit_web_quota, client." . implode(", client.", $read_limits) . " FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id");
396396

397-
if($client['limit_cgi'] != 'y') $this->dataRecord['cgi'] = '-';
398-
if($client['limit_ssi'] != 'y') $this->dataRecord['ssi'] = '-';
399-
if($client['limit_perl'] != 'y') $this->dataRecord['perl'] = '-';
400-
if($client['limit_ruby'] != 'y') $this->dataRecord['ruby'] = '-';
401-
if($client['limit_python'] != 'y') $this->dataRecord['python'] = '-';
397+
if($client['limit_cgi'] != 'y') $this->dataRecord['cgi'] = 'n';
398+
if($client['limit_ssi'] != 'y') $this->dataRecord['ssi'] = 'n';
399+
if($client['limit_perl'] != 'y') $this->dataRecord['perl'] = 'n';
400+
if($client['limit_ruby'] != 'y') $this->dataRecord['ruby'] = 'n';
401+
if($client['limit_python'] != 'y') $this->dataRecord['python'] = 'n';
402402
if($client['force_suexec'] == 'y') $this->dataRecord['suexec'] = 'y';
403-
if($client['limit_hterror'] != 'y') $this->dataRecord['errordocs'] = '-';
404-
if($client['limit_wildcard'] != 'y' && $this->dataRecord['subdomain'] == '*') $this->dataRecord['subdomain'] = '-';
405-
if($client['limit_ssl'] != 'y') $this->dataRecord['ssl'] = '-';
403+
if($client['limit_hterror'] != 'y') $this->dataRecord['errordocs'] = 'n';
404+
if($client['limit_wildcard'] != 'y' && $this->dataRecord['subdomain'] == '*') $this->dataRecord['subdomain'] = 'n';
405+
if($client['limit_ssl'] != 'y') $this->dataRecord['ssl'] = 'n';
406406

407407
// only generate quota and traffic warnings if value has changed
408408
if($this->id > 0) {
@@ -455,15 +455,15 @@ function onSubmit() {
455455
$this->dataRecord['web_folder'] = $tmp['web_folder']; // cannot be changed!
456456

457457
// set the settings to current if not provided (or cleared due to limits)
458-
if($this->dataRecord['cgi'] == '-') $this->dataRecord['cgi'] = $tmp['cgi'];
459-
if($this->dataRecord['ssi'] == '-') $this->dataRecord['ssi'] = $tmp['ssi'];
460-
if($this->dataRecord['perl'] == '-') $this->dataRecord['perl'] = $tmp['perl'];
461-
if($this->dataRecord['ruby'] == '-') $this->dataRecord['ruby'] = $tmp['ruby'];
462-
if($this->dataRecord['python'] == '-') $this->dataRecord['python'] = $tmp['python'];
463-
if($this->dataRecord['suexec'] == '-') $this->dataRecord['suexec'] = $tmp['suexec'];
464-
if($this->dataRecord['errordocs'] == '-') $this->dataRecord['errordocs'] = $tmp['errordocs'];
465-
if($this->dataRecord['subdomain'] == '-') $this->dataRecord['subdomain'] = $tmp['subdomain'];
466-
if($this->dataRecord['ssl'] == '-') $this->dataRecord['ssl'] = $tmp['ssl'];
458+
if($this->dataRecord['cgi'] == 'n') $this->dataRecord['cgi'] = $tmp['cgi'];
459+
if($this->dataRecord['ssi'] == 'n') $this->dataRecord['ssi'] = $tmp['ssi'];
460+
if($this->dataRecord['perl'] == 'n') $this->dataRecord['perl'] = $tmp['perl'];
461+
if($this->dataRecord['ruby'] == 'n') $this->dataRecord['ruby'] = $tmp['ruby'];
462+
if($this->dataRecord['python'] == 'n') $this->dataRecord['python'] = $tmp['python'];
463+
if($this->dataRecord['suexec'] == 'n') $this->dataRecord['suexec'] = $tmp['suexec'];
464+
if($this->dataRecord['errordocs'] == 'n') $this->dataRecord['errordocs'] = $tmp['errordocs'];
465+
if($this->dataRecord['subdomain'] == 'n') $this->dataRecord['subdomain'] = $tmp['subdomain'];
466+
if($this->dataRecord['ssl'] == 'n') $this->dataRecord['ssl'] = $tmp['ssl'];
467467

468468
unset($tmp);
469469
// When the record is inserted

0 commit comments

Comments
 (0)