Backend update renamed controllers and models to be singular
This commit is contained in:
@@ -26,7 +26,7 @@
|
||||
this.click++
|
||||
},
|
||||
actuallyDelete(){
|
||||
axios.post('/api/notes/delete', {'noteId':this.noteId}).then(response => {
|
||||
axios.post('/api/note/delete', {'noteId':this.noteId}).then(response => {
|
||||
if(response.data == true){
|
||||
this.$bus.$emit('note_deleted')
|
||||
}
|
||||
|
@@ -143,7 +143,7 @@
|
||||
let vm = this
|
||||
//Component is activated with NoteId in place, lookup text with associated ID
|
||||
if(this.$store.getters.getLoggedIn){
|
||||
axios.post('/api/notes/get', {'noteId': noteId})
|
||||
axios.post('/api/note/get', {'noteId': noteId})
|
||||
.then(response => {
|
||||
|
||||
//Set up local data
|
||||
@@ -248,7 +248,7 @@
|
||||
this.saveDebounce = setTimeout(() => {
|
||||
//Only notify user if saving - may help with debugging in the future
|
||||
vm.statusText = 'Saving'
|
||||
axios.post('/api/notes/update', postData).then( response => {
|
||||
axios.post('/api/note/update', postData).then( response => {
|
||||
vm.statusText = 'Saved'
|
||||
vm.updated = Math.round((+new Date)/1000)
|
||||
|
||||
|
@@ -45,7 +45,7 @@
|
||||
getTags(){
|
||||
//Get Note Tags -> /api/tags/get
|
||||
let vm = this
|
||||
axios.post('/api/tags/get', {'noteId': this.noteId})
|
||||
axios.post('/api/tag/get', {'noteId': this.noteId})
|
||||
.then(response => {
|
||||
//Set up local data
|
||||
vm.tags = response.data
|
||||
@@ -105,7 +105,7 @@
|
||||
'noteId':vm.noteId
|
||||
}
|
||||
|
||||
axios.post('/api/tags/suggest', postData)
|
||||
axios.post('/api/tag/suggest', postData)
|
||||
.then(response => {
|
||||
|
||||
vm.suggestions = response.data
|
||||
@@ -130,7 +130,7 @@
|
||||
'noteId':this.noteId
|
||||
}
|
||||
let vm = this
|
||||
axios.post('/api/tags/addtonote', postData)
|
||||
axios.post('/api/tag/addtonote', postData)
|
||||
.then(response => {
|
||||
vm.newTagInput = ''
|
||||
vm.clearSuggestions()
|
||||
@@ -155,7 +155,7 @@
|
||||
'noteId':this.noteId
|
||||
}
|
||||
let vm = this
|
||||
axios.post('/api/tags/removefromnote', postData)
|
||||
axios.post('/api/tag/removefromnote', postData)
|
||||
.then(response => {
|
||||
vm.getTags()
|
||||
})
|
||||
|
@@ -196,7 +196,7 @@
|
||||
}
|
||||
//Perform search
|
||||
let vm = this
|
||||
axios.post('/api/notes/search', postData).
|
||||
axios.post('/api/note/search', postData).
|
||||
then(response => {
|
||||
console.log('Notes and Tags')
|
||||
console.log(response.data)
|
||||
@@ -217,7 +217,7 @@
|
||||
const title = ''
|
||||
let vm = this
|
||||
|
||||
axios.post('/api/notes/create', {title})
|
||||
axios.post('/api/note/create', {title})
|
||||
.then(response => {
|
||||
|
||||
if(response.data && response.data.id){
|
||||
|
Reference in New Issue
Block a user