This commit is contained in:
@@ -109,6 +109,10 @@ todo: AFTER ATTACHMENTS WIKI IMAGES
|
||||
|
||||
todo: after attachments - integration tests update
|
||||
|
||||
|
||||
todo: THIS! At this point, upload to dev server and thoroughly test with devices, it seems a bit slow at times
|
||||
- Might need to hide attachments until user clicks on something to reveal as it seems odd to fetch every open
|
||||
|
||||
todo: after attachments - DATADUMP - v7 wiki to RAVEN markdown
|
||||
- https://rockfish.ayanova.com/default.htm#!/rfcaseEdit/3468
|
||||
- Need to export images and attached docs as attachments
|
||||
|
||||
@@ -86,7 +86,7 @@
|
||||
<v-card-actions>
|
||||
<v-spacer></v-spacer>
|
||||
<v-btn text @click="editMenu = false">{{ $ay.t("Cancel") }}</v-btn>
|
||||
<v-btn color="primary" text @click="editClick()">{{
|
||||
<v-btn color="primary" text @click="saveEdit">{{
|
||||
$ay.t("OK")
|
||||
}}</v-btn>
|
||||
</v-card-actions>
|
||||
@@ -233,6 +233,37 @@ export default {
|
||||
this.$nextTick(() => {
|
||||
this.editMenu = true;
|
||||
});
|
||||
},
|
||||
saveEdit() {
|
||||
let vm = this;
|
||||
if (!vm.editName) {
|
||||
//todo: some error here, name is required..
|
||||
return;
|
||||
}
|
||||
//check if they differ first
|
||||
let o = null;
|
||||
for (let i = 0; i < vm.displayList.length; i++) {
|
||||
if (vm.displayList[i].id == vm.editId) {
|
||||
o = vm.displayList[i];
|
||||
break;
|
||||
}
|
||||
}
|
||||
//any changes?
|
||||
if (o.name == vm.editName && o.notes == vm.editNotes) {
|
||||
return;
|
||||
}
|
||||
|
||||
//post to server
|
||||
//get concurrency token for PUT from master list?
|
||||
//or do away with master list and just have updateDisplayList become createDisplayList (and it adds concurrency token) and
|
||||
//get called from all routes that return a list? **BETTER IDEA!**
|
||||
//todo: MAKE A PUT ROUTE then POST THIS
|
||||
|
||||
//Update item in list
|
||||
//(attempting to cheat here, rather than refresh the whole list from server)
|
||||
//but I do like a clean refresh so if this doesn't work then just call get list
|
||||
o.name = vm.editName;
|
||||
o.notes = vm.editNotes;
|
||||
}
|
||||
//-----
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user