preparations for object_generator (generating objects with attributes and constraints)
This commit is contained in:
@@ -110,7 +110,7 @@ std::shared_ptr<attribute> repository_node::determine_reference_column(const std
|
||||
repository& repo) {
|
||||
const auto it = repo.missing_references_.find(ti);
|
||||
if (it == repo.missing_references_.end()) {
|
||||
return std::make_shared<attribute>(pk_info.pk_column_name, pk_info.type, table_name, attribute_options{utils::constraints::FOREIGN_KEY});
|
||||
return std::make_shared<attribute>(pk_info.pk_column_name, pk_info.type, table_name, attribute_options{utils::constraints::ForeignKey});
|
||||
}
|
||||
|
||||
auto ref_column = it->second;
|
||||
@@ -118,7 +118,7 @@ std::shared_ptr<attribute> repository_node::determine_reference_column(const std
|
||||
ref_column->name(pk_info.pk_column_name);
|
||||
ref_column->table_name(table_name);
|
||||
ref_column->change_type(pk_info.type);
|
||||
ref_column->attributes() = utils::constraints::FOREIGN_KEY;
|
||||
ref_column->attributes() = utils::constraints::ForeignKey;
|
||||
|
||||
if (table_name.empty()) {
|
||||
repo.missing_references_.insert({ti, ref_column});
|
||||
|
||||
Reference in New Issue
Block a user