diff options
author | zotlabs <mike@macgirvin.com> | 2018-05-10 20:54:48 -0700 |
---|---|---|
committer | zotlabs <mike@macgirvin.com> | 2018-05-10 20:54:48 -0700 |
commit | 5dae0ef4f9be92d76260739348e7adf85c2fff19 (patch) | |
tree | 7b8512e9cd39c41119a2b2a6d0be97f9c95f2881 /view/tpl/jot-header.tpl | |
parent | 62bc5e8051ea7eb96359da5ff335a67b0e1af4ac (diff) | |
download | volse-hubzilla-5dae0ef4f9be92d76260739348e7adf85c2fff19.tar.gz volse-hubzilla-5dae0ef4f9be92d76260739348e7adf85c2fff19.tar.bz2 volse-hubzilla-5dae0ef4f9be92d76260739348e7adf85c2fff19.zip |
add cancel button to editor, fix issue with autosave of categories
Diffstat (limited to 'view/tpl/jot-header.tpl')
-rwxr-xr-x | view/tpl/jot-header.tpl | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/view/tpl/jot-header.tpl b/view/tpl/jot-header.tpl index df67e9b2d..f2b68ece0 100755 --- a/view/tpl/jot-header.tpl +++ b/view/tpl/jot-header.tpl @@ -357,6 +357,14 @@ var activeCommentText = ''; } } + function itemCancel() { + $("#jot-title").val(''); + $("#profile-jot-text").val(''); + $("#jot-category").val(''); + postSaveChanges('clean',''); + window.history.back(); + } + function itemFiler(id) { if($('#item-filer-dialog').length) $('#item-filer-dialog').remove(); @@ -575,7 +583,7 @@ $( document ).on( "click", ".wall-item-delete-link,.page-delete-link,.layout-del localStorage.setItem("post_title" + postid, $("#jot-title").val()); localStorage.setItem("post_body" + postid, $("#profile-jot-text").val()); if($("#jot-category").length) - localStorage.setItem("post_category + postid", $("#jot-category").val()); + localStorage.setItem("post_category" + postid, $("#jot-category").val()); } if(action == 'start') { |