We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bfc4f60 commit 2ab7188Copy full SHA for 2ab7188
ui/src/views/AutogenView.vue
@@ -1191,15 +1191,12 @@ export default {
1191
}
1192
1193
1194
- if (this.items.length > 0) {
1195
- if (!this.showAction || this.dataView) {
1196
- this.resource = this.items[0]
1197
- this.$emit('change-resource', this.resource)
1198
- }
1199
- } else {
1200
- if (this.dataView) {
1201
- this.$router.push({ path: '/exception/404' })
1202
+ if (this.items.length <= 0 && this.dataView) {
+ this.$router.push({ path: '/exception/404' })
+ }
+ if (!this.showAction || this.dataView) {
+ this.resource = this.items?.[0] || {}
+ this.$emit('change-resource', this.resource)
1203
1204
}).catch(error => {
1205
if (!error || !error.message) {
0 commit comments