Hi All,
I have placed some custom code as mentioned below.
Component:CRM_UI_FRAME
View:Workareaviewset
Page:Workareaviewset.htm
What the below code does if the user is ideal for 5 min in CRM Web ui screen it will give popup saying your session is going to end if we don't perform any activity in the session..
In my case it's giving popup and if they click on ok ..again it's resetting the time.
But if the user did not confirm the popup either 'Yes' or 'No' it should by default logout after reaching the maximum session time out based on the parameter.(rdisp/plugin_auto_logout).
Currently it's not doing anything until user perform some action on the popup..I need help in How we can achieve if user didn't not performed any action on the popup after certain time to come out of the session or proceed further with remaining code in BSP.
if we can come out from that popup SAP will automatically take care of default logout.
I appreciate your help on this.
<script type="text/javascript">
var c=300;
var t;
var timer_is_on=0;
document.onclick = function() {
c = 300;
if (!timer_is_on)
{
timer_is_on=1;
timedCount();
}
};
document.onmousemove = function() {
c = 300;
if (!timer_is_on)
{
timer_is_on=1;
timedCount();
}
};
document.onkeypress = function() {
c = 300;
if (!timer_is_on)
{
timer_is_on=1;
timedCount();
}
};
thtmlbRegisterOnLoad(doTimer);
function timedCount()
{
c=c-1;
if (c == '0')
{
<%--alert("Your session will time out in 5 minutes") ; --%>
var r = confirm("Your session will time out in 5 minutes!");
}
t=setTimeout("timedCount()",1000);
}
function doTimer()
{
c = 300;
if (!timer_is_on)
{
timer_is_on=1;
timedCount();
}
}
</script>
Thanks,
Sara.