mirror of
https://gitlab.com/pamhyr/pamhyr2.git
synced 2026-10-30 03:20:41 +01:00
DB: Fixes for db 0.1.0 creation.
This commit is contained in:
1 parent
9ec080a107
commit
328f5656bf
11 files changed
+32
-21
No files matched your search
@@ -31,8 +31,7 @@ class PointXYZ(Point, SQLSubModel):
|
||||
x: float = 0.0, y: float = 0.0, z: float = 0.0,
|
||||
name: str = "", profile=None, status=None):
|
||||
super(PointXYZ, self).__init__(
|
||||
id=id
|
||||
name=name, profile=profile, status=status
|
||||
id=id, name=name, profile=profile, status=status
|
||||
)
|
||||
|
||||
self._x = float(x)
|
||||
@@ -51,11 +50,11 @@ class PointXYZ(Point, SQLSubModel):
|
||||
z INTEGER NOT NULL,
|
||||
profile INTEGER NOT NULL,
|
||||
sl INTEGER,
|
||||
{Scenario.create_db_add_scenario()},
|
||||
{Scenario.create_db_add_scenario_fk()},
|
||||
FOREIGN KEY(profile)
|
||||
REFERENCES geometry_profileXYZ(pamhyr_id),
|
||||
FOREIGN KEY(sl) REFERENCES sedimentary_layer(pamhyr_id),
|
||||
{Scenario.create_db_add_scenario()},
|
||||
{Scenario.create_db_add_scenario_fk()},
|
||||
PRIMARY KEY(pamhyr_id, scenario)
|
||||
)
|
||||
""")
|
||||
|
||||
Reference in new issue
Block a user