Updates
This commit is contained in:
@@ -84,10 +84,17 @@ export default function ({
|
||||
targetChildTableParentDatabase.tables[
|
||||
targetChildTableParentDatabaseTableIndex
|
||||
].fields = [...currentTableSchema.fields];
|
||||
|
||||
targetChildTableParentDatabase.tables[
|
||||
targetChildTableParentDatabaseTableIndex
|
||||
].indexes = [...(currentTableSchema.indexes || [])];
|
||||
|
||||
targetChildTableParentDatabase.tables[
|
||||
targetChildTableParentDatabaseTableIndex
|
||||
].uniqueConstraints = [
|
||||
...(currentTableSchema.uniqueConstraints || []),
|
||||
];
|
||||
|
||||
writeUpdatedDbSchema({
|
||||
dbSchema: targetChildTableParentDatabase,
|
||||
userId,
|
||||
@@ -221,6 +228,9 @@ export default function ({
|
||||
targetParentDatabaseTable.fields;
|
||||
newCurrentDbSchema.tables[currentTableSchemaIndex].indexes =
|
||||
targetParentDatabaseTable.indexes;
|
||||
newCurrentDbSchema.tables[
|
||||
currentTableSchemaIndex
|
||||
].uniqueConstraints = targetParentDatabaseTable.uniqueConstraints;
|
||||
|
||||
writeUpdatedDbSchema({ dbSchema: targetParentDatabase, userId });
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user