Initial commit of CK-QR Platform
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
CREATE TABLE IF NOT EXISTS qr_scans (
|
||||
id UUID PRIMARY KEY DEFAULT uuid_generate_v4(),
|
||||
qr_code_id UUID REFERENCES qr_codes(id) ON DELETE CASCADE,
|
||||
ip_address VARCHAR(45),
|
||||
user_agent TEXT,
|
||||
os VARCHAR(100),
|
||||
device_type VARCHAR(50),
|
||||
scanned_at TIMESTAMP WITH TIME ZONE DEFAULT CURRENT_TIMESTAMP
|
||||
);
|
||||
@@ -0,0 +1,15 @@
|
||||
CREATE TABLE IF NOT EXISTS app_settings (
|
||||
key VARCHAR(100) PRIMARY KEY,
|
||||
value TEXT,
|
||||
category VARCHAR(50),
|
||||
updated_at TIMESTAMP WITH TIME ZONE DEFAULT CURRENT_TIMESTAMP
|
||||
);
|
||||
|
||||
-- Insert some default keys so they show up in the UI
|
||||
INSERT INTO app_settings (key, value, category) VALUES
|
||||
('icici_merchant_id', '', 'payments'),
|
||||
('icici_api_key', '', 'payments'),
|
||||
('google_safe_browsing_key', '', 'security'),
|
||||
('google_client_id', '', 'auth'),
|
||||
('apple_service_id', '', 'auth')
|
||||
ON CONFLICT (key) DO NOTHING;
|
||||
@@ -0,0 +1,3 @@
|
||||
INSERT INTO users (email, password_hash, role)
|
||||
VALUES ('admin@ckqr.com', '$2b$10$ezY4oBvmZUc667XCKbl98.hKicJbOG9yaV9lFbZXwbeXWgMuN7L/6', 'enterprise')
|
||||
ON CONFLICT (email) DO NOTHING;
|
||||
Reference in New Issue
Block a user