[fix] output:database:postgresql

This commit is contained in:
Christian Fraß 2024-06-03 09:33:24 +02:00
parent ea9d8db0f8
commit 5e928f8cab

View file

@ -89,8 +89,8 @@ namespace _sindri.outputs.database.postgresql
// nullability
.concat(
data_field.nullable
? ["NULL"]
: []
? []
: ["NOT NULL"]
)
// default
.concat(
@ -166,26 +166,30 @@ namespace _sindri.outputs.database.postgresql
(
[]
.concat(
(domain.description === null)
? []
: [
(! (domain.description === null))
? [
{
"kind": "TABLE",
"subject": domain.name,
"value": domain.description,
}
]
: []
)
.concat(
(domain.key_field === null)
? []
: [
(
(! (domain.key_field === null))
&&
(! (domain.key_field.description === null))
)
? [
{
"kind": "COLUMN",
"subject": (domain.name + "." + domain.key_field.name),
"value": domain.description,
"value": domain.key_field.description,
}
]
: []
)
.concat(
domain.data_fields