Commit fd989d82 authored by janis.streib's avatar janis.streib 🦉
Browse files

FIX: more error handling magic

parent 1ed3020c
Pipeline #120560 passed with stages
in 9 minutes and 39 seconds
......@@ -64,7 +64,9 @@
></DataEditField>
</template>
<hr/>
<b-checkbox v-model="show_result_int">Rückgabe des Transaktionselements nach erfolgreicher Ausführung anzeigen</b-checkbox>
<b-checkbox v-model="show_result_int">Rückgabe des Transaktionselements nach erfolgreicher Ausführung
anzeigen
</b-checkbox>
</b-collapse>
</template>
</template>
......@@ -258,6 +260,9 @@ export default {
return
}
const res = await TransactionUtil.getObjectMetadata(this, this.object_fq_name)
if (res === null) {
return
}
this.object_definition = res.object_definition
this.object_functions = res.object_functions
this.object_definition_reference_names_by_attribute = res.object_definition_reference_names_by_attribute
......
......@@ -317,23 +317,28 @@ async function init() {
// handle error
if (error.response) {
var stat = error.response.status
switch (stat) {
case 401:
await LoginService.logout(null)
store.commit('logout')
if (router.currentRoute.path !== '/login') {
router.push('/login')
}
break
case 403:
await LoginService.logout(null)
store.commit('logout')
if (router.currentRoute.path !== '/login') {
router.push('/login')
}
break
default:
break
try {
switch (stat) {
case 401:
await LoginService.logout(null)
store.commit('logout')
if (router.currentRoute.path !== '/login') {
await router.push('/login')
}
break
case 403:
await LoginService.logout(null)
store.commit('logout')
if (router.currentRoute.path !== '/login') {
await router.push('/login')
}
break
default:
break
}
} catch (f) {
window.console.info('silently failed navigation error (probably by calling it in parallel)')
window.console.info(f)
}
} else {
switch (stat) {
......
Supports Markdown
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