1
1
mirror of https://github.com/Fabio286/antares.git synced 2025-06-05 21:59:22 +02:00

feat: new data tabs

This commit is contained in:
2021-07-13 19:23:02 +02:00
parent 88c4cdc8e2
commit ab382dfbcd
6 changed files with 77 additions and 20 deletions

View File

@ -20,6 +20,7 @@
class="menu-item"
:class="{'text-bold': breadcrumbs.schema === database.name && [breadcrumbs.table, breadcrumbs.view].includes(table.name)}"
@click="selectTable({schema: database.name, table})"
@dblclick="openDataTab({schema: database.name, table})"
@contextmenu.prevent="showTableContext($event, table)"
>
<a class="table-name">
@ -281,8 +282,12 @@ export default {
this.changeBreadcrumbs({ schema, table: null });
},
selectTable ({ schema, table }) {
this.setBreadcrumbs({ schema, [table.type]: table.name });
this.newTab({ uid: this.connection.uid, table: table.name, schema: this.database.name, type: 'temp-data' });
this.setBreadcrumbs({ schema, [table.type]: table.name });
},
openDataTab ({ schema, table }) {
this.newTab({ uid: this.connection.uid, table: table.name, schema: this.database.name, type: 'data' });
this.setBreadcrumbs({ schema, [table.type]: table.name });
},
showSchemaContext (event, schema) {
this.selectSchema(schema);