From b95f7ed91a7c420ed99226e7b994bc212f26c296 Mon Sep 17 00:00:00 2001 From: Uwe Steinmann Date: Tue, 23 Jun 2015 07:44:47 +0200 Subject: [PATCH] new parameter overrideMimeType --- inc/inc.ClassSettings.php | 4 ++++ op/op.Settings.php | 1 + views/bootstrap/class.Settings.php | 4 ++++ 3 files changed, 9 insertions(+) diff --git a/inc/inc.ClassSettings.php b/inc/inc.ClassSettings.php index faaa56f0b..f058b559d 100644 --- a/inc/inc.ClassSettings.php +++ b/inc/inc.ClassSettings.php @@ -127,6 +127,8 @@ class Settings { /* {{{ */ var $_enableVersionModification = false; // enable/disable duplicate names of a document in a folder var $_enableDuplicateDocNames = true; + // override mimetype set by browser when uploading a file + var $_overrideMimeType = false; // enable/disable notification when added as a reviewer/approver var $_enableNotificationAppRev = true; // enable/disable notification of users/group who need to take action for @@ -509,6 +511,7 @@ class Settings { /* {{{ */ $this->_enableVersionDeletion = Settings::boolval($tab["enableVersionDeletion"]); $this->_enableVersionModification = Settings::boolval($tab["enableVersionModification"]); $this->_enableDuplicateDocNames = Settings::boolval($tab["enableDuplicateDocNames"]); + $this->_overrideMimeType = Settings::boolval($tab["overrideMimeType"]); // XML Path: /configuration/advanced/notification $node = $xml->xpath('/configuration/advanced/notification'); @@ -785,6 +788,7 @@ class Settings { /* {{{ */ $this->setXMLAttributValue($node, "enableVersionDeletion", $this->_enableVersionDeletion); $this->setXMLAttributValue($node, "enableVersionModification", $this->_enableVersionModification); $this->setXMLAttributValue($node, "enableDuplicateDocNames", $this->_enableDuplicateDocNames); + $this->setXMLAttributValue($node, "overrideMimeType", $this->_overrideMimeType); // XML Path: /configuration/advanced/notification $node = $this->getXMLNode($xml, '/configuration/advanced', 'notification'); diff --git a/op/op.Settings.php b/op/op.Settings.php index 34bac533e..32a7803ff 100644 --- a/op/op.Settings.php +++ b/op/op.Settings.php @@ -158,6 +158,7 @@ if ($action == "saveSettings") $settings->_enableVersionDeletion = getBoolValue("enableVersionDeletion"); $settings->_enableVersionModification = getBoolValue("enableVersionModification"); $settings->_enableDuplicateDocNames = getBoolValue("enableDuplicateDocNames"); + $settings->_overrideMimeType = getBoolValue("overrideMimeType"); // SETTINGS - ADVANCED - NOTIFICATION $settings->_enableOwnerNotification = getBoolValue("enableOwnerNotification"); diff --git a/views/bootstrap/class.Settings.php b/views/bootstrap/class.Settings.php index 2bcb53478..282f92fc0 100644 --- a/views/bootstrap/class.Settings.php +++ b/views/bootstrap/class.Settings.php @@ -545,6 +545,10 @@ if(!is_writeable($settings->_configFilePath)) { : _enableDuplicateDocNames) echo "checked" ?> /> + "> + : + _overrideMimeType) echo "checked" ?> /> +