utils.py
changeset 4903 627fcd90e08f
parent 4899 c666d265fb95
child 4961 03e083faefbf
equal deleted inserted replaced
4902:4e67a538e476 4903:627fcd90e08f
   158     def add_onload(self, jscode, jsoncall=_MARKER):
   158     def add_onload(self, jscode, jsoncall=_MARKER):
   159         if jsoncall is not _MARKER:
   159         if jsoncall is not _MARKER:
   160             warn('[3.7] specifying jsoncall is not needed anymore',
   160             warn('[3.7] specifying jsoncall is not needed anymore',
   161                  DeprecationWarning, stacklevel=2)
   161                  DeprecationWarning, stacklevel=2)
   162         self.add_post_inline_script(u"""jQuery(CubicWeb).one('server-response', function(event) {
   162         self.add_post_inline_script(u"""jQuery(CubicWeb).one('server-response', function(event) {
   163 });""" % jscode)
   163 %s});""" % jscode)
   164 
   164 
   165 
   165 
   166     def add_js(self, jsfile):
   166     def add_js(self, jsfile):
   167         """adds `jsfile` to the list of javascripts used in the webpage
   167         """adds `jsfile` to the list of javascripts used in the webpage
   168 
   168