PM-3739: 18719: Urgent help required with ProcessMaker on IE 11
This commit is contained in:
@@ -179,6 +179,12 @@ if (count($arrayTabItem) > 0) {
|
||||
$headPublisher->assign("urlProxy", $urlProxy);
|
||||
$headPublisher->assign('credentials', $clientToken );
|
||||
|
||||
$ieVersion = null;
|
||||
if(preg_match("/^.*\(.*MSIE (\d+)\..+\).*$/", $_SERVER["HTTP_USER_AGENT"], $arrayMatch) || preg_match("/^.*\(.*rv.(\d+)\..+\).*$/", $_SERVER["HTTP_USER_AGENT"], $arrayMatch)){
|
||||
$ieVersion = intval($arrayMatch[1]);
|
||||
}
|
||||
$oHeadPublisher->assign( 'ieVersion', $ieVersion );
|
||||
|
||||
$headPublisher->addExtJsScript("app/main", true);
|
||||
$headPublisher->addExtJsScript("cases/casesListConsolidated", false); //Adding a JavaScript file .js
|
||||
$headPublisher->addContent("cases/casesListConsolidated"); //Adding a HTML file .html
|
||||
|
||||
@@ -187,7 +187,12 @@ try {
|
||||
$loc = $aNextStep['PAGE'];
|
||||
}
|
||||
//Triggers After
|
||||
if (isset( $_SESSION['TRIGGER_DEBUG']['ISSET'] )) {
|
||||
$ieVersion = null;
|
||||
if(preg_match("/^.*\(.*MSIE (\d+)\..+\).*$/", $_SERVER["HTTP_USER_AGENT"], $arrayMatch) || preg_match("/^.*\(.*rv.(\d+)\..+\).*$/", $_SERVER["HTTP_USER_AGENT"], $arrayMatch)){
|
||||
$ieVersion = intval($arrayMatch[1]);
|
||||
}
|
||||
|
||||
if (isset( $_SESSION['TRIGGER_DEBUG']['ISSET'] ) && $ieVersion != 11) {
|
||||
if ($_SESSION['TRIGGER_DEBUG']['ISSET'] == 1) {
|
||||
$oTemplatePower = new TemplatePower( PATH_TPL . 'cases/cases_Step.html' );
|
||||
$oTemplatePower->prepare();
|
||||
@@ -205,10 +210,7 @@ try {
|
||||
}
|
||||
|
||||
//close tab only if IE11
|
||||
$ieVersion = null;
|
||||
if(preg_match("/^.*\(.*MSIE (\d+)\..+\).*$/", $_SERVER["HTTP_USER_AGENT"], $arrayMatch) || preg_match("/^.*\(.*rv.(\d+)\..+\).*$/", $_SERVER["HTTP_USER_AGENT"], $arrayMatch)){
|
||||
$ieVersion = intval($arrayMatch[1]);
|
||||
}
|
||||
|
||||
if($ieVersion == 11 && !isset($_SESSION['__OUTLOOK_CONNECTOR__'])) {
|
||||
$script = "<script type='text/javascript'>
|
||||
try {
|
||||
|
||||
@@ -177,7 +177,12 @@ if (isset( $_GET['breakpoint'] )) {
|
||||
/**
|
||||
* Here we throw the debug view
|
||||
*/
|
||||
if (isset( $_GET['breakpoint'] )) {
|
||||
$ieVersion = null;
|
||||
if(preg_match("/^.*\(.*MSIE (\d+)\..+\).*$/", $_SERVER["HTTP_USER_AGENT"], $arrayMatch) || preg_match("/^.*\(.*rv.(\d+)\..+\).*$/", $_SERVER["HTTP_USER_AGENT"], $arrayMatch)){
|
||||
$ieVersion = intval($arrayMatch[1]);
|
||||
}
|
||||
|
||||
if (isset( $_GET['breakpoint'] ) && $ieVersion != 11) {
|
||||
|
||||
$G_PUBLISH->AddContent( 'view', 'cases/showDebugFrameLoader' );
|
||||
$G_PUBLISH->AddContent( 'view', 'cases/showDebugFrameBreaker' );
|
||||
@@ -1124,7 +1129,7 @@ if (!isset($_SESSION["PM_RUN_OUTSIDE_MAIN_APP"])) {
|
||||
|
||||
G::RenderPage( 'publish', 'blank' );
|
||||
|
||||
if ($_SESSION['TRIGGER_DEBUG']['ISSET']) {
|
||||
if ($_SESSION['TRIGGER_DEBUG']['ISSET'] && $ieVersion != 11) {
|
||||
G::evalJScript( '
|
||||
if (typeof showdebug != \'undefined\') {
|
||||
showdebug();
|
||||
|
||||
@@ -229,6 +229,7 @@ var htmlMessage;
|
||||
//var rowLabels = [];
|
||||
|
||||
var smodel;
|
||||
var newCaseNewTab;
|
||||
|
||||
function openCase(){
|
||||
var rowModel = consolidatedGrid.getSelectionModel().getSelected();
|
||||
@@ -236,7 +237,7 @@ function openCase(){
|
||||
var appUid = rowModel.data.APP_UID;
|
||||
var delIndex = rowModel.data.DEL_INDEX;
|
||||
var caseTitle = (rowModel.data.APP_TITLE) ? rowModel.data.APP_TITLE : rowModel.data.APP_UID;
|
||||
|
||||
if(ieVersion != 11) {
|
||||
Ext.Msg.show({
|
||||
msg: _("ID_OPEN_CASE") + " " + caseTitle,
|
||||
width:300,
|
||||
@@ -245,6 +246,7 @@ function openCase(){
|
||||
interval:200
|
||||
}
|
||||
});
|
||||
}
|
||||
params = '';
|
||||
switch(action){
|
||||
case 'consolidated':
|
||||
@@ -255,15 +257,24 @@ function openCase(){
|
||||
break;
|
||||
}
|
||||
params += '&action=' + 'todo';
|
||||
redirect(requestFile + '?' + params);
|
||||
|
||||
if(ieVersion == 11) {
|
||||
if(newCaseNewTab) {
|
||||
newCaseNewTab.close();
|
||||
}
|
||||
newCaseNewTab = window.open(requestFile + '?' + params);
|
||||
} else {
|
||||
redirect(requestFile + '?' + params);
|
||||
}
|
||||
} else {
|
||||
msgBox(_("ID_INFORMATION"), _("ID_SELECT_ONE_AT_LEAST"));
|
||||
}
|
||||
}
|
||||
|
||||
function jumpToCase(appNumber){
|
||||
if(ieVersion != 11) {
|
||||
Ext.MessageBox.show({ msg: _('ID_PROCESSING'), wait:true,waitConfig: {interval:200} });
|
||||
}
|
||||
Ext.Ajax.request({
|
||||
url: 'cases_Ajax',
|
||||
success: function(response) {
|
||||
@@ -272,7 +283,14 @@ function jumpToCase(appNumber){
|
||||
params = 'APP_NUMBER=' + appNumber;
|
||||
params += '&action=jump';
|
||||
requestFile = '../cases/open';
|
||||
if(ieVersion == 11) {
|
||||
if(newCaseNewTab) {
|
||||
newCaseNewTab.close();
|
||||
}
|
||||
newCaseNewTab = window.open(requestFile + '?' + params);
|
||||
} else {
|
||||
redirect(requestFile + '?' + params);
|
||||
}
|
||||
} else {
|
||||
Ext.MessageBox.hide();
|
||||
var message = new Array();
|
||||
@@ -1342,3 +1360,8 @@ function linkRenderer(value)
|
||||
return "<a href=\"" + value + "\" onclick=\"window.open('" + value + "', '_blank'); return false;\">" + value + "</a>";
|
||||
}
|
||||
|
||||
Ext.EventManager.on(window, 'beforeunload', function () {
|
||||
if(newCaseNewTab) {
|
||||
newCaseNewTab.close();
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user