notes, links, err fix

This commit is contained in:
Paul Liverman III 2018-04-24 21:00:29 -07:00
parent 0e52a5e936
commit 4bace26750
3 changed files with 8 additions and 4 deletions

View File

@ -16,12 +16,12 @@ class Simplex extends Application
@include locate "api" @include locate "api"
@include locate "docs" @include locate "docs"
-- TODO intentionally cause an error to see if this is working as intended
handle_error: (err, trace) => handle_error: (err, trace) =>
if @original_request.route_name\find "api_" if @original_request.route_name\find "api_"
return status: 500, json: { errors: {err}, :trace } -- NOTE trace should be saved and NOT returned to the user -- return status: 500, json: { errors: {err}, :trace } -- NOTE trace should be saved and NOT returned to the user
return status: 500, json: { errors: {err} }
else else
super! super err --, trace
[index: "/"]: => [index: "/"]: =>
@title = "Simplex Task Manager" @title = "Simplex Task Manager"

View File

@ -23,6 +23,10 @@ class extends Widget
div class: "container", -> div class: "container", ->
div class: "row", -> div class: "row", ->
div class: "column column-25 btns", -> div class: "column column-25 btns", ->
if @user
a class: "button", href: @url_for("index"), "Tasks"
else
a class: "button", href: @url_for("index"), "About"
a class: "button", href: @url_for("docs_v1"), "API Docs" a class: "button", href: @url_for("docs_v1"), "API Docs"
div class: "column column-100", -> div class: "column column-100", ->
h1(@title or "Simplex") h1(@title or "Simplex")

View File

@ -67,7 +67,7 @@ function new_api_key() {
} }
function delete_item(e) { function delete_item(e) {
e = e.parents("li"); e = $(e).parents("li");
checkbox = $("input:checkbox", e); checkbox = $("input:checkbox", e);
if (checkbox.length) { if (checkbox.length) {