Commit 4fb6a513 authored by TTS Kieu Tuan Anh's avatar TTS Kieu Tuan Anh

preview img

parent 39666ecf
...@@ -79,6 +79,6 @@ ...@@ -79,6 +79,6 @@
<script> <script>
export default { export default {
layout: 'admin', layout: 'admin',
middleware: ['web'], middleware: ['web']
} }
</script> </script>
...@@ -290,6 +290,15 @@ ...@@ -290,6 +290,15 @@
@change="fileSelected" @change="fileSelected"
/> />
</v-col> </v-col>
<v-col cols="12">
<img
v-if="file"
contain
max-height="300"
max-width="500"
:src="file"
>
</v-col>
</v-row> </v-row>
</v-container> </v-container>
<small>*indicates required field</small> <small>*indicates required field</small>
...@@ -682,8 +691,12 @@ export default { ...@@ -682,8 +691,12 @@ export default {
}) })
}, },
fileSelected (event) { fileSelected (event) {
console.log(event) if (event) {
console.log(this.images) this.file = URL.createObjectURL(event)
console.log(this.file)
} else {
this.file = null
}
} }
} }
} }
......
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