本文整理汇总了PHP中Configurations::getSystemDate方法的典型用法代码示例。如果您正苦于以下问题:PHP Configurations::getSystemDate方法的具体用法?PHP Configurations::getSystemDate怎么用?PHP Configurations::getSystemDate使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Configurations
的用法示例。
在下文中一共展示了Configurations::getSystemDate方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: Step
$oHeadPublisher->assign('FORMATS', $conf->getFormats());
$uri = '';
foreach ($_GET as $k => $v) {
$uri .= $uri == '' ? "{$k}={$v}" : "&{$k}={$v}";
}
//$case = $oCase->loadCase( $_GET['APP_UID'], $_GET['DEL_INDEX'] );
if (isset($_GET['action']) && $_GET['action'] == 'jump') {
$case = $oCase->loadCase($_GET['APP_UID'], $_GET['DEL_INDEX'], $_GET['action']);
} else {
$case = $oCase->loadCase($_GET['APP_UID'], $_GET['DEL_INDEX']);
}
if (!isset($_GET['to_revise'])) {
$script = 'cases_Open?';
} else {
$script = 'cases_OpenToRevise?';
$delIndex = $_GET['DEL_INDEX'];
$appUid = $_GET['APP_UID'];
$oHeadPublisher->assign('treeToReviseTitle', G::loadtranslation('ID_STEP_LIST'));
$casesPanelUrl = 'casesToReviseTreeContent?APP_UID=' . $appUid . '&DEL_INDEX=' . $delIndex;
$oHeadPublisher->assign('casesPanelUrl', $casesPanelUrl);
//translations
echo "<div id='toReviseTree'></div>";
}
$oStep = new Step();
$oStep = $oStep->loadByProcessTaskPosition($case['PRO_UID'], $case['TAS_UID'], 1);
$oHeadPublisher->assign('uri', $script . $uri);
$oHeadPublisher->assign('_APP_NUM', '#: ' . $case['APP_NUMBER']);
$oHeadPublisher->assign('_ENV_CURRENT_DATE', $conf->getSystemDate(date('Y-m-d')));
$oHeadPublisher->assign('_ENV_CURRENT_DATE_NO_FORMAT', date('Y-m-d-h-i-A'));
$oHeadPublisher->assign('idfirstform', is_null($oStep) ? '' : $oStep->getStepUidObj());
G::RenderPage('publish', 'extJs');
示例2: _default
//.........这里部分代码省略.........
$freeOfChargeText = "";
if (!defined('SKIP_FREE_OF_CHARGE_TEXT')) {
$freeOfChargeText = "Supplied free of charge with no support, certification, warranty, <br>maintenance nor indemnity by Colosa and its Certified Partners.";
}
if (class_exists('pmLicenseManager')) {
$freeOfChargeText = "";
}
$fileFooter = PATH_SKINS . SYS_SKIN . PATH_SEP . 'footer.html';
if (file_exists($fileFooter)) {
$footer .= file_get_contents($fileFooter);
} else {
$fileFooter = PATH_SKIN_ENGINE . SYS_SKIN . PATH_SEP . 'footer.html';
if (file_exists($fileFooter)) {
$footer .= file_get_contents($fileFooter);
} else {
$fileFooter = PATH_CUSTOM_SKINS . SYS_SKIN . PATH_SEP . 'footer.html';
if (file_exists($fileFooter)) {
$footer .= file_get_contents($fileFooter);
} else {
$footer .= "<br />Copyright © 2003-" . date('Y') . " <a href=\"http://www.colosa.com\" alt=\"Colosa, Inc.\" target=\"_blank\">Colosa, Inc.</a> All rights reserved.<br /> {$freeOfChargeText} " . "<br><br/><a href=\"http://www.processmaker.com\" alt=\"Powered by ProcessMaker - Open Source Workflow & Business Process Management (BPM) Management Software\" title=\"Powered by ProcessMaker\" target=\"_blank\"></a>";
}
}
}
}
$oMenu = new Menu();
$menus = $oMenu->generateArrayForTemplate($G_MAIN_MENU, 'SelectedMenu', 'mainMenu', $G_MENU_SELECTED, $G_ID_MENU_SELECTED);
$smarty->assign('menus', $menus);
$oSubMenu = new Menu();
$subMenus = $oSubMenu->generateArrayForTemplate($G_SUB_MENU, 'selectedSubMenu', 'subMenu', $G_SUB_MENU_SELECTED, $G_ID_SUB_MENU_SELECTED);
$smarty->assign('subMenus', $subMenus);
if (!defined('NO_DISPLAY_USERNAME')) {
define('NO_DISPLAY_USERNAME', 0);
}
if (NO_DISPLAY_USERNAME == 0) {
$switch_interface = isset($_SESSION['user_experience']) && $_SESSION['user_experience'] == 'SWITCHABLE';
$smarty->assign('user_logged', isset($_SESSION['USER_LOGGED']) ? $_SESSION['USER_LOGGED'] : '');
$smarty->assign('tracker', SYS_COLLECTION == 'tracker' ? $G_PUBLISH->Parts[0]['File'] != 'tracker/login' ? true : '' : '');
$smarty->assign('switch_interface', $switch_interface);
$smarty->assign('switch_interface_label', G::LoadTranslation('ID_SWITCH_INTERFACE'));
$smarty->assign('rolename', isset($_SESSION['USR_ROLENAME']) ? $_SESSION['USR_ROLENAME'] . '' : '');
$smarty->assign('pipe', isset($_SESSION['USR_USERNAME']) ? ' | ' : '');
$smarty->assign('logout', G::LoadTranslation('ID_LOGOUT'));
$smarty->assign('workspace', defined('SYS_SYS') ? SYS_SYS : '');
$uws = isset($_SESSION['USR_ROLENAME']) && $_SESSION['USR_ROLENAME'] != '' ? strtolower(G::LoadTranslation('ID_WORKSPACE_USING')) : G::LoadTranslation('ID_WORKSPACE_USING');
$smarty->assign('workspace_label', $uws);
G::LoadClass("configuration");
$conf = new Configurations();
$conf->getFormats();
if (defined('SYS_SYS')) {
$smarty->assign('udate', $conf->getSystemDate(date('Y-m-d H:i:s')));
} else {
$smarty->assign('udate', G::getformatedDate(date('Y-m-d H:i:s'), 'M d, yyyy', SYS_LANG));
}
$name = $conf->userNameFormat(isset($_SESSION['USR_USERNAME']) ? $_SESSION['USR_USERNAME'] : '', isset($_SESSION['USR_FULLNAME']) ? htmlentities($_SESSION['USR_FULLNAME'], ENT_QUOTES, 'UTF-8') : '', isset($_SESSION['USER_LOGGED']) ? $_SESSION['USER_LOGGED'] : '');
$smarty->assign('user', $name);
}
if (class_exists('pmLicenseManager')) {
$pmLicenseManagerO =& pmLicenseManager::getSingleton();
$expireIn = $pmLicenseManagerO->getExpireIn();
$expireInLabel = $pmLicenseManagerO->getExpireInLabel();
//if($expireIn<=30){
if ($expireInLabel != "") {
$smarty->assign('msgVer', '<label class="textBlack">' . $expireInLabel . '</label> ');
}
//}
}
if (defined('SYS_SYS')) {
$logout = '/sys' . SYS_SYS . '/' . SYS_LANG . '/' . SYS_SKIN . '/login/login';
} else {
$logout = '/sys/' . SYS_LANG . '/' . SYS_SKIN . '/login/login';
}
$smarty->assign('linklogout', $logout);
$smarty->assign('footer', $footer);
$smarty->assign('tpl_menu', PATH_TEMPLATE . 'menu.html');
$smarty->assign('tpl_submenu', PATH_TEMPLATE . 'submenu.html');
G::LoadClass('replacementLogo');
$oLogoR = new replacementLogo();
if (defined("SYS_SYS")) {
$aFotoSelect = $oLogoR->getNameLogo(isset($_SESSION['USER_LOGGED']) ? $_SESSION['USER_LOGGED'] : '');
if (is_array($aFotoSelect)) {
$sFotoSelect = trim($aFotoSelect['DEFAULT_LOGO_NAME']);
$sWspaceSelect = trim($aFotoSelect['WORKSPACE_LOGO_NAME']);
}
}
if (class_exists('PMPluginRegistry')) {
$oPluginRegistry =& PMPluginRegistry::getSingleton();
if (isset($sFotoSelect) && $sFotoSelect != '' && !strcmp($sWspaceSelect, SYS_SYS)) {
$sCompanyLogo = $oPluginRegistry->getCompanyLogo($sFotoSelect);
$sCompanyLogo = "/sys" . SYS_SYS . "/" . SYS_LANG . "/" . SYS_SKIN . "/setup/showLogoFile.php?id=" . base64_encode($sCompanyLogo);
} else {
$sCompanyLogo = $oPluginRegistry->getCompanyLogo('/images/processmaker.logo.jpg');
}
} else {
$sCompanyLogo = '/images/processmaker.logo.jpg';
}
$smarty->assign('logo_company', $sCompanyLogo);
$smarty->force_compile = $this->forceTemplateCompile;
$smarty->display($this->layoutFile['basename']);
}
}
示例3: getProcessInformation
public function getProcessInformation()
{
if (!isset($_SESSION['USER_LOGGED'])) {
$response = new stdclass();
$response->message = G::LoadTranslation('ID_LOGIN_AGAIN');
$response->lostSession = true;
print G::json_encode($response);
die;
}
$process = new Process();
$processData = $process->load($_SESSION['PROCESS']);
require_once 'classes/model/Users.php';
$user = new Users();
try {
$userData = $user->load($processData['PRO_CREATE_USER']);
$processData['PRO_AUTHOR'] = $userData['USR_FIRSTNAME'] . ' ' . $userData['USR_LASTNAME'];
} catch (Exception $oError) {
$processData['PRO_AUTHOR'] = '(USER DELETED)';
}
$conf = new Configurations();
$conf->getFormats();
$processData['PRO_CREATE_DATE'] = $conf->getSystemDate($processData['PRO_CREATE_DATE']);
print G::json_encode($processData);
}
示例4: __construct
public function __construct($flagActivatePlugins = true)
{
G::LoadClass('serverConfiguration');
$oServerConf =& serverConf::getSingleton();
$oServerConf->setProperty('LOGIN_NO_WS', true);
//to do: this files probably needs to be in core, since they are GPL2
//include_once (PATH_PLUGINS . 'enterprise' . PATH_SEP . 'classes' . PATH_SEP . 'class.license.lib.php');
//include_once (PATH_PLUGINS . 'enterprise' . PATH_SEP . 'classes' . PATH_SEP . 'class.license.app.php');
require_once PATH_CORE . 'classes' . PATH_SEP . 'class.license.lib.php';
require_once PATH_CORE . 'classes' . PATH_SEP . 'class.license.app.php';
//searching .dat files in workspace folder
$server_array = $_SERVER;
$licfile = glob(PATH_DATA_SITE . "*.dat");
if (count($licfile) > 0 && is_file($licfile[0])) {
$oServerConf->setProperty('ACTIVE_LICENSE', array(SYS_SYS => ""));
}
$activeLicenseSetting = $oServerConf->getProperty('ACTIVE_LICENSE');
if (isset($activeLicenseSetting[SYS_SYS]) && file_exists($activeLicenseSetting[SYS_SYS])) {
$licenseFile = $activeLicenseSetting[SYS_SYS];
} else {
$activeLicense = $this->getActiveLicense();
$oServerConf->setProperty('ACTIVE_LICENSE', array(SYS_SYS => $activeLicense['LICENSE_PATH']));
$licenseFile = $activeLicense['LICENSE_PATH'];
}
$application = new license_application($licenseFile, false, true, false, true);
$application->set_server_vars($server_array);
$application->DATE_STRING = 'Y-m-d H:i:s';
$results = $application->validate();
$validStatus = array('OK', 'EXPIRED', 'TMINUS');
$this->result = $results['RESULT'];
$this->features = array();
$this->licensedfeatures = array();
$this->licensedfeaturesList = array();
if (in_array($this->result, $validStatus)) {
$this->serial = "3ptta7Xko2prrptrZnSd356aqmPXvMrayNPFj6CLdaR1pWtrW6qPw9jV0OHjxrDGu8LVxtmSm9nP5kR23HRpdZWccpeui+bKkK°DoqCt2Kqgpq6Vg37s";
$info['FIRST_NAME'] = $results['DATA']['FIRST_NAME'];
$info['LAST_NAME'] = $results['DATA']['LAST_NAME'];
$info['DOMAIN_WORKSPACE'] = $results['DATA']['DOMAIN_WORKSPACE'];
$this->date = $results['DATE'];
$this->info = $info;
$this->type = $results['DATA']['TYPE'];
$this->plan = isset($results['DATA']['PLAN']) ? $results['DATA']['PLAN'] : "";
$this->id = $results['ID'];
$this->expireIn = $this->getExpireIn();
$this->features = $this->result != 'TMINUS' ? isset($results['DATA']['CUSTOMER_PLUGIN']) ? $results['DATA']['CUSTOMER_PLUGIN'] : $this->getActiveFeatures() : array();
$this->licensedfeatures = $this->result != 'TMINUS' ? isset($results['DATA']['CUSTOMER_LICENSED_FEATURES']) ? $results['DATA']['CUSTOMER_LICENSED_FEATURES'] : array() : array();
$this->licensedfeaturesList = isset($results['DATA']['LICENSED_FEATURES_LIST']) ? $results['DATA']['LICENSED_FEATURES_LIST'] : null;
$this->status = $this->getCurrentLicenseStatus();
if (isset($results['LIC'])) {
$resultsRegister = $results['LIC'];
$this->server = $results['LIC']['SRV'];
$this->file = $results['LIC']['FILE'];
$this->workspace = isset($results['LIC']['WORKSPACE']) ? $results['LIC']['WORKSPACE'] : 'pmLicenseSrv';
$this->licenseSerial = isset($results['LIC']['SERIAL']) ? $results['LIC']['SERIAL'] : '';
$this->supportStartDate = isset($results['DATA']['SUPPORT_START_DATE']) ? $results['DATA']['SUPPORT_START_DATE'] : '';
$this->supportEndDate = isset($results['DATA']['SUPPORT_END_DATE']) ? $results['DATA']['SUPPORT_END_DATE'] : '';
$this->supportStartDate = date("Y-m-d H:i:s", strtotime($this->supportStartDate));
$this->supportEndDate = date("Y-m-d H:i:s", strtotime($this->supportEndDate));
G::LoadClass("configuration");
$conf = new Configurations();
if (defined('SYS_SYS') && $conf->exists("ENVIRONMENT_SETTINGS")) {
$this->supportStartDate = $conf->getSystemDate($this->supportStartDate);
$this->supportEndDate = $conf->getSystemDate($this->supportEndDate);
} else {
$this->supportStartDate = G::getformatedDate($this->supportStartDate, 'M d, yyyy', SYS_LANG);
$this->supportEndDate = G::getformatedDate($this->supportEndDate, 'M d, yyyy', SYS_LANG);
}
} else {
$resultsRegister = array();
$resultsRegister['ID'] = $results['DATA']['DOMAIN_WORKSPACE'];
$this->server = null;
$this->file = null;
}
$resultsRegister['date'] = $results['DATE'];
$resultsRegister['info'] = $info;
$resultsRegister['type'] = $results['DATA']['TYPE'];
if ($oServerConf->getProperty('LICENSE_INFO')) {
$licInfoA = $oServerConf->getProperty('LICENSE_INFO');
} else {
$licInfoA = array();
}
$licInfoA[SYS_SYS] = $resultsRegister;
$oServerConf->setProperty('LICENSE_INFO', $licInfoA);
}
if ($flagActivatePlugins) {
$this->activateFeatures();
}
}
示例5: getAppsData
//.........这里部分代码省略.........
$type == "todo" || $type == "draft" || $type == "paused" || $type == "sent" ||
$type == "selfservice" || $type == "unassigned" || $type == "search"
) &&
(($solrConf = System::solrEnv()) !== false)
) {
G::LoadClass("AppSolr");
$ApplicationSolrIndex = new AppSolr(
$solrConf["solr_enabled"],
$solrConf["solr_host"],
$solrConf["solr_instance"]
);
if ($ApplicationSolrIndex->isSolrEnabled() && $solrConf['solr_enabled'] == true) {
//Check if there are missing records to reindex and reindex them
$ApplicationSolrIndex->synchronizePendingApplications();
$solrEnabled = true;
} else{
$solrEnabled = false;
}
}
if ($solrEnabled) {
$cases = $ApplicationSolrIndex->getAppGridData(
$user,
$start,
$limit,
$type,
$filter,
$search,
$process,
$status,
'',
$dateFrom,
$dateTo,
$callback,
$dir,
$sort,
$category
);
} else {
G::LoadClass( 'applications' );
$apps = new Applications();
$cases = $apps->getAll(
$user,
$start,
$limit,
$type,
$filter,
$search,
$process,
$status,
'',
$dateFrom,
$dateTo,
$callback,
$dir,
$sort,
$category,
false
);
}
// formating & complitting apps data with 'Notes'
foreach ($cases['data'] as $i => $row) {
// Formatting
$appTitle = str_replace( '#', '', $row['APP_TITLE'] );
if (is_numeric( $appTitle )) {
$cases['data'][$i]['APP_TITLE'] = G::LoadTranslation( 'ID_CASE' ) . ' ' . $appTitle;
}
if (isset( $row['DEL_DELEGATE_DATE'] )) {
G::LoadClass( "configuration" );
$conf = new Configurations();
$generalConfCasesList = $conf->getConfiguration( 'ENVIRONMENT_SETTINGS', '' );
$cases['data'][$i]['DEL_DELEGATE_DATE'] = '';
if (defined('SYS_SYS')) {
if (isset( $generalConfCasesList['casesListDateFormat'] ) && ! empty( $generalConfCasesList['casesListDateFormat'] )) {
$cases['data'][$i]['DEL_DELEGATE_DATE'] = $conf->getSystemDate($row['DEL_DELEGATE_DATE'], 'casesListDateFormat');
}
}
if ($cases['data'][$i]['DEL_DELEGATE_DATE'] == '') {
$cases['data'][$i]['DEL_DELEGATE_DATE'] = $conf->getSystemDate($row['DEL_DELEGATE_DATE']);
}
}
if (isset( $row['APP_DEL_PREVIOUS_USER'] )) {
$cases['data'][$i]['APP_DEL_PREVIOUS_USER'] = ucwords( $row['APP_DEL_PREVIOUS_USER'] );
}
// Completting with Notes
$notes = $appNotes->getNotesList( $row['APP_UID'], '', $notesStart, $notesLimit );
$notes = $notes['array'];
$cases['data'][$i]['NOTES_COUNT'] = $notes['totalCount'];
$cases['data'][$i]['NOTES_LIST'] = $notes['notes'];
}
return $cases;
}
示例6: getAppsData
public function getAppsData($type, $start = null, $limit = null, $user = null, $filter = null, $search = null, $process = null, $status = null, $dateFrom = null, $dateTo = null, $callback = null, $dir = null, $sort = "APP_CACHE_VIEW.APP_NUMBER", $category = null)
{
require_once "classes/model/AppNotes.php";
G::LoadClass('applications');
$apps = new Applications();
$appNotes = new AppNotes();
$start = empty($start) ? $this->appListStart : $start;
$limit = empty($limit) ? $this->appListLimit : $limit;
$notesStart = 0;
$notesLimit = 4;
switch ($user) {
case 'CURRENT_USER':
$user = $this->userID;
break;
case 'ALL':
$user = null;
break;
case null:
$user = $this->userID;
break;
default:
//$user = $this->userID;
break;
}
$cases = $apps->getAll($user, $start, $limit, $type, $filter, $search, $process, $status, $type, $dateFrom, $dateTo, $callback, $dir, $sort, $category, false);
// formating & complitting apps data with 'Notes'
foreach ($cases['data'] as $i => $row) {
// Formatting
$appTitle = str_replace('#', '', $row['APP_TITLE']);
if (is_numeric($appTitle)) {
$cases['data'][$i]['APP_TITLE'] = G::LoadTranslation('ID_CASE') . ' ' . $appTitle;
}
if (isset($row['DEL_DELEGATE_DATE'])) {
G::LoadClass("configuration");
$conf = new Configurations();
$generalConfCasesList = $conf->getConfiguration('ENVIRONMENT_SETTINGS', '');
$cases['data'][$i]['DEL_DELEGATE_DATE'] = '';
if (defined('SYS_SYS')) {
if (isset($generalConfCasesList['casesListDateFormat']) && !empty($generalConfCasesList['casesListDateFormat'])) {
$cases['data'][$i]['DEL_DELEGATE_DATE'] = $conf->getSystemDate($row['DEL_DELEGATE_DATE'], 'casesListDateFormat');
}
}
if ($cases['data'][$i]['DEL_DELEGATE_DATE'] == '') {
$cases['data'][$i]['DEL_DELEGATE_DATE'] = $conf->getSystemDate($row['DEL_DELEGATE_DATE']);
}
}
if (isset($row['APP_DEL_PREVIOUS_USER'])) {
$cases['data'][$i]['APP_DEL_PREVIOUS_USER'] = ucwords($row['APP_DEL_PREVIOUS_USER']);
}
// Completting with Notes
$notes = $appNotes->getNotesList($row['APP_UID'], '', $notesStart, $notesLimit);
$notes = $notes['array'];
$cases['data'][$i]['NOTES_COUNT'] = $notes['totalCount'];
$cases['data'][$i]['NOTES_LIST'] = $notes['notes'];
}
return $cases;
}
示例7: Configurations
<?php
require_once PATH_CORE . 'classes' . PATH_SEP . 'class.pmLicenseManager.php';
require_once PATH_CORE . "classes" . PATH_SEP . "model" . PATH_SEP . "AddonsStore.php";
require_once PATH_CORE . "classes" . PATH_SEP . "class.enterpriseUtils.php";
AddonsStore::checkLicenseStore();
$licenseManager =& pmLicenseManager::getSingleton();
$oHeadPublisher =& headPublisher::getSingleton();
if (isset($licenseManager->date) && is_array($licenseManager->date)) {
G::LoadClass("configuration");
$conf = new Configurations();
if (defined('SYS_SYS') && $conf->exists("ENVIRONMENT_SETTINGS")) {
$licenseManager->date['START'] = date("Y-m-d H:i:s", strtotime($licenseManager->date['HUMAN']['START']));
$licenseManager->date['END'] = date("Y-m-d H:i:s", strtotime($licenseManager->date['HUMAN']['END']));
$licenseManager->date['START'] = $conf->getSystemDate($licenseManager->date['START']);
$licenseManager->date['END'] = $conf->getSystemDate($licenseManager->date['END']);
} else {
$licenseManager->date['START'] = date("Y-m-d H:i:s", strtotime($licenseManager->date['HUMAN']['START']));
$licenseManager->date['END'] = date("Y-m-d H:i:s", strtotime($licenseManager->date['HUMAN']['END']));
$licenseManager->date['START'] = G::getformatedDate($licenseManager->date['START'], 'M d, yyyy', SYS_LANG);
$licenseManager->date['END'] = G::getformatedDate($licenseManager->date['END'], 'M d, yyyy', SYS_LANG);
}
}
if (isset($licenseManager->result) && $licenseManager->result == "OK") {
$oHeadPublisher->assign("license_start_date", $licenseManager->date["START"]);
$oHeadPublisher->assign("license_end_date", $licenseManager->expireIn != "NEVER" ? $licenseManager->date["END"] : "NA");
$oHeadPublisher->assign("license_user", $licenseManager->info["FIRST_NAME"] . " " . $licenseManager->info["LAST_NAME"] . " (" . $licenseManager->info["DOMAIN_WORKSPACE"] . ")");
$oHeadPublisher->assign("license_span", $licenseManager->expireIn != "NEVER" ? ceil($licenseManager->date["SPAN"] / 60 / 60 / 24) : "~");
$oHeadPublisher->assign("license_name", $licenseManager->type);
$oHeadPublisher->assign("license_server", $licenseManager->server);
$oHeadPublisher->assign("license_expires", $licenseManager->expireIn);