[FIX] website_sale,website_event: can't create product and event. Why: controller and route are strict mode, remove / at the end of the route

bzr revid: chm@openerp.com-20140313132013-2foflswtdd5fp8hb
This commit is contained in:
chm@openerp.com 2014-03-13 14:20:13 +01:00
parent 9c24ebbaff
commit ba63094b9b
2 changed files with 2 additions and 2 deletions

View File

@ -187,7 +187,7 @@ class website_event(http.Controller):
}
return request.website.render("website_event.event_description_full", values)
@http.route('/event/add_event/', type='http', auth="user", multilang=True, methods=['POST'], website=True)
@http.route('/event/add_event', type='http', auth="user", multilang=True, methods=['POST'], website=True)
def add_event(self, event_name="New Event", **kwargs):
return self._add_event(event_name, request.context, **kwargs)

View File

@ -321,7 +321,7 @@ class Ecommerce(http.Controller):
context=dict(context, mail_create_nosubcribe=True))
return werkzeug.utils.redirect(request.httprequest.referrer + "#comments")
@http.route(['/shop/add_product/'], type='http', auth="user", methods=['POST'], website=True, multilang=True)
@http.route(['/shop/add_product'], type='http', auth="user", methods=['POST'], website=True, multilang=True)
def add_product(self, name=None, category=0, **post):
if not name:
name = _("New Product")