BUG 11969 Web session TimeOut at HOME

In Home Tab when you loss session, PM naver advise it to you, and it still working but dosen't save the data.

So now all Home places are validated  to show a popup message when you loos session.
This commit is contained in:
jennylee
2013-06-03 18:13:38 -04:00
parent fd62aa1e0d
commit 774a391f38
21 changed files with 1369 additions and 563 deletions

View File

@@ -105,8 +105,8 @@ class AppNotes extends BaseAppNotes
$response['success'] = G::LoadTranslation("ID_FAILURE");
$response['message'] = $msg;
} else {
$response['success'] = G::LoadTranslation("ID_SUCCESS");
$response['message'] = G::LoadTranslation("ID_SAVED2");
$response['success'] = "success";
$response['message'] = G::LoadTranslation("ID_SAVED");
}
if ($notify) {

View File

@@ -1,5 +1,11 @@
<?php
if (!isset($_SESSION['USER_LOGGED'])) {
$response = new stdclass();
$response->message = G::LoadTranslation('ID_LOGIN_AGAIN');
$response->lostSession = true;
print G::json_encode( $response );
die();
}
/**
* App controller
*
@@ -21,6 +27,13 @@ class AppProxy extends HttpProxyController
*/
function getNotesList ($httpData)
{
if (!isset($_SESSION['USER_LOGGED'])) {
$response = new stdclass();
$response->message = G::LoadTranslation('ID_LOGIN_AGAIN');
$response->lostSession = true;
print G::json_encode( $response );
die();
}
$appUid = null;
if (isset( $httpData->appUid ) && trim( $httpData->appUid ) != "") {
@@ -116,6 +129,13 @@ class AppProxy extends HttpProxyController
//Send the response to client
@ini_set("implicit_flush", 1);
ob_start();
if (!isset($_SESSION['USER_LOGGED'])) {
$response = new stdclass();
$response->message = G::LoadTranslation('ID_LOGIN_AGAIN');
$response->lostSession = true;
print G::json_encode( $response );
die();
}
echo G::json_encode($response);
@ob_flush();
@flush();

View File

@@ -33,7 +33,19 @@
//require_once 'classes/model/AppDelay.php';
//require_once 'classes/model/Process.php';
//require_once 'classes/model/Task.php';
if(isset($_REQUEST['action']) && $_REQUEST['action'] == "verifySession" ) {
if (!isset($_SESSION['USER_LOGGED'])) {
$response = new stdclass();
$response->message = G::LoadTranslation('ID_LOGIN_AGAIN');
$response->lostSession = true;
print G::json_encode( $response );
die();
} else {
$response = new stdclass();
print G::json_encode( $response );
die();
}
}
class Ajax
{
@@ -73,6 +85,13 @@ class Ajax
public function steps()
{
if (!isset($_SESSION['USER_LOGGED'])) {
$response = new stdclass();
$response->message = G::LoadTranslation('ID_LOGIN_AGAIN');
$response->lostSession = true;
print G::json_encode( $response );
die();
}
G::LoadClass('applications');
$applications = new Applications();
@@ -296,6 +315,13 @@ class Ajax
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';
@@ -314,6 +340,13 @@ class Ajax
public function getTaskInformation()
{
if (!isset($_SESSION['USER_LOGGED'])) {
$response = new stdclass();
$response->message = G::LoadTranslation('ID_LOGIN_AGAIN');
$response->lostSession = true;
print G::json_encode( $response );
die();
}
$task = new Task();
if ($_SESSION['TASK'] == '-1') {
$_SESSION['TASK'] = $_SESSION['CURRENT_TASK'];
@@ -364,6 +397,13 @@ class Ajax
public function uploadedDocuments()
{
if (!isset($_SESSION['USER_LOGGED'])) {
$response = new stdclass();
$response->message = G::LoadTranslation('ID_LOGIN_AGAIN');
$response->lostSession = true;
print G::json_encode( $response );
die();
}
global $G_PUBLISH;
G::loadClass('configuration');
@@ -457,6 +497,13 @@ class Ajax
public function getUsersToReassign()
{
if (!isset($_SESSION['USER_LOGGED'])) {
$response = new stdclass();
$response->message = G::LoadTranslation('ID_LOGIN_AGAIN');
$response->lostSession = true;
print G::json_encode( $response );
die();
}
$case = new Cases();
$result->data = $case->getUsersToReassign($_SESSION['TASK'], $_SESSION['USER_LOGGED']);
@@ -594,6 +641,13 @@ class Ajax
public function changeLogTab()
{
if (!isset($_SESSION['USER_LOGGED'])) {
$response = new stdclass();
$response->message = G::LoadTranslation('ID_LOGIN_AGAIN');
$response->lostSession = true;
print G::json_encode( $response );
die();
}
try {
global $G_PUBLISH;
require_once 'classes/model/AppHistory.php';

View File

@@ -1,4 +1,11 @@
<?php
if (!isset($_SESSION['USER_LOGGED'])) {
$response = new stdclass();
$response->message = G::LoadTranslation('ID_LOGIN_AGAIN');
$response->lostSession = true;
print G::json_encode( $response );
die();
}
/**
* casesList_Ajax.php
*

View File

@@ -1,4 +1,12 @@
<?php
if (!isset($_SESSION['USER_LOGGED'])) {
$res = new stdclass();
$res->message = G::LoadTranslation('ID_LOGIN_AGAIN');
$res->lostSession = true;
$res->success = true;
print G::json_encode( $res );
die();
}
if (! isset( $_REQUEST['action'] )) {
$res['success'] = 'failure';
$res['message'] = G::LoadTranslation( 'ID_REQUEST_ACTION' );

View File

@@ -1,4 +1,11 @@
<?php
if (!isset($_SESSION['USER_LOGGED'])) {
$response = new stdclass();
$response->message = G::LoadTranslation('ID_LOGIN_AGAIN');
$response->lostSession = true;
print G::json_encode( $response );
die();
}
/**
* cases_Ajax.php
*

View File

@@ -21,7 +21,12 @@
* For more information, contact Colosa Inc, 2566 Le Jeune Rd.,
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
*/
if (!isset($_SESSION['USER_LOGGED'])) {
G::SendTemporalMessage( 'ID_LOGIN_AGAIN', 'warning', 'labels' );
die( '<script type="text/javascript">
parent.location = "../cases/casesListExtJs?action=selfservice";
</script>');
}
/* Permissions */
switch ($RBAC->userCanAccess( 'PM_CASES' )) {
case - 2:

View File

@@ -22,8 +22,12 @@
* Coral Gables, FL, 33134, USA, or email info@colosa.com.
*/
//validate the data post
if (!isset($_SESSION['USER_LOGGED'])) {
G::SendTemporalMessage( 'ID_LOGIN_AGAIN', 'warning', 'labels' );
die( '<script type="text/javascript">
parent.location = "../cases/casesStartPage?action=startCase";
</script>');
}
try {
if ($_GET['APP_UID'] !== $_SESSION['APPLICATION']) {
throw new Exception( G::LoadTranslation( 'ID_INVALID_APPLICATION_ID_MSG', array ('<a href=\'' . $_SERVER['HTTP_REFERER'] . '\'>{1}</a>',G::LoadTranslation( 'ID_REOPEN' ) ) ) );

View File

@@ -28,7 +28,19 @@
*/
require_once ("classes/model/AppDocumentPeer.php");
if(isset($_REQUEST['actionAjax']) && $_REQUEST['actionAjax'] == "verifySession" ) {
if (!isset($_SESSION['USER_LOGGED'])) {
$response = new stdclass();
$response->message = G::LoadTranslation('ID_LOGIN_AGAIN');
$response->lostSession = true;
print G::json_encode( $response );
die();
} else {
$response = new stdclass();
print G::json_encode( $response );
die();
}
}
//v = Version
//a = Case UID

View File

@@ -1,4 +1,11 @@
<?php
if (!isset($_SESSION['USER_LOGGED'])) {
$response = new stdclass();
$response->message = G::LoadTranslation('ID_LOGIN_AGAIN');
$response->lostSession = true;
print G::json_encode( $response );
die();
}
/**
* cases_ShowOutputDocument.php
*

View File

@@ -1,4 +1,10 @@
<?php
if (!isset($_SESSION['USER_LOGGED'])) {
G::SendTemporalMessage( 'ID_LOGIN_AGAIN', 'warning', 'labels' );
die( '<script type="text/javascript">
parent.location = "../cases/casesStartPage?action=startCase";
</script>');
}
/**
* cases_Step.php
*

View File

@@ -1,8 +1,11 @@
<?php
if (!isset($_SESSION['USER_LOGGED'])) {
$result = new stdclass();
$result->error = G::LoadTranslation('ID_LOGIN_AGAIN');
die(G::json_encode($result));
$responseObject = new stdclass();
$responseObject->error = G::LoadTranslation('ID_LOGIN_AGAIN');
$responseObject->success = true;
$responseObject->lostSession = true;
print G::json_encode( $responseObject );
die();
}
//Getting the extJs parameters

View File

@@ -1,4 +1,11 @@
<?php
if (!isset($_SESSION['USER_LOGGED'])) {
$response = new stdclass();
$response->message = G::LoadTranslation('ID_LOGIN_AGAIN');
$response->lostSession = true;
print G::json_encode( $response );
die();
}
$callback = isset( $_POST['callback'] ) ? $_POST['callback'] : 'stcCallback1001';
$dir = isset( $_POST['dir'] ) ? $_POST['dir'] : 'DESC';
$sort = isset( $_POST['sort'] ) ? $_POST['sort'] : '';

View File

@@ -42,7 +42,7 @@ function openCaseNotesWindow(appUid1, modalSw, appTitle, proUid, taskUid)
limit:startRecord+loadSize
},
listeners:{
load:function(){
load:function(response){
Ext.MessageBox.hide();
if ( typeof(storeNotes.reader.jsonData.noPerms != 'undefined') &&
(storeNotes.reader.jsonData.noPerms == '1') ) {
@@ -68,8 +68,23 @@ function openCaseNotesWindow(appUid1, modalSw, appTitle, proUid, taskUid)
caseNotesWindow.show();
newNoteAreaActive = false;
newNoteHandler();
},
exception: function(dp, type, action, options, response, arg) {
responseObject = Ext.util.JSON.decode(response.responseText);
if (responseObject.lostSession) {
Ext.Msg.show({
title: _('ID_ERROR'),
msg: responseObject.message,
animEl: 'elId',
icon: Ext.MessageBox.ERROR,
buttons: Ext.MessageBox.OK,
fn : function(btn) {
location = location;
}
});
}
}
}
});
storeNotes.load();
@@ -350,8 +365,17 @@ function sendNote()
Ext.getCmp('addCancelBtn').setDisabled(false);
statusBarMessage( _('ID_CASES_NOTE_POST_SUCCESS'), false,true);
storeNotes.load();
}
else {
} else if (data.lostSession) {
Ext.Msg.show({
title : _('ID_CASES_NOTE_POST_ERROR'),
msg : data.message,
icon : Ext.MessageBox.ERROR,
buttons : Ext.Msg.OK,
fn : function(btn) {
location = location;
}
});
} else {
Ext.getCmp('caseNoteText').setDisabled(false);
Ext.getCmp('sendBtn').setDisabled(false);
Ext.getCmp('addCancelBtn').setDisabled(false);
@@ -476,8 +500,17 @@ var openSummaryWindow = function(appUid, delIndex, action)
summaryWindow.add(summaryTabs);
summaryWindow.doLayout();
summaryWindow.show();
}
else {
} else if (response.lostSession) {
Ext.Msg.show({
title : "ERROR",
msg : response.message,
icon : Ext.MessageBox.ERROR,
buttons : Ext.Msg.OK,
fn : function(btn) {
location = location;
}
});
} else {
PMExt.warning(_('ID_WARNING'), response.message);
}
summaryWindowOpened = false;

View File

@@ -453,33 +453,58 @@ function openActionDialog(caller, action, dataAux)
var urlDownload = ext_itemgrid.getSelectionModel().getSelected().get("downloadLink");
if (selectedRows.length == 1) {
if (ext_itemgrid.getSelectionModel().getSelected().get("appDocType") == "Output" && ext_itemgrid.getSelectionModel().getSelected().get("outDocGenerate") != "") {
dataAux = (dataAux != "")? dataAux : "pdf";
Ext.Ajax.request({
url : 'ajaxListener' ,
params : {action : 'verifySession'},
success: function ( result, request ) {
var data = Ext.util.JSON.decode(result.responseText);
if( data.lostSession ) {
Ext.Msg.show({
title: _('ID_ERROR'),
msg: data.message,
animEl: 'elId',
icon: Ext.MessageBox.ERROR,
buttons: Ext.MessageBox.OK,
fn : function(btn) {
location = location;
}
});
} else {
if (ext_itemgrid.getSelectionModel().getSelected().get("appDocType") == "Output" && ext_itemgrid.getSelectionModel().getSelected().get("outDocGenerate") != "") {
dataAux = (dataAux != "")? dataAux : "pdf";
urlDownload = stringReplace("&ext=.{3,}&", "&ext=" + dataAux + "&", urlDownload);
}
urlDownload = stringReplace("&ext=.{3,}&", "&ext=" + dataAux + "&", urlDownload);
}
if (ext_itemgrid.getSelectionModel().getSelected().get("appDocPlugin") != "") {
messageText = _("ID_DOWNLOADING_FILE") + " " + ext_itemgrid.getSelectionModel().getSelected().get("name");
statusBarMessage(messageText, true, true);
if (ext_itemgrid.getSelectionModel().getSelected().get("appDocPlugin") != "") {
messageText = _("ID_DOWNLOADING_FILE") + " " + ext_itemgrid.getSelectionModel().getSelected().get("name");
statusBarMessage(messageText, true, true);
try {
Ext.destroy(Ext.get("downloadIframe"));
} catch (e) {
try {
Ext.destroy(Ext.get("downloadIframe"));
} catch (e) {
}
Ext.DomHelper.append(document.body, {
tag: "iframe",
id: "downloadIframe",
frameBorder: 0,
width: 0,
height: 0,
css: "display: none; visibility: hidden; height: 0px;",
src: urlDownload
});
} else {
streamFilefromPM(urlDownload);
}
}
},
failure: function ( result, request) {
if (typeof(result.responseText) != 'undefined') {
Ext.MessageBox.alert( _('ID_FAILED'), result.responseText);
}
}
Ext.DomHelper.append(document.body, {
tag: "iframe",
id: "downloadIframe",
frameBorder: 0,
width: 0,
height: 0,
css: "display: none; visibility: hidden; height: 0px;",
src: urlDownload
});
} else {
streamFilefromPM(urlDownload);
}
});
}
/*

View File

@@ -348,19 +348,44 @@
var rowSelected = processesGrid.getSelectionModel().getSelected();
if( rowSelected ){
//generateDocumentGridGlobal construct
generateDocumentGridDownloadGlobal.APP_DOC_UID = rowSelected.data.APP_DOC_UID;
generateDocumentGridDownloadGlobal.FILEDOC = rowSelected.data.FILEDOC;
generateDocumentGridDownloadGlobal.FILEPDF = rowSelected.data.FILEPDF;
generateDocumentGridDownloadGlobal.DOWNLOAD = 'FILEDOC';
var APP_DOC_UID = generateDocumentGridDownloadGlobal.APP_DOC_UID;
var FILEDOC = generateDocumentGridDownloadGlobal.FILEDOC;
var FILEPDF = generateDocumentGridDownloadGlobal.FILEPDF;
var DOWNLOAD = generateDocumentGridDownloadGlobal.DOWNLOAD;
generateDocumentGridDownload();
if( rowSelected ){
Ext.Ajax.request({
url : 'cases_ShowDocument' ,
params : {actionAjax : 'verifySession'},
success: function ( result, request ) {
var data = Ext.util.JSON.decode(result.responseText);
if( data.lostSession ) {
Ext.Msg.show({
title: _('ID_ERROR'),
msg: data.message,
animEl: 'elId',
icon: Ext.MessageBox.ERROR,
buttons: Ext.MessageBox.OK,
fn : function(btn) {
location = location;
}
});
} else {
//generateDocumentGridGlobal construct
generateDocumentGridDownloadGlobal.APP_DOC_UID = rowSelected.data.APP_DOC_UID;
generateDocumentGridDownloadGlobal.FILEDOC = rowSelected.data.FILEDOC;
generateDocumentGridDownloadGlobal.FILEPDF = rowSelected.data.FILEPDF;
generateDocumentGridDownloadGlobal.DOWNLOAD = 'FILEDOC';
var APP_DOC_UID = generateDocumentGridDownloadGlobal.APP_DOC_UID;
var FILEDOC = generateDocumentGridDownloadGlobal.FILEDOC;
var FILEPDF = generateDocumentGridDownloadGlobal.FILEPDF;
var DOWNLOAD = generateDocumentGridDownloadGlobal.DOWNLOAD;
generateDocumentGridDownload();
}
},
failure: function ( result, request) {
if (typeof(result.responseText) != 'undefined') {
Ext.MessageBox.alert( _('ID_FAILED'), result.responseText);
}
}
});
}
else{
Ext.Msg.show({
@@ -389,19 +414,44 @@
var rowSelected = processesGrid.getSelectionModel().getSelected();
if( rowSelected ){
//generateDocumentGridGlobal construct
generateDocumentGridDownloadGlobal.APP_DOC_UID = rowSelected.data.APP_DOC_UID;
generateDocumentGridDownloadGlobal.FILEDOC = rowSelected.data.FILEDOC;
generateDocumentGridDownloadGlobal.FILEPDF = rowSelected.data.FILEPDF;
generateDocumentGridDownloadGlobal.DOWNLOAD = 'FILEPDF';
var APP_DOC_UID = generateDocumentGridDownloadGlobal.APP_DOC_UID;
var FILEDOC = generateDocumentGridDownloadGlobal.FILEDOC;
var FILEPDF = generateDocumentGridDownloadGlobal.FILEPDF;
var DOWNLOAD = generateDocumentGridDownloadGlobal.DOWNLOAD;
generateDocumentGridDownload();
if( rowSelected ){
Ext.Ajax.request({
url : 'cases_ShowDocument' ,
params : {actionAjax : 'verifySession'},
success: function ( result, request ) {
var data = Ext.util.JSON.decode(result.responseText);
if( data.lostSession ) {
Ext.Msg.show({
title: _('ID_ERROR'),
msg: data.message,
animEl: 'elId',
icon: Ext.MessageBox.ERROR,
buttons: Ext.MessageBox.OK,
fn : function(btn) {
location = location;
}
});
} else {
//generateDocumentGridGlobal construct
generateDocumentGridDownloadGlobal.APP_DOC_UID = rowSelected.data.APP_DOC_UID;
generateDocumentGridDownloadGlobal.FILEDOC = rowSelected.data.FILEDOC;
generateDocumentGridDownloadGlobal.FILEPDF = rowSelected.data.FILEPDF;
generateDocumentGridDownloadGlobal.DOWNLOAD = 'FILEPDF';
var APP_DOC_UID = generateDocumentGridDownloadGlobal.APP_DOC_UID;
var FILEDOC = generateDocumentGridDownloadGlobal.FILEDOC;
var FILEPDF = generateDocumentGridDownloadGlobal.FILEPDF;
var DOWNLOAD = generateDocumentGridDownloadGlobal.DOWNLOAD;
generateDocumentGridDownload();
}
},
failure: function ( result, request) {
if (typeof(result.responseText) != 'undefined') {
Ext.MessageBox.alert( _('ID_FAILED'), result.responseText);
}
}
});
}
else{
Ext.Msg.show({

File diff suppressed because it is too large Load Diff

View File

@@ -63,21 +63,96 @@ Ext.onReady(function() {
text : 'X',
ctCls : 'pm_search_x_button',
handler : function() {
Ext.getCmp('processesFilter').setValue('');
startCaseFilter.clear();
Ext.Ajax.request({
url : 'casesStartPage_Ajax' ,
params : {action : 'verifySession'},
success: function ( result, request ) {
var data = Ext.util.JSON.decode(result.responseText);
if( data.lostSession ) {
Ext.Msg.show({
title: _('ID_ERROR'),
msg: data.message,
animEl: 'elId',
icon: Ext.MessageBox.ERROR,
buttons: Ext.MessageBox.OK,
fn : function(btn) {
location = location;
}
});
} else {
Ext.getCmp('processesFilter').setValue('');
startCaseFilter.clear();
}
},
failure: function ( result, request) {
if (typeof(result.responseText) != 'undefined') {
Ext.MessageBox.alert( _('ID_FAILED'), result.responseText);
}
}
});
}
}, ' ', ' ', {
iconCls : 'icon-expand-all',
tooltip : _('ID_EXPAND_ALL'),
handler : function() {
Ext.getCmp("startCaseTreePanel").root.expand(true);
Ext.Ajax.request({
url : 'casesStartPage_Ajax' ,
params : {action : 'verifySession'},
success: function ( result, request ) {
var data = Ext.util.JSON.decode(result.responseText);
if( data.lostSession ) {
Ext.Msg.show({
title: _('ID_ERROR'),
msg: data.message,
animEl: 'elId',
icon: Ext.MessageBox.ERROR,
buttons: Ext.MessageBox.OK,
fn : function(btn) {
location = location;
}
});
} else {
Ext.getCmp("startCaseTreePanel").root.expand(true);
}
},
failure: function ( result, request) {
if (typeof(result.responseText) != 'undefined') {
Ext.MessageBox.alert( _('ID_FAILED'), result.responseText);
}
}
});
},
scope : this
}, '-', {
iconCls : 'icon-collapse-all',
tooltip : _('ID_COLLAPSE_ALL'),
handler : function() {
Ext.getCmp("startCaseTreePanel").root.collapse(true);
Ext.Ajax.request({
url : 'casesStartPage_Ajax' ,
params : {action : 'verifySession'},
success: function ( result, request ) {
var data = Ext.util.JSON.decode(result.responseText);
if( data.lostSession ) {
Ext.Msg.show({
title: _('ID_ERROR'),
msg: data.message,
animEl: 'elId',
icon: Ext.MessageBox.ERROR,
buttons: Ext.MessageBox.OK,
fn : function(btn) {
location = location;
}
});
} else {
Ext.getCmp("startCaseTreePanel").root.collapse(true);
}
},
failure: function ( result, request) {
if (typeof(result.responseText) != 'undefined') {
Ext.MessageBox.alert( _('ID_FAILED'), result.responseText);
}
}
});
},
scope : this
}, ' ', ' ', {
@@ -86,8 +161,33 @@ Ext.onReady(function() {
icon : '/images/refresh.gif',
handler : function() {
tree = Ext.getCmp('startCaseTreePanel');
tree.getLoader().load(tree.root);
Ext.Ajax.request({
url : 'casesStartPage_Ajax' ,
params : {action : 'verifySession'},
success: function ( result, request ) {
var data = Ext.util.JSON.decode(result.responseText);
if( data.lostSession ) {
Ext.Msg.show({
title: _('ID_ERROR'),
msg: data.message,
animEl: 'elId',
icon: Ext.MessageBox.ERROR,
buttons: Ext.MessageBox.OK,
fn : function(btn) {
location = location;
}
});
} else {
tree = Ext.getCmp('startCaseTreePanel');
tree.getLoader().load(tree.root);
}
},
failure: function ( result, request) {
if (typeof(result.responseText) != 'undefined') {
Ext.MessageBox.alert( _('ID_FAILED'), result.responseText);
}
}
});
}
}
],
@@ -96,7 +196,32 @@ Ext.onReady(function() {
openCaseA(n);
},
click : function(n) {
showDetailsA(n);
Ext.Ajax.request({
url : 'casesStartPage_Ajax' ,
params : {action : 'verifySession'},
success: function ( result, request ) {
var data = Ext.util.JSON.decode(result.responseText);
if( data.lostSession ) {
Ext.Msg.show({
title: _('ID_ERROR'),
msg: data.message,
animEl: 'elId',
icon: Ext.MessageBox.ERROR,
buttons: Ext.MessageBox.OK,
fn : function(btn) {
location = location;
}
});
} else {
showDetailsA(n);
}
},
failure: function ( result, request) {
if (typeof(result.responseText) != 'undefined') {
Ext.MessageBox.alert( _('ID_FAILED'), result.responseText);
}
}
});
},
load: function(node){
if (node.childNodes.length == 0)
@@ -289,8 +414,17 @@ function openCaseA(n){
var res = Ext.util.JSON.decode(response.responseText);
if (res.openCase) {
window.location = res.openCase.PAGE;
}
else {
}else if (res.lostSession) {
Ext.Msg.show({
title : TRANSLATIONS.ID_ERROR_CREATING_NEW_CASE, // 'Error creating a new Case',
msg : res.message,
icon : Ext.MessageBox.ERROR,
buttons : Ext.Msg.OK,
fn : function(btn) {
location = location;
}
});
} else {
Ext.Msg.show({
title : TRANSLATIONS.ID_ERROR_CREATING_NEW_CASE, // 'Error creating a new Case',
msg : '<textarea cols="50" rows="10">'

View File

@@ -421,19 +421,43 @@
var rowSelected = processesGrid.getSelectionModel().getSelected();
if( rowSelected ){
//uploadDocumentGridGlobal construct
uploadDocumentGridDownloadGlobal.APP_DOC_UID = rowSelected.data.APP_DOC_UID;
uploadDocumentGridDownloadGlobal.DOWNLOAD_LINK = rowSelected.data.DOWNLOAD_LINK;
uploadDocumentGridDownloadGlobal.TITLE = rowSelected.data.TITLE;
var APP_DOC_UID = uploadDocumentGridDownloadGlobal.APP_DOC_UID;
var DOWNLOAD_LINK = uploadDocumentGridDownloadGlobal.DOWNLOAD_LINK;
var TITLE = uploadDocumentGridDownloadGlobal.TITLE;
uploadDocumentGridDownload();
}
else{
if( rowSelected ){
Ext.Ajax.request({
url : 'cases_ShowDocument' ,
params : {actionAjax : 'verifySession'},
success: function ( result, request ) {
var data = Ext.util.JSON.decode(result.responseText);
if( data.lostSession ) {
Ext.Msg.show({
title: _('ID_ERROR'),
msg: data.message,
animEl: 'elId',
icon: Ext.MessageBox.ERROR,
buttons: Ext.MessageBox.OK,
fn : function(btn) {
top.location = '../login/login';
}
});
} else {
//uploadDocumentGridGlobal construct
uploadDocumentGridDownloadGlobal.APP_DOC_UID = rowSelected.data.APP_DOC_UID;
uploadDocumentGridDownloadGlobal.DOWNLOAD_LINK = rowSelected.data.DOWNLOAD_LINK;
uploadDocumentGridDownloadGlobal.TITLE = rowSelected.data.TITLE;
var APP_DOC_UID = uploadDocumentGridDownloadGlobal.APP_DOC_UID;
var DOWNLOAD_LINK = uploadDocumentGridDownloadGlobal.DOWNLOAD_LINK;
var TITLE = uploadDocumentGridDownloadGlobal.TITLE;
uploadDocumentGridDownload();
}
},
failure: function ( result, request) {
if (typeof(result.responseText) != 'undefined') {
Ext.MessageBox.alert( _('ID_FAILED'), result.responseText);
}
}
});
} else{
Ext.Msg.show({
title:'',
msg: TRANSLATIONS.ID_NO_SELECTION_WARNING,

File diff suppressed because it is too large Load Diff

View File

@@ -31,11 +31,11 @@
function transactionLog($transactionName){
if (extension_loaded('newrelic')) {
$baseName="ProcessMaker";
//Application base name
newrelic_set_appname ($baseName);
//Custom parameters
if(defined("SYS_SYS")){
newrelic_add_custom_parameter ("workspace", SYS_SYS);
@@ -61,10 +61,10 @@ function transactionLog($transactionName){
if(defined("PATH_DATA_SITE")){
newrelic_add_custom_parameter ("path_site", PATH_DATA_SITE);
}
//Show correct transaction name
if(defined("SYS_SYS")){
newrelic_set_appname ("PM-".SYS_SYS.";$baseName");
newrelic_set_appname ("PM-".SYS_SYS.";$baseName");
}
if(defined("PATH_CORE")){
$transactionName=str_replace(PATH_CORE,"",$transactionName);
@@ -374,8 +374,8 @@ if (Bootstrap::virtualURI( $_SERVER['REQUEST_URI'], $virtualURITable, $realPath
if (file_exists( $pluginFilename )) {
//NewRelic Snippet - By JHL
transactionLog($pluginFilename);
transactionLog($pluginFilename);
Bootstrap::streamFile( $pluginFilename );
}
die();
@@ -400,7 +400,7 @@ if (Bootstrap::virtualURI( $_SERVER['REQUEST_URI'], $virtualURITable, $realPath
if (file_exists( $fileToBeStreamed )) {
//NewRelic Snippet - By JHL
transactionLog($fileToBeStreamed);
Bootstrap::streamFile( $fileToBeStreamed );
}
die();
@@ -428,7 +428,7 @@ if (Bootstrap::virtualURI( $_SERVER['REQUEST_URI'], $virtualURITable, $realPath
$realPath[0] .= strpos( basename( $realPath[0] ), '.' ) === false ? '.php' : '';
//NewRelic Snippet - By JHL
transactionLog($realPath[0]);
Bootstrap::streamFile( $realPath[0] );
die();
}
@@ -531,7 +531,7 @@ if (! defined( 'PATH_DATA' ) || ! file_exists( PATH_DATA )) {
$installer->setHttpRequestData( $_REQUEST );
//NewRelic Snippet - By JHL
transactionLog($controllerAction);
$installer->call( $controllerAction );
} else {
$_SESSION['phpFileNotFound'] = $_SERVER['REQUEST_URI'];
@@ -870,6 +870,17 @@ if (! defined( 'EXECUTE_BY_CRON' )) {
$noLoginFiles[] = 'appFolderAjax';
$noLoginFiles[] = 'steps_Ajax';
$noLoginFiles[] = 'proxyCasesList';
$noLoginFiles[] = 'casesStartPage_Ajax';
$noLoginFiles[] = 'appProxy';
$noLoginFiles[] = 'cases_Ajax';
$noLoginFiles[] = 'casesList_Ajax';
$noLoginFiles[] = 'proxyReassignCasesList';
$noLoginFiles[] = 'ajaxListener';
$noLoginFiles[] = 'cases_Step';
$noLoginFiles[] = 'cases_ShowOutputDocument';
$noLoginFiles[] = 'cases_ShowDocument';
$noLoginFiles[] = 'cases_CatchExecute';
$noLoginFiles[] = 'cases_SaveData';
$noLoginFolders[] = 'services';
$noLoginFolders[] = 'tracker';