feat: add posts_per_page column to sites table
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
7c4dc0885e
commit
9b36a35c1a
4 changed files with 35 additions and 24 deletions
|
|
@ -14,15 +14,16 @@ INSERT INTO sites (
|
|||
title,
|
||||
tagline,
|
||||
timezone,
|
||||
posts_per_page,
|
||||
created_at
|
||||
) VALUES (?, ?, ?, ?, ?, ?)
|
||||
) VALUES (?, ?, ?, ?, ?, ?, ?)
|
||||
RETURNING id;
|
||||
|
||||
-- name: HasUsersAndSites :one
|
||||
SELECT (SELECT COUNT(*) FROM users) > 0 AND (SELECT COUNT(*) FROM sites) > 0 AS has_users_and_sites;
|
||||
|
||||
-- name: UpdateSite :exec
|
||||
UPDATE sites SET title = ?, tagline = ?, timezone = ? WHERE id = ?;
|
||||
UPDATE sites SET title = ?, tagline = ?, timezone = ?, posts_per_page = ? WHERE id = ?;
|
||||
|
||||
-- name: SelectAllSitesWithOwners :many
|
||||
SELECT s.id, s.guid, s.title, s.owner_id, u.username
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue