From 56e0af3b41742876b471332aeb943a5a2ca8dfbf Mon Sep 17 00:00:00 2001
From: T <t@tjp.lol>
Date: Mon, 4 Aug 2025 09:49:52 -0600
Subject: Generate invoice PDFs

---
 internal/database/schema.sql | 20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)

(limited to 'internal/database/schema.sql')

diff --git a/internal/database/schema.sql b/internal/database/schema.sql
index a4483e1..84f4f02 100644
--- a/internal/database/schema.sql
+++ b/internal/database/schema.sql
@@ -15,6 +15,26 @@ create table if not exists project (
     foreign key (client_id) references client(id)
 );
 
+create table if not exists contractor (
+    id integer primary key autoincrement,
+    name text not null,
+    label text not null,
+    email text not null,
+    created_at datetime default current_timestamp
+);
+
+create table if not exists invoice (
+    id integer primary key autoincrement,
+    year integer not null,
+    month integer not null,
+    number integer not null,
+    client_id integer not null,
+    total_amount integer not null,
+    created_at datetime default current_timestamp,
+    unique(year, month, number),
+    foreign key (client_id) references client(id)
+);
+
 create table if not exists time_entry (
     id integer primary key autoincrement,
     start_time datetime not null,
-- 
cgit v1.2.3

