forked from Techsystech/web
test controller
parent
681700adea
commit
324cf5f27a
|
@ -36,5 +36,4 @@
|
|||
'static/src/xml/popup_help.xml',
|
||||
],
|
||||
'installable': True,
|
||||
'auto_install': False,
|
||||
}
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
##############################################################################
|
||||
|
||||
from openerp import models, fields
|
||||
from openerp.http import Controller, route
|
||||
|
||||
|
||||
class IrActionsActwindow(models.Model):
|
||||
|
@ -29,3 +30,8 @@ class IrActionsActwindow(models.Model):
|
|||
string="Custom Help",
|
||||
help="Use this field to add custom content for documentation purpose")
|
||||
|
||||
|
||||
class MyController(Controller):
|
||||
@route('/help', auth='public')
|
||||
def handler(self):
|
||||
return 'blabla'
|
||||
|
|
|
@ -14,6 +14,9 @@ openerp.help_contextual_popup = function(instance, local) {
|
|||
$elem.data('click-init', true);
|
||||
|
||||
var help_html = '';
|
||||
help_html += '<a href="http://localhost:8069/help" target="_blank" onclick="window.open(this.href,\'nom_Popup\','
|
||||
help_html += '\'height=400 , width=400 , location=no , resizable=yes , scrollbars=no\');return false;">'
|
||||
help_html += '→ Exemple ←</a>'
|
||||
if (self.action.help) {
|
||||
help_html += '<h3>Odoo Help</h3>'
|
||||
help_html += '<div id="erp_help">' + self.action.help + '</div>';
|
||||
|
|
Loading…
Reference in New Issue