mirror of https://github.com/Fabio286/antares.git
fix: remove last char from datetime and time if is a dot
This commit is contained in:
parent
fccfe92453
commit
e89911b185
|
@ -19,7 +19,7 @@ module.exports = {
|
||||||
schedulers: false,
|
schedulers: false,
|
||||||
// Settings
|
// Settings
|
||||||
databaseEdit: false,
|
databaseEdit: false,
|
||||||
tableSettings: true,
|
tableSettings: false,
|
||||||
viewSettings: false,
|
viewSettings: false,
|
||||||
triggerSettings: false,
|
triggerSettings: false,
|
||||||
routineSettings: false,
|
routineSettings: false,
|
||||||
|
|
|
@ -1267,8 +1267,8 @@ export class PostgreSQLClient extends AntaresCore {
|
||||||
|
|
||||||
queryResult = rows.map(row => {
|
queryResult = rows.map(row => {
|
||||||
return row.reduce((acc, curr, i) => {
|
return row.reduce((acc, curr, i) => {
|
||||||
const table = tablesInfo[fields[i].tableID].table;
|
const table = tablesInfo[fields[i].tableID] ? tablesInfo[fields[i].tableID].table : '';
|
||||||
acc[`${table}.${fields[i].name}`] = curr;
|
acc[`${table ? `${table}.` : ''}${fields[i].name}`] = curr;
|
||||||
return acc;
|
return acc;
|
||||||
}, {});
|
}, {});
|
||||||
});
|
});
|
||||||
|
|
|
@ -412,7 +412,13 @@ export default {
|
||||||
this.isInlineEditor[this.editingField] = false;
|
this.isInlineEditor[this.editingField] = false;
|
||||||
let content;
|
let content;
|
||||||
if (!BLOB.includes(this.editingType)) {
|
if (!BLOB.includes(this.editingType)) {
|
||||||
|
if ([...DATETIME, ...TIME].includes(this.editingType)) {
|
||||||
|
if (this.editingContent.substring(this.editingContent.length - 1) === '.')
|
||||||
|
this.editingContent = this.editingContent.slice(0, -1);
|
||||||
|
}
|
||||||
|
|
||||||
if (this.editingContent === this.$options.filters.typeFormat(this.originalContent, this.editingType, this.editingLength)) return;// If not changed
|
if (this.editingContent === this.$options.filters.typeFormat(this.originalContent, this.editingType, this.editingLength)) return;// If not changed
|
||||||
|
|
||||||
content = this.editingContent;
|
content = this.editingContent;
|
||||||
}
|
}
|
||||||
else { // Handle file upload
|
else { // Handle file upload
|
||||||
|
|
Loading…
Reference in New Issue