fix schema so payments can be sent between lnbits wallets.

This commit is contained in:
fiatjaf
2019-12-16 16:23:06 +00:00
parent 377243b9cb
commit ce94fc8984
3 changed files with 10 additions and 9 deletions
+4 -2
View File
@@ -13,13 +13,15 @@ CREATE TABLE IF NOT EXISTS wallets (
);
CREATE TABLE IF NOT EXISTS apipayments (
payhash text PRIMARY KEY,
payhash text NOT NULL,
amount integer NOT NULL,
fee integer NOT NULL DEFAULT 0,
wallet text NOT NULL,
pending boolean NOT NULL,
memo text,
time timestamp NOT NULL DEFAULT (strftime('%s', 'now'))
time timestamp NOT NULL DEFAULT (strftime('%s', 'now')),
UNIQUE (wallet, payhash)
);
CREATE VIEW IF NOT EXISTS balances AS