feature/ui-redesign #4

Merged
jason merged 4 commits from feature/ui-redesign into master 2026-03-08 23:42:01 -05:00
Showing only changes of commit bb0f5dd9b8 - Show all commits

View File

@@ -26,7 +26,7 @@ function initDatabase(dbPath) {
sex TEXT NOT NULL CHECK(sex IN ('male', 'female')),
birth_date DATE,
color TEXT,
microchip TEXT UNIQUE,
microchip TEXT,
photo_urls TEXT, -- JSON array of photo URLs
notes TEXT,
is_active INTEGER DEFAULT 1,
@@ -35,6 +35,13 @@ function initDatabase(dbPath) {
)
`);
// Create unique index for microchip that allows NULL values
db.exec(`
CREATE UNIQUE INDEX IF NOT EXISTS idx_dogs_microchip
ON dogs(microchip)
WHERE microchip IS NOT NULL
`);
// Parents table - Relationship mapping
db.exec(`
CREATE TABLE IF NOT EXISTS parents (