mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-03-11 16:35:38 +00:00
- missing files for new configuration tool
This commit is contained in:
parent
1a9e46397f
commit
9c0e2220af
198
conf/settings.xml.template
Normal file
198
conf/settings.xml.template
Normal file
|
@ -0,0 +1,198 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<configuration>
|
||||
<site>
|
||||
<!-- siteName: Name of site used in the page titles. Default: letoDMS
|
||||
- footNote: Message to display at the bottom of every page
|
||||
- printDisclaimer: if true the disclaimer message the lang.inc files will be print on the bottom of the page
|
||||
- language: default language (name of a subfolder in folder "languages")
|
||||
- theme: default style (name of a subfolder in folder "styles")
|
||||
-->
|
||||
<display
|
||||
siteName = "letoDMS"
|
||||
footNote = "letoDMS free document management system - www.letodms.com"
|
||||
printDisclaimer="true"
|
||||
language = "English"
|
||||
theme = "clean"
|
||||
>
|
||||
</display>
|
||||
<!-- strictFormCheck: Strict form checking. If set to true, then all fields in the form will be checked for a value. If set to false, then (most) comments and keyword fields become optional. Comments are always required when submitting a review or overriding document status.
|
||||
- viewOnlineFileTypes: files with one of the following endings can be viewed online (USE ONLY LOWER CASE CHARACTERS)
|
||||
- enableConverting: enable/disable converting of files
|
||||
- enableEmail: enable/disable automatic email notification
|
||||
- enableUsersView: enable/disable group and user view for all users
|
||||
- enableFolderTree: false to don't show the folder tree
|
||||
- expandFolderTree: 0 to start with tree hidden
|
||||
- 1 to start with tree shown and first level expanded
|
||||
- 2 to start with tree shown fully expanded
|
||||
-->
|
||||
<edition
|
||||
strictFormCheck = "false"
|
||||
viewOnlineFileTypes = ".txt;.text;.html;.htm;.pdf;.gif;.png;.jpg;.jpeg"
|
||||
enableConverting = "true"
|
||||
enableEmail = "true"
|
||||
enableUsersView = "true"
|
||||
enableFolderTree = "true"
|
||||
expandFolderTree = "1"
|
||||
|
||||
>
|
||||
</edition>
|
||||
<!-- enableCalendar: enable/disable calendar
|
||||
- calendarDefaultView: calendar default view ("w" for week,"m" for month,"y" for year)
|
||||
- firstDayOfWeek: first day of the week (0=sunday, 6=saturday)
|
||||
-->
|
||||
<calendar
|
||||
enableCalendar = "true"
|
||||
calendarDefaultView = "y"
|
||||
firstDayOfWeek = "0"
|
||||
>
|
||||
</calendar>
|
||||
</site>
|
||||
|
||||
<system>
|
||||
<!-- rootDir: Path to where letoDMS is located
|
||||
- httpRoot: The relative path in the URL, after the domain part. Do not include the
|
||||
- http:// prefix or the web host name. e.g. If the full URL is
|
||||
- http://www.example.com/letodms/, set $_httpRoot = "/letodms/".
|
||||
- If the URL is http://www.example.com/, set $_httpRoot = "/".
|
||||
- contentDir: Where the uploaded files are stored (best to choose a directory that
|
||||
- is not accessible through your web-server)
|
||||
- logFileEnable: set false to disable log system
|
||||
- logFileRotation: the log file rotation (h=hourly, d=daily, m=monthly)
|
||||
-->
|
||||
<server
|
||||
rootDir = ""
|
||||
httpRoot = "/letodms/"
|
||||
contentDir = ""
|
||||
logFileEnable = "true"
|
||||
logFileRotation = "d"
|
||||
>
|
||||
</server>
|
||||
|
||||
<!-- enableGuestLogin: If you want anybody to login as guest, set the following line to true
|
||||
- note: guest login should be used only in a trusted environment
|
||||
- restricted: Restricted access: only allow users to log in if they have an entry in the local database (irrespective of successful authentication with LDAP).
|
||||
- enableUserImage: enable users images
|
||||
- disableSelfEdit: if true user cannot edit his own profile
|
||||
-->
|
||||
<authentication
|
||||
enableGuestLogin = "false"
|
||||
restricted = "true"
|
||||
enableUserImage = "false"
|
||||
disableSelfEdit = "false"
|
||||
>
|
||||
<connectors>
|
||||
<!-- ***** CONNECTOR LDAP *****
|
||||
- enable: enable/disable connector
|
||||
- type: type of connector ldap / AD
|
||||
- host: hostname of the authentification server
|
||||
- URIs are supported, e.g.: ldaps://ldap.host.com
|
||||
- port: port of the authentification server
|
||||
- baseDN: top level of the LDAP directory tree
|
||||
-->
|
||||
<connector
|
||||
enable = "false"
|
||||
type = "ldap"
|
||||
host = "ldaps://ldap.host.com"
|
||||
port = "389"
|
||||
baseDN = ""
|
||||
>
|
||||
</connector>
|
||||
<!-- ***** CONNECTOR Microsoft Active Directory *****
|
||||
- enable: enable/disable connector
|
||||
- type: type of connector ldap / AD
|
||||
- host: hostname of the authentification server
|
||||
- port: port of the authentification server
|
||||
- baseDN: top level of the LDAP directory tree
|
||||
- accountDomainName: sample: example.com
|
||||
-->
|
||||
<connector
|
||||
enable = "false"
|
||||
type = "AD"
|
||||
host = "ldap.example.com"
|
||||
port = "389"
|
||||
baseDN = ""
|
||||
accountDomainName = "example.com"
|
||||
>
|
||||
</connector>
|
||||
</connectors>
|
||||
</authentication>
|
||||
<!-- ADOdbPath: Path to adodb. This is the directory containing the adodb directory
|
||||
- dbDriver: DB-Driver used by adodb (see adodb-readme)
|
||||
- dbHostname: DB-Server
|
||||
- dbDatabase: database where the tables for letodms are stored (optional - see adodb-readme)
|
||||
- dbUser: username for database-access
|
||||
- dbPass: password for database-access
|
||||
-->
|
||||
<database
|
||||
ADOdbPath = ""
|
||||
dbDriver = "mysql"
|
||||
dbHostname = "localhost"
|
||||
dbDatabase = "letodms"
|
||||
dbUser = "letodms"
|
||||
dbPass = "letodms"
|
||||
>
|
||||
</database>
|
||||
<!-- smtpServer: SMTP Server hostname
|
||||
- smtpPort: SMTP Server port
|
||||
- smtpSendFrom: Send from
|
||||
-->
|
||||
<smtp
|
||||
smtpServer = "localhost"
|
||||
smtpPort = "25"
|
||||
smtpSendFrom = "letodms@localhost"
|
||||
/>
|
||||
</system>
|
||||
|
||||
|
||||
<advanced>
|
||||
<!-- siteDefaultPage: Default page on login. Defaults to out/out.ViewFolder.php
|
||||
- rootFolderID: ID of root-folder (mostly no need to change)
|
||||
- titleDisplayHack: Workaround for page titles that go over more than 2 lines.
|
||||
-->
|
||||
<display
|
||||
siteDefaultPage =""
|
||||
rootFolderID = "1"
|
||||
titleDisplayHack = "true"
|
||||
|
||||
>
|
||||
</display>
|
||||
<!-- guestID: ID of guest-user used when logged in as guest (mostly no need to change)
|
||||
- adminIP: if enabled admin can login only by specified IP addres, leave empty to avoid the control
|
||||
- NOTE: works only with local autentication (no LDAP)
|
||||
-->
|
||||
<authentication
|
||||
guestID = "2"
|
||||
adminIP = ""
|
||||
>
|
||||
</authentication>
|
||||
<!-- enableAdminRevApp: false to don't list administrator as reviewer/approver
|
||||
- versioningFileName: the name of the versioning info file created by the backup tool
|
||||
-->
|
||||
<edition
|
||||
enableAdminRevApp = "false"
|
||||
versioningFileName = "versioning_info.txt"
|
||||
>
|
||||
</edition>
|
||||
<!-- coreDir: Path to LetoDMS_Core (optional)
|
||||
- contentOffsetDir: To work around limitations in the underlying file system, a new
|
||||
- directory structure has been devised that exists within the content
|
||||
- directory ($_contentDir). This requires a base directory from which
|
||||
- to begin. Usually leave this to the default setting, 1048576, but can
|
||||
- be any number or string that does not already exist within $_contentDir.
|
||||
- maxDirID: Maximum number of sub-directories per parent directory. Default: 32700.
|
||||
- updateNotifyTime: users are notified about document-changes that took place within the last "updateNotifyTime" seconds
|
||||
-->
|
||||
<server
|
||||
coreDir = ""
|
||||
contentOffsetDir = "1048576"
|
||||
maxDirID = "32700"
|
||||
updateNotifyTime = "86400"
|
||||
>
|
||||
</server>
|
||||
|
||||
</advanced>
|
||||
|
||||
</configuration>
|
||||
|
||||
|
||||
|
134
op/op.Settings.php
Normal file
134
op/op.Settings.php
Normal file
|
@ -0,0 +1,134 @@
|
|||
<?php
|
||||
// MyDMS. Document Management System
|
||||
// Copyright (C) 2002-2005 Markus Westphal
|
||||
// Copyright (C) 2006-2008 Malcolm Cowe
|
||||
// Copyright (C) 2010 Matteo Lucarelli
|
||||
//
|
||||
// This program is free software; you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation; either version 2 of the License, or
|
||||
// (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with this program; if not, write to the Free Software
|
||||
// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
|
||||
include("../inc/inc.Settings.php");
|
||||
include("../inc/inc.Utils.php");
|
||||
include("../inc/inc.DBInit.php");
|
||||
include("../inc/inc.Language.php");
|
||||
include("../inc/inc.ClassUI.php");
|
||||
include("../inc/inc.Authentication.php");
|
||||
|
||||
|
||||
function getBoolValue($post_name)
|
||||
{
|
||||
$out = false;
|
||||
if (isset($_POST[$post_name]))
|
||||
if ($_POST[$post_name]=="on")
|
||||
$out = true;
|
||||
|
||||
return $out;
|
||||
}
|
||||
|
||||
if (!$user->isAdmin()) {
|
||||
UI::exitError(getMLText("admin_tools"),getMLText("access_denied"));
|
||||
}
|
||||
|
||||
if (isset($_POST["action"])) $action=$_POST["action"];
|
||||
else if (isset($_GET["action"])) $action=$_GET["action"];
|
||||
else $action=NULL;
|
||||
|
||||
// --------------------------------------------------------------------------
|
||||
if ($action == "saveSettings")
|
||||
{
|
||||
// -------------------------------------------------------------------------
|
||||
// get values
|
||||
// -------------------------------------------------------------------------
|
||||
// SETTINGS - SITE - DISPLAY
|
||||
$settings->_siteName = $_POST["siteName"];
|
||||
$settings->_footNote = $_POST["footNote"];
|
||||
$settings->_printDisclaimer = getBoolValue("printDisclaimer");
|
||||
$settings->_language = $_POST["language"];
|
||||
$settings->_theme = $_POST["theme"];
|
||||
|
||||
// SETTINGS - SITE - EDITION
|
||||
$settings->_strictFormCheck = getBoolValue("strictFormCheck");
|
||||
$settings->setViewOnlineFileTypesFromString($_POST["viewOnlineFileTypes"]);
|
||||
$settings->_enableConverting = getBoolValue("enableConverting");
|
||||
$settings->_enableEmail =getBoolValue("enableEmail");
|
||||
$settings->_enableUsersView = getBoolValue("enableUsersView");
|
||||
$settings->_enableFolderTree = getBoolValue("enableFolderTree");
|
||||
$settings->_expandFolderTree = intval($_POST["expandFolderTree"]);
|
||||
|
||||
// SETTINGS - SITE - CALENDAR
|
||||
$settings->_enableCalendar = getBoolValue("enableCalendar");
|
||||
$settings->_calendarDefaultView = $_POST["calendarDefaultView"];
|
||||
$settings->_firstDayOfWeek = intval($_POST["firstDayOfWeek"]);
|
||||
|
||||
// SETTINGS - SYSTEM - SERVER
|
||||
$settings->_rootDir = $_POST["rootDir"];
|
||||
$settings->_httpRoot = $_POST["httpRoot"];
|
||||
$settings->_contentDir = $_POST["contentDir"];
|
||||
$settings->_logFileEnable = getBoolValue("logFileEnable");
|
||||
$settings->_logFileRotation = $_POST["logFileRotation"];
|
||||
|
||||
// SETTINGS - SYSTEM - AUTHENTICATION
|
||||
$settings->_enableGuestLogin = getBoolValue("enableGuestLogin");
|
||||
$settings->_restricted = getBoolValue("restricted");
|
||||
$settings->_enableUserImage = getBoolValue("enableUserImage");
|
||||
$settings->_disableSelfEdit = getBoolValue("disableSelfEdit");
|
||||
|
||||
// TODO Connectors
|
||||
|
||||
// SETTINGS - SYSTEM - DATABASE
|
||||
$settings->_ADOdbPath = $_POST["ADOdbPath"];
|
||||
$settings->_dbDriver = $_POST["dbDriver"];
|
||||
$settings->_dbHostname = $_POST["dbHostname"];
|
||||
$settings->_dbDatabase = $_POST["dbDatabase"];
|
||||
$settings->_dbUser = $_POST["dbUser"];
|
||||
$settings->_dbPass = $_POST["dbPass"];
|
||||
|
||||
// SETTINGS - SYSTEM - SMTP
|
||||
$settings->_smtpServer = $_POST["smtpServer"];
|
||||
$settings->_smtpPort = $_POST["smtpPort"];
|
||||
$settings->_smtpSendFrom = $_POST["smtpSendFrom"];
|
||||
|
||||
// SETTINGS -ADVANCED - DISPLAY
|
||||
$settings->_siteDefaultPage = $_POST["siteDefaultPage"];
|
||||
$settings->_rootFolderID = intval($_POST["rootFolderID"]);
|
||||
$settings->_titleDisplayHack = getBoolValue("titleDisplayHack");
|
||||
|
||||
// SETTINGS - ADVANCED - AUTHENTICATION
|
||||
$settings->_guestID = intval($_POST["guestID"]);
|
||||
$settings->_adminIP = $_POST["adminIP"];
|
||||
|
||||
// SETTINGS - ADVANCED - EDITION
|
||||
$settings->_versioningFileName = $_POST["versioningFileName"];
|
||||
$settings->_enableAdminRevApp = getBoolValue("enableAdminRevApp");
|
||||
|
||||
// SETTINGS - ADVANCED - SERVER
|
||||
$settings->_coreDir = $_POST["coreDir"];
|
||||
$settings->_contentOffsetDir = intval($_POST["contentOffsetDir"]);
|
||||
$settings->_maxDirID = intval($_POST["maxDirID"]);
|
||||
$settings->_updateNotifyTime = intval($_POST["updateNotifyTime"]);
|
||||
$settings->_maxExecutionTime = intval($_POST["maxExecutionTime"]);
|
||||
|
||||
// -------------------------------------------------------------------------
|
||||
// save
|
||||
// -------------------------------------------------------------------------
|
||||
if (!$settings->save())
|
||||
UI::exitError(getMLText("admin_tools"),getMLText("settings_SaveError"));
|
||||
|
||||
add_log_line(".php&action=savesettings");
|
||||
}
|
||||
|
||||
|
||||
header("Location:../out/out.AdminTools.php");
|
||||
|
||||
?>
|
Loading…
Reference in New Issue
Block a user