Se rendre au contenu
Menu
Cette question a été signalée
1 Répondre
4102 Vues

I am trying to plug some of my javascript function for CRM module in openerp. what i want to achieve is -

  • disable right click
  • disable text selection.

Here below is the code of my js function.

 noRightClick = function () {
    document.oncontextmenu = function(){ return false; };
  };

and

noSelect = function () {
    document.onselectstart = function () {
      if (event.srcElement.type != "text" && event.srcElement.type != "textarea" && event.srcElement.type != "password") {
        return false;
      } else {
        return true;
      }
    };

Please suggest where should i place these functions, so that it applicable to only CRM module.

Thanks in advance...

Avatar
Ignorer
Meilleure réponse

You can find information on how to do that on the web module documentation:

https://doc.openerp.com/trunk/web/module/ https://doc.openerp.com/trunk/training/

Avatar
Ignorer
Publications associées Réponses Vues Activité
2
juil. 25
1224
2
avr. 25
1629
1
mai 25
8617
0
mars 15
4101
1
juin 25
972