Add forward and UTF note boxes
This commit is contained in:
parent
fd0232a694
commit
2f1dc4d368
@ -66,6 +66,8 @@ function saveNote(id) {
|
||||
zipcode: "",
|
||||
route: "",
|
||||
notes: "",
|
||||
forwards: "",
|
||||
utfs: "",
|
||||
toggles: {}
|
||||
};
|
||||
if (exists) {
|
||||
@ -77,6 +79,8 @@ function saveNote(id) {
|
||||
note.zipcode = $("input[name=zipcode]").val().trim();
|
||||
note.route = $("input[name=route]").val().trim().toUpperCase();
|
||||
note.notes = $("textarea#notes").val().trim();
|
||||
note.forwards = $("textarea#forwards").val().trim();
|
||||
note.utfs = $("textarea#utfs").val().trim();
|
||||
|
||||
if (note.number == "") {
|
||||
app.dialog.alert("Fill in an address number.", "Error");
|
||||
@ -161,6 +165,13 @@ $(".view-main").on("click", ".editnotebtn", function () {
|
||||
});
|
||||
}
|
||||
|
||||
if (typeof note.forwards == "undefined") {
|
||||
note.forwards = "";
|
||||
}
|
||||
if (typeof note.utfs == "undefined") {
|
||||
note.utfs = "";
|
||||
}
|
||||
|
||||
router.navigate("/myroute/editnote", {
|
||||
context: {
|
||||
title: "Edit Note",
|
||||
|
@ -56,6 +56,12 @@
|
||||
{{#if notes}}
|
||||
<p>{{newlinestobr notes}}</p>
|
||||
{{/if}}
|
||||
{{#if forwards}}
|
||||
<p><b><i class="fas fa-forward"></i></b> {{newlinestobr forwards}}</p>
|
||||
{{/if}}
|
||||
{{#if utfs}}
|
||||
<p><b><span class="fa-stack"><i class="fas fa-forward"></i><i class="fas fa-slash"></i></span></b> {{newlinestobr utfs}}</p>
|
||||
{{/if}}
|
||||
<div class="margin-vertical-half">
|
||||
<ul>
|
||||
{{#each toggles}}
|
||||
|
@ -93,6 +93,26 @@
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
<li class="item-divider">Forwards</li>
|
||||
<li class="item-content item-input">
|
||||
<div class="item-inner">
|
||||
<div class="item-input-wrap">
|
||||
<textarea id="forwards">{{note.forwards}}</textarea>
|
||||
<span class="input-clear-button"></span>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
<li class="item-divider">UTFs</li>
|
||||
<li class="item-content item-input">
|
||||
<div class="item-inner">
|
||||
<div class="item-input-wrap">
|
||||
<textarea id="utfs">{{note.utfs}}</textarea>
|
||||
<span class="input-clear-button"></span>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -191,6 +191,8 @@ var routes = [
|
||||
zipcode: inStorage("zipcode") ? getStorage("zipcode") : "",
|
||||
route: inStorage("lastrouteid") ? getStorage("lastrouteid") : "",
|
||||
notes: "",
|
||||
forwards: "",
|
||||
utfs: "",
|
||||
toggles: {}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user