Conflictos arreglados
This commit is contained in:
@@ -42,14 +42,26 @@ G::LoadClass( 'case' );
|
||||
|
||||
$actionAjax = isset( $_REQUEST['actionAjax'] ) ? $_REQUEST['actionAjax'] : null;
|
||||
|
||||
function filterUserListArray($users = array(), $filter = '')
|
||||
{
|
||||
$filteredUsers = array();
|
||||
foreach ($users as $user) {
|
||||
if(stripos($user['USR_FULLNAME'], $filter) || empty($filter)) {
|
||||
$filteredUsers[] = $user;
|
||||
}
|
||||
}
|
||||
return $filteredUsers;
|
||||
}
|
||||
|
||||
if ($actionAjax == "userValues") {
|
||||
//global $oAppCache;
|
||||
$oAppCache = new AppCacheView();
|
||||
$action = isset( $_REQUEST['action'] ) ? $_REQUEST['action'] : null;
|
||||
$query = isset( $_REQUEST['query'] ) ? $_REQUEST['query'] : null;
|
||||
$users = array();
|
||||
$users[] = array ("USR_UID" => "", "USR_FULLNAME" => G::LoadTranslation( "ID_ALL_USERS" ));
|
||||
$users[] = array ("USR_UID" => "CURRENT_USER", "USR_FULLNAME" => G::LoadTranslation( "ID_CURRENT_USER" ));
|
||||
|
||||
$users = filterUserListArray($users, $query);
|
||||
//now get users, just for the Search action
|
||||
switch ($action) {
|
||||
case 'search_simple':
|
||||
@@ -67,6 +79,14 @@ if ($actionAjax == "userValues") {
|
||||
$cUsers->addSelectColumn(UsersPeer::USR_FIRSTNAME);
|
||||
$cUsers->addSelectColumn(UsersPeer::USR_LASTNAME);
|
||||
$cUsers->add( UsersPeer::USR_STATUS, 'CLOSED', Criteria::NOT_EQUAL );
|
||||
|
||||
if (!is_null($query)) {
|
||||
$filters = $cUsers->getNewCriterion( UsersPeer::USR_FIRSTNAME, '%'.$query.'%', Criteria::LIKE )->addOr(
|
||||
$cUsers->getNewCriterion( UsersPeer::USR_LASTNAME, '%'.$query.'%', Criteria::LIKE )->addOr(
|
||||
$cUsers->getNewCriterion( UsersPeer::USR_USERNAME, '%'.$query.'%', Criteria::LIKE )));
|
||||
$cUsers->addOr( $filters );
|
||||
}
|
||||
$cUsers->setLimit(20);
|
||||
$cUsers->addAscendingOrderByColumn(UsersPeer::TABLE_NAME . "." . $conf->userNameFormatGetFirstFieldByUsersTable());
|
||||
$oDataset = UsersPeer::doSelectRS( $cUsers );
|
||||
$oDataset->setFetchmode( ResultSet::FETCHMODE_ASSOC );
|
||||
@@ -453,7 +473,7 @@ if ($actionAjax == 'showDynaformListHistory') {
|
||||
var showDynaformHistoryGlobal = {};
|
||||
showDynaformHistoryGlobal.dynUID = '';
|
||||
showDynaformHistoryGlobal.tablename = '';
|
||||
showDynaformHistoryGlobal.dynDate = '';casesList_Ajax.php
|
||||
showDynaformHistoryGlobal.dynDate = '';
|
||||
showDynaformHistoryGlobal.dynTitle = '';
|
||||
function showDynaformHistory(dynUID,tablename,dynDate,dynTitle){
|
||||
showDynaformHistoryGlobal.dynUID = dynUID;
|
||||
|
||||
@@ -77,7 +77,11 @@ try {
|
||||
$aFields = $oCase->loadCase( $sAppUid, $iDelIndex );
|
||||
// g::pr($aFields);
|
||||
// die;
|
||||
|
||||
if (!isset($_SESSION['CURRENT_TASK'])) {
|
||||
$_SESSION['CURRENT_TASK'] = $aFields['TAS_UID'];
|
||||
} else if ($_SESSION['CURRENT_TASK'] == '') {
|
||||
$_SESSION['CURRENT_TASK'] = $aFields['TAS_UID'];
|
||||
}
|
||||
switch ($aFields['APP_STATUS']) {
|
||||
case 'DRAFT':
|
||||
case 'TO_DO':
|
||||
|
||||
@@ -1,4 +1,11 @@
|
||||
<?php
|
||||
require_once 'classes/model/AppDelegation.php';
|
||||
$delegation = new AppDelegation();
|
||||
if( $delegation->alreadyRouted($_SESSION['APPLICATION'],$_SESSION['INDEX']) ) {
|
||||
G::header('location: ../cases/casesListExtJs');
|
||||
die();
|
||||
}
|
||||
|
||||
if (!isset($_SESSION['USER_LOGGED'])) {
|
||||
G::SendTemporalMessage( 'ID_LOGIN_AGAIN', 'warning', 'labels' );
|
||||
die( '<script type="text/javascript">
|
||||
|
||||
@@ -62,6 +62,7 @@ foreach ($DEBUG_ERRORS as $error) {
|
||||
]}';
|
||||
|
||||
*/
|
||||
$triggersRet = new StdClass();
|
||||
$triggersRet->total = count( $triggersList );
|
||||
$triggersRet->data = $triggersList;
|
||||
echo G::json_encode( $triggersRet );
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
* @date Sept 13th, 2010
|
||||
*
|
||||
*/
|
||||
|
||||
G::LoadClass( "configuration" );
|
||||
|
||||
$request = isset( $_POST["request"] ) ? $_POST["request"] : (isset( $_GET["request"] ) ? $_GET["request"] : null);
|
||||
@@ -39,17 +38,27 @@ switch ($request) {
|
||||
if (is_numeric($config)) {
|
||||
$config = array();
|
||||
}
|
||||
$config['format'] = $_POST["userFormat"];
|
||||
$config['dateFormat'] = $_POST["dateFormat"];
|
||||
if (isset($_POST["userFormat"])) {
|
||||
$config['format'] = $_POST["userFormat"];
|
||||
}
|
||||
if (isset($_POST["dateFormat"])) {
|
||||
$config['dateFormat'] = $_POST["dateFormat"];
|
||||
}
|
||||
$config['startCaseHideProcessInf'] = ((isset( $_POST["hideProcessInf"] )) ? true : false);
|
||||
$config['casesListDateFormat'] = $_POST["casesListDateFormat"];
|
||||
$config['casesListRowNumber'] = intval( $_POST["casesListRowNumber"] );
|
||||
$config['casesListRefreshTime'] = intval( $_POST["txtCasesRefreshTime"]);
|
||||
if (isset($_POST["casesListDateFormat"])) {
|
||||
$config['casesListDateFormat'] = $_POST["casesListDateFormat"];
|
||||
}
|
||||
if (isset($_POST["casesListDateFormat"])) {
|
||||
$config['casesListRowNumber'] = intval( $_POST["casesListRowNumber"] );
|
||||
}
|
||||
if (isset($_POST["txtCasesRefreshTime"])) {
|
||||
$config['casesListRefreshTime'] = intval( $_POST["txtCasesRefreshTime"]);
|
||||
}
|
||||
|
||||
$conf->aConfig = $config;
|
||||
$conf->saveConfig( "ENVIRONMENT_SETTINGS", "" );
|
||||
|
||||
G::auditLog("UpdateEnvironmentSettings", "UserNameDisplayFormat -> ".$_POST["userFormat"].", GlobalDateFormat -> ".$_POST["dateFormat"].", HideProcessInformation -> ".(string)isset($_POST["hideProcessInf"]).", DateFormat -> ".$_POST["casesListDateFormat"].", NumberOfRowsPerPage -> ".$_POST["casesListRowNumber"].", RefreshTimeSeconds -> ".$_POST["txtCasesRefreshTime"]);
|
||||
G::auditLog("UpdateEnvironmentSettings", "UserNameDisplayFormat -> ".(isset($_POST["userFormat"]) ? $_POST["userFormat"] : '').", GlobalDateFormat -> ".(isset($_POST["dateFormat"]) ? $_POST["dateFormat"] : '').", HideProcessInformation -> ".(string)isset($_POST["hideProcessInf"]).", DateFormat -> ".(isset($_POST["casesListDateFormat"]) ? $_POST["casesListDateFormat"] : '').", NumberOfRowsPerPage -> ".(isset($_POST["casesListRowNumber"]) ? $_POST["casesListRowNumber"] : '').", RefreshTimeSeconds -> ".(isset($_POST["txtCasesRefreshTime"]) ? $_POST["txtCasesRefreshTime"] : ''));
|
||||
|
||||
$response = new stdclass();
|
||||
$response->success = true;
|
||||
|
||||
@@ -22,13 +22,13 @@
|
||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||
*/
|
||||
/*
|
||||
* dynaforms & documents for Case Tracker
|
||||
*
|
||||
* @author Everth S. Berrios Morales <everth@colosa.com>
|
||||
*
|
||||
/*
|
||||
* dynaforms & documents for Case Tracker
|
||||
*
|
||||
* @author Everth S. Berrios Morales <everth@colosa.com>
|
||||
*
|
||||
*/
|
||||
if (! isset( $_SESSION['PROCESS'] )) {
|
||||
if (! isset( $_SESSION['PROCESS'] ) || ! isset( $_SESSION['APPLICATION'] )) {
|
||||
G::header( 'location: login' );
|
||||
}
|
||||
$G_MAIN_MENU = 'caseTracker';
|
||||
|
||||
@@ -22,13 +22,13 @@
|
||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||
*/
|
||||
/*
|
||||
* Hystory case for Case Tracker
|
||||
*
|
||||
* @author Everth S. Berrios Morales <everth@colosa.com>
|
||||
*
|
||||
/*
|
||||
* Hystory case for Case Tracker
|
||||
*
|
||||
* @author Everth S. Berrios Morales <everth@colosa.com>
|
||||
*
|
||||
*/
|
||||
if (! isset( $_SESSION['PROCESS'] )) {
|
||||
if (! isset( $_SESSION['PROCESS'] ) || ! isset( $_SESSION['APPLICATION'] ) ) {
|
||||
G::header( 'location: login' );
|
||||
}
|
||||
|
||||
|
||||
@@ -22,13 +22,13 @@
|
||||
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
|
||||
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
|
||||
*/
|
||||
/*
|
||||
* History messages for Case Tracker
|
||||
*
|
||||
* @author Everth S. Berrios Morales <everth@colosa.com>
|
||||
*
|
||||
/*
|
||||
* History messages for Case Tracker
|
||||
*
|
||||
* @author Everth S. Berrios Morales <everth@colosa.com>
|
||||
*
|
||||
*/
|
||||
if (! isset( $_SESSION['PROCESS'] )) {
|
||||
if (! isset( $_SESSION['PROCESS'] ) || ! isset( $_SESSION['APPLICATION'] )) {
|
||||
G::header( 'location: login' );
|
||||
}
|
||||
$G_MAIN_MENU = 'caseTracker';
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
*
|
||||
*/
|
||||
require_once 'classes/model/Process.php';
|
||||
if (! isset( $_SESSION['PROCESS'] )) {
|
||||
if (! isset( $_SESSION['PROCESS'] ) || ! isset( $_SESSION['APPLICATION'] )) {
|
||||
G::header( 'location: login' );
|
||||
}
|
||||
$G_MAIN_MENU = 'caseTracker';
|
||||
|
||||
@@ -81,7 +81,7 @@ foreach ($aInfoFunction as $k => $v) {
|
||||
$option = floatval($aDataTriggers[$sOptionTrigger]);
|
||||
break;
|
||||
default:
|
||||
$option = (is_numeric($aDataTriggers[$sOptionTrigger]) || is_bool($aDataTriggers[$sOptionTrigger]) ) ? trim($aDataTriggers[$sOptionTrigger]) : (strstr($aDataTriggers[$sOptionTrigger], "array")) ? trim($aDataTriggers[$sOptionTrigger]) : "'" . trim($aDataTriggers[$sOptionTrigger]) . "'";
|
||||
$option = (is_numeric($aDataTriggers[$sOptionTrigger]) || is_bool($aDataTriggers[$sOptionTrigger]) ) ? trim($aDataTriggers[$sOptionTrigger]) : (strstr($aDataTriggers[$sOptionTrigger], "'.array.'")) ? trim($aDataTriggers[$sOptionTrigger]) : "'" . trim($aDataTriggers[$sOptionTrigger]) . "'";
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user