mirror of
https://github.com/Fabio286/antares.git
synced 2025-06-05 21:59:22 +02:00
Partial implementation of fields edit
This commit is contained in:
@ -31,6 +31,7 @@
|
||||
v-if="results"
|
||||
:results="results"
|
||||
:fields="resultsFields"
|
||||
@updateField="updateField"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
@ -134,6 +135,24 @@ export default {
|
||||
}
|
||||
|
||||
this.isQuering = false;
|
||||
},
|
||||
async updateField (payload) {
|
||||
const params = {
|
||||
uid: this.connection.uid,
|
||||
schema: this.workspace.breadcrumbs.schema,
|
||||
table: this.workspace.breadcrumbs.table,
|
||||
...payload
|
||||
};
|
||||
console.log(params);
|
||||
|
||||
try {
|
||||
const { status, response } = await Structure.updateTableCell(params);
|
||||
if (status !== 'success')
|
||||
this.addNotification({ status: 'error', message: response });
|
||||
}
|
||||
catch (err) {
|
||||
this.addNotification({ status: 'error', message: err.stack });
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
Reference in New Issue
Block a user