Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
356
Opening appointment dialog on single click of webdayview
posted

Hi quick and simple and if anyone can let me know how to do it I would be grateful

Currently I am opening the dialog on double click and all is well but my client wants to open on a single click of the webdayview and I have scoured the forums and docs for an answer and found nada. can this be done?

Many thanks


Richard

Parents
  • 24497
    posted

    Hi,

    Unfortunately there is no public option to replace dblclick action by click. However, since ig_webdayview.js is public by defenition (and provided by installation) anybody can look at its logic and check how browser events are processed. I can give one of the solutions (without support in case of misbehavior).
    Process ClientSideEvents.Click and DblClick and implement functions by following:

    <script type="text/javascript">

    function myClick(oDay, oEvent, src)
    {
     
    // next 3 lines are optional
     
    // check if "active" element is clicked
     
    var attr = src.getAttribute('uie');
      
    if(attr.indexOf('SLOT') != 0 && attr.indexOf('LABL') != 0 && attr.indexOf('_ADA') != 0)
        
    return;
     
    // notify webdayview about faked dblclick event
     
    oDay._onHandleEvent(src, {type:'dblclick', myEvt:true});
    }

    function myDblclick(oDay, oEvent, src)
    {
     
    // cancel real dblclick event, but keep faked event
     
    if(!oEvent.event.myEvt)
         oEvent.cancel =
    true;
    }

    </script>

    Regards,
    Viktor
    Infragistics web team

Reply Children