diff --git a/src/components/paneDisplayComponents/galleryComponents/captureCard.vue b/src/components/paneDisplayComponents/galleryComponents/captureCard.vue index d538de6b..8c221614 100644 --- a/src/components/paneDisplayComponents/galleryComponents/captureCard.vue +++ b/src/components/paneDisplayComponents/galleryComponents/captureCard.vue @@ -3,28 +3,53 @@
- - + +

{{ metadata.filename }}

-

- + +
+
+
+ More... +
+
+
-
+
+ +
+ +

{{ metadata.filename }}

+

Time: {{ betterTimestring }}

+

ID: {{ metadata.id }}

+

Format: {{ metadata.format }}

+

Path: {{ metadata.path }}

+ +
+

{{ key }}: {{ value }}

+
+
+ +
+ +
@@ -71,7 +96,7 @@ export default { methods: { handleTagSubmit: function(event) { - console.log(this.TagURL); + console.log(this.tagURL); console.log(this.newtag); this.newTagRequest(this.newtag); this.newtag = ""; @@ -80,7 +105,7 @@ export default { newTagRequest: function(tag_string) { // Send tag PUT request - axios.put(this.TagURL, [tag_string]) + axios.put(this.tagURL, [tag_string]) .then(response => { // Update tag array this.getTagRequest() @@ -102,7 +127,7 @@ export default { delTagRequest: function(tag_string) { console.log(tag_string) // Send tag DELETE request - axios.delete(this.TagURL, {data: [tag_string]}) + axios.delete(this.tagURL, {data: [tag_string]}) .then(response => { // Update tag array this.getTagRequest() @@ -114,7 +139,7 @@ export default { getTagRequest: function() { // Send tag request - axios.get(this.TagURL) + axios.get(this.tagURL) .then(response => { this.tags = response.data.metadata.tags }) @@ -134,20 +159,32 @@ export default { }, computed: { - TagModalID: function () { + tagModalID: function () { return this.makeModalName("tag-modal-") }, - TagModalTarget: function () { - return "#" + this.TagModalID + tagModalTarget: function () { + return "#" + this.tagModalID }, - ThumbURL: function () { + metadataModalID: function () { + return this.makeModalName("metadata-modal-") + }, + metadataModalTarget: function () { + return "#" + this.metadataModalID + }, + thumbURL: function () { return this.$store.getters.uri + "/camera/capture/" + this.metadata.id + "/download?thumbnail=true" }, - ImgURL: function () { + imgURL: function () { return this.$store.getters.uri + "/camera/capture/" + this.metadata.id + "/download/" + this.metadata.filename }, - TagURL: function () { + tagURL: function () { return this.$store.getters.uri + "/camera/capture/" + this.metadata.id + "/tags" + }, + betterTimestring: function () { + var dtSplit = this.metadata.time.split("_"); + var date = dtSplit[0] + var time = dtSplit[1].replace(/-/g, ":") + return date + " " + time } } @@ -162,4 +199,5 @@ export default { .deletable-label:hover { background-color: #f0506e; } + \ No newline at end of file