Fix the issue of parameter concatenation when generating ORM with inspectdb (#331)

Co-authored-by: floodpillar <165008032+floodpillar@users.noreply.github.com>
This commit is contained in:
xsillen 2024-12-03 11:44:36 +08:00 committed by GitHub
parent c0fd3ec63c
commit 4e46d9d969
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -36,7 +36,7 @@ class Column(BaseModel):
length_parts.append(f"max_digits={self.max_digits}")
if self.decimal_places:
length_parts.append(f"decimal_places={self.decimal_places}")
length = ", ".join(length_parts)
length = ", ".join(length_parts)+", "
if self.null:
null = "null=True, "
if self.default is not None: