Remove now-extraneous latitude/longitude generated columns

Now that we can pull out the geometry directly into a go object we don't
need these and they complicate our insertions
This commit is contained in:
Eli Ribble 2026-05-07 16:38:42 +00:00
parent 34a136eba5
commit 7a361a330d
No known key found for this signature in database
40 changed files with 426 additions and 464 deletions

View file

@ -28,11 +28,11 @@ func SiteFromAddressIDForOrg(ctx context.Context, txn db.Ex, address_id int64, o
}
return &result, nil
}
func SiteFromIDForOrg(ctx context.Context, comm_id int64, org_id int64) (model.Site, error) {
func SiteFromIDForOrg(ctx context.Context, txn db.Ex, comm_id int64, org_id int64) (model.Site, error) {
statement := table.Site.SELECT(
table.Site.AllColumns,
).FROM(table.Site).
WHERE(table.Site.ID.EQ(postgres.Int(comm_id)).AND(
table.Site.OrganizationID.EQ(postgres.Int(org_id))))
return db.ExecuteOne[model.Site](ctx, statement)
return db.ExecuteOneTx[model.Site](ctx, txn, statement)
}