Commit df4178c7 authored by Anton's avatar Anton

Replace all model property occurrences of uuid with _uuid

parent fc1aa4bb
......@@ -110,7 +110,7 @@
const results = await this.$store.dispatch('annotations/find', { 'target.id': payload.id })
for (let item of results.items) {
const itemPayload = ObjectUtil.merge({}, payload)
itemPayload.uuid = item.uuid
itemPayload._uuid = item._uuid
await this.$store.dispatch(action, payload)
}
}
......
......@@ -127,13 +127,13 @@
submit: {
handler () {
context.payload.author = context.$store.state.auth.payload.userId
if (!context.$route.params.id) {
if (!context.$route.params.uuid) {
context.payload.type = [constants.MAP_TYPE_TIMELINE]
}
return Promise.resolve()
.then(() => {
if (context.payload.uuid) {
return context.$store.dispatch('maps/patch', [context.payload.uuid, context.payload])
if (context.payload._uuid) {
return context.$store.dispatch('maps/patch', [context.payload._uuid, context.payload])
}
return context.$store.dispatch('maps/create', context.payload)
})
......
......@@ -106,7 +106,7 @@
}
else if (this.type === 'video/panopto' && annotation) {
this.type = 'video/mp4'
const meta = await this.$store.dispatch('metadata/get', annotation.uuid)
const meta = await this.$store.dispatch('metadata/get', annotation._uuid)
if (meta && meta.video) src = meta.video
else console.error('panopto video failed to load', meta.video)
}
......
......@@ -20,7 +20,7 @@
template(slot="top-right", slot-scope="props")
q-search(hide-underline, v-model="filter", dark)
q-td(slot="body-cell-title", slot-scope="props", :props="props")
router-link.primary(v-if="hasShow", :to="getViewLink(props.row.uuid)")
router-link.primary(v-if="hasShow", :to="getViewLink(props.row._uuid)")
promise-span(:value="props.value")
promise-span(v-if="!hasShow", :value="props.value")
q-td(slot="body-cell-tags", slot-scope="props", :props="props")
......@@ -113,7 +113,7 @@
if (btn.type === 'delete') {
this.loading = true
try {
await this.$store.dispatch(`${this.path}/delete`, props.row.uuid)
await this.$store.dispatch(`${this.path}/delete`, props.row._uuid)
}
catch (err) {
if (typeof this.$captureException === 'function') this.$captureException(err)
......
......@@ -67,8 +67,8 @@
let a = _this.annotations.find(a => {
return a.body.value === t
})
// console.log('remove', a.uuid, t)
if (a && a.uuid) return this.$store.dispatch('annotations/remove', a.uuid)
// console.log('remove', a._uuid, t)
if (a && a._uuid) return this.$store.dispatch('annotations/remove', a._uuid)
return null
})
......@@ -118,7 +118,7 @@
.then(annotations => {
_this.annotations = annotations.filter(a => a.target.id === _this.timeline.id) // TODO: Anton, why is target id ignored in the query?
let newTags = annotations.map(a => {
// this.$store.dispatch('annotations/remove', a.uuid) // clean up tags
// this.$store.dispatch('annotations/remove', a._uuid) // clean up tags
return a.body.value
})
newTags = this.enforceUniqueTags(newTags)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment