'Duplicate a blog.
:param blog_post_id: id of the blog post currently browsed.
:return redirect to the new blog created'

@http.route('/blog/post_duplicate', type='http', auth='public', website=True, methods=['POST'])
def blog_post_copy(self, blog_post_id, **post):

    new_blog_post = request.env['blog.post'].with_context(mail_create_nosubscribe=True).browse(int(blog_post_id)).copy()
    return werkzeug.utils.redirect(('/blog/%s/post/%s?enable_editor=1' % (slug(new_blog_post.blog_id), slug(new_blog_post))))
