示例#1
0
def delete(_resp, id):
    cmd = curso_facade.delete_curso_cmd(id)
    try:
        cmd()
    except CommandExecutionException:
        _resp.status_code = 500
        return JsonResponse(cmd.errors)
示例#2
0
def delete(curso_id):
    curso_facade.delete_curso_cmd(curso_id)()
    return RedirectResponse(router.to_path(index))