mirror of
https://github.com/SuiteCRM/SuiteCRM-Core.git
synced 2025-09-13 00:42:08 +08:00
Merge commit '8e4cc94994
' as 'public/legacy'
This commit is contained in:
commit
11be803da2
9769 changed files with 1617695 additions and 0 deletions
194
public/legacy/install/TeamDemoData.php
Executable file
194
public/legacy/install/TeamDemoData.php
Executable file
|
@ -0,0 +1,194 @@
|
|||
<?php
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
class TeamDemoData
|
||||
{
|
||||
public $_team;
|
||||
public $_large_scale_test;
|
||||
|
||||
public $guids = array(
|
||||
'jim' => 'seed_jim_id',
|
||||
'sarah' => 'seed_sarah_id',
|
||||
'sally' => 'seed_sally_id',
|
||||
'max' => 'seed_max_id',
|
||||
'will' => 'seed_will_id',
|
||||
'chris' => 'seed_chris_id',
|
||||
/*
|
||||
* Pending fix of demo data mechanism
|
||||
'jim' => 'jim00000-0000-0000-0000-000000000000',
|
||||
'sarah' => 'sarah000-0000-0000-0000-000000000000',
|
||||
'sally' => 'sally000-0000-0000-0000-000000000000',
|
||||
'max' => 'max00000-0000-0000-0000-000000000000',
|
||||
'will' => 'will0000-0000-0000-0000-000000000000',
|
||||
'chris' => 'chris000-0000-0000-0000-000000000000',
|
||||
*/
|
||||
);
|
||||
|
||||
/**
|
||||
* Constructor for creating demo data for teams
|
||||
*/
|
||||
public function __construct($seed_team, $large_scale_test = false)
|
||||
{
|
||||
$this->_team = $seed_team;
|
||||
$this->_large_scale_test = $large_scale_test;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public function create_demo_data()
|
||||
{
|
||||
global $current_language;
|
||||
global $sugar_demodata;
|
||||
foreach ($sugar_demodata['teams'] as $v) {
|
||||
if (!$this->_team->retrieve($v['team_id'])) {
|
||||
$this->_team->create_team($v['name'], $v['description'], $v['team_id']);
|
||||
}
|
||||
}
|
||||
|
||||
if ($this->_large_scale_test) {
|
||||
$team_list = $this->_seed_data_get_team_list();
|
||||
foreach ($team_list as $team_name) {
|
||||
$this->_quick_create($team_name);
|
||||
}
|
||||
}
|
||||
|
||||
$this->add_users_to_team();
|
||||
}
|
||||
|
||||
public function add_users_to_team()
|
||||
{
|
||||
// Create the west team memberships
|
||||
$this->_team->retrieve("West");
|
||||
$this->_team->add_user_to_team($this->guids['sarah']);
|
||||
$this->_team->add_user_to_team($this->guids['sally']);
|
||||
$this->_team->add_user_to_team($this->guids["max"]);
|
||||
|
||||
// Create the east team memberships
|
||||
$this->_team->retrieve("East");
|
||||
$this->_team->add_user_to_team($this->guids["will"]);
|
||||
$this->_team->add_user_to_team($this->guids['chris']);
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public function get_random_team()
|
||||
{
|
||||
$team_list = $this->_seed_data_get_team_list();
|
||||
$team_list_size = count($team_list);
|
||||
$random_index = mt_rand(0, $team_list_size-1);
|
||||
|
||||
return $team_list[$random_index];
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public function get_random_teamset()
|
||||
{
|
||||
$team_list = $this->_seed_data_get_teamset_list();
|
||||
$team_list_size = count($team_list);
|
||||
$random_index = mt_rand(0, $team_list_size-1);
|
||||
|
||||
return $team_list[$random_index];
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public function _seed_data_get_teamset_list()
|
||||
{
|
||||
$teamsets = array();
|
||||
$teamsets[] = array("East", "West");
|
||||
$teamsets[] = array("East", "West", "1");
|
||||
$teamsets[] = array("West", "East");
|
||||
$teamsets[] = array("West", "East", "1");
|
||||
$teamsets[] = array("1", "East");
|
||||
$teamsets[] = array("1", "West");
|
||||
return $teamsets;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public function _seed_data_get_team_list()
|
||||
{
|
||||
$teams = array();
|
||||
//bug 28138 todo
|
||||
$teams[] = "north";
|
||||
$teams[] = "south";
|
||||
$teams[] = "left";
|
||||
$teams[] = "right";
|
||||
$teams[] = "in";
|
||||
$teams[] = "out";
|
||||
$teams[] = "fly";
|
||||
$teams[] = "walk";
|
||||
$teams[] = "crawl";
|
||||
$teams[] = "pivot";
|
||||
$teams[] = "money";
|
||||
$teams[] = "dinero";
|
||||
$teams[] = "shadow";
|
||||
$teams[] = "roof";
|
||||
$teams[] = "sales";
|
||||
$teams[] = "pillow";
|
||||
$teams[] = "feather";
|
||||
|
||||
return $teams;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public function _quick_create($name)
|
||||
{
|
||||
if (!$this->_team->retrieve($name)) {
|
||||
$this->_team->create_team($name, $name, $name);
|
||||
}
|
||||
}
|
||||
}
|
93
public/legacy/install/UploadLangFileCheck.php
Executable file
93
public/legacy/install/UploadLangFileCheck.php
Executable file
|
@ -0,0 +1,93 @@
|
|||
<?php
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
//Request object must have these property values:
|
||||
// Module: module name, this module should have a file called TreeData.php
|
||||
// Function: name of the function to be called in TreeData.php, the function will be called statically.
|
||||
// PARAM prefixed properties: array of these property/values will be passed to the function as parameter.
|
||||
|
||||
require_once('include/JSON.php');
|
||||
require_once('include/upload_file.php');
|
||||
|
||||
//require_once('modules/UpgradeWizard/uw_utils.php');
|
||||
|
||||
$json = getJSONobj();
|
||||
/*
|
||||
$file_name = $json->decode(html_entity_decode($_REQUEST['file_name']));
|
||||
|
||||
if(isset($file_name['jsonObject']) && $file_name['jsonObject'] != null){
|
||||
$file_name = $file_name['jsonObject'];
|
||||
}
|
||||
*/
|
||||
|
||||
$file_name = $_REQUEST['file_name'];
|
||||
$filesize = '';
|
||||
if (file_exists($file_name)) {
|
||||
$filesize =filesize($file_name);
|
||||
}
|
||||
|
||||
//$GLOBALS['log']->fatal($file_name);
|
||||
$response = '';
|
||||
|
||||
//$GLOBALS['log']->fatal('file name '.$file_name);
|
||||
//$GLOBALS['log']->fatal('file size loaded '.filesize($file_name));
|
||||
|
||||
|
||||
//if($filesize > ini_get("upload_max_filesize"))
|
||||
|
||||
//$GLOBALS['log']->fatal(substr(ini_get("upload_max_filesize"), 0, strlen( ini_get("upload_max_filesize")) - 1));
|
||||
//get the file size defined in php.ini
|
||||
//$uploadSizeIni = substr(ini_get("upload_max_filesize"), 0, strlen( ini_get("upload_max_filesize")) - 1);
|
||||
//$GLOBALS['log']->fatal('Upload php setting Size '.return_bytes(ini_get("upload_max_filesize")));
|
||||
if ($filesize != null) {
|
||||
if (($filesize > return_bytes(ini_get("upload_max_filesize"))) || ($filesize > return_bytes(ini_get("post_max_size")))) {
|
||||
$response=$filesize;
|
||||
//$response= "<script>alert('File size is bigger than the max_upload-size setting in php.ini. Upgrade attempt will fail. Increase the upload_max_size in php.ini to greater than ')</script>";
|
||||
}
|
||||
}
|
||||
|
||||
if (!empty($response)) {
|
||||
echo $response;
|
||||
}
|
||||
sugar_cleanup();
|
||||
exit();
|
186
public/legacy/install/UserDemoData.php
Executable file
186
public/legacy/install/UserDemoData.php
Executable file
|
@ -0,0 +1,186 @@
|
|||
<?php
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
|
||||
class UserDemoData
|
||||
{
|
||||
public $_user;
|
||||
public $_large_scale_test;
|
||||
public $guids = array(
|
||||
'jim' => 'seed_jim_id',
|
||||
'sarah' => 'seed_sarah_id',
|
||||
'sally' => 'seed_sally_id',
|
||||
'max' => 'seed_max_id',
|
||||
'will' => 'seed_will_id',
|
||||
'chris' => 'seed_chris_id',
|
||||
/*
|
||||
* Pending fix of demo data mechanism
|
||||
'jim' => 'jim00000-0000-0000-0000-000000000000',
|
||||
'sarah' => 'sarah000-0000-0000-0000-000000000000',
|
||||
'sally' => 'sally000-0000-0000-0000-000000000000',
|
||||
'max' => 'max00000-0000-0000-0000-000000000000',
|
||||
'will' => 'will0000-0000-0000-0000-000000000000',
|
||||
'chris' => 'chris000-0000-0000-0000-000000000000',
|
||||
*/
|
||||
);
|
||||
|
||||
/**
|
||||
* Constructor for creating user demo data
|
||||
*/
|
||||
public function __construct($seed_user, $large_scale_test = false)
|
||||
{
|
||||
// use a seed user so it does not have to be known which file to
|
||||
// include the User class from
|
||||
$this->_user = $seed_user;
|
||||
$this->_large_scale_test = $large_scale_test;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public function create_demo_data()
|
||||
{
|
||||
global $current_language;
|
||||
global $sugar_demodata;
|
||||
foreach ($sugar_demodata['users'] as $v) {
|
||||
$this->_create_seed_user($v['id'], $v['last_name'], $v['first_name'], $v['user_name'], $v['title'], $v['is_admin'], $v['reports_to'], $v['reports_to_name'], $v['email']);
|
||||
}
|
||||
if ($this->_large_scale_test) {
|
||||
$user_list = $this->_seed_data_get_user_list();
|
||||
foreach ($user_list as $user_name) {
|
||||
$this->_quick_create_user($user_name);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Create a user in the seed data.
|
||||
*/
|
||||
public function _create_seed_user(
|
||||
$id,
|
||||
$last_name,
|
||||
$first_name,
|
||||
$user_name,
|
||||
$title,
|
||||
$is_admin,
|
||||
$reports_to,
|
||||
$reports_to_name,
|
||||
$email
|
||||
) {
|
||||
$u = BeanFactory::newBean('Users');
|
||||
|
||||
$u->id=$id;
|
||||
$u->new_with_id = true;
|
||||
$u->last_name = $last_name;
|
||||
$u->first_name = $first_name;
|
||||
$u->user_name = $user_name;
|
||||
$u->title = $title;
|
||||
$u->status = 'Active';
|
||||
$u->employee_status = 'Active';
|
||||
$u->is_admin = $is_admin;
|
||||
$u->user_hash = User::getPasswordHash($user_name);
|
||||
$u->reports_to_id = $reports_to;
|
||||
$u->reports_to_name = $reports_to_name;
|
||||
$u->emailAddress->addAddress($email, true);
|
||||
$u->emailAddress->addAddress("reply.".$email, false, true);
|
||||
$u->emailAddress->addAddress("alias.".$email);
|
||||
|
||||
// bug 15371 tyoung set a user preference so that Users/DetailView.php can find something without repeatedly querying the db in vain
|
||||
$u->setPreference('max_tabs', '7');
|
||||
$u->savePreferencesToDB();
|
||||
|
||||
$u->save();
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public function _seed_data_get_user_list()
|
||||
{
|
||||
$users = array();
|
||||
//bug 28138 todo
|
||||
$users[] = "north";
|
||||
$users[] = "south";
|
||||
$users[] = "east";
|
||||
$users[] = "west";
|
||||
$users[] = "left";
|
||||
$users[] = "right";
|
||||
$users[] = "in";
|
||||
$users[] = "out";
|
||||
$users[] = "fly";
|
||||
$users[] = "walk";
|
||||
$users[] = "crawl";
|
||||
$users[] = "pivot";
|
||||
$users[] = "money";
|
||||
$users[] = "dinero";
|
||||
$users[] = "shadow";
|
||||
$users[] = "roof";
|
||||
$users[] = "sales";
|
||||
$users[] = "pillow";
|
||||
$users[] = "feather";
|
||||
|
||||
return $users;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public function _quick_create_user($name)
|
||||
{
|
||||
global $sugar_demodata;
|
||||
if (!$this->_user->retrieve($name.'_id')) {
|
||||
$this->_create_seed_user(
|
||||
"{$name}_id",
|
||||
$name,
|
||||
$name,
|
||||
$name,
|
||||
$sugar_demodata['users'][0]['title'],
|
||||
$sugar_demodata['users'][0]['is_admin'],
|
||||
"seed_jim_id",
|
||||
$sugar_demodata['users'][0]['last_name'].", ".$sugar_demodata['users'][0]['first_name'],
|
||||
$sugar_demodata['users'][0]['email']
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
392
public/legacy/install/checkDBSettings.php
Executable file
392
public/legacy/install/checkDBSettings.php
Executable file
|
@ -0,0 +1,392 @@
|
|||
<?php
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
function checkDBSettings($silent=false)
|
||||
{
|
||||
installLog("Begin DB Check Process *************");
|
||||
global $mod_strings;
|
||||
$errors = array();
|
||||
copyInputsIntoSession();
|
||||
|
||||
$db = getInstallDbInstance();
|
||||
|
||||
installLog("testing with {$db->dbType}:{$db->variant}");
|
||||
|
||||
|
||||
if (trim($_SESSION['setup_db_database_name']) == '') {
|
||||
$errors['ERR_DB_NAME'] = $mod_strings['ERR_DB_NAME'];
|
||||
installLog("ERROR:: {$errors['ERR_DB_NAME']}");
|
||||
}
|
||||
|
||||
|
||||
if (!$db->isDatabaseNameValid($_SESSION['setup_db_database_name'])) {
|
||||
$errIdx = 'ERR_DB_' . strtoupper($_SESSION['setup_db_type']) . '_DB_NAME_INVALID';
|
||||
$errors[$errIdx] = $mod_strings[$errIdx];
|
||||
installLog("ERROR:: {$errors[$errIdx]}");
|
||||
}
|
||||
|
||||
if ($_SESSION['setup_db_type'] != 'oci8') {
|
||||
// Oracle doesn't need host name, others do
|
||||
if (trim($_SESSION['setup_db_host_name']) == '') {
|
||||
$errors['ERR_DB_HOSTNAME'] = $mod_strings['ERR_DB_HOSTNAME'];
|
||||
installLog("ERROR:: {$errors['ERR_DB_HOSTNAME']}");
|
||||
}
|
||||
}
|
||||
|
||||
//check to see that password and retype are same, if needed
|
||||
if (!empty($_SESSION['dbUSRData']) && ($_SESSION['dbUSRData']=='create' || $_SESSION['dbUSRData']=='provide')) {
|
||||
if ($_SESSION['setup_db_sugarsales_password'] != $_SESSION['setup_db_sugarsales_password_retype']) {
|
||||
$errors['ERR_DBCONF_PASSWORD_MISMATCH'] = $mod_strings['ERR_DBCONF_PASSWORD_MISMATCH'];
|
||||
installLog("ERROR:: {$errors['ERR_DBCONF_PASSWORD_MISMATCH']}");
|
||||
}
|
||||
}
|
||||
|
||||
// bail if the basic info isn't valid
|
||||
if (count($errors) > 0) {
|
||||
installLog("Basic form info is INVALID, exit Process.");
|
||||
return printErrors($errors);
|
||||
} else {
|
||||
installLog("Basic form info is valid, continuing Process.");
|
||||
}
|
||||
|
||||
$dbconfig = array(
|
||||
"db_host_name" => $_SESSION['setup_db_host_name'],
|
||||
"db_host_instance" => isset($_SESSION['setup_db_host_instance']) ? $_SESSION['setup_db_host_instance'] : null,
|
||||
);
|
||||
|
||||
if (!empty($_SESSION['setup_db_port_num'])) {
|
||||
$dbconfig["db_port"] = $_SESSION['setup_db_port_num'];
|
||||
} else {
|
||||
$_SESSION['setup_db_port_num'] = '';
|
||||
}
|
||||
|
||||
// Needed for database implementation that do not allow connections to the server directly
|
||||
// and that typically require the manual setup of a database instances such as DB2
|
||||
if (empty($_SESSION['setup_db_create_database'])) {
|
||||
$dbconfig["db_name"] = $_SESSION['setup_db_database_name'];
|
||||
}
|
||||
|
||||
// check database name validation in different database types (default is mssql)
|
||||
switch (strtolower($db->dbType)) {
|
||||
|
||||
case 'mysql':
|
||||
if (preg_match("![/\\.]+!i", $_SESSION['setup_db_database_name'])) {
|
||||
$errors['ERR_DB_MYSQL_DB_NAME'] = $mod_strings['ERR_DB_MYSQL_DB_NAME_INVALID'];
|
||||
installLog("ERROR:: {$errors['ERR_DB_MYSQL_DB_NAME']}");
|
||||
}
|
||||
break;
|
||||
|
||||
case 'mssql':
|
||||
default:
|
||||
// Bug 29855 - Check to see if given db name is valid
|
||||
if (preg_match("![\"'*/\\?:<>-]+!i", $_SESSION['setup_db_database_name'])) {
|
||||
$errors['ERR_DB_MSSQL_DB_NAME'] = $mod_strings['ERR_DB_MSSQL_DB_NAME_INVALID'];
|
||||
installLog("ERROR:: {$errors['ERR_DB_MSSQL_DB_NAME']}");
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
// test the account that will talk to the db if we're not creating it
|
||||
if ($_SESSION['setup_db_sugarsales_user'] != '' && !$_SESSION['setup_db_create_sugarsales_user']) {
|
||||
$dbconfig["db_user_name"] = $_SESSION['setup_db_sugarsales_user'];
|
||||
$dbconfig["db_password"] = $_SESSION['setup_db_sugarsales_password'];
|
||||
installLog("Testing user account...");
|
||||
|
||||
// try connecting to the DB
|
||||
if (!$db->connect($dbconfig, false)) {
|
||||
$error = $db->lastError();
|
||||
$errors['ERR_DB_LOGIN_FAILURE'] = $mod_strings['ERR_DB_LOGIN_FAILURE'];
|
||||
installLog("ERROR:: {$errors['ERR_DB_LOGIN_FAILURE']}");
|
||||
} else {
|
||||
installLog("Connection made using host: {$_SESSION['setup_db_host_name']}, usr: {$_SESSION['setup_db_sugarsales_user']}");
|
||||
$db->disconnect();
|
||||
}
|
||||
}
|
||||
|
||||
// privileged account tests
|
||||
else {
|
||||
if (empty($_SESSION['setup_db_admin_user_name'])) {
|
||||
$errors['ERR_DB_PRIV_USER'] = $mod_strings['ERR_DB_PRIV_USER'];
|
||||
installLog("ERROR:: {$errors['ERR_DB_PRIV_USER']}");
|
||||
} else {
|
||||
installLog("Testing priviliged account...");
|
||||
$dbconfig["db_user_name"] = $_SESSION['setup_db_admin_user_name'];
|
||||
$dbconfig["db_password"] = $_SESSION['setup_db_admin_password'];
|
||||
if (!$db->connect($dbconfig, false)) {
|
||||
$error = $db->lastError();
|
||||
$errors['ERR_DB_LOGIN_FAILURE'] = $mod_strings['ERR_DB_LOGIN_FAILURE'];
|
||||
installLog("ERROR:: {$errors['ERR_DB_LOGIN_FAILURE']}");
|
||||
} else {
|
||||
installLog("Connection made using host: {$_SESSION['setup_db_host_name']}, usr: {$_SESSION['setup_db_sugarsales_user']}");
|
||||
$db_selected = $db->dbExists($_SESSION['setup_db_database_name']);
|
||||
if ($silent==false && $db_selected && $_SESSION['setup_db_create_database'] && empty($_SESSION['setup_db_drop_tables'])) {
|
||||
// DB exists but user didn't agree to overwrite it
|
||||
$errStr = $mod_strings['ERR_DB_EXISTS_PROCEED'];
|
||||
$errors['ERR_DB_EXISTS_PROCEED'] = $errStr;
|
||||
installLog("ERROR:: {$errors['ERR_DB_EXISTS_PROCEED']}");
|
||||
} elseif ($silent==false && !$db_selected && !$_SESSION['setup_db_create_database']) {
|
||||
// DB does not exist but user did not allow to create it
|
||||
$errors['ERR_DB_EXISTS_NOT'] = $mod_strings['ERR_DB_EXISTS_NOT'];
|
||||
installLog("ERROR:: {$errors['ERR_DB_EXISTS_NOT']}");
|
||||
} else {
|
||||
if ($db_selected) {
|
||||
installLog("DB Selected, will reuse {$_SESSION['setup_db_database_name']}");
|
||||
if ($db->tableExists('config')) {
|
||||
include('sugar_version.php');
|
||||
$versions = $db->getOne("SELECT COUNT(*) FROM config WHERE category='info' AND name='sugar_version' AND VALUE LIKE '$sugar_db_version'");
|
||||
if ($versions > 0 && $silent==false) {
|
||||
$errors['ERR_DB_EXISTS_WITH_CONFIG'] = $mod_strings['ERR_DB_EXISTS_WITH_CONFIG'];
|
||||
installLog("ERROR:: {$errors['ERR_DB_EXISTS_WITH_CONFIG']}");
|
||||
}
|
||||
}
|
||||
} else {
|
||||
installLog("DB not selected, will create {$_SESSION['setup_db_database_name']}");
|
||||
}
|
||||
if ($_SESSION['setup_db_create_sugarsales_user'] && $_SESSION['setup_db_sugarsales_user'] != '' && $db_selected) {
|
||||
if ($db->userExists($_SESSION['setup_db_sugarsales_user'])) {
|
||||
$errors['ERR_DB_USER_EXISTS'] = $mod_strings['ERR_DB_USER_EXISTS'];
|
||||
installLog("ERROR:: {$errors['ERR_DB_USER_EXISTS']}");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// DB SPECIFIC
|
||||
$check = $db->canInstall();
|
||||
if ($check !== true) {
|
||||
$error = array_shift($check);
|
||||
array_unshift($check, $mod_strings[$error]);
|
||||
$errors[$error] = call_user_func_array('sprintf', $check);
|
||||
installLog("ERROR:: {$errors[$error]}");
|
||||
} else {
|
||||
installLog("Passed DB install check");
|
||||
}
|
||||
|
||||
$db->disconnect();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if ($silent) {
|
||||
return $errors;
|
||||
} else {
|
||||
printErrors($errors);
|
||||
}
|
||||
installLog("End DB Check Process *************");
|
||||
}
|
||||
|
||||
function printErrors($errors)
|
||||
{
|
||||
global $mod_strings;
|
||||
if (count($errors) == 0) {
|
||||
echo 'dbCheckPassed';
|
||||
installLog("SUCCESS:: no errors detected!");
|
||||
} else {
|
||||
if ((count($errors) == 1 && (isset($errors["ERR_DB_EXISTS_PROCEED"])||isset($errors["ERR_DB_EXISTS_WITH_CONFIG"]))) ||
|
||||
(count($errors) == 2 && isset($errors["ERR_DB_EXISTS_PROCEED"]) && isset($errors["ERR_DB_EXISTS_WITH_CONFIG"]))) {
|
||||
///throw alert asking to overwwrite db
|
||||
echo 'preexeest';
|
||||
installLog("WARNING:: no errors detected, but DB tables will be dropped!, issuing warning to user");
|
||||
} else {
|
||||
installLog("FATAL:: errors have been detected! User will not be allowed to continue. Errors are as follow:");
|
||||
//print out errors
|
||||
$validationErr = "<p><b>{$mod_strings['ERR_DBCONF_VALIDATION']}</b></p>";
|
||||
$validationErr .= '<ul>';
|
||||
|
||||
foreach ($errors as $key =>$erMsg) {
|
||||
if ($key != "ERR_DB_EXISTS_PROCEED" && $key != "ERR_DB_EXISTS_WITH_CONFIG") {
|
||||
if ($_SESSION['dbUSRData'] == 'same' && $key == 'ERR_DB_ADMIN') {
|
||||
installLog(".. {$erMsg}");
|
||||
break;
|
||||
}
|
||||
$validationErr .= '<li class="error">' . $erMsg . '</li>';
|
||||
installLog(".. {$erMsg}");
|
||||
}
|
||||
}
|
||||
$validationErr .= '</ul>';
|
||||
$validationErr .= '</div>';
|
||||
|
||||
echo $validationErr;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
function copyInputsIntoSession()
|
||||
{
|
||||
if (isset($_REQUEST['setup_db_type'])) {
|
||||
$_SESSION['setup_db_type'] = $_REQUEST['setup_db_type'];
|
||||
}
|
||||
if (isset($_REQUEST['setup_db_admin_user_name'])) {
|
||||
$_SESSION['setup_db_admin_user_name'] = $_REQUEST['setup_db_admin_user_name'];
|
||||
}
|
||||
if (isset($_REQUEST['setup_db_admin_password'])) {
|
||||
$_SESSION['setup_db_admin_password'] = $_REQUEST['setup_db_admin_password'];
|
||||
}
|
||||
if (isset($_REQUEST['setup_db_database_name'])) {
|
||||
$_SESSION['setup_db_database_name'] = $_REQUEST['setup_db_database_name'];
|
||||
}
|
||||
if (isset($_REQUEST['setup_db_host_name'])) {
|
||||
$_SESSION['setup_db_host_name'] = $_REQUEST['setup_db_host_name'];
|
||||
}
|
||||
|
||||
//FTS Support
|
||||
if (isset($_REQUEST['setup_fts_type'])) {
|
||||
$_SESSION['setup_fts_type'] = $_REQUEST['setup_fts_type'];
|
||||
}
|
||||
if (isset($_REQUEST['setup_fts_host'])) {
|
||||
$_SESSION['setup_fts_host'] = $_REQUEST['setup_fts_host'];
|
||||
}
|
||||
if (isset($_REQUEST['setup_fts_port'])) {
|
||||
$_SESSION['setup_fts_port'] = $_REQUEST['setup_fts_port'];
|
||||
}
|
||||
|
||||
if (isset($_SESSION['setup_db_type']) && (!isset($_SESSION['setup_db_manager']) || isset($_REQUEST['setup_db_type']))) {
|
||||
$_SESSION['setup_db_manager'] = DBManagerFactory::getManagerByType($_SESSION['setup_db_type']);
|
||||
}
|
||||
|
||||
if (isset($_REQUEST['setup_db_host_instance'])) {
|
||||
$_SESSION['setup_db_host_instance'] = $_REQUEST['setup_db_host_instance'];
|
||||
}
|
||||
|
||||
if (isset($_REQUEST['setup_db_port_num'])) {
|
||||
$_SESSION['setup_db_port_num'] = $_REQUEST['setup_db_port_num'];
|
||||
}
|
||||
|
||||
// on a silent install, copy values from $_SESSION into $_REQUEST
|
||||
if (isset($_REQUEST['goto']) && $_REQUEST['goto'] == 'SilentInstall') {
|
||||
if (isset($_SESSION['dbUSRData']) && !empty($_SESSION['dbUSRData'])) {
|
||||
$_REQUEST['dbUSRData'] = $_SESSION['dbUSRData'];
|
||||
} else {
|
||||
$_REQUEST['dbUSRData'] = 'same';
|
||||
}
|
||||
|
||||
if (isset($_SESSION['setup_db_sugarsales_user']) && !empty($_SESSION['setup_db_sugarsales_user'])) {
|
||||
$_REQUEST['setup_db_sugarsales_user'] = $_SESSION['setup_db_sugarsales_user'];
|
||||
} else {
|
||||
$_REQUEST['dbUSRData'] = 'same';
|
||||
}
|
||||
|
||||
$_REQUEST['setup_db_sugarsales_password'] = $_SESSION['setup_db_sugarsales_password'];
|
||||
$_REQUEST['setup_db_sugarsales_password_retype'] = $_SESSION['setup_db_sugarsales_password'];
|
||||
}
|
||||
|
||||
//make sure we are creating or using provided user for app db connections
|
||||
$_SESSION['setup_db_create_sugarsales_user'] = true;//get_boolean_from_request('setup_db_create_sugarsales_user');
|
||||
$db = getInstallDbInstance();
|
||||
if (!$db->supports("create_user")) {
|
||||
//if the DB doesn't support creating users, make the admin user/password same as connecting user/password
|
||||
$_SESSION['setup_db_sugarsales_user'] = $_SESSION['setup_db_admin_user_name'];
|
||||
$_SESSION['setup_db_sugarsales_password'] = $_SESSION['setup_db_admin_password'];
|
||||
$_SESSION['setup_db_sugarsales_password_retype'] = $_SESSION['setup_db_sugarsales_password'];
|
||||
$_SESSION['setup_db_create_sugarsales_user'] = false;
|
||||
$_SESSION['setup_db_create_database'] = false;
|
||||
} else {
|
||||
$_SESSION['setup_db_create_database'] = true;
|
||||
//retrieve the value from dropdown in order to know what settings the user
|
||||
//wants to use for the sugar db user.
|
||||
|
||||
//use provided db admin by default
|
||||
$_SESSION['dbUSRData'] = 'same';
|
||||
|
||||
if (isset($_REQUEST['dbUSRData']) && !empty($_REQUEST['dbUSRData'])) {
|
||||
$_SESSION['dbUSRData'] = $_REQUEST['dbUSRData'];
|
||||
}
|
||||
|
||||
|
||||
if ($_SESSION['dbUSRData'] == 'auto') {
|
||||
//create user automatically
|
||||
$_SESSION['setup_db_create_sugarsales_user'] = true;
|
||||
$_SESSION['setup_db_sugarsales_user'] = "sugar".create_db_user_creds(5);
|
||||
$_SESSION['setup_db_sugarsales_password'] = create_db_user_creds(10);
|
||||
$_SESSION['setup_db_sugarsales_password_retype'] = $_SESSION['setup_db_sugarsales_password'];
|
||||
} elseif ($_SESSION['dbUSRData'] == 'provide') {
|
||||
//use provided user info
|
||||
$_SESSION['setup_db_create_sugarsales_user'] = false;
|
||||
$_SESSION['setup_db_sugarsales_user'] = $_REQUEST['setup_db_sugarsales_user'];
|
||||
$_SESSION['setup_db_sugarsales_password'] = $_REQUEST['setup_db_sugarsales_password'];
|
||||
$_SESSION['setup_db_sugarsales_password_retype'] = $_REQUEST['setup_db_sugarsales_password_retype'];
|
||||
} elseif ($_SESSION['dbUSRData'] == 'create') {
|
||||
// create user with provided info
|
||||
$_SESSION['setup_db_create_sugarsales_user'] = true;
|
||||
$_SESSION['setup_db_sugarsales_user'] = $_REQUEST['setup_db_sugarsales_user'];
|
||||
$_SESSION['setup_db_sugarsales_password'] = $_REQUEST['setup_db_sugarsales_password'];
|
||||
$_SESSION['setup_db_sugarsales_password_retype'] = $_REQUEST['setup_db_sugarsales_password_retype'];
|
||||
} else {
|
||||
//Use the same login as provided admin user
|
||||
$_SESSION['setup_db_create_sugarsales_user'] = false;
|
||||
$_SESSION['setup_db_sugarsales_user'] = $_SESSION['setup_db_admin_user_name'];
|
||||
$_SESSION['setup_db_sugarsales_password'] = $_SESSION['setup_db_admin_password'];
|
||||
$_SESSION['setup_db_sugarsales_retype'] = $_SESSION['setup_db_admin_password'];
|
||||
}
|
||||
}
|
||||
|
||||
if (!isset($_SESSION['demoData']) || empty($_SESSION['demoData'])) {
|
||||
$_SESSION['demoData'] = 'no';
|
||||
}
|
||||
if (isset($_REQUEST['demoData'])) {
|
||||
$_SESSION['demoData'] = $_REQUEST['demoData'] ;
|
||||
}
|
||||
|
||||
if ($db->supports('create_db')) {
|
||||
if (!empty($_SESSION['setup_db_create_database'])) {
|
||||
// if we're dropping DB, no need to drop tables
|
||||
$_SESSION['setup_db_drop_tables'] = false;
|
||||
}
|
||||
} else {
|
||||
// we can't create DB, so can't drop it
|
||||
$_SESSION['setup_db_create_database'] = false;
|
||||
}
|
||||
|
||||
if (isset($_REQUEST['goto']) && $_REQUEST['goto'] == 'SilentInstall' && isset($_SESSION['setup_db_drop_tables'])) {
|
||||
//set up for Oracle Silent Installer
|
||||
$_REQUEST['setup_db_drop_tables'] = $_SESSION['setup_db_drop_tables'] ;
|
||||
}
|
||||
}
|
||||
|
||||
//// END PAGEOUTPUT
|
||||
///////////////////////////////////////////////////////////////////////////////
|
4
public/legacy/install/complete_install.php
Executable file
4
public/legacy/install/complete_install.php
Executable file
|
@ -0,0 +1,4 @@
|
|||
<?php
|
||||
|
||||
ob_clean();
|
||||
header('Location: index.php?module=Users&action=Login');
|
62
public/legacy/install/data/disc_client.php
Executable file
62
public/legacy/install/data/disc_client.php
Executable file
|
@ -0,0 +1,62 @@
|
|||
<?php
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
// array elements are regexp patterns, and must not contain '#' signs
|
||||
$disc_client_ignore = array(
|
||||
// dirs
|
||||
"\\./cache/.*",
|
||||
"\\./examples/.*",
|
||||
// files
|
||||
"\\.*config\\.php\$",
|
||||
"\\.*sugarcrm\\.log\\.*",
|
||||
|
||||
"\\.*sync\\.log\\.*",
|
||||
"\\.htaccess\$",
|
||||
"\\.*\\.tmp\$",
|
||||
"\\.*\\.bak\$",
|
||||
"\\.*\\.zip\$",
|
||||
|
||||
);
|
||||
|
||||
$disc_client_no_sync = array(
|
||||
);
|
43
public/legacy/install/dbConfig.js
Executable file
43
public/legacy/install/dbConfig.js
Executable file
|
@ -0,0 +1,43 @@
|
|||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/function togglePasswordRetypeRequired(){var theForm=document.forms[0];var elem=document.getElementById('password_retype_required');if(theForm.setup_db_create_sugarsales_user.checked){elem.style.display='';theForm.setup_db_username_is_privileged.checked="";theForm.setup_db_username_is_privileged.disabled="disabled";toggleUsernameIsPrivileged();}
|
||||
else{elem.style.display='none';theForm.setup_db_username_is_privileged.disabled="";}}
|
||||
function toggleDropTables(){var theForm=document.forms[0];if(theForm.setup_db_create_database.checked){theForm.setup_db_drop_tables.checked='';theForm.setup_db_drop_tables.disabled="disabled";}
|
||||
else{theForm.setup_db_drop_tables.disabled='';}}
|
||||
function toggleUsernameIsPrivileged(){var theForm=document.forms[0];var elem=document.getElementById('privileged_user_info');if(theForm.setup_db_username_is_privileged.checked){elem.style.display='none';}
|
||||
else{elem.style.display='';}}
|
454
public/legacy/install/dbConfig_a.php
Executable file
454
public/legacy/install/dbConfig_a.php
Executable file
|
@ -0,0 +1,454 @@
|
|||
<?php
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
|
||||
|
||||
global $sugar_version, $js_custom_version;
|
||||
|
||||
|
||||
if (empty($_SESSION['setup_db_host_name'])) {
|
||||
$_SESSION['setup_db_host_name'] = (isset($sugar_config['db_host_name'])) ? $sugar_config['db_host_name'] : $_SERVER['SERVER_NAME'];
|
||||
}
|
||||
|
||||
if (!isset($install_script) || !$install_script) {
|
||||
die($mod_strings['ERR_NO_DIRECT_SCRIPT']);
|
||||
}
|
||||
|
||||
|
||||
// DB split
|
||||
$createDbCheckbox = '';
|
||||
$createDb = (!empty($_SESSION['setup_db_create_database'])) ? 'checked="checked"' : '';
|
||||
$dropCreate = (!empty($_SESSION['setup_db_drop_tables'])) ? 'checked="checked"' : '';
|
||||
$instanceName = '';
|
||||
if (isset($_SESSION['setup_db_host_instance']) && !empty($_SESSION['setup_db_host_instance'])) {
|
||||
$instanceName = $_SESSION['setup_db_host_instance'];
|
||||
}
|
||||
|
||||
$setupDbPortNum ='';
|
||||
if (isset($_SESSION['setup_db_port_num']) && !empty($_SESSION['setup_db_port_num'])) {
|
||||
$setupDbPortNum = $_SESSION['setup_db_port_num'];
|
||||
}
|
||||
|
||||
$db = getInstallDbInstance();
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// BEGIN PAGE OUTPUT
|
||||
|
||||
$langHeader = get_language_header();
|
||||
|
||||
$out =<<<EOQ
|
||||
<!DOCTYPE HTML>
|
||||
<html {$langHeader}>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Script-Type" content="text/javascript">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<title>{$mod_strings['LBL_WIZARD_TITLE']} {$mod_strings['LBL_DBCONF_TITLE']}</title>
|
||||
<link rel="stylesheet" href="install/install.css" type="text/css" />
|
||||
<link rel='stylesheet' type='text/css' href='include/javascript/yui/build/container/assets/container.css' />
|
||||
<link rel="stylesheet" href="themes/suite8/css/fontello.css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/animation.css"><!--[if IE 7]><link rel="stylesheet" href="css/fontello-ie7.css"><![endif]-->
|
||||
<link REL="SHORTCUT ICON" HREF="include/images/sugar_icon.ico">
|
||||
<script type="text/javascript" src="install/installCommon.js"></script>
|
||||
<script type="text/javascript" src="install/dbConfig.js"></script>
|
||||
<script src="cache/include/javascript/sugar_grp1_yui.js?s={$sugar_version}&c={$js_custom_version}"></script>
|
||||
<script src="cache/include/javascript/sugar_grp1_jquery.js?s={$sugar_version}&c={$js_custom_version}"></script>
|
||||
</head>
|
||||
|
||||
EOQ;
|
||||
$out .= '<body onload="document.getElementById(\'button_next2\').focus();">';
|
||||
|
||||
$out2 =<<<EOQ2
|
||||
<!--SuiteCRM installer-->
|
||||
<div id="install_container">
|
||||
<div id="install_box">
|
||||
<form action="install.php" method="post" name="setConfig" id="form">
|
||||
<div id="install_content">
|
||||
<header id="install_header">
|
||||
<div id="steps"><p>{$mod_strings['LBL_STEP5']}</p><i class="icon-progress-0" id="complete"></i><i class="icon-progress-1" id="complete"></i><i class="icon-progress-2" id="complete"></i><i class="icon-progress-3" id="complete"></i><i class="icon-progress-4" id="complete"></i><i class="icon-progress-5"></i><i class="icon-progress-6"></i><i class="icon-progress-7"></i></div>
|
||||
<div class="install_img"><a href="https://suitecrm.com" target="_blank"><img src="{$sugar_md}" alt="SuiteCRM"></a></div>
|
||||
</header>
|
||||
<input type='hidden' name='setup_db_drop_tables' id='setup_db_drop_tables' value=''>
|
||||
<input type="hidden" id="hidden_goto" name="goto" value="{$mod_strings['LBL_BACK']}" />
|
||||
<h2>{$mod_strings['LBL_DBCONF_TITLE']}</h2>
|
||||
<div id="errorMsgs" style="display:none"></div>
|
||||
<div class="required">{$mod_strings['LBL_REQUIRED']}</div>
|
||||
<hr>
|
||||
<h3>{$mod_strings['LBL_DBCONF_TITLE_NAME']}</h3>
|
||||
|
||||
EOQ2;
|
||||
|
||||
$config_params = $db->installConfig();
|
||||
$form = '';
|
||||
foreach ($config_params as $group => $gdata) {
|
||||
$form.= "<div class='install_block'>";
|
||||
$form .= "<label>{$mod_strings[$group]}</label><br>\n";
|
||||
foreach ($gdata as $name => $value) {
|
||||
if (!empty($value)) {
|
||||
if (!empty($value['required'])) {
|
||||
$form .= "<span class=\"required\">*</span>";
|
||||
} else {
|
||||
}
|
||||
if (!empty($_SESSION[$name])) {
|
||||
$sessval = $_SESSION[$name];
|
||||
} else {
|
||||
$sessval = '';
|
||||
}
|
||||
if (!empty($value["type"])) {
|
||||
$type = $value["type"];
|
||||
} else {
|
||||
$type = '';
|
||||
}
|
||||
|
||||
$form .= <<<FORM
|
||||
|
||||
FORM;
|
||||
//if the type is password, set a hidden field to capture the value. This is so that we can properly encode special characters, which is a limitation with password fields
|
||||
if ($type=='password') {
|
||||
$form .= "<input type='$type' name='{$name}_entry' id='{$name}_entry' value='".urldecode($sessval)."'><input type='hidden' name='$name' id='$name' value='".urldecode($sessval)."'>";
|
||||
} else {
|
||||
$form .= "<input type='$type' name='$name' id='$name' value='$sessval'>";
|
||||
}
|
||||
|
||||
|
||||
|
||||
$form .= <<<FORM
|
||||
FORM;
|
||||
} else {
|
||||
$form .= "<input name=\"$name\" id=\"$name\" value=\"\" type=\"hidden\">\n";
|
||||
}
|
||||
}
|
||||
$form .= "</div>";
|
||||
}
|
||||
|
||||
$out2 .= $form;
|
||||
|
||||
//if we are installing in custom mode, include the following html
|
||||
if ($db->supports("create_user")) {
|
||||
// create / set db user dropdown
|
||||
$auto_select = '';
|
||||
$provide_select ='';
|
||||
$create_select = '';
|
||||
$same_select = '';
|
||||
if (isset($_SESSION['dbUSRData'])) {
|
||||
// if($_SESSION['dbUSRData']=='auto') {$auto_select ='selected';}
|
||||
if ($_SESSION['dbUSRData']=='provide') {
|
||||
$provide_select ='selected';
|
||||
}
|
||||
if (isset($_SESSION['install_type']) && !empty($_SESSION['install_type']) && strtolower($_SESSION['install_type'])=='custom') {
|
||||
if ($_SESSION['dbUSRData']=='create') {
|
||||
$create_select ='selected';
|
||||
}
|
||||
}
|
||||
if ($_SESSION['dbUSRData']=='same') {
|
||||
$same_select ='selected';
|
||||
}
|
||||
} else {
|
||||
$same_select ='selected';
|
||||
}
|
||||
$dbUSRDD = "<select name='dbUSRData' id='dbUSRData' onchange='toggleDBUser();'>";
|
||||
$dbUSRDD .= "<option value='provide' $provide_select>".$mod_strings['LBL_DBCONFIG_PROVIDE_DD']."</option>";
|
||||
$dbUSRDD .= "<option value='create' $create_select>".$mod_strings['LBL_DBCONFIG_CREATE_DD']."</option>";
|
||||
$dbUSRDD .= "<option value='same' $same_select>".$mod_strings['LBL_DBCONFIG_SAME_DD']."</option>";
|
||||
$dbUSRDD .= "</select><br> ";
|
||||
|
||||
|
||||
|
||||
$setup_db_sugarsales_password = urldecode($_SESSION['setup_db_sugarsales_password']);
|
||||
$setup_db_sugarsales_user = urldecode($_SESSION['setup_db_sugarsales_user']);
|
||||
$setup_db_sugarsales_password_retype = urldecode($_SESSION['setup_db_sugarsales_password_retype']);
|
||||
|
||||
$out2 .=<<<EOQ2
|
||||
<br>
|
||||
<hr>
|
||||
<br>
|
||||
{$mod_strings['LBL_DBCONFIG_SECURITY']}
|
||||
<div class='install_block'><label><b>{$mod_strings['LBL_DBCONF_SUITE_DB_USER']}</b></label>$dbUSRDD
|
||||
<span id='connection_user_div' style="display:none">
|
||||
<span class="required">*</span>
|
||||
<label><b>{$mod_strings['LBL_DBCONF_SUITE_DB_USER']}</b></label>
|
||||
<input type="text" name="setup_db_sugarsales_user" value="{$_SESSION['setup_db_sugarsales_user']}" />
|
||||
<label><b>{$mod_strings['LBL_DBCONF_DB_PASSWORD']}</b></label>
|
||||
<input type="password" name="setup_db_sugarsales_password_entry" value="{$setup_db_sugarsales_password}" />
|
||||
<input type="hidden" name="setup_db_sugarsales_password" value="{$setup_db_sugarsales_password}" />
|
||||
<label><b>{$mod_strings['LBL_DBCONF_DB_PASSWORD2']}</b></label>
|
||||
<input type="password" name="setup_db_sugarsales_password_retype_entry" value="{$setup_db_sugarsales_password_retype}" /><input type="hidden" name="setup_db_sugarsales_password_retype" value="{$setup_db_sugarsales_password_retype}" />
|
||||
</span>
|
||||
</div>
|
||||
|
||||
EOQ2;
|
||||
}
|
||||
|
||||
$demoDD = "<select name='demoData' id='demoData' class='select'><option value='no' >".$mod_strings['LBL_NO']."</option><option value='yes'>".$mod_strings['LBL_YES']."</option>";
|
||||
$demoDD .= "</select>";
|
||||
|
||||
|
||||
$out3 =<<<EOQ3
|
||||
<hr>
|
||||
<div class="install_block">
|
||||
<h2>{$mod_strings['LBL_DBCONF_DEMO_DATA_TITLE']}</h2>
|
||||
<label>{$mod_strings['LBL_DBCONF_DEMO_DATA']}</label>
|
||||
{$demoDD}
|
||||
</div>
|
||||
<br>
|
||||
<br>
|
||||
EOQ3;
|
||||
|
||||
|
||||
|
||||
$out4 =<<<EOQ4
|
||||
</div>
|
||||
<hr>
|
||||
<div id="installcontrols">
|
||||
<input type="hidden" name="current_step" value="{$next_step}">
|
||||
<input class="button" type="button" name="goto" value="{$mod_strings['LBL_BACK']}" id="button_back_dbConfig" onclick="document.getElementById('form').submit();" />
|
||||
<input class="button" type="button" name="goto" id="button_next2" value="{$mod_strings['LBL_NEXT']}" onClick="callDBCheck();"/>
|
||||
</div>
|
||||
</form>
|
||||
<br>
|
||||
|
||||
<script>
|
||||
|
||||
$('#fts_type').change(function(){
|
||||
if($(this).val() == '')
|
||||
hideFTSSettings();
|
||||
else
|
||||
showFTSSettings();
|
||||
});
|
||||
|
||||
function showFTSSettings()
|
||||
{
|
||||
$('#fts_port_row').show();
|
||||
$('#fts_host_row').show();
|
||||
}
|
||||
|
||||
function hideFTSSettings()
|
||||
{
|
||||
$('#fts_port_row').hide();
|
||||
$('#fts_host_row').hide();
|
||||
}
|
||||
|
||||
function toggleDBUser(){
|
||||
if(typeof(document.getElementById('dbUSRData')) !='undefined'
|
||||
&& document.getElementById('dbUSRData') != null){
|
||||
|
||||
ouv = document.getElementById('dbUSRData').value;
|
||||
if(ouv == 'provide' || ouv == 'create'){
|
||||
document.getElementById('connection_user_div').style.display = '';
|
||||
document.getElementById('sugarDBUs<br>er').style.display = 'none';
|
||||
}else{
|
||||
document.getElementById('connection_user_div').style.display = 'none';
|
||||
document.getElementById('sugarDBUser').style.display = '';
|
||||
}
|
||||
}
|
||||
}
|
||||
toggleDBUser();
|
||||
|
||||
var msgPanel;
|
||||
function callDBCheck(){
|
||||
|
||||
//begin main function that will be called
|
||||
ajaxCall = function(msg_panel){
|
||||
//create success function for callback
|
||||
|
||||
getPanel = function() {
|
||||
var args = { width:"300px",
|
||||
modal:true,
|
||||
fixedcenter: true,
|
||||
constraintoviewport: false,
|
||||
underlay:"shadow",
|
||||
close:false,
|
||||
draggable:true,
|
||||
|
||||
effect:{effect:YAHOO.widget.ContainerEffect.FADE, duration:.5}
|
||||
} ;
|
||||
msg_panel = new YAHOO.widget.Panel('p_msg', args);
|
||||
|
||||
msg_panel.setHeader("{$mod_strings['LBL_LICENSE_CHKDB_HEADER']}");
|
||||
msg_panel.setBody(document.getElementById("checkingDiv").innerHTML);
|
||||
msg_panel.render(document.body);
|
||||
msgPanel = msg_panel;
|
||||
}
|
||||
|
||||
|
||||
passed = function(url){
|
||||
document.setConfig.goto.value="{$mod_strings['LBL_NEXT']}";
|
||||
document.getElementById('hidden_goto').value="{$mod_strings['LBL_NEXT']}";
|
||||
document.setConfig.current_step.value="{$next_step}";
|
||||
document.setConfig.submit();
|
||||
}
|
||||
success = function(o) {
|
||||
|
||||
//condition for just the preexisting database
|
||||
if (o.responseText.indexOf('preexeest')>=0){
|
||||
|
||||
// throw confirmation message
|
||||
msg_panel.setBody(document.getElementById("sysCheckMsg").innerHTML);
|
||||
msg_panel.render(document.body);
|
||||
msgPanel = msg_panel;
|
||||
document.getElementById('accept_btn').focus();
|
||||
//condition for no errors
|
||||
}else if (o.responseText.indexOf('dbCheckPassed')>=0){
|
||||
//make navigation
|
||||
passed("install.php?goto={$mod_strings['LBL_NEXT']}");
|
||||
|
||||
//condition for other errors
|
||||
}else{
|
||||
//turn off loading message
|
||||
msgPanel.hide();
|
||||
document.getElementById("errorMsgs").innerHTML = o.responseText;
|
||||
document.getElementById("errorMsgs").style.display = '';
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
}//end success
|
||||
|
||||
|
||||
//copy the db values over to the hidden field counterparts
|
||||
document.setConfig.setup_db_admin_password.value = document.setConfig.setup_db_admin_password_entry.value;
|
||||
|
||||
|
||||
|
||||
//set loading message and create url
|
||||
postData = "checkDBSettings=true&to_pdf=1&sugar_body_only=1";
|
||||
postData += "&setup_db_database_name="+document.setConfig.setup_db_database_name.value;
|
||||
if(typeof(document.setConfig.setup_db_host_instance) != 'undefined'){
|
||||
postData += "&setup_db_host_instance="+document.setConfig.setup_db_host_instance.value;
|
||||
}
|
||||
if(typeof(document.setConfig.setup_db_port_num) != 'undefined'){
|
||||
postData += "&setup_db_port_num="+document.setConfig.setup_db_port_num.value;
|
||||
}
|
||||
postData += "&setup_db_host_name="+document.setConfig.setup_db_host_name.value;
|
||||
postData += "&setup_db_admin_user_name="+document.setConfig.setup_db_admin_user_name.value;
|
||||
postData += "&setup_db_admin_password="+encodeURIComponent(document.setConfig.setup_db_admin_password.value);
|
||||
if(typeof(document.setConfig.setup_db_sugarsales_user) != 'undefined'){
|
||||
postData += "&setup_db_sugarsales_user="+document.setConfig.setup_db_sugarsales_user.value;
|
||||
}
|
||||
if(typeof(document.setConfig.setup_db_sugarsales_password) != 'undefined'){
|
||||
document.setConfig.setup_db_sugarsales_password.value = document.setConfig.setup_db_sugarsales_password_entry.value;
|
||||
postData += "&setup_db_sugarsales_password="+encodeURIComponent(document.setConfig.setup_db_sugarsales_password.value);
|
||||
}
|
||||
if(typeof(document.setConfig.setup_db_sugarsales_password_retype) != 'undefined'){
|
||||
document.setConfig.setup_db_sugarsales_password_retype.value = document.setConfig.setup_db_sugarsales_password_retype_entry.value;
|
||||
postData += "&setup_db_sugarsales_password_retype="+encodeURIComponent(document.setConfig.setup_db_sugarsales_password_retype.value);
|
||||
}
|
||||
if(typeof(document.setConfig.dbUSRData) != 'undefined'){
|
||||
postData += "&dbUSRData="+document.getElementById('dbUSRData').value;
|
||||
}
|
||||
|
||||
EOQ4;
|
||||
|
||||
|
||||
$out_dd = 'postData += "&demoData="+document.setConfig.demoData.value;';
|
||||
$out5 =<<<EOQ5
|
||||
postData += "&to_pdf=1&sugar_body_only=1";
|
||||
|
||||
//if this is a call already in progress, then just return
|
||||
if(typeof ajxProgress != 'undefined'){
|
||||
return;
|
||||
}
|
||||
|
||||
getPanel();
|
||||
msgPanel.show;
|
||||
var ajxProgress = YAHOO.util.Connect.asyncRequest('POST','install.php', {success: success, failure: success}, postData);
|
||||
|
||||
|
||||
};//end ajaxCall method
|
||||
ajaxCall();
|
||||
return;
|
||||
}
|
||||
|
||||
function confirm_drop_tables(yes_no){
|
||||
|
||||
if(yes_no == true){
|
||||
document.getElementById('setup_db_drop_tables').value = true;
|
||||
//make navigation
|
||||
document.setConfig.goto.value="{$mod_strings['LBL_NEXT']}";
|
||||
document.getElementById('hidden_goto').value="{$mod_strings['LBL_NEXT']}";
|
||||
document.setConfig.current_step.value="{$next_step}";
|
||||
document.setConfig.submit();
|
||||
}else{
|
||||
//set drop tables to false
|
||||
document.getElementById('setup_db_drop_tables').value = false;
|
||||
msgPanel.hide();
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<div id="checkingDiv" style="display:none">
|
||||
<p><img alt="{$mod_strings['LBL_LICENSE_CHKDB_HEADER']}" src='install/processing.gif'> <br>{$mod_strings['LBL_LICENSE_CHKDB_HEADER']}</p>
|
||||
</div>
|
||||
|
||||
<div id='sysCheckMsg' style="display:none">
|
||||
<p>{$mod_strings['LBL_DROP_DB_CONFIRM']}</p>
|
||||
<input id='accept_btn' type='button' class='button' onclick='confirm_drop_tables(true)' value="{$mod_strings['LBL_ACCEPT']}">
|
||||
<input type='button' class='button' onclick='confirm_drop_tables(false)' id="button_cancel_dbConfig" value="{$mod_strings['LBL_CANCEL']}">
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<footer id="install_footer">
|
||||
<p id="footer_links"><a href="https://suitecrm.com" target="_blank">Visit suitecrm.com</a> | <a href="https://suitecrm.com/suitecrm/forum" target="_blank">Support Forums</a> | <a href="https://docs.suitecrm.com/admin/installation-guide/" target="_blank">Installation Guide</a> | <a href="LICENSE.txt" target="_blank">License</a>
|
||||
</footer>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
<!--
|
||||
if ( YAHOO.env.ua )
|
||||
UA = YAHOO.env.ua;
|
||||
-->
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
EOQ5;
|
||||
|
||||
//// END PAGE OUTPUT
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
echo $out;
|
||||
echo $out2;
|
||||
echo $out3;
|
||||
echo $out4;
|
||||
echo $out_dd;
|
||||
echo $out5;
|
21724
public/legacy/install/demoData.en_us.php
Executable file
21724
public/legacy/install/demoData.en_us.php
Executable file
File diff suppressed because it is too large
Load diff
361
public/legacy/install/download_modules.php
Executable file
361
public/legacy/install/download_modules.php
Executable file
|
@ -0,0 +1,361 @@
|
|||
<?php
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
global $sugar_version, $js_custom_version;
|
||||
$lang_curr = $_SESSION['language'];
|
||||
require_once('ModuleInstall/PackageManager/PackageManagerDisplay.php');
|
||||
|
||||
if (!isset($install_script) || !$install_script || empty($_SESSION['setup_db_admin_user_name'])) {
|
||||
die($mod_strings['ERR_NO_DIRECT_SCRIPT']);
|
||||
}
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// PREFILL $sugar_config VARS
|
||||
if (empty($sugar_config['upload_dir'])) {
|
||||
$sugar_config['upload_dir'] = 'upload/';
|
||||
}
|
||||
if (empty($sugar_config['upload_maxsize'])) {
|
||||
$sugar_config['upload_maxsize'] = 8192000;
|
||||
}
|
||||
if (empty($sugar_config['upload_badext'])) {
|
||||
$sugar_config['upload_badext'] = array('php', 'php3', 'php4', 'php5', 'pl', 'cgi', 'py', 'asp', 'cfm', 'js', 'vbs', 'html', 'htm');
|
||||
}
|
||||
//// END PREFILL $sugar_config VARS
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
require_once('include/utils/php_zip_utils.php');
|
||||
|
||||
require_once('include/upload_file.php');
|
||||
|
||||
|
||||
|
||||
$GLOBALS['log'] = LoggerManager::getLogger();
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// PREP VARS FOR LANG PACK
|
||||
$base_upgrade_dir = sugar_cached("upgrades");
|
||||
$base_tmp_upgrade_dir = $base_upgrade_dir."/temp";
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// HANDLE FILE UPLOAD AND PROCESSING
|
||||
$errors = array();
|
||||
$uploadResult = '';
|
||||
//commitModules();
|
||||
if (isset($_REQUEST['languagePackAction']) && !empty($_REQUEST['languagePackAction'])) {
|
||||
switch ($_REQUEST['languagePackAction']) {
|
||||
case 'upload':
|
||||
$perform = false;
|
||||
$tempFile = '';
|
||||
if (isset($_REQUEST['release_id']) && $_REQUEST['release_id'] != "") {
|
||||
require_once('ModuleInstall/PackageManager/PackageManager.php');
|
||||
$pm = new PackageManager();
|
||||
$tempFile = $pm->download($_REQUEST['release_id']);
|
||||
$perform = true;
|
||||
//$base_filename = urldecode($tempFile);
|
||||
} else {
|
||||
$file = new UploadFile('language_pack');
|
||||
if ($file->confirm_upload()) {
|
||||
$perform = true;
|
||||
if (strpos($file->mime_type, 'zip') !== false) { // only .zip files
|
||||
$tempFile = $file->get_stored_filename();
|
||||
if ($file->final_move($tempFile)) {
|
||||
$perform = true;
|
||||
} else {
|
||||
$errors[] = $mod_strings['ERR_LANG_UPLOAD_3'];
|
||||
}
|
||||
} else {
|
||||
$errors[] = $mod_strings['ERR_LANG_UPLOAD_2'];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if ($perform) { // check for a real file
|
||||
$uploadResult = $mod_strings['LBL_LANG_SUCCESS'];
|
||||
$result = langPackUnpack('langpack', $tempFile);
|
||||
} else {
|
||||
$errors[] = $mod_strings['ERR_LANG_UPLOAD_1'];
|
||||
}
|
||||
|
||||
if (count($errors) > 0) {
|
||||
foreach ($errors as $error) {
|
||||
$uploadResult .= $error."<br />";
|
||||
}
|
||||
}
|
||||
break; // end 'validate'
|
||||
case 'commit':
|
||||
$sugar_config = commitModules(false, 'langpack');
|
||||
break;
|
||||
case 'uninstall': // leaves zip file in "uploaded" state
|
||||
$sugar_config = uninstallLanguagePack();
|
||||
break;
|
||||
case 'remove':
|
||||
removeLanguagePack();
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
//// END HANDLE FILE UPLOAD AND PROCESSING
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// PRELOAD DISPLAY DATA
|
||||
$upload_max_filesize = ini_get('upload_max_filesize');
|
||||
$upload_max_filesize_bytes = return_bytes($upload_max_filesize);
|
||||
$fileMaxSize ='';
|
||||
if (!defined('SUGARCRM_MIN_UPLOAD_MAX_FILESIZE_BYTES')) {
|
||||
define('SUGARCRM_MIN_UPLOAD_MAX_FILESIZE_BYTES', 6 * 1024 * 1024);
|
||||
}
|
||||
|
||||
if ($upload_max_filesize_bytes < constant('SUGARCRM_MIN_UPLOAD_MAX_FILESIZE_BYTES')) {
|
||||
$GLOBALS['log']->debug("detected upload_max_filesize: $upload_max_filesize");
|
||||
$fileMaxSize = '<p class="error">'.$mod_strings['ERR_UPLOAD_MAX_FILESIZE']."</p>\n";
|
||||
}
|
||||
$availablePatches = getLangPacks(true);
|
||||
$installedLanguagePacks = getInstalledLangPacks();
|
||||
$errs = '';
|
||||
if (isset($validation_errors)) {
|
||||
if (count($validation_errors) > 0) {
|
||||
$errs = '<div id="errorMsgs">';
|
||||
$errs .= "<p>{$mod_strings['LBL_SYSOPTS_ERRS_TITLE']}</p>";
|
||||
$errs .= '<ul>';
|
||||
|
||||
foreach ($validation_errors as $error) {
|
||||
$errs .= '<li>' . $error . '</li>';
|
||||
}
|
||||
|
||||
$errs .= '</ul>';
|
||||
$errs .= '</div>';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
//// PRELOAD DISPLAY DATA
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// BEING PAGE OUTPUT
|
||||
$disabled = "";
|
||||
$result = "";
|
||||
$langHeader = get_language_header();
|
||||
$out =<<<EOQ
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html {$langHeader}>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Script-Type" content="text/javascript">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<title>{$mod_strings['LBL_WIZARD_TITLE']} {$mod_strings['LBL_MODULE_TITLE']}</title>
|
||||
<link REL="SHORTCUT ICON" HREF="include/images/sugar_icon.ico">
|
||||
<link rel="stylesheet" href="install/install.css" type="text/css">
|
||||
<script type="text/javascript" src="install/installCommon.js"></script>
|
||||
<link rel="stylesheet" type="text/css" media="all" href="jscalendar/calendar-win2k-cold-1.css?s={$sugar_version}&c={$js_custom_version}">
|
||||
<script>jscal_today = 1161698116000; if(typeof app_strings == "undefined") app_strings = new Array();</script>
|
||||
<script type="text/javascript" src="cache/include/javascript/sugar_grp1.js?s={$sugar_version}&c={$js_custom_version}"></script>
|
||||
<script type="text/javascript" src="cache/include/javascript/sugar_grp1_yui.js?s={$sugar_version}&c={$js_custom_version}"></script>
|
||||
<script type="text/javascript">
|
||||
<!--
|
||||
if ( YAHOO.env.ua )
|
||||
UA = YAHOO.env.ua;
|
||||
-->
|
||||
</script>
|
||||
</head>
|
||||
|
||||
<body onLoad="document.getElementById('button_next2').focus();">
|
||||
{$fileMaxSize}
|
||||
<table cellspacing="0" width="100%" cellpadding="0" border="0" align="center" class="shell">
|
||||
<tr><td colspan="2" id="help"><a href="{$help_url}" target='_blank'>{$mod_strings['LBL_HELP']} </a></td></tr>
|
||||
<tr>
|
||||
<th width="500">
|
||||
<p>
|
||||
<img src="{$sugar_md}" alt="SugarCRM" border="0">
|
||||
</p>{$mod_strings['LBL_MODULE_TITLE']}</th>
|
||||
<th width="200" style="text-align: right;">
|
||||
</th>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
<p>{$mod_strings['LBL_LANG_1']}</p>
|
||||
<table width="100%" cellspacing="0" cellpadding="0" border="0" align="center" class="StyleDottedHr">
|
||||
<tr>
|
||||
<th colspan="2" align="left">{$mod_strings['LBL_LANG_TITLE']}</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
EOQ;
|
||||
$form =<<<EOQ1
|
||||
<form name="the_form" enctype="multipart/form-data"
|
||||
action="install.php" method="post">
|
||||
<input type="hidden" name="current_step" value="{$next_step}">
|
||||
<input type="hidden" name="language" value="{$lang_curr}">
|
||||
<input type="hidden" name="goto" value="{$mod_strings['LBL_CHECKSYS_RECHECK']}">
|
||||
<input type="hidden" name="languagePackAction" value="upload">
|
||||
<input type="hidden" name="install_type" value="custom">
|
||||
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="edit view">
|
||||
<tr>
|
||||
<td>
|
||||
<table width="450" border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td colspan='2'>
|
||||
{$mod_strings['LBL_LANG_UPLOAD']}:<br />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
|
||||
<input type="file" name="language_pack" onchange="uploadCheck();" size="40" />
|
||||
</td>
|
||||
<td valign="bottom">
|
||||
<input class='button' id="upload_button" type=button value="{$mod_strings['LBL_LANG_BUTTON_UPLOAD']}"
|
||||
disabled="disabled"
|
||||
onClick="document.the_form.language_pack_escaped.value = escape( document.the_form.language_pack.value );
|
||||
document.the_form.submit();"
|
||||
/>
|
||||
<input type=hidden name="language_pack_escaped" value="" />
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
{$uploadResult}
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
<script>
|
||||
function uploadCheck(){
|
||||
var len = escape(document.the_form.language_pack.value).length;
|
||||
if(escape(document.the_form.language_pack.value).substr(len-3,len) !='zip'){
|
||||
//document.the_form.upgrade_zip.value = '';
|
||||
//document.getElementById("upgrade_zip").value = '';
|
||||
alert('Not a zip file');
|
||||
document.the_form.language_pack.value = '';
|
||||
//document.getElementById("language_pack").value='';
|
||||
document.getElementById("upload_button").disabled='disabled';
|
||||
}
|
||||
else{
|
||||
//AJAX call for checking the file size and comparing with php.ini settings.
|
||||
var callback = {
|
||||
success:function(r) {
|
||||
document.the_form.upload_button.disabled='';
|
||||
}
|
||||
}
|
||||
//var file_name = document.getElementById('upgrade_zip').value;
|
||||
var file_name = document.the_form.language_pack.value;
|
||||
postData = 'file_name=' + file_name + 'install&action=UploadLangFileCheck&to_pdf=1';
|
||||
YAHOO.util.Connect.asyncRequest('POST', 'index.php', callback, postData);
|
||||
}
|
||||
}
|
||||
</script>
|
||||
EOQ1;
|
||||
$out1 =<<<EOQ2
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan=2>
|
||||
{$result}
|
||||
</td>
|
||||
</tr>
|
||||
<!--// Available Upgrades //-->
|
||||
<tr>
|
||||
<td align="left" colspan="2">
|
||||
<hr>
|
||||
<table cellspacing="0" cellpadding="0" border="0" class="stdTable">
|
||||
{$availablePatches}
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<td align="left" colspan="2">
|
||||
<hr>
|
||||
<table cellspacing="0" cellpadding="0" border="0" class="stdTable">
|
||||
{$installedLanguagePacks}
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right" colspan="2">
|
||||
<hr>
|
||||
<form name="the_form1" action="install.php" method="post" id="form">
|
||||
<input type="hidden" name="current_step" value="{$next_step}">
|
||||
<input type="hidden" name="language" value="{$lang_curr}">
|
||||
<input type="hidden" name="install_type" value="custom">
|
||||
<table cellspacing="0" cellpadding="0" border="0" class="stdTable">
|
||||
<tr>
|
||||
|
||||
<td>
|
||||
<input type="hidden" name="default_user_name" value="admin">
|
||||
</td>
|
||||
<td>
|
||||
<input class="button" type="submit" name="goto" value="{$mod_strings['LBL_NEXT']}" id="button_next2" {$disabled} />
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
EOQ2;
|
||||
$hidden_fields = "<input type=\"hidden\" name=\"current_step\" value=\"{$next_step}\">";
|
||||
$hidden_fields .= "<input type=\"hidden\" name=\"goto\" value=\"{$mod_strings['LBL_CHECKSYS_RECHECK']}\">";
|
||||
$hidden_fields .= "<input type=\"hidden\" name=\"languagePackAction\" value=\"commit\">";
|
||||
//$form2 = PackageManagerDisplay::buildPackageDisplay($form, $hidden_fields, 'install.php', array('langpack'), 'form1', true);
|
||||
$form2 = PackageManagerDisplay::buildPatchDisplay($form, $hidden_fields, 'install.php', array('langpack'));
|
||||
|
||||
echo $out.$form2.$out1;
|
||||
|
||||
//unlinkTempFiles('','');
|
||||
//// END PAGEOUTPUT
|
||||
///////////////////////////////////////////////////////////////////////////////
|
689
public/legacy/install/install.css
Executable file
689
public/legacy/install/install.css
Executable file
|
@ -0,0 +1,689 @@
|
|||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
/* SuiteCRM Installation CSS*/
|
||||
body {
|
||||
margin: 0px 0px 0px 0px;
|
||||
background-color : #f7f7f7 ;
|
||||
color : #333333;
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
font-weight:normal;
|
||||
font-size:0.8em;
|
||||
}
|
||||
|
||||
img {
|
||||
border:none;
|
||||
}
|
||||
|
||||
tr,td,th,table {
|
||||
font-size: 12px;
|
||||
color: #333333;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
h1 {
|
||||
color: #EA1313;
|
||||
font-size: 20px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 8px;
|
||||
}
|
||||
|
||||
h2 {
|
||||
color: #B41C4F;
|
||||
font-size: 18px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 6px;
|
||||
}
|
||||
|
||||
h3 {
|
||||
color: #333333;
|
||||
font-size: 16px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 8px;
|
||||
}
|
||||
|
||||
h4 {
|
||||
color: #565656;
|
||||
font-family: Arial, Verdana, Helvetica, sans-serif;
|
||||
font-size: 14px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 2px;
|
||||
}
|
||||
|
||||
h5 {
|
||||
color: #333333;
|
||||
font-family: Arial, Verdana, Helvetica, sans-serif;
|
||||
font-size: 13px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 1px;
|
||||
}
|
||||
|
||||
p {
|
||||
margin-top: 0px;
|
||||
margin-bottom: 10px
|
||||
}
|
||||
|
||||
hr {
|
||||
color: #ffffff;
|
||||
width: 100%;
|
||||
height: 1px;
|
||||
}
|
||||
|
||||
a:link, a:visited {
|
||||
font-size: 12px; color: #333333;
|
||||
text-decoration: none;
|
||||
font-family: Arial, Verdana, Helvetica, sans-serif;
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
a:hover {
|
||||
color: #EA1313;
|
||||
text-decoration: none;
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
li {
|
||||
list-style-image: url('../themes/suite8/images/right-arrow-install.png');
|
||||
margin-left: 6px;
|
||||
margin-bottom:2px;
|
||||
}
|
||||
|
||||
li ul li {
|
||||
list-style:none;
|
||||
margin-bottom:2px;
|
||||
}
|
||||
|
||||
ul ul li {
|
||||
list-style:none;
|
||||
margin-bottom:2px;
|
||||
}
|
||||
|
||||
input,select {
|
||||
border: 1px solid #888888;
|
||||
font-size: 11px;
|
||||
background-color: #ffffff;
|
||||
}
|
||||
|
||||
input[type="radio"] {
|
||||
border: none;
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
textarea {
|
||||
border: 1px solid #888888;
|
||||
color: #222222;
|
||||
font-size: 11px;
|
||||
background-color: #ffffff;
|
||||
}
|
||||
|
||||
.checkbox {
|
||||
border:0px;
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
.button {
|
||||
background-color:#B41C4F;
|
||||
text-indent:0;
|
||||
display:inline-block;
|
||||
color:#ffffff;
|
||||
font-size:14px;
|
||||
font-style:normal;
|
||||
height:30px;
|
||||
line-height:15px;
|
||||
text-decoration:none;
|
||||
text-align:center;
|
||||
text-shadow:1px 1px 0px #810e05;
|
||||
cursor:pointer;
|
||||
padding: 0 10px 0 10px;
|
||||
transition: all 0.5s ease;
|
||||
}
|
||||
|
||||
.button:hover, .acceptButton:hover {
|
||||
background:#565656;
|
||||
transition: all 0.5s ease;
|
||||
}
|
||||
/* custom */
|
||||
|
||||
.acceptButton {
|
||||
background-color:#B41C4F;
|
||||
text-indent:0;
|
||||
display:inline-block;
|
||||
color:#ffffff;
|
||||
font-size:14px;
|
||||
font-style:normal;
|
||||
height:30px;
|
||||
line-height:15px;
|
||||
text-decoration:none;
|
||||
text-align:center;
|
||||
text-shadow:1px 1px 0px #810e05;
|
||||
cursor:pointer;
|
||||
padding: 0 10px 0 10px;
|
||||
transition: all 0.5s ease;
|
||||
}
|
||||
|
||||
.small {
|
||||
font-size: 10px;
|
||||
}
|
||||
|
||||
.stop {
|
||||
color: #cc0000;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
.stop a:link, a:visited {
|
||||
color: #cc0000;
|
||||
text-decoration: underline;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
.go {
|
||||
color: #00cc00;
|
||||
}
|
||||
|
||||
.required {
|
||||
color: #ff2222;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.error {
|
||||
color: #ff2222;
|
||||
font-weight: bold;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
ul.tablist {
|
||||
padding: 4px 0;
|
||||
margin: 10px 0 0 0;
|
||||
border-bottom: 1px solid #999;
|
||||
font: 12px Arial, Verdana, Helvetica, sans-serif;
|
||||
}
|
||||
|
||||
ul.tablist li {
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
display: inline;
|
||||
}
|
||||
|
||||
ul.tablist li a {
|
||||
padding: 4px 8px;
|
||||
margin: 0px;
|
||||
border-top: 1px solid #ccc;
|
||||
border-right: 1px solid #ccc;
|
||||
border-bottom: 1px solid #999;
|
||||
text-decoration: none;
|
||||
color: #666666;
|
||||
}
|
||||
|
||||
ul.tablist li a:link, ul.tablist li a:visited {
|
||||
text-decoration: none;
|
||||
color: #444444;
|
||||
}
|
||||
|
||||
ul.tablist li a:hover
|
||||
{
|
||||
border-color: #666;
|
||||
color: #000;
|
||||
}
|
||||
|
||||
ul.tablist li a.current, ul.tablist li a.current:hover {
|
||||
padding: 4px 8px;
|
||||
border-top: 1px solid #999;
|
||||
border-right: 1px solid #999;
|
||||
border-bottom: 1px solid #fff;
|
||||
font-weight: bold;
|
||||
background-color: #ffffff;
|
||||
color: #000000;
|
||||
}
|
||||
|
||||
a.other{
|
||||
color: #000000;
|
||||
}
|
||||
|
||||
/* fixes to yui classes */
|
||||
|
||||
.yui-panel .hd {
|
||||
background-color:#DDDDDD !important;
|
||||
border-left:medium none !important;
|
||||
border-right:medium none !important;
|
||||
border-top:1px solid #FFFFFF;
|
||||
color:#444444 !important;
|
||||
font-size:13px !important;
|
||||
font-weight:bold !important;
|
||||
line-height:normal !important;
|
||||
overflow:hidden;
|
||||
padding:4px 4px 4px 8px !important;
|
||||
}
|
||||
.yui-panel .bd {
|
||||
padding:6px 8px 10px !important;
|
||||
}
|
||||
|
||||
.yui-panel .bd p {
|
||||
margin:0 !important;
|
||||
}
|
||||
|
||||
#install_box {
|
||||
width: 960px !important;
|
||||
min-width: 50% !important;
|
||||
height:600 !important;
|
||||
min-height:600px !important;
|
||||
max-height:600 !important;
|
||||
line-height: 1.4em;
|
||||
background:#ffffff;
|
||||
border:1px solid #cccccc;
|
||||
vertical-align:middle;
|
||||
overflow:auto;
|
||||
padding:10px;
|
||||
|
||||
}
|
||||
|
||||
#install_header {
|
||||
margin:10px auto;
|
||||
border-bottom:1px solid #cccccc;
|
||||
height:50px;
|
||||
}
|
||||
|
||||
#install_header img {
|
||||
float:left;
|
||||
padding:0 10px;
|
||||
max-height:40px;
|
||||
}
|
||||
|
||||
.rslides {
|
||||
position: relative;
|
||||
list-style: none;
|
||||
overflow: hidden;
|
||||
width: 100%;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.rslides li {
|
||||
-webkit-backface-visibility: hidden;
|
||||
position: absolute;
|
||||
display: none;
|
||||
width: 100%;
|
||||
left: 0;
|
||||
top: 0;
|
||||
}
|
||||
|
||||
.rslides li:first-child {
|
||||
position: relative;
|
||||
display: block;
|
||||
float: left;
|
||||
}
|
||||
|
||||
.rslides img {
|
||||
display: block;
|
||||
height: auto;
|
||||
float: left;
|
||||
width: 100%;
|
||||
border: 0;
|
||||
}
|
||||
|
||||
#welcomelink {
|
||||
float:right;
|
||||
margin:10px 10px 0 0;
|
||||
padding:0;
|
||||
font-weight:normal;
|
||||
color:#565656;
|
||||
}
|
||||
|
||||
#welcomelink {
|
||||
font-weight:normal;
|
||||
color:#565656;
|
||||
}
|
||||
|
||||
#install_footer {
|
||||
margin:10px auto;
|
||||
height:50px;
|
||||
}
|
||||
|
||||
.install_img {
|
||||
max-width:200px;
|
||||
}
|
||||
|
||||
.install_img:hover {
|
||||
transition: all 0.5s ease;
|
||||
opacity:0.8;
|
||||
}
|
||||
|
||||
#footer_links a{
|
||||
text-decoration:none;
|
||||
}
|
||||
|
||||
p#footer_links {
|
||||
text-align:center;
|
||||
margin-top:10px;
|
||||
}
|
||||
#wrapper {
|
||||
min-height:400px !important;
|
||||
width:960px !important;
|
||||
border-bottom:1px solid #cccccc;
|
||||
}
|
||||
|
||||
.sliderimg {
|
||||
|
||||
max-height:400px !important;
|
||||
}
|
||||
#progress {
|
||||
text-align:center;
|
||||
position:relative;
|
||||
|
||||
}
|
||||
|
||||
#install_content {
|
||||
font-size:12px;
|
||||
max-height:450px;
|
||||
overflow:auto;
|
||||
}
|
||||
|
||||
#steps {
|
||||
font-size:24px;
|
||||
verticle-align:top;
|
||||
float:right;
|
||||
margin: 0 5px 0 0;
|
||||
}
|
||||
|
||||
#steps p {
|
||||
font-size:14px;
|
||||
margin:0 0 2px 5px;
|
||||
}
|
||||
|
||||
#complete {
|
||||
color:green;
|
||||
}
|
||||
|
||||
#licenseaccept {
|
||||
padding:10px;
|
||||
float:left;
|
||||
}
|
||||
|
||||
#installcontrols {
|
||||
float:right;
|
||||
padding:10px;
|
||||
}
|
||||
|
||||
.licensetext {
|
||||
display: block;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
padding:10px;
|
||||
}
|
||||
|
||||
#installoptions {
|
||||
padding:10px;
|
||||
}
|
||||
|
||||
div.install_block{
|
||||
overflow:hidden;
|
||||
}
|
||||
div.install_block label{
|
||||
max-width:50% !important;
|
||||
display:block;
|
||||
float:left;
|
||||
text-align:left;
|
||||
}
|
||||
|
||||
div.install_block h3{
|
||||
width:auto;
|
||||
display:block;
|
||||
float:left;
|
||||
text-align:left;
|
||||
}
|
||||
div.install_block .input{
|
||||
margin-left:4px;
|
||||
float:left;
|
||||
}
|
||||
|
||||
div.install_block .select{
|
||||
margin-left:4px;
|
||||
float:left;
|
||||
}
|
||||
input {
|
||||
padding:5px;
|
||||
margin:5px;
|
||||
border:1px solid #cccccc;
|
||||
font-size:1em;
|
||||
}
|
||||
|
||||
select {
|
||||
padding:5px;
|
||||
margin:5px;
|
||||
border:1px solid #cccccc;
|
||||
font-size:1em;
|
||||
}
|
||||
|
||||
input[type=text] {
|
||||
padding:5px;
|
||||
margin:5px;
|
||||
border:1px solid #cccccc;
|
||||
font-size:1em;
|
||||
}
|
||||
|
||||
input[type=password] {
|
||||
padding:5px;
|
||||
margin:5px;
|
||||
border:1px solid #cccccc;
|
||||
font-size:1em;
|
||||
}
|
||||
|
||||
#install_container {
|
||||
width: 960px !important;
|
||||
min-width: 50% !important;
|
||||
height:600px !important;
|
||||
min-height:600px !important;
|
||||
max-height:600px !important;
|
||||
position: absolute;
|
||||
top:-10%;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
margin:auto;
|
||||
}
|
||||
|
||||
#errorheaders {
|
||||
margin:0 0 50px 0;
|
||||
}
|
||||
|
||||
#errormsg {
|
||||
margin-top:100px;
|
||||
}
|
||||
|
||||
.dbcred {
|
||||
width: 45%;
|
||||
float: left;
|
||||
padding: 5px 15px;
|
||||
}
|
||||
|
||||
.sitecred {
|
||||
width: 45%; /* Account for margins + border values */
|
||||
float: left;
|
||||
padding: 5px 15px;
|
||||
margin: 0px 5px 5px 5px;
|
||||
}
|
||||
/*
|
||||
.syscred {
|
||||
width: 30%;
|
||||
padding: 5px 15px;
|
||||
float: left;
|
||||
}
|
||||
*/
|
||||
|
||||
|
||||
.smtp_tab_toggler.selected {
|
||||
border: 1px solid #B41C4F;
|
||||
}
|
||||
|
||||
.form_section {
|
||||
padding: 10px;
|
||||
}
|
||||
|
||||
.form_section .clear {
|
||||
display: block;
|
||||
float: none;
|
||||
clear: both;
|
||||
}
|
||||
|
||||
.form_section .formrow {
|
||||
display: block;
|
||||
float: left;
|
||||
width: 430px;
|
||||
}
|
||||
|
||||
.form_section .formrow label {
|
||||
display: block;
|
||||
float: left;
|
||||
width: 180px;
|
||||
margin-top: 11px;
|
||||
}
|
||||
.form_section .formrow.big {
|
||||
width: 580px;
|
||||
}
|
||||
.form_section .formrow.big label {
|
||||
width: 250px;
|
||||
}
|
||||
.form_section .formrow input[type="checkbox"] {
|
||||
margin-top: 11px;
|
||||
}
|
||||
|
||||
.form_section .formrow label i {
|
||||
cursor: pointer;
|
||||
/* border: 1px solid lightgrey; */
|
||||
padding: 0 6px;
|
||||
position: relative;
|
||||
z-index: 1000;
|
||||
}
|
||||
.form_section .formrow label i .tooltip {
|
||||
display: none;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 30px;
|
||||
width: 500px;
|
||||
border: 1px solid #B41C4F;
|
||||
background: white;
|
||||
padding: 10px 20px;
|
||||
-webkit-box-shadow: 0px 5px 20px 0px rgba(0,0,0,0.75);
|
||||
-moz-box-shadow: 0px 5px 20px 0px rgba(0,0,0,0.75);
|
||||
box-shadow: 0px 5px 20px 0px rgba(0,0,0,0.75);
|
||||
z-index: 1001;
|
||||
}
|
||||
.form_section .formrow label i:hover .tooltip {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.form_section .formrow img {
|
||||
margin-top: 11px;
|
||||
}
|
||||
|
||||
.text-right {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
|
||||
#steps {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.field-error {
|
||||
background: lightcoral;
|
||||
}
|
||||
|
||||
/*****
|
||||
MEDIA QUERIES
|
||||
*************************************************************************************/
|
||||
/* for 980px or less */
|
||||
@media screen and (max-width: 980px) {
|
||||
|
||||
#confsettings {
|
||||
width: 94%;
|
||||
}
|
||||
.dbcred {
|
||||
width: 41%;
|
||||
padding: 1% 4%;
|
||||
}
|
||||
.sitecred {
|
||||
width: 41%;
|
||||
padding: 1% 4%;
|
||||
margin: 0px 0px 5px 5px;
|
||||
float: right;
|
||||
}
|
||||
|
||||
.syscred {
|
||||
clear: both;
|
||||
padding: 1% 4%;
|
||||
width: auto;
|
||||
float: none;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/* for 700px or less */
|
||||
@media screen and (max-width: 960px) {
|
||||
|
||||
.dbcred {
|
||||
width: auto;
|
||||
float: none;
|
||||
}
|
||||
|
||||
.sitecred {
|
||||
width: auto;
|
||||
float: none;
|
||||
margin-left: 0px;
|
||||
}
|
||||
|
||||
.syscred {
|
||||
width: auto;
|
||||
float: none;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#syscred {
|
||||
clear:both;
|
||||
position:relative;
|
||||
border-top:1px solid #cccccc;
|
||||
border-bottom:1px solid #cccccc;
|
||||
margin:10px 0 10px 0;
|
||||
padding:0 10px 0 10px;
|
||||
}
|
||||
|
||||
#syscred p {
|
||||
font-weight:normal;
|
||||
|
||||
}
|
573
public/legacy/install/install2.css
Normal file
573
public/legacy/install/install2.css
Normal file
|
@ -0,0 +1,573 @@
|
|||
/* common */
|
||||
* {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
font-size: 12px;
|
||||
font-weight: normal;
|
||||
color: #333333;
|
||||
}
|
||||
|
||||
body {
|
||||
background-color: #f7f7f7;;
|
||||
}
|
||||
|
||||
|
||||
h3 {
|
||||
font-size: 16px;
|
||||
font-weight: bold;
|
||||
text-shadow: 1px 1px 1px rgba(150, 150, 150, 0.5);
|
||||
}
|
||||
b, strong {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
a:link, a:visited {
|
||||
font-size: 12px; color: #333333;
|
||||
text-decoration: none;
|
||||
font-family: Arial, Verdana, Helvetica, sans-serif;
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
a:hover {
|
||||
color: #EA1313;
|
||||
text-decoration: none;
|
||||
text-decoration: underline;
|
||||
}
|
||||
.clear {
|
||||
clear: both;
|
||||
}
|
||||
|
||||
/* buttons */
|
||||
#install_container .button,
|
||||
#install_container .acceptButton {
|
||||
background-color:#B41C4F;
|
||||
text-indent:0;
|
||||
display:inline-block;
|
||||
color:#ffffff;
|
||||
font-size:14px;
|
||||
font-style:normal;
|
||||
height:30px;
|
||||
line-height:15px;
|
||||
text-decoration:none;
|
||||
text-align:center;
|
||||
text-shadow:1px 1px 0px #810e05;
|
||||
cursor:pointer;
|
||||
padding: 0 10px 0 10px;
|
||||
transition: all 0.5s ease;
|
||||
}
|
||||
|
||||
#install_container .button:hover,
|
||||
#install_container .acceptButton:hover {
|
||||
background:#565656;
|
||||
transition: all 0.5s ease;
|
||||
}
|
||||
|
||||
#install_container select[name="timezone"] {
|
||||
max-width: 230px;
|
||||
}
|
||||
|
||||
/* Sys env. msg */
|
||||
|
||||
#syscred p {
|
||||
margin: 0;
|
||||
padding: 2px;
|
||||
border: none;
|
||||
width: 49%;
|
||||
min-width: 330px;
|
||||
float: left;
|
||||
}
|
||||
#syscred p b {
|
||||
float: left;
|
||||
margin-right: 10px;
|
||||
}
|
||||
#syscred p span.stop * {
|
||||
color: red;
|
||||
display: block;
|
||||
float: left;
|
||||
}
|
||||
/* ----------------------------------------------- */
|
||||
|
||||
/*
|
||||
#install_container * {
|
||||
background-color: white;
|
||||
}
|
||||
*/
|
||||
|
||||
/* header (logo & steps) */
|
||||
#install_header {
|
||||
margin:10px auto;
|
||||
border-bottom:1px solid #cccccc;
|
||||
height:50px;
|
||||
}
|
||||
|
||||
#install_header img {
|
||||
float:left;
|
||||
padding:0;
|
||||
max-height:40px;
|
||||
}
|
||||
|
||||
/* steps */
|
||||
#steps {
|
||||
font-size:24px;
|
||||
verticle-align:top;
|
||||
float:right;
|
||||
margin: 0 5px 0 0;
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
#steps p {
|
||||
font-size:14px;
|
||||
margin:0 0 2px 5px;
|
||||
}
|
||||
|
||||
#steps i {
|
||||
font-size: 24px;
|
||||
}
|
||||
#complete {
|
||||
color: green;
|
||||
}
|
||||
|
||||
|
||||
/* logo image */
|
||||
.install_img {
|
||||
max-width:200px;
|
||||
}
|
||||
|
||||
.install_img:hover {
|
||||
transition: all 0.5s ease;
|
||||
opacity:0.8;
|
||||
}
|
||||
|
||||
|
||||
#install_box {
|
||||
line-height: 1.4em;
|
||||
background:#ffffff;
|
||||
border:1px solid #cccccc;
|
||||
vertical-align:middle;
|
||||
padding: 10px 20px;
|
||||
margin: 20px;
|
||||
/* min-height: 800px; */
|
||||
|
||||
-webkit-box-shadow: 0px 14px 57px -14px rgba(0,0,0,0.46);
|
||||
-moz-box-shadow: 0px 14px 57px -14px rgba(0,0,0,0.46);
|
||||
box-shadow: 0px 14px 57px -14px rgba(0,0,0,0.46);
|
||||
}
|
||||
|
||||
/* install controlls*/
|
||||
#installcontrols {
|
||||
/*float:right;*/
|
||||
text-align: right;
|
||||
padding:10px;
|
||||
}
|
||||
|
||||
/* footer & footer links */
|
||||
|
||||
#install_footer {
|
||||
margin:10px auto;
|
||||
height:50px;
|
||||
}
|
||||
|
||||
#footer_links a{
|
||||
text-decoration:none;
|
||||
}
|
||||
|
||||
p#footer_links {
|
||||
text-align:center;
|
||||
margin-top:10px;
|
||||
}
|
||||
|
||||
/* configuration step */
|
||||
|
||||
div.install_block{
|
||||
/*overflow:hidden;*/
|
||||
}
|
||||
div.install_block label{
|
||||
max-width:50% !important;
|
||||
display:block;
|
||||
float:left;
|
||||
text-align:left;
|
||||
}
|
||||
|
||||
div.install_block h3{
|
||||
width:auto;
|
||||
display:block;
|
||||
float:left;
|
||||
text-align:left;
|
||||
}
|
||||
div.install_block .input{
|
||||
margin-left:4px;
|
||||
float:left;
|
||||
}
|
||||
|
||||
div.install_block .select{
|
||||
margin-left:4px;
|
||||
float:left;
|
||||
}
|
||||
.starhook div.install_block span {display: inline; float: left; width: 5px; padding-top:8px; padding-left:3px;}
|
||||
input {
|
||||
padding:5px;
|
||||
margin:5px;
|
||||
border:1px solid #cccccc;
|
||||
font-size:1em;
|
||||
}
|
||||
|
||||
select {
|
||||
padding:5px;
|
||||
margin:5px;
|
||||
border:1px solid #cccccc;
|
||||
font-size:1em;
|
||||
background-color: white;
|
||||
}
|
||||
|
||||
input[type=text] {
|
||||
padding:5px;
|
||||
margin:5px;
|
||||
border:1px solid #cccccc;
|
||||
font-size:1em;
|
||||
}
|
||||
|
||||
input[type=password] {
|
||||
padding:5px;
|
||||
margin:5px;
|
||||
border:1px solid #cccccc;
|
||||
font-size:1em;
|
||||
}
|
||||
|
||||
|
||||
#errorheaders {
|
||||
margin:0 0 50px 0;
|
||||
}
|
||||
|
||||
#errormsg {
|
||||
margin-top:100px;
|
||||
}
|
||||
|
||||
.dbcred {
|
||||
width: 45%;
|
||||
float: left;
|
||||
padding: 5px 15px;
|
||||
}
|
||||
|
||||
.sitecred {
|
||||
width: 45%; /* Account for margins + border values */
|
||||
float: left;
|
||||
padding: 5px 15px;
|
||||
margin: 0px 5px 5px 5px;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
.small {
|
||||
font-size: 10px;
|
||||
}
|
||||
|
||||
.stop {
|
||||
color: #cc0000;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
.stop a:link, a:visited {
|
||||
color: #cc0000;
|
||||
text-decoration: underline;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
.go {
|
||||
color: #00cc00;
|
||||
}
|
||||
|
||||
.required {
|
||||
color: #ff2222;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.error {
|
||||
color: #ff2222;
|
||||
font-weight: bold;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
ul.tablist {
|
||||
padding: 4px 0;
|
||||
margin: 10px 0 0 0;
|
||||
border-bottom: 1px solid #999;
|
||||
font: 12px Arial, Verdana, Helvetica, sans-serif;
|
||||
}
|
||||
|
||||
ul.tablist li {
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
display: inline;
|
||||
}
|
||||
|
||||
ul.tablist li a {
|
||||
padding: 4px 8px;
|
||||
margin: 0px;
|
||||
border-top: 1px solid #ccc;
|
||||
border-right: 1px solid #ccc;
|
||||
border-bottom: 1px solid #999;
|
||||
text-decoration: none;
|
||||
color: #666666;
|
||||
}
|
||||
|
||||
ul.tablist li a:link, ul.tablist li a:visited {
|
||||
text-decoration: none;
|
||||
color: #444444;
|
||||
}
|
||||
|
||||
ul.tablist li a:hover
|
||||
{
|
||||
border-color: #666;
|
||||
color: #000;
|
||||
}
|
||||
|
||||
ul.tablist li a.current, ul.tablist li a.current:hover {
|
||||
padding: 4px 8px;
|
||||
border-top: 1px solid #999;
|
||||
border-right: 1px solid #999;
|
||||
border-bottom: 1px solid #fff;
|
||||
font-weight: bold;
|
||||
background-color: #ffffff;
|
||||
color: #000000;
|
||||
}
|
||||
|
||||
a.other{
|
||||
color: #000000;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
h2 {
|
||||
color: #B41C4F;
|
||||
font-size: 18px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 6px;
|
||||
text-shadow: 1px 1px 1px rgba(150, 150, 150, 0.5);
|
||||
}
|
||||
|
||||
|
||||
.smtp_tab_toggler.selected {
|
||||
border: 1px solid #B41C4F;
|
||||
}
|
||||
|
||||
.form_section {
|
||||
padding: 10px;
|
||||
}
|
||||
|
||||
.form_section .clear {
|
||||
display: block;
|
||||
float: none;
|
||||
clear: both;
|
||||
}
|
||||
|
||||
.form_section .formrow {
|
||||
display: block;
|
||||
float: left;
|
||||
width: 430px;
|
||||
}
|
||||
|
||||
.form_section .formrow label, label {
|
||||
display: block;
|
||||
float: left;
|
||||
width: 180px;
|
||||
margin-top: 11px;
|
||||
}
|
||||
.form_section .formrow.big {
|
||||
width: 580px;
|
||||
}
|
||||
.form_section .formrow.big label {
|
||||
width: 250px;
|
||||
}
|
||||
.form_section .formrow input[type="checkbox"] {
|
||||
margin-top: 11px;
|
||||
}
|
||||
|
||||
.form_section .formrow label i,
|
||||
label i,
|
||||
.tooltip-toggle {
|
||||
cursor: pointer;
|
||||
/* border: 1px solid lightgrey; */
|
||||
padding: 0 6px;
|
||||
position: relative;
|
||||
z-index: 1000;
|
||||
}
|
||||
.form_section .formrow label i .tooltip,
|
||||
label i .tooltip,
|
||||
.tooltip-toggle .tooltip {
|
||||
display: none;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 30px;
|
||||
width: 500px;
|
||||
border: 1px solid #B41C4F;
|
||||
background: white;
|
||||
padding: 10px 20px;
|
||||
-webkit-box-shadow: 0px 5px 20px 0px rgba(0,0,0,0.75);
|
||||
-moz-box-shadow: 0px 5px 20px 0px rgba(0,0,0,0.75);
|
||||
box-shadow: 0px 5px 20px 0px rgba(0,0,0,0.75);
|
||||
z-index: 1001;
|
||||
}
|
||||
.form_section .formrow label i:hover .tooltip,
|
||||
label i:hover .tooltip,
|
||||
.tooltip-toggle:hover .tooltip {
|
||||
display: block;
|
||||
}
|
||||
|
||||
div.tooltip-toggle {
|
||||
display: inline;
|
||||
|
||||
}
|
||||
|
||||
.form_section .formrow img {
|
||||
margin-top: 11px;
|
||||
}
|
||||
|
||||
.text-right {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
|
||||
#steps {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.field-error {
|
||||
background: lightcoral;
|
||||
}
|
||||
|
||||
/* wellcome page */
|
||||
|
||||
#welcomelink {
|
||||
font-weight: normal;
|
||||
color: #565656;
|
||||
}
|
||||
#welcomelink {
|
||||
float: right;
|
||||
margin: 10px 10px 0 0;
|
||||
padding: 0;
|
||||
font-weight: normal;
|
||||
color: #565656;
|
||||
}
|
||||
h1 {
|
||||
color: #EA1313;
|
||||
font-size: 20px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 8px;
|
||||
text-shadow: 1px 1px 1px rgba(150, 150, 150, 0.5);
|
||||
}
|
||||
|
||||
/* slider */
|
||||
form #wrapper {
|
||||
min-height:400px !important;
|
||||
border-bottom:1px solid #cccccc;
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
.sliderimg {
|
||||
|
||||
/* max-height:400px !important; */
|
||||
}
|
||||
|
||||
.rslides {
|
||||
position: relative;
|
||||
list-style: none;
|
||||
overflow: hidden;
|
||||
width: 100%;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
max-height: 500px;
|
||||
}
|
||||
|
||||
.rslides li {
|
||||
-webkit-backface-visibility: hidden;
|
||||
position: absolute;
|
||||
display: none;
|
||||
width: 100%;
|
||||
left: 0;
|
||||
top: 0;
|
||||
}
|
||||
|
||||
.rslides li:first-child {
|
||||
position: relative;
|
||||
display: block;
|
||||
float: left;
|
||||
}
|
||||
|
||||
.rslides img {
|
||||
display: block;
|
||||
height: auto;
|
||||
float: left;
|
||||
width: 100%;
|
||||
border: 0;
|
||||
}
|
||||
|
||||
/* license */
|
||||
#licenseDiv {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
#licenseaccept {
|
||||
padding:10px;
|
||||
float:none;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
#licenseDivToggler {
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
/* system check preloader */
|
||||
.preloading {
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
|
||||
/* install config step */
|
||||
.floatbox {
|
||||
width:48%;
|
||||
min-width: 400px;
|
||||
display: block;
|
||||
float: left;
|
||||
}
|
||||
.floatbox.full {
|
||||
width: 98%;
|
||||
}
|
||||
|
||||
|
||||
.toggler {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/*****
|
||||
MEDIA QUERIES
|
||||
*************************************************************************************/
|
||||
/* for 1300px or less */
|
||||
@media screen and (max-width: 1300px) {
|
||||
.formrow.big label {float: none;}
|
||||
}
|
||||
|
||||
|
||||
/* for 700px or less */
|
||||
@media screen and (max-width: 700px) {
|
||||
#install_header {border: none;}
|
||||
}
|
||||
|
||||
/* for 500px or less */
|
||||
@media screen and (max-width: 500px) {
|
||||
.floatbox {float: none;}
|
||||
.floatbox.full {min-width: initial;}
|
||||
#install_box .formrow label {float: none;}
|
||||
#install_box label {float: none;}
|
||||
.install_block input {display: block; float: none; max-width: 40%;}
|
||||
.ibmsg {width: 70%;}
|
||||
#syscred p {width: initial; min-width: initial;}
|
||||
.licensetext {width: 70%;}
|
||||
#licenseaccept {width: initial; diaplay: block; float: none;}
|
||||
}
|
41
public/legacy/install/installCommon.js
Executable file
41
public/legacy/install/installCommon.js
Executable file
|
@ -0,0 +1,41 @@
|
|||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
function showHelp(step)
|
||||
{url='https://community.suitecrm.com';name='helpWindowPopup';window.open(url,name);}
|
||||
function setFocus(){focus=document.getElementById('button_next2');focus.focus();}
|
2007
public/legacy/install/installConfig.php
Executable file
2007
public/legacy/install/installConfig.php
Executable file
File diff suppressed because it is too large
Load diff
94
public/legacy/install/installDisabled.php
Executable file
94
public/legacy/install/installDisabled.php
Executable file
|
@ -0,0 +1,94 @@
|
|||
<?php
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
if (!isset($install_script) || !$install_script) {
|
||||
die($mod_strings['ERR_NO_DIRECT_SCRIPT']);
|
||||
}
|
||||
|
||||
|
||||
$langHeader = get_language_header();
|
||||
$out =<<<EOQ
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
|
||||
<html {$langHeader}>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<title>{$disabled_title}</title>
|
||||
<link rel="stylesheet" href="install/install.css" type="text/css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<table cellspacing="0" cellpadding="0" border="0" align="center" class=
|
||||
"shell">
|
||||
<tr>
|
||||
<th width="400">{$disabled_title_2}</th>
|
||||
|
||||
<th width="200" height="30" style="text-align: right;"> </th>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
<p>
|
||||
<img src="{$sugar_md}" alt="SugarCRM" border="0">
|
||||
</p>
|
||||
{$disabled_text}
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td align="right" colspan="2" height="20">
|
||||
<hr>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<footer id="install_footer">
|
||||
<p id="footer_links"><a href="https://suitecrm.com" target="_blank">Visit suitecrm.com</a> | <a href="https://suitecrm.com/suitecrm/forum" target="_blank">Support Forums</a> | <a href="https://docs.suitecrm.com/admin/installation-guide/" target="_blank">Installation Guide</a> | <a href="LICENSE.txt" target="_blank">License</a>
|
||||
</footer>
|
||||
</body>
|
||||
</html>
|
||||
EOQ;
|
||||
echo $out;
|
376
public/legacy/install/installHelp.php
Executable file
376
public/legacy/install/installHelp.php
Executable file
|
@ -0,0 +1,376 @@
|
|||
<?php
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
|
||||
|
||||
class HelpItem
|
||||
{
|
||||
public $associated_field = '';
|
||||
public $title = '';
|
||||
public $text = '';
|
||||
}
|
||||
|
||||
function &help_menu_html()
|
||||
{
|
||||
$str =<<<HEREDOC_END
|
||||
<div>SugarCRM Install Help</div>
|
||||
<ul>
|
||||
<li><a href="$_SERVER[PHP_SELF]?step=1">Step 1: Prerequisite checks</a></li>
|
||||
<li><a href="$_SERVER[PHP_SELF]?step=2">Step 2: Database configuration</a></li>
|
||||
<li><a href="$_SERVER[PHP_SELF]?step=3">Step 3: Site configuration</a></li>
|
||||
<li><a href="$_SERVER[PHP_SELF]?step=4">Step 4: Saving config file and setting up the database</a></li>
|
||||
<li><a href="$_SERVER[PHP_SELF]?step=5">Step 5: Registration</a></li>
|
||||
</ul>
|
||||
HEREDOC_END;
|
||||
return $str;
|
||||
}
|
||||
|
||||
function &format_help_items(&$help_items)
|
||||
{
|
||||
$str = '<table>';
|
||||
|
||||
foreach ($help_items as $help_item) {
|
||||
$str .= <<< HEREDOC_END
|
||||
<tr><td><b>$help_item->title</b></td></tr>
|
||||
<tr><td>$help_item->text</td></tr>
|
||||
HEREDOC_END;
|
||||
}
|
||||
|
||||
$str .= '</table>';
|
||||
|
||||
return $str;
|
||||
}
|
||||
|
||||
function &help_step_1_html()
|
||||
{
|
||||
$help_items = array();
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'PHP Version';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
The version of PHP installed must be 4.3.x or 5.x.
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'MySQL Database';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
Checking that the MySQL API is accessible.
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'SugarCRM Configuration File';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
The configuration file (config.php) must be writable.
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Cache Sub-Directories';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
All the sub-directories beneath the cache directory (cache) must be
|
||||
writable.
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Session Save Path';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
The session save path specified in the PHP initialization file (php.ini)
|
||||
as session_save_path must exist and be writable.
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$str =format_help_items($help_items);
|
||||
return $str;
|
||||
}
|
||||
|
||||
function &help_step_2_html()
|
||||
{
|
||||
$help_items = array();
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Host Name';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Database Name';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Create Database';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'User Name for SugarCRM';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Create User';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Password for SugarCRM';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Re-Type Password for SugarCRM';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Drop and recreate existing SugarCRM tables?';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Populate database with demo data?';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Database Admin User Name';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Database Admin Password';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$str =format_help_items($help_items);
|
||||
return $str;
|
||||
}
|
||||
|
||||
function &help_step_3_html()
|
||||
{
|
||||
$help_items = array();
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'URL';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'SugarCRM Admin Password';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Re-type SugarCRM Admin Password';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Allow SugarCRM to collect anonymous usage information?';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Use a Custom Session Directory for SugarCRM';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Path to Session Directory';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Provide Your Own Application ID';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Application ID';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$str =format_help_items($help_items);
|
||||
return $str;
|
||||
}
|
||||
|
||||
function &help_step_4_html()
|
||||
{
|
||||
$help_items = array();
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Perform Install';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$str =format_help_items($help_items);
|
||||
return $str;
|
||||
}
|
||||
|
||||
function &help_step_5_html()
|
||||
{
|
||||
$help_items = array();
|
||||
|
||||
$help_item = new HelpItem();
|
||||
$help_item->title = 'Registration';
|
||||
$help_item->text = <<< HEREDOC_END
|
||||
TODO
|
||||
HEREDOC_END;
|
||||
|
||||
$help_items[] = $help_item;
|
||||
|
||||
$str =format_help_items($help_items);
|
||||
return $str;
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html <?php get_language_header(); ?>>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<title>SugarCRM Install Help</title>
|
||||
<link rel="stylesheet" href="install/install.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
<?php
|
||||
if (isset($_GET['step'])) {
|
||||
switch ($_GET['step']) {
|
||||
case 1:
|
||||
echo help_step_1_html();
|
||||
break;
|
||||
case 2:
|
||||
echo help_step_2_html();
|
||||
break;
|
||||
case 3:
|
||||
echo help_step_3_html();
|
||||
break;
|
||||
case 4:
|
||||
echo help_step_4_html();
|
||||
break;
|
||||
case 5:
|
||||
echo help_step_5_html();
|
||||
break;
|
||||
default:
|
||||
echo help_menu_html();
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
echo help_menu_html();
|
||||
}
|
||||
?>
|
||||
|
||||
<form>
|
||||
<input type="button" value="Close" onclick="javascript:window.close();" />
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
410
public/legacy/install/installSystemCheck.php
Executable file
410
public/legacy/install/installSystemCheck.php
Executable file
|
@ -0,0 +1,410 @@
|
|||
<?php
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
|
||||
$_SESSION['setup_license_accept'] = true;
|
||||
|
||||
/**
|
||||
* @param bool $install_script
|
||||
* @param array $mod_strings
|
||||
* @return string
|
||||
*/
|
||||
function runCheck($install_script, $mod_strings = array())
|
||||
{
|
||||
installLog('Begin System Check Process *************');
|
||||
|
||||
if (!isset($install_script) || !$install_script) {
|
||||
installLog('Error:: ' . $mod_strings['ERR_NO_DIRECT_SCRIPT']);
|
||||
die($mod_strings['ERR_NO_DIRECT_SCRIPT']);
|
||||
}
|
||||
|
||||
if (!defined('SUGARCRM_MIN_MEM')) {
|
||||
define('SUGARCRM_MIN_MEM', 40);
|
||||
}
|
||||
|
||||
|
||||
|
||||
// for keeping track of whether to enable/disable the 'Next' button
|
||||
$error_found = false;
|
||||
$error_txt = '';
|
||||
|
||||
|
||||
// check IIS and FastCGI
|
||||
$server_software = $_SERVER["SERVER_SOFTWARE"];
|
||||
if ((strpos($_SERVER["SERVER_SOFTWARE"], 'Microsoft-IIS') !== false)
|
||||
&& php_sapi_name() == 'cgi-fcgi'
|
||||
&& ini_get('fastcgi.logging') != '0') {
|
||||
installLog($mod_strings['ERR_CHECKSYS_FASTCGI_LOGGING']);
|
||||
$iisVersion = "<b><span class=stop>{$mod_strings['ERR_CHECKSYS_FASTCGI_LOGGING']}</span></b>";
|
||||
$error_found = true;
|
||||
$error_txt .= '
|
||||
<p><b>'.$mod_strings['LBL_CHECKSYS_FASTCGI'].'</b></p>
|
||||
<p ><span class="error">'.$iisVersion.'</span></p>
|
||||
';
|
||||
}
|
||||
|
||||
if (strpos($server_software, 'Microsoft-IIS') !== false) {
|
||||
$iis_version = '';
|
||||
if (preg_match_all("/^.*\/(\d+\.?\d*)$/", $server_software, $out)) {
|
||||
$iis_version = $out[1][0];
|
||||
}
|
||||
|
||||
$check_iis_version_result = check_iis_version($iis_version);
|
||||
if ($check_iis_version_result == -1) {
|
||||
installLog($mod_strings['ERR_CHECKSYS_IIS_INVALID_VER'].' '.$iis_version);
|
||||
$iisVersion = "<b><span class=stop>{$mod_strings['ERR_CHECKSYS_IIS_INVALID_VER']} {$iis_version}</span></b>";
|
||||
$error_found = true;
|
||||
$error_txt .= '
|
||||
<p><b>'.$mod_strings['LBL_CHECKSYS_IISVER'].'</b></p>
|
||||
<p><span class="error">'.$iisVersion.'</span></p>
|
||||
';
|
||||
} else {
|
||||
if (php_sapi_name() != 'cgi-fcgi') {
|
||||
installLog($mod_strings['ERR_CHECKSYS_FASTCGI'].' '.$iis_version);
|
||||
$iisVersion = "<b><span class=stop>{$mod_strings['ERR_CHECKSYS_FASTCGI']}</span></b>";
|
||||
$error_found = true;
|
||||
$error_txt .= '
|
||||
<p><b>'.$mod_strings['LBL_CHECKSYS_FASTCGI'].'</b></p>
|
||||
<p><span class="error">'.$iisVersion.'</span></p>
|
||||
';
|
||||
} else {
|
||||
if (ini_get('fastcgi.logging') != '0') {
|
||||
installLog($mod_strings['ERR_CHECKSYS_FASTCGI_LOGGING'].' '.$iis_version);
|
||||
$iisVersion = "<b><span class=stop>{$mod_strings['ERR_CHECKSYS_FASTCGI_LOGGING']}</span></b>";
|
||||
$error_found = true;
|
||||
$error_txt .= '
|
||||
<p><b>'.$mod_strings['LBL_CHECKSYS_FASTCGI'].'</b></p>
|
||||
<p ><span class="error">'.$iisVersion.'</span></p>
|
||||
';
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// PHP VERSION
|
||||
|
||||
|
||||
if (check_php_version() === -1) {
|
||||
installLog($mod_strings['ERR_CHECKSYS_PHP_INVALID_VER'].' '.constant('PHP_VERSION'));
|
||||
$phpVersion = "<b><span class=stop>{$mod_strings['ERR_CHECKSYS_PHP_INVALID_VER']} ".constant('PHP_VERSION')." )</span></b>";
|
||||
$error_found = true;
|
||||
$error_txt .= '
|
||||
<p><b>'.$mod_strings['LBL_CHECKSYS_PHPVER'].'</b></p>
|
||||
<p><span class="error">'.$phpVersion.'</span></p>
|
||||
';
|
||||
}
|
||||
|
||||
// database and connect
|
||||
if (!empty($_REQUEST['setup_db_type'])) {
|
||||
$_SESSION['setup_db_type'] = $_REQUEST['setup_db_type'];
|
||||
}
|
||||
|
||||
$drivers = DBManagerFactory::getDbDrivers();
|
||||
|
||||
if (empty($drivers)) {
|
||||
$db_name = $mod_strings['LBL_DB_UNAVAILABLE'];
|
||||
installLog("ERROR:: {$mod_strings['LBL_CHECKSYS_DB_SUPPORT_NOT_AVAILABLE']}");
|
||||
$dbStatus = "<b><span class=stop>{$mod_strings['LBL_CHECKSYS_DB_SUPPORT_NOT_AVAILABLE']}</span></b>";
|
||||
$error_found = true;
|
||||
$error_txt .= '
|
||||
<p><strong>'.$db_name.'</strong></p>
|
||||
<p class="error">'.$dbStatus.'</p>
|
||||
';
|
||||
}
|
||||
|
||||
// XML Parsing
|
||||
if (!function_exists('xml_parser_create')) {
|
||||
$xmlStatus = "<b><span class=stop>{$mod_strings['LBL_CHECKSYS_XML_NOT_AVAILABLE']}</span></b>";
|
||||
installLog("ERROR:: {$mod_strings['LBL_CHECKSYS_XML_NOT_AVAILABLE']}");
|
||||
$error_found = true;
|
||||
$error_txt .= '
|
||||
<p><strong>'.$mod_strings['LBL_CHECKSYS_XML'].'</strong></p>
|
||||
<p class="error">'.$xmlStatus.'</p>
|
||||
';
|
||||
} else {
|
||||
installLog("XML Parsing Support Found");
|
||||
}
|
||||
|
||||
// JSON Parsing
|
||||
if (!function_exists('json_decode')) {
|
||||
$jsonStatus = "<b><span class=stop>{$mod_strings['ERR_CHECKSYS_JSON_NOT_AVAILABLE']}</span></b>";
|
||||
installLog("ERROR:: {$mod_strings['ERR_CHECKSYS_JSON_NOT_AVAILABLE']}");
|
||||
$error_found = true;
|
||||
$error_txt .= '
|
||||
<p><strong>'.$mod_strings['LBL_CHECKSYS_JSON'].'</strong></p>
|
||||
<p class="error">'.$jsonStatus.'</p>
|
||||
';
|
||||
} else {
|
||||
installLog("JSON Parsing Support Found");
|
||||
}
|
||||
|
||||
// mbstrings
|
||||
if (!function_exists('mb_strlen')) {
|
||||
$mbstringStatus = "<b><span class=stop>{$mod_strings['ERR_CHECKSYS_MBSTRING']}</font></b>";
|
||||
installLog("ERROR:: {$mod_strings['ERR_CHECKSYS_MBSTRING']}");
|
||||
$error_found = true;
|
||||
$error_txt .= '
|
||||
<p><strong>'.$mod_strings['LBL_CHECKSYS_MBSTRING'].'</strong></p>
|
||||
<p class="error">'.$mbstringStatus.'</p>
|
||||
';
|
||||
} else {
|
||||
installLog("MBString Support Found");
|
||||
}
|
||||
|
||||
// zip
|
||||
if (!class_exists('ZipArchive')) {
|
||||
$zipStatus = "<b><span class=stop>{$mod_strings['ERR_CHECKSYS_ZIP']}</font></b>";
|
||||
installLog("ERROR:: {$mod_strings['ERR_CHECKSYS_ZIP']}");
|
||||
} else {
|
||||
installLog("ZIP Support Found");
|
||||
}
|
||||
|
||||
// config.php
|
||||
if (file_exists('./config.php') && (!(make_writable('./config.php')) || !(is_writable('./config.php')))) {
|
||||
installLog("ERROR:: {$mod_strings['ERR_CHECKSYS_CONFIG_NOT_WRITABLE']}");
|
||||
$configStatus = "<b><span class='stop'>{$mod_strings['ERR_CHECKSYS_CONFIG_NOT_WRITABLE']}</span></b>";
|
||||
$error_found = true;
|
||||
$error_txt .= '
|
||||
<p><strong>'.$mod_strings['LBL_CHECKSYS_CONFIG'].'</strong></p>
|
||||
<p class="error">'.$configStatus.'</p>
|
||||
';
|
||||
}
|
||||
|
||||
// config_override.php
|
||||
if (file_exists('./config_override.php') && (!(make_writable('./config_override.php')) || !(is_writable('./config_override.php')))) {
|
||||
installLog("ERROR:: {$mod_strings['ERR_CHECKSYS_CONFIG_OVERRIDE_NOT_WRITABLE']}");
|
||||
$configStatus = "<b><span class='stop'>{$mod_strings['ERR_CHECKSYS_CONFIG_OVERRIDE_NOT_WRITABLE']}</span></b>";
|
||||
$error_found = true;
|
||||
$error_txt .= '
|
||||
<p><strong>'.$mod_strings['LBL_CHECKSYS_OVERRIDE_CONFIG'].'</strong></p>
|
||||
<p class="error">'.$configStatus.'</p>
|
||||
';
|
||||
}
|
||||
|
||||
// custom dir
|
||||
if (!make_writable('./custom')) {
|
||||
$customStatus = "<b><span class='stop'>{$mod_strings['ERR_CHECKSYS_CUSTOM_NOT_WRITABLE']}</font></b>";
|
||||
installLog("ERROR:: {$mod_strings['ERR_CHECKSYS_CUSTOM_NOT_WRITABLE']}");
|
||||
$error_found = true;
|
||||
$error_txt .= '
|
||||
<p><strong>'.$mod_strings['LBL_CHECKSYS_CUSTOM'].'</strong></p>
|
||||
<p class="error">'.$customStatus.'</p>
|
||||
';
|
||||
} else {
|
||||
installLog("/custom directory and subdirectory check passed");
|
||||
}
|
||||
|
||||
|
||||
// cache dir
|
||||
$cache_files[] = '';
|
||||
$cache_files[] = 'images';
|
||||
$cache_files[] = 'layout';
|
||||
$cache_files[] = 'pdf';
|
||||
$cache_files[] = 'xml';
|
||||
$cache_files[] = 'include/javascript';
|
||||
$filelist = '';
|
||||
|
||||
foreach ($cache_files as $c_file) {
|
||||
$dirname = sugar_cached($c_file);
|
||||
$ok = false;
|
||||
if ((is_dir($dirname)) || @sugar_mkdir($dirname, 0755, true)) { // set permissions to restrictive - use make_writable to change in a standard way to the required permissions
|
||||
$ok = make_writable($dirname);
|
||||
}
|
||||
if (!$ok) {
|
||||
$filelist .= '<br>'.getcwd()."/$dirname";
|
||||
}
|
||||
}
|
||||
if (strlen($filelist)>0) {
|
||||
$error_found = true;
|
||||
installLog("ERROR:: Some subdirectories in cache subfolder were not read/writeable:");
|
||||
installLog($filelist);
|
||||
$error_txt .= '
|
||||
<p><strong>'.$mod_strings['LBL_CHECKSYS_CACHE'].'</strong></p>
|
||||
<p align="right" class="error" class="error"><b><span class="stop">'.$mod_strings['ERR_CHECKSYS_FILES_NOT_WRITABLE'].'</span></b>
|
||||
|
||||
<p><b>'.$mod_strings['LBL_CHECKSYS_FIX_FILES'].'</b>'.$filelist. '</p>
|
||||
';
|
||||
} else {
|
||||
installLog("cache directory and subdirectory check passed");
|
||||
}
|
||||
|
||||
|
||||
// check modules dir
|
||||
$_SESSION['unwriteable_module_files'] = array();
|
||||
//if(!$writeableFiles['ret_val']) {
|
||||
$passed_write = recursive_make_writable('./modules');
|
||||
if (isset($_SESSION['unwriteable_module_files']['failed']) && $_SESSION['unwriteable_module_files']['failed']) {
|
||||
$passed_write = false;
|
||||
}
|
||||
|
||||
if (!$passed_write) {
|
||||
$moduleStatus = "<b><span class='stop'>{$mod_strings['ERR_CHECKSYS_NOT_WRITABLE']}</span></b>";
|
||||
installLog("ERROR:: Module directories and the files under them are not writeable.");
|
||||
$error_found = true;
|
||||
$error_txt .= '
|
||||
<p><strong>'.$mod_strings['LBL_CHECKSYS_MODULE'].'</strong></p>
|
||||
<p align="right" class="error">'.$moduleStatus.'</p>
|
||||
';
|
||||
|
||||
//list which module directories are not writeable, if there are less than 10
|
||||
$error_txt .= '
|
||||
<b>'.$mod_strings['LBL_CHECKSYS_FIX_MODULE_FILES'].'</b>';
|
||||
foreach ($_SESSION['unwriteable_module_files'] as $key=>$file) {
|
||||
if ($key !='.' && $key != 'failed') {
|
||||
$error_txt .='<br>'.$file;
|
||||
}
|
||||
}
|
||||
$error_txt .= '
|
||||
';
|
||||
} else {
|
||||
installLog("/module directory and subdirectory check passed");
|
||||
}
|
||||
|
||||
// check upload dir
|
||||
if (!make_writable('./upload')) {
|
||||
$uploadStatus = "<b><span class='stop'>{$mod_strings['ERR_CHECKSYS_NOT_WRITABLE']}</span></b>";
|
||||
installLog("ERROR: Upload directory is not writable.");
|
||||
$error_found = true;
|
||||
$error_txt .= '
|
||||
<p><strong>'.$mod_strings['LBL_CHECKSYS_UPLOAD'].'</strong></p>
|
||||
<p align="right" class="error">'.$uploadStatus.'</p>
|
||||
';
|
||||
} else {
|
||||
installLog("/upload directory check passed");
|
||||
}
|
||||
|
||||
// check zip file support
|
||||
if (!class_exists("ZipArchive")) {
|
||||
$zipStatus = "<span class='stop'><b>{$mod_strings['ERR_CHECKSYS_ZIP']}</b></span>";
|
||||
|
||||
installLog("ERROR: Zip support not found.");
|
||||
$error_found = true;
|
||||
$error_txt .= '
|
||||
<p><strong>'.$mod_strings['LBL_CHECKSYS_ZIP'].'</strong></p>
|
||||
<p align="right" class="error">'.$zipStatus.'</p>
|
||||
';
|
||||
} else {
|
||||
installLog("/zip check passed");
|
||||
}
|
||||
|
||||
|
||||
// check PCRE version
|
||||
if (defined('PCRE_VERSION')) {
|
||||
if (version_compare(PCRE_VERSION, '7.0') < 0) {
|
||||
installLog("ERROR: PCRE Version is less than 7.0.");
|
||||
$error_found = true;
|
||||
$pcreStatus = "<span class='stop'><b>{$mod_strings['ERR_CHECKSYS_PCRE_VER']}</b></span>";
|
||||
$error_txt .= '
|
||||
<p><strong>'.$mod_strings['LBL_CHECKSYS_PCRE'].'</strong></p>
|
||||
<p align="right" class="error">'.$pcreStatus.'</p>
|
||||
';
|
||||
} else {
|
||||
installLog("PCRE version check passed");
|
||||
}
|
||||
} else {
|
||||
installLog("ERROR: PCRE not found.");
|
||||
$error_found = true;
|
||||
$pcreStatus = "<span class='stop'><b>{$mod_strings['ERR_CHECKSYS_PCRE']}</b></span>";
|
||||
$error_txt .= '
|
||||
<p><strong>'.$mod_strings['LBL_CHECKSYS_PCRE'].'</strong></p>
|
||||
<p align="right" class="error">'.$pcreStatus.'</p>
|
||||
';
|
||||
}
|
||||
|
||||
|
||||
$customSystemChecks = installerHook('additionalCustomSystemChecks');
|
||||
if ($customSystemChecks != 'undefined') {
|
||||
if ($customSystemChecks['error_found'] == true) {
|
||||
$error_found = true;
|
||||
}
|
||||
if (!empty($customSystemChecks['error_txt'])) {
|
||||
$error_txt .= $customSystemChecks['error_txt'];
|
||||
}
|
||||
}
|
||||
|
||||
// PHP.ini
|
||||
$phpIniLocation = get_cfg_var("cfg_file_path");
|
||||
installLog("php.ini location found. {$phpIniLocation}");
|
||||
// disable form if error found
|
||||
|
||||
if ($error_found) {
|
||||
installLog("Outputting HTML for System check");
|
||||
installLog("Errors were found *************");
|
||||
$disabled = $error_found ? 'disabled="disabled"' : '';
|
||||
|
||||
$help_url = get_help_button_url();
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// BEGIN PAGE OUTPUT
|
||||
$out =<<<EOQ
|
||||
<h2>{$mod_strings['LBL_CHECKSYS_TITLE']}</h2>
|
||||
<div width="200" height="30" style="/*float: right;*/">
|
||||
<p>{$mod_strings['ERR_CHECKSYS']}</p>
|
||||
<hr>
|
||||
</div>
|
||||
<div id="errorheaders">
|
||||
<h2 style="float: right;">{$mod_strings['LBL_CHECKSYS_STATUS']}</h2>
|
||||
<h2 style="float: left;">{$mod_strings['LBL_CHECKSYS_COMPONENT']}</h2>
|
||||
</div>
|
||||
<div id="errormsg">
|
||||
<p>$error_txt</p>
|
||||
</div>
|
||||
<div align="center" style="margin: 5px;">
|
||||
<i>{$mod_strings['LBL_CHECKSYS_PHP_INI']}<br>{$phpIniLocation}</i>
|
||||
</div>
|
||||
<hr>
|
||||
<div id="installcontrols">
|
||||
<form action="install3.php" method="post" name="theForm" id="theForm">
|
||||
<input class="button" type="button" onclick="window.open('https://community.suitecrm.com');" value="{$mod_strings['LBL_HELP']}" />
|
||||
<input class="button" type="button" name="Re-check" value="{$mod_strings['LBL_CHECKSYS_RECHECK']}" onclick="callSysCheck();" id="button_next2"/>
|
||||
</form>
|
||||
</div>
|
||||
EOQ;
|
||||
return $out;
|
||||
} else {
|
||||
installLog("Outputting HTML for System check");
|
||||
installLog("No Errors were found *************");
|
||||
return 'passed';
|
||||
}
|
||||
}
|
||||
//// END PAGEOUTPUT
|
||||
///////////////////////////////////////////////////////////////////////////////
|
138
public/legacy/install/installType.php
Executable file
138
public/legacy/install/installType.php
Executable file
|
@ -0,0 +1,138 @@
|
|||
<?php
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
if (!isset($install_script) || !$install_script) {
|
||||
die($mod_strings['ERR_NO_DIRECT_SCRIPT']);
|
||||
}
|
||||
// $mod_strings come from calling page.
|
||||
|
||||
$langDropDown = get_select_options_with_id($supportedLanguages, $current_language);
|
||||
|
||||
|
||||
|
||||
if (!isset($_SESSION['licenseKey_submitted']) || !$_SESSION['licenseKey_submitted']) {
|
||||
$_SESSION['setup_license_key_users'] = 0;
|
||||
$_SESSION['setup_license_key_expire_date'] = "";
|
||||
$_SESSION['setup_license_key'] = "";
|
||||
$_SESSION['setup_num_lic_oc'] = 0;
|
||||
} else {
|
||||
}
|
||||
|
||||
//php version suggestion
|
||||
$php_suggested_ver = '';
|
||||
if (check_php_version() === -1) {
|
||||
$php_suggested_ver=$mod_strings['LBL_YOUR_PHP_VERSION'].phpversion().$mod_strings['LBL_RECOMMENDED_PHP_VERSION'];
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// START OUTPUT
|
||||
|
||||
$langHeader = get_language_header();
|
||||
$out = <<<EOQ
|
||||
<!doctype html>
|
||||
<html {$langHeader}>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<title>{$mod_strings['LBL_WIZARD_TITLE']} {$mod_strings['LBL_INSTALL_TYPE_TITLE']}</title> <link REL="SHORTCUT ICON" HREF="include/images/sugar_icon.ico">
|
||||
<link rel="stylesheet" href="install/install.css" type="text/css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/responsiveslides.css" type="text/css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/themes.css" type="text/css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/fontello.css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/animation.css"><!--[if IE 7]><link rel="stylesheet" href="css/fontello-ie7.css"><![endif]-->
|
||||
<script src="include/javascript/jquery/jquery-min.js"></script>
|
||||
</head>
|
||||
<body onload="javascript:document.getElementById('button_next').focus();">
|
||||
<!--SuiteCRM installer-->
|
||||
<div id="install_container">
|
||||
<div id="install_box">
|
||||
<header id="install_header">
|
||||
<div id="steps"><p>{$mod_strings['LBL_STEP3']}</p><i class="icon-progress-0" id="complete"></i><i class="icon-progress-1" id="complete"></i><i class="icon-progress-2"></i><i class="icon-progress-3"></i><i class="icon-progress-4"></i><i class="icon-progress-5"></i><i class="icon-progress-6"></i><i class="icon-progress-7"></i></div>
|
||||
<div class="install_img"><a href="https://suitecrm.com"><img src="{$sugar_md}" alt="SuiteCRM"></a></div>
|
||||
</header>
|
||||
<form action="install.php" method="post" name="form" id="form">
|
||||
<div id="install_content">
|
||||
EOQ;
|
||||
|
||||
$typical_checked ='checked';
|
||||
$custom_checked ='';
|
||||
if (isset($_SESSION['install_type']) && $_SESSION['install_type']=='custom') {
|
||||
$typical_checked ='';
|
||||
$custom_checked ='checked';
|
||||
} else {
|
||||
//do nothing because defaults handle this condition
|
||||
}
|
||||
|
||||
$out .= <<<EOQ2
|
||||
<div id="installoptions">
|
||||
<h2>{$mod_strings['LBL_INSTALL_TYPE_SUBTITLE']}</h2>
|
||||
<input name="install_type" type="radio" value="Typical" {$typical_checked}>{$mod_strings['LBL_INSTALL_TYPE_TYPICAL']}
|
||||
{$mod_strings['LBL_INSTALL_TYPE_MSG2']}
|
||||
<br>
|
||||
<input type="radio" name="install_type" value="custom" {$custom_checked}>{$mod_strings['LBL_INSTALL_TYPE_CUSTOM']}
|
||||
{$mod_strings['LBL_INSTALL_TYPE_MSG3']}
|
||||
<br>
|
||||
<b><i>{$php_suggested_ver}</i></b>
|
||||
<br>
|
||||
<hr>
|
||||
</div>
|
||||
</div>
|
||||
<div id="installcontrols">
|
||||
<input type="hidden" name="current_step" value="{$next_step}">
|
||||
<input class="button" type="button" value="{$mod_strings['LBL_BACK']}" id="button_back_installType" onclick="document.getElementById('form').submit();" />
|
||||
<input type="hidden" name="goto" value="{$mod_strings['LBL_BACK']}" />
|
||||
<input class="button" type="submit" name="goto" value="{$mod_strings['LBL_NEXT']}" id="button_next" />
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<footer id="install_footer">
|
||||
<p id="footer_links"><a href="https://suitecrm.com" target="_blank">Visit suitecrm.com</a> | <a href="https://suitecrm.com/suitecrm/forum" target="_blank">Support Forums</a> | <a href="https://docs.suitecrm.com/admin/installation-guide/" target="_blank">Installation Guide</a> | <a href="LICENSE.txt" target="_blank">License</a>
|
||||
</footer>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
EOQ2;
|
||||
echo $out;
|
101
public/legacy/install/install_defaults.php
Executable file
101
public/legacy/install/install_defaults.php
Executable file
|
@ -0,0 +1,101 @@
|
|||
<?php
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2019 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
|
||||
$installer_defaults = [
|
||||
'language' => 'en_us',
|
||||
'oc_install' => '',
|
||||
'setup_license_accept' => false,
|
||||
'test_session' => 'sessions are available',
|
||||
'license_submitted' => false,
|
||||
'setup_license_key_users' => '0',
|
||||
'setup_license_key_expire_date' => '',
|
||||
'setup_license_key' => '',
|
||||
'setup_num_lic_oc' => '0',
|
||||
'install_type' => 'typical',
|
||||
'setup_db_type' => 'mysql',
|
||||
'setup_db_host_name' => '',
|
||||
'setup_db_host_instance' => 'SQLEXPRESS',
|
||||
'setup_db_database_name' => 'suitecrm',
|
||||
'setup_db_sugarsales_user' => '',
|
||||
'setup_db_sugarsales_password' => '',
|
||||
'setup_db_sugarsales_password_retype' => '',
|
||||
'setup_db_create_database' => true,
|
||||
'setup_db_drop_tables' => false,
|
||||
'setup_db_username_is_privileged' => true,
|
||||
'setup_db_admin_user_name' => '',
|
||||
'setup_db_admin_password' => '',
|
||||
'setup_db_provide_own_user' => false,
|
||||
'dbConfig_submitted' => false,
|
||||
'demoData' => 'no',
|
||||
'setup_site_url' => '',
|
||||
'setup_system_name' => 'SuiteCRM',
|
||||
'setup_site_sugarbeet' => true,
|
||||
'setup_site_defaults' => true,
|
||||
'setup_site_custom_session_path' => false,
|
||||
'setup_site_session_path' => false,
|
||||
'setup_site_custom_log_dir' => false,
|
||||
'setup_site_log_dir' => false,
|
||||
'setup_site_log_level' => 'fatal',
|
||||
'setup_site_specify_guid' => false,
|
||||
'setup_site_guid' => '',
|
||||
'setup_site_admin_password' => '',
|
||||
'setup_site_admin_password_retype' => '',
|
||||
'site_default_theme' => 'suite8',
|
||||
'default_theme' => 'suite8',
|
||||
'disable_persistent_connections' => false,
|
||||
'default_language' => 'en_us',
|
||||
'default_charset' => 'UTF-8',
|
||||
'default_currency_name' => 'US Dollars',
|
||||
'default_currency_symbol' => '$',
|
||||
'default_currency_iso4217' => 'USD',
|
||||
'default_locale_name_format' => 's f l',
|
||||
'default_email_charset' => 'UTF-8',
|
||||
'default_export_charset' => 'UTF-8',
|
||||
'export_delimiter' => ',',
|
||||
'rss_cache_time' => '10800',
|
||||
'language_keys' => 'en_us',
|
||||
'language_values' => 'US+English',
|
||||
'setup_site_sugarbeet_automatic_checks' => true,
|
||||
'setup_site_sugarbeet_anonymous_stats' => true,
|
||||
'siteConfig_submitted' => false,
|
||||
'strict_id_validation' => false,
|
||||
'dbUSRData' => 'same',
|
||||
];
|
2334
public/legacy/install/install_utils.php
Executable file
2334
public/legacy/install/install_utils.php
Executable file
File diff suppressed because it is too large
Load diff
5
public/legacy/install/lang.config.php
Executable file
5
public/legacy/install/lang.config.php
Executable file
|
@ -0,0 +1,5 @@
|
|||
<?php
|
||||
|
||||
// ADDITIONAL LANGUAGES
|
||||
$config['languages'] = array(
|
||||
);
|
577
public/legacy/install/language/en_us.lang.php
Executable file
577
public/legacy/install/language/en_us.lang.php
Executable file
|
@ -0,0 +1,577 @@
|
|||
<?php
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2019 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
|
||||
$mod_strings = array(
|
||||
'LBL_BASIC_SEARCH' => 'Quick Filter',
|
||||
'LBL_ADVANCED_SEARCH' => 'Advanced Filter',
|
||||
'LBL_BASIC_TYPE' => 'Basic Type',
|
||||
'LBL_ADVANCED_TYPE' => 'Advanced Type',
|
||||
'LBL_SYSOPTS_2' => 'What type of database will be used for the SuiteCRM instance you are about to install?',
|
||||
'LBL_SYSOPTS_DB' => 'Specify Database Type',
|
||||
'LBL_SYSOPTS_DB_TITLE' => 'Database Type',
|
||||
'LBL_SYSOPTS_ERRS_TITLE' => 'Please fix the following errors before proceeding:',
|
||||
'ERR_DB_VERSION_FAILURE' => 'Unable to check database version.',
|
||||
'DEFAULT_CHARSET' => 'UTF-8',
|
||||
'ERR_ADMIN_USER_NAME_BLANK' => 'Provide the user name for the SuiteCRM admin user. ',
|
||||
'ERR_ADMIN_PASS_BLANK' => 'Provide the password for the SuiteCRM admin user. ',
|
||||
|
||||
'ERR_CHECKSYS' => 'Errors have been detected during compatibility check. In order for your SuiteCRM Installation to function properly, please take the proper steps to address the issues listed below and either press the recheck button, or try installing again.',
|
||||
'ERR_CHECKSYS_CALL_TIME' => 'Allow Call Time Pass Reference is On (this should be set to Off in php.ini)',
|
||||
'ERR_CHECKSYS_CURL' => 'Not found: SuiteCRM Scheduler will run with limited functionality.',
|
||||
'ERR_CHECKSYS_IMAP' => 'Not found: InboundEmail and Campaigns (Email) require the IMAP libraries. Neither will be functional.',
|
||||
'ERR_CHECKSYS_MEM_LIMIT_1' => ' (Set this to ',
|
||||
'ERR_CHECKSYS_MEM_LIMIT_2' => 'M or larger in your php.ini file)',
|
||||
'ERR_CHECKSYS_NOT_WRITABLE' => 'Warning: Not Writable',
|
||||
'ERR_CHECKSYS_PHP_INVALID_VER' => 'Your version of PHP is not supported by SuiteCRM. You will need to install a version that is compatible with the SuiteCRM application. Please consult the Compatibility Matrix in the Release Notes for supported PHP Versions. Your version is ',
|
||||
'ERR_CHECKSYS_IIS_INVALID_VER' => 'Your version of IIS is not supported by SuiteCRM. You will need to install a version that is compatible with the SuiteCRM application. Please consult the Compatibility Matrix in the Release Notes for supported IIS Versions. Your version is ',
|
||||
'ERR_CHECKSYS_FASTCGI' => 'We detect that you are not using a FastCGI handler mapping for PHP. You will need to install/configure a version that is compatible with the SuiteCRM application. Please consult the Compatibility Matrix in the Release Notes for supported Versions. Please see <a href="http://www.iis.net/php/" target="_blank">http://www.iis.net/php/</a> for details ',
|
||||
'ERR_CHECKSYS_FASTCGI_LOGGING' => 'For optimal experience using IIS/FastCGI sapi, set fastcgi.logging to 0 in your php.ini file.',
|
||||
'LBL_DB_UNAVAILABLE' => 'Database unavailable',
|
||||
'LBL_CHECKSYS_DB_SUPPORT_NOT_AVAILABLE' => 'Database Support was not found. Please make sure you have the necessary drivers for one of the following supported Database Types: MySQL or MS SQLServer. You might need to uncomment the extension in the php.ini file, or recompile with the right binary file, depending on your version of PHP. Please refer to your PHP Manual for more information on how to enable Database Support.',
|
||||
'LBL_CHECKSYS_XML_NOT_AVAILABLE' => 'Functions associated with XML Parser Libraries that are needed by the SuiteCRM application were not found. You might need to uncomment the extension in the php.ini file, or recompile with the right binary file, depending on your version of PHP. Please refer to your PHP Manual for more information.',
|
||||
'ERR_CHECKSYS_MBSTRING' => 'Functions associated with the Multibyte Strings PHP extension (mbstring) that are needed by the SuiteCRM application were not found. <br/><br/>Generally, the mbstring module is not enabled by default in PHP and must be activated with --enable-mbstring when the PHP binary is built. Please refer to your PHP Manual for more information on how to enable mbstring support.',
|
||||
'ERR_CHECKSYS_CONFIG_NOT_WRITABLE' => 'The config file exists but is not writeable. Please take the necessary steps to make the file writeable. Depending on your Operating system, this might require you to change the permissions by running chmod 766, or to right click on the filename to access the properties and uncheck the read only option.',
|
||||
'ERR_CHECKSYS_CONFIG_OVERRIDE_NOT_WRITABLE' => 'The config override file exists but is not writeable. Please take the necessary steps to make the file writeable. Depending on your Operating system, this might require you to change the permissions by running chmod 766, or to right click on the filename to access the properties and uncheck the read only option.',
|
||||
'ERR_CHECKSYS_CUSTOM_NOT_WRITABLE' => 'The Custom Directory exists but is not writeable. You may have to change permissions on it (chmod 766) or right click on it and uncheck the read only option, depending on your Operating System. Please take the needed steps to make the file writeable.',
|
||||
'ERR_CHECKSYS_FILES_NOT_WRITABLE' => "The files or directories listed below are not writeable or are missing and cannot be created. Depending on your Operating System, correcting this may require you to change permissions on the files or parent directory (chmod 755), or to right click on the parent directory and uncheck the 'read only' option and apply it to all subfolders.",
|
||||
'ERR_CHECKSYS_JSON_NOT_AVAILABLE' => "Functions associated with JSON Parser Libraries that are needed by the SuiteCRM application were not found. You might need to uncomment the extension in the php.ini file, or recompile with the right binary file, depending on your version of PHP. Please refer to your PHP Manual for more information.",
|
||||
'LBL_CHECKSYS_OVERRIDE_CONFIG' => 'Config override',
|
||||
'ERR_CHECKSYS_SAFE_MODE' => 'Safe Mode is On (you may wish to disable in php.ini)',
|
||||
'ERR_CHECKSYS_ZLIB' => 'ZLib support not found: SuiteCRM reaps enormous performance benefits with zlib compression.',
|
||||
'ERR_CHECKSYS_ZIP' => 'ZIP support not found: SuiteCRM needs ZIP support in order to process compressed files.',
|
||||
'ERR_CHECKSYS_PCRE' => 'PCRE library not found: SuiteCRM needs PCRE library in order to process Perl style of regular expression pattern matching.',
|
||||
'ERR_CHECKSYS_PCRE_VER' => 'PCRE library version: SuiteCRM needs PCRE library 7.0 or above to process Perl style of regular expression pattern matching.',
|
||||
'ERR_DB_ADMIN' => 'The provided database administrator username and/or password is invalid, and a connection to the database could not be established. Please enter a valid user name and password. (Error: ',
|
||||
'ERR_DB_ADMIN_MSSQL' => 'The provided database administrator username and/or password is invalid, and a connection to the database could not be established. Please enter a valid user name and password.',
|
||||
'ERR_DB_EXISTS_NOT' => 'The specified database does not exist.',
|
||||
'ERR_DB_EXISTS_WITH_CONFIG' => 'Database already exists with config data. To run an install with the chosen database, please re-run the install and choose: "Drop and recreate existing SuiteCRM tables?". To upgrade, use the Upgrade Wizard in the Admin Console. Please read the upgrade documentation located <a href="https://suitecrm.com/wiki/index.php/Upgrade" target="_new">here</a>.',
|
||||
'ERR_DB_EXISTS' => 'The provided Database Name already exists -- cannot create another one with the same name.',
|
||||
'ERR_DB_EXISTS_PROCEED' => 'The provided Database Name already exists. You can<br>1. hit the back button and choose a new database name <br>2. click next and continue but all existing tables on this database will be dropped. <strong>This means your tables and data will be blown away.</strong>',
|
||||
'ERR_DB_HOSTNAME' => 'Host name cannot be blank.',
|
||||
'ERR_DB_INVALID' => 'Invalid database type selected.',
|
||||
'ERR_DB_LOGIN_FAILURE' => 'The provided database host, username, and/or password is invalid, and a connection to the database could not be established. Please enter a valid host, username and password',
|
||||
'ERR_DB_LOGIN_FAILURE_MYSQL' => 'The provided database host, username, and/or password is invalid, and a connection to the database could not be established. Please enter a valid host, username and password',
|
||||
'ERR_DB_LOGIN_FAILURE_MSSQL' => 'The provided database host, username, and/or password is invalid, and a connection to the database could not be established. Please enter a valid host, username and password',
|
||||
'ERR_DB_MYSQL_VERSION' => 'Your MySQL version (%s) is not supported by SuiteCRM. You will need to install a version that is compatible with the SuiteCRM application. Please consult the Compatibility Matrix in the Release Notes for supported MySQL versions.',
|
||||
'ERR_DB_NAME' => 'Database name cannot be blank.',
|
||||
'ERR_DB_MYSQL_DB_NAME_INVALID' => "Database name cannot contain a '\\', '/', or '.'",
|
||||
'ERR_DB_MSSQL_DB_NAME_INVALID' => "Database name cannot begin with a number, '#', or '@' and cannot contain a space, '\"', \"'\", '*', '/', '\', '?', ':', '<', '>', '&', '!', or '-'",
|
||||
'ERR_DB_OCI8_DB_NAME_INVALID' => "Database name can only consist of alphanumeric characters and the symbols '#', '_' or '$'",
|
||||
'ERR_DB_PASSWORD' => 'The passwords provided for the SuiteCRM database administrator do not match. Please re-enter the same passwords in the password fields.',
|
||||
'ERR_DB_PRIV_USER' => 'Provide a database administrator user name. The user is required for the initial connection to the database.',
|
||||
'ERR_DB_USER_EXISTS' => 'User name for SuiteCRM database user already exists -- cannot create another one with the same name. Please enter a new user name.',
|
||||
'ERR_DB_USER' => 'Enter a user name for the SuiteCRM database administrator.',
|
||||
'ERR_DBCONF_VALIDATION' => 'Please fix the following errors before proceeding:',
|
||||
'ERR_DBCONF_PASSWORD_MISMATCH' => 'The passwords provided for the SuiteCRM database user do not match. Please re-enter the same passwords in the password fields.',
|
||||
'ERR_ERROR_GENERAL' => 'The following errors were encountered:',
|
||||
'ERR_LANG_CANNOT_DELETE_FILE' => 'Cannot delete file: ',
|
||||
'ERR_LANG_MISSING_FILE' => 'Cannot find file: ',
|
||||
'ERR_LANG_NO_LANG_FILE' => 'No language pack file found at include/language inside: ',
|
||||
'ERR_LANG_UPLOAD_1' => 'There was a problem with your upload. Please try again.',
|
||||
'ERR_LANG_UPLOAD_2' => 'Language Packs must be ZIP archives.',
|
||||
'ERR_LANG_UPLOAD_3' => 'PHP could not move the temp file to the upgrade directory.',
|
||||
'ERR_LOG_DIRECTORY_NOT_EXISTS' => 'Log directory provided is not a valid directory.',
|
||||
'ERR_LOG_DIRECTORY_NOT_WRITABLE' => 'Log directory provided is not a writable directory.',
|
||||
'ERR_NO_DIRECT_SCRIPT' => 'Unable to process script directly.',
|
||||
'ERR_NO_SINGLE_QUOTE' => 'Cannot use the single quotation mark for ',
|
||||
'ERR_PASSWORD_MISMATCH' => 'The passwords provided for the SuiteCRM admin user do not match. Please re-enter the same passwords in the password fields.',
|
||||
'ERR_PERFORM_CONFIG_PHP_1' => 'Cannot write to the <span class=stop>config.php</span> file.',
|
||||
'ERR_PERFORM_CONFIG_PHP_2' => 'You can continue this installation by manually creating the config.php file and pasting the configuration information below into the config.php file. However, you <strong>must </strong>create the config.php file before you continue to the next step.',
|
||||
'ERR_PERFORM_CONFIG_PHP_3' => 'Did you remember to create the config.php file?',
|
||||
'ERR_PERFORM_CONFIG_PHP_4' => 'Warning: Could not write to config.php file. Please ensure it exists.',
|
||||
'ERR_PERFORM_HTACCESS_1' => 'Cannot write to the ',
|
||||
'ERR_PERFORM_HTACCESS_2' => ' file.',
|
||||
'ERR_PERFORM_HTACCESS_3' => 'If you want to secure your log file from being accessible via browser, create an .htaccess file in your log directory with the line:',
|
||||
'ERR_PERFORM_NO_TCPIP' => '<b>We could not detect an Internet connection.</b> When you do have a connection, please visit <a href="http://www.suitecrm.com/">http://www.suitecrm.com/</a> to register with SuiteCRM. By letting us know a little bit about how your company plans to use SuiteCRM, we can ensure we are always delivering the right application for your business needs.',
|
||||
'ERR_SESSION_DIRECTORY_NOT_EXISTS' => 'Session directory provided is not a valid directory.',
|
||||
'ERR_SESSION_DIRECTORY' => 'Session directory provided is not a writable directory.',
|
||||
'ERR_SESSION_PATH' => 'Session path is required if you wish to specify your own.',
|
||||
'ERR_SI_NO_CONFIG' => 'You did not include config_si.php in the document root, or you did not define $sugar_config_si in config.php',
|
||||
'ERR_SITE_GUID' => 'Application ID is required if you wish to specify your own.',
|
||||
'ERROR_SPRITE_SUPPORT' => "Currently we are not able to locate the GD library, as a result you will not be able to use the CSS Sprite functionality.",
|
||||
'ERR_UPLOAD_MAX_FILESIZE' => 'Warning: Your PHP configuration should be changed to allow files of at least 6MB to be uploaded.',
|
||||
'LBL_UPLOAD_MAX_FILESIZE_TITLE' => 'Upload File Size',
|
||||
'ERR_URL_BLANK' => 'Provide the base URL for the SuiteCRM instance.',
|
||||
'ERR_UW_NO_UPDATE_RECORD' => 'Could not locate installation record of',
|
||||
'ERROR_MANIFEST_TYPE' => 'Manifest file must specify the package type.',
|
||||
'ERROR_PACKAGE_TYPE' => 'Manifest file specifies an unrecognized package type',
|
||||
'ERROR_VERSION_INCOMPATIBLE' => 'The uploaded file is not compatible with this version of SuiteCRM: ',
|
||||
|
||||
'LBL_BACK' => 'Back',
|
||||
'LBL_CANCEL' => 'Cancel',
|
||||
'LBL_ACCEPT' => 'I Accept',
|
||||
'LBL_CHECKSYS_CACHE' => 'Writable Cache Sub-Directories',
|
||||
'LBL_DROP_DB_CONFIRM' => 'The provided Database Name already exists.<br>You can either:<br>1. Click on the Cancel button and choose a new database name, or <br>2. Click the Accept button and continue. All existing tables in the database will be dropped. <strong>This means that all of the tables and pre-existing data will be blown away.</strong>',
|
||||
'LBL_CHECKSYS_COMPONENT' => 'Component',
|
||||
'LBL_CHECKSYS_CONFIG' => 'Writable SuiteCRM Configuration File (config.php)',
|
||||
'LBL_CHECKSYS_CURL' => 'cURL Module',
|
||||
'LBL_CHECKSYS_CUSTOM' => 'Writeable Custom Directory',
|
||||
'LBL_CHECKSYS_DATA' => 'Writable Data Sub-Directories',
|
||||
'LBL_CHECKSYS_IMAP' => 'IMAP Module',
|
||||
'LBL_CHECKSYS_FASTCGI' => 'FastCGI',
|
||||
'LBL_CHECKSYS_MBSTRING' => 'MB Strings Module',
|
||||
'LBL_CHECKSYS_MEM_OK' => 'OK (No Limit)',
|
||||
'LBL_CHECKSYS_MEM_UNLIMITED' => 'OK (Unlimited)',
|
||||
'LBL_CHECKSYS_MEM' => 'PHP Memory Limit',
|
||||
'LBL_CHECKSYS_MODULE' => 'Writable Modules Sub-Directories and Files',
|
||||
'LBL_CHECKSYS_NOT_AVAILABLE' => 'Not Available',
|
||||
'LBL_CHECKSYS_OK' => 'OK',
|
||||
'LBL_CHECKSYS_PHP_INI' => 'Location of your PHP configuration file (php.ini):',
|
||||
'LBL_CHECKSYS_PHP_OK' => 'OK (ver ',
|
||||
'LBL_CHECKSYS_PHPVER' => 'PHP Version',
|
||||
'LBL_CHECKSYS_IISVER' => 'IIS Version',
|
||||
'LBL_CHECKSYS_JSON' => 'JSON Parsing',
|
||||
'LBL_CHECKSYS_RECHECK' => 'Re-check',
|
||||
'LBL_CHECKSYS_STATUS' => 'Status',
|
||||
'LBL_CHECKSYS_TITLE' => 'System Check Acceptance',
|
||||
'LBL_CHECKSYS_XML' => 'XML Parsing',
|
||||
'LBL_CHECKSYS_ZLIB' => 'ZLIB Compression Module',
|
||||
'LBL_CHECKSYS_ZIP' => 'ZIP Handling Module',
|
||||
'LBL_CHECKSYS_PCRE' => 'PCRE Library',
|
||||
'LBL_CHECKSYS_FIX_FILES' => 'Please fix the following files or directories before proceeding:',
|
||||
'LBL_CHECKSYS_FIX_MODULE_FILES' => 'Please fix the following module directories and the files under them before proceeding:',
|
||||
'LBL_CHECKSYS_UPLOAD' => 'Writable Upload Directory',
|
||||
'LBL_CLOSE' => 'Close',
|
||||
'LBL_THREE' => '3',
|
||||
'LBL_CONFIRM_BE_CREATED' => 'be created',
|
||||
'LBL_CONFIRM_DB_TYPE' => 'Database Type',
|
||||
'LBL_CONFIRM_NOT' => 'not',
|
||||
'LBL_CONFIRM_TITLE' => 'Confirm Settings',
|
||||
'LBL_CONFIRM_WILL' => 'will',
|
||||
'LBL_DBCONF_DB_DROP' => 'Drop Tables',
|
||||
'LBL_DBCONF_DB_NAME' => 'Database Name',
|
||||
'LBL_DBCONF_DB_PASSWORD' => 'SuiteCRM Database User Password',
|
||||
'LBL_DBCONF_DB_PASSWORD2' => 'Re-enter SuiteCRM Database User Password',
|
||||
'LBL_DBCONF_DB_USER' => 'SuiteCRM Database User',
|
||||
'LBL_DBCONF_SUITE_DB_USER' => 'SuiteCRM Database User',
|
||||
'LBL_DBCONF_DB_ADMIN_USER' => 'Database Administrator Username',
|
||||
'LBL_DBCONF_DB_ADMIN_PASSWORD' => 'Database Admin Password',
|
||||
'LBL_DBCONF_COLLATION' => 'Collation',
|
||||
'LBL_DBCONF_CHARSET' => 'Character Set',
|
||||
'LBL_DBCONF_ADV_DB_CFG_TITLE' => 'Advanced Database Configuration',
|
||||
'LBL_DBCONF_DEMO_DATA' => 'Populate Database with Demo Data?',
|
||||
'LBL_DBCONF_DEMO_DATA_TITLE' => 'Choose Demo Data',
|
||||
'LBL_DBCONF_HOST_NAME' => 'Host Name',
|
||||
'LBL_DBCONF_HOST_INSTANCE' => 'Host Instance',
|
||||
'LBL_DBCONFIG_SECURITY' => 'For security purposes, you can specify an exclusive database user to connect to the SuiteCRM database. This user must be able to write, update and retrieve data on the SuiteCRM database that will be created for this instance. This user can be the database administrator specified above, or you can provide new or existing database user information.',
|
||||
'LBL_DBCONFIG_PROVIDE_DD' => 'Provide existing user',
|
||||
'LBL_DBCONFIG_CREATE_DD' => 'Define user to create',
|
||||
'LBL_DBCONFIG_SAME_DD' => 'Same as Admin User',
|
||||
'LBL_DBCONF_TITLE' => 'Database Configuration',
|
||||
'LBL_DBCONF_TITLE_NAME' => 'Provide Database Name',
|
||||
'LBL_DBCONF_TITLE_USER_INFO' => 'Provide Database User Information',
|
||||
'LBL_DBCONF_TITLE_PSWD_INFO_LABEL' => 'Password',
|
||||
'LBL_DISABLED_DESCRIPTION_2' => 'After this change has been made, you may click the "Start" button below to begin your installation. <i>After the installation is complete, you will want to change the value for \'installer_locked\' to \'true\'.</i>',
|
||||
'LBL_DISABLED_DESCRIPTION' => 'The installer has already been run once. As a safety measure, it has been disabled from running a second time. If you are absolutely sure you want to run it again, please go to your config.php file and locate (or add) a variable called \'installer_locked\' and set it to \'false\'. The line should look like this:',
|
||||
'LBL_DISABLED_HELP_1' => 'For installation help, please visit the SuiteCRM',
|
||||
'LBL_DISABLED_HELP_LNK' => 'https://community.suitecrm.com',
|
||||
'LBL_DISABLED_HELP_2' => 'support forums',
|
||||
'LBL_DISABLED_TITLE_2' => 'SuiteCRM Installation has been Disabled',
|
||||
'LBL_HELP' => 'Help',
|
||||
'LBL_INSTALL' => 'Install',
|
||||
'LBL_INSTALL_TYPE_TITLE' => 'Installation Options',
|
||||
'LBL_INSTALL_TYPE_SUBTITLE' => 'Choose Install Type',
|
||||
'LBL_INSTALL_TYPE_TYPICAL' => ' <b>Typical Install</b>',
|
||||
'LBL_INSTALL_TYPE_CUSTOM' => ' <b>Custom Install</b>',
|
||||
'LBL_INSTALL_TYPE_MSG2' => 'Requires minimum information for the installation. Recommended for new users.',
|
||||
'LBL_INSTALL_TYPE_MSG3' => 'Provides additional options to set during the installation. Most of these options are also available after installation in the admin screens. Recommended for advanced users.',
|
||||
'LBL_LANG_1' => 'To use a language in SuiteCRM other than the default language (US-English), you can upload and install the language pack at this time. You will be able to upload and install language packs from within the SuiteCRM application as well. If you would like to skip this step, click Next.',
|
||||
'LBL_LANG_BUTTON_COMMIT' => 'Install',
|
||||
'LBL_LANG_BUTTON_REMOVE' => 'Remove',
|
||||
'LBL_LANG_BUTTON_UNINSTALL' => 'Uninstall',
|
||||
'LBL_LANG_BUTTON_UPLOAD' => 'Upload',
|
||||
'LBL_LANG_NO_PACKS' => 'none',
|
||||
'LBL_LANG_PACK_INSTALLED' => 'The following language packs have been installed: ',
|
||||
'LBL_LANG_PACK_READY' => 'The following language packs are ready to be installed: ',
|
||||
'LBL_LANG_SUCCESS' => 'The language pack was successfully uploaded.',
|
||||
'LBL_LANG_TITLE' => 'Language Pack',
|
||||
'LBL_LAUNCHING_SILENT_INSTALL' => 'Installing SuiteCRM now. This may take up to a few minutes.',
|
||||
'LBL_LANG_UPLOAD' => 'Upload a Language Pack',
|
||||
'LBL_LICENSE_ACCEPTANCE' => 'License Acceptance',
|
||||
'LBL_LICENSE_CHECKING' => 'Checking system for compatibility.',
|
||||
'LBL_LICENSE_CHKENV_HEADER' => 'Checking Environment',
|
||||
'LBL_LICENSE_CHKDB_HEADER' => 'Verifying DB Credentials.',
|
||||
'LBL_LICENSE_CHECK_PASSED' => 'System passed check for compatibility.',
|
||||
'LBL_CREATE_CACHE' => 'Preparing to Install...',
|
||||
'LBL_LICENSE_REDIRECT' => 'Redirecting in ',
|
||||
'LBL_LICENSE_I_ACCEPT' => 'I Accept',
|
||||
'LBL_LICENSE_PRINTABLE' => ' Printable View ',
|
||||
'LBL_PRINT_SUMM' => 'Print Summary',
|
||||
'LBL_LICENSE_TITLE_2' => 'SuiteCRM License',
|
||||
|
||||
'LBL_LOCALE_NAME_FIRST' => 'David',
|
||||
'LBL_LOCALE_NAME_LAST' => 'Livingstone',
|
||||
'LBL_LOCALE_NAME_SALUTATION' => 'Dr.',
|
||||
|
||||
'LBL_ML_ACTION' => 'Action',
|
||||
'LBL_ML_DESCRIPTION' => 'Description',
|
||||
'LBL_ML_INSTALLED' => 'Date Installed',
|
||||
'LBL_ML_NAME' => 'Name',
|
||||
'LBL_ML_PUBLISHED' => 'Date Published',
|
||||
'LBL_ML_TYPE' => 'Type',
|
||||
'LBL_ML_UNINSTALLABLE' => 'Uninstallable',
|
||||
'LBL_ML_VERSION' => 'Version',
|
||||
'LBL_MSSQL' => 'SQL Server',
|
||||
'LBL_MSSQL2' => 'SQL Server (FreeTDS)',
|
||||
'LBL_MSSQL_SQLSRV' => 'SQL Server (Microsoft SQL Server Driver for PHP)',
|
||||
'LBL_MYSQL' => 'MySQL',
|
||||
'LBL_MYSQLI' => 'MySQL (mysqli extension)',
|
||||
'LBL_NEXT' => 'Next',
|
||||
'LBL_NO' => 'No',
|
||||
'LBL_PERFORM_ADMIN_PASSWORD' => 'Setting site admin password',
|
||||
'LBL_PERFORM_CONFIG_PHP' => 'Creating SuiteCRM configuration file',
|
||||
'LBL_PERFORM_CREATE_DB_1' => '<b>Creating the database</b> ',
|
||||
'LBL_PERFORM_CREATE_DB_2' => ' <b>on</b> ',
|
||||
'LBL_PERFORM_CREATE_DB_USER' => 'Creating the Database username and password...',
|
||||
'LBL_PERFORM_CREATE_DEFAULT' => 'Creating default SuiteCRM data',
|
||||
'LBL_PERFORM_DEFAULT_SCHEDULER' => 'Creating default scheduler jobs',
|
||||
'LBL_PERFORM_DEFAULT_USERS' => 'Creating default users',
|
||||
'LBL_PERFORM_DEMO_DATA' => 'Populating the database tables with demo data (this may take a little while)',
|
||||
'LBL_PERFORM_DONE' => 'done<br>',
|
||||
'LBL_PERFORM_FINISH' => 'Finish',
|
||||
'LBL_PERFORM_OUTRO_1' => 'The setup of SuiteCRM ',
|
||||
'LBL_PERFORM_OUTRO_2' => ' is now complete!',
|
||||
'LBL_PERFORM_OUTRO_3' => 'Total time: ',
|
||||
'LBL_PERFORM_OUTRO_4' => ' seconds.',
|
||||
'LBL_PERFORM_OUTRO_5' => 'Approximate memory used: ',
|
||||
'LBL_PERFORM_OUTRO_6' => ' bytes.',
|
||||
'LBL_PERFORM_SUCCESS' => 'Success!',
|
||||
'LBL_PERFORM_TABLES' => 'Creating SuiteCRM application tables, audit tables and relationship metadata',
|
||||
'LBL_PERFORM_TITLE' => 'Perform Setup',
|
||||
'LBL_PRINT' => 'Print',
|
||||
'LBL_REG_CONF_1' => 'Please complete the short form below to receive product announcements, training news, special offers and special event invitations from SuiteCRM. We do not sell, rent, share or otherwise distribute the information collected here to third parties.',
|
||||
'LBL_REG_CONF_3' => 'Thank you for registering. Click on the Finish button to login to SuiteCRM. You will need to log in for the first time using the username "admin" and the password you entered in step 2.',
|
||||
'LBL_REG_TITLE' => 'Registration',
|
||||
|
||||
'LBL_REQUIRED' => '* Required field',
|
||||
|
||||
'LBL_SITECFG_ADMIN_Name' => 'SuiteCRM Application Admin Name',
|
||||
'LBL_SITECFG_ADMIN_PASS_2' => 'Re-enter SuiteCRM Admin User Password',
|
||||
'LBL_SITECFG_ADMIN_PASS' => 'SuiteCRM Admin User Password',
|
||||
'LBL_SITECFG_APP_ID' => 'Application ID',
|
||||
'LBL_SITECFG_CUSTOM_ID_DIRECTIONS' => 'If selected, you must provide an application ID to override the auto-generated ID. The ID ensures that sessions of one SuiteCRM instance are not used by other instances. If you have a cluster of SuiteCRM installations, they all must share the same application ID.',
|
||||
'LBL_SITECFG_CUSTOM_ID' => 'Provide Your Own Application ID',
|
||||
'LBL_SITECFG_CUSTOM_LOG_DIRECTIONS' => 'If selected, you must specify a log directory to override the default directory for the SuiteCRM log. Regardless of where the log file is located, access to it through a web browser will be restricted via an .htaccess redirect.',
|
||||
'LBL_SITECFG_CUSTOM_LOG' => 'Use a Custom Log Directory',
|
||||
'LBL_SITECFG_CUSTOM_SESSION_DIRECTIONS' => 'If selected, you must provide a secure folder for storing SuiteCRM session information. This can be done to prevent session data from being vulnerable on shared servers.',
|
||||
'LBL_SITECFG_CUSTOM_SESSION' => 'Use a Custom Session Directory for SuiteCRM',
|
||||
'LBL_SITECFG_FIX_ERRORS' => '<b>Please fix the following errors before proceeding:</b>',
|
||||
'LBL_SITECFG_LOG_DIR' => 'Log Directory',
|
||||
'LBL_SITECFG_SESSION_PATH' => 'Path to Session Directory<br>(must be writable)',
|
||||
'LBL_SITECFG_SITE_SECURITY' => 'Select Security Options',
|
||||
'LBL_SITECFG_SUITE_UP_DIRECTIONS' => 'If selected, the system will periodically check for updated versions of the application.',
|
||||
'LBL_SITECFG_SUITE_UP' => 'Automatically Check For Updates?',
|
||||
'LBL_SITECFG_TITLE' => 'Site Configuration',
|
||||
'LBL_SITECFG_TITLE2' => 'Identify Administration User',
|
||||
'LBL_SITECFG_SECURITY_TITLE' => 'Site Security',
|
||||
'LBL_SITECFG_URL' => 'URL of SuiteCRM Instance',
|
||||
'LBL_SITECFG_ANONSTATS' => 'Send Anonymous Usage Statistics?',
|
||||
'LBL_SITECFG_ANONSTATS_DIRECTIONS' => 'If selected, SuiteCRM will send <b>anonymous</b> statistics about your installation to SuiteCRM Inc. every time your system checks for new versions. This information will help us better understand how the application is used and guide improvements to the product.',
|
||||
'LBL_SITECFG_URL_MSG' => 'Enter the URL that will be used to access the SuiteCRM instance after installation. The URL will also be used as a base for the URLs in the SuiteCRM application pages. The URL should include the web server or machine name or IP address.',
|
||||
'LBL_SITECFG_SYS_NAME_MSG' => 'Enter a name for your system. This name will be displayed in the browser title bar when users visit the SuiteCRM application.',
|
||||
'LBL_SITECFG_PASSWORD_MSG' => 'After installation, you will need to use the SuiteCRM admin user (default username = admin) to log in to the SuiteCRM instance. Enter a password for this administrator user. This password can be changed after the initial login. You may also enter another admin username to use besides the default value provided.',
|
||||
'LBL_SITECFG_COLLATION_MSG' => 'Select collation (sorting) settings for your system. This settings will create the tables with the specific language you use. In case your language doesn\'t require special settings please use default value.',
|
||||
'LBL_SPRITE_SUPPORT' => 'Sprite Support',
|
||||
'LBL_SYSTEM_CREDS' => 'System Credentials',
|
||||
'LBL_SYSTEM_ENV' => 'System Environment',
|
||||
'LBL_SHOW_PASS' => 'Show Passwords',
|
||||
'LBL_HIDE_PASS' => 'Hide Passwords',
|
||||
'LBL_HIDDEN' => '<i>(hidden)</i>',
|
||||
'LBL_STEP1' => 'Step 1 of 2 - Pre-Installation requirements',
|
||||
'LBL_STEP2' => 'Step 2 of 2 - Configuration',
|
||||
'LBL_STEP' => 'Step',
|
||||
'LBL_TITLE_WELCOME' => 'Welcome to the SuiteCRM ',
|
||||
//welcome page variables
|
||||
'LBL_TITLE_ARE_YOU_READY' => 'Are you ready to install?',
|
||||
'REQUIRED_SYS_COMP' => 'Required System Components',
|
||||
'REQUIRED_SYS_COMP_MSG' =>
|
||||
'Before you begin, please be sure that you have the supported versions of the following system components:<br>
|
||||
<ul>
|
||||
<li> Database/Database Management System (Examples: MariaDB, MySQL or SQL Server)</li>
|
||||
<li> Web Server (Apache, IIS)</li>
|
||||
</ul>
|
||||
Consult the Compatibility Matrix in the Release Notes for
|
||||
compatible system components for the SuiteCRM version that you are installing.<br>',
|
||||
'REQUIRED_SYS_CHK' => 'Initial System Check',
|
||||
'REQUIRED_SYS_CHK_MSG' =>
|
||||
'When you begin the installation process, a system check will be performed on the web server on which the SuiteCRM files are located in order to
|
||||
make sure the system is configured properly and has all of the necessary components
|
||||
to successfully complete the installation. <br><br>
|
||||
The system checks all of the following:<br>
|
||||
<ul>
|
||||
<li><b>PHP version</b> – must be compatible with the application</li>
|
||||
<li><b>Session Variables</b> – must be working properly</li>
|
||||
<li><b>MB Strings</b> – must be installed and enabled in php.ini</li>
|
||||
<li><b>Database Support</b> – must exist for MariaDB, MySQL or SQL Server</li>
|
||||
<li><b>Config.php</b> – must exist and must have the appropriate permissions to make it writeable</li>
|
||||
<li>The following SuiteCRM files must be writeable:<ul><li><b>/custom</li>
|
||||
<li>/cache</li>
|
||||
<li>/modules</li>
|
||||
<li>/upload</b></li></ul></li></ul>
|
||||
If the check fails, you will not be able to proceed with the installation.
|
||||
An error message will be displayed, explaining why your system did not pass the check.
|
||||
After making any necessary changes, you can undergo the system check again to continue the installation.<br>',
|
||||
|
||||
|
||||
'REQUIRED_INSTALLTYPE' => 'Typical or Custom install',
|
||||
'REQUIRED_INSTALLTYPE_MSG' =>
|
||||
'After the system check is performed, you can choose either
|
||||
the Typical or the Custom installation.<br><br>
|
||||
For both <b>Typical</b> and <b>Custom</b> installations, you will need to know the following:<br>
|
||||
<ul>
|
||||
<li> <b>Type of database</b> that will house the SuiteCRM data <ul><li>Compatible database
|
||||
types: MariaDB, MySQL or SQL Server.<br><br></li></ul></li>
|
||||
<li> <b>Name of the web server</b> or machine (host) on which the database is located
|
||||
<ul><li>This may be <i>localhost</i> if the database is on your local computer or is on the same web server or machine as your SuiteCRM files.<br><br></li></ul></li>
|
||||
<li><b>Name of the database</b> that you would like to use to house the SuiteCRM data</li>
|
||||
<ul>
|
||||
<li> You might already have an existing database that you would like to use. If
|
||||
you provide the name of an existing database, the tables in the database will
|
||||
be dropped during installation when the schema for the SuiteCRM database is defined.</li>
|
||||
<li> If you do not already have a database, the name you provide will be used for
|
||||
the new database that is created for the instance during installation.<br><br></li>
|
||||
</ul>
|
||||
<li><b>Database administrator user name and password</b> <ul><li>The database administrator should be able to create tables and users and write to the database.</li><li>You might need to
|
||||
contact your database administrator for this information if the database is
|
||||
not located on your local computer and/or if you are not the database administrator.<br><br></ul></li></li>
|
||||
<li> <b>SuiteCRM database user name and password</b>
|
||||
</li>
|
||||
<ul>
|
||||
<li> The user may be the database administrator, or you may provide the name of
|
||||
another existing database user. </li>
|
||||
<li> If you would like to create a new database user for this purpose, you will
|
||||
be able to provide a new username and password during the installation process,
|
||||
and the user will be created during installation. </li>
|
||||
</ul></ul><p>
|
||||
|
||||
For the <b>Custom</b> setup, you might also need to know the following:<br>
|
||||
<ul>
|
||||
<li> <b>URL that will be used to access the SuiteCRM instance</b> after it is installed.
|
||||
This URL should include the web server or machine name or IP address.<br><br></li>
|
||||
<li> [Optional] <b>Path to the session directory</b> if you wish to use a custom
|
||||
session directory for SuiteCRM information in order to prevent session data from
|
||||
being vulnerable on shared servers.<br><br></li>
|
||||
<li> [Optional] <b>Path to a custom log directory</b> if you wish to override the default directory for the SuiteCRM log.<br><br></li>
|
||||
<li> [Optional] <b>Application ID</b> if you wish to override the auto-generated
|
||||
ID that ensures that sessions of one SuiteCRM instance are not used by other instances.<br><br></li>
|
||||
<li><b>Character Set</b> most commonly used in your locale.<br><br></li></ul>
|
||||
For more detailed information, please consult the Installation Guide.
|
||||
',
|
||||
'LBL_WELCOME_PLEASE_READ_BELOW' => 'Please read the following important information before proceeding with the installation. The information will help you determine whether or not you are ready to install the application at this time.',
|
||||
|
||||
'LBL_WELCOME_CHOOSE_LANGUAGE' => '<b>Choose your language</b>',
|
||||
'LBL_WELCOME_SETUP_WIZARD' => 'Setup Wizard',
|
||||
'LBL_WIZARD_TITLE' => 'SuiteCRM Setup Wizard: ',
|
||||
'LBL_YES' => 'Yes',
|
||||
|
||||
'LBL_PATCHES_TITLE' => 'Install Latest Patches',
|
||||
'LBL_MODULE_TITLE' => 'Install Language Packs',
|
||||
'LBL_PATCH_1' => 'If you would like to skip this step, click Next.',
|
||||
'LBL_PATCH_TITLE' => 'System Patch',
|
||||
'LBL_PATCH_READY' => 'The following patch(es) are ready to be installed:',
|
||||
'LBL_SESSION_ERR_DESCRIPTION' => "SuiteCRM relies upon PHP sessions to store important information while connected to this web server. Your PHP installation does not have the Session information correctly configured.
|
||||
<br><br>A common misconfiguration is that the <b>'session.save_path'</b> directive is not pointing to a valid directory. <br>
|
||||
<br> Please correct your <a target=_new href='http://us2.php.net/manual/en/ref.session.php'>PHP configuration</a> in the php.ini file located here below.",
|
||||
'LBL_SESSION_ERR_TITLE' => 'PHP Sessions Configuration Error',
|
||||
'LBL_SYSTEM_NAME' => 'System Name',
|
||||
'LBL_COLLATION' => 'Collation Settings',
|
||||
'LBL_REQUIRED_SYSTEM_NAME' => 'Provide a System Name for the SuiteCRM instance.',
|
||||
'LBL_PATCH_UPLOAD' => 'Select a patch file from your local computer',
|
||||
'LBL_INCOMPATIBLE_PHP_VERSION' => 'Php version 5 or above is required.',
|
||||
'LBL_MINIMUM_PHP_VERSION' => 'Minimum Php version required is 5.1.0. Recommended Php version is 5.2.x.',
|
||||
'LBL_YOUR_PHP_VERSION' => '(Your current php version is ',
|
||||
'LBL_RECOMMENDED_PHP_VERSION' => ' Recommended php version is 5.2.x)',
|
||||
'LBL_BACKWARD_COMPATIBILITY_ON' => 'Php Backward Compatibility mode is turned on. Set zend.ze1_compatibility_mode to Off for proceeding further',
|
||||
'LBL_STREAM' => 'PHP allows to use stream',
|
||||
|
||||
'advanced_password_new_account_email' => array(
|
||||
'subject' => 'New account information',
|
||||
'type' => 'system',
|
||||
'description' => 'This template is used when the System Administrator sends a new password to a user.',
|
||||
'body' => '<div><table border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width="550" align=\"\"\"center\"\"\"><tbody><tr><td colspan=\"2\"><p>Here is your account username and temporary password:</p><p>Username : $contact_user_user_name </p><p>Password : $contact_user_user_hash </p><br><p>$config_site_url</p><br><p>After you log in using the above password, you may be required to reset the password to one of your own choice.</p> </td> </tr><tr><td colspan=\"2\"></td> </tr> </tbody></table> </div>',
|
||||
'txt_body' =>
|
||||
'
|
||||
Here is your account username and temporary password:
|
||||
Username : $contact_user_user_name
|
||||
Password : $contact_user_user_hash
|
||||
|
||||
$config_site_url
|
||||
|
||||
After you log in using the above password, you may be required to reset the password to one of your own choice.',
|
||||
'name' => 'System-generated password email',
|
||||
),
|
||||
'advanced_password_forgot_password_email' => array(
|
||||
'subject' => 'Reset your account password',
|
||||
'type' => 'system',
|
||||
'description' => "This template is used to send a user a link to click to reset the user's account password.",
|
||||
'body' => '<div><table border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width="550" align=\"\"\"center\"\"\"><tbody><tr><td colspan=\"2\"><p>You recently requested on $contact_user_pwd_last_changed to be able to reset your account password. </p><p>Click on the link below to reset your password:</p><p> $contact_user_link_guid </p> </td> </tr><tr><td colspan=\"2\"></td> </tr> </tbody></table> </div>',
|
||||
'txt_body' =>
|
||||
'
|
||||
You recently requested on $contact_user_pwd_last_changed to be able to reset your account password.
|
||||
|
||||
Click on the link below to reset your password:
|
||||
|
||||
$contact_user_link_guid',
|
||||
'name' => 'Forgot Password email',
|
||||
),
|
||||
|
||||
|
||||
'two_factor_auth_email' => array(
|
||||
'subject' => 'Two Factor Authentication Code',
|
||||
'type' => 'system',
|
||||
'description' => "This template is used to send a user a code for Two Factor Authentication.",
|
||||
'body' => '<div><table border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width="550" align=\"\"\"center\"\"\"><tbody><tr><td colspan=\"2\"><p>Two Factor Authentication code is <b>$code</b>.</p> </td> </tr><tr><td colspan=\"2\"></td> </tr> </tbody></table> </div>',
|
||||
'txt_body' =>
|
||||
'Two Factor Authentication code is $code.',
|
||||
'name' => 'Two Factor Authentication email',
|
||||
),
|
||||
|
||||
// SMTP settings
|
||||
|
||||
'LBL_FROM_NAME' => '"From" Name:',
|
||||
'LBL_FROM_ADDR' => '"From" Address:',
|
||||
|
||||
'LBL_WIZARD_SMTP_DESC' => 'Provide the email account that will be used to send emails, such as the assignment notifications and new user passwords. Users will receive emails from SuiteCRM, as sent from the specified email account.',
|
||||
'LBL_CHOOSE_EMAIL_PROVIDER' => 'Choose your Email provider:',
|
||||
|
||||
'LBL_SMTPTYPE_GMAIL' => 'Gmail',
|
||||
'LBL_SMTPTYPE_YAHOO' => 'Yahoo! Mail',
|
||||
'LBL_SMTPTYPE_EXCHANGE' => 'Microsoft Exchange',
|
||||
'LBL_SMTPTYPE_OTHER' => 'Other',
|
||||
'LBL_MAIL_SMTP_SETTINGS' => 'SMTP Server Specification',
|
||||
'LBL_MAIL_SMTPSERVER' => 'SMTP Server:',
|
||||
'LBL_MAIL_SMTPPORT' => 'SMTP Port:',
|
||||
'LBL_MAIL_SMTPAUTH_REQ' => 'Use SMTP Authentication?',
|
||||
'LBL_EMAIL_SMTP_SSL_OR_TLS' => 'Enable SMTP over SSL or TLS?',
|
||||
'LBL_GMAIL_SMTPUSER' => 'Gmail Email Address:',
|
||||
'LBL_GMAIL_SMTPPASS' => 'Gmail Password:',
|
||||
'LBL_ALLOW_DEFAULT_SELECTION' => 'Allow users to use this account for outgoing email:',
|
||||
'LBL_ALLOW_DEFAULT_SELECTION_HELP' => 'When this option is selected, all users will be able to send emails using the same outgoing mail account used to send system notifications and alerts. If the option is not selected, users can still use the outgoing mail server after providing their own account information.',
|
||||
|
||||
'LBL_YAHOOMAIL_SMTPPASS' => 'Yahoo! Mail Password:',
|
||||
'LBL_YAHOOMAIL_SMTPUSER' => 'Yahoo! Mail ID:',
|
||||
|
||||
'LBL_EXCHANGE_SMTPPASS' => 'Exchange Password:',
|
||||
'LBL_EXCHANGE_SMTPUSER' => 'Exchange Username:',
|
||||
'LBL_EXCHANGE_SMTPPORT' => 'Exchange Server Port:',
|
||||
'LBL_EXCHANGE_SMTPSERVER' => 'Exchange Server:',
|
||||
|
||||
|
||||
'LBL_MAIL_SMTPUSER' => 'SMTP Username:',
|
||||
'LBL_MAIL_SMTPPASS' => 'SMTP Password:',
|
||||
|
||||
// Branding
|
||||
|
||||
'LBL_WIZARD_SYSTEM_TITLE' => 'Branding',
|
||||
'LBL_WIZARD_SYSTEM_DESC' => 'Provide your organization\'s name and logo in order to brand your SuiteCRM.',
|
||||
'SYSTEM_NAME_WIZARD' => 'Name:',
|
||||
'SYSTEM_NAME_HELP' => 'This is the name that displays in the title bar of your browser.',
|
||||
'NEW_LOGO' => 'Select Logo:',
|
||||
'NEW_LOGO_HELP' => 'The image file format can be either .png or .jpg. The maximum height is 170px, and the maximum width is 450px. Any image uploaded that is larger in any direction will be scaled to these max dimensions.',
|
||||
'COMPANY_LOGO_UPLOAD_BTN' => 'Upload',
|
||||
'CURRENT_LOGO' => 'Current Logo:',
|
||||
'CURRENT_LOGO_HELP' => 'This logo is displayed in the centre of the login screen of the SuiteCRM application.',
|
||||
|
||||
|
||||
//Scenario selection of modules
|
||||
'LBL_WIZARD_SCENARIO_TITLE' => 'Scenario Selection',
|
||||
'LBL_WIZARD_SCENARIO_DESC' => 'This is to allow tailoring of the displayed modules based on your requirements. Each of the modules can be enabled after install using the administration page.',
|
||||
'LBL_WIZARD_SCENARIO_EMPTY' => 'There are no scenarios currently set in the configuration file (config.php)',
|
||||
|
||||
|
||||
// System Local Settings
|
||||
|
||||
|
||||
'LBL_LOCALE_TITLE' => 'System Locale Settings',
|
||||
'LBL_WIZARD_LOCALE_DESC' => 'Specify how you would like data in SuiteCRM to be displayed, based on your geographical location. The settings you provide here will be the default settings. Users will be able set their own preferences.',
|
||||
'LBL_DATE_FORMAT' => 'Date Format:',
|
||||
'LBL_TIME_FORMAT' => 'Time Format:',
|
||||
'LBL_TIMEZONE' => 'Time Zone:',
|
||||
'LBL_LANGUAGE' => 'Language:',
|
||||
'LBL_CURRENCY' => 'Currency:',
|
||||
'LBL_CURRENCY_SYMBOL' => 'Currency Symbol:',
|
||||
'LBL_CURRENCY_ISO4217' => 'ISO 4217 Currency Code:',
|
||||
'LBL_NUMBER_GROUPING_SEP' => '1000s separator:',
|
||||
'LBL_DECIMAL_SEP' => 'Decimal symbol:',
|
||||
'LBL_NAME_FORMAT' => 'Name Format:',
|
||||
'UPLOAD_LOGO' => 'Please wait, logo uploading...',
|
||||
'ERR_UPLOAD_FILETYPE' => 'File type not allowed, please upload a jpeg or png.',
|
||||
'ERR_LANG_UPLOAD_UNKNOWN' => 'Unknown file upload error occurred.',
|
||||
'ERR_UPLOAD_FILE_UPLOAD_ERR_INI_SIZE' => 'The uploaded file exceeds the upload_max_filesize directive in php.ini.',
|
||||
'ERR_UPLOAD_FILE_UPLOAD_ERR_FORM_SIZE' => 'The uploaded file exceeds the MAX_FILE_SIZE directive that was specified in the HTML form.',
|
||||
'ERR_UPLOAD_FILE_UPLOAD_ERR_PARTIAL' => 'The uploaded file was only partially uploaded.',
|
||||
'ERR_UPLOAD_FILE_UPLOAD_ERR_NO_FILE' => 'No file was uploaded.',
|
||||
'ERR_UPLOAD_FILE_UPLOAD_ERR_NO_TMP_DIR' => 'Missing a temporary folder.',
|
||||
'ERR_UPLOAD_FILE_UPLOAD_ERR_CANT_WRITE' => 'Failed to write file to disk.',
|
||||
'ERR_UPLOAD_FILE_UPLOAD_ERR_EXTENSION' => 'A PHP extension stopped the file upload. PHP does not provide a way to ascertain which extension caused the file upload to stop.',
|
||||
|
||||
'LBL_INSTALL_PROCESS' => 'Install...',
|
||||
|
||||
'LBL_EMAIL_ADDRESS' => 'Email Address:',
|
||||
'ERR_ADMIN_EMAIL' => 'Administrator Email Address is incorrect.',
|
||||
'ERR_SITE_URL' => 'Site URL is required.',
|
||||
|
||||
'STAT_CONFIGURATION' => 'Configuration relationships...',
|
||||
'STAT_CREATE_DB' => 'Create database...',
|
||||
|
||||
'STAT_CREATE_DEFAULT_SETTINGS' => 'Create default settings...',
|
||||
'STAT_INSTALL_FINISH' => 'Install finish...',
|
||||
'STAT_INSTALL_FINISH_LOGIN' => 'Installation process finished, <a href="%s">please log in...</a>',
|
||||
'LBL_LICENCE_TOOLTIP' => 'Please accept license first',
|
||||
|
||||
'LBL_MORE_OPTIONS_TITLE' => 'More options',
|
||||
'LBL_START' => '',
|
||||
'LBL_DB_CONN_ERR' => 'Database error',
|
||||
'LBL_OLD_PHP' => 'Old PHP Version Detected!',
|
||||
'LBL_OLD_PHP_MSG' => 'The recommended PHP version to install SuiteCRM is %s <br />Although the minimum PHP version required is %s, is not recommended due to the large number of fixed bugs, including security fixes, released in the more modern versions.<br />You are using PHP version %s, which is EOL: <a href="http://php.net/eol.php">http://php.net/eol.php</a>.<br />Please consider upgrading your PHP version. Instructions on <a href="http://php.net/migration70">http://php.net/migration70</a>. ',
|
||||
'LBL_OLD_PHP_OK' => 'I\'m aware of the risks and wish to continue.',
|
||||
|
||||
'LBL_DBCONF_TITLE_USER_INFO_LABEL' => 'User',
|
||||
'LBL_DBCONFIG_MSG3_LABEL' => 'Database Name',
|
||||
'LBL_DBCONFIG_MSG3' => 'Name of the database that will contain the data for the SuiteCRM instance you are about to install.',
|
||||
'LBL_DBCONFIG_MSG2_LABEL' => 'Host Name',
|
||||
'LBL_DBCONFIG_MSG2' => 'Name of web server or machine (host) on which the database is located (such as www.mydomain.com). If installing locally, it\'s better to use \'localhost\' than \'127.0.0.1\', for performance reasons.',
|
||||
'LBL_DBCONFIG_B_MSG1_LABEL' => '', // this label dynamically needed in install/installConfig.php:293
|
||||
'LBL_DBCONFIG_B_MSG1' => 'The username and password of a database administrator who can create database tables and users and who can write to the database is necessary in order to set up the SuiteCRM database.'
|
||||
);
|
42
public/legacy/install/license.js
Executable file
42
public/legacy/install/license.js
Executable file
|
@ -0,0 +1,42 @@
|
|||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/function toggleLicenseAccept(){var theForm=document.forms[0];if(theForm.setup_license_accept.checked){theForm.setup_license_accept.checked="";}
|
||||
else{theForm.setup_license_accept.checked="yes";}
|
||||
toggleNextButton();}
|
||||
function toggleNextButton(){var theForm=document.forms[0];var nextButton=document.getElementById("button_next");if(theForm.setup_license_accept.checked){nextButton.disabled='';nextButton.focus();}
|
||||
else{nextButton.disabled="disabled";}}
|
215
public/legacy/install/license.php
Executable file
215
public/legacy/install/license.php
Executable file
|
@ -0,0 +1,215 @@
|
|||
<?php
|
||||
//if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
|
||||
|
||||
global $sugar_version, $js_custom_version;
|
||||
if (!isset($install_script) || !$install_script) {
|
||||
die('Unable to process script directly.');
|
||||
}
|
||||
|
||||
// setup session variables (and their defaults) if this page has not yet been submitted
|
||||
if (!isset($_SESSION['license_submitted']) || !$_SESSION['license_submitted']) {
|
||||
$_SESSION['setup_license_accept'] = false;
|
||||
}
|
||||
|
||||
$checked = (isset($_SESSION['setup_license_accept']) && !empty($_SESSION['setup_license_accept'])) ? 'checked="on"' : '';
|
||||
|
||||
require_once("install/install_utils.php");
|
||||
$license_file = getLicenseContents("LICENSE.txt");
|
||||
$langHeader = get_language_header();
|
||||
$out =<<<EOQ
|
||||
<!DOCTYPE HTML>
|
||||
<html {$langHeader}>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<title>{$mod_strings['LBL_WIZARD_TITLE']} {$mod_strings['LBL_LICENSE_ACCEPTANCE']}</title>
|
||||
<link REL="SHORTCUT ICON" HREF="include/images/sugar_icon.ico">
|
||||
<link rel="stylesheet" href="install/install.css" type="text/css">
|
||||
<script src="cache/include/javascript/sugar_grp1_yui.js?s={$sugar_version}&c={$js_custom_version}"></script>
|
||||
<script type="text/javascript">
|
||||
<!--
|
||||
if ( YAHOO.env.ua )
|
||||
UA = YAHOO.env.ua;
|
||||
-->
|
||||
</script>
|
||||
<link rel='stylesheet' type='text/css' href='include/javascript/yui/build/container/assets/container.css' />
|
||||
<script type="text/javascript" src="install/license.js"></script>
|
||||
<link rel="stylesheet" href="themes/suite8/css/fontello.css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/animation.css"><!--[if IE 7]><link rel="stylesheet" href="css/fontello-ie7.css"><![endif]-->
|
||||
</head>
|
||||
|
||||
<body onload="javascript:toggleNextButton();document.getElementById('button_next2').focus();">
|
||||
<!--SuiteCRM installer-->
|
||||
<div id="install_container">
|
||||
<div id="install_box">
|
||||
<div id='licenseDiv'>
|
||||
<header id="install_header">
|
||||
<div class="install_img"><a href="https://suitecrm.com" target="_blank"><img src="{$sugar_md}" alt="SuiteCRM"></a></div>
|
||||
<div id="steps"><p>{$mod_strings['LBL_STEP2']}</p><i class="icon-progress-0" id="complete"></i><i class="icon-progress-1"></i><i class="icon-progress-2"></i><i class="icon-progress-3"></i><i class="icon-progress-4"></i><i class="icon-progress-5"></i><i class="icon-progress-6"></i><i class="icon-progress-7"></i></div> <form action="install.php" method="post" name="setConfig" id="form">
|
||||
</header>
|
||||
<textarea class="licensetext" cols="80" rows="20" readonly>{$license_file}</textarea>
|
||||
<br>
|
||||
<hr>
|
||||
<div id="licenseaccept">
|
||||
<input type="checkbox" class="checkbox" name="setup_license_accept" id="button_next2" onClick='toggleNextButton();' {$checked} />
|
||||
<a href='javascript:void(0)' onClick='toggleLicenseAccept();toggleNextButton();'>{$mod_strings['LBL_LICENSE_I_ACCEPT']}</a>
|
||||
<input type="button" class="button" name="print_license" id="button_print_license" value="{$mod_strings['LBL_LICENSE_PRINTABLE']}"
|
||||
onClick='window.open("install.php?page=licensePrint&language={$current_language}");' />
|
||||
</div>
|
||||
</div>
|
||||
<div id="installcontrols">
|
||||
<input type="hidden" name="current_step" value="{$next_step}">
|
||||
<input class="acceptButton" type="button" name="goto" value="{$mod_strings['LBL_BACK']}" id="button_back_license" onclick="document.getElementById('form').submit();" />
|
||||
<input class="acceptButton" type="button" name="goto" value="{$mod_strings['LBL_NEXT']}" id="button_next" disabled="disabled" onclick="callSysCheck();"/>
|
||||
<input type="hidden" name="goto" id='hidden_goto' value="{$mod_strings['LBL_BACK']}" />
|
||||
</div>
|
||||
</form>
|
||||
<div id='sysCheckMsg'><div>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
var msgPanel;
|
||||
function callSysCheck(){
|
||||
|
||||
//begin main function that will be called
|
||||
ajaxCall = function(msg_panel){
|
||||
//create success function for callback
|
||||
|
||||
getPanel = function() {
|
||||
var args = { width:"300px",
|
||||
modal:true,
|
||||
fixedcenter: true,
|
||||
constraintoviewport: false,
|
||||
underlay:"shadow",
|
||||
close:false,
|
||||
draggable:true,
|
||||
|
||||
effect:{effect:YAHOO.widget.ContainerEffect.FADE, duration:.5}
|
||||
} ;
|
||||
msg_panel = new YAHOO.widget.Panel('p_msg', args);
|
||||
//If we haven't built our panel using existing markup,
|
||||
//we can set its content via script:
|
||||
msg_panel.setHeader("{$mod_strings['LBL_LICENSE_CHKENV_HEADER']}");
|
||||
msg_panel.setBody(document.getElementById("checkingDiv").innerHTML);
|
||||
msg_panel.render(document.body);
|
||||
msgPanel = msg_panel;
|
||||
}
|
||||
|
||||
|
||||
passed = function(url){
|
||||
document.setConfig.goto.value="{$mod_strings['LBL_NEXT']}";
|
||||
document.getElementById('hidden_goto').value="{$mod_strings['LBL_NEXT']}";
|
||||
document.setConfig.current_step.value="{$next_step}";
|
||||
document.setConfig.submit();
|
||||
window.focus();
|
||||
}
|
||||
success = function(o) {
|
||||
if (o.responseText.indexOf('passed')>=0){
|
||||
if ( YAHOO.util.Selector.query('button', 'p_msg', true) != null )
|
||||
YAHOO.util.Selector.query('button', 'p_msg', true).style.display = 'none';
|
||||
scsbody = "<table cellspacing='0' cellpadding='0' border='0' align='center'><tr><td>";
|
||||
scsbody += "<p>{$mod_strings['LBL_LICENSE_CHECK_PASSED']}</p>";
|
||||
scsbody += "<div id='cntDown'>{$mod_strings['LBL_THREE']}</div>";
|
||||
scsbody += "</td></tr></table>";
|
||||
scsbody += "<script>countdown(3);<\/script>";
|
||||
msgPanel.setBody(scsbody);
|
||||
msgPanel.render();
|
||||
countdown(3);
|
||||
window.setTimeout('passed("install.php?goto=next")', 2500);
|
||||
|
||||
}else{
|
||||
//turn off loading message
|
||||
msgPanel.hide();
|
||||
document.getElementById('sysCheckMsg').style.display = '';
|
||||
document.getElementById('licenseDiv').style.display = 'none';
|
||||
document.getElementById('sysCheckMsg').innerHTML=o.responseText;
|
||||
}
|
||||
|
||||
|
||||
}//end success
|
||||
|
||||
//set loading message and create url
|
||||
postData = "checkInstallSystem=true&to_pdf=1&sugar_body_only=1";
|
||||
|
||||
//if this is a call already in progress, then just return
|
||||
if(typeof ajxProgress != 'undefined'){
|
||||
return;
|
||||
}
|
||||
|
||||
getPanel();
|
||||
msgPanel.show;
|
||||
var ajxProgress = YAHOO.util.Connect.asyncRequest('POST','install.php', {success: success, failure: success}, postData);
|
||||
|
||||
|
||||
};//end ajaxCall method
|
||||
ajaxCall();
|
||||
return;
|
||||
}
|
||||
|
||||
function countdown(num){
|
||||
scsbody = "<table cellspacing='0' cellpadding='0' border='0' align='center'><tr><td>";
|
||||
scsbody += "<p>{$mod_strings['LBL_LICENSE_CHECK_PASSED']}</p>";
|
||||
scsbody += "<div id='cntDown'>{$mod_strings['LBL_LICENSE_REDIRECT']}"+num+"</div>";
|
||||
scsbody += "</td></tr></table>";
|
||||
msgPanel.setBody(scsbody);
|
||||
msgPanel.render();
|
||||
if(num >0){
|
||||
num = num-1;
|
||||
setTimeout("countdown("+num+")",1000);
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
<div id="checkingDiv" style="display:none">
|
||||
<p><img src='install/processing.gif' alt="{$mod_strings['LBL_LICENSE_CHECKING']}"> <br>{$mod_strings['LBL_LICENSE_CHECKING']}</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<footer id="install_footer">
|
||||
<p id="footer_links"><a href="https://suitecrm.com" target="_blank">Visit suitecrm.com</a> | <a href="https://suitecrm.com/suitecrm/forum" target="_blank">Support Forums</a> | <a href="https://docs.suitecrm.com/admin/installation-guide/" target="_blank">Installation Guide</a> | <a href="LICENSE.txt" target="_blank">License</a>
|
||||
</footer>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
EOQ;
|
||||
echo $out;
|
94
public/legacy/install/licensePrint.php
Executable file
94
public/legacy/install/licensePrint.php
Executable file
|
@ -0,0 +1,94 @@
|
|||
<?php
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
/**
|
||||
|
||||
* Description: printable license page.
|
||||
*/
|
||||
|
||||
clean_incoming_data();
|
||||
|
||||
require_once("install/language/{$_GET['language']}.lang.php");
|
||||
require_once("install/install_utils.php");
|
||||
|
||||
$license_file = wordwrap(getLicenseContents("LICENSE.txt"), 100);
|
||||
$langHeader = get_language_header();
|
||||
$out =<<<EOQ
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html {$langHeader}>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<title>{$mod_strings['LBL_LICENSE_TITLE_2']}</title>
|
||||
<link REL="SHORTCUT ICON" HREF="include/images/sugar_icon.ico">
|
||||
<link rel="stylesheet" href="install/install.css" type="text/css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<table cellspacing="0" cellpadding="0" border="0" align="center" class="shell" width="90%">
|
||||
<tr>
|
||||
<td colspan='3' align="right">
|
||||
<input type="button" name="print_license" value=" {$mod_strings['LBL_PRINT']} " onClick='window.print();' />
|
||||
<input type="button" name="close_windows" value=" {$mod_strings['LBL_CLOSE']} " onClick='window.close();' />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="2%"> </td>
|
||||
<td>
|
||||
<pre>
|
||||
{$license_file}
|
||||
</pre>
|
||||
</td>
|
||||
<td width="2%"> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan='3' align="right">
|
||||
<input type="button" name="print_license" value=" {$mod_strings['LBL_PRINT']} " onClick='window.print();' />
|
||||
<input type="button" name="close_windows" value=" {$mod_strings['LBL_CLOSE']} " onClick='window.close();' />
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
EOQ;
|
||||
echo $out;
|
38
public/legacy/install/oc_convert.js
Executable file
38
public/legacy/install/oc_convert.js
Executable file
|
@ -0,0 +1,38 @@
|
|||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/function toggleIsFirstTime(){var theForm=document.forms[0];theForm.first_time.value="false";}
|
39
public/legacy/install/oc_install.js
Executable file
39
public/legacy/install/oc_install.js
Executable file
|
@ -0,0 +1,39 @@
|
|||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/function toggleOfflineClientInstallation(){var theForm=document.forms[0];if(!theForm.oc_install.checked){theForm.oc_server_url.disabled="disabled";theForm.oc_username.disabled="disabled";theForm.oc_password.disabled="disabled";}
|
||||
else{theForm.oc_server_url.disabled='';theForm.oc_username.disabled='';theForm.oc_password.disabled='';}}
|
43
public/legacy/install/old_php.js
Normal file
43
public/legacy/install/old_php.js
Normal file
|
@ -0,0 +1,43 @@
|
|||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
function toggleOldPHP(){var theForm=document.forms[0];if(theForm.setup_old_php.checked){theForm.setup_old_php.checked="";}
|
||||
else{theForm.setup_old_php.checked="yes";}
|
||||
toggleNextButton();}
|
||||
function toggleNextButton(){var theForm=document.forms[0];var nextButton=document.getElementById("button_next");if(theForm.setup_old_php.checked){nextButton.disabled='';nextButton.focus();}
|
||||
else{nextButton.disabled="disabled";}}
|
149
public/legacy/install/old_php.php
Normal file
149
public/legacy/install/old_php.php
Normal file
|
@ -0,0 +1,149 @@
|
|||
<?php
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
|
||||
if (!isset($install_script) || !$install_script) {
|
||||
die($mod_strings['ERR_NO_DIRECT_SCRIPT']);
|
||||
}
|
||||
|
||||
$langDropDown = get_select_options_with_id($supportedLanguages, $current_language);
|
||||
|
||||
$_SESSION['setup_old_php'] = get_boolean_from_request('setup_old_php');
|
||||
|
||||
$checked = (isset($_SESSION['setup_old_php']) && !empty($_SESSION['setup_old_php'])) ? 'checked="on"' : '';
|
||||
|
||||
$langHeader = get_language_header();
|
||||
|
||||
// load javascripts
|
||||
include('jssource/JSGroupings.php');
|
||||
$jsSrc = '';
|
||||
foreach ($sugar_grp1_yui as $jsFile => $grp) {
|
||||
$jsSrc .= "\t<script src=\"$jsFile\"></script>\n";
|
||||
}
|
||||
|
||||
//// START OUTPUT
|
||||
|
||||
$msg = sprintf(
|
||||
$mod_strings['LBL_OLD_PHP_MSG'],
|
||||
constant('SUITECRM_PHP_REC_VERSION'),
|
||||
constant('SUITECRM_PHP_MIN_VERSION'),
|
||||
constant('PHP_VERSION')
|
||||
);
|
||||
|
||||
$out = <<<EOQ
|
||||
<!DOCTYPE HTML>
|
||||
<html {$langHeader}>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<meta content='width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0' name='viewport' />
|
||||
<title>{$mod_strings['LBL_WIZARD_TITLE']} {$mod_strings['LBL_TITLE_WELCOME']} {$setup_sugar_version} {$mod_strings['LBL_WELCOME_SETUP_WIZARD']}, {$mod_strings['LBL_LICENSE_ACCEPTANCE']}</title>
|
||||
<link REL="SHORTCUT ICON" HREF="include/images/sugar_icon.ico">
|
||||
<link rel="stylesheet" href="install/install2.css" type="text/css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/themes.css" type="text/css">
|
||||
<script src="include/javascript/jquery/jquery-min.js"></script>
|
||||
$jsSrc
|
||||
<script type="text/javascript">
|
||||
<!--
|
||||
if ( YAHOO.env.ua )
|
||||
UA = YAHOO.env.ua;
|
||||
-->
|
||||
</script>
|
||||
<link rel='stylesheet' type='text/css' href='include/javascript/yui/build/container/assets/container.css' />
|
||||
<script type="text/javascript" src="install/old_php.js"></script>
|
||||
<link rel="stylesheet" href="themes/suite8/css/fontello.css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/animation.css"><!--[if IE 7]><link rel="stylesheet" href="css/fontello-ie7.css"><![endif]-->
|
||||
</head>
|
||||
<body onload="javascript:toggleNextButton();document.getElementById('button_next2').focus();">
|
||||
<!--SuiteCRM installer-->
|
||||
<div id="install_container">
|
||||
<div id="install_box">
|
||||
<form action="install.php" method="post" name="setConfig" id="form">
|
||||
<header id="install_header">
|
||||
<h1 id="welcomelink">{$mod_strings['LBL_TITLE_WELCOME']} {$setup_sugar_version} {$mod_strings['LBL_WELCOME_SETUP_WIZARD']}</h1>
|
||||
<div class="install_img"><a href="https://suitecrm.com" target="_blank"><img src="{$sugar_md}" alt="SuiteCRM"></a></div>
|
||||
</header>
|
||||
<div id="content">
|
||||
<h2>{$mod_strings['LBL_OLD_PHP']}</h2>
|
||||
<div class="floatbox full">{$msg}
|
||||
<div id="licenseaccept">
|
||||
<input type="checkbox" class="checkbox" name="setup_old_php" id="button_next2" onClick='toggleNextButton();' {$checked} />
|
||||
<a href='javascript:void(0)' onClick='toggleOldPHP();toggleNextButton();'>{$mod_strings['LBL_OLD_PHP_OK']}</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<hr>
|
||||
<div id="installcontrols">
|
||||
|
||||
<input type="hidden" name="current_step" value="{$next_step}">
|
||||
{$mod_strings['LBL_WELCOME_CHOOSE_LANGUAGE']}: <select name="language" onchange='onLangSelect(this);';>{$langDropDown}</select>
|
||||
<input class="acceptButton" type="submit" name="goto" value="{$mod_strings['LBL_NEXT']}" id="button_next" disabled="disabled" title="{$mod_strings['LBL_LICENCE_TOOLTIP']}" />
|
||||
<input type="hidden" name="goto" id='hidden_goto' value="{$mod_strings['LBL_NEXT']}" />
|
||||
</div>
|
||||
|
||||
</form>
|
||||
<div style="clear:both;"></div>
|
||||
<div id='sysCheckMsg'></div>
|
||||
<div style="clear:both;"></div>
|
||||
</div>
|
||||
<div id="checkingDiv" style="display:none">
|
||||
<p><img src='install/processing.gif' alt="{$mod_strings['LBL_LICENSE_CHECKING']}"> <br>{$mod_strings['LBL_LICENSE_CHECKING']}</p>
|
||||
</div>
|
||||
<footer id="install_footer">
|
||||
<p id="footer_links"><a href="https://suitecrm.com" target="_blank">Visit suitecrm.com</a> | <a href="https://suitecrm.com/suitecrm/forum" target="_blank">Support Forums</a> | <a href="https://docs.suitecrm.com/admin/installation-guide/" target="_blank">Installation Guide</a> | <a href="LICENSE.txt" target="_blank">License</a>
|
||||
</footer>
|
||||
</div>
|
||||
<script>
|
||||
|
||||
function onLangSelect(e) {
|
||||
$("input[name=current_step]").attr('name', '_current_step');
|
||||
$("input[name=goto]").attr('name', '_goto');
|
||||
e.form.submit();
|
||||
}
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
EOQ;
|
||||
|
||||
echo $out;
|
839
public/legacy/install/performSetup.php
Executable file
839
public/legacy/install/performSetup.php
Executable file
|
@ -0,0 +1,839 @@
|
|||
<?php
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
|
||||
function installStatus($msg, $cmd = null, $overwrite = false, $before = '[ok]<br>')
|
||||
{
|
||||
$fname = 'install/status.json';
|
||||
if (!$overwrite && file_exists($fname)) {
|
||||
$stat = json_decode(file_get_contents($fname));
|
||||
//$msg = json_encode($stat);
|
||||
$msg = $stat->message . $before . $msg;
|
||||
}
|
||||
file_put_contents($fname, json_encode(array(
|
||||
'message' => $msg,
|
||||
'command' => $cmd,
|
||||
)));
|
||||
}
|
||||
installStatus($mod_strings['LBL_START'], null, true, '');
|
||||
|
||||
// This file will load the configuration settings from session data,
|
||||
// write to the config file, and execute any necessary database steps.
|
||||
$GLOBALS['installing'] = true;
|
||||
if (!isset($install_script) || !$install_script) {
|
||||
die($mod_strings['ERR_NO_DIRECT_SCRIPT']);
|
||||
}
|
||||
ini_set("output_buffering", "0");
|
||||
set_time_limit(3600);
|
||||
// flush after each output so the user can see the progress in real-time
|
||||
ob_implicit_flush();
|
||||
|
||||
|
||||
require_once('install/install_utils.php');
|
||||
|
||||
require_once('modules/TableDictionary.php');
|
||||
|
||||
global $trackerManager;
|
||||
|
||||
$trackerManager = TrackerManager::getInstance();
|
||||
$trackerManager->pause();
|
||||
|
||||
global $cache_dir;
|
||||
global $line_entry_format;
|
||||
global $line_exit_format;
|
||||
global $rel_dictionary;
|
||||
global $render_table_close;
|
||||
global $render_table_open;
|
||||
global $setup_db_admin_password;
|
||||
global $setup_db_admin_user_name;
|
||||
global $setup_db_create_database;
|
||||
global $setup_db_create_sugarsales_user;
|
||||
global $setup_db_database_name;
|
||||
global $setup_db_drop_tables;
|
||||
global $setup_db_host_instance;
|
||||
global $setup_db_port_num;
|
||||
global $setup_db_host_name;
|
||||
global $demoData;
|
||||
global $setup_db_sugarsales_password;
|
||||
global $setup_db_sugarsales_user;
|
||||
global $setup_site_admin_user_name;
|
||||
global $setup_site_admin_password;
|
||||
global $setup_site_guid;
|
||||
global $setup_site_url;
|
||||
global $parsed_url;
|
||||
global $setup_site_host_name;
|
||||
global $setup_site_log_dir;
|
||||
global $setup_site_log_file;
|
||||
global $setup_site_session_path;
|
||||
global $setup_site_log_level;
|
||||
|
||||
|
||||
$cache_dir = sugar_cached("");
|
||||
$line_entry_format = "     <b>";
|
||||
$line_exit_format = "...   </b>";
|
||||
$rel_dictionary = $dictionary; // sourced by modules/TableDictionary.php
|
||||
$render_table_close = "";
|
||||
$render_table_open = "";
|
||||
$setup_db_admin_password = $_SESSION['setup_db_admin_password'];
|
||||
$setup_db_admin_user_name = $_SESSION['setup_db_admin_user_name'];
|
||||
$setup_db_create_database = $_SESSION['setup_db_create_database'];
|
||||
$setup_db_create_sugarsales_user = $_SESSION['setup_db_create_sugarsales_user'];
|
||||
$setup_db_database_name = $_SESSION['setup_db_database_name'];
|
||||
$setup_db_drop_tables = $_SESSION['setup_db_drop_tables'];
|
||||
$setup_db_host_instance = $_SESSION['setup_db_host_instance'];
|
||||
$setup_db_port_num = $_SESSION['setup_db_port_num'];
|
||||
$setup_db_host_name = $_SESSION['setup_db_host_name'];
|
||||
$demoData = $_SESSION['demoData'];
|
||||
$setup_db_sugarsales_password = $_SESSION['setup_db_sugarsales_password'];
|
||||
$setup_db_sugarsales_user = $_SESSION['setup_db_sugarsales_user'];
|
||||
$setup_site_admin_user_name = $_SESSION['setup_site_admin_user_name'];
|
||||
$setup_site_admin_password = $_SESSION['setup_site_admin_password'];
|
||||
$setup_site_guid = (isset($_SESSION['setup_site_specify_guid']) && $_SESSION['setup_site_specify_guid'] != '') ? $_SESSION['setup_site_guid'] : '';
|
||||
$setup_site_url = $_SESSION['setup_site_url'];
|
||||
$parsed_url = parse_url($setup_site_url);
|
||||
$setup_site_host_name = $parsed_url['host'];
|
||||
$setup_site_log_dir = isset($_SESSION['setup_site_custom_log_dir']) ? $_SESSION['setup_site_log_dir'] : '.';
|
||||
$setup_site_log_file = 'suitecrm.log'; // may be an option later
|
||||
$setup_site_session_path = isset($_SESSION['setup_site_custom_session_path']) ? $_SESSION['setup_site_session_path'] : '';
|
||||
$setup_site_log_level ='fatal';
|
||||
|
||||
/*sugar_cache_clear('TeamSetsCache');
|
||||
if ( file_exists($cache_dir .'modules/Teams/TeamSetCache.php') ) {
|
||||
unlink($cache_dir.'modules/Teams/TeamSetCache.php');
|
||||
}
|
||||
|
||||
sugar_cache_clear('TeamSetsMD5Cache');
|
||||
if ( file_exists($cache_dir.'modules/Teams/TeamSetMD5Cache.php') ) {
|
||||
unlink($cache_dir.'modules/Teams/TeamSetMD5Cache.php');
|
||||
}*/
|
||||
$langHeader = get_language_header();
|
||||
$out =<<<EOQ
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<!DOCTYPE HTML>
|
||||
<html {$langHeader}>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Script-Type" content="text/javascript">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<title>{$mod_strings['LBL_WIZARD_TITLE']} {$mod_strings['LBL_PERFORM_TITLE']}</title>
|
||||
<link REL="SHORTCUT ICON" HREF="$icon">
|
||||
<!-- <link rel="stylesheet" href="$css" type="text/css" /> -->
|
||||
<script type="text/javascript" src="$common"></script>
|
||||
<link rel="stylesheet" href="install/install2.css" type="text/css" />
|
||||
<script type="text/javascript" src="install/installCommon.js"></script>
|
||||
<script type="text/javascript" src="install/siteConfig.js"></script>
|
||||
<link rel='stylesheet' type='text/css' href='include/javascript/yui/build/container/assets/container.css' />
|
||||
<link rel="stylesheet" href="themes/suite8/css/fontello.css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/animation.css"><!--[if IE 7]><link rel="stylesheet" href="css/fontello-ie7.css"><![endif]-->
|
||||
</head>
|
||||
<body onload="javascript:document.getElementById('button_next2').focus();">
|
||||
<!--SuiteCRM installer-->
|
||||
<div id="install_container">
|
||||
<div id="install_box">
|
||||
<header id="install_header">
|
||||
<div id="steps">
|
||||
<p>{$mod_strings['LBL_STEP2']}</p>
|
||||
<i class="icon-progress-0" id="complete"></i>
|
||||
<i class="icon-progress-1" id="complete"></i>
|
||||
<i class="icon-progress-2"></i>
|
||||
</div>
|
||||
<div class="install_img"><a href="https://suitecrm.com" target="_blank"><img src="{$sugar_md}" alt="SuiteCRM"></a></div>
|
||||
</header>
|
||||
EOQ;
|
||||
echo $out;
|
||||
installStatus($mod_strings['STAT_CONFIGURATION'], null, false, '');
|
||||
installLog("calling handleSugarConfig()");
|
||||
$bottle = handleSugarConfig();
|
||||
//installLog("calling handleLog4Php()");
|
||||
//handleLog4Php();
|
||||
|
||||
$server_software = $_SERVER["SERVER_SOFTWARE"];
|
||||
if (strpos($server_software, 'Microsoft-IIS') !== false) {
|
||||
installLog("calling handleWebConfig()");
|
||||
handleWebConfig();
|
||||
} else {
|
||||
installLog("calling handleHtaccess()");
|
||||
handleHtaccess();
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// START TABLE STUFF
|
||||
echo "<br>";
|
||||
echo "<b>{$mod_strings['LBL_PERFORM_TABLES']}</b>";
|
||||
echo "<br>";
|
||||
|
||||
// create the SugarCRM database
|
||||
if ($setup_db_create_database) {
|
||||
installLog("calling handleDbCreateDatabase()");
|
||||
installerHook('pre_handleDbCreateDatabase');
|
||||
handleDbCreateDatabase();
|
||||
installerHook('post_handleDbCreateDatabase');
|
||||
} else {
|
||||
|
||||
// ensure the charset and collation are utf8
|
||||
installLog("calling handleDbCharsetCollation()");
|
||||
installerHook('pre_handleDbCharsetCollation');
|
||||
handleDbCharsetCollation();
|
||||
installerHook('post_handleDbCharsetCollation');
|
||||
}
|
||||
|
||||
//Suite rebuild exts
|
||||
/*require_once('ModuleInstall/ModuleInstaller.php');
|
||||
$ModuleInstaller = new ModuleInstaller();
|
||||
$ModuleInstaller->silent=true;
|
||||
$ModuleInstaller->rebuild_modules();
|
||||
$ModuleInstaller->rebuild_languages( array ('en_us' => 'English (US)',));
|
||||
$ModuleInstaller->rebuild_extensions();
|
||||
$ModuleInstaller->rebuild_tabledictionary();*/
|
||||
|
||||
// create the SugarCRM database user
|
||||
if ($setup_db_create_sugarsales_user) {
|
||||
installerHook('pre_handleDbCreateSugarUser');
|
||||
handleDbCreateSugarUser();
|
||||
installerHook('post_handleDbCreateSugarUser');
|
||||
}
|
||||
|
||||
foreach ($beanFiles as $bean => $file) {
|
||||
require_once($file);
|
||||
}
|
||||
echo "<br>";
|
||||
// load up the config_override.php file.
|
||||
// This is used to provide default user settings
|
||||
if (is_file("config_override.php")) {
|
||||
require_once("config_override.php");
|
||||
}
|
||||
|
||||
global $db;
|
||||
global $startTime;
|
||||
global $focus;
|
||||
global $processed_tables;
|
||||
global $db;
|
||||
global $empty;
|
||||
global $new_tables;
|
||||
global $new_config;
|
||||
global $new_report;
|
||||
global $nonStandardModules;
|
||||
|
||||
|
||||
$db = DBManagerFactory::getInstance();
|
||||
$startTime = microtime(true);
|
||||
$focus = 0;
|
||||
$processed_tables = array(); // for keeping track of the tables we have worked on
|
||||
$empty = array();
|
||||
$new_tables = 1; // is there ever a scenario where we DON'T create the admin user?
|
||||
$new_config = 1;
|
||||
$new_report = 1;
|
||||
|
||||
// add non-module Beans to this array to keep the installer from erroring.
|
||||
$nonStandardModules = array(
|
||||
//'Tracker',
|
||||
);
|
||||
|
||||
|
||||
/**
|
||||
* loop through all the Beans and create their tables
|
||||
*/
|
||||
installStatus($mod_strings['STAT_CREATE_DB']);
|
||||
installLog("looping through all the Beans and create their tables");
|
||||
//start by clearing out the vardefs
|
||||
VardefManager::clearVardef();
|
||||
installerHook('pre_createAllModuleTables');
|
||||
|
||||
|
||||
foreach ($beanFiles as $bean => $file) {
|
||||
$doNotInit = array('Scheduler', 'SchedulersJob', 'ProjectTask','jjwg_Maps','jjwg_Address_Cache','jjwg_Areas','jjwg_Markers');
|
||||
|
||||
if (in_array($bean, $doNotInit)) {
|
||||
$focus = new $bean(false);
|
||||
} else {
|
||||
$focus = new $bean();
|
||||
}
|
||||
|
||||
if ($bean == 'Configurator') {
|
||||
continue;
|
||||
}
|
||||
|
||||
$table_name = $focus->table_name;
|
||||
//installStatus(sprintf($mod_strings['STAT_CREATE_DB_TABLE'], $focus->table_name ));
|
||||
installLog("processing table ".$focus->table_name);
|
||||
// check to see if we have already setup this table
|
||||
if (!in_array($table_name, $processed_tables)) {
|
||||
if (!file_exists("modules/".$focus->module_dir."/vardefs.php")) {
|
||||
continue;
|
||||
}
|
||||
if (!in_array($bean, $nonStandardModules)) {
|
||||
require_once("modules/".$focus->module_dir."/vardefs.php"); // load up $dictionary
|
||||
if (isset($dictionary[$focus->object_name]['table']) && $dictionary[$focus->object_name]['table'] == 'does_not_exist') {
|
||||
continue; // support new vardef definitions
|
||||
}
|
||||
} else {
|
||||
continue; //no further processing needed for ignored beans.
|
||||
}
|
||||
|
||||
// table has not been setup...we will do it now and remember that
|
||||
$processed_tables[] = $table_name;
|
||||
|
||||
$focus->db->database = $db->database; // set db connection so we do not need to reconnect
|
||||
|
||||
if ($setup_db_drop_tables) {
|
||||
drop_table_install($focus);
|
||||
installLog("dropping table ".$focus->table_name);
|
||||
}
|
||||
|
||||
if (create_table_if_not_exist($focus)) {
|
||||
installLog("creating table ".$focus->table_name);
|
||||
if ($bean == "User") {
|
||||
$new_tables = 1;
|
||||
}
|
||||
if ($bean == "Administration") {
|
||||
$new_config = 1;
|
||||
}
|
||||
}
|
||||
|
||||
installLog("creating Relationship Meta for ".$focus->getObjectName());
|
||||
installerHook('pre_createModuleTable', array('module' => $focus->getObjectName()));
|
||||
SugarBean::createRelationshipMeta($focus->getObjectName(), $db, $table_name, $empty, $focus->module_dir);
|
||||
installerHook('post_createModuleTable', array('module' => $focus->getObjectName()));
|
||||
echo ".";
|
||||
} // end if()
|
||||
}
|
||||
|
||||
|
||||
installerHook('post_createAllModuleTables');
|
||||
|
||||
echo "<br>";
|
||||
//// END TABLE STUFF
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// START RELATIONSHIP CREATION
|
||||
|
||||
ksort($rel_dictionary);
|
||||
foreach ($rel_dictionary as $rel_name => $rel_data) {
|
||||
$table = $rel_data['table'];
|
||||
|
||||
if ($setup_db_drop_tables) {
|
||||
if ($db->tableExists($table)) {
|
||||
$db->dropTableName($table);
|
||||
}
|
||||
}
|
||||
|
||||
if (!$db->tableExists($table)) {
|
||||
$db->createTableParams($table, $rel_data['fields'], $rel_data['indices']);
|
||||
}
|
||||
|
||||
SugarBean::createRelationshipMeta($rel_name, $db, $table, $rel_dictionary, '');
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// START CREATE DEFAULTS
|
||||
echo "<br>";
|
||||
echo "<b>{$mod_strings['LBL_PERFORM_CREATE_DEFAULT']}</b><br>";
|
||||
echo "<br>";
|
||||
installStatus($mod_strings['STAT_CREATE_DEFAULT_SETTINGS']);
|
||||
installLog("Begin creating Defaults");
|
||||
installerHook('pre_createDefaultSettings');
|
||||
if ($new_config) {
|
||||
installLog("insert defaults into config table");
|
||||
insert_default_settings();
|
||||
}
|
||||
installerHook('post_createDefaultSettings');
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
installerHook('pre_createUsers');
|
||||
if ($new_tables) {
|
||||
echo $line_entry_format.$mod_strings['LBL_PERFORM_DEFAULT_USERS'].$line_exit_format;
|
||||
installLog($mod_strings['LBL_PERFORM_DEFAULT_USERS']);
|
||||
create_default_users();
|
||||
echo $mod_strings['LBL_PERFORM_DONE'];
|
||||
} else {
|
||||
echo $line_entry_format.$mod_strings['LBL_PERFORM_ADMIN_PASSWORD'].$line_exit_format;
|
||||
installLog($mod_strings['LBL_PERFORM_ADMIN_PASSWORD']);
|
||||
$db->setUserName($setup_db_sugarsales_user);
|
||||
$db->setUserPassword($setup_db_sugarsales_password);
|
||||
set_admin_password($setup_site_admin_password);
|
||||
echo $mod_strings['LBL_PERFORM_DONE'];
|
||||
}
|
||||
installerHook('post_createUsers');
|
||||
|
||||
|
||||
|
||||
|
||||
// default OOB schedulers
|
||||
|
||||
echo $line_entry_format.$mod_strings['LBL_PERFORM_DEFAULT_SCHEDULER'].$line_exit_format;
|
||||
installLog($mod_strings['LBL_PERFORM_DEFAULT_SCHEDULER']);
|
||||
$scheduler = BeanFactory::newBean('Schedulers');
|
||||
installerHook('pre_createDefaultSchedulers');
|
||||
$scheduler->rebuildDefaultSchedulers();
|
||||
installerHook('post_createDefaultSchedulers');
|
||||
|
||||
|
||||
echo $mod_strings['LBL_PERFORM_DONE'];
|
||||
|
||||
|
||||
|
||||
// Enable Sugar Feeds and add all feeds by default
|
||||
installLog("Enable SugarFeeds");
|
||||
enableSugarFeeds();
|
||||
|
||||
// Install the logic hook for WorkFLow
|
||||
installLog("Creating WorkFlow logic hook");
|
||||
if (!function_exists('createWorkFlowLogicHook')) {
|
||||
function createWorkFlowLogicHook($filePath = 'Extension/application/Ext/LogicHooks/AOW_WorkFlow_Hook.php')
|
||||
{
|
||||
$customFileLoc = create_custom_directory($filePath);
|
||||
$fp = sugar_fopen($customFileLoc, 'wb');
|
||||
$contents = <<<CIA
|
||||
<?php
|
||||
if (!isset(\$hook_array) || !is_array(\$hook_array)) {
|
||||
\$hook_array = array();
|
||||
}
|
||||
if (!isset(\$hook_array['after_save']) || !is_array(\$hook_array['after_save'])) {
|
||||
\$hook_array['after_save'] = array();
|
||||
}
|
||||
\$hook_array['after_save'][] = array(99, 'AOW_Workflow', 'modules/AOW_WorkFlow/AOW_WorkFlow.php','AOW_WorkFlow', 'run_bean_flows');
|
||||
CIA;
|
||||
|
||||
fwrite($fp,$contents);
|
||||
fclose($fp);
|
||||
|
||||
}
|
||||
}
|
||||
createWorkFlowLogicHook();
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
//// FINALIZE LANG PACK INSTALL
|
||||
if (isset($_SESSION['INSTALLED_LANG_PACKS']) && is_array($_SESSION['INSTALLED_LANG_PACKS']) && !empty($_SESSION['INSTALLED_LANG_PACKS'])) {
|
||||
updateUpgradeHistory();
|
||||
}
|
||||
|
||||
|
||||
//require_once('modules/Connectors/InstallDefaultConnectors.php');
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// INSTALL PASSWORD TEMPLATES
|
||||
include('install/seed_data/Advanced_Password_SeedData.php');
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// SETUP DONE
|
||||
installLog("Installation has completed *********");
|
||||
|
||||
$memoryUsed = '';
|
||||
if (function_exists('memory_get_usage')) {
|
||||
$memoryUsed = $mod_strings['LBL_PERFORM_OUTRO_5'] . memory_get_usage() . $mod_strings['LBL_PERFORM_OUTRO_6'];
|
||||
}
|
||||
|
||||
|
||||
$errTcpip = '';
|
||||
$fp = @fsockopen("www.suitecrm.com", 80, $errno, $errstr, 3);
|
||||
if (!$fp) {
|
||||
$errTcpip = "<p>{$mod_strings['ERR_PERFORM_NO_TCPIP']}</p>";
|
||||
}
|
||||
if ($fp && (!isset($_SESSION['oc_install']) || $_SESSION['oc_install'] == false)) {
|
||||
@fclose($fp);
|
||||
if ($next_step == 9999) {
|
||||
$next_step = 8;
|
||||
}
|
||||
$fpResult = <<<FP
|
||||
<form action="install.php" method="post" name="form" id="form">
|
||||
<input type="hidden" name="current_step" value="{$next_step}">
|
||||
<input class="button" type="submit" name="goto" value="{$mod_strings['LBL_NEXT']}" id="button_next2"/>
|
||||
</form>
|
||||
FP;
|
||||
} else {
|
||||
$fpResult = <<<FP
|
||||
<form action="index.php" method="post" name="formFinish" id="formFinish">
|
||||
<input type="hidden" name="default_user_name" value="admin" />
|
||||
<input class="button" type="submit" name="next" value="{$mod_strings['LBL_PERFORM_FINISH']}" id="button_next2"/>
|
||||
</form>
|
||||
FP;
|
||||
}
|
||||
|
||||
if (isset($_SESSION['setup_site_sugarbeet_automatic_checks']) && $_SESSION['setup_site_sugarbeet_automatic_checks'] == true) {
|
||||
set_CheckUpdates_config_setting('automatic');
|
||||
} else {
|
||||
set_CheckUpdates_config_setting('manual');
|
||||
}
|
||||
if (!empty($_SESSION['setup_system_name'])) {
|
||||
$admin=BeanFactory::newBean('Administration');
|
||||
$admin->saveSetting('system', 'name', $_SESSION['setup_system_name']);
|
||||
}
|
||||
|
||||
// Bug 28601 - Set the default list of tabs to show
|
||||
$enabled_tabs = array();
|
||||
$enabled_tabs[] = 'Home';
|
||||
$enabled_tabs[] = 'Accounts';
|
||||
$enabled_tabs[] = 'Contacts';
|
||||
$enabled_tabs[] = 'Opportunities';
|
||||
$enabled_tabs[] = 'Leads';
|
||||
$enabled_tabs[] = 'AOS_Quotes';
|
||||
$enabled_tabs[] = 'Calendar';
|
||||
$enabled_tabs[] = 'Documents';
|
||||
$enabled_tabs[] = 'Emails';
|
||||
$enabled_tabs[] = 'Spots';
|
||||
$enabled_tabs[] = 'Campaigns';
|
||||
$enabled_tabs[] = 'Calls';
|
||||
$enabled_tabs[] = 'Meetings';
|
||||
$enabled_tabs[] = 'Tasks';
|
||||
$enabled_tabs[] = 'Notes';
|
||||
$enabled_tabs[] = 'AOS_Invoices';
|
||||
$enabled_tabs[] = 'AOS_Contracts';
|
||||
$enabled_tabs[] = 'Cases';
|
||||
$enabled_tabs[] = 'Prospects';
|
||||
$enabled_tabs[] = 'ProspectLists';
|
||||
$enabled_tabs[] = 'Project';
|
||||
$enabled_tabs[] = 'AM_ProjectTemplates';
|
||||
$enabled_tabs[] = 'AM_TaskTemplates';
|
||||
$enabled_tabs[] = 'FP_events';
|
||||
$enabled_tabs[] = 'FP_Event_Locations';
|
||||
$enabled_tabs[] = 'AOS_Products';
|
||||
$enabled_tabs[] = 'AOS_Product_Categories';
|
||||
$enabled_tabs[] = 'AOS_PDF_Templates';
|
||||
$enabled_tabs[] = 'jjwg_Maps';
|
||||
$enabled_tabs[] = 'jjwg_Markers';
|
||||
$enabled_tabs[] = 'jjwg_Areas';
|
||||
$enabled_tabs[] = 'jjwg_Address_Cache';
|
||||
$enabled_tabs[] = 'AOR_Reports';
|
||||
$enabled_tabs[] = 'AOW_WorkFlow';
|
||||
$enabled_tabs[] = 'AOK_KnowledgeBase';
|
||||
$enabled_tabs[] = 'AOK_Knowledge_Base_Categories';
|
||||
$enabled_tabs[] = 'EmailTemplates';
|
||||
$enabled_tabs[] = 'Surveys';
|
||||
|
||||
//Beginning of the scenario implementations
|
||||
//We need to load the tabs so that we can remove those which are scenario based and un-selected
|
||||
//Remove the custom tabConfig as this overwrites the complete list containined in the include/tabConfig.php
|
||||
if (file_exists('custom/include/tabConfig.php')) {
|
||||
unlink('custom/include/tabConfig.php');
|
||||
}
|
||||
require_once('include/tabConfig.php');
|
||||
|
||||
//Remove the custom dashlet so that we can use the complete list of defaults to filter by category
|
||||
if (file_exists('custom/modules/Home/dashlets.php')) {
|
||||
unlink('custom/modules/Home/dashlets.php');
|
||||
}
|
||||
//Check if the folder is in place
|
||||
if (!file_exists('custom/modules/Home')) {
|
||||
sugar_mkdir('custom/modules/Home', 0775);
|
||||
}
|
||||
//Check if the folder is in place
|
||||
if (!file_exists('custom/include')) {
|
||||
sugar_mkdir('custom/include', 0775);
|
||||
}
|
||||
|
||||
|
||||
require_once('modules/Home/dashlets.php');
|
||||
|
||||
if (isset($_SESSION['installation_scenarios'])) {
|
||||
foreach ($_SESSION['installation_scenarios'] as $scenario) {
|
||||
//If the item is not in $_SESSION['scenarios'], then unset them as they are not required
|
||||
if (!in_array($scenario['key'], $_SESSION['scenarios'])) {
|
||||
foreach ($scenario['modules'] as $module) {
|
||||
if (($removeKey = array_search($module, $enabled_tabs)) !== false) {
|
||||
unset($enabled_tabs[$removeKey]);
|
||||
}
|
||||
}
|
||||
|
||||
//Loop through the dashlets to remove from the default home page based on this scenario
|
||||
foreach ($scenario['dashlets'] as $dashlet) {
|
||||
//if (($removeKey = array_search($dashlet, $defaultDashlets)) !== false) {
|
||||
// unset($defaultDashlets[$removeKey]);
|
||||
// }
|
||||
if (isset($defaultDashlets[$dashlet])) {
|
||||
unset($defaultDashlets[$dashlet]);
|
||||
}
|
||||
}
|
||||
|
||||
//If the scenario has an associated group tab, remove accordingly (by not adding to the custom tabconfig.php
|
||||
if (isset($scenario['groupedTabs'])) {
|
||||
unset($GLOBALS['tabStructure'][$scenario['groupedTabs']]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//Have a 'core' options, with accounts / contacts if no other scenario is selected
|
||||
if (!is_null($_SESSION['scenarios'])) {
|
||||
unset($GLOBALS['tabStructure']['LBL_TABGROUP_DEFAULT']);
|
||||
}
|
||||
|
||||
|
||||
//Write the tabstructure to custom so that the grouping are not shown for the un-selected scenarios
|
||||
$fp = sugar_fopen('custom/include/tabConfig.php', 'w');
|
||||
$fileContents = "<?php \n" .'$GLOBALS["tabStructure"] ='.var_export($GLOBALS['tabStructure'], true).';';
|
||||
fwrite($fp, $fileContents);
|
||||
fclose($fp);
|
||||
|
||||
//Write the dashlets to custom so that the dashlets are not shown for the un-selected scenarios
|
||||
$fp = sugar_fopen('custom/modules/Home/dashlets.php', 'w');
|
||||
$fileContents = "<?php \n" .'$defaultDashlets ='.var_export($defaultDashlets, true).';';
|
||||
fwrite($fp, $fileContents);
|
||||
fclose($fp);
|
||||
|
||||
|
||||
// End of the scenario implementations
|
||||
|
||||
|
||||
installerHook('pre_setSystemTabs');
|
||||
require_once('modules/MySettings/TabController.php');
|
||||
$tabs = new TabController();
|
||||
$tabs->set_system_tabs($enabled_tabs);
|
||||
installerHook('post_setSystemTabs');
|
||||
include_once('install/suite_install/suite_install.php');
|
||||
|
||||
post_install_modules();
|
||||
|
||||
//Call rebuildSprites
|
||||
/*if(function_exists('imagecreatetruecolor'))
|
||||
{
|
||||
require_once('modules/UpgradeWizard/uw_utils.php');
|
||||
rebuildSprites(true);
|
||||
}*/
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// START DEMO DATA
|
||||
|
||||
// populating the db with seed data
|
||||
installLog("populating the db with seed data");
|
||||
if ($_SESSION['demoData'] != 'no') {
|
||||
installerHook('pre_installDemoData');
|
||||
set_time_limit(301);
|
||||
|
||||
echo "<br>";
|
||||
echo "<b>{$mod_strings['LBL_PERFORM_DEMO_DATA']}</b>";
|
||||
echo "<br><br>";
|
||||
|
||||
print($render_table_close);
|
||||
print($render_table_open);
|
||||
|
||||
global $current_user;
|
||||
$current_user = BeanFactory::newBean('Users');
|
||||
$current_user->retrieve(1);
|
||||
include("install/populateSeedData.php");
|
||||
installerHook('post_installDemoData');
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////
|
||||
//// Store information by installConfig.php form
|
||||
|
||||
// save current superglobals and vars
|
||||
$varStack['GLOBALS'] = $GLOBALS;
|
||||
$varStack['defined_vars'] = get_defined_vars();
|
||||
|
||||
// restore previously posted form
|
||||
$_REQUEST = array_merge($_REQUEST, $_SESSION);
|
||||
$_POST = array_merge($_POST, $_SESSION);
|
||||
|
||||
|
||||
installStatus($mod_strings['STAT_INSTALL_FINISH']);
|
||||
installLog('Save configuration settings..');
|
||||
|
||||
// <--------------------------------------------------------
|
||||
// from ConfigurationConroller->action_saveadminwizard()
|
||||
// ---------------------------------------------------------->
|
||||
|
||||
installLog('save locale');
|
||||
|
||||
|
||||
|
||||
|
||||
//global $current_user;
|
||||
installLog('new Administration');
|
||||
$focus = BeanFactory::newBean('Administration');
|
||||
installLog('retrieveSettings');
|
||||
//$focus->retrieveSettings();
|
||||
// switch off the adminwizard (mark that we have got past this point)
|
||||
installLog('AdminWizard OFF');
|
||||
$focus->saveSetting('system', 'adminwizard', 1);
|
||||
|
||||
installLog('saveConfig');
|
||||
$focus->saveConfig();
|
||||
|
||||
installLog('new Configurator');
|
||||
global $configurator;
|
||||
$configurator = new Configurator();
|
||||
installLog('populateFromPost');
|
||||
$configurator->populateFromPost();
|
||||
|
||||
|
||||
|
||||
|
||||
installLog('handleOverride');
|
||||
// add local settings to config overrides
|
||||
if (!empty($_SESSION['default_date_format'])) {
|
||||
$sugar_config['default_date_format'] = $_SESSION['default_date_format'];
|
||||
}
|
||||
if (!empty($_SESSION['default_time_format'])) {
|
||||
$sugar_config['default_time_format'] = $_SESSION['default_time_format'];
|
||||
}
|
||||
if (!empty($_SESSION['default_language'])) {
|
||||
$sugar_config['default_language'] = $_SESSION['default_language'];
|
||||
}
|
||||
if (!empty($_SESSION['default_locale_name_format'])) {
|
||||
$sugar_config['default_locale_name_format'] = $_SESSION['default_locale_name_format'];
|
||||
}
|
||||
//$configurator->handleOverride();
|
||||
|
||||
|
||||
|
||||
// save current web-server user for the cron user check mechanism:
|
||||
installLog('addCronAllowedUser');
|
||||
addCronAllowedUser(getRunningUser());
|
||||
|
||||
|
||||
|
||||
installLog('saveConfig');
|
||||
$configurator->saveConfig();
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
// Bug 37310 - Delete any existing currency that matches the one we've just set the default to during the admin wizard
|
||||
installLog('new Currency');
|
||||
$currency = new Currency;
|
||||
installLog('retrieve');
|
||||
$currency->retrieve($currency->retrieve_id_by_name($_REQUEST['default_currency_name']));
|
||||
if (!empty($currency->id)
|
||||
&& $currency->symbol == $_REQUEST['default_currency_symbol']
|
||||
&& $currency->iso4217 == $_REQUEST['default_currency_iso4217']) {
|
||||
$currency->deleted = 1;
|
||||
installLog('DBG: save currency');
|
||||
$currency->save();
|
||||
}
|
||||
|
||||
|
||||
installLog('Save user settings..');
|
||||
|
||||
// <------------------------------------------------
|
||||
// from UsersController->action_saveuserwizard()
|
||||
// ---------------------------------------------------------->
|
||||
|
||||
|
||||
// set all of these default parameters since the Users save action will undo the defaults otherwise
|
||||
|
||||
// load admin
|
||||
$current_user = BeanFactory::newBean('Users');
|
||||
$current_user->retrieve(1);
|
||||
$current_user->is_admin = '1';
|
||||
$sugar_config = get_sugar_config_defaults();
|
||||
|
||||
// set local settings - if neccessary you can set here more fields as named in User module / EditView form...
|
||||
if (isset($_REQUEST['timezone']) && $_REQUEST['timezone']) {
|
||||
$current_user->setPreference('timezone', $_REQUEST['timezone']);
|
||||
}
|
||||
|
||||
if (file_exists(__DIR__ . '/../modules/ACL/install_actions.php')) {
|
||||
require_once(__DIR__ . '/../modules/ACL/install_actions.php');
|
||||
}
|
||||
|
||||
$_POST['dateformat'] = $_REQUEST['default_date_format'];
|
||||
$_POST['record'] = $current_user->id;
|
||||
$_POST['is_admin'] = ($current_user->is_admin ? 'on' : '');
|
||||
$_POST['use_real_names'] = true;
|
||||
$_POST['reminder_checked'] = '1';
|
||||
$_POST['reminder_time'] = 1800;
|
||||
$_POST['email_reminder_time'] = 3600;
|
||||
$_POST['mailmerge_on'] = 'on';
|
||||
$_POST['receive_notifications'] = $current_user->receive_notifications;
|
||||
installLog('DBG: SugarThemeRegistry::getDefault');
|
||||
$_POST['user_theme'] = (string) SugarThemeRegistry::getDefault();
|
||||
|
||||
// save and redirect to new view
|
||||
$_REQUEST['do_not_redirect'] = true;
|
||||
|
||||
// restore superglobals and vars
|
||||
$GLOBALS = $varStack['GLOBALS'];
|
||||
foreach ($varStack['defined_vars'] as $__key => $__value) {
|
||||
$$__key = $__value;
|
||||
}
|
||||
|
||||
|
||||
|
||||
$endTime = microtime(true);
|
||||
$deltaTime = $endTime - $startTime;
|
||||
|
||||
if (!is_array($bottle) || !is_object($bottle)) {
|
||||
$bottle = (array)$bottle;
|
||||
LoggerManager::getLogger()->warn('Bottle needs to be an array to perform setup');
|
||||
}
|
||||
|
||||
|
||||
if (count($bottle) > 0) {
|
||||
foreach ($bottle as $bottle_message) {
|
||||
$bottleMsg .= "{$bottle_message}\n";
|
||||
}
|
||||
} else {
|
||||
$bottleMsg = $mod_strings['LBL_PERFORM_SUCCESS'];
|
||||
}
|
||||
installerHook('post_installModules');
|
||||
|
||||
$out =<<<EOQ
|
||||
<br><p><b>{$mod_strings['LBL_PERFORM_OUTRO_1']} {$setup_sugar_version} {$mod_strings['LBL_PERFORM_OUTRO_2']}</b></p>
|
||||
|
||||
{$mod_strings['LBL_PERFORM_OUTRO_3']} {$deltaTime} {$mod_strings['LBL_PERFORM_OUTRO_4']}<br />
|
||||
<p><b>{$memoryUsed}</b></p>
|
||||
<p><b>{$errTcpip}</b></p>
|
||||
<p><b>{$fpResult}</b></p>
|
||||
</div>
|
||||
<footer id="install_footer">
|
||||
<p id="footer_links"><a href="https://suitecrm.com" target="_blank">Visit suitecrm.com</a> | <a href="https://suitecrm.com/suitecrm/forum" target="_blank">Support Forums</a> | <a href="https://docs.suitecrm.com/admin/installation-guide/" target="_blank">Installation Guide</a> | <a href="LICENSE.txt" target="_blank">License</a>
|
||||
</footer>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
<!--
|
||||
<bottle>{$bottleMsg}</bottle>
|
||||
-->
|
||||
EOQ;
|
||||
|
||||
echo $out;
|
||||
|
||||
$loginURL = str_replace('install.php', 'index.php', "//$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]");
|
||||
installStatus(sprintf($mod_strings['STAT_INSTALL_FINISH_LOGIN'], $loginURL), array('function' => 'redirect', 'arguments' => $loginURL));
|
498
public/legacy/install/populateSeedData.php
Executable file
498
public/legacy/install/populateSeedData.php
Executable file
|
@ -0,0 +1,498 @@
|
|||
<?php
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
// load the correct demo data and main application language file depending upon the installer language selected; if
|
||||
// it's not found fall back on en_us
|
||||
if (file_exists("include/language/{$current_language}.lang.php")) {
|
||||
require_once("include/language/{$current_language}.lang.php");
|
||||
} else {
|
||||
require_once("include/language/en_us.lang.php");
|
||||
}
|
||||
require_once('install/UserDemoData.php');
|
||||
require_once('install/TeamDemoData.php');
|
||||
|
||||
global $sugar_demodata;
|
||||
if (file_exists("install/demoData.{$current_language}.php")) {
|
||||
require_once("install/demoData.{$current_language}.php");
|
||||
} else {
|
||||
require_once("install/demoData.en_us.php");
|
||||
}
|
||||
|
||||
$last_name_count = count($sugar_demodata['last_name_array']);
|
||||
$first_name_count = count($sugar_demodata['first_name_array']);
|
||||
$company_name_count = count($sugar_demodata['company_name_array']);
|
||||
$street_address_count = count($sugar_demodata['street_address_array']);
|
||||
$city_array_count = count($sugar_demodata['city_array']);
|
||||
global $app_list_strings;
|
||||
global $sugar_config;
|
||||
$_REQUEST['useEmailWidget'] = "true";
|
||||
if (empty($app_list_strings)) {
|
||||
$app_list_strings = return_app_list_strings_language('en_us');
|
||||
}
|
||||
/*
|
||||
* Seed the random number generator with a fixed constant. This will make all installs of the same code have the same
|
||||
* seed data. This facilitates cross database testing..
|
||||
*/
|
||||
mt_srand(93285903);
|
||||
$db = DBManagerFactory::getInstance();
|
||||
$timedate = TimeDate::getInstance();
|
||||
// Set the max time to one hour (helps Windows load the seed data)
|
||||
ini_set("max_execution_time", "3600");
|
||||
// ensure we have enough memory
|
||||
$memory_needed = 256;
|
||||
$memory_limit = ini_get('memory_limit');
|
||||
if ($memory_limit != "" && $memory_limit != "-1") { // if memory_limit is set
|
||||
rtrim($memory_limit, 'M');
|
||||
$memory_limit_int = (int) $memory_limit;
|
||||
if ($memory_limit_int < $memory_needed) {
|
||||
ini_set("memory_limit", (string)$memory_needed . "M");
|
||||
}
|
||||
}
|
||||
$large_scale_test = empty($sugar_config['large_scale_test']) ?
|
||||
false : $sugar_config['large_scale_test'];
|
||||
|
||||
$seed_user = BeanFactory::newBean('Users');
|
||||
$user_demo_data = new UserDemoData($seed_user, $large_scale_test);
|
||||
$user_demo_data->create_demo_data();
|
||||
$number_contacts = 200;
|
||||
$number_companies = 50;
|
||||
$number_leads = 200;
|
||||
$large_scale_test = empty($sugar_config['large_scale_test']) ? false : $sugar_config['large_scale_test'];
|
||||
// If large scale test is set to true, increase the seed data.
|
||||
if ($large_scale_test) {
|
||||
// increase the cuttoff time to 1 hour
|
||||
ini_set("max_execution_time", "3600");
|
||||
$number_contacts = 100000;
|
||||
$number_companies = 15000;
|
||||
$number_leads = 100000;
|
||||
}
|
||||
|
||||
|
||||
$possible_duration_hours_arr = array( 0, 1, 2, 3);
|
||||
$possible_duration_minutes_arr = array('00' => '00','15' => '15', '30' => '30', '45' => '45');
|
||||
$account_ids = array();
|
||||
$accounts = array();
|
||||
$opportunity_ids = array();
|
||||
|
||||
// Determine the assigned user for all demo data. This is the default user if set, or admin
|
||||
$assigned_user_name = "admin";
|
||||
if (!empty($sugar_config['default_user_name']) &&
|
||||
!empty($sugar_config['create_default_user']) &&
|
||||
$sugar_config['create_default_user']) {
|
||||
$assigned_user_name = $sugar_config['default_user_name'];
|
||||
}
|
||||
|
||||
// Look up the user id for the assigned user
|
||||
$seed_user = BeanFactory::newBean('Users');
|
||||
$assigned_user_id = $seed_user->retrieve_user_id($assigned_user_name);
|
||||
$patterns[] = '/ /';
|
||||
$patterns[] = '/\./';
|
||||
$patterns[] = '/&/';
|
||||
$patterns[] = '/\//';
|
||||
$replacements[] = '';
|
||||
$replacements[] = '';
|
||||
$replacements[] = '';
|
||||
$replacements[] = '';
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// ACCOUNTS
|
||||
|
||||
for ($i = 0; $i < $number_companies; $i++) {
|
||||
$account_name = $sugar_demodata['company_name_array'][mt_rand(0, $company_name_count-1)];
|
||||
// Create new accounts.
|
||||
$account = BeanFactory::newBean('Accounts');
|
||||
$account->name = $account_name;
|
||||
$account->phone_office = create_phone_number();
|
||||
$account->assigned_user_id = $assigned_user_id;
|
||||
$account->emailAddress->addAddress(createEmailAddress(), true);
|
||||
$account->emailAddress->addAddress(createEmailAddress());
|
||||
$account->website = createWebAddress();
|
||||
$account->billing_address_street = $sugar_demodata['street_address_array'][mt_rand(0, $street_address_count-1)];
|
||||
$account->billing_address_city = $sugar_demodata['city_array'][mt_rand(0, $city_array_count-1)];
|
||||
if ($i % 3 == 1) {
|
||||
$account->billing_address_state = "NY";
|
||||
$assigned_user_id = mt_rand(9, 10);
|
||||
if ($assigned_user_id == 9) {
|
||||
$account->assigned_user_name = "seed_will";
|
||||
$account->assigned_user_id = $account->assigned_user_name."_id";
|
||||
} else {
|
||||
$account->assigned_user_name = "seed_chris";
|
||||
$account->assigned_user_id = $account->assigned_user_name."_id";
|
||||
}
|
||||
|
||||
$account->assigned_user_id = $account->assigned_user_name."_id";
|
||||
} else {
|
||||
$account->billing_address_state = "CA";
|
||||
$assigned_user_id = mt_rand(6, 8);
|
||||
if ($assigned_user_id == 6) {
|
||||
$account->assigned_user_name = "seed_sarah";
|
||||
} elseif ($assigned_user_id == 7) {
|
||||
$account->assigned_user_name = "seed_sally";
|
||||
} else {
|
||||
$account->assigned_user_name = "seed_max";
|
||||
}
|
||||
|
||||
$account->assigned_user_id = $account->assigned_user_name."_id";
|
||||
}
|
||||
|
||||
$account->billing_address_postalcode = mt_rand(10000, 99999);
|
||||
$account->billing_address_country = 'USA';
|
||||
$account->shipping_address_street = $account->billing_address_street;
|
||||
$account->shipping_address_city = $account->billing_address_city;
|
||||
$account->shipping_address_state = $account->billing_address_state;
|
||||
$account->shipping_address_postalcode = $account->billing_address_postalcode;
|
||||
$account->shipping_address_country = $account->billing_address_country;
|
||||
$account->industry = array_rand($app_list_strings['industry_dom']);
|
||||
$account->account_type = "Customer";
|
||||
$account->save();
|
||||
$account_ids[] = $account->id;
|
||||
$accounts[] = $account;
|
||||
|
||||
// Create a case for the account
|
||||
$case = BeanFactory::newBean('Cases');
|
||||
$case->account_id = $account->id;
|
||||
$case->priority = array_rand($app_list_strings['case_priority_dom']);
|
||||
$case->status = array_rand($app_list_strings['case_status_dom']);
|
||||
$case->name = $sugar_demodata['case_seed_names'][mt_rand(0, 4)];
|
||||
$case->assigned_user_id = $account->assigned_user_id;
|
||||
$case->assigned_user_name = $account->assigned_user_name;
|
||||
$case->save();
|
||||
|
||||
// Create a bug for the account
|
||||
$bug = BeanFactory::newBean('Bugs');
|
||||
$bug->account_id = $account->id;
|
||||
$bug->priority = array_rand($app_list_strings['bug_priority_dom']);
|
||||
$bug->status = array_rand($app_list_strings['bug_status_dom']);
|
||||
$bug->name = $sugar_demodata['bug_seed_names'][mt_rand(0, 4)];
|
||||
$bug->assigned_user_id = $account->assigned_user_id;
|
||||
$bug->assigned_user_name = $account->assigned_user_name;
|
||||
$bug->save();
|
||||
|
||||
$note = BeanFactory::newBean('Notes');
|
||||
$note->parent_type = 'Accounts';
|
||||
$note->parent_id = $account->id;
|
||||
$seed_data_index = mt_rand(0, 3);
|
||||
$note->name = $sugar_demodata['note_seed_names_and_Descriptions'][$seed_data_index][0];
|
||||
$note->description = $sugar_demodata['note_seed_names_and_Descriptions'][$seed_data_index][1];
|
||||
$note->assigned_user_id = $account->assigned_user_id;
|
||||
$note->assigned_user_name = $account->assigned_user_name;
|
||||
$note->save();
|
||||
|
||||
$call = BeanFactory::newBean('Calls');
|
||||
$call->parent_type = 'Accounts';
|
||||
$call->parent_id = $account->id;
|
||||
$call->name = $sugar_demodata['call_seed_data_names'][mt_rand(0, 3)];
|
||||
$call->assigned_user_id = $account->assigned_user_id;
|
||||
$call->assigned_user_name = $account->assigned_user_name;
|
||||
$call->direction='Outbound';
|
||||
$call->date_start = create_date(). ' ' . create_time();
|
||||
$call->duration_hours='0';
|
||||
$call->duration_minutes='30';
|
||||
$call->account_id =$account->id;
|
||||
$call->status='Planned';
|
||||
$call->save();
|
||||
|
||||
//Set the user to accept the call
|
||||
$seed_user->id = $call->assigned_user_id;
|
||||
$call->set_accept_status($seed_user, 'accept');
|
||||
|
||||
//Create new opportunities
|
||||
$opp = BeanFactory::newBean('Opportunities');
|
||||
$opp->assigned_user_id = $account->assigned_user_id;
|
||||
$opp->assigned_user_name = $account->assigned_user_name;
|
||||
$opp->name = substr($account_name." - 1000 units", 0, 50);
|
||||
$opp->date_closed = create_date();
|
||||
$opp->lead_source = array_rand($app_list_strings['lead_source_dom']);
|
||||
$opp->sales_stage = array_rand($app_list_strings['sales_stage_dom']);
|
||||
// If the deal is already one, make the date closed occur in the past.
|
||||
if ($opp->sales_stage == "Closed Won" || $opp->sales_stage == "Closed Lost") {
|
||||
$opp->date_closed = create_past_date();
|
||||
}
|
||||
$opp->opportunity_type = array_rand($app_list_strings['opportunity_type_dom']);
|
||||
$amount = array("10000", "25000", "50000", "75000");
|
||||
$key = array_rand($amount);
|
||||
$opp->amount = $amount[$key];
|
||||
$probability = array("10", "70", "40", "60");
|
||||
$key = array_rand($probability);
|
||||
$opp->probability = $probability[$key];
|
||||
$opp->save();
|
||||
$opportunity_ids[] = $opp->id;
|
||||
// Create a linking table entry to assign an account to the opportunity.
|
||||
$opp->set_relationship('accounts_opportunities', array('opportunity_id'=>$opp->id ,'account_id'=> $account->id), false);
|
||||
}
|
||||
|
||||
$titles = $sugar_demodata['titles'];
|
||||
$account_max = count($account_ids) - 1;
|
||||
$first_name_max = $first_name_count - 1;
|
||||
$last_name_max = $last_name_count - 1;
|
||||
$street_address_max = $street_address_count - 1;
|
||||
$city_array_max = $city_array_count - 1;
|
||||
$lead_source_max = count($app_list_strings['lead_source_dom']) - 1;
|
||||
$lead_status_max = count($app_list_strings['lead_status_dom']) - 1;
|
||||
$title_max = count($titles) - 1;
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// DEMO CONTACTS
|
||||
for ($i=0; $i<$number_contacts; $i++) {
|
||||
$contact = BeanFactory::newBean('Contacts');
|
||||
$contact->first_name = $sugar_demodata['first_name_array'][mt_rand(0, $first_name_max)];
|
||||
$contact->last_name = $sugar_demodata['last_name_array'][mt_rand(0, $last_name_max)];
|
||||
$contact->assigned_user_id = $account->assigned_user_id;
|
||||
$contact->primary_address_street = $sugar_demodata['street_address_array'][mt_rand(0, $street_address_max)];
|
||||
$contact->primary_address_city = $sugar_demodata['city_array'][mt_rand(0, $city_array_max)];
|
||||
$contact->lead_source = array_rand($app_list_strings['lead_source_dom']);
|
||||
$contact->title = $titles[mt_rand(0, $title_max)];
|
||||
$contact->emailAddress->addAddress(createEmailAddress(), true, true);
|
||||
$contact->emailAddress->addAddress(createEmailAddress(), false, false, false, true);
|
||||
$assignedUser = BeanFactory::newBean('Users');
|
||||
$assignedUser->retrieve($contact->assigned_user_id);
|
||||
$contact->assigned_user_id = $assigned_user_id;
|
||||
$contact->email1 = createEmailAddress();
|
||||
$key = array_rand($sugar_demodata['street_address_array']);
|
||||
$contact->primary_address_street = $sugar_demodata['street_address_array'][$key];
|
||||
$key = array_rand($sugar_demodata['city_array']);
|
||||
$contact->primary_address_city = $sugar_demodata['city_array'][$key];
|
||||
$contact->lead_source = array_rand($app_list_strings['lead_source_dom']);
|
||||
$contact->title = $titles[array_rand($titles)];
|
||||
$contact->phone_work = create_phone_number();
|
||||
$contact->phone_home = create_phone_number();
|
||||
$contact->phone_mobile = create_phone_number();
|
||||
$account_number = mt_rand(0, $account_max);
|
||||
$account_id = $account_ids[$account_number];
|
||||
// Fill in a bogus address
|
||||
$contacts_account = $accounts[$account_number];
|
||||
$contact->primary_address_state = $contacts_account->billing_address_state;
|
||||
$contact->assigned_user_id = $contacts_account->assigned_user_id;
|
||||
$contact->assigned_user_name = $contacts_account->assigned_user_name;
|
||||
$contact->primary_address_postalcode = mt_rand(10000, 99999);
|
||||
$contact->primary_address_country = 'USA';
|
||||
$contact->save();
|
||||
// Create a linking table entry to assign an account to the contact.
|
||||
$contact->set_relationship('accounts_contacts', array('contact_id'=>$contact->id ,'account_id'=> $account_id), false);
|
||||
// This assumes that there will be one opportunity per company in the seed data.
|
||||
$opportunity_key = array_rand($opportunity_ids);
|
||||
$contact->set_relationship('opportunities_contacts', array('contact_id'=>$contact->id ,'opportunity_id'=> $opportunity_ids[$opportunity_key], 'contact_role'=>$app_list_strings['opportunity_relationship_type_default_key']), false);
|
||||
|
||||
//Create new tasks
|
||||
$task = BeanFactory::newBean('Tasks');
|
||||
$key = array_rand($sugar_demodata['task_seed_data_names']);
|
||||
$task->name = $sugar_demodata['task_seed_data_names'][$key];
|
||||
//separate date and time field have been merged into one.
|
||||
$task->date_due = create_date() . ' ' . create_time();
|
||||
$task->date_due_flag = 0;
|
||||
$task->assigned_user_id = $contacts_account->assigned_user_id;
|
||||
$task->assigned_user_name = $contacts_account->assigned_user_name;
|
||||
$task->priority = array_rand($app_list_strings['task_priority_dom']);
|
||||
$task->status = array_rand($app_list_strings['task_status_dom']);
|
||||
$task->contact_id = $contact->id;
|
||||
if ($contact->primary_address_city == "San Mateo") {
|
||||
$task->parent_id = $account_id;
|
||||
$task->parent_type = 'Accounts';
|
||||
}
|
||||
$task->save();
|
||||
|
||||
//Create new meetings
|
||||
$meeting = BeanFactory::newBean('Meetings');
|
||||
$key = array_rand($sugar_demodata['meeting_seed_data_names']);
|
||||
$meeting->name = $sugar_demodata['meeting_seed_data_names'][$key];
|
||||
$meeting->date_start = create_date(). ' ' . create_time();
|
||||
//$meeting->time_start = date("H:i",time());
|
||||
$meeting->duration_hours = array_rand($possible_duration_hours_arr);
|
||||
$meeting->duration_minutes = array_rand($possible_duration_minutes_arr);
|
||||
$meeting->assigned_user_id = $assigned_user_id;
|
||||
$meeting->assigned_user_id = $contacts_account->assigned_user_id;
|
||||
$meeting->assigned_user_name = $contacts_account->assigned_user_name;
|
||||
$meeting->description = $sugar_demodata['meeting_seed_data_descriptions'];
|
||||
$meeting->status = array_rand($app_list_strings['meeting_status_dom']);
|
||||
$meeting->contact_id = $contact->id;
|
||||
$meeting->parent_id = $account_id;
|
||||
$meeting->parent_type = 'Accounts';
|
||||
// dont update vcal
|
||||
$meeting->update_vcal = false;
|
||||
$meeting->save();
|
||||
// leverage the seed user to set the acceptance status on the meeting.
|
||||
$seed_user->id = $meeting->assigned_user_id;
|
||||
$meeting->set_accept_status($seed_user, 'accept');
|
||||
|
||||
//Create new emails
|
||||
$email = BeanFactory::newBean('Emails');
|
||||
$key = array_rand($sugar_demodata['email_seed_data_subjects']);
|
||||
$email->name = $sugar_demodata['email_seed_data_subjects'][$key];
|
||||
$email->date_start = create_date();
|
||||
$email->time_start = create_time();
|
||||
$email->duration_hours = array_rand($possible_duration_hours_arr);
|
||||
$email->duration_minutes = array_rand($possible_duration_minutes_arr);
|
||||
$email->assigned_user_id = $assigned_user_id;
|
||||
$email->assigned_user_id = $contacts_account->assigned_user_id;
|
||||
$email->assigned_user_name = $contacts_account->assigned_user_name;
|
||||
$email->description = $sugar_demodata['email_seed_data_descriptions'];
|
||||
$email->status = 'sent';
|
||||
$email->parent_id = $account_id;
|
||||
$email->parent_type = 'Accounts';
|
||||
$email->to_addrs = $contact->emailAddress->getPrimaryAddress($contact);
|
||||
$email->from_addr = $assignedUser->emailAddress->getPrimaryAddress($assignedUser);
|
||||
isValidEmailAddress($email->from_addr);
|
||||
$email->from_addr_name = $email->from_addr;
|
||||
$email->to_addrs_names = $email->to_addrs;
|
||||
$email->type = 'out';
|
||||
$email->save();
|
||||
$email->load_relationship('contacts');
|
||||
$email->contacts->add($contact);
|
||||
$email->load_relationship('accounts');
|
||||
$email->accounts->add($contacts_account);
|
||||
}
|
||||
|
||||
for ($i=0; $i<$number_leads; $i++) {
|
||||
$lead = BeanFactory::newBean('Leads');
|
||||
$lead->account_name = $sugar_demodata['company_name_array'][mt_rand(0, $company_name_count-1)];
|
||||
$lead->first_name = $sugar_demodata['first_name_array'][mt_rand(0, $first_name_max)];
|
||||
$lead->last_name = $sugar_demodata['last_name_array'][mt_rand(0, $last_name_max)];
|
||||
$lead->primary_address_street = $sugar_demodata['street_address_array'][mt_rand(0, $street_address_max)];
|
||||
$lead->primary_address_city = $sugar_demodata['city_array'][mt_rand(0, $city_array_max)];
|
||||
$lead->lead_source = array_rand($app_list_strings['lead_source_dom']);
|
||||
$lead->title = $sugar_demodata['titles'][mt_rand(0, $title_max)];
|
||||
$lead->phone_work = create_phone_number();
|
||||
$lead->phone_home = create_phone_number();
|
||||
$lead->phone_mobile = create_phone_number();
|
||||
$lead->emailAddress->addAddress(createEmailAddress(), true);
|
||||
// Fill in a bogus address
|
||||
$lead->primary_address_state = $sugar_demodata['primary_address_state'];
|
||||
$leads_account = $accounts[$account_number];
|
||||
$lead->primary_address_state = $leads_account->billing_address_state;
|
||||
$lead->status = array_rand($app_list_strings['lead_status_dom']);
|
||||
$lead->lead_source = array_rand($app_list_strings['lead_source_dom']);
|
||||
if ($i % 3 == 1) {
|
||||
$lead->billing_address_state = $sugar_demodata['billing_address_state']['east'];
|
||||
$assigned_user_id = mt_rand(9, 10);
|
||||
if ($assigned_user_id == 9) {
|
||||
$lead->assigned_user_name = "seed_will";
|
||||
$lead->assigned_user_id = $lead->assigned_user_name."_id";
|
||||
} else {
|
||||
$lead->assigned_user_name = "seed_chris";
|
||||
$lead->assigned_user_id = $lead->assigned_user_name."_id";
|
||||
}
|
||||
|
||||
$lead->assigned_user_id = $lead->assigned_user_name."_id";
|
||||
} else {
|
||||
$lead->billing_address_state = $sugar_demodata['billing_address_state']['west'];
|
||||
$assigned_user_id = mt_rand(6, 8);
|
||||
if ($assigned_user_id == 6) {
|
||||
$lead->assigned_user_name = "seed_sarah";
|
||||
} else {
|
||||
if ($assigned_user_id == 7) {
|
||||
$lead->assigned_user_name = "seed_sally";
|
||||
} else {
|
||||
$lead->assigned_user_name = "seed_max";
|
||||
}
|
||||
}
|
||||
|
||||
$lead->assigned_user_id = $lead->assigned_user_name."_id";
|
||||
}
|
||||
|
||||
|
||||
// If this is a large scale test, switch to the bulk teams 90% of the time.
|
||||
if ($large_scale_test) {
|
||||
if (mt_rand(0, 100) < 90) {
|
||||
$assigned_team = $team_demo_data->get_random_team();
|
||||
$lead->assigned_user_name = $assigned_team;
|
||||
} else {
|
||||
}
|
||||
}
|
||||
$lead->primary_address_postalcode = mt_rand(10000, 99999);
|
||||
$lead->primary_address_country = $sugar_demodata['primary_address_country'];
|
||||
$lead->save();
|
||||
}
|
||||
|
||||
|
||||
///
|
||||
/// SEED DATA FOR EMAIL TEMPLATES
|
||||
///
|
||||
if (!empty($sugar_demodata['emailtemplates_seed_data'])) {
|
||||
foreach ($sugar_demodata['emailtemplates_seed_data'] as $v) {
|
||||
$EmailTemp = BeanFactory::newBean('EmailTemplates');
|
||||
$EmailTemp->name = $v['name'];
|
||||
$EmailTemp->description = $v['description'];
|
||||
$EmailTemp->subject = $v['subject'];
|
||||
$EmailTemp->body = $v['text_body'];
|
||||
$EmailTemp->body_html = $v['body'];
|
||||
$EmailTemp->deleted = 0;
|
||||
$EmailTemp->published = 'off';
|
||||
$EmailTemp->text_only = 0;
|
||||
$id =$EmailTemp->save();
|
||||
}
|
||||
}
|
||||
///
|
||||
/// SEED DATA FOR PROJECT AND PROJECT TASK
|
||||
///
|
||||
include_once('modules/Project/Project.php');
|
||||
include_once('modules/ProjectTask/ProjectTask.php');
|
||||
// Project: Audit Plan
|
||||
$project = BeanFactory::newBean('Project');
|
||||
$project->name = $sugar_demodata['project_seed_data']['audit']['name'];
|
||||
$project->description = $sugar_demodata['project_seed_data']['audit']['description'];
|
||||
$project->assigned_user_id = 1;
|
||||
$project->estimated_start_date = $sugar_demodata['project_seed_data']['audit']['estimated_start_date'];
|
||||
$project->estimated_end_date = $sugar_demodata['project_seed_data']['audit']['estimated_end_date'];
|
||||
$project->status = $sugar_demodata['project_seed_data']['audit']['status'];
|
||||
$project->priority = $sugar_demodata['project_seed_data']['audit']['priority'];
|
||||
$audit_plan_id = $project->save();
|
||||
|
||||
$project_task_id_counter = 1; // all the project task IDs cannot be 1, so using couter
|
||||
foreach ($sugar_demodata['project_seed_data']['audit']['project_tasks'] as $v) {
|
||||
$project_task = BeanFactory::newBean('ProjectTask');
|
||||
$project_task->assigned_user_id = 1;
|
||||
$project_task->name = $v['name'];
|
||||
$project_task->date_start = $v['date_start'];
|
||||
$project_task->date_finish = $v['date_finish'];
|
||||
$project_task->project_id = $audit_plan_id;
|
||||
$project_task->project_task_id = $project_task_id_counter;
|
||||
$project_task->description = $v['description'];
|
||||
$project_task->duration = $v['duration'];
|
||||
$project_task->duration_unit = $v['duration_unit'];
|
||||
$project_task->percent_complete = $v['percent_complete'];
|
||||
$communicate_stakeholders_id = $project_task->save();
|
||||
|
||||
$project_task_id_counter++;
|
||||
}
|
BIN
public/legacy/install/processing.gif
Executable file
BIN
public/legacy/install/processing.gif
Executable file
Binary file not shown.
After Width: | Height: | Size: 11 KiB |
168
public/legacy/install/ready.css
Normal file
168
public/legacy/install/ready.css
Normal file
|
@ -0,0 +1,168 @@
|
|||
/* common */
|
||||
* {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
font-size: 12px;
|
||||
font-weight: normal;
|
||||
color: #333333;
|
||||
}
|
||||
|
||||
body {
|
||||
background-color: #f7f7f7;;
|
||||
}
|
||||
|
||||
|
||||
h3 {
|
||||
font-size: 16px;
|
||||
font-weight: bold;
|
||||
}
|
||||
b, strong {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
a:link, a:visited {
|
||||
font-size: 12px; color: #333333;
|
||||
text-decoration: none;
|
||||
font-family: Arial, Verdana, Helvetica, sans-serif;
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
a:hover {
|
||||
color: #EA1313;
|
||||
text-decoration: none;
|
||||
text-decoration: underline;
|
||||
}
|
||||
.clear {
|
||||
clear: both;
|
||||
}
|
||||
|
||||
/* buttons */
|
||||
#install_container .button,
|
||||
#install_container .acceptButton {
|
||||
background-color:#B41C4F;
|
||||
text-indent:0;
|
||||
display:inline-block;
|
||||
color:#ffffff;
|
||||
font-size:14px;
|
||||
font-style:normal;
|
||||
height:30px;
|
||||
line-height:15px;
|
||||
text-decoration:none;
|
||||
text-align:center;
|
||||
text-shadow:1px 1px 0px #810e05;
|
||||
cursor:pointer;
|
||||
padding: 0 10px 0 10px;
|
||||
transition: all 0.5s ease;
|
||||
}
|
||||
|
||||
#install_container .button:hover,
|
||||
#install_container .acceptButton:hover {
|
||||
background:#565656;
|
||||
transition: all 0.5s ease;
|
||||
}
|
||||
|
||||
/* Sys env. msg */
|
||||
|
||||
#syscred p {
|
||||
margin: 0;
|
||||
padding: 2px;
|
||||
border: none;
|
||||
width: 49%;
|
||||
min-width: 330px;
|
||||
float: left;
|
||||
}
|
||||
#syscred p b {
|
||||
float: left;
|
||||
margin-right: 10px;
|
||||
}
|
||||
#syscred p span.stop * {
|
||||
color: red;
|
||||
display: block;
|
||||
float: left;
|
||||
}
|
||||
/* ----------------------------------------------- */
|
||||
|
||||
/*
|
||||
#install_container * {
|
||||
background-color: white;
|
||||
}
|
||||
*/
|
||||
|
||||
/* header (logo & steps) */
|
||||
#install_header {
|
||||
margin:10px auto;
|
||||
border-bottom:1px solid #cccccc;
|
||||
height:50px;
|
||||
}
|
||||
|
||||
#install_header img {
|
||||
float:left;
|
||||
padding:0;
|
||||
max-height:40px;
|
||||
}
|
||||
|
||||
/* steps */
|
||||
#steps {
|
||||
font-size:24px;
|
||||
verticle-align:top;
|
||||
float:right;
|
||||
margin: 0 5px 0 0;
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
#steps p {
|
||||
font-size:14px;
|
||||
margin:0 0 2px 5px;
|
||||
}
|
||||
|
||||
#steps i {
|
||||
font-size: 24px;
|
||||
}
|
||||
#complete {
|
||||
color: green;
|
||||
}
|
||||
|
||||
|
||||
/* logo image */
|
||||
.install_img {
|
||||
max-width:200px;
|
||||
}
|
||||
|
||||
.install_img:hover {
|
||||
transition: all 0.5s ease;
|
||||
opacity:0.8;
|
||||
}
|
||||
|
||||
|
||||
#install_box {
|
||||
line-height: 1.4em;
|
||||
background:#ffffff;
|
||||
border:1px solid #cccccc;
|
||||
vertical-align:middle;
|
||||
padding: 10px 20px;
|
||||
margin: 20px;
|
||||
|
||||
}
|
||||
|
||||
/* install controlls*/
|
||||
#installcontrols {
|
||||
/*float:right;*/
|
||||
text-align: right;
|
||||
padding:10px;
|
||||
}
|
||||
|
||||
/* footer & footer links */
|
||||
|
||||
#install_footer {
|
||||
margin:10px auto;
|
||||
height:50px;
|
||||
}
|
||||
|
||||
#footer_links a{
|
||||
text-decoration:none;
|
||||
}
|
||||
|
||||
p#footer_links {
|
||||
text-align:center;
|
||||
margin-top:10px;
|
||||
}
|
||||
|
394
public/legacy/install/ready.php
Executable file
394
public/legacy/install/ready.php
Executable file
|
@ -0,0 +1,394 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
|
||||
include_once __DIR__ . '/../include/Imap/ImapHandlerFactory.php';
|
||||
|
||||
if (!isset($install_script) || !$install_script) {
|
||||
die($mod_strings['ERR_NO_DIRECT_SCRIPT']);
|
||||
}
|
||||
// $mod_strings come from calling page.
|
||||
|
||||
|
||||
// System Environment
|
||||
$envString = '
|
||||
|
||||
<h3>'.$mod_strings['LBL_SYSTEM_ENV'].'</h3>';
|
||||
|
||||
// PHP VERSION
|
||||
$envString .='<p><b>'.$mod_strings['LBL_CHECKSYS_PHPVER'].'</b> '.constant('PHP_VERSION').'</p>';
|
||||
|
||||
|
||||
//Begin List of already known good variables. These were checked during the initial sys check
|
||||
// XML Parsing
|
||||
$envString .='<p><b>'.$mod_strings['LBL_CHECKSYS_XML'].'</b> '.$mod_strings['LBL_CHECKSYS_OK'].'</p>';
|
||||
|
||||
|
||||
|
||||
// mbstrings
|
||||
|
||||
$envString .='<p><b>'.$mod_strings['LBL_CHECKSYS_MBSTRING'].'</b> '.$mod_strings['LBL_CHECKSYS_OK'].'</p>';
|
||||
|
||||
// config.php
|
||||
$envString .='<p><b>'.$mod_strings['LBL_CHECKSYS_CONFIG'].'</b> '.$mod_strings['LBL_CHECKSYS_OK'].'</p>';
|
||||
|
||||
// custom dir
|
||||
|
||||
|
||||
$envString .='<p><b>'.$mod_strings['LBL_CHECKSYS_CUSTOM'].'</b> '.$mod_strings['LBL_CHECKSYS_OK'].'</p>';
|
||||
|
||||
|
||||
// modules dir
|
||||
$envString .='<p><b>'.$mod_strings['LBL_CHECKSYS_MODULE'].'</b> '.$mod_strings['LBL_CHECKSYS_OK'].'</p>';
|
||||
|
||||
// upload dir
|
||||
$envString .='<p><b>'.$mod_strings['LBL_CHECKSYS_UPLOAD'].'</b> '.$mod_strings['LBL_CHECKSYS_OK'].'</p>';
|
||||
|
||||
// data dir
|
||||
|
||||
$envString .='<p><b>'.$mod_strings['LBL_CHECKSYS_DATA'].'</b> '.$mod_strings['LBL_CHECKSYS_OK'].'</p>';
|
||||
|
||||
// cache dir
|
||||
$error_found = true;
|
||||
$envString .='<p><b>'.$mod_strings['LBL_CHECKSYS_CACHE'].'</b> '.$mod_strings['LBL_CHECKSYS_OK'].'</p>';
|
||||
// End already known to be good
|
||||
|
||||
// memory limit
|
||||
$memory_msg = "";
|
||||
// CL - fix for 9183 (if memory_limit is enabled we will honor it and check it; otherwise use unlimited)
|
||||
$memory_limit = ini_get('memory_limit');
|
||||
if (empty($memory_limit)) {
|
||||
$memory_limit = "-1";
|
||||
}
|
||||
if (!defined('SUGARCRM_MIN_MEM')) {
|
||||
define('SUGARCRM_MIN_MEM', 64*1024*1024);
|
||||
}
|
||||
$sugarMinMem = constant('SUGARCRM_MIN_MEM');
|
||||
// logic based on: http://us2.php.net/manual/en/ini.core.php#ini.memory-limit
|
||||
if ($memory_limit == "") { // memory_limit disabled at compile time, no memory limit
|
||||
$memory_msg = "<b>{$mod_strings['LBL_CHECKSYS_MEM_OK']}</b>";
|
||||
} elseif ($memory_limit == "-1") { // memory_limit enabled, but set to unlimited
|
||||
$memory_msg = (string)($mod_strings['LBL_CHECKSYS_MEM_UNLIMITED']);
|
||||
} else {
|
||||
$mem_display = $memory_limit;
|
||||
preg_match('/^\s*([0-9.]+)\s*([KMGTPE])B?\s*$/i', $memory_limit, $matches);
|
||||
$num = (float)$matches[1];
|
||||
// Don't break so that it falls through to the next case.
|
||||
switch (strtoupper($matches[2])) {
|
||||
case 'G':
|
||||
$num = $num * 1024;
|
||||
// no break
|
||||
case 'M':
|
||||
$num = $num * 1024;
|
||||
// no break
|
||||
case 'K':
|
||||
$num = $num * 1024;
|
||||
}
|
||||
$memory_limit_int = (int)$num;
|
||||
$SUGARCRM_MIN_MEM = (int) constant('SUGARCRM_MIN_MEM');
|
||||
if ($memory_limit_int < constant('SUGARCRM_MIN_MEM')) {
|
||||
// Bug59667: The string ERR_CHECKSYS_MEM_LIMIT_2 already has 'M' in it,
|
||||
// so we divide the constant by 1024*1024.
|
||||
$min_mem_in_megs = constant('SUGARCRM_MIN_MEM')/(1024*1024);
|
||||
$memory_msg = "<span class='stop'><b>$memory_limit{$mod_strings['ERR_CHECKSYS_MEM_LIMIT_1']}" . $min_mem_in_megs . "{$mod_strings['ERR_CHECKSYS_MEM_LIMIT_2']}</b></span>";
|
||||
$memory_msg = str_replace('$memory_limit', $mem_display, $memory_msg);
|
||||
} else {
|
||||
$memory_msg = "{$mod_strings['LBL_CHECKSYS_OK']} ({$memory_limit})";
|
||||
}
|
||||
}
|
||||
|
||||
$envString .='<p><b>'.$mod_strings['LBL_CHECKSYS_MEM'].'</strong></b> '.$memory_msg.'</p>';
|
||||
|
||||
// zlib
|
||||
if (function_exists('gzclose')) {
|
||||
$zlibStatus = (string)($mod_strings['LBL_CHECKSYS_OK']);
|
||||
} else {
|
||||
$zlibStatus = "<span class='stop'><b>{$mod_strings['ERR_CHECKSYS_ZLIB']}</b></span>";
|
||||
}
|
||||
$envString .='<p><b>'.$mod_strings['LBL_CHECKSYS_ZLIB'].'</b> '.$zlibStatus.'</p>';
|
||||
|
||||
// zip
|
||||
if (class_exists("ZipArchive")) {
|
||||
$zipStatus = (string)($mod_strings['LBL_CHECKSYS_OK']);
|
||||
} else {
|
||||
$zipStatus = "<span class='stop'><b>{$mod_strings['ERR_CHECKSYS_ZIP']}</b></span>";
|
||||
}
|
||||
$envString .='<p><b>'.$mod_strings['LBL_CHECKSYS_ZIP'].'</b> '.$zipStatus.'</p>';
|
||||
|
||||
// PCRE
|
||||
if (defined('PCRE_VERSION')) {
|
||||
if (version_compare(PCRE_VERSION, '7.0') < 0) {
|
||||
$pcreStatus = "<span class='stop'><b>{$mod_strings['ERR_CHECKSYS_PCRE_VER']}</b></span>";
|
||||
} else {
|
||||
$pcreStatus = (string)($mod_strings['LBL_CHECKSYS_OK']);
|
||||
}
|
||||
} else {
|
||||
$pcreStatus = "<span class='stop'><b>{$mod_strings['ERR_CHECKSYS_PCRE']}</b></span>";
|
||||
}
|
||||
$envString .='<p><b>'.$mod_strings['LBL_CHECKSYS_PCRE'].'</b> '.$pcreStatus.'</p>';
|
||||
|
||||
// imap
|
||||
$imapFactory = new ImapHandlerFactory();
|
||||
$imap = $imapFactory->getImapHandler();
|
||||
if ($imap->isAvailable()) {
|
||||
$imapStatus = (string)($mod_strings['LBL_CHECKSYS_OK']);
|
||||
} else {
|
||||
$imapStatus = "<span class='stop'><b>{$mod_strings['ERR_CHECKSYS_IMAP']}</b></span>";
|
||||
}
|
||||
|
||||
$envString .='<p><b>'.$mod_strings['LBL_CHECKSYS_IMAP'].'</b> '.$imapStatus.'</p>';
|
||||
|
||||
|
||||
// cURL
|
||||
if (function_exists('curl_init')) {
|
||||
$curlStatus = (string)($mod_strings['LBL_CHECKSYS_OK']);
|
||||
} else {
|
||||
$curlStatus = "<span class='stop'><b>{$mod_strings['ERR_CHECKSYS_CURL']}</b></span>";
|
||||
}
|
||||
|
||||
$envString .='<p><b>'.$mod_strings['LBL_CHECKSYS_CURL'].'</b> '.$curlStatus.'</p>';
|
||||
|
||||
|
||||
//CHECK UPLOAD FILE SIZE
|
||||
$upload_max_filesize = ini_get('upload_max_filesize');
|
||||
$upload_max_filesize_bytes = return_bytes($upload_max_filesize);
|
||||
if (!defined('SUGARCRM_MIN_UPLOAD_MAX_FILESIZE_BYTES')) {
|
||||
define('SUGARCRM_MIN_UPLOAD_MAX_FILESIZE_BYTES', 6 * 1024 * 1024);
|
||||
}
|
||||
|
||||
if ($upload_max_filesize_bytes > constant('SUGARCRM_MIN_UPLOAD_MAX_FILESIZE_BYTES')) {
|
||||
$fileMaxStatus = "{$mod_strings['LBL_CHECKSYS_OK']}</font>";
|
||||
} else {
|
||||
$fileMaxStatus = "<span class='stop'><b>{$mod_strings['ERR_UPLOAD_MAX_FILESIZE']}</font></b></span>";
|
||||
}
|
||||
|
||||
$envString .='<p><b>'.$mod_strings['LBL_UPLOAD_MAX_FILESIZE_TITLE'].'</b> '.$fileMaxStatus.'</p>';
|
||||
|
||||
//CHECK Sprite support
|
||||
if (function_exists('imagecreatetruecolor')) {
|
||||
$spriteSupportStatus = "{$mod_strings['LBL_CHECKSYS_OK']}</font>";
|
||||
} else {
|
||||
$spriteSupportStatus = "<span class='stop'><b>{$mod_strings['ERROR_SPRITE_SUPPORT']}</b></span>";
|
||||
}
|
||||
$envString .='<p><b>'.$mod_strings['LBL_SPRITE_SUPPORT'].'</b> '.$spriteSupportStatus.'</p>';
|
||||
|
||||
// Suhosin allow to use upload://
|
||||
if (UploadStream::getSuhosinStatus() == true || (strpos(ini_get('suhosin.perdir'), 'e') !== false && strpos($_SERVER["SERVER_SOFTWARE"], 'Microsoft-IIS') === false)) {
|
||||
$suhosinStatus = (string)($mod_strings['LBL_CHECKSYS_OK']);
|
||||
} else {
|
||||
$suhosinStatus = "<span class='stop'><b>{$app_strings['ERR_SUHOSIN']}</b></span>";
|
||||
}
|
||||
$envString .= "<p><b>{$mod_strings['LBL_STREAM']} (" . UploadStream::STREAM_NAME . "://)</b> " . $suhosinStatus . "</p>";
|
||||
|
||||
// PHP.ini
|
||||
$phpIniLocation = get_cfg_var("cfg_file_path");
|
||||
$envString .='<p><b>'.$mod_strings['LBL_CHECKSYS_PHP_INI'].'</b> '.$phpIniLocation.'</p>';
|
||||
|
||||
$out =<<<EOQ
|
||||
|
||||
<div id="syscred">
|
||||
|
||||
EOQ;
|
||||
|
||||
$out .= $envString;
|
||||
|
||||
$out .=<<<EOQ
|
||||
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
EOQ;
|
||||
|
||||
$sugar_config_defaults = get_sugar_config_defaults();
|
||||
|
||||
// CRON Settings
|
||||
if (!isset($sugar_config['default_language'])) {
|
||||
$sugar_config['default_language'] = $_SESSION['default_language'];
|
||||
}
|
||||
if (!isset($sugar_config['cache_dir'])) {
|
||||
$sugar_config['cache_dir'] = $sugar_config_defaults['cache_dir'];
|
||||
}
|
||||
if (!isset($sugar_config['site_url'])) {
|
||||
$sugar_config['site_url'] = $_SESSION['setup_site_url'];
|
||||
}
|
||||
if (!isset($sugar_config['translation_string_prefix'])) {
|
||||
$sugar_config['translation_string_prefix'] = $sugar_config_defaults['translation_string_prefix'];
|
||||
}
|
||||
$mod_strings_scheduler = return_module_language($GLOBALS['current_language'], 'Schedulers');
|
||||
$error = '';
|
||||
|
||||
if (!isset($_SERVER['Path'])) {
|
||||
$_SERVER['Path'] = getenv('Path');
|
||||
}
|
||||
if (is_windows()) {
|
||||
if (isset($_SERVER['Path']) && !empty($_SERVER['Path'])) { // IIS IUSR_xxx may not have access to Path or it is not set
|
||||
if (!strpos($_SERVER['Path'], 'php')) {
|
||||
// $error = '<em>'.$mod_strings_scheduler['LBL_NO_PHP_CLI'].'</em>';
|
||||
}
|
||||
}
|
||||
$cronString = '<p><b>'.$mod_strings_scheduler['LBL_CRON_WINDOWS_DESC'].'</b><br>
|
||||
cd /D '.realpath('./').'<br>
|
||||
php.exe -f cron.php
|
||||
<br>'.$error.'</p>
|
||||
';
|
||||
} else {
|
||||
if (isset($_SERVER['Path']) && !empty($_SERVER['Path'])) { // some Linux servers do not make this available
|
||||
if (!strpos($_SERVER['PATH'], 'php')) {
|
||||
// $error = '<em>'.$mod_strings_scheduler['LBL_NO_PHP_CLI'].'</em>';
|
||||
}
|
||||
}
|
||||
require_once 'install/install_utils.php';
|
||||
$webServerUser = getRunningUser();
|
||||
if ($webServerUser == '') {
|
||||
$webServerUser = '<web_server_user>';
|
||||
}
|
||||
$cronString = '<p><b>'.$mod_strings_scheduler['LBL_CRON_INSTRUCTIONS_LINUX'].'</b><br> '.$mod_strings_scheduler['LBL_CRON_LINUX_DESC1'].'<br>
|
||||
<span style=\'background-color:#dfdfdf\'>sudo crontab -e -u '.$webServerUser.'</span><br> '.$mod_strings_scheduler['LBL_CRON_LINUX_DESC2'].'<br>
|
||||
<span style=\'background-color:#dfdfdf\'>* * * * *
|
||||
cd '.realpath('./').'; php -f cron.php > /dev/null 2>&1
|
||||
</span><br>'.$mod_strings_scheduler['LBL_CRON_LINUX_DESC3'].'
|
||||
<br><br><hr><br>'.$error.'</p>
|
||||
';
|
||||
}
|
||||
|
||||
$out .= $cronString;
|
||||
|
||||
$sysEnv = $out;
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// START OUTPUT
|
||||
|
||||
$langHeader = get_language_header();
|
||||
$out = <<<EOQ
|
||||
<!DOCTYPE HTML>
|
||||
<html {$langHeader}>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<meta content='width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0' name='viewport' />
|
||||
<title>{$mod_strings['LBL_WIZARD_TITLE']} {$mod_strings['LBL_TITLE_ARE_YOU_READY']}</title> <link REL="SHORTCUT ICON" HREF="include/images/sugar_icon.ico">
|
||||
<link rel="stylesheet" href="install/install2.css" type="text/css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/responsiveslides.css" type="text/css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/themes.css" type="text/css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/fontello.css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/animation.css"><!--[if IE 7]><link rel="stylesheet" href="css/fontello-ie7.css"><![endif]-->
|
||||
<script src="include/javascript/jquery/jquery-min.js"></script>
|
||||
<script src="themes/suite8/js/responsiveslides.min.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<!--SuiteCRM installer-->
|
||||
<div id="install_container">
|
||||
<div id="install_box">
|
||||
<header id="install_header">
|
||||
<div id="steps">
|
||||
<p>{$mod_strings['LBL_STEP1']}</p>
|
||||
<i class="icon-progress-0" id="complete"></i>
|
||||
<i class="icon-progress-1"></i>
|
||||
<i class="icon-progress-2"></i>
|
||||
</div>
|
||||
<!--
|
||||
<div id="steps"><p>{$mod_strings['LBL_STEP1']}</p><i class="icon-progress-0"></i><i class="icon-progress-1"></i><i class="icon-progress-2"></i><i class="icon-progress-3"></i><i class="icon-progress-4"></i><i class="icon-progress-5"></i><i class="icon-progress-6"></i><i class="icon-progress-7"></i></div>
|
||||
-->
|
||||
<div class="install_img"><a href="https://suitecrm.com" target="_blank"><img src="{$sugar_md}" alt="SuiteCRM"></a></div>
|
||||
</header>
|
||||
<form action="install.php" method="post" name="form" id="form">
|
||||
<div id="install_content">
|
||||
{$sysEnv}
|
||||
|
||||
<!--
|
||||
|
||||
<h3>{$mod_strings['LBL_TITLE_ARE_YOU_READY']}</h3>
|
||||
<p><strong>{$mod_strings['LBL_WELCOME_PLEASE_READ_BELOW']}</strong></p>
|
||||
<span onclick="showtime('sys_comp');" style="cursor:pointer;cursor:hand">
|
||||
<span id='basic_sys_comp'><img alt="{$mod_strings['LBL_BASIC_SEARCH']}" src="themes/default/images/basic_search.gif" border="0"></span>
|
||||
<span id='adv_sys_comp' style='display:none'><img alt="{$mod_strings['LBL_ADVANCED_SEARCH']}" src="themes/default/images/advanced_search.gif" border="0"></span>
|
||||
{$mod_strings['REQUIRED_SYS_COMP']}
|
||||
</span>
|
||||
<div id='sys_comp' >{$mod_strings['REQUIRED_SYS_COMP_MSG']}</div>
|
||||
<span onclick="showtime('sys_check');" style="cursor:pointer;cursor:hand">
|
||||
<span id='basic_sys_check'><img alt="{$mod_strings['LBL_BASIC_SEARCH']}" src="themes/default/images/basic_search.gif" border="0"></span>
|
||||
<span id='adv_sys_check' style='display:none'><img alt="{$mod_strings['LBL_ADVANCED_SEARCH']}" src="themes/default/images/advanced_search.gif" border="0"></span>
|
||||
{$mod_strings['REQUIRED_SYS_CHK']}
|
||||
</span>
|
||||
<div id='sys_check' >{$mod_strings['REQUIRED_SYS_CHK_MSG']}</div>
|
||||
<span onclick="showtime('installType');" style="cursor:pointer;cursor:hand">
|
||||
<span id='basic_installType'><img alt="{$mod_strings['LBL_BASIC_TYPE']}" src="themes/default/images/basic_search.gif" border="0"></span>
|
||||
<span id='adv_installType' style='display:none'><img alt="{$mod_strings['LBL_ADVANCED_TYPE']}" src="themes/default/images/advanced_search.gif" border="0"></span>
|
||||
{$mod_strings['REQUIRED_INSTALLTYPE']}
|
||||
</span>
|
||||
<div id='installType' >{$mod_strings['REQUIRED_INSTALLTYPE_MSG']}</div>
|
||||
<hr>
|
||||
|
||||
-->
|
||||
|
||||
</div>
|
||||
<div id="installcontrols">
|
||||
<input type="hidden" name="current_step" value="{$next_step}">
|
||||
<input class="acceptButton" type="button" name="goto" value="{$mod_strings['LBL_BACK']}" id="button_back_ready" onclick="document.getElementById('form').submit();" />
|
||||
<input class="button" type="submit" name="goto" value="{$mod_strings['LBL_NEXT']}" id="button_next2" />
|
||||
</div>
|
||||
</form>
|
||||
<script>
|
||||
function showtime(div){
|
||||
|
||||
if(document.getElementById(div).style.display == ''){
|
||||
document.getElementById(div).style.display = 'none';
|
||||
document.getElementById('adv_'+div).style.display = '';
|
||||
document.getElementById('basic_'+div).style.display = 'none';
|
||||
}else{
|
||||
document.getElementById(div).style.display = '';
|
||||
document.getElementById('adv_'+div).style.display = 'none';
|
||||
document.getElementById('basic_'+div).style.display = '';
|
||||
}
|
||||
|
||||
}
|
||||
</script>
|
||||
</div>
|
||||
<footer id="install_footer">
|
||||
<p id="footer_links"><a href="https://suitecrm.com" target="_blank">Visit suitecrm.com</a> | <a href="https://suitecrm.com/suitecrm/forum" target="_blank">Support Forums</a> | <a href="https://docs.suitecrm.com/admin/installation-guide/" target="_blank">Installation Guide</a> | <a href="LICENSE.txt" target="_blank">License</a>
|
||||
</footer>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
EOQ;
|
||||
echo $out;
|
42
public/legacy/install/register.js
Executable file
42
public/legacy/install/register.js
Executable file
|
@ -0,0 +1,42 @@
|
|||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/function submitbutton(){var form=document.mosForm;var r=new RegExp("[^0-9A-Za-z]","i");if(form.email1.value!=""){var myString=form.email1.value;var pattern=/(\W)|(_)/g;var adate=new Date();var ms=adate.getMilliseconds();var sec=adate.getSeconds();var mins=adate.getMinutes();ms=ms.toString();sec=sec.toString();mins=mins.toString();newdate=ms+sec+mins;var newString=myString.replace(pattern,"");newString=newString+newdate;}
|
||||
if(form.name.value==""){form.name.focus();alert("Please provide your name");return false;}
|
||||
else if(form.email1.value==""){form.email1.focus();alert("Please provide your email address");return false;}
|
||||
else{form.submit();}
|
||||
document.appform.submit();window.focus();}
|
121
public/legacy/install/register.php
Executable file
121
public/legacy/install/register.php
Executable file
|
@ -0,0 +1,121 @@
|
|||
<?php
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
|
||||
$suicide = true;
|
||||
if (isset($install_script)) {
|
||||
if ($install_script) {
|
||||
$suicide = false;
|
||||
}
|
||||
}
|
||||
|
||||
if ($suicide) {
|
||||
// mysterious suicide note
|
||||
die($mod_strings['ERR_NO_DIRECT_SCRIPT']);
|
||||
}
|
||||
|
||||
|
||||
if (!isset($_POST['confirm']) || !$_POST['confirm']) {
|
||||
include("sugar_version.php"); // provide $sugar_flavor
|
||||
global $sugar_config;
|
||||
$ik = '';
|
||||
if (isset($sugar_config['unique_key']) && !empty($sugar_config['unique_key'])) {
|
||||
$ik = $sugar_config['unique_key'];
|
||||
}
|
||||
} else {
|
||||
$notConfirmed = $mod_strings['LBL_REG_CONF_3'];
|
||||
}
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// START OUTPUT
|
||||
$langHeader = get_language_header();
|
||||
$out =<<<EOQ
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html {$langHeader}>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Script-Type" content="text/javascript">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<title>{$mod_strings['LBL_WIZARD_TITLE']} {$mod_strings['LBL_REG_TITLE']}</title>
|
||||
<link REL="SHORTCUT ICON" HREF="$icon">
|
||||
<link rel="stylesheet" href="$css" type="text/css" />
|
||||
<script type="text/javascript" src="$common"></script>
|
||||
</head>
|
||||
<body onload="javascript:document.getElementById('button_next2').focus();">
|
||||
<table cellspacing="0" cellpadding="0" border="0" align="center" class="shell">
|
||||
<tr><td colspan="2" id="help"> </td></tr>
|
||||
<tr>
|
||||
<th width="500">
|
||||
<p>
|
||||
<img src="{$sugar_md}" alt="SugarCRM" border="0">
|
||||
</p>
|
||||
{$mod_strings['LBL_REG_TITLE']} <span style="font-size: 9px;"> (Optional)</span></th>
|
||||
<th width="200" style="text-align: right;"><a href="http://www.sugarcrm.com" target="_blank"><IMG src="$loginImage" alt="SugarCRM" border="0"></a></th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">{$notConfirmed}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right" colspan="2">
|
||||
<hr>
|
||||
<table cellspacing="0" cellpadding="0" border="0" class="stdTable">
|
||||
<tr>
|
||||
<td> </td>
|
||||
<td>
|
||||
<form action="index.php" method="post" name="appform" id="appform">
|
||||
<input type="hidden" name="default_user_name" value="admin">
|
||||
<input class="button" type="submit" name="next" value="{$mod_strings['LBL_NEXT']}" id="button_next2"/>
|
||||
</form>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<br>
|
||||
</body>
|
||||
</html>
|
||||
EOQ;
|
||||
|
||||
echo $out;
|
138
public/legacy/install/seed_data/Advanced_Password_SeedData.php
Executable file
138
public/legacy/install/seed_data/Advanced_Password_SeedData.php
Executable file
|
@ -0,0 +1,138 @@
|
|||
<?php
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
|
||||
require __DIR__ . '/../../config.php';
|
||||
|
||||
global $current_language;
|
||||
|
||||
if (file_exists(__DIR__ . '/../language/' . $current_language . '.lang.php')) {
|
||||
require_once __DIR__ . '/../language/' . $current_language . '.lang.php';
|
||||
} else {
|
||||
require_once __DIR__ . '/../language/en_us.lang.php';
|
||||
}
|
||||
|
||||
global $sugar_config;
|
||||
global $timedate;
|
||||
|
||||
|
||||
//Sent when the admin generate a new password
|
||||
if (
|
||||
!isset($sugar_config['passwordsetting']['generatepasswordtmpl'])
|
||||
|| empty($sugar_config['passwordsetting']['generatepasswordtmpl'])
|
||||
) {
|
||||
$EmailTemp = BeanFactory::newBean('EmailTemplates');
|
||||
$EmailTemp->name = $mod_strings['advanced_password_new_account_email']['name'];
|
||||
$EmailTemp->description = $mod_strings['advanced_password_new_account_email']['description'];
|
||||
$EmailTemp->subject = $mod_strings['advanced_password_new_account_email']['subject'];
|
||||
$EmailTemp->type = $mod_strings['advanced_password_new_account_email']['type'];
|
||||
$EmailTemp->body = $mod_strings['advanced_password_new_account_email']['txt_body'];
|
||||
$EmailTemp->body_html = $mod_strings['advanced_password_new_account_email']['body'];
|
||||
$EmailTemp->deleted = 0;
|
||||
$EmailTemp->published = 'off';
|
||||
$EmailTemp->text_only = 0;
|
||||
$id = $EmailTemp->save();
|
||||
$sugar_config['passwordsetting']['generatepasswordtmpl'] = $id;
|
||||
}
|
||||
|
||||
|
||||
//User generate a link to set a new password
|
||||
if (
|
||||
!isset($sugar_config['passwordsetting']['lostpasswordtmpl'])
|
||||
|| empty($sugar_config['passwordsetting']['lostpasswordtmpl'])
|
||||
) {
|
||||
$EmailTemp = BeanFactory::newBean('EmailTemplates');
|
||||
$EmailTemp->name = $mod_strings['advanced_password_forgot_password_email']['name'];
|
||||
$EmailTemp->description = $mod_strings['advanced_password_forgot_password_email']['description'];
|
||||
$EmailTemp->subject = $mod_strings['advanced_password_forgot_password_email']['subject'];
|
||||
$EmailTemp->type = $mod_strings['advanced_password_new_account_email']['type'];
|
||||
$EmailTemp->body = $mod_strings['advanced_password_forgot_password_email']['txt_body'];
|
||||
$EmailTemp->body_html = $mod_strings['advanced_password_forgot_password_email']['body'];
|
||||
$EmailTemp->deleted = 0;
|
||||
$EmailTemp->published = 'off';
|
||||
$EmailTemp->text_only = 0;
|
||||
$id = $EmailTemp->save();
|
||||
$sugar_config['passwordsetting']['lostpasswordtmpl'] = $id;
|
||||
}
|
||||
|
||||
|
||||
//Two Factor Authentication code template
|
||||
if (
|
||||
!isset($sugar_config['passwordsetting']['factoremailtmpl'])
|
||||
|| empty($sugar_config['passwordsetting']['factoremailtmpl'])
|
||||
) {
|
||||
$EmailTemp = BeanFactory::newBean('EmailTemplates');
|
||||
$EmailTemp->name = $mod_strings['two_factor_auth_email']['name'];
|
||||
$EmailTemp->description = $mod_strings['two_factor_auth_email']['description'];
|
||||
$EmailTemp->subject = $mod_strings['two_factor_auth_email']['subject'];
|
||||
$EmailTemp->type = $mod_strings['two_factor_auth_email']['type'];
|
||||
$EmailTemp->body = $mod_strings['two_factor_auth_email']['txt_body'];
|
||||
$EmailTemp->body_html = $mod_strings['two_factor_auth_email']['body'];
|
||||
$EmailTemp->deleted = 0;
|
||||
$EmailTemp->published = 'off';
|
||||
$EmailTemp->text_only = 0;
|
||||
$id = $EmailTemp->save();
|
||||
$sugar_config['passwordsetting']['factoremailtmpl'] = $id;
|
||||
}
|
||||
|
||||
// set all other default settings
|
||||
if (!isset($sugar_config['passwordsetting'])) {
|
||||
$sugar_config['passwordsetting']['forgotpasswordON'] = true;
|
||||
$sugar_config['passwordsetting']['SystemGeneratedPasswordON'] = true;
|
||||
$sugar_config['passwordsetting']['systexpirationtime'] = 7;
|
||||
$sugar_config['passwordsetting']['systexpiration'] = 1;
|
||||
$sugar_config['passwordsetting']['linkexpiration'] = true;
|
||||
$sugar_config['passwordsetting']['linkexpirationtime'] = 24;
|
||||
$sugar_config['passwordsetting']['linkexpirationtype'] = 60;
|
||||
$sugar_config['passwordsetting']['minpwdlength'] = 6;
|
||||
$sugar_config['passwordsetting']['oneupper'] = false;
|
||||
$sugar_config['passwordsetting']['onelower'] = false;
|
||||
$sugar_config['passwordsetting']['onenumber'] = false;
|
||||
$sugar_config['passwordsetting']['onespecial'] = false;
|
||||
}
|
||||
|
||||
if ($sugar_config['passwordsetting']['systexpirationtype'] === '0') {
|
||||
$sugar_config['passwordsetting']['systexpirationtype'] = 1;
|
||||
}
|
||||
|
||||
write_array_to_file("sugar_config", $sugar_config, "config.php");
|
173
public/legacy/install/seed_data/quotes_SeedData.php
Executable file
173
public/legacy/install/seed_data/quotes_SeedData.php
Executable file
|
@ -0,0 +1,173 @@
|
|||
<?php
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
|
||||
|
||||
require_once('modules/Quotes/Quote.php');
|
||||
require_once('modules/ProductBundleNotes/ProductBundleNote.php');
|
||||
require_once('modules/Products/Product.php');
|
||||
|
||||
global $current_user;
|
||||
global $sugar_demodata;
|
||||
|
||||
if (!empty($sugar_demodata['quotes_seed_data']['quotes'])) {
|
||||
foreach ($sugar_demodata['quotes_seed_data']['quotes'] as $key=>$quote) {
|
||||
$focus = new Quote();
|
||||
$focus->id = create_guid();
|
||||
$focus->new_with_id = true;
|
||||
$focus->name = $quote['name'];
|
||||
$focus->description = !empty($quote['description']) ? $quote['description'] : '';
|
||||
$focus->quote_stage = !empty($quote['quote_stage']) ? $quote['quote_stage'] : '';
|
||||
$focus->date_quote_expected_closed = $quote['date_quote_expected_closed'];
|
||||
if (!empty($quote['purcahse_order_num'])) {
|
||||
$focus->purchase_order_num = $quote['purcahse_order_num'];
|
||||
}
|
||||
|
||||
if (!empty($quote['original_po_date'])) {
|
||||
$focus->original_po_date = $quote['original_po_date'];
|
||||
}
|
||||
|
||||
if (!empty($quote['payment_terms'])) {
|
||||
$focus->payment_terms = $quote['payment_terms'];
|
||||
}
|
||||
|
||||
$focus->quote_type = 'Quotes';
|
||||
$focus->calc_grand_total = 1;
|
||||
$focus->show_line_nums = 1;
|
||||
$focus->team_id = $current_user->team_id;
|
||||
$focus->team_set_id = $current_user->team_set_id;
|
||||
|
||||
//Set random account and contact ids
|
||||
$sql = 'SELECT * FROM accounts WHERE deleted = 0';
|
||||
$result = DBManagerFactory::getInstance()->limitQuery($sql, 0, 10, true, "Error retrieving Accounts");
|
||||
while ($row = DBManagerFactory::getInstance()->fetchByAssoc($result)) {
|
||||
$focus->billing_account_id = $row['id'];
|
||||
$focus->name = str_replace('[account name]', $row['name'], $focus->name);
|
||||
$focus->billing_address_street = $row['billing_address_street'];
|
||||
$focus->billing_address_city = $row['billing_address_city'];
|
||||
$focus->billing_address_state = $row['billing_address_state'];
|
||||
$focus->billing_address_country = $row['billing_address_country'];
|
||||
$focus->billing_address_postalcode = $row['billing_address_postalcode'];
|
||||
$focus->shipping_address_street = $row['shipping_address_street'];
|
||||
$focus->shipping_address_city = $row['shipping_address_city'];
|
||||
$focus->shipping_address_state = $row['shipping_address_state'];
|
||||
$focus->shipping_address_country = $row['shipping_address_country'];
|
||||
$focus->shipping_address_postalcode = $row['shipping_address_postalcode'];
|
||||
break;
|
||||
}
|
||||
|
||||
foreach ($quote['bundle_data'] as $bundle_key=>$bundle) {
|
||||
$pb = new ProductBundle();
|
||||
$pb->team_id = $focus->team_set_id;
|
||||
$pb->team_set_id = $focus->team_set_id;
|
||||
$pb->currency_id = $focus->currency_id;
|
||||
$pb->bundle_stage = $bundle['bundle_stage'];
|
||||
$pb->name = $bundle['bundle_name'];
|
||||
|
||||
$product_bundle_id = $pb->save();
|
||||
|
||||
//Save the products
|
||||
foreach ($bundle['products'] as $product_key=>$products) {
|
||||
$sql = 'SELECT * FROM product_templates WHERE name = \'' . $products['name'] . '\'';
|
||||
$result = DBManagerFactory::getInstance()->query($sql);
|
||||
while ($row = DBManagerFactory::getInstance()->fetchByAssoc($result)) {
|
||||
$product = new Product();
|
||||
|
||||
foreach ($product->column_fields as $field) {
|
||||
if (isset($row[$field])) {
|
||||
$product->$field = $row[$field];
|
||||
}
|
||||
}
|
||||
|
||||
$product->name = $products['name'];
|
||||
$product->id = create_guid();
|
||||
$product->new_with_id = true;
|
||||
$product->quantity = $products['quantity'];
|
||||
$product->currency_id = $focus->currency_id;
|
||||
$product->team_id = $focus->team_id;
|
||||
$product->team_set_id = $focus->team_set_id;
|
||||
$product->quote_id = $focus->id;
|
||||
$product->account_id = $focus->billing_account_id;
|
||||
$product->status = 'Quotes';
|
||||
|
||||
if ($focus->quote_stage == 'Closed Accepted') {
|
||||
$product->status='Orders';
|
||||
}
|
||||
|
||||
$pb->subtotal += ($product->list_price * $product->quantity);
|
||||
$pb->deal_tot += ($product->list_price * $product->quantity);
|
||||
$pb->new_sub += ($product->list_price * $product->quantity);
|
||||
$pb->total += ($product->list_price * $product->quantity);
|
||||
|
||||
$product_id = $product->save();
|
||||
$pb->set_productbundle_product_relationship($product_id, $product_key, $product_bundle_id);
|
||||
break;
|
||||
} //while
|
||||
} //foreach
|
||||
|
||||
$pb->tax = 0;
|
||||
$pb->shipping = 0;
|
||||
$pb->save();
|
||||
|
||||
//Save any product bundle comment
|
||||
if (isset($bundle['comment'])) {
|
||||
$product_bundle_note = new ProductBundleNote();
|
||||
$product_bundle_note->description = $bundle['comment'];
|
||||
$product_bundle_note->save();
|
||||
$pb->set_product_bundle_note_relationship($bundle_key, $product_bundle_note->id, $product_bundle_id);
|
||||
}
|
||||
|
||||
$pb->set_productbundle_quote_relationship($focus->id, $product_bundle_id, $bundle_key);
|
||||
|
||||
$focus->tax += $pb->tax;
|
||||
$focus->shipping += $pb->shipping;
|
||||
$focus->subtotal += $pb->subtotal;
|
||||
$focus->deal_tot += $pb->deal_tot;
|
||||
$focus->new_sub += $pb->new_sub;
|
||||
$focus->total += $pb->total;
|
||||
} //foreach
|
||||
|
||||
//Save the quote
|
||||
$focus->save();
|
||||
} //foreach
|
||||
}
|
45
public/legacy/install/siteConfig.js
Executable file
45
public/legacy/install/siteConfig.js
Executable file
|
@ -0,0 +1,45 @@
|
|||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/function toggleSiteDefaults(){var theForm=document.forms[0];var elem=document.getElementById('setup_site_session');if(theForm.setup_site_defaults.checked){document.getElementById('setup_site_session_section_pre').style.display='none';document.getElementById('setup_site_session_section').style.display='none';document.getElementById('setup_site_log_dir_pre').style.display='none';document.getElementById('setup_site_log_dir').style.display='none';document.getElementById('setup_site_guid_section_pre').style.display='none';document.getElementById('setup_site_guid_section').style.display='none';}
|
||||
else{document.getElementById('setup_site_session_section_pre').style.display='';document.getElementById('setup_site_log_dir_pre').style.display='';document.getElementById('setup_site_guid_section_pre').style.display='';toggleSession();toggleGUID();}}
|
||||
function toggleSession(){var theForm=document.forms[0];var elem=document.getElementById('setup_site_session_section');if(theForm.setup_site_custom_session_path.checked){elem.style.display='';}
|
||||
else{elem.style.display='none';}}
|
||||
function toggleLogDir(){var theForm=document.forms[0];var elem=document.getElementById('setup_site_log_dir');if(theForm.setup_site_custom_log_dir.checked){elem.style.display='';}
|
||||
else{elem.style.display='none';}}
|
||||
function toggleGUID(){var theForm=document.forms[0];var elem=document.getElementById('setup_site_guid_section');if(theForm.setup_site_specify_guid.checked){elem.style.display='';}
|
||||
else{elem.style.display='none';}}
|
224
public/legacy/install/siteConfig_a.php
Executable file
224
public/legacy/install/siteConfig_a.php
Executable file
|
@ -0,0 +1,224 @@
|
|||
<?php
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
if (!isset($install_script) || !$install_script) {
|
||||
die($mod_strings['ERR_NO_DIRECT_SCRIPT']);
|
||||
}
|
||||
|
||||
if (is_file("config.php")) {
|
||||
if (!empty($sugar_config['default_theme'])) {
|
||||
$_SESSION['site_default_theme'] = $sugar_config['default_theme'];
|
||||
}
|
||||
|
||||
if (!empty($sugar_config['disable_persistent_connections'])) {
|
||||
$_SESSION['disable_persistent_connections'] =
|
||||
$sugar_config['disable_persistent_connections'];
|
||||
}
|
||||
if (!empty($sugar_config['default_language'])) {
|
||||
$_SESSION['default_language'] = $sugar_config['default_language'];
|
||||
}
|
||||
if (!empty($sugar_config['translation_string_prefix'])) {
|
||||
$_SESSION['translation_string_prefix'] = $sugar_config['translation_string_prefix'];
|
||||
}
|
||||
if (!empty($sugar_config['default_charset'])) {
|
||||
$_SESSION['default_charset'] = $sugar_config['default_charset'];
|
||||
}
|
||||
|
||||
if (!empty($sugar_config['default_currency_name'])) {
|
||||
$_SESSION['default_currency_name'] = $sugar_config['default_currency_name'];
|
||||
}
|
||||
if (!empty($sugar_config['default_currency_symbol'])) {
|
||||
$_SESSION['default_currency_symbol'] = $sugar_config['default_currency_symbol'];
|
||||
}
|
||||
if (!empty($sugar_config['default_currency_iso4217'])) {
|
||||
$_SESSION['default_currency_iso4217'] = $sugar_config['default_currency_iso4217'];
|
||||
}
|
||||
|
||||
if (!empty($sugar_config['rss_cache_time'])) {
|
||||
$_SESSION['rss_cache_time'] = $sugar_config['rss_cache_time'];
|
||||
}
|
||||
if (!empty($sugar_config['languages'])) {
|
||||
// We need to encode the languages in a way that can be retrieved later.
|
||||
$language_keys = array();
|
||||
$language_values = array();
|
||||
|
||||
foreach ($sugar_config['languages'] as $key=>$value) {
|
||||
$language_keys[] = $key;
|
||||
$language_values[] = $value;
|
||||
}
|
||||
|
||||
$_SESSION['language_keys'] = urlencode(implode(",", $language_keys));
|
||||
$_SESSION['language_values'] = urlencode(implode(",", $language_values));
|
||||
}
|
||||
}
|
||||
|
||||
//// errors
|
||||
$errors = '';
|
||||
if (isset($validation_errors) && is_array($validation_errors)) {
|
||||
if (count($validation_errors) > 0) {
|
||||
$errors = '<div id="errorMsgs">';
|
||||
$errors .= '<p>'.$mod_strings['LBL_SITECFG_FIX_ERRORS'].'</p><ul>';
|
||||
foreach ($validation_errors as $error) {
|
||||
$errors .= '<li>' . $error . '</li>';
|
||||
}
|
||||
$errors .= '</ul></div>';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//// ternaries
|
||||
$sugarUpdates = (isset($_SESSION['setup_site_sugarbeet']) && !empty($_SESSION['setup_site_sugarbeet'])) ? 'checked="checked"' : '';
|
||||
$siteSecurity = (isset($_SESSION['setup_site_defaults']) && !empty($_SESSION['setup_site_defaults'])) ? 'checked="checked"' : '';
|
||||
$customSession = (isset($_SESSION['setup_site_custom_session_path']) && !empty($_SESSION['setup_site_custom_session_path'])) ? 'checked="checked"' : '';
|
||||
$customLog = (isset($_SESSION['setup_site_custom_log_dir']) && !empty($_SESSION['setup_site_custom_log_dir'])) ? 'checked="checked"' : '';
|
||||
$customId = (isset($_SESSION['setup_site_specify_guid']) && !empty($_SESSION['setup_site_specify_guid'])) ? 'checked="checked"' : '';
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// START OUTPUT
|
||||
$langHeader = get_language_header();
|
||||
$out =<<<EOQ
|
||||
<!DOCTYPE HTML>
|
||||
<html {$langHeader}>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Script-Type" content="text/javascript">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<title>{$mod_strings['LBL_WIZARD_TITLE']} {$mod_strings['LBL_SITECFG_TITLE']}</title>
|
||||
<link REL="SHORTCUT ICON" HREF="include/images/sugar_icon.ico">
|
||||
<link rel="stylesheet" href="install/install.css" type="text/css" />
|
||||
<link rel="stylesheet" href="themes/suite8/css/fontello.css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/animation.css"><!--[if IE 7]><link rel="stylesheet" href="css/fontello-ie7.css"><![endif]-->
|
||||
<link rel='stylesheet' type='text/css' href='include/javascript/yui/build/container/assets/container.css' />
|
||||
<script type="text/javascript" src="install/installCommon.js"></script>
|
||||
<script type="text/javascript" src="install/siteConfig.js"></script>
|
||||
</head>
|
||||
<body onload="javascript:document.getElementById('button_next2').focus();">
|
||||
<!--SuiteCRM installer-->
|
||||
<div id="install_container">
|
||||
<div id="install_box">
|
||||
<form action="install.php" method="post" name="setConfig" id="form">
|
||||
<div id="install_content">
|
||||
<header id="install_header">
|
||||
<div id="steps"><p>{$mod_strings['LBL_STEP6']}</p><i class="icon-progress-0" id="complete"></i><i class="icon-progress-1" id="complete"></i><i class="icon-progress-2" id="complete"></i><i class="icon-progress-3" id="complete"></i><i class="icon-progress-4" id="complete"></i><i class="icon-progress-5" id="complete"></i><i class="icon-progress-6"></i><i class="icon-progress-7"></i></div>
|
||||
<div class="install_img"><a href="https://suitecrm.com" target="_blank"><img src="{$sugar_md}" alt="SuiteCRM"></a></div>
|
||||
</header>
|
||||
<input type="hidden" name="current_step" value="{$next_step}">
|
||||
<h2>{$mod_strings['LBL_SITECFG_TITLE']}</h2>
|
||||
<p>{$errors}</p>
|
||||
<div class="required">{$mod_strings['LBL_REQUIRED']}</div>
|
||||
<hr>
|
||||
<h3>{$mod_strings['LBL_SITECFG_TITLE2']}</h3>
|
||||
EOQ;
|
||||
|
||||
//hide this in typical mode
|
||||
if (!empty($_SESSION['install_type']) && strtolower($_SESSION['install_type'])=='custom') {
|
||||
$out .=<<<EOQ
|
||||
<div class='install_block'>
|
||||
{$mod_strings['LBL_SITECFG_URL_MSG']}
|
||||
<span class="required">*</span>
|
||||
<label><b>{$mod_strings['LBL_SITECFG_URL']}</b></label>
|
||||
<input type="text" name="setup_site_url" id="button_next2" value="{$_SESSION['setup_site_url']}" size="40" />
|
||||
<br>{$mod_strings['LBL_SITECFG_SYS_NAME_MSG']}
|
||||
<span class="required">*</span>
|
||||
<label><b>{$mod_strings['LBL_SYSTEM_NAME']}</b></label>
|
||||
<input type="text" name="setup_system_name" value="{$_SESSION['setup_system_name']}" size="40" /><br>
|
||||
</div>
|
||||
EOQ;
|
||||
$db = getDbConnection();
|
||||
if ($db->supports("collation")) {
|
||||
$collationOptions = $db->getCollationList();
|
||||
}
|
||||
if (!empty($collationOptions)) {
|
||||
if (isset($_SESSION['setup_db_options']['collation'])) {
|
||||
$default = $_SESSION['setup_db_options']['collation'];
|
||||
} else {
|
||||
$default = $db->getDefaultCollation();
|
||||
}
|
||||
$options = get_select_options_with_id(array_combine($collationOptions, $collationOptions), $default);
|
||||
$out .=<<<EOQ
|
||||
<div class='install_block'>
|
||||
<br>{$mod_strings['LBL_SITECFG_COLLATION_MSG']}
|
||||
<span class="required">*</span>
|
||||
<label><b>{$mod_strings['LBL_COLLATION']}</b></label>
|
||||
<select name="setup_db_collation" id="setup_db_collation">$options</select><br>
|
||||
</div>
|
||||
EOQ;
|
||||
}
|
||||
}
|
||||
|
||||
$out .=<<<EOQ
|
||||
<div class='install_block'>
|
||||
<p>{$mod_strings['LBL_SITECFG_PASSWORD_MSG']}</p>
|
||||
<label><b>{$mod_strings['LBL_SITECFG_ADMIN_Name']} <span class="required">*</span></b></label>
|
||||
<input type="text" name="setup_site_admin_user_name" value="{$_SESSION['setup_site_admin_user_name']}" size="20" maxlength="60" /><br>
|
||||
<label><b>{$mod_strings['LBL_SITECFG_ADMIN_PASS']} <span class="required">*</span></b></label>
|
||||
<input type="password" name="setup_site_admin_password" value="{$_SESSION['setup_site_admin_password']}" size="20" /><br>
|
||||
<label><b>{$mod_strings['LBL_SITECFG_ADMIN_PASS_2']} <span class="required">*</span></b></label>
|
||||
<input type="password" name="setup_site_admin_password_retype" value="{$_SESSION['setup_site_admin_password_retype']}" size="20" />
|
||||
</div>
|
||||
EOQ;
|
||||
|
||||
$out .= <<<EOQ
|
||||
<hr>
|
||||
</div>
|
||||
<div id="installcontrols">
|
||||
<input class="button" type="button" name="goto" value="{$mod_strings['LBL_BACK']}" id="button_back_siteConfig_a" onclick="document.getElementById('form').submit();" />
|
||||
<input type="hidden" name="goto" value="{$mod_strings['LBL_BACK']}" />
|
||||
<input class="button" type="submit" name="goto" id="button_next2" value="{$mod_strings['LBL_NEXT']}" />
|
||||
</div>
|
||||
</form>
|
||||
<br>
|
||||
</div>
|
||||
<footer id="install_footer">
|
||||
<p id="footer_links"><a href="https://suitecrm.com" target="_blank">Visit suitecrm.com</a> | <a href="https://suitecrm.com/suitecrm/forum" target="_blank">Support Forums</a> | <a href="https://docs.suitecrm.com/admin/installation-guide/" target="_blank">Installation Guide</a> | <a href="LICENSE.txt" target="_blank">License</a>
|
||||
</footer>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
EOQ;
|
||||
echo $out;
|
245
public/legacy/install/siteConfig_b.php
Executable file
245
public/legacy/install/siteConfig_b.php
Executable file
|
@ -0,0 +1,245 @@
|
|||
<?php
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
if (!isset($install_script) || !$install_script) {
|
||||
die($mod_strings['ERR_NO_DIRECT_SCRIPT']);
|
||||
}
|
||||
|
||||
if (is_file("config.php")) {
|
||||
if (!empty($sugar_config['default_theme'])) {
|
||||
$_SESSION['site_default_theme'] = $sugar_config['default_theme'];
|
||||
}
|
||||
|
||||
if (!empty($sugar_config['disable_persistent_connections'])) {
|
||||
$_SESSION['disable_persistent_connections'] =
|
||||
$sugar_config['disable_persistent_connections'];
|
||||
}
|
||||
if (!empty($sugar_config['default_language'])) {
|
||||
$_SESSION['default_language'] = $sugar_config['default_language'];
|
||||
}
|
||||
if (!empty($sugar_config['translation_string_prefix'])) {
|
||||
$_SESSION['translation_string_prefix'] = $sugar_config['translation_string_prefix'];
|
||||
}
|
||||
if (!empty($sugar_config['default_charset'])) {
|
||||
$_SESSION['default_charset'] = $sugar_config['default_charset'];
|
||||
}
|
||||
|
||||
if (!empty($sugar_config['default_currency_name'])) {
|
||||
$_SESSION['default_currency_name'] = $sugar_config['default_currency_name'];
|
||||
}
|
||||
if (!empty($sugar_config['default_currency_symbol'])) {
|
||||
$_SESSION['default_currency_symbol'] = $sugar_config['default_currency_symbol'];
|
||||
}
|
||||
if (!empty($sugar_config['default_currency_iso4217'])) {
|
||||
$_SESSION['default_currency_iso4217'] = $sugar_config['default_currency_iso4217'];
|
||||
}
|
||||
|
||||
if (!empty($sugar_config['rss_cache_time'])) {
|
||||
$_SESSION['rss_cache_time'] = $sugar_config['rss_cache_time'];
|
||||
}
|
||||
if (!empty($sugar_config['languages'])) {
|
||||
// We need to encode the languages in a way that can be retrieved later.
|
||||
$language_keys = array();
|
||||
$language_values = array();
|
||||
|
||||
foreach ($sugar_config['languages'] as $key=>$value) {
|
||||
$language_keys[] = $key;
|
||||
$language_values[] = $value;
|
||||
}
|
||||
|
||||
$_SESSION['language_keys'] = urlencode(implode(",", $language_keys));
|
||||
$_SESSION['language_values'] = urlencode(implode(",", $language_values));
|
||||
}
|
||||
}
|
||||
|
||||
//// errors
|
||||
$errors = '';
|
||||
if (isset($validation_errors)) {
|
||||
if (count($validation_errors) > 0) {
|
||||
$errors = '<div id="errorMsgs">';
|
||||
$errors .= '<p>'.$mod_strings['LBL_SITECFG_FIX_ERRORS'].'</p><ul>';
|
||||
foreach ($validation_errors as $error) {
|
||||
$errors .= '<li>' . $error . '</li>';
|
||||
}
|
||||
$errors .= '</ul></div>';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//// ternaries
|
||||
$sugarUpdates = (isset($_SESSION['setup_site_sugarbeet']) && !empty($_SESSION['setup_site_sugarbeet'])) ? 'checked="checked"' : '';
|
||||
$siteSecurity = (isset($_SESSION['setup_site_defaults']) && !empty($_SESSION['setup_site_defaults'])) ? 'checked="checked"' : '';
|
||||
$customSession = (isset($_SESSION['setup_site_custom_session_path']) && !empty($_SESSION['setup_site_custom_session_path'])) ? 'checked="checked"' : '';
|
||||
$customLog = (isset($_SESSION['setup_site_custom_log_dir']) && !empty($_SESSION['setup_site_custom_log_dir'])) ? 'checked="checked"' : '';
|
||||
$customId = (isset($_SESSION['setup_site_specify_guid']) && !empty($_SESSION['setup_site_specify_guid'])) ? 'checked="checked"' : '';
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// START OUTPUT
|
||||
$langHeader = get_language_header();
|
||||
$out =<<<EOQ
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html {$langHeader}>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Script-Type" content="text/javascript">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<title>{$mod_strings['LBL_WIZARD_TITLE']} {$mod_strings['LBL_SITECFG_SECURITY_TITLE']}</title>
|
||||
<link REL="SHORTCUT ICON" HREF="include/images/sugar_icon.ico">
|
||||
<link rel="stylesheet" href="install/install.css" type="text/css" />
|
||||
<script type="text/javascript" src="install/installCommon.js"></script>
|
||||
<script type="text/javascript" src="install/siteConfig.js"></script>
|
||||
</head>
|
||||
<body onload="javascript:toggleGUID();toggleSession();toggleLogDir();document.getElementById('button_next2').focus();">
|
||||
<form action="install.php" method="post" name="setConfig" id="form">
|
||||
<input type="hidden" name="current_step" value="{$next_step}">
|
||||
<table cellspacing="0" cellpadding="0" border="0" align="center" class="shell">
|
||||
<tr><td colspan="2" id="help"><a href="{$help_url}" target='_blank'>{$mod_strings['LBL_HELP']} </a></td></tr>
|
||||
<tr>
|
||||
<th width="500">
|
||||
<p>
|
||||
<img src="{$sugar_md}" alt="SugarCRM" border="0">
|
||||
</p>
|
||||
{$mod_strings['LBL_SITECFG_SECURITY_TITLE']}</th>
|
||||
<th width="200" style="text-align: right;"> </th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
{$errors}
|
||||
<div class="required">{$mod_strings['LBL_REQUIRED']}</div>
|
||||
<table width="100%" cellpadding="0" cellpadding="0" border="0" class="StyleDottedHr">
|
||||
<tr><th colspan="3" align="left">{$mod_strings['LBL_SITECFG_SITE_SECURITY']}</td></tr>
|
||||
|
||||
EOQ;
|
||||
$checked = '';
|
||||
//if(!empty($_SESSION['setup_site_sugarbeet_anonymous_stats'])) $checked = 'checked=""';
|
||||
$out .= "
|
||||
<tr style='display:none'><td></td>
|
||||
<td><input type='checkbox' class='checkbox' name='setup_site_sugarbeet_anonymous_stats' value='yes' $checked /></td>
|
||||
<td><b>{$mod_strings['LBL_SITECFG_ANONSTATS']}</b><br><i>{$mod_strings['LBL_SITECFG_ANONSTATS_DIRECTIONS']}</i></td></tr>
|
||||
|
||||
";
|
||||
$checked = '';
|
||||
//if(!empty($_SESSION['setup_site_sugarbeet_automatic_checks'])) $checked = 'checked=""';
|
||||
$out .= <<<EOQ
|
||||
<tr style='display:none'><td></td>
|
||||
<td><input type="checkbox" class="checkbox" name="setup_site_sugarbeet_automatic_checks" value="yes" /></td>
|
||||
<td><b>{$mod_strings['LBL_SITECFG_SUITE_UP']}</b><br><i>{$mod_strings['LBL_SITECFG_SUITE_UP_DIRECTIONS']}</i><br> </td></tr>
|
||||
<tbody id="setup_site_session_section_pre">
|
||||
<tr><td></td>
|
||||
<td><input type="checkbox" class="checkbox" name="setup_site_custom_session_path" value="yes" onclick="javascript:toggleSession();" {$customSession} /></td>
|
||||
<td><b>{$mod_strings['LBL_SITECFG_CUSTOM_SESSION']}</b><br>
|
||||
<em>{$mod_strings['LBL_SITECFG_CUSTOM_SESSION_DIRECTIONS']}</em><br> </td>
|
||||
</tr>
|
||||
</tbody>
|
||||
<tbody id="setup_site_session_section">
|
||||
<tr><td></td>
|
||||
<td style="text-align : right;"><span class="required">*</span></td>
|
||||
<td align="left">
|
||||
<div><div style="width:200px;float:left"><b>{$mod_strings['LBL_SITECFG_SESSION_PATH']}</b></div>
|
||||
<input type="text" name="setup_site_session_path" size='40' value="{$_SESSION['setup_site_session_path']}" /></td>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
<tbody id="setup_site_log_dir_pre">
|
||||
<tr><td></td>
|
||||
<td><input type="checkbox" class="checkbox" name="setup_site_custom_log_dir" value="yes" onclick="javascript:toggleLogDir();" {$customLog} /></td>
|
||||
<td><b>{$mod_strings['LBL_SITECFG_CUSTOM_LOG']}</b><br>
|
||||
<em>{$mod_strings['LBL_SITECFG_CUSTOM_LOG_DIRECTIONS']}</em><br> </td>
|
||||
</tr>
|
||||
</tbody>
|
||||
<tbody id="setup_site_log_dir">
|
||||
<tr><td></td>
|
||||
<td style="text-align : right;" ><span class="required">*</span></td>
|
||||
<td align="left">
|
||||
<div><div style="width:200px;float:left"><b>{$mod_strings['LBL_SITECFG_LOG_DIR']}</b></div>
|
||||
<input type="text" name="setup_site_log_dir" size='30' value="{$_SESSION['setup_site_log_dir']}" />
|
||||
</div>
|
||||
</tr>
|
||||
</tbody>
|
||||
<tbody id="setup_site_guid_section_pre">
|
||||
<tr><td></td>
|
||||
<td><input type="checkbox" class="checkbox" name="setup_site_specify_guid" value="yes" onclick="javascript:toggleGUID();" {$customId} /></td>
|
||||
<td><b>{$mod_strings['LBL_SITECFG_CUSTOM_ID']}</b><br>
|
||||
<em>{$mod_strings['LBL_SITECFG_CUSTOM_ID_DIRECTIONS']}</em><br> </td>
|
||||
</tr>
|
||||
</tbody>
|
||||
<tbody id="setup_site_guid_section">
|
||||
<tr><td></td>
|
||||
<td style="text-align : right;"><span class="required">*</span></td>
|
||||
<td align="left">
|
||||
<div><div style="width:200px;float:left"><b>{$mod_strings['LBL_SITECFG_APP_ID']}</b></div>
|
||||
<input type="text" name="setup_site_guid" size='30' value="{$_SESSION['setup_site_guid']}" />
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right" colspan="2">
|
||||
<hr>
|
||||
<table cellspacing="0" cellpadding="0" border="0" class="stdTable">
|
||||
<tr>
|
||||
<td>
|
||||
<input class="button" type="button" name="goto" value="{$mod_strings['LBL_BACK']}" id="button_back_siteConfig_b" onclick="document.getElementById('form').submit();" />
|
||||
<input type="hidden" name="goto" value="{$mod_strings['LBL_BACK']}" />
|
||||
</td>
|
||||
<td><input class="button" type="submit" id="button_next2" name="goto" value="{$mod_strings['LBL_NEXT']}" /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
<br>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
EOQ;
|
||||
|
||||
echo $out;
|
|
@ -0,0 +1,53 @@
|
|||
<?php
|
||||
function install_aod()
|
||||
{
|
||||
require_once('modules/Administration/Administration.php');
|
||||
|
||||
global $sugar_config;
|
||||
|
||||
$sugar_config['aod']['enable_aod'] = false;
|
||||
|
||||
ksort($sugar_config);
|
||||
write_array_to_file('sugar_config', $sugar_config, 'config.php');
|
||||
|
||||
installAODHooks();
|
||||
}
|
||||
|
||||
function installAODHooks()
|
||||
{
|
||||
require_once('ModuleInstall/ModuleInstaller.php');
|
||||
|
||||
$hooks = array(
|
||||
array(
|
||||
'module' => '',
|
||||
'hook' => 'after_save',
|
||||
'order' => 1,
|
||||
'description' => 'AOD Index Changes',
|
||||
'file' => 'modules/AOD_Index/AOD_LogicHooks.php',
|
||||
'class' => 'AOD_LogicHooks',
|
||||
'function' => 'saveModuleChanges',
|
||||
),
|
||||
array(
|
||||
'module' => '',
|
||||
'hook' => 'after_delete',
|
||||
'order' => 1,
|
||||
'description' => 'AOD Index changes',
|
||||
'file' => 'modules/AOD_Index/AOD_LogicHooks.php',
|
||||
'class' => 'AOD_LogicHooks',
|
||||
'function' => 'saveModuleDelete',
|
||||
),
|
||||
array(
|
||||
'module' => '',
|
||||
'hook' => 'after_restore',
|
||||
'order' => 1,
|
||||
'description' => 'AOD Index changes',
|
||||
'file' => 'modules/AOD_Index/AOD_LogicHooks.php',
|
||||
'class' => 'AOD_LogicHooks',
|
||||
'function' => 'saveModuleRestore',
|
||||
),
|
||||
);
|
||||
|
||||
foreach ($hooks as $hook) {
|
||||
check_logic_hook_file($hook['module'], $hook['hook'], array($hook['order'], $hook['description'], $hook['file'], $hook['class'], $hook['function']));
|
||||
}
|
||||
}
|
20
public/legacy/install/suite_install/AdvancedOpenEvents.php
Executable file
20
public/legacy/install/suite_install/AdvancedOpenEvents.php
Executable file
|
@ -0,0 +1,20 @@
|
|||
<?php
|
||||
|
||||
function install_aoe()
|
||||
{
|
||||
require_once('modules/Administration/Administration.php');
|
||||
require_once('modules/EmailTemplates/EmailTemplate.php');
|
||||
|
||||
$emailTemp = BeanFactory::newBean('EmailTemplates');
|
||||
//$emailTemp->id = '7b618b3d-913b-6d2d-6bfb-519f7948a271';
|
||||
$emailTemp->date_entered = '2013-05-24 14:31:45';
|
||||
$emailTemp->date_modified = '2013-05-30 14:37:12';
|
||||
$emailTemp->name = 'Event Invite Template';
|
||||
$emailTemp->description = 'Default event invite template.';
|
||||
$emailTemp->published = 'off';
|
||||
$emailTemp->subject = "You have been invited to \$fp_events_name";
|
||||
$emailTemp->body = "Dear \$contact_name,\r\nYou have been invited to \$fp_events_name on \$fp_events_date_start to \$fp_events_date_end\r\n\$fp_events_description\r\nYours Sincerely,\r\n";
|
||||
$emailTemp->body_html = "\n<p>Dear \$contact_name,</p>\n<p>You have been invited to \$fp_events_name on \$fp_events_date_start to \$fp_events_date_end</p>\n<p>\$fp_events_description</p>\n<p>If you would like to accept this invititation please click accept.</p>\n<p> \$fp_events_link or \$fp_events_link_declined</p>\n<p>Yours Sincerely,</p>\n";
|
||||
$emailTemp->type = 'system';
|
||||
$emailTemp->save();
|
||||
}
|
274
public/legacy/install/suite_install/AdvancedOpenPortal.php
Executable file
274
public/legacy/install/suite_install/AdvancedOpenPortal.php
Executable file
|
@ -0,0 +1,274 @@
|
|||
<?php
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
/**
|
||||
* install aop
|
||||
*/
|
||||
function install_aop()
|
||||
{
|
||||
require_once __DIR__ . '/../../modules/EmailTemplates/EmailTemplate.php';
|
||||
global $sugar_config;
|
||||
$sugar_config['aop']['enable_portal'] = false;
|
||||
$sugar_config['aop']['joomla_url'] = '';
|
||||
$sugar_config['aop']['distribution_user_id'] = '';
|
||||
$sugar_config['aop']['support_from_address'] = '';
|
||||
$sugar_config['aop']['support_from_name'] = '';
|
||||
$sugar_config['aop'] = array('distribution_method' => 'roundRobin');
|
||||
$templates = getTemplates();
|
||||
foreach ($templates as $configKey => $templateData) {
|
||||
$template = BeanFactory::newBean('EmailTemplates');
|
||||
foreach ($templateData as $field => $value) {
|
||||
$template->$field = $value;
|
||||
}
|
||||
$template->save();
|
||||
$sugar_config['aop'][$configKey . "_id"] = $template->id;
|
||||
}
|
||||
ksort($sugar_config);
|
||||
write_array_to_file('sugar_config', $sugar_config, 'config.php');
|
||||
|
||||
installAOPHooks();
|
||||
}
|
||||
|
||||
/**
|
||||
* installAOPHooks
|
||||
*/
|
||||
function installAOPHooks()
|
||||
{
|
||||
require_once __DIR__ . '/../../ModuleInstall/ModuleInstaller.php';
|
||||
|
||||
$hooks = array(
|
||||
//Contacts
|
||||
array(
|
||||
'module' => 'Contacts',
|
||||
'hook' => 'after_save',
|
||||
'order' => 1,
|
||||
'description' => 'Update Portal',
|
||||
'file' => 'modules/Contacts/updatePortal.php',
|
||||
'class' => 'updatePortal',
|
||||
'function' => 'updateUser',
|
||||
),
|
||||
// Cases
|
||||
array(
|
||||
'module' => 'Cases',
|
||||
'hook' => 'before_save',
|
||||
'order' => 10,
|
||||
'description' => 'Save case updates',
|
||||
'file' => 'modules/AOP_Case_Updates/CaseUpdatesHook.php',
|
||||
'class' => 'CaseUpdatesHook',
|
||||
'function' => 'saveUpdate',
|
||||
),
|
||||
array(
|
||||
'module' => 'Cases',
|
||||
'hook' => 'before_save',
|
||||
'order' => 11,
|
||||
'description' => 'Save case events',
|
||||
'file' => 'modules/AOP_Case_Events/CaseEventsHook.php',
|
||||
'class' => 'CaseEventsHook',
|
||||
'function' => 'saveUpdate',
|
||||
),
|
||||
array(
|
||||
'module' => 'Cases',
|
||||
'hook' => 'before_save',
|
||||
'order' => 12,
|
||||
'description' => 'Case closure prep',
|
||||
'file' => 'modules/AOP_Case_Updates/CaseUpdatesHook.php',
|
||||
'class' => 'CaseUpdatesHook',
|
||||
'function' => 'closureNotifyPrep',
|
||||
),
|
||||
array(
|
||||
'module' => 'Cases',
|
||||
'hook' => 'after_save',
|
||||
'order' => 10,
|
||||
'description' => 'Send contact case closure email',
|
||||
'file' => 'modules/AOP_Case_Updates/CaseUpdatesHook.php',
|
||||
'class' => 'CaseUpdatesHook',
|
||||
'function' => 'closureNotify',
|
||||
),
|
||||
array(
|
||||
'module' => 'Cases',
|
||||
'hook' => 'after_relationship_add',
|
||||
'order' => 9,
|
||||
'description' => 'Assign account',
|
||||
'file' => 'modules/AOP_Case_Updates/CaseUpdatesHook.php',
|
||||
'class' => 'CaseUpdatesHook',
|
||||
'function' => 'assignAccount',
|
||||
),
|
||||
array(
|
||||
'module' => 'Cases',
|
||||
'hook' => 'after_relationship_add',
|
||||
'order' => 10,
|
||||
'description' => 'Send contact case email',
|
||||
'file' => 'modules/AOP_Case_Updates/CaseUpdatesHook.php',
|
||||
'class' => 'CaseUpdatesHook',
|
||||
'function' => 'creationNotify',
|
||||
),
|
||||
array(
|
||||
'module' => 'Cases',
|
||||
'hook' => 'after_retrieve',
|
||||
'order' => 10,
|
||||
'description' => 'Filter HTML',
|
||||
'file' => 'modules/AOP_Case_Updates/CaseUpdatesHook.php',
|
||||
'class' => 'CaseUpdatesHook',
|
||||
'function' => 'filterHTML',
|
||||
),
|
||||
//Emails
|
||||
array(
|
||||
'module' => 'Emails',
|
||||
'hook' => 'after_save',
|
||||
'order' => 10,
|
||||
'description' => 'Save email case updates',
|
||||
'file' => 'modules/AOP_Case_Updates/CaseUpdatesHook.php',
|
||||
'class' => 'CaseUpdatesHook',
|
||||
'function' => 'saveEmailUpdate',
|
||||
),
|
||||
);
|
||||
|
||||
foreach ($hooks as $hook) {
|
||||
check_logic_hook_file(
|
||||
$hook['module'],
|
||||
$hook['hook'],
|
||||
array($hook['order'], $hook['description'], $hook['file'], $hook['class'], $hook['function'])
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @return array
|
||||
*/
|
||||
function getTemplates()
|
||||
{
|
||||
$templates = array();
|
||||
$templates['case_closure_email_template'] = array(
|
||||
'name' => 'Case Closure',
|
||||
'published' => 'off',
|
||||
'description' => 'Template for informing a contact that their case has been closed.',
|
||||
'subject' => '$acase_name [CASE:$acase_case_number] closed',
|
||||
'type' => 'system',
|
||||
'body' => 'Hi $contact_first_name $contact_last_name,
|
||||
|
||||
Your case $acase_name (# $acase_case_number) has been closed on $acase_date_entered
|
||||
Status: $acase_status
|
||||
Reference: $acase_case_number
|
||||
Resolution: $acase_resolution',
|
||||
'body_html' => '<p> Hi $contact_first_name $contact_last_name,</p>
|
||||
<p>Your case $acase_name (# $acase_case_number) has been closed on $acase_date_entered</p>
|
||||
<table border="0"><tbody>
|
||||
<tr><td>Status</td><td>$acase_status</td></tr>
|
||||
<tr><td>Reference</td><td>$acase_case_number</td></tr>
|
||||
<tr><td>Resolution</td><td>$acase_resolution</td></tr>
|
||||
</tbody></table>'
|
||||
);
|
||||
|
||||
$templates['joomla_account_creation_email_template'] = array(
|
||||
'name' => 'Joomla Account Creation',
|
||||
'published' => 'off',
|
||||
'description' => 'Template used when informing a contact that they\'ve been given an account on the joomla portal.',
|
||||
'subject' => 'Support Portal Account Created',
|
||||
'type' => 'system',
|
||||
'body' => 'Hi $contact_name,
|
||||
An account has been created for you at $portal_address.
|
||||
You may login using this email address and the password $joomla_pass',
|
||||
'body_html' => '<p>Hi $contact_name,</p>
|
||||
<p>An account has been created for you at <a href="$portal_address">$portal_address</a>.</p>
|
||||
<p>You may login using this email address and the password $joomla_pass</p>'
|
||||
);
|
||||
|
||||
$templates['case_creation_email_template'] = array(
|
||||
'name' => 'Case Creation',
|
||||
'published' => 'off',
|
||||
'description' => 'Template to send to a contact when a case is received from them.',
|
||||
'subject' => '$acase_name [CASE:$acase_case_number]',
|
||||
'type' => 'system',
|
||||
'body' => 'Hi $contact_first_name $contact_last_name,
|
||||
|
||||
We\'ve received your case $acase_name (# $acase_case_number) on $acase_date_entered
|
||||
Status: $acase_status
|
||||
Reference: $acase_case_number
|
||||
Description: $acase_description',
|
||||
'body_html' => '<p> Hi $contact_first_name $contact_last_name,</p>
|
||||
<p>We\'ve received your case $acase_name (# $acase_case_number) on $acase_date_entered</p>
|
||||
<table border="0"><tbody>
|
||||
<tr><td>Status</td><td>$acase_status</td></tr>
|
||||
<tr><td>Reference</td><td>$acase_case_number</td></tr>
|
||||
<tr><td>Description</td><td>$acase_description</td></tr>
|
||||
</tbody></table>'
|
||||
);
|
||||
|
||||
$templates['contact_email_template'] = array(
|
||||
'name' => 'Contact Case Update',
|
||||
'published' => 'off',
|
||||
'description' => 'Template to send to a contact when their case is updated.',
|
||||
'subject' => '$acase_name update [CASE:$acase_case_number]',
|
||||
'type' => 'system',
|
||||
'body' => 'Hi $user_first_name $user_last_name,
|
||||
|
||||
You\'ve had an update to your case $acase_name (# $acase_case_number) on $aop_case_updates_date_entered:
|
||||
$contact_first_name $contact_last_name, said:
|
||||
$aop_case_updates_description',
|
||||
'body_html' => '<p>Hi $contact_first_name $contact_last_name,</p>
|
||||
<p> </p>
|
||||
<p>You\'ve had an update to your case $acase_name (# $acase_case_number) on $aop_case_updates_date_entered:</p>
|
||||
<p><strong>$user_first_name $user_last_name said:</strong></p>
|
||||
<p style="padding-left:30px;">$aop_case_updates_description</p>'
|
||||
);
|
||||
|
||||
$templates['user_email_template'] = array(
|
||||
'name' => 'User Case Update',
|
||||
'published' => 'off',
|
||||
'description' => 'Email template to send to a SuiteCRM user when their case is updated.',
|
||||
'subject' => '$acase_name (# $acase_case_number) update',
|
||||
'type' => 'system',
|
||||
'body' => 'Hi $user_first_name $user_last_name,
|
||||
|
||||
You\'ve had an update to your case $acase_name (# $acase_case_number) on $aop_case_updates_date_entered:
|
||||
$contact_first_name $contact_last_name, said:
|
||||
$aop_case_updates_description
|
||||
You may review this Case at:
|
||||
$sugarurl/index.php?module=Cases&action=DetailView&record=$acase_id;',
|
||||
'body_html' => '<p>Hi $user_first_name $user_last_name,</p>
|
||||
<p> </p>
|
||||
<p>You\'ve had an update to your case $acase_name (# $acase_case_number) on $aop_case_updates_date_entered:</p>
|
||||
<p><strong>$contact_first_name $contact_last_name, said:</strong></p>
|
||||
<p style="padding-left:30px;">$aop_case_updates_description</p>
|
||||
<p>You may review this Case at: $sugarurl/index.php?module=Cases&action=DetailView&record=$acase_id;</p>'
|
||||
);
|
||||
|
||||
return $templates;
|
||||
}
|
57
public/legacy/install/suite_install/AdvancedOpenSales.php
Executable file
57
public/legacy/install/suite_install/AdvancedOpenSales.php
Executable file
|
@ -0,0 +1,57 @@
|
|||
<?php
|
||||
function install_aos()
|
||||
{
|
||||
require_once('modules/Administration/Administration.php');
|
||||
|
||||
global $sugar_config;
|
||||
|
||||
$sugar_config['aos']['version'] = '5.3.3';
|
||||
if (!isset($sugar_config['aos']['contracts']['renewalReminderPeriod'])) {
|
||||
$sugar_config['aos']['contracts']['renewalReminderPeriod'] = '14';
|
||||
}
|
||||
if (!isset($sugar_config['aos']['lineItems']['totalTax'])) {
|
||||
$sugar_config['aos']['lineItems']['totalTax'] = false;
|
||||
}
|
||||
if (!isset($sugar_config['aos']['lineItems']['enableGroups'])) {
|
||||
$sugar_config['aos']['lineItems']['enableGroups'] = true;
|
||||
}
|
||||
if (!isset($sugar_config['aos']['invoices']['initialNumber'])) {
|
||||
$sugar_config['aos']['invoices']['initialNumber'] = '1';
|
||||
}
|
||||
if (!isset($sugar_config['aos']['quotes']['initialNumber'])) {
|
||||
$sugar_config['aos']['quotes']['initialNumber'] = '1';
|
||||
}
|
||||
|
||||
ksort($sugar_config);
|
||||
write_array_to_file('sugar_config', $sugar_config, 'config.php');
|
||||
}
|
||||
|
||||
function upgrade_aos()
|
||||
{
|
||||
global $sugar_config, $db;
|
||||
if (!isset($sugar_config['aos']['version']) || $sugar_config['aos']['version'] < 5.2) {
|
||||
$db->query("UPDATE aos_pdf_templates SET type = 'AOS_Quotes' WHERE type = 'Quotes'");
|
||||
$db->query("UPDATE aos_pdf_templates SET type = 'AOS_Invoices' WHERE type = 'Invoices'");
|
||||
|
||||
require_once('include/utils/file_utils.php');
|
||||
|
||||
$old_files = array(
|
||||
'custom/Extension/modules/Accounts/Ext/Layoutdefs/Account.php',
|
||||
'custom/Extension/modules/Accounts/Ext/Vardefs/Account.php',
|
||||
'custom/Extension/modules/Contacts/Ext/Layoutdefs/Contact.php',
|
||||
'custom/Extension/modules/Contacts/Ext/Vardefs/Contact.php',
|
||||
'custom/Extension/modules/Opportunities/Ext/Layoutdefs/Opportunity.php',
|
||||
'custom/Extension/modules/Opportunities/Ext/Vardefs/Opportunity.php',
|
||||
'custom/Extension/modules/Project/Ext/Layoutdefs/Project.php',
|
||||
'custom/Extension/modules/Project/Ext/Vardefs/Project.php',
|
||||
'modules/AOS_Quotes/js/Quote.js',
|
||||
);
|
||||
|
||||
foreach ($old_files as $old_file) {
|
||||
if (file_exists($old_file)) {
|
||||
create_custom_directory('bak_aos/'.$old_file);
|
||||
sugar_rename($old_file, 'custom/bak_aos/'.$old_file);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
968
public/legacy/install/suite_install/GoogleMaps.php
Executable file
968
public/legacy/install/suite_install/GoogleMaps.php
Executable file
|
@ -0,0 +1,968 @@
|
|||
<?php
|
||||
function install_gmaps()
|
||||
{
|
||||
require_once('ModuleInstall/ModuleInstaller.php');
|
||||
$ModuleInstaller = new ModuleInstaller();
|
||||
$ModuleInstaller->install_custom_fields(getCustomFields());
|
||||
|
||||
installJJWHooks();
|
||||
}
|
||||
|
||||
|
||||
function installJJWHooks()
|
||||
{
|
||||
$hooks= array(
|
||||
// Prospects
|
||||
array(
|
||||
'module' => 'Prospects',
|
||||
'hook' => 'before_save',
|
||||
'order' => 77,
|
||||
'description' => 'updateGeocodeInfo',
|
||||
'file' => 'modules/Prospects/ProspectsJjwg_MapsLogicHook.php',
|
||||
'class' => 'ProspectsJjwg_MapsLogicHook',
|
||||
'function' => 'updateGeocodeInfo',
|
||||
),
|
||||
array(
|
||||
'module' => 'Prospects',
|
||||
'hook' => 'after_save',
|
||||
'order' => 77,
|
||||
'description' => 'updateRelatedMeetingsGeocodeInfo',
|
||||
'file' => 'modules/Prospects/ProspectsJjwg_MapsLogicHook.php',
|
||||
'class' => 'ProspectsJjwg_MapsLogicHook',
|
||||
'function' => 'updateRelatedMeetingsGeocodeInfo',
|
||||
),
|
||||
// Leads
|
||||
array(
|
||||
'module' => 'Leads',
|
||||
'hook' => 'before_save',
|
||||
'order' => 77,
|
||||
'description' => 'updateGeocodeInfo',
|
||||
'file' => 'modules/Leads/LeadsJjwg_MapsLogicHook.php',
|
||||
'class' => 'LeadsJjwg_MapsLogicHook',
|
||||
'function' => 'updateGeocodeInfo',
|
||||
),
|
||||
array(
|
||||
'module' => 'Leads',
|
||||
'hook' => 'after_save',
|
||||
'order' => 77,
|
||||
'description' => 'updateRelatedMeetingsGeocodeInfo',
|
||||
'file' => 'modules/Leads/LeadsJjwg_MapsLogicHook.php',
|
||||
'class' => 'LeadsJjwg_MapsLogicHook',
|
||||
'function' => 'updateRelatedMeetingsGeocodeInfo',
|
||||
),
|
||||
// Contacts
|
||||
array(
|
||||
'module' => 'Contacts',
|
||||
'hook' => 'before_save',
|
||||
'order' => 77,
|
||||
'description' => 'updateGeocodeInfo',
|
||||
'file' => 'modules/Contacts/ContactsJjwg_MapsLogicHook.php',
|
||||
'class' => 'ContactsJjwg_MapsLogicHook',
|
||||
'function' => 'updateGeocodeInfo',
|
||||
),
|
||||
array(
|
||||
'module' => 'Contacts',
|
||||
'hook' => 'after_save',
|
||||
'order' => 77,
|
||||
'description' => 'updateRelatedMeetingsGeocodeInfo',
|
||||
'file' => 'modules/Contacts/ContactsJjwg_MapsLogicHook.php',
|
||||
'class' => 'ContactsJjwg_MapsLogicHook',
|
||||
'function' => 'updateRelatedMeetingsGeocodeInfo',
|
||||
),
|
||||
// Meetings
|
||||
array(
|
||||
'module' => 'Meetings',
|
||||
'hook' => 'after_save',
|
||||
'order' => 77,
|
||||
'description' => 'updateMeetingGeocodeInfo',
|
||||
'file' => 'modules/Meetings/MeetingsJjwg_MapsLogicHook.php',
|
||||
'class' => 'MeetingsJjwg_MapsLogicHook',
|
||||
'function' => 'updateMeetingGeocodeInfo',
|
||||
),
|
||||
// Opportunities (5 hooks)
|
||||
array(
|
||||
'module' => 'Opportunities',
|
||||
'hook' => 'before_save',
|
||||
'order' => 77,
|
||||
'description' => 'updateGeocodeInfo',
|
||||
'file' => 'modules/Opportunities/OpportunitiesJjwg_MapsLogicHook.php',
|
||||
'class' => 'OpportunitiesJjwg_MapsLogicHook',
|
||||
'function' => 'updateGeocodeInfo',
|
||||
),
|
||||
array(
|
||||
'module' => 'Opportunities',
|
||||
'hook' => 'after_save',
|
||||
'order' => 77,
|
||||
'description' => 'updateRelatedMeetingsGeocodeInfo',
|
||||
'file' => 'modules/Opportunities/OpportunitiesJjwg_MapsLogicHook.php',
|
||||
'class' => 'OpportunitiesJjwg_MapsLogicHook',
|
||||
'function' => 'updateRelatedMeetingsGeocodeInfo',
|
||||
),
|
||||
array(
|
||||
'module' => 'Opportunities',
|
||||
'hook' => 'after_save',
|
||||
'order' => 78,
|
||||
'description' => 'updateRelatedProjectGeocodeInfo',
|
||||
'file' => 'modules/Opportunities/OpportunitiesJjwg_MapsLogicHook.php',
|
||||
'class' => 'OpportunitiesJjwg_MapsLogicHook',
|
||||
'function' => 'updateRelatedProjectGeocodeInfo',
|
||||
),
|
||||
array(
|
||||
'module' => 'Opportunities',
|
||||
'hook' => 'after_relationship_add',
|
||||
'order' => 77,
|
||||
'description' => 'addRelationship',
|
||||
'file' => 'modules/Opportunities/OpportunitiesJjwg_MapsLogicHook.php',
|
||||
'class' => 'OpportunitiesJjwg_MapsLogicHook',
|
||||
'function' => 'addRelationship',
|
||||
),
|
||||
array(
|
||||
'module' => 'Opportunities',
|
||||
'hook' => 'after_relationship_delete',
|
||||
'order' => 77,
|
||||
'description' => 'deleteRelationship',
|
||||
'file' => 'modules/Opportunities/OpportunitiesJjwg_MapsLogicHook.php',
|
||||
'class' => 'OpportunitiesJjwg_MapsLogicHook',
|
||||
'function' => 'deleteRelationship',
|
||||
),
|
||||
// Cases (4 Hooks)
|
||||
array(
|
||||
'module' => 'Cases',
|
||||
'hook' => 'before_save',
|
||||
'order' => 77,
|
||||
'description' => 'updateGeocodeInfo',
|
||||
'file' => 'modules/Cases/CasesJjwg_MapsLogicHook.php',
|
||||
'class' => 'CasesJjwg_MapsLogicHook',
|
||||
'function' => 'updateGeocodeInfo',
|
||||
),
|
||||
array(
|
||||
'module' => 'Cases',
|
||||
'hook' => 'after_save',
|
||||
'order' => 77,
|
||||
'description' => 'updateRelatedMeetingsGeocodeInfo',
|
||||
'file' => 'modules/Cases/CasesJjwg_MapsLogicHook.php',
|
||||
'class' => 'CasesJjwg_MapsLogicHook',
|
||||
'function' => 'updateRelatedMeetingsGeocodeInfo',
|
||||
),
|
||||
array(
|
||||
'module' => 'Cases',
|
||||
'hook' => 'after_relationship_add',
|
||||
'order' => 77,
|
||||
'description' => 'addRelationship',
|
||||
'file' => 'modules/Cases/CasesJjwg_MapsLogicHook.php',
|
||||
'class' => 'CasesJjwg_MapsLogicHook',
|
||||
'function' => 'addRelationship',
|
||||
),
|
||||
array(
|
||||
'module' => 'Cases',
|
||||
'hook' => 'after_relationship_delete',
|
||||
'order' => 77,
|
||||
'description' => 'deleteRelationship',
|
||||
'file' => 'modules/Cases/CasesJjwg_MapsLogicHook.php',
|
||||
'class' => 'CasesJjwg_MapsLogicHook',
|
||||
'function' => 'deleteRelationship',
|
||||
),
|
||||
// Project (4 Hooks)
|
||||
array(
|
||||
'module' => 'Project',
|
||||
'hook' => 'before_save',
|
||||
'order' => 77,
|
||||
'description' => 'updateGeocodeInfo',
|
||||
'file' => 'modules/Project/ProjectJjwg_MapsLogicHook.php',
|
||||
'class' => 'ProjectJjwg_MapsLogicHook',
|
||||
'function' => 'updateGeocodeInfo',
|
||||
),
|
||||
array(
|
||||
'module' => 'Project',
|
||||
'hook' => 'after_save',
|
||||
'order' => 77,
|
||||
'description' => 'updateRelatedMeetingsGeocodeInfo',
|
||||
'file' => 'modules/Project/ProjectJjwg_MapsLogicHook.php',
|
||||
'class' => 'ProjectJjwg_MapsLogicHook',
|
||||
'function' => 'updateRelatedMeetingsGeocodeInfo',
|
||||
),
|
||||
array(
|
||||
'module' => 'Project',
|
||||
'hook' => 'after_relationship_add',
|
||||
'order' => 77,
|
||||
'description' => 'addRelationship',
|
||||
'file' => 'modules/Project/ProjectJjwg_MapsLogicHook.php',
|
||||
'class' => 'ProjectJjwg_MapsLogicHook',
|
||||
'function' => 'addRelationship',
|
||||
),
|
||||
array(
|
||||
'module' => 'Project',
|
||||
'hook' => 'after_relationship_delete',
|
||||
'order' => 77,
|
||||
'description' => 'deleteRelationship',
|
||||
'file' => 'modules/Project/ProjectJjwg_MapsLogicHook.php',
|
||||
'class' => 'ProjectJjwg_MapsLogicHook',
|
||||
'function' => 'deleteRelationship',
|
||||
),
|
||||
// Accounts (7 hooks)
|
||||
array(
|
||||
'module' => 'Accounts',
|
||||
'hook' => 'before_save',
|
||||
'order' => 77,
|
||||
'description' => 'updateGeocodeInfo',
|
||||
'file' => 'modules/Accounts/AccountsJjwg_MapsLogicHook.php',
|
||||
'class' => 'AccountsJjwg_MapsLogicHook',
|
||||
'function' => 'updateGeocodeInfo',
|
||||
),
|
||||
array(
|
||||
'module' => 'Accounts',
|
||||
'hook' => 'after_save',
|
||||
'order' => 77,
|
||||
'description' => 'updateRelatedMeetingsGeocodeInfo',
|
||||
'file' => 'modules/Accounts/AccountsJjwg_MapsLogicHook.php',
|
||||
'class' => 'AccountsJjwg_MapsLogicHook',
|
||||
'function' => 'updateRelatedMeetingsGeocodeInfo',
|
||||
),
|
||||
array(
|
||||
'module' => 'Accounts',
|
||||
'hook' => 'after_save',
|
||||
'order' => 78,
|
||||
'description' => 'updateRelatedProjectGeocodeInfo',
|
||||
'file' => 'modules/Accounts/AccountsJjwg_MapsLogicHook.php',
|
||||
'class' => 'AccountsJjwg_MapsLogicHook',
|
||||
'function' => 'updateRelatedProjectGeocodeInfo',
|
||||
),
|
||||
array(
|
||||
'module' => 'Accounts',
|
||||
'hook' => 'after_save',
|
||||
'order' => 79,
|
||||
'description' => 'updateRelatedOpportunitiesGeocodeInfo',
|
||||
'file' => 'modules/Accounts/AccountsJjwg_MapsLogicHook.php',
|
||||
'class' => 'AccountsJjwg_MapsLogicHook',
|
||||
'function' => 'updateRelatedOpportunitiesGeocodeInfo',
|
||||
),
|
||||
array(
|
||||
'module' => 'Accounts',
|
||||
'hook' => 'after_save',
|
||||
'order' => 80,
|
||||
'description' => 'updateRelatedCasesGeocodeInfo',
|
||||
'file' => 'modules/Accounts/AccountsJjwg_MapsLogicHook.php',
|
||||
'class' => 'AccountsJjwg_MapsLogicHook',
|
||||
'function' => 'updateRelatedCasesGeocodeInfo',
|
||||
),
|
||||
array(
|
||||
'module' => 'Accounts',
|
||||
'hook' => 'after_relationship_add',
|
||||
'order' => 77,
|
||||
'description' => 'addRelationship',
|
||||
'file' => 'modules/Accounts/AccountsJjwg_MapsLogicHook.php',
|
||||
'class' => 'AccountsJjwg_MapsLogicHook',
|
||||
'function' => 'addRelationship',
|
||||
),
|
||||
array(
|
||||
'module' => 'Accounts',
|
||||
'hook' => 'after_relationship_delete',
|
||||
'order' => 77,
|
||||
'description' => 'deleteRelationship',
|
||||
'file' => 'modules/Accounts/AccountsJjwg_MapsLogicHook.php',
|
||||
'class' => 'AccountsJjwg_MapsLogicHook',
|
||||
'function' => 'deleteRelationship',
|
||||
),
|
||||
);
|
||||
|
||||
foreach ($hooks as $hook) {
|
||||
check_logic_hook_file($hook['module'], $hook['hook'], array($hook['order'], $hook['description'], $hook['file'], $hook['class'], $hook['function']));
|
||||
}
|
||||
}
|
||||
|
||||
function getCustomFields()
|
||||
{
|
||||
$custom_fields =
|
||||
array(
|
||||
'Accountsjjwg_maps_lng_c' =>
|
||||
array(
|
||||
'id' => 'Accountsjjwg_maps_lng_c',
|
||||
'name' => 'jjwg_maps_lng_c',
|
||||
'label' => 'LBL_JJWG_MAPS_LNG',
|
||||
'comments' => null,
|
||||
'help' => 'Longitude',
|
||||
'module' => 'Accounts',
|
||||
'type' => 'float',
|
||||
'max_size' => '11',
|
||||
'require_option' => '0',
|
||||
'default' => '0.00000000',
|
||||
'default_value' => '0.00000000',
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'precision' => '8',
|
||||
'ext1' => '8',
|
||||
),
|
||||
'Accountsjjwg_maps_lat_c' =>
|
||||
array(
|
||||
'id' => 'Accountsjjwg_maps_lat_c',
|
||||
'name' => 'jjwg_maps_lat_c',
|
||||
'label' => 'LBL_JJWG_MAPS_LAT',
|
||||
'comments' => null,
|
||||
'help' => 'Latitude',
|
||||
'module' => 'Accounts',
|
||||
'type' => 'float',
|
||||
'max_size' => '10',
|
||||
'require_option' => '0',
|
||||
'default' => '0.00000000',
|
||||
'default_value' => '0.00000000',
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'precision' => '8',
|
||||
'ext1' => '8',
|
||||
),
|
||||
'Accountsjjwg_maps_geocode_status_c' =>
|
||||
array(
|
||||
'id' => 'Accountsjjwg_maps_geocode_status_c',
|
||||
'name' => 'jjwg_maps_geocode_status_c',
|
||||
'label' => 'LBL_JJWG_MAPS_GEOCODE_STATUS',
|
||||
'comments' => 'Geocode Status',
|
||||
'help' => 'Geocode Status',
|
||||
'module' => 'Accounts',
|
||||
'type' => 'varchar',
|
||||
'max_size' => '255',
|
||||
'require_option' => '0',
|
||||
'default' => null,
|
||||
'default_value' => null,
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'ext1' => null,
|
||||
),
|
||||
'Accountsjjwg_maps_address_c' =>
|
||||
array(
|
||||
'id' => 'Accountsjjwg_maps_address_c',
|
||||
'name' => 'jjwg_maps_address_c',
|
||||
'label' => 'LBL_JJWG_MAPS_ADDRESS',
|
||||
'comments' => 'Address',
|
||||
'help' => 'Address',
|
||||
'module' => 'Accounts',
|
||||
'type' => 'varchar',
|
||||
'max_size' => '255',
|
||||
'require_option' => '0',
|
||||
'default' => null,
|
||||
'default_value' => null,
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'ext1' => null,
|
||||
),
|
||||
'Casesjjwg_maps_lng_c' =>
|
||||
array(
|
||||
'id' => 'Casesjjwg_maps_lng_c',
|
||||
'name' => 'jjwg_maps_lng_c',
|
||||
'label' => 'LBL_JJWG_MAPS_LNG',
|
||||
'comments' => null,
|
||||
'help' => 'Longitude',
|
||||
'module' => 'Cases',
|
||||
'type' => 'float',
|
||||
'max_size' => '11',
|
||||
'require_option' => '0',
|
||||
'default' => '0.00000000',
|
||||
'default_value' => '0.00000000',
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'precision' => '8',
|
||||
'ext1' => '8',
|
||||
),
|
||||
'Casesjjwg_maps_lat_c' =>
|
||||
array(
|
||||
'id' => 'Casesjjwg_maps_lat_c',
|
||||
'name' => 'jjwg_maps_lat_c',
|
||||
'label' => 'LBL_JJWG_MAPS_LAT',
|
||||
'comments' => null,
|
||||
'help' => 'Latitude',
|
||||
'module' => 'Cases',
|
||||
'type' => 'float',
|
||||
'max_size' => '10',
|
||||
'require_option' => '0',
|
||||
'default' => '0.00000000',
|
||||
'default_value' => '0.00000000',
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'precision' => '8',
|
||||
'ext1' => '8',
|
||||
),
|
||||
'Casesjjwg_maps_geocode_status_c' =>
|
||||
array(
|
||||
'id' => 'Casesjjwg_maps_geocode_status_c',
|
||||
'name' => 'jjwg_maps_geocode_status_c',
|
||||
'label' => 'LBL_JJWG_MAPS_GEOCODE_STATUS',
|
||||
'comments' => 'Geocode Status',
|
||||
'help' => 'Geocode Status',
|
||||
'module' => 'Cases',
|
||||
'type' => 'varchar',
|
||||
'max_size' => '255',
|
||||
'require_option' => '0',
|
||||
'default' => null,
|
||||
'default_value' => null,
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'ext1' => null,
|
||||
),
|
||||
'Casesjjwg_maps_address_c' =>
|
||||
array(
|
||||
'id' => 'Casesjjwg_maps_address_c',
|
||||
'name' => 'jjwg_maps_address_c',
|
||||
'label' => 'LBL_JJWG_MAPS_ADDRESS',
|
||||
'comments' => 'Address',
|
||||
'help' => 'Address',
|
||||
'module' => 'Cases',
|
||||
'type' => 'varchar',
|
||||
'max_size' => '255',
|
||||
'require_option' => '0',
|
||||
'default' => null,
|
||||
'default_value' => null,
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'ext1' => null,
|
||||
),
|
||||
'Contactsjjwg_maps_lng_c' =>
|
||||
array(
|
||||
'id' => 'Contactsjjwg_maps_lng_c',
|
||||
'name' => 'jjwg_maps_lng_c',
|
||||
'label' => 'LBL_JJWG_MAPS_LNG',
|
||||
'comments' => null,
|
||||
'help' => 'Longitude',
|
||||
'module' => 'Contacts',
|
||||
'type' => 'float',
|
||||
'max_size' => '11',
|
||||
'require_option' => '0',
|
||||
'default' => '0.00000000',
|
||||
'default_value' => '0.00000000',
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'precision' => '8',
|
||||
'ext1' => '8',
|
||||
),
|
||||
'Contactsjjwg_maps_lat_c' =>
|
||||
array(
|
||||
'id' => 'Contactsjjwg_maps_lat_c',
|
||||
'name' => 'jjwg_maps_lat_c',
|
||||
'label' => 'LBL_JJWG_MAPS_LAT',
|
||||
'comments' => null,
|
||||
'help' => 'Latitude',
|
||||
'module' => 'Contacts',
|
||||
'type' => 'float',
|
||||
'max_size' => '10',
|
||||
'require_option' => '0',
|
||||
'default' => '0.00000000',
|
||||
'default_value' => '0.00000000',
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'precision' => '8',
|
||||
'ext1' => '8',
|
||||
),
|
||||
'Contactsjjwg_maps_geocode_status_c' =>
|
||||
array(
|
||||
'id' => 'Contactsjjwg_maps_geocode_status_c',
|
||||
'name' => 'jjwg_maps_geocode_status_c',
|
||||
'label' => 'LBL_JJWG_MAPS_GEOCODE_STATUS',
|
||||
'comments' => 'Geocode Status',
|
||||
'help' => 'Geocode Status',
|
||||
'module' => 'Contacts',
|
||||
'type' => 'varchar',
|
||||
'max_size' => '255',
|
||||
'require_option' => '0',
|
||||
'default' => null,
|
||||
'default_value' => null,
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'ext1' => null,
|
||||
),
|
||||
'Contactsjjwg_maps_address_c' =>
|
||||
array(
|
||||
'id' => 'Contactsjjwg_maps_address_c',
|
||||
'name' => 'jjwg_maps_address_c',
|
||||
'label' => 'LBL_JJWG_MAPS_ADDRESS',
|
||||
'comments' => 'Address',
|
||||
'help' => 'Address',
|
||||
'module' => 'Contacts',
|
||||
'type' => 'varchar',
|
||||
'max_size' => '255',
|
||||
'require_option' => '0',
|
||||
'default' => null,
|
||||
'default_value' => null,
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'ext1' => null,
|
||||
),
|
||||
'Leadsjjwg_maps_lng_c' =>
|
||||
array(
|
||||
'id' => 'Leadsjjwg_maps_lng_c',
|
||||
'name' => 'jjwg_maps_lng_c',
|
||||
'label' => 'LBL_JJWG_MAPS_LNG',
|
||||
'comments' => null,
|
||||
'help' => 'Longitude',
|
||||
'module' => 'Leads',
|
||||
'type' => 'float',
|
||||
'max_size' => '11',
|
||||
'require_option' => '0',
|
||||
'default' => '0.00000000',
|
||||
'default_value' => '0.00000000',
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'precision' => '8',
|
||||
'ext1' => '8',
|
||||
),
|
||||
'Leadsjjwg_maps_lat_c' =>
|
||||
array(
|
||||
'id' => 'Leadsjjwg_maps_lat_c',
|
||||
'name' => 'jjwg_maps_lat_c',
|
||||
'label' => 'LBL_JJWG_MAPS_LAT',
|
||||
'comments' => null,
|
||||
'help' => 'Latitude',
|
||||
'module' => 'Leads',
|
||||
'type' => 'float',
|
||||
'max_size' => '10',
|
||||
'require_option' => '0',
|
||||
'default' => '0.00000000',
|
||||
'default_value' => '0.00000000',
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'precision' => '8',
|
||||
'ext1' => '8',
|
||||
),
|
||||
'Leadsjjwg_maps_geocode_status_c' =>
|
||||
array(
|
||||
'id' => 'Leadsjjwg_maps_geocode_status_c',
|
||||
'name' => 'jjwg_maps_geocode_status_c',
|
||||
'label' => 'LBL_JJWG_MAPS_GEOCODE_STATUS',
|
||||
'comments' => 'Geocode Status',
|
||||
'help' => 'Geocode Status',
|
||||
'module' => 'Leads',
|
||||
'type' => 'varchar',
|
||||
'max_size' => '255',
|
||||
'require_option' => '0',
|
||||
'default' => null,
|
||||
'default_value' => null,
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'ext1' => null,
|
||||
),
|
||||
'Leadsjjwg_maps_address_c' =>
|
||||
array(
|
||||
'id' => 'Leadsjjwg_maps_address_c',
|
||||
'name' => 'jjwg_maps_address_c',
|
||||
'label' => 'LBL_JJWG_MAPS_ADDRESS',
|
||||
'comments' => 'Address',
|
||||
'help' => 'Address',
|
||||
'module' => 'Leads',
|
||||
'type' => 'varchar',
|
||||
'max_size' => '255',
|
||||
'require_option' => '0',
|
||||
'default' => null,
|
||||
'default_value' => null,
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'ext1' => null,
|
||||
),
|
||||
'Meetingsjjwg_maps_lng_c' =>
|
||||
array(
|
||||
'id' => 'Meetingsjjwg_maps_lng_c',
|
||||
'name' => 'jjwg_maps_lng_c',
|
||||
'label' => 'LBL_JJWG_MAPS_LNG',
|
||||
'comments' => null,
|
||||
'help' => 'Longitude',
|
||||
'module' => 'Meetings',
|
||||
'type' => 'float',
|
||||
'max_size' => '11',
|
||||
'require_option' => '0',
|
||||
'default' => '0.00000000',
|
||||
'default_value' => '0.00000000',
|
||||
'date_modified' => '2012-08-17 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'precision' => '8',
|
||||
'ext1' => '8',
|
||||
),
|
||||
'Meetingsjjwg_maps_lat_c' =>
|
||||
array(
|
||||
'id' => 'Meetingsjjwg_maps_lat_c',
|
||||
'name' => 'jjwg_maps_lat_c',
|
||||
'label' => 'LBL_JJWG_MAPS_LAT',
|
||||
'comments' => null,
|
||||
'help' => 'Latitude',
|
||||
'module' => 'Meetings',
|
||||
'type' => 'float',
|
||||
'max_size' => '10',
|
||||
'require_option' => '0',
|
||||
'default' => '0.00000000',
|
||||
'default_value' => '0.00000000',
|
||||
'date_modified' => '2012-08-17 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'precision' => '8',
|
||||
'ext1' => '8',
|
||||
),
|
||||
'Meetingsjjwg_maps_geocode_status_c' =>
|
||||
array(
|
||||
'id' => 'Meetingsjjwg_maps_geocode_status_c',
|
||||
'name' => 'jjwg_maps_geocode_status_c',
|
||||
'label' => 'LBL_JJWG_MAPS_GEOCODE_STATUS',
|
||||
'comments' => 'Geocode Status',
|
||||
'help' => 'Geocode Status',
|
||||
'module' => 'Meetings',
|
||||
'type' => 'varchar',
|
||||
'max_size' => '255',
|
||||
'require_option' => '0',
|
||||
'default_value' => null,
|
||||
'date_modified' => '2012-08-17 22:06:01',
|
||||
'deleted' => '0',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'ext1' => null,
|
||||
),
|
||||
'Meetingsjjwg_maps_address_c' =>
|
||||
array(
|
||||
'id' => 'Meetingsjjwg_maps_address_c',
|
||||
'name' => 'jjwg_maps_address_c',
|
||||
'label' => 'LBL_JJWG_MAPS_ADDRESS',
|
||||
'comments' => 'Address',
|
||||
'help' => 'Address',
|
||||
'module' => 'Meetings',
|
||||
'type' => 'varchar',
|
||||
'max_size' => '255',
|
||||
'require_option' => '0',
|
||||
'default' => null,
|
||||
'default_value' => null,
|
||||
'date_modified' => '2012-08-17 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'ext1' => null,
|
||||
),
|
||||
'Opportunitiesjjwg_maps_lng_c' =>
|
||||
array(
|
||||
'id' => 'Opportunitiesjjwg_maps_lng_c',
|
||||
'name' => 'jjwg_maps_lng_c',
|
||||
'label' => 'LBL_JJWG_MAPS_LNG',
|
||||
'comments' => null,
|
||||
'help' => 'Longitude',
|
||||
'module' => 'Opportunities',
|
||||
'type' => 'float',
|
||||
'max_size' => '11',
|
||||
'require_option' => '0',
|
||||
'default' => '0.00000000',
|
||||
'default_value' => '0.00000000',
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'precision' => '8',
|
||||
'ext1' => '8',
|
||||
),
|
||||
'Opportunitiesjjwg_maps_lat_c' =>
|
||||
array(
|
||||
'id' => 'Opportunitiesjjwg_maps_lat_c',
|
||||
'name' => 'jjwg_maps_lat_c',
|
||||
'label' => 'LBL_JJWG_MAPS_LAT',
|
||||
'comments' => null,
|
||||
'help' => 'Latitude',
|
||||
'module' => 'Opportunities',
|
||||
'type' => 'float',
|
||||
'max_size' => '10',
|
||||
'require_option' => '0',
|
||||
'default' => '0.00000000',
|
||||
'default_value' => '0.00000000',
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'precision' => '8',
|
||||
'ext1' => '8',
|
||||
),
|
||||
'Opportunitiesjjwg_maps_geocode_status_c' =>
|
||||
array(
|
||||
'id' => 'Opportunitiesjjwg_maps_geocode_status_c',
|
||||
'name' => 'jjwg_maps_geocode_status_c',
|
||||
'label' => 'LBL_JJWG_MAPS_GEOCODE_STATUS',
|
||||
'comments' => 'Geocode Status',
|
||||
'help' => 'Geocode Status',
|
||||
'module' => 'Opportunities',
|
||||
'type' => 'varchar',
|
||||
'max_size' => '255',
|
||||
'require_option' => '0',
|
||||
'default' => null,
|
||||
'default_value' => null,
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'ext1' => null,
|
||||
),
|
||||
'Opportunitiesjjwg_maps_address_c' =>
|
||||
array(
|
||||
'id' => 'Opportunitiesjjwg_maps_address_c',
|
||||
'name' => 'jjwg_maps_address_c',
|
||||
'label' => 'LBL_JJWG_MAPS_ADDRESS',
|
||||
'comments' => 'Address',
|
||||
'help' => 'Address',
|
||||
'module' => 'Opportunities',
|
||||
'type' => 'varchar',
|
||||
'max_size' => '255',
|
||||
'require_option' => '0',
|
||||
'default' => null,
|
||||
'default_value' => null,
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'ext1' => null,
|
||||
),
|
||||
'Projectjjwg_maps_lng_c' =>
|
||||
array(
|
||||
'id' => 'Projectjjwg_maps_lng_c',
|
||||
'name' => 'jjwg_maps_lng_c',
|
||||
'label' => 'LBL_JJWG_MAPS_LNG',
|
||||
'comments' => null,
|
||||
'help' => 'Longitude',
|
||||
'module' => 'Project',
|
||||
'type' => 'float',
|
||||
'max_size' => '11',
|
||||
'require_option' => '0',
|
||||
'default' => '0.00000000',
|
||||
'default_value' => '0.00000000',
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'precision' => '8',
|
||||
'ext1' => '8',
|
||||
),
|
||||
'Projectjjwg_maps_lat_c' =>
|
||||
array(
|
||||
'id' => 'Projectjjwg_maps_lat_c',
|
||||
'name' => 'jjwg_maps_lat_c',
|
||||
'label' => 'LBL_JJWG_MAPS_LAT',
|
||||
'comments' => null,
|
||||
'help' => 'Latitude',
|
||||
'module' => 'Project',
|
||||
'type' => 'float',
|
||||
'max_size' => '10',
|
||||
'require_option' => '0',
|
||||
'default' => '0.00000000',
|
||||
'default_value' => '0.00000000',
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'precision' => '8',
|
||||
'ext1' => '8',
|
||||
),
|
||||
'Projectjjwg_maps_geocode_status_c' =>
|
||||
array(
|
||||
'id' => 'Projectjjwg_maps_geocode_status_c',
|
||||
'name' => 'jjwg_maps_geocode_status_c',
|
||||
'label' => 'LBL_JJWG_MAPS_GEOCODE_STATUS',
|
||||
'comments' => 'Geocode Status',
|
||||
'help' => 'Geocode Status',
|
||||
'module' => 'Project',
|
||||
'type' => 'varchar',
|
||||
'max_size' => '255',
|
||||
'require_option' => '0',
|
||||
'default' => null,
|
||||
'default_value' => null,
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'ext1' => null,
|
||||
),
|
||||
'Projectjjwg_maps_address_c' =>
|
||||
array(
|
||||
'id' => 'Projectjjwg_maps_address_c',
|
||||
'name' => 'jjwg_maps_address_c',
|
||||
'label' => 'LBL_JJWG_MAPS_ADDRESS',
|
||||
'comments' => 'Address',
|
||||
'help' => 'Address',
|
||||
'module' => 'Project',
|
||||
'type' => 'varchar',
|
||||
'max_size' => '255',
|
||||
'require_option' => '0',
|
||||
'default' => null,
|
||||
'default_value' => null,
|
||||
'date_modified' => '2010-09-18 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'ext1' => null,
|
||||
),
|
||||
'Prospectsjjwg_maps_lng_c' =>
|
||||
array(
|
||||
'id' => 'Prospectsjjwg_maps_lng_c',
|
||||
'name' => 'jjwg_maps_lng_c',
|
||||
'label' => 'LBL_JJWG_MAPS_LNG',
|
||||
'comments' => null,
|
||||
'help' => 'Longitude',
|
||||
'module' => 'Prospects',
|
||||
'type' => 'float',
|
||||
'max_size' => '11',
|
||||
'require_option' => '0',
|
||||
'default' => '0.00000000',
|
||||
'default_value' => '0.00000000',
|
||||
'date_modified' => '2012-08-17 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'precision' => '8',
|
||||
'ext1' => '8',
|
||||
),
|
||||
'Prospectsjjwg_maps_lat_c' =>
|
||||
array(
|
||||
'id' => 'Prospectsjjwg_maps_lat_c',
|
||||
'name' => 'jjwg_maps_lat_c',
|
||||
'label' => 'LBL_JJWG_MAPS_LAT',
|
||||
'comments' => null,
|
||||
'help' => 'Latitude',
|
||||
'module' => 'Prospects',
|
||||
'type' => 'float',
|
||||
'max_size' => '10',
|
||||
'require_option' => '0',
|
||||
'default' => '0.00000000',
|
||||
'default_value' => '0.00000000',
|
||||
'date_modified' => '2012-08-17 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'precision' => '8',
|
||||
'ext1' => '8',
|
||||
),
|
||||
'Prospectsjjwg_maps_geocode_status_c' =>
|
||||
array(
|
||||
'id' => 'Prospectsjjwg_maps_geocode_status_c',
|
||||
'name' => 'jjwg_maps_geocode_status_c',
|
||||
'label' => 'LBL_JJWG_MAPS_GEOCODE_STATUS',
|
||||
'comments' => 'Geocode Status',
|
||||
'help' => 'Geocode Status',
|
||||
'module' => 'Prospects',
|
||||
'type' => 'varchar',
|
||||
'max_size' => '255',
|
||||
'require_option' => '0',
|
||||
'default' => null,
|
||||
'default_value' => null,
|
||||
'date_modified' => '2012-08-17 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'ext1' => null,
|
||||
),
|
||||
'Prospectsjjwg_maps_address_c' =>
|
||||
array(
|
||||
'id' => 'Prospectsjjwg_maps_address_c',
|
||||
'name' => 'jjwg_maps_address_c',
|
||||
'label' => 'LBL_JJWG_MAPS_ADDRESS',
|
||||
'comments' => 'Address',
|
||||
'help' => 'Address',
|
||||
'module' => 'Prospects',
|
||||
'type' => 'varchar',
|
||||
'max_size' => '255',
|
||||
'require_option' => '0',
|
||||
'default' => null,
|
||||
'default_value' => null,
|
||||
'date_modified' => '2012-08-17 22:06:01',
|
||||
'audited' => '0',
|
||||
'mass_update' => '0',
|
||||
'duplicate_merge' => '0',
|
||||
'reportable' => '1',
|
||||
'importable' => 'true',
|
||||
'ext1' => null,
|
||||
),
|
||||
);
|
||||
|
||||
return $custom_fields;
|
||||
}
|
80
public/legacy/install/suite_install/Projects.php
Normal file
80
public/legacy/install/suite_install/Projects.php
Normal file
|
@ -0,0 +1,80 @@
|
|||
<?php
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
function install_projects()
|
||||
{
|
||||
require_once('ModuleInstall/ModuleInstaller.php');
|
||||
|
||||
$hooks = array(
|
||||
//Projects
|
||||
array(
|
||||
'module' => 'Project',
|
||||
'hook' => 'before_delete',
|
||||
'order' => 1,
|
||||
'description' => 'Delete Project Tasks',
|
||||
'file' => 'modules/Project/delete_project_tasks.php',
|
||||
'class' => 'delete_project_tasks',
|
||||
'function' => 'delete_tasks',
|
||||
),
|
||||
// ProjectTasks
|
||||
array(
|
||||
'module' => 'ProjectTask',
|
||||
'hook' => 'before_save',
|
||||
'order' => 1,
|
||||
'description' => 'update project end date',
|
||||
'file' => 'modules/ProjectTask/updateDependencies.php',
|
||||
'class' => 'updateDependencies',
|
||||
'function' => 'update_dependency',
|
||||
),
|
||||
array(
|
||||
'module' => 'ProjectTask',
|
||||
'hook' => 'after_save',
|
||||
'order' => 1,
|
||||
'description' => 'update project end date',
|
||||
'file' => 'modules/ProjectTask/updateProject.php',
|
||||
'class' => 'updateEndDate',
|
||||
'function' => 'update',
|
||||
),
|
||||
);
|
||||
|
||||
foreach ($hooks as $hook) {
|
||||
check_logic_hook_file($hook['module'], $hook['hook'], array($hook['order'], $hook['description'], $hook['file'], $hook['class'], $hook['function']));
|
||||
}
|
||||
}
|
61
public/legacy/install/suite_install/Reschedule.php
Normal file
61
public/legacy/install/suite_install/Reschedule.php
Normal file
|
@ -0,0 +1,61 @@
|
|||
<?php
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
function install_reschedule()
|
||||
{
|
||||
require_once('ModuleInstall/ModuleInstaller.php');
|
||||
|
||||
$hooks = array(
|
||||
//Calls
|
||||
array(
|
||||
'module' => 'Calls',
|
||||
'hook' => 'process_record',
|
||||
'order' => 1,
|
||||
'description' => 'count',
|
||||
'file' => 'modules/Calls_Reschedule/reschedule_count.php',
|
||||
'class' => 'reschedule_count',
|
||||
'function' => 'count',
|
||||
),
|
||||
);
|
||||
|
||||
foreach ($hooks as $hook) {
|
||||
check_logic_hook_file($hook['module'], $hook['hook'], array($hook['order'], $hook['description'], $hook['file'], $hook['class'], $hook['function']));
|
||||
}
|
||||
}
|
125
public/legacy/install/suite_install/Search.php
Normal file
125
public/legacy/install/suite_install/Search.php
Normal file
|
@ -0,0 +1,125 @@
|
|||
<?php
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
|
||||
require_once('modules/Administration/Administration.php');
|
||||
|
||||
/**
|
||||
* Configure defaults for the SearchWrapper.
|
||||
*/
|
||||
function install_search()
|
||||
{
|
||||
global $sugar_config;
|
||||
|
||||
$sugar_config['search']['controller'] = 'UnifiedSearch';
|
||||
$sugar_config['search']['defaultEngine'] = 'BasicSearchEngine';
|
||||
$sugar_config['search']['pagination'] = [
|
||||
'min' => 10, 'max' => 50, 'step' => 10,
|
||||
];
|
||||
|
||||
ksort($sugar_config);
|
||||
write_array_to_file('sugar_config', $sugar_config, 'config.php');
|
||||
}
|
||||
|
||||
/**
|
||||
* Configure defaults for Elasticsearch and installs logic hooks.
|
||||
*/
|
||||
function install_es()
|
||||
{
|
||||
global $sugar_config;
|
||||
|
||||
$sugar_config['search']['ElasticSearch'] = [
|
||||
'enabled' => false,
|
||||
'host' => 'localhost',
|
||||
'user' => '',
|
||||
'pass' => '',
|
||||
];
|
||||
|
||||
ksort($sugar_config);
|
||||
write_array_to_file('sugar_config', $sugar_config, 'config.php');
|
||||
|
||||
installESHooks();
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets up the Elasticsearch logic hooks.
|
||||
*/
|
||||
function installESHooks()
|
||||
{
|
||||
require_once('ModuleInstall/ModuleInstaller.php');
|
||||
|
||||
$hooks = [
|
||||
[
|
||||
'module' => '',
|
||||
'hook' => 'after_save',
|
||||
'order' => 1,
|
||||
'description' => 'ElasticSearch Index Changes',
|
||||
'file' => 'lib/Search/ElasticSearch/ElasticSearchHooks.php',
|
||||
'class' => 'SuiteCRM\Search\ElasticSearch\ElasticSearchHooks',
|
||||
'function' => 'beanSaved',
|
||||
],
|
||||
[
|
||||
'module' => '',
|
||||
'hook' => 'after_delete',
|
||||
'order' => 1,
|
||||
'description' => 'ElasticSearch Index Changes',
|
||||
'file' => 'lib/Search/ElasticSearch/ElasticSearchHooks.php',
|
||||
'class' => 'SuiteCRM\Search\ElasticSearch\ElasticSearchHooks',
|
||||
'function' => 'beanDeleted',
|
||||
],
|
||||
];
|
||||
|
||||
foreach ($hooks as $hook) {
|
||||
check_logic_hook_file(
|
||||
$hook['module'],
|
||||
$hook['hook'],
|
||||
[
|
||||
$hook['order'],
|
||||
$hook['description'],
|
||||
$hook['file'],
|
||||
$hook['class'],
|
||||
$hook['function'],
|
||||
]
|
||||
);
|
||||
}
|
||||
}
|
99
public/legacy/install/suite_install/SecurityGroups.php
Executable file
99
public/legacy/install/suite_install/SecurityGroups.php
Executable file
|
@ -0,0 +1,99 @@
|
|||
<?php
|
||||
|
||||
function install_ss()
|
||||
{
|
||||
//eggsurplus: set up default config options
|
||||
|
||||
require_once('sugar_version.php');
|
||||
require_once('modules/Administration/Administration.php');
|
||||
global $sugar_config;
|
||||
|
||||
/** If this is the first install set some default settings */
|
||||
if (!array_key_exists('securitysuite_additive', $sugar_config)) {
|
||||
// save securitysuite_additive setting
|
||||
$sugar_config['securitysuite_additive'] = true;
|
||||
// save securitysuite_user_role_precedence setting
|
||||
$sugar_config['securitysuite_user_role_precedence'] = true;
|
||||
// save securitysuite_user_popup setting
|
||||
$sugar_config['securitysuite_user_popup'] = true;
|
||||
// save securitysuite_popup_select setting
|
||||
$sugar_config['securitysuite_popup_select'] = false;
|
||||
// save securitysuite_inherit_creator setting
|
||||
$sugar_config['securitysuite_inherit_creator'] = true;
|
||||
// save securitysuite_inherit_parent setting
|
||||
$sugar_config['securitysuite_inherit_parent'] = true;
|
||||
// save securitysuite_inherit_assigned setting
|
||||
$sugar_config['securitysuite_inherit_assigned'] = true;
|
||||
// save securitysuite_strict_rights setting
|
||||
$sugar_config['securitysuite_strict_rights'] = false;
|
||||
|
||||
//ksort($sugar_config);
|
||||
//write_array_to_file('sugar_config', $sugar_config, 'config.php');
|
||||
}
|
||||
|
||||
if (!array_key_exists('securitysuite_strict_rights', $sugar_config)) {
|
||||
// save securitysuite_strict_rights setting
|
||||
$sugar_config['securitysuite_strict_rights'] = true;
|
||||
|
||||
//ksort($sugar_config);
|
||||
//write_array_to_file('sugar_config', $sugar_config, 'config.php');
|
||||
}
|
||||
|
||||
if (!array_key_exists('securitysuite_filter_user_list', $sugar_config)) {
|
||||
// save securitysuite_filter_user_list setting
|
||||
$sugar_config['securitysuite_filter_user_list'] = false;
|
||||
|
||||
//ksort($sugar_config);
|
||||
//write_array_to_file('sugar_config', $sugar_config, 'config.php');
|
||||
}
|
||||
|
||||
if (!isset($GLOBALS['sugar_config']['addAjaxBannedModules'])) {
|
||||
$GLOBALS['sugar_config']['addAjaxBannedModules'] = array();
|
||||
}
|
||||
$GLOBALS['sugar_config']['addAjaxBannedModules'][] = 'SecurityGroups';
|
||||
|
||||
$sugar_config['securitysuite_version'] = '6.5.17';
|
||||
ksort($sugar_config);
|
||||
write_array_to_file('sugar_config', $sugar_config, 'config.php');
|
||||
|
||||
installSSHooks();
|
||||
}
|
||||
|
||||
function installSSHooks()
|
||||
{
|
||||
require_once('ModuleInstall/ModuleInstaller.php');
|
||||
|
||||
$hooks = array(
|
||||
array(
|
||||
'module' => '',
|
||||
'hook' => 'after_ui_footer',
|
||||
'order' => 10,
|
||||
'description' => 'popup_onload',
|
||||
'file' => 'modules/SecurityGroups/AssignGroups.php',
|
||||
'class' => 'AssignGroups',
|
||||
'function' => 'popup_onload',
|
||||
),
|
||||
array(
|
||||
'module' => '',
|
||||
'hook' => 'after_ui_frame',
|
||||
'order' => 20,
|
||||
'description' => 'mass_assign',
|
||||
'file' => 'modules/SecurityGroups/AssignGroups.php',
|
||||
'class' => 'AssignGroups',
|
||||
'function' => 'mass_assign',
|
||||
),
|
||||
array(
|
||||
'module' => '',
|
||||
'hook' => 'after_save',
|
||||
'order' => 30,
|
||||
'description' => 'popup_select',
|
||||
'file' => 'modules/SecurityGroups/AssignGroups.php',
|
||||
'class' => 'AssignGroups',
|
||||
'function' => 'popup_select',
|
||||
),
|
||||
);
|
||||
|
||||
foreach ($hooks as $hook) {
|
||||
check_logic_hook_file($hook['module'], $hook['hook'], array($hook['order'], $hook['description'], $hook['file'], $hook['class'], $hook['function']));
|
||||
}
|
||||
}
|
60
public/legacy/install/suite_install/Social.php
Normal file
60
public/legacy/install/suite_install/Social.php
Normal file
|
@ -0,0 +1,60 @@
|
|||
<?php
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
function install_social()
|
||||
{
|
||||
require_once('ModuleInstall/ModuleInstaller.php');
|
||||
|
||||
$hooks = array(
|
||||
array(
|
||||
'module' => '',
|
||||
'hook' => 'after_ui_frame',
|
||||
'order' => 1,
|
||||
'description' => 'Load Social JS',
|
||||
'file' => 'include/social/hooks.php',
|
||||
'class' => 'hooks',
|
||||
'function' => 'load_js',
|
||||
),
|
||||
);
|
||||
|
||||
foreach ($hooks as $hook) {
|
||||
check_logic_hook_file($hook['module'], $hook['hook'], array($hook['order'], $hook['description'], $hook['file'], $hook['class'], $hook['function']));
|
||||
}
|
||||
}
|
121
public/legacy/install/suite_install/SystemEmailTemplates.php
Normal file
121
public/legacy/install/suite_install/SystemEmailTemplates.php
Normal file
|
@ -0,0 +1,121 @@
|
|||
<?php
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
/**
|
||||
* Install System Email Templates
|
||||
*/
|
||||
function installSystemEmailTemplates()
|
||||
{
|
||||
require_once __DIR__ . '/../../modules/EmailTemplates/EmailTemplate.php';
|
||||
global $sugar_config;
|
||||
|
||||
$templates = getSystemEmailTemplates();
|
||||
foreach ($templates as $configKey => $templateData) {
|
||||
if (
|
||||
isset($sugar_config['system_email_templates'])
|
||||
&& isset($sugar_config['system_email_templates'][$configKey . "_id"])
|
||||
&& !empty($sugar_config['system_email_templates'][$configKey . "_id"])
|
||||
) {
|
||||
continue;
|
||||
}
|
||||
|
||||
$template = BeanFactory::newBean('EmailTemplates');
|
||||
foreach ($templateData as $field => $value) {
|
||||
$template->$field = $value;
|
||||
}
|
||||
$template->save();
|
||||
$sugar_config['system_email_templates'][$configKey . "_id"] = $template->id;
|
||||
}
|
||||
|
||||
ksort($sugar_config);
|
||||
write_array_to_file('sugar_config', $sugar_config, 'config.php');
|
||||
}
|
||||
|
||||
/**
|
||||
* upgrade System Email Templates
|
||||
*/
|
||||
function upgradeSystemEmailTemplates()
|
||||
{
|
||||
installSystemEmailTemplates();
|
||||
}
|
||||
|
||||
function setSystemEmailTemplatesDefaultConfig()
|
||||
{
|
||||
global $sugar_config;
|
||||
|
||||
|
||||
// set confirm_opt_in_template
|
||||
if (
|
||||
isset($sugar_config['system_email_templates'])
|
||||
&& isset($sugar_config['system_email_templates']['confirm_opt_in_template' . "_id"])
|
||||
&& isset($sugar_config['email_enable_confirm_opt_in'])
|
||||
) {
|
||||
$sugar_config['email_confirm_opt_in_email_template_id'] =
|
||||
$sugar_config['system_email_templates']['confirm_opt_in_template' . "_id"];
|
||||
}
|
||||
|
||||
ksort($sugar_config);
|
||||
write_array_to_file('sugar_config', $sugar_config, 'config.php');
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return array
|
||||
*/
|
||||
function getSystemEmailTemplates()
|
||||
{
|
||||
$templates = array();
|
||||
$templates['confirm_opt_in_template'] = array(
|
||||
'name' => 'Confirmed Opt In',
|
||||
'published' => 'off',
|
||||
'description' => 'Email template to send to a contact to confirm they have opted in.',
|
||||
'subject' => 'Confirm Opt In',
|
||||
'type' => 'system',
|
||||
'body' => 'Hi $contact_first_name $contact_last_name, \n Please confirm that you have opted in by selecting the following link: $sugarurl/index.php?entryPoint=ConfirmOptIn&from=$emailaddress_email_address',
|
||||
'body_html' =>
|
||||
'<p>Hi $contact_first_name $contact_last_name,</p>
|
||||
<p>
|
||||
Please confirm that you have opted in by selecting the following link:
|
||||
<a href="$sugarurl/index.php?entryPoint=ConfirmOptIn&from=$emailaddress_confirm_opt_in_token">Opt In</a>
|
||||
</p>'
|
||||
);
|
||||
|
||||
return $templates;
|
||||
}
|
15
public/legacy/install/suite_install/collations.php
Normal file
15
public/legacy/install/suite_install/collations.php
Normal file
|
@ -0,0 +1,15 @@
|
|||
<?php
|
||||
|
||||
$collations = array(
|
||||
'mysql' =>
|
||||
array(
|
||||
array(
|
||||
'name' => 'utf8_general_ci',
|
||||
'charset' => 'utf8',
|
||||
),
|
||||
array(
|
||||
'name' => 'utf8mb4_general_ci',
|
||||
'charset' => 'utf8mb4',
|
||||
),
|
||||
),
|
||||
);
|
39
public/legacy/install/suite_install/enabledTabs.php
Normal file
39
public/legacy/install/suite_install/enabledTabs.php
Normal file
|
@ -0,0 +1,39 @@
|
|||
<?php
|
||||
|
||||
$enabled_tabs = array();
|
||||
$enabled_tabs[] = 'Home';
|
||||
$enabled_tabs[] = 'Accounts';
|
||||
$enabled_tabs[] = 'Contacts';
|
||||
$enabled_tabs[] = 'Opportunities';
|
||||
$enabled_tabs[] = 'Leads';
|
||||
$enabled_tabs[] = 'AOS_Quotes';
|
||||
$enabled_tabs[] = 'Calendar';
|
||||
$enabled_tabs[] = 'Documents';
|
||||
$enabled_tabs[] = 'Emails';
|
||||
$enabled_tabs[] = 'Campaigns';
|
||||
$enabled_tabs[] = 'Calls';
|
||||
$enabled_tabs[] = 'Meetings';
|
||||
$enabled_tabs[] = 'Tasks';
|
||||
$enabled_tabs[] = 'Notes';
|
||||
$enabled_tabs[] = 'AOS_Invoices';
|
||||
$enabled_tabs[] = 'AOS_Contracts';
|
||||
$enabled_tabs[] = 'Cases';
|
||||
$enabled_tabs[] = 'Prospects';
|
||||
$enabled_tabs[] = 'ProspectLists';
|
||||
$enabled_tabs[] = 'Project';
|
||||
$enabled_tabs[] = 'AM_ProjectTemplates';
|
||||
$enabled_tabs[] = 'AM_TaskTemplates';
|
||||
$enabled_tabs[] = 'FP_events';
|
||||
$enabled_tabs[] = 'FP_Event_Locations';
|
||||
$enabled_tabs[] = 'AOS_Products';
|
||||
$enabled_tabs[] = 'AOS_Product_Categories';
|
||||
$enabled_tabs[] = 'AOS_PDF_Templates';
|
||||
$enabled_tabs[] = 'jjwg_Maps';
|
||||
$enabled_tabs[] = 'jjwg_Markers';
|
||||
$enabled_tabs[] = 'jjwg_Areas';
|
||||
$enabled_tabs[] = 'jjwg_Address_Cache';
|
||||
$enabled_tabs[] = 'AOR_Reports';
|
||||
$enabled_tabs[] = 'AOW_WorkFlow';
|
||||
$enabled_tabs[] = 'AOK_KnowledgeBase';
|
||||
$enabled_tabs[] = 'AOK_Knowledge_Base_Categories';
|
||||
$enabled_tabs[] = 'EmailTemplates';
|
120
public/legacy/install/suite_install/scenarios.php
Executable file
120
public/legacy/install/suite_install/scenarios.php
Executable file
|
@ -0,0 +1,120 @@
|
|||
<?php
|
||||
global $app_strings;
|
||||
if ($app_strings === null) {
|
||||
$app_strings = return_application_language($current_language);
|
||||
}
|
||||
|
||||
$installation_scenarios = array(
|
||||
0 =>
|
||||
array(
|
||||
'key' => 'Sales',
|
||||
'title' => $app_strings['LBL_SCENARIO_SALES'],
|
||||
'description' => $app_strings['LBL_SCENARIO_SALES_DESCRIPTION'],
|
||||
'groupedTabs'=> 'LBL_TABGROUP_SALES',
|
||||
'modules' =>
|
||||
array(
|
||||
0 => 'Opportunities',
|
||||
1 => 'Leads'
|
||||
),
|
||||
'modulesScenarioDisplayName' =>
|
||||
array(
|
||||
0 => $app_strings['LBL_OPPORTUNITIES'],
|
||||
1 => $app_strings['LBL_LEADS']
|
||||
),
|
||||
'dashlets'=>
|
||||
array(
|
||||
0 => 'MyOpportunitiesDashlet',
|
||||
1 => 'MyLeadsDashlet'
|
||||
)
|
||||
),
|
||||
1 =>
|
||||
array(
|
||||
'key' => 'Marketing',
|
||||
'title' => $app_strings['LBL_SCENARIO_MARKETING'],
|
||||
'description' => $app_strings['LBL_SCENARIO_MAKETING_DESCRIPTION'],
|
||||
'groupedTabs'=> 'LBL_TABGROUP_MARKETING',
|
||||
'modules' =>
|
||||
array(
|
||||
0 => 'Prospects', //Not enabled by default
|
||||
1 => 'ProspectLists', //Not enabled by default
|
||||
2 => 'Campaigns',
|
||||
3 => 'FP_events',
|
||||
4 => 'FP_Event_Locations'
|
||||
),
|
||||
'modulesScenarioDisplayName' =>
|
||||
array(
|
||||
0 => 'Targets',
|
||||
1 => 'Target Lists',
|
||||
2 => 'Campaigns',
|
||||
3 => 'Events',
|
||||
4 => 'Event Locations'
|
||||
),
|
||||
'dashlets'=>array()
|
||||
),
|
||||
2 =>
|
||||
array(
|
||||
'key' => 'Finance',
|
||||
'title' => $app_strings['LBL_SCENARIO_FINANCE'],
|
||||
'description' => $app_strings['LBL_SCENARIO_FINANCE_DESCRIPTION'],
|
||||
'groupedTabs'=> '',
|
||||
'modules' =>
|
||||
array(
|
||||
0 => 'AOS_Products',
|
||||
1 => 'AOS_Product_Categories',
|
||||
2 => 'AOS_Quotes',
|
||||
3 => 'AOS_Invoices',
|
||||
4 => 'AOS_Contracts'
|
||||
),
|
||||
'modulesScenarioDisplayName' =>
|
||||
array(
|
||||
0 => 'Products',
|
||||
1 => 'Product_Categories',
|
||||
2 => 'Quotes',
|
||||
3 => 'Invoices',
|
||||
4 => 'Contracts'
|
||||
),
|
||||
'dashlets'=>array()
|
||||
),
|
||||
3 =>
|
||||
array(
|
||||
'key' => 'ServiceManagement',
|
||||
'title' => $app_strings['LBL_SCENARIO_SERVICE'],
|
||||
'description' => $app_strings['LBL_SCENARIO_SERVICE_DESCRIPTION'],
|
||||
'groupedTabs'=> 'LBL_TABGROUP_SUPPORT',
|
||||
'modules' =>
|
||||
array(
|
||||
0 => 'Cases',
|
||||
1 => 'AOK_KnowledgeBase',
|
||||
2 => 'AOK_Knowledge_Base_Categories' //Is this the same as Knowledge Base Articles
|
||||
),
|
||||
'modulesScenarioDisplayName' =>
|
||||
array(
|
||||
0 => 'Cases',
|
||||
1 => 'Knowledge Base',
|
||||
2 => 'Knowledge Base Categories'
|
||||
),
|
||||
'dashlets'=>array()
|
||||
),
|
||||
4 =>
|
||||
array(
|
||||
'key' => 'ProjectManagement',
|
||||
'title' => $app_strings['LBL_SCENARIO_PROJECT'],
|
||||
'description' => $app_strings['LBL_SCENARIO_PROJECT_DESCRIPTION'],
|
||||
'groupedTabs'=> '',
|
||||
'modules' =>
|
||||
array(
|
||||
0 => 'AM_TaskTemplates', //Project Task Templates'
|
||||
1 => 'Project Tasks',
|
||||
2 => 'AM_ProjectTemplates',
|
||||
3 => 'Project'
|
||||
),
|
||||
'modulesScenarioDisplayName' =>
|
||||
array(
|
||||
0 => 'Project Task Templates', //Project Task Templates'
|
||||
1 => 'Project Tasks',
|
||||
2 => 'Project Templates',
|
||||
3 => 'Project'
|
||||
),
|
||||
'dashlets'=>array()
|
||||
)
|
||||
);
|
63
public/legacy/install/suite_install/suite_install.php
Executable file
63
public/legacy/install/suite_install/suite_install.php
Executable file
|
@ -0,0 +1,63 @@
|
|||
<?php
|
||||
|
||||
require_once('sugar_version.php');
|
||||
require_once('suitecrm_version.php');
|
||||
|
||||
global $sugar_config;
|
||||
$sugar_config['default_max_tabs'] = 8;
|
||||
$sugar_config['suitecrm_version'] = $suitecrm_version;
|
||||
$sugar_config['sugar_version'] = $sugar_version;
|
||||
$sugar_config['sugarbeet'] = false;
|
||||
$sugar_config['enable_action_menu'] = true;
|
||||
|
||||
$sugar_config['search']['controller'] = 'UnifiedSearch';
|
||||
$sugar_config['search']['defaultEngine'] = 'BasicSearchEngine';
|
||||
|
||||
$sugar_config['imap_test'] = false;
|
||||
|
||||
ksort($sugar_config);
|
||||
write_array_to_file('sugar_config', $sugar_config, 'config.php');
|
||||
|
||||
require_once('modules/Administration/updater_utils.php');
|
||||
set_CheckUpdates_config_setting('manual');
|
||||
|
||||
|
||||
require_once('install/suite_install/AdvancedOpenSales.php');
|
||||
install_aos();
|
||||
|
||||
require_once('install/suite_install/AdvancedOpenPortal.php');
|
||||
install_aop();
|
||||
|
||||
require_once('install/suite_install/AdvancedOpenDiscovery.php');
|
||||
install_aod();
|
||||
|
||||
require_once('install/suite_install/AdvancedOpenEvents.php');
|
||||
install_aoe();
|
||||
|
||||
require_once('install/suite_install/Search.php');
|
||||
install_search();
|
||||
install_es();
|
||||
|
||||
require_once('install/suite_install/Projects.php');
|
||||
install_projects();
|
||||
|
||||
require_once('install/suite_install/Reschedule.php');
|
||||
install_reschedule();
|
||||
|
||||
require_once('install/suite_install/SecurityGroups.php');
|
||||
install_ss();
|
||||
|
||||
require_once('install/suite_install/GoogleMaps.php');
|
||||
install_gmaps();
|
||||
|
||||
require_once('install/suite_install/Social.php');
|
||||
install_social();
|
||||
|
||||
require_once('install/suite_install/SystemEmailTemplates.php');
|
||||
installSystemEmailTemplates();
|
||||
setSystemEmailTemplatesDefaultConfig();
|
||||
|
||||
require_once('modules/Administration/QuickRepairAndRebuild.php');
|
||||
$actions = array('clearAll');
|
||||
$randc = new RepairAndClear();
|
||||
$randc->repairAndClearAll($actions, array(translate('LBL_ALL_MODULES')), true, false);
|
354
public/legacy/install/welcome.php
Executable file
354
public/legacy/install/welcome.php
Executable file
|
@ -0,0 +1,354 @@
|
|||
<?php
|
||||
if (!defined('sugarEntry') || !sugarEntry) {
|
||||
die('Not A Valid Entry Point');
|
||||
}
|
||||
/**
|
||||
*
|
||||
* SugarCRM Community Edition is a customer relationship management program developed by
|
||||
* SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
|
||||
*
|
||||
* SuiteCRM is an extension to SugarCRM Community Edition developed by SalesAgility Ltd.
|
||||
* Copyright (C) 2011 - 2018 SalesAgility Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it under
|
||||
* the terms of the GNU Affero General Public License version 3 as published by the
|
||||
* Free Software Foundation with the addition of the following permission added
|
||||
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
|
||||
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
|
||||
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
|
||||
*
|
||||
* 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 Affero General Public License for more
|
||||
* details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License along with
|
||||
* this program; if not, see http://www.gnu.org/licenses or write to the Free
|
||||
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA.
|
||||
*
|
||||
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
|
||||
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
|
||||
*
|
||||
* The interactive user interfaces in modified source and object code versions
|
||||
* of this program must display Appropriate Legal Notices, as required under
|
||||
* Section 5 of the GNU Affero General Public License version 3.
|
||||
*
|
||||
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
|
||||
* these Appropriate Legal Notices must retain the display of the "Powered by
|
||||
* SugarCRM" logo and "Supercharged by SuiteCRM" logo. If the display of the logos is not
|
||||
* reasonably feasible for technical reasons, the Appropriate Legal Notices must
|
||||
* display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM".
|
||||
*/
|
||||
|
||||
if (!isset($install_script) || !$install_script) {
|
||||
die($mod_strings['ERR_NO_DIRECT_SCRIPT']);
|
||||
}
|
||||
// $mod_strings come from calling page.
|
||||
|
||||
$langDropDown = get_select_options_with_id($supportedLanguages, $current_language);
|
||||
|
||||
|
||||
|
||||
|
||||
$_SESSION['setup_license_accept'] = get_boolean_from_request('setup_license_accept');
|
||||
$_SESSION['license_submitted'] = true;
|
||||
|
||||
// setup session variables (and their defaults) if this page has not yet been submitted
|
||||
if (!isset($_SESSION['license_submitted']) || !$_SESSION['license_submitted']) {
|
||||
$_SESSION['setup_license_accept'] = false;
|
||||
}
|
||||
|
||||
$checked = (isset($_SESSION['setup_license_accept']) && !empty($_SESSION['setup_license_accept'])) ? 'checked="on"' : '';
|
||||
|
||||
require_once("install/install_utils.php");
|
||||
$license_file = getLicenseContents("LICENSE.txt");
|
||||
$langHeader = get_language_header();
|
||||
|
||||
|
||||
// load javascripts
|
||||
include('jssource/JSGroupings.php');
|
||||
$jsSrc = '';
|
||||
foreach ($sugar_grp1_yui as $jsFile => $grp) {
|
||||
$jsSrc .= "\t<script src=\"$jsFile\"></script>\n";
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
//// START OUTPUT
|
||||
|
||||
$langHeader = get_language_header();
|
||||
$out = <<<EOQ
|
||||
<!DOCTYPE HTML>
|
||||
<html {$langHeader}>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="Content-Style-Type" content="text/css">
|
||||
<meta content='width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0' name='viewport' />
|
||||
<title>{$mod_strings['LBL_WIZARD_TITLE']} {$mod_strings['LBL_TITLE_WELCOME']} {$setup_sugar_version} {$mod_strings['LBL_WELCOME_SETUP_WIZARD']}, {$mod_strings['LBL_LICENSE_ACCEPTANCE']}</title>
|
||||
<link REL="SHORTCUT ICON" HREF="include/images/sugar_icon.ico">
|
||||
<link rel="stylesheet" href="install/install2.css" type="text/css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/responsiveslides.css" type="text/css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/themes.css" type="text/css">
|
||||
<script src="include/javascript/jquery/jquery-min.js"></script>
|
||||
<script src="themes/suite8/js/responsiveslides.min.js"></script>
|
||||
$jsSrc
|
||||
<script type="text/javascript">
|
||||
<!--
|
||||
if ( YAHOO.env.ua )
|
||||
UA = YAHOO.env.ua;
|
||||
-->
|
||||
</script>
|
||||
<link rel='stylesheet' type='text/css' href='include/javascript/yui/build/container/assets/container.css' />
|
||||
<script type="text/javascript" src="install/license.js"></script>
|
||||
<link rel="stylesheet" href="themes/suite8/css/fontello.css">
|
||||
<link rel="stylesheet" href="themes/suite8/css/animation.css"><!--[if IE 7]><link rel="stylesheet" href="css/fontello-ie7.css"><![endif]-->
|
||||
<style>
|
||||
/*
|
||||
#install_box {
|
||||
max-width: 1000px;
|
||||
margin: 20px auto;
|
||||
}
|
||||
*/
|
||||
</style>
|
||||
</head>
|
||||
<body onload="javascript:toggleNextButton();document.getElementById('button_next2').focus();">
|
||||
<!--SuiteCRM installer-->
|
||||
<div id="install_container">
|
||||
<div id="install_box">
|
||||
<form action="install.php" method="post" name="setConfig" id="form">
|
||||
<header id="install_header">
|
||||
<h1 id="welcomelink">{$mod_strings['LBL_TITLE_WELCOME']} {$setup_sugar_version} {$mod_strings['LBL_WELCOME_SETUP_WIZARD']}</h1>
|
||||
<div class="install_img"><a href="https://suitecrm.com" target="_blank"><img src="{$sugar_md}" alt="SuiteCRM"></a></div>
|
||||
</header>
|
||||
<div id="wrapper" style="display:none;">
|
||||
<div class="rslides_container">
|
||||
<ul class="rslides" id="slider2">
|
||||
<li><img src="themes/suite8/images/SuiteScreen1.png" alt="" class="sliderimg"></li>
|
||||
<li><img src="themes/suite8/images/SuiteScreen2.png" alt="" class="sliderimg"></li>
|
||||
<li><img src="themes/suite8/images/SuiteScreen3.png" alt="" class="sliderimg"></li>
|
||||
<li><img src="themes/suite8/images/SuiteScreen4.png" alt="" class="sliderimg"></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!--
|
||||
<div id='licenseDivToggler' style="text-align: center;"><a href="javascript:void(0);" onclick="javascript:$('#licenseDiv').toggle();">Show Software License</a></div>
|
||||
-->
|
||||
<div id="content">
|
||||
<div id='licenseDiv' style="/* display: none; */">
|
||||
<textarea class="licensetext" cols="80" rows="20" readonly>{$license_file}</textarea>
|
||||
</div>
|
||||
<div id="licenseaccept">
|
||||
<input type="checkbox" class="checkbox" name="setup_license_accept" id="button_next2" onClick='toggleNextButton();' {$checked} />
|
||||
<a href='javascript:void(0)' onClick='toggleLicenseAccept();toggleNextButton();'>{$mod_strings['LBL_LICENSE_I_ACCEPT']}</a>
|
||||
<input type="button" class="button" name="print_license" id="button_print_license" value="{$mod_strings['LBL_LICENSE_PRINTABLE']}"
|
||||
onClick='window.open("install.php?page=licensePrint&language={$current_language}");' />
|
||||
</div>
|
||||
</div>
|
||||
<hr>
|
||||
<div id="installcontrols">
|
||||
|
||||
<input type="hidden" name="current_step" value="{$next_step}">
|
||||
{$mod_strings['LBL_WELCOME_CHOOSE_LANGUAGE']}: <select name="language" onchange='onLangSelect(this);';>{$langDropDown}</select>
|
||||
<input class="acceptButton" type="button" name="goto" value="{$mod_strings['LBL_NEXT']}" id="button_next" disabled="disabled" title="{$mod_strings['LBL_LICENCE_TOOLTIP']}" onclick="callSysCheck();"/>
|
||||
<input type="hidden" name="goto" id='hidden_goto' value="{$mod_strings['LBL_BACK']}" />
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</form>
|
||||
<div style="clear:both;"></div>
|
||||
<div id='sysCheckMsg'></div>
|
||||
<div style="clear:both;"></div>
|
||||
</div>
|
||||
<div id="checkingDiv" style="display:none">
|
||||
<!-- <table cellspacing='0' cellpadding='0' border='0' align='center'><tr><td> -->
|
||||
<p><img src='install/processing.gif' alt="{$mod_strings['LBL_LICENSE_CHECKING']}"> <br>{$mod_strings['LBL_LICENSE_CHECKING']}</p>
|
||||
<!-- </td></tr></table> -->
|
||||
</div>
|
||||
<footer id="install_footer">
|
||||
<p id="footer_links"><a href="https://suitecrm.com" target="_blank">Visit suitecrm.com</a> | <a href="https://suitecrm.com/suitecrm/forum" target="_blank">Support Forums</a> | <a href="https://docs.suitecrm.com/admin/installation-guide/" target="_blank">Installation Guide</a> | <a href="LICENSE.txt" target="_blank">License</a>
|
||||
</footer>
|
||||
</div>
|
||||
<script>
|
||||
function showtime(div){
|
||||
|
||||
if(document.getElementById(div).style.display == ''){
|
||||
document.getElementById(div).style.display = 'none';
|
||||
document.getElementById('adv_'+div).style.display = '';
|
||||
document.getElementById('basic_'+div).style.display = 'none';
|
||||
}
|
||||
else {
|
||||
document.getElementById(div).style.display = '';
|
||||
document.getElementById('adv_'+div).style.display = 'none';
|
||||
document.getElementById('basic_'+div).style.display = '';
|
||||
}
|
||||
|
||||
}
|
||||
</script>
|
||||
<script>
|
||||
$(".rslides").responsiveSlides({
|
||||
auto: true, // Boolean: Animate automatically, true or false
|
||||
speed: 800, // Integer: Speed of the transition, in milliseconds
|
||||
timeout: 6000, // Integer: Time between slide transitions, in milliseconds
|
||||
pager: false, // Boolean: Show pager, true or false
|
||||
random: false, // Boolean: Randomize the order of the slides, true or false
|
||||
pause: false, // Boolean: Pause on hover, true or false
|
||||
pauseControls: true, // Boolean: Pause when hovering controls, true or false
|
||||
prevText: "", // String: Text for the "previous" button
|
||||
nextText: "", // String: Text for the "next" button
|
||||
maxwidth: "", // Integer: Max-width of the slideshow, in pixels
|
||||
navContainer: "ul", // Selector: Where controls should be appended to, default is after the 'ul'
|
||||
manualControls: "", // Selector: Declare custom pager navigation
|
||||
namespace: "rslides", // String: Change the default namespace used
|
||||
before: function(){}, // Function: Before callback
|
||||
after: function(){} // Function: After callback
|
||||
});
|
||||
$("#slider2").responsiveSlides({
|
||||
nav: true,
|
||||
speed: 500,
|
||||
//maxwidth: 750,
|
||||
namespace: "centered-btns",
|
||||
speed: 800, // Integer: Speed of the transition, in milliseconds
|
||||
timeout: 6000, // Integer: Time between slide transitions, in milliseconds
|
||||
});
|
||||
</script>
|
||||
|
||||
<script>
|
||||
var msgPanel;
|
||||
function callSysCheck(){
|
||||
|
||||
//begin main function that will be called
|
||||
ajaxCall = function(msg_panel){
|
||||
//create success function for callback
|
||||
|
||||
getPanel = function() {
|
||||
var args = { width:"300px",
|
||||
modal:true,
|
||||
fixedcenter: true,
|
||||
constraintoviewport: false,
|
||||
underlay:"shadow",
|
||||
close:false,
|
||||
draggable:true,
|
||||
|
||||
effect:{effect:YAHOO.widget.ContainerEffect.FADE, duration:.5},
|
||||
zindex: 1000
|
||||
} ;
|
||||
msg_panel = new YAHOO.widget.Panel('p_msg', args);
|
||||
//If we haven't built our panel using existing markup,
|
||||
//we can set its content via script:
|
||||
msg_panel.setHeader("{$mod_strings['LBL_LICENSE_CHKENV_HEADER']}");
|
||||
msg_panel.setBody(document.getElementById("checkingDiv").innerHTML);
|
||||
msg_panel.render(document.body);
|
||||
msgPanel = msg_panel;
|
||||
}
|
||||
|
||||
|
||||
passed = function(url){
|
||||
document.setConfig.goto.value="{$mod_strings['LBL_NEXT']}";
|
||||
document.getElementById('hidden_goto').value="{$mod_strings['LBL_NEXT']}";
|
||||
document.setConfig.current_step.value="{$next_step}";
|
||||
document.setConfig.submit();
|
||||
window.focus();
|
||||
}
|
||||
success = function(o) {
|
||||
if (o.responseText.indexOf('passed')>=0){
|
||||
if ( YAHOO.util.Selector.query('button', 'p_msg', true) != null )
|
||||
YAHOO.util.Selector.query('button', 'p_msg', true).style.display = 'none';
|
||||
//scsbody = "<table cellspacing='0' cellpadding='0' border='0' align='center'><tr><td>";
|
||||
scsbody = '<h1>{$mod_strings['LBL_LICENSE_CHKENV_HEADER']}</h1>';
|
||||
scsbody += "<p><img src='install/processing.gif' alt=\"{$mod_strings['LBL_CREATE_CACHE']}\"></p>";
|
||||
scsbody += "<p>{$mod_strings['LBL_LICENSE_CHECK_PASSED']}<br>{$mod_strings['LBL_CREATE_CACHE']}</p>";
|
||||
//scsbody += "<div id='cntDown'>{$mod_strings['LBL_THREE']}</div>";
|
||||
//scsbody += "</td></tr></table>";
|
||||
//scsbody += "<script>countdown(3);<\/script>";
|
||||
//msgPanel.setBody(scsbody);
|
||||
//msgPanel.render();
|
||||
$('#content').html(scsbody);
|
||||
//countdown(3);
|
||||
//window.setTimeout('passed("install.php?goto=next")', 2500);
|
||||
passed("install.php?goto=next");
|
||||
|
||||
}else{
|
||||
//turn off loading message
|
||||
//msgPanel.hide();
|
||||
$('#content p').remove();
|
||||
document.getElementById('sysCheckMsg').style.display = '';
|
||||
/* document.getElementById('licenseDiv').style.display = 'none'; */
|
||||
document.getElementById('sysCheckMsg').innerHTML=o.responseText;
|
||||
}
|
||||
|
||||
|
||||
}//end success
|
||||
|
||||
//set loading message and create url
|
||||
postData = "checkInstallSystem=true&to_pdf=1&sugar_body_only=1";
|
||||
|
||||
//if this is a call already in progress, then just return
|
||||
if(typeof ajxProgress != 'undefined'){
|
||||
return;
|
||||
}
|
||||
|
||||
//getPanel();
|
||||
//msgPanel.show;
|
||||
|
||||
$('#content').addClass('preloading');
|
||||
$('#content').html('<h1>{$mod_strings['LBL_LICENSE_CHKENV_HEADER']}</h1>' + document.getElementById("checkingDiv").innerHTML);
|
||||
|
||||
var ajxProgress = YAHOO.util.Connect.asyncRequest('POST','install.php', {success: success, failure: success}, postData);
|
||||
|
||||
|
||||
};//end ajaxCall method
|
||||
ajaxCall();
|
||||
return;
|
||||
}
|
||||
|
||||
function countdown(num){
|
||||
//scsbody = "<table cellspacing='0' cellpadding='0' border='0' align='center'><tr><td>";
|
||||
scsbody = '<h1>{$mod_strings['LBL_LICENSE_CHKENV_HEADER']}</h1>';
|
||||
scsbody += "<p>{$mod_strings['LBL_LICENSE_CHECK_PASSED']}</p>";
|
||||
scsbody += "<div id='cntDown'>{$mod_strings['LBL_LICENSE_REDIRECT']}"+num+"</div>";
|
||||
//scsbody += "</td></tr></table>";
|
||||
//msgPanel.setBody(scsbody);
|
||||
//msgPanel.render();
|
||||
$('#content').html(scsbody);
|
||||
if(num >0){
|
||||
num = num-1;
|
||||
setTimeout("countdown("+num+")",1000);
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<script>
|
||||
function onLangSelect(e) {
|
||||
$("input[name=current_step]").attr('name', '_current_step');
|
||||
$("input[name=goto]").attr('name', '_goto');
|
||||
e.form.submit();
|
||||
}
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
EOQ;
|
||||
if (check_php_version() === -1) {
|
||||
if (empty($mod_strings['LBL_MINIMUM_PHP_VERSION'])) {
|
||||
$mod_strings['LBL_MINIMUM_PHP_VERSION'] = 'The minimum PHP version required is '.constant('SUITECRM_PHP_MIN_VERSION');
|
||||
}
|
||||
|
||||
$php_verison_warning =<<<eoq
|
||||
<table width="100%" cellpadding="0" cellpadding="0" border="0" class="Welcome">
|
||||
<tr>
|
||||
<td colspan="2" align="center" id="ready_image"><IMG src="include/images/install_themes.jpg" width="698" height="190" alt="Sugar Themes" border="0"></td>
|
||||
</tr>
|
||||
<th colspan="2" align="center">
|
||||
<h1><span class='error'><b>{$mod_strings['LBL_MINIMUM_PHP_VERSION']}</b></span></h1>
|
||||
</th>
|
||||
<tr>
|
||||
<td colspan="2" align="center" id="ready_image"><IMG src="include/images/install_themes.jpg" width="698" height="190" alt="Sugar Themes" border="0"></td>
|
||||
</tr>
|
||||
</table>
|
||||
eoq;
|
||||
$out = $php_verison_warning;
|
||||
}
|
||||
echo $out;
|
Loading…
Add table
Add a link
Reference in a new issue