Merged in jonathanquispe/processmaker/pm2153 (pull request #2145)
pm2153
This commit is contained in:
@@ -31,7 +31,11 @@
|
|||||||
|
|
||||||
$G_PUBLISH = new Publisher();
|
$G_PUBLISH = new Publisher();
|
||||||
//echo G::generateUniqueNumber();
|
//echo G::generateUniqueNumber();
|
||||||
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'tracker/login', '', '', SYS_URI . 'tracker/authentication.php' );
|
if(SYS_SKIN == 'neoclassic'){
|
||||||
|
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'tracker/loginpm3', '', '', SYS_URI . 'tracker/authentication.php' );
|
||||||
|
}else{
|
||||||
|
$G_PUBLISH->AddContent( 'xmlform', 'xmlform', 'tracker/login', '', '', SYS_URI . 'tracker/authentication.php' );
|
||||||
|
}
|
||||||
|
|
||||||
G::RenderPage( "publish" );
|
G::RenderPage( "publish" );
|
||||||
session_destroy();
|
session_destroy();
|
||||||
|
|||||||
@@ -734,7 +734,11 @@ class SkinEngine
|
|||||||
$switch_interface = isset($_SESSION['user_experience']) && $_SESSION['user_experience'] == 'SWITCHABLE';
|
$switch_interface = isset($_SESSION['user_experience']) && $_SESSION['user_experience'] == 'SWITCHABLE';
|
||||||
|
|
||||||
$smarty->assign('user_logged', (isset($_SESSION['USER_LOGGED'])? $_SESSION['USER_LOGGED'] : ''));
|
$smarty->assign('user_logged', (isset($_SESSION['USER_LOGGED'])? $_SESSION['USER_LOGGED'] : ''));
|
||||||
|
if(SYS_SKIN == 'neoclassic'){
|
||||||
|
$smarty->assign('tracker', (SYS_COLLECTION == 'tracker') ? ( ($G_PUBLISH->Parts[0]['File'] != 'tracker/loginpm3' ) ? true : '') : '');
|
||||||
|
}else{
|
||||||
$smarty->assign('tracker', (SYS_COLLECTION == 'tracker') ? ( ($G_PUBLISH->Parts[0]['File'] != 'tracker/login' ) ? true : '') : '');
|
$smarty->assign('tracker', (SYS_COLLECTION == 'tracker') ? ( ($G_PUBLISH->Parts[0]['File'] != 'tracker/login' ) ? true : '') : '');
|
||||||
|
}
|
||||||
$smarty->assign('switch_interface', $switch_interface);
|
$smarty->assign('switch_interface', $switch_interface);
|
||||||
$smarty->assign('switch_interface_label', G::LoadTranslation('ID_SWITCH_INTERFACE'));
|
$smarty->assign('switch_interface_label', G::LoadTranslation('ID_SWITCH_INTERFACE'));
|
||||||
$smarty->assign('rolename', isset($_SESSION['USR_ROLENAME']) ? $_SESSION['USR_ROLENAME'] . '' : '');
|
$smarty->assign('rolename', isset($_SESSION['USR_ROLENAME']) ? $_SESSION['USR_ROLENAME'] . '' : '');
|
||||||
|
|||||||
25
workflow/engine/xmlform/tracker/loginpm3.html
Normal file
25
workflow/engine/xmlform/tracker/loginpm3.html
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
<form accept-charset="UTF-8" role="form" class="form-signin" id="{$form_id}" name="{$form_name}" action="{$form_action}" method="post" encType="multipart/form-data" style="margin:0px;" onsubmit="return validateForm('{$form_objectRequiredFields}');">
|
||||||
|
<input type="hidden" class="notValidateThisFields" name="__notValidateThisFields__" id="__notValidateThisFields__" value="{$form_objectRequiredFields}" />
|
||||||
|
<input type="hidden" name="DynaformRequiredFields" id="DynaformRequiredFields" value="{$form_objectRequiredFields}" />
|
||||||
|
<input type="hidden" name="__DynaformName__" id="__DynaformName__" value="{$form_name}" />
|
||||||
|
<fieldset>
|
||||||
|
<label class="panel-login">
|
||||||
|
<div class="login_result"><h4>{$form.TITLE}</h4></div>
|
||||||
|
</label>
|
||||||
|
{$form.USR_USERNAME}
|
||||||
|
{$form.CASE}
|
||||||
|
{$form.PIN}
|
||||||
|
|
||||||
|
</fieldset>
|
||||||
|
<fieldset>
|
||||||
|
<label class="panel-login">
|
||||||
|
<div class="login_result"></div>
|
||||||
|
</label>
|
||||||
|
{$form.BSUBMIT}
|
||||||
|
</fieldset>
|
||||||
|
<script type="text/javascript">
|
||||||
|
{$form.JS}
|
||||||
|
</script>
|
||||||
|
</form>
|
||||||
|
<script src="/lib/pmdynaform/libs/respondjs/respond.min.js"></script>
|
||||||
|
<script src="/lib/pmdynaform/libs/html5shiv/html5shiv.js"></script>
|
||||||
69
workflow/engine/xmlform/tracker/loginpm3.xml
Normal file
69
workflow/engine/xmlform/tracker/loginpm3.xml
Normal file
@@ -0,0 +1,69 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<dynaForm name="login" version="1.0" basedir="" xmlform_type="NORMAL" width="400px" enabletemplate ="1">
|
||||||
|
<TITLE type="title">
|
||||||
|
<en><![CDATA[CASE TRACKER]]></en>
|
||||||
|
</TITLE>
|
||||||
|
<CASE type="Text" size="30" maxlength="50" validate="Any">
|
||||||
|
<en><![CDATA[Case Code]]></en>
|
||||||
|
</CASE>
|
||||||
|
<PIN type="password" size="30" maxlength="32">
|
||||||
|
<en><![CDATA[Pin]]></en>
|
||||||
|
</PIN>
|
||||||
|
<BSUBMIT type="submit">
|
||||||
|
<en><![CDATA[Enter]]></en>
|
||||||
|
</BSUBMIT>
|
||||||
|
<JS type="javascript"><![CDATA[
|
||||||
|
|
||||||
|
function getElementsByClassNameIE8(node, classname) {
|
||||||
|
var a = [];
|
||||||
|
var re = new RegExp('(^| )'+classname+'( |$)');
|
||||||
|
var els = node.getElementsByTagName("*");
|
||||||
|
for(var i=0,j=els.length; i<j; i++)
|
||||||
|
if(re.test(els[i].className))a.push(els[i]);
|
||||||
|
return a;
|
||||||
|
};
|
||||||
|
|
||||||
|
window.onload= function(){
|
||||||
|
var inputCode,
|
||||||
|
inputPin;
|
||||||
|
if(document.getElementById('form[BSUBMIT]').classList == undefined && document.getElementById('form[CASE]').placeholder === undefined){
|
||||||
|
document.getElementById('form[BSUBMIT]').className = "button-login-success";
|
||||||
|
document.getElementById('form[CASE]').value = _('ID_CASE_CODE');
|
||||||
|
document.getElementById('form[PIN]').value = _('ID_PIN');
|
||||||
|
document.getElementById('form[PIN]').title = _('ID_PIN');
|
||||||
|
|
||||||
|
inputCode = document.getElementById('form[CASE]');
|
||||||
|
inputPin = document.getElementById('form[PIN]');
|
||||||
|
|
||||||
|
inputCode.attachEvent("onclick", function (){
|
||||||
|
if(_('ID_CASE_CODE') == inputCode.value){
|
||||||
|
inputCode.value="";
|
||||||
|
}
|
||||||
|
});
|
||||||
|
inputCode.attachEvent("onblur", function (){
|
||||||
|
if(inputCode.value == ""){
|
||||||
|
inputCode.value=_('ID_CASE_CODE');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
inputPin.attachEvent("onclick", function (){
|
||||||
|
if(_('ID_PIN') == inputPin.value){
|
||||||
|
inputPin.value="";
|
||||||
|
}
|
||||||
|
});
|
||||||
|
inputPin.attachEvent("onblur", function (){
|
||||||
|
if(inputPin.value == ""){
|
||||||
|
inputPin.value=_('ID_PIN');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
}else{
|
||||||
|
document.getElementById('form[BSUBMIT]').classList.remove('module_app_button___gray');
|
||||||
|
document.getElementById('form[BSUBMIT]').classList.add('button-login-success');
|
||||||
|
document.getElementById('form[CASE]').placeholder = _('ID_CASE_CODE');
|
||||||
|
document.getElementById('form[PIN]').placeholder = _('ID_PIN');
|
||||||
|
}
|
||||||
|
};
|
||||||
|
]]></JS>
|
||||||
|
</dynaForm>
|
||||||
Reference in New Issue
Block a user