mirror of
https://github.com/Fabio286/antares.git
synced 2025-06-05 21:59:22 +02:00
fix(SQLite): field length lost when editing a table, fixes #664
This commit is contained in:
@ -296,7 +296,13 @@ export class SQLiteClient extends AntaresCore {
|
||||
// ADD FIELDS
|
||||
fields.forEach(field => {
|
||||
const typeInfo = this.getTypeInfo(field.type);
|
||||
const length = typeInfo?.length ? field.enumValues || field.numLength || field.charLength || field.datePrecision : false;
|
||||
const length = typeInfo?.length
|
||||
? field.enumValues ||
|
||||
field.numLength ||
|
||||
field.numPrecision ||
|
||||
field.charLength ||
|
||||
field.datePrecision
|
||||
: false;
|
||||
|
||||
newColumns.push(`"${field.name}"
|
||||
${field.type.toUpperCase()}${length ? `(${length})` : ''}
|
||||
|
Reference in New Issue
Block a user