# HG changeset patch # User sylvain.thenault@logilab.fr # Date 1242292138 -7200 # Thu May 14 11:08:58 2009 +0200 # Node ID 10e012a60087dd4e4d162ae3cb47720fa85ee904 # Parent cd8d4a6091ecf3e5637567d61469885681105bde use new request method diff --git a/views.py b/views.py --- a/views.py +++ b/views.py @@ -20,7 +20,7 @@ from cubicweb.view import EntityView from cubicweb.common.uilib import rql_for_eid, cut, safe_cut from cubicweb.common.mixins import TreeViewMixIn -from cubicweb.web import ajax_replace_url, stdmsgs, uicfg +from cubicweb.web import stdmsgs, uicfg from cubicweb.web.action import LinkToEntityAction, Action from cubicweb.web.form import FormViewMixIn from cubicweb.web.formwidgets import Button @@ -109,15 +109,17 @@ if action is None: reply = u'' else: - url = ajax_replace_url('comment%sHolder' % entity.eid, - rql_for_eid(entity.eid), 'inlinecomment') + url = self.req.build_ajax_replace_url( + 'comment%sHolder' % entity.eid, rql_for_eid(entity.eid), + 'inlinecomment') reply = ' | <a href="%s">%s</a>' % (html_escape(url), _(action.title)) if editaction is None: edit = u'' else: - url = ajax_replace_url('comment%s' % entity.eid, - rql_for_eid(entity.eid), 'editcomment') + url = self.req.build_ajax_replace_url( + 'comment%s' % entity.eid, rql_for_eid(entity.eid), + 'editcomment') edit = ' | <a href="%s">%s</a>' % (html_escape(url), _(editaction.title)) text = entity.printable_value('content') @@ -217,8 +219,8 @@ self.div_id(), self.div_class(), eid)) action = self.vreg.select_action('reply_comment', req, self.rset, row=0) if action is not None: - url = ajax_replace_url('comment%sHolder' % eid, rql_for_eid(eid), - 'inlinecomment') + url = self.req.build_ajax_replace_url( + 'comment%sHolder' % eid, rql_for_eid(eid), 'inlinecomment') reply = u' (<a href="%s">%s</a>)' % (url, req._(action.title)) if req.use_fckeditor() and req.property_value('ui.default-text-format') == 'text/html': req.fckeditor_config()