Error box, download button, editor save and more.
This commit is contained in:
14 files changed
+180
-102
No files matched your search
@@ -36,8 +36,7 @@ export default {
|
||||
})
|
||||
.catch(error => {
|
||||
buttons.done('delete')
|
||||
// TODO: show error in prompt
|
||||
console.log(error)
|
||||
this.$store.commit('showError', error)
|
||||
})
|
||||
|
||||
return
|
||||
@@ -63,7 +62,7 @@ export default {
|
||||
console.log(error)
|
||||
this.$store.commit('setReload', true)
|
||||
buttons.done('delete')
|
||||
// TODO: show error in prompt
|
||||
this.$store.commit('showError', error)
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
<div class="prompt error">
|
||||
<i class="material-icons">error_outline</i>
|
||||
<h3>Something went wrong</h3>
|
||||
<pre>{{ error }}</pre>
|
||||
<pre>{{ $store.state.showMessage }}</pre>
|
||||
<div>
|
||||
<button @click="$store.commit('closeHovers')" autofocus>Close</button>
|
||||
<button @click="close" autofocus>Close</button>
|
||||
<button @click="reportIssue" class="cancel">Report Issue</button>
|
||||
</div>
|
||||
</div>
|
||||
@@ -13,10 +13,12 @@
|
||||
<script>
|
||||
export default {
|
||||
name: 'error',
|
||||
props: ['error'],
|
||||
methods: {
|
||||
reportIssue () {
|
||||
window.open('https://github.com/hacdias/filemanager/issues/new')
|
||||
},
|
||||
close () {
|
||||
this.$store.commit('closeHovers')
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -81,10 +81,9 @@ export default {
|
||||
buttons.done('move')
|
||||
this.$router.push({page: dest})
|
||||
})
|
||||
.catch(e => {
|
||||
.catch(error => {
|
||||
buttons.done('move')
|
||||
// TODO: show error in prompt
|
||||
console.log(e)
|
||||
this.$store.commit('showError', error)
|
||||
})
|
||||
},
|
||||
next: function (event) {
|
||||
|
||||
@@ -39,8 +39,7 @@ export default {
|
||||
this.$router.push({ path: uri })
|
||||
})
|
||||
.catch(error => {
|
||||
// TODO: Show error message!
|
||||
console.log(error)
|
||||
this.$store.commit('showError', error)
|
||||
})
|
||||
|
||||
this.$store.commit('closeHovers')
|
||||
|
||||
@@ -39,8 +39,7 @@ export default {
|
||||
this.$router.push({ path: uri })
|
||||
})
|
||||
.catch(error => {
|
||||
// TODO: show error message in a box
|
||||
console.log(error)
|
||||
this.$store.commit('showError', error)
|
||||
})
|
||||
|
||||
this.$store.commit('closeHovers')
|
||||
|
||||
@@ -61,8 +61,7 @@ export default {
|
||||
// TODO: keep selected after reload?
|
||||
this.$store.commit('setReload', true)
|
||||
}).catch(error => {
|
||||
// TODO: show error message
|
||||
console.log(error)
|
||||
this.$store.commit('showError', error)
|
||||
})
|
||||
|
||||
this.$store.commit('closeHovers')
|
||||
|
||||
Reference in new issue
Block a user