mock events db schema
This commit is contained in:
@@ -0,0 +1,63 @@
|
|||||||
|
BEGIN;
|
||||||
|
|
||||||
|
|
||||||
|
--- event processing
|
||||||
|
|
||||||
|
DROP TRIGGER amazon_store_events ON mock.raw_shop_events;
|
||||||
|
DROP FUNCTION mock.process_raw_amazon_event;
|
||||||
|
|
||||||
|
DROP TRIGGER big_cartel_store_events ON mock.raw_shop_events;
|
||||||
|
DROP FUNCTION mock.process_raw_big_cartel_event;
|
||||||
|
|
||||||
|
DROP TRIGGER ebay_store_events ON mock.raw_shop_events;
|
||||||
|
DROP FUNCTION mock.process_raw_ebay_event;
|
||||||
|
|
||||||
|
DROP TRIGGER ecwid_store_events ON mock.raw_shop_events;
|
||||||
|
DROP FUNCTION mock.process_raw_ecwid_event;
|
||||||
|
|
||||||
|
DROP TRIGGER etsy_store_events ON mock.raw_shop_events;
|
||||||
|
DROP FUNCTION mock.process_raw_etsy_event;
|
||||||
|
|
||||||
|
DROP TRIGGER shopify_store_events ON mock.raw_shop_events;
|
||||||
|
DROP FUNCTION mock.process_raw_shopify_event;
|
||||||
|
|
||||||
|
DROP TRIGGER square_online_store_events ON mock.raw_shop_events;
|
||||||
|
DROP FUNCTION mock.process_raw_square_online_event;
|
||||||
|
|
||||||
|
DROP TRIGGER squarespace_store_events ON mock.raw_shop_events;
|
||||||
|
DROP FUNCTION mock.process_raw_squarespace_event;
|
||||||
|
|
||||||
|
DROP TRIGGER tiktok_store_events ON mock.raw_shop_events;
|
||||||
|
DROP FUNCTION mock.process_raw_tiktok_event;
|
||||||
|
|
||||||
|
DROP TRIGGER walmart_marketplace_store_events ON mock.raw_shop_events;
|
||||||
|
DROP FUNCTION mock.process_raw_walmart_marketplace_event;
|
||||||
|
|
||||||
|
DROP TRIGGER wix_store_events ON mock.raw_shop_events;
|
||||||
|
DROP FUNCTION mock.process_raw_wix_event;
|
||||||
|
|
||||||
|
DROP TRIGGER woo_commerce_store_events ON mock.raw_shop_events;
|
||||||
|
DROP FUNCTION mock.process_raw_woo_commerce_event;
|
||||||
|
|
||||||
|
DROP TRIGGER zoho_store_events ON mock.raw_shop_events;
|
||||||
|
DROP FUNCTION mock.process_raw_zoho_event;
|
||||||
|
|
||||||
|
-- event tables
|
||||||
|
|
||||||
|
DROP TABLE mock.shop_amazon_events;
|
||||||
|
DROP TABLE mock.shop_big_cartel_events;
|
||||||
|
DROP TABLE mock.shop_ebay_events;
|
||||||
|
DROP TABLE mock.shop_ecwid_events;
|
||||||
|
DROP TABLE mock.shop_etsy_events;
|
||||||
|
DROP TABLE mock.shop_shopify_events;
|
||||||
|
DROP TABLE mock.shop_square_online_events;
|
||||||
|
DROP TABLE mock.shop_squarespace_events;
|
||||||
|
DROP TABLE mock.shop_tiktok_events;
|
||||||
|
DROP TABLE mock.shop_walmart_marketplace_events;
|
||||||
|
DROP TABLE mock.shop_wix_events;
|
||||||
|
DROP TABLE mock.shop_woo_commerce_events;
|
||||||
|
DROP TABLE mock.shop_zoho_events;
|
||||||
|
DROP TABLE mock.raw_shop_events;
|
||||||
|
|
||||||
|
|
||||||
|
COMMIT;
|
||||||
@@ -0,0 +1,465 @@
|
|||||||
|
BEGIN;
|
||||||
|
|
||||||
|
|
||||||
|
-- raw store events
|
||||||
|
|
||||||
|
CREATE TABLE mock.raw_shop_events (
|
||||||
|
platform TEXT NOT NULL,
|
||||||
|
store_id TEXT NOT NULL,
|
||||||
|
event_timestamp TIMESTAMPTZ NOT NULL,
|
||||||
|
event_id TEXT NOT NULL,
|
||||||
|
raw_payload JSONB NOT NULL,
|
||||||
|
parsed BOOLEAN NOT NULL DEFAULT FALSE,
|
||||||
|
|
||||||
|
PRIMARY KEY (platform, store_id, event_id, event_timestamp)
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
-- processed event tables
|
||||||
|
|
||||||
|
CREATE TABLE mock.shop_amazon_events (
|
||||||
|
platform TEXT NOT NULL DEFAULT 'amazon' CHECK (platform = 'amazon'),
|
||||||
|
store_id TEXT NOT NULL,
|
||||||
|
event_timestamp TIMESTAMPTZ NOT NULL,
|
||||||
|
event_id TEXT NOT NULL,
|
||||||
|
|
||||||
|
PRIMARY KEY (store_id, event_id, event_timestamp),
|
||||||
|
FOREIGN KEY (platform, store_id, event_id, event_timestamp) REFERENCES mock.raw_shop_events
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE mock.shop_big_cartel_events (
|
||||||
|
platform TEXT NOT NULL DEFAULT 'big_cartel' CHECK (platform = 'big_cartel'),
|
||||||
|
store_id TEXT NOT NULL,
|
||||||
|
event_timestamp TIMESTAMPTZ NOT NULL,
|
||||||
|
event_id TEXT NOT NULL,
|
||||||
|
|
||||||
|
PRIMARY KEY (store_id, event_id, event_timestamp),
|
||||||
|
FOREIGN KEY (platform, store_id, event_id, event_timestamp) REFERENCES mock.raw_shop_events
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE mock.shop_ebay_events (
|
||||||
|
platform TEXT NOT NULL DEFAULT 'ebay' CHECK (platform = 'ebay'),
|
||||||
|
store_id TEXT NOT NULL,
|
||||||
|
event_timestamp TIMESTAMPTZ NOT NULL,
|
||||||
|
event_id TEXT NOT NULL,
|
||||||
|
|
||||||
|
PRIMARY KEY (store_id, event_id, event_timestamp),
|
||||||
|
FOREIGN KEY (platform, store_id, event_id, event_timestamp) REFERENCES mock.raw_shop_events
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE mock.shop_ecwid_events (
|
||||||
|
platform TEXT NOT NULL DEFAULT 'ecwid' CHECK (platform = 'ecwid'),
|
||||||
|
store_id TEXT NOT NULL,
|
||||||
|
event_timestamp TIMESTAMPTZ NOT NULL,
|
||||||
|
event_id TEXT NOT NULL,
|
||||||
|
|
||||||
|
PRIMARY KEY (store_id, event_id, event_timestamp),
|
||||||
|
FOREIGN KEY (platform, store_id, event_id, event_timestamp) REFERENCES mock.raw_shop_events
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE mock.shop_etsy_events (
|
||||||
|
platform TEXT NOT NULL DEFAULT 'etsy' CHECK (platform = 'etsy'),
|
||||||
|
store_id TEXT NOT NULL,
|
||||||
|
event_timestamp TIMESTAMPTZ NOT NULL,
|
||||||
|
event_id TEXT NOT NULL,
|
||||||
|
|
||||||
|
PRIMARY KEY (store_id, event_id, event_timestamp),
|
||||||
|
FOREIGN KEY (platform, store_id, event_id, event_timestamp) REFERENCES mock.raw_shop_events
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE mock.shop_shopify_events (
|
||||||
|
platform TEXT NOT NULL DEFAULT 'shopify' CHECK (platform = 'shopify'),
|
||||||
|
store_id TEXT NOT NULL,
|
||||||
|
event_timestamp TIMESTAMPTZ NOT NULL,
|
||||||
|
event_id TEXT NOT NULL,
|
||||||
|
|
||||||
|
PRIMARY KEY (store_id, event_id, event_timestamp),
|
||||||
|
FOREIGN KEY (platform, store_id, event_id, event_timestamp) REFERENCES mock.raw_shop_events
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE mock.shop_square_online_events (
|
||||||
|
platform TEXT NOT NULL DEFAULT 'square_online' CHECK (platform = 'square_online'),
|
||||||
|
store_id TEXT NOT NULL,
|
||||||
|
event_timestamp TIMESTAMPTZ NOT NULL,
|
||||||
|
event_id TEXT NOT NULL,
|
||||||
|
|
||||||
|
PRIMARY KEY (store_id, event_id, event_timestamp),
|
||||||
|
FOREIGN KEY (platform, store_id, event_id, event_timestamp) REFERENCES mock.raw_shop_events
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE mock.shop_squarespace_events (
|
||||||
|
platform TEXT NOT NULL DEFAULT 'squarespace' CHECK (platform = 'squarespace'),
|
||||||
|
store_id TEXT NOT NULL,
|
||||||
|
event_timestamp TIMESTAMPTZ NOT NULL,
|
||||||
|
event_id TEXT NOT NULL,
|
||||||
|
|
||||||
|
PRIMARY KEY (store_id, event_id, event_timestamp),
|
||||||
|
FOREIGN KEY (platform, store_id, event_id, event_timestamp) REFERENCES mock.raw_shop_events
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE mock.shop_tiktok_events (
|
||||||
|
platform TEXT NOT NULL DEFAULT 'tiktok' CHECK (platform = 'tiktok'),
|
||||||
|
store_id TEXT NOT NULL,
|
||||||
|
event_timestamp TIMESTAMPTZ NOT NULL,
|
||||||
|
event_id TEXT NOT NULL,
|
||||||
|
|
||||||
|
PRIMARY KEY (store_id, event_id, event_timestamp),
|
||||||
|
FOREIGN KEY (platform, store_id, event_id, event_timestamp) REFERENCES mock.raw_shop_events
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE mock.shop_walmart_marketplace_events (
|
||||||
|
platform TEXT NOT NULL DEFAULT 'walmart_marketplace' CHECK (platform = 'walmart_marketplace'),
|
||||||
|
store_id TEXT NOT NULL,
|
||||||
|
event_timestamp TIMESTAMPTZ NOT NULL,
|
||||||
|
event_id TEXT NOT NULL,
|
||||||
|
|
||||||
|
PRIMARY KEY (store_id, event_id, event_timestamp),
|
||||||
|
FOREIGN KEY (platform, store_id, event_id, event_timestamp) REFERENCES mock.raw_shop_events
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE mock.shop_wix_events (
|
||||||
|
platform TEXT NOT NULL DEFAULT 'wix' CHECK (platform = 'wix'),
|
||||||
|
store_id TEXT NOT NULL,
|
||||||
|
event_timestamp TIMESTAMPTZ NOT NULL,
|
||||||
|
event_id TEXT NOT NULL,
|
||||||
|
|
||||||
|
PRIMARY KEY (store_id, event_id, event_timestamp),
|
||||||
|
FOREIGN KEY (platform, store_id, event_id, event_timestamp) REFERENCES mock.raw_shop_events
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE mock.shop_woo_commerce_events (
|
||||||
|
platform TEXT NOT NULL DEFAULT 'woo_commerce' CHECK (platform = 'woo_commerce'),
|
||||||
|
store_id TEXT NOT NULL,
|
||||||
|
event_timestamp TIMESTAMPTZ NOT NULL,
|
||||||
|
event_id TEXT NOT NULL,
|
||||||
|
|
||||||
|
PRIMARY KEY (store_id, event_id, event_timestamp),
|
||||||
|
FOREIGN KEY (platform, store_id, event_id, event_timestamp) REFERENCES mock.raw_shop_events
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE TABLE mock.shop_zoho_events (
|
||||||
|
platform TEXT NOT NULL DEFAULT 'zoho' CHECK (platform = 'zoho'),
|
||||||
|
store_id TEXT NOT NULL,
|
||||||
|
event_timestamp TIMESTAMPTZ NOT NULL,
|
||||||
|
event_id TEXT NOT NULL,
|
||||||
|
|
||||||
|
PRIMARY KEY (store_id, event_id, event_timestamp),
|
||||||
|
FOREIGN KEY (platform, store_id, event_id, event_timestamp) REFERENCES mock.raw_shop_events
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
--- event processing
|
||||||
|
|
||||||
|
CREATE OR REPLACE FUNCTION mock.process_raw_amazon_event() RETURNS TRIGGER AS $process_raw_amazon_event$
|
||||||
|
BEGIN
|
||||||
|
INSERT INTO mock.shop_amazon_events (
|
||||||
|
platform,
|
||||||
|
store_id,
|
||||||
|
event_timestamp,
|
||||||
|
event_id
|
||||||
|
)
|
||||||
|
SELECT
|
||||||
|
NEW.platform,
|
||||||
|
NEW.store_id,
|
||||||
|
NEW.event_timestamp,
|
||||||
|
NEW.event_id;
|
||||||
|
RETURN NULL;
|
||||||
|
END;
|
||||||
|
$process_raw_amazon_event$ LANGUAGE plpgsql;
|
||||||
|
|
||||||
|
CREATE OR REPLACE TRIGGER amazon_store_events
|
||||||
|
AFTER INSERT ON mock.raw_shop_events
|
||||||
|
FOR EACH ROW
|
||||||
|
WHEN (NEW.platform = 'amazon')
|
||||||
|
EXECUTE FUNCTION mock.process_raw_amazon_event();
|
||||||
|
|
||||||
|
|
||||||
|
CREATE OR REPLACE FUNCTION mock.process_raw_big_cartel_event() RETURNS TRIGGER AS $process_raw_big_cartel_event$
|
||||||
|
BEGIN
|
||||||
|
INSERT INTO mock.shop_big_cartel_events (
|
||||||
|
platform,
|
||||||
|
store_id,
|
||||||
|
event_timestamp,
|
||||||
|
event_id
|
||||||
|
)
|
||||||
|
SELECT
|
||||||
|
NEW.platform,
|
||||||
|
NEW.store_id,
|
||||||
|
NEW.event_timestamp,
|
||||||
|
NEW.event_id;
|
||||||
|
RETURN NULL;
|
||||||
|
END;
|
||||||
|
$process_raw_big_cartel_event$ LANGUAGE plpgsql;
|
||||||
|
|
||||||
|
CREATE OR REPLACE TRIGGER big_cartel_store_events
|
||||||
|
AFTER INSERT ON mock.raw_shop_events
|
||||||
|
FOR EACH ROW
|
||||||
|
WHEN (NEW.platform = 'big_cartel')
|
||||||
|
EXECUTE FUNCTION mock.process_raw_big_cartel_event();
|
||||||
|
|
||||||
|
|
||||||
|
CREATE OR REPLACE FUNCTION mock.process_raw_ebay_event() RETURNS TRIGGER AS $process_raw_ebay_event$
|
||||||
|
BEGIN
|
||||||
|
INSERT INTO mock.shop_ebay_events (
|
||||||
|
platform,
|
||||||
|
store_id,
|
||||||
|
event_timestamp,
|
||||||
|
event_id
|
||||||
|
)
|
||||||
|
SELECT
|
||||||
|
NEW.platform,
|
||||||
|
NEW.store_id,
|
||||||
|
NEW.event_timestamp,
|
||||||
|
NEW.event_id;
|
||||||
|
RETURN NULL;
|
||||||
|
END;
|
||||||
|
$process_raw_ebay_event$ LANGUAGE plpgsql;
|
||||||
|
|
||||||
|
CREATE OR REPLACE TRIGGER ebay_store_events
|
||||||
|
AFTER INSERT ON mock.raw_shop_events
|
||||||
|
FOR EACH ROW
|
||||||
|
WHEN (NEW.platform = 'ebay')
|
||||||
|
EXECUTE FUNCTION mock.process_raw_ebay_event();
|
||||||
|
|
||||||
|
|
||||||
|
CREATE OR REPLACE FUNCTION mock.process_raw_ecwid_event() RETURNS TRIGGER AS $process_raw_ecwid_event$
|
||||||
|
BEGIN
|
||||||
|
INSERT INTO mock.shop_ecwid_events (
|
||||||
|
platform,
|
||||||
|
store_id,
|
||||||
|
event_timestamp,
|
||||||
|
event_id
|
||||||
|
)
|
||||||
|
SELECT
|
||||||
|
NEW.platform,
|
||||||
|
NEW.store_id,
|
||||||
|
NEW.event_timestamp,
|
||||||
|
NEW.event_id;
|
||||||
|
RETURN NULL;
|
||||||
|
END;
|
||||||
|
$process_raw_ecwid_event$ LANGUAGE plpgsql;
|
||||||
|
|
||||||
|
CREATE OR REPLACE TRIGGER ecwid_store_events
|
||||||
|
AFTER INSERT ON mock.raw_shop_events
|
||||||
|
FOR EACH ROW
|
||||||
|
WHEN (NEW.platform = 'ecwid')
|
||||||
|
EXECUTE FUNCTION mock.process_raw_ecwid_event();
|
||||||
|
|
||||||
|
|
||||||
|
CREATE OR REPLACE FUNCTION mock.process_raw_etsy_event() RETURNS TRIGGER AS $process_raw_etsy_event$
|
||||||
|
BEGIN
|
||||||
|
INSERT INTO mock.shop_etsy_events (
|
||||||
|
platform,
|
||||||
|
store_id,
|
||||||
|
event_timestamp,
|
||||||
|
event_id
|
||||||
|
)
|
||||||
|
SELECT
|
||||||
|
NEW.platform,
|
||||||
|
NEW.store_id,
|
||||||
|
NEW.event_timestamp,
|
||||||
|
NEW.event_id;
|
||||||
|
RETURN NULL;
|
||||||
|
END;
|
||||||
|
$process_raw_etsy_event$ LANGUAGE plpgsql;
|
||||||
|
|
||||||
|
CREATE OR REPLACE TRIGGER etsy_store_events
|
||||||
|
AFTER INSERT ON mock.raw_shop_events
|
||||||
|
FOR EACH ROW
|
||||||
|
WHEN (NEW.platform = 'etsy')
|
||||||
|
EXECUTE FUNCTION mock.process_raw_etsy_event();
|
||||||
|
|
||||||
|
|
||||||
|
CREATE OR REPLACE FUNCTION mock.process_raw_shopify_event() RETURNS TRIGGER AS $process_raw_shopify_event$
|
||||||
|
BEGIN
|
||||||
|
INSERT INTO mock.shop_shopify_events (
|
||||||
|
platform,
|
||||||
|
store_id,
|
||||||
|
event_timestamp,
|
||||||
|
event_id
|
||||||
|
)
|
||||||
|
SELECT
|
||||||
|
NEW.platform,
|
||||||
|
NEW.store_id,
|
||||||
|
NEW.event_timestamp,
|
||||||
|
NEW.event_id;
|
||||||
|
RETURN NULL;
|
||||||
|
END;
|
||||||
|
$process_raw_shopify_event$ LANGUAGE plpgsql;
|
||||||
|
|
||||||
|
CREATE OR REPLACE TRIGGER shopify_store_events
|
||||||
|
AFTER INSERT ON mock.raw_shop_events
|
||||||
|
FOR EACH ROW
|
||||||
|
WHEN (NEW.platform = 'shopify')
|
||||||
|
EXECUTE FUNCTION mock.process_raw_shopify_event();
|
||||||
|
|
||||||
|
|
||||||
|
CREATE OR REPLACE FUNCTION mock.process_raw_square_online_event() RETURNS TRIGGER AS $process_raw_square_online_event$
|
||||||
|
BEGIN
|
||||||
|
INSERT INTO mock.shop_square_online_events (
|
||||||
|
platform,
|
||||||
|
store_id,
|
||||||
|
event_timestamp,
|
||||||
|
event_id
|
||||||
|
)
|
||||||
|
SELECT
|
||||||
|
NEW.platform,
|
||||||
|
NEW.store_id,
|
||||||
|
NEW.event_timestamp,
|
||||||
|
NEW.event_id;
|
||||||
|
RETURN NULL;
|
||||||
|
END;
|
||||||
|
$process_raw_square_online_event$ LANGUAGE plpgsql;
|
||||||
|
|
||||||
|
CREATE OR REPLACE TRIGGER square_online_store_events
|
||||||
|
AFTER INSERT ON mock.raw_shop_events
|
||||||
|
FOR EACH ROW
|
||||||
|
WHEN (NEW.platform = 'square_online')
|
||||||
|
EXECUTE FUNCTION mock.process_raw_square_online_event();
|
||||||
|
|
||||||
|
|
||||||
|
CREATE OR REPLACE FUNCTION mock.process_raw_squarespace_event() RETURNS TRIGGER AS $process_raw_squarespace_event$
|
||||||
|
BEGIN
|
||||||
|
INSERT INTO mock.shop_squarespace_events (
|
||||||
|
platform,
|
||||||
|
store_id,
|
||||||
|
event_timestamp,
|
||||||
|
event_id
|
||||||
|
)
|
||||||
|
SELECT
|
||||||
|
NEW.platform,
|
||||||
|
NEW.store_id,
|
||||||
|
NEW.event_timestamp,
|
||||||
|
NEW.event_id;
|
||||||
|
RETURN NULL;
|
||||||
|
END;
|
||||||
|
$process_raw_squarespace_event$ LANGUAGE plpgsql;
|
||||||
|
|
||||||
|
CREATE OR REPLACE TRIGGER squarespace_store_events
|
||||||
|
AFTER INSERT ON mock.raw_shop_events
|
||||||
|
FOR EACH ROW
|
||||||
|
WHEN (NEW.platform = 'squarespace')
|
||||||
|
EXECUTE FUNCTION mock.process_raw_squarespace_event();
|
||||||
|
|
||||||
|
|
||||||
|
CREATE OR REPLACE FUNCTION mock.process_raw_tiktok_event() RETURNS TRIGGER AS $process_raw_tiktok_event$
|
||||||
|
BEGIN
|
||||||
|
INSERT INTO mock.shop_tiktok_events (
|
||||||
|
platform,
|
||||||
|
store_id,
|
||||||
|
event_timestamp,
|
||||||
|
event_id
|
||||||
|
)
|
||||||
|
SELECT
|
||||||
|
NEW.platform,
|
||||||
|
NEW.store_id,
|
||||||
|
NEW.event_timestamp,
|
||||||
|
NEW.event_id;
|
||||||
|
RETURN NULL;
|
||||||
|
END;
|
||||||
|
$process_raw_tiktok_event$ LANGUAGE plpgsql;
|
||||||
|
|
||||||
|
CREATE OR REPLACE TRIGGER tiktok_store_events
|
||||||
|
AFTER INSERT ON mock.raw_shop_events
|
||||||
|
FOR EACH ROW
|
||||||
|
WHEN (NEW.platform = 'tiktok')
|
||||||
|
EXECUTE FUNCTION mock.process_raw_tiktok_event();
|
||||||
|
|
||||||
|
|
||||||
|
CREATE OR REPLACE FUNCTION mock.process_raw_walmart_marketplace_event() RETURNS TRIGGER AS $process_raw_walmart_marketplace_event$
|
||||||
|
BEGIN
|
||||||
|
INSERT INTO mock.shop_walmart_marketplace_events (
|
||||||
|
platform,
|
||||||
|
store_id,
|
||||||
|
event_timestamp,
|
||||||
|
event_id
|
||||||
|
)
|
||||||
|
SELECT
|
||||||
|
NEW.platform,
|
||||||
|
NEW.store_id,
|
||||||
|
NEW.event_timestamp,
|
||||||
|
NEW.event_id;
|
||||||
|
RETURN NULL;
|
||||||
|
END;
|
||||||
|
$process_raw_walmart_marketplace_event$ LANGUAGE plpgsql;
|
||||||
|
|
||||||
|
CREATE OR REPLACE TRIGGER walmart_marketplace_store_events
|
||||||
|
AFTER INSERT ON mock.raw_shop_events
|
||||||
|
FOR EACH ROW
|
||||||
|
WHEN (NEW.platform = 'walmart_marketplace')
|
||||||
|
EXECUTE FUNCTION mock.process_raw_walmart_marketplace_event();
|
||||||
|
|
||||||
|
|
||||||
|
CREATE OR REPLACE FUNCTION mock.process_raw_wix_event() RETURNS TRIGGER AS $process_raw_wix_event$
|
||||||
|
BEGIN
|
||||||
|
INSERT INTO mock.shop_wix_events (
|
||||||
|
platform,
|
||||||
|
store_id,
|
||||||
|
event_timestamp,
|
||||||
|
event_id
|
||||||
|
)
|
||||||
|
SELECT
|
||||||
|
NEW.platform,
|
||||||
|
NEW.store_id,
|
||||||
|
NEW.event_timestamp,
|
||||||
|
NEW.event_id;
|
||||||
|
RETURN NULL;
|
||||||
|
END;
|
||||||
|
$process_raw_wix_event$ LANGUAGE plpgsql;
|
||||||
|
|
||||||
|
CREATE OR REPLACE TRIGGER wix_store_events
|
||||||
|
AFTER INSERT ON mock.raw_shop_events
|
||||||
|
FOR EACH ROW
|
||||||
|
WHEN (NEW.platform = 'wix')
|
||||||
|
EXECUTE FUNCTION mock.process_raw_wix_event();
|
||||||
|
|
||||||
|
|
||||||
|
CREATE OR REPLACE FUNCTION mock.process_raw_woo_commerce_event() RETURNS TRIGGER AS $process_raw_woo_commerce_event$
|
||||||
|
BEGIN
|
||||||
|
INSERT INTO mock.shop_woo_commerce_events (
|
||||||
|
platform,
|
||||||
|
store_id,
|
||||||
|
event_timestamp,
|
||||||
|
event_id
|
||||||
|
)
|
||||||
|
SELECT
|
||||||
|
NEW.platform,
|
||||||
|
NEW.store_id,
|
||||||
|
NEW.event_timestamp,
|
||||||
|
NEW.event_id;
|
||||||
|
RETURN NULL;
|
||||||
|
END;
|
||||||
|
$process_raw_woo_commerce_event$ LANGUAGE plpgsql;
|
||||||
|
|
||||||
|
CREATE OR REPLACE TRIGGER woo_commerce_store_events
|
||||||
|
AFTER INSERT ON mock.raw_shop_events
|
||||||
|
FOR EACH ROW
|
||||||
|
WHEN (NEW.platform = 'woo_commerce')
|
||||||
|
EXECUTE FUNCTION mock.process_raw_woo_commerce_event();
|
||||||
|
|
||||||
|
|
||||||
|
CREATE OR REPLACE FUNCTION mock.process_raw_zoho_event() RETURNS TRIGGER AS $process_raw_zoho_event$
|
||||||
|
BEGIN
|
||||||
|
INSERT INTO mock.shop_zoho_events (
|
||||||
|
platform,
|
||||||
|
store_id,
|
||||||
|
event_timestamp,
|
||||||
|
event_id
|
||||||
|
)
|
||||||
|
SELECT
|
||||||
|
NEW.platform,
|
||||||
|
NEW.store_id,
|
||||||
|
NEW.event_timestamp,
|
||||||
|
NEW.event_id;
|
||||||
|
RETURN NULL;
|
||||||
|
END;
|
||||||
|
$process_raw_zoho_event$ LANGUAGE plpgsql;
|
||||||
|
|
||||||
|
CREATE OR REPLACE TRIGGER zoho_store_events
|
||||||
|
AFTER INSERT ON mock.raw_shop_events
|
||||||
|
FOR EACH ROW
|
||||||
|
WHEN (NEW.platform = 'zoho')
|
||||||
|
EXECUTE FUNCTION mock.process_raw_zoho_event();
|
||||||
|
|
||||||
|
|
||||||
|
COMMIT;
|
||||||
File diff suppressed because one or more lines are too long
|
Before Width: | Height: | Size: 414 KiB After Width: | Height: | Size: 471 KiB |
@@ -9,6 +9,16 @@ entity "**accounts**" {
|
|||||||
*""user_id"": //text [FK]//
|
*""user_id"": //text [FK]//
|
||||||
}
|
}
|
||||||
|
|
||||||
|
entity "**raw_shop_events**" {
|
||||||
|
+ ""platform"": //text [PK]//
|
||||||
|
+ ""store_id"": //text [PK]//
|
||||||
|
+ ""event_timestamp"": //timestamp with time zone [PK]//
|
||||||
|
+ ""event_id"": //text [PK]//
|
||||||
|
--
|
||||||
|
*""raw_payload"": //jsonb //
|
||||||
|
*""parsed"": //boolean //
|
||||||
|
}
|
||||||
|
|
||||||
entity "**shop_amazon**" {
|
entity "**shop_amazon**" {
|
||||||
+ ""account_id"": //integer [PK][FK]//
|
+ ""account_id"": //integer [PK][FK]//
|
||||||
+ ""shop_id"": //text [PK]//
|
+ ""shop_id"": //text [PK]//
|
||||||
@@ -17,6 +27,14 @@ entity "**shop_amazon**" {
|
|||||||
*""name"": //text //
|
*""name"": //text //
|
||||||
}
|
}
|
||||||
|
|
||||||
|
entity "**shop_amazon_events**" {
|
||||||
|
+ ""store_id"": //text [PK]//
|
||||||
|
+ ""event_timestamp"": //timestamp with time zone [PK][FK]//
|
||||||
|
+ ""event_id"": //text [PK]//
|
||||||
|
--
|
||||||
|
*""platform"": //text //
|
||||||
|
}
|
||||||
|
|
||||||
entity "**shop_amazon_listings**" {
|
entity "**shop_amazon_listings**" {
|
||||||
+ ""shop_id"": //text [PK][FK]//
|
+ ""shop_id"": //text [PK][FK]//
|
||||||
+ ""listing_id"": //text [PK]//
|
+ ""listing_id"": //text [PK]//
|
||||||
@@ -63,6 +81,14 @@ entity "**shop_big_cartel**" {
|
|||||||
*""name"": //text //
|
*""name"": //text //
|
||||||
}
|
}
|
||||||
|
|
||||||
|
entity "**shop_big_cartel_events**" {
|
||||||
|
+ ""store_id"": //text [PK]//
|
||||||
|
+ ""event_timestamp"": //timestamp with time zone [PK][FK]//
|
||||||
|
+ ""event_id"": //text [PK]//
|
||||||
|
--
|
||||||
|
*""platform"": //text //
|
||||||
|
}
|
||||||
|
|
||||||
entity "**shop_big_cartel_listings**" {
|
entity "**shop_big_cartel_listings**" {
|
||||||
+ ""shop_id"": //text [PK][FK]//
|
+ ""shop_id"": //text [PK][FK]//
|
||||||
+ ""listing_id"": //text [PK]//
|
+ ""listing_id"": //text [PK]//
|
||||||
@@ -109,6 +135,14 @@ entity "**shop_ebay**" {
|
|||||||
*""name"": //text //
|
*""name"": //text //
|
||||||
}
|
}
|
||||||
|
|
||||||
|
entity "**shop_ebay_events**" {
|
||||||
|
+ ""store_id"": //text [PK]//
|
||||||
|
+ ""event_timestamp"": //timestamp with time zone [PK][FK]//
|
||||||
|
+ ""event_id"": //text [PK]//
|
||||||
|
--
|
||||||
|
*""platform"": //text //
|
||||||
|
}
|
||||||
|
|
||||||
entity "**shop_ebay_listings**" {
|
entity "**shop_ebay_listings**" {
|
||||||
+ ""shop_id"": //text [PK][FK]//
|
+ ""shop_id"": //text [PK][FK]//
|
||||||
+ ""listing_id"": //text [PK]//
|
+ ""listing_id"": //text [PK]//
|
||||||
@@ -155,6 +189,14 @@ entity "**shop_ecwid**" {
|
|||||||
*""name"": //text //
|
*""name"": //text //
|
||||||
}
|
}
|
||||||
|
|
||||||
|
entity "**shop_ecwid_events**" {
|
||||||
|
+ ""store_id"": //text [PK]//
|
||||||
|
+ ""event_timestamp"": //timestamp with time zone [PK][FK]//
|
||||||
|
+ ""event_id"": //text [PK]//
|
||||||
|
--
|
||||||
|
*""platform"": //text //
|
||||||
|
}
|
||||||
|
|
||||||
entity "**shop_ecwid_listings**" {
|
entity "**shop_ecwid_listings**" {
|
||||||
+ ""shop_id"": //text [PK][FK]//
|
+ ""shop_id"": //text [PK][FK]//
|
||||||
+ ""listing_id"": //text [PK]//
|
+ ""listing_id"": //text [PK]//
|
||||||
@@ -201,6 +243,14 @@ entity "**shop_etsy**" {
|
|||||||
*""name"": //text //
|
*""name"": //text //
|
||||||
}
|
}
|
||||||
|
|
||||||
|
entity "**shop_etsy_events**" {
|
||||||
|
+ ""store_id"": //text [PK]//
|
||||||
|
+ ""event_timestamp"": //timestamp with time zone [PK][FK]//
|
||||||
|
+ ""event_id"": //text [PK]//
|
||||||
|
--
|
||||||
|
*""platform"": //text //
|
||||||
|
}
|
||||||
|
|
||||||
entity "**shop_etsy_listings**" {
|
entity "**shop_etsy_listings**" {
|
||||||
+ ""shop_id"": //text [PK][FK]//
|
+ ""shop_id"": //text [PK][FK]//
|
||||||
+ ""listing_id"": //text [PK]//
|
+ ""listing_id"": //text [PK]//
|
||||||
@@ -247,6 +297,14 @@ entity "**shop_shopify**" {
|
|||||||
*""name"": //text //
|
*""name"": //text //
|
||||||
}
|
}
|
||||||
|
|
||||||
|
entity "**shop_shopify_events**" {
|
||||||
|
+ ""store_id"": //text [PK]//
|
||||||
|
+ ""event_timestamp"": //timestamp with time zone [PK][FK]//
|
||||||
|
+ ""event_id"": //text [PK]//
|
||||||
|
--
|
||||||
|
*""platform"": //text //
|
||||||
|
}
|
||||||
|
|
||||||
entity "**shop_shopify_listings**" {
|
entity "**shop_shopify_listings**" {
|
||||||
+ ""shop_id"": //text [PK][FK]//
|
+ ""shop_id"": //text [PK][FK]//
|
||||||
+ ""listing_id"": //text [PK]//
|
+ ""listing_id"": //text [PK]//
|
||||||
@@ -293,6 +351,14 @@ entity "**shop_square_online**" {
|
|||||||
*""name"": //text //
|
*""name"": //text //
|
||||||
}
|
}
|
||||||
|
|
||||||
|
entity "**shop_square_online_events**" {
|
||||||
|
+ ""store_id"": //text [PK]//
|
||||||
|
+ ""event_timestamp"": //timestamp with time zone [PK][FK]//
|
||||||
|
+ ""event_id"": //text [PK]//
|
||||||
|
--
|
||||||
|
*""platform"": //text //
|
||||||
|
}
|
||||||
|
|
||||||
entity "**shop_square_online_listings**" {
|
entity "**shop_square_online_listings**" {
|
||||||
+ ""shop_id"": //text [PK][FK]//
|
+ ""shop_id"": //text [PK][FK]//
|
||||||
+ ""listing_id"": //text [PK]//
|
+ ""listing_id"": //text [PK]//
|
||||||
@@ -339,6 +405,14 @@ entity "**shop_squarespace**" {
|
|||||||
*""name"": //text //
|
*""name"": //text //
|
||||||
}
|
}
|
||||||
|
|
||||||
|
entity "**shop_squarespace_events**" {
|
||||||
|
+ ""store_id"": //text [PK]//
|
||||||
|
+ ""event_timestamp"": //timestamp with time zone [PK][FK]//
|
||||||
|
+ ""event_id"": //text [PK]//
|
||||||
|
--
|
||||||
|
*""platform"": //text //
|
||||||
|
}
|
||||||
|
|
||||||
entity "**shop_squarespace_listings**" {
|
entity "**shop_squarespace_listings**" {
|
||||||
+ ""shop_id"": //text [PK][FK]//
|
+ ""shop_id"": //text [PK][FK]//
|
||||||
+ ""listing_id"": //text [PK]//
|
+ ""listing_id"": //text [PK]//
|
||||||
@@ -385,6 +459,14 @@ entity "**shop_tiktok**" {
|
|||||||
*""name"": //text //
|
*""name"": //text //
|
||||||
}
|
}
|
||||||
|
|
||||||
|
entity "**shop_tiktok_events**" {
|
||||||
|
+ ""store_id"": //text [PK]//
|
||||||
|
+ ""event_timestamp"": //timestamp with time zone [PK][FK]//
|
||||||
|
+ ""event_id"": //text [PK]//
|
||||||
|
--
|
||||||
|
*""platform"": //text //
|
||||||
|
}
|
||||||
|
|
||||||
entity "**shop_tiktok_listings**" {
|
entity "**shop_tiktok_listings**" {
|
||||||
+ ""shop_id"": //text [PK][FK]//
|
+ ""shop_id"": //text [PK][FK]//
|
||||||
+ ""listing_id"": //text [PK]//
|
+ ""listing_id"": //text [PK]//
|
||||||
@@ -431,6 +513,14 @@ entity "**shop_walmart_marketplace**" {
|
|||||||
*""name"": //text //
|
*""name"": //text //
|
||||||
}
|
}
|
||||||
|
|
||||||
|
entity "**shop_walmart_marketplace_events**" {
|
||||||
|
+ ""store_id"": //text [PK]//
|
||||||
|
+ ""event_timestamp"": //timestamp with time zone [PK][FK]//
|
||||||
|
+ ""event_id"": //text [PK]//
|
||||||
|
--
|
||||||
|
*""platform"": //text //
|
||||||
|
}
|
||||||
|
|
||||||
entity "**shop_walmart_marketplace_listings**" {
|
entity "**shop_walmart_marketplace_listings**" {
|
||||||
+ ""shop_id"": //text [PK][FK]//
|
+ ""shop_id"": //text [PK][FK]//
|
||||||
+ ""listing_id"": //text [PK]//
|
+ ""listing_id"": //text [PK]//
|
||||||
@@ -477,6 +567,14 @@ entity "**shop_wix**" {
|
|||||||
*""name"": //text //
|
*""name"": //text //
|
||||||
}
|
}
|
||||||
|
|
||||||
|
entity "**shop_wix_events**" {
|
||||||
|
+ ""store_id"": //text [PK]//
|
||||||
|
+ ""event_timestamp"": //timestamp with time zone [PK][FK]//
|
||||||
|
+ ""event_id"": //text [PK]//
|
||||||
|
--
|
||||||
|
*""platform"": //text //
|
||||||
|
}
|
||||||
|
|
||||||
entity "**shop_wix_listings**" {
|
entity "**shop_wix_listings**" {
|
||||||
+ ""shop_id"": //text [PK][FK]//
|
+ ""shop_id"": //text [PK][FK]//
|
||||||
+ ""listing_id"": //text [PK]//
|
+ ""listing_id"": //text [PK]//
|
||||||
@@ -523,6 +621,14 @@ entity "**shop_woo_commerce**" {
|
|||||||
*""name"": //text //
|
*""name"": //text //
|
||||||
}
|
}
|
||||||
|
|
||||||
|
entity "**shop_woo_commerce_events**" {
|
||||||
|
+ ""store_id"": //text [PK]//
|
||||||
|
+ ""event_timestamp"": //timestamp with time zone [PK][FK]//
|
||||||
|
+ ""event_id"": //text [PK]//
|
||||||
|
--
|
||||||
|
*""platform"": //text //
|
||||||
|
}
|
||||||
|
|
||||||
entity "**shop_woo_commerce_listings**" {
|
entity "**shop_woo_commerce_listings**" {
|
||||||
+ ""shop_id"": //text [PK][FK]//
|
+ ""shop_id"": //text [PK][FK]//
|
||||||
+ ""listing_id"": //text [PK]//
|
+ ""listing_id"": //text [PK]//
|
||||||
@@ -569,6 +675,14 @@ entity "**shop_zoho**" {
|
|||||||
*""name"": //text //
|
*""name"": //text //
|
||||||
}
|
}
|
||||||
|
|
||||||
|
entity "**shop_zoho_events**" {
|
||||||
|
+ ""store_id"": //text [PK]//
|
||||||
|
+ ""event_timestamp"": //timestamp with time zone [PK][FK]//
|
||||||
|
+ ""event_id"": //text [PK]//
|
||||||
|
--
|
||||||
|
*""platform"": //text //
|
||||||
|
}
|
||||||
|
|
||||||
entity "**shop_zoho_listings**" {
|
entity "**shop_zoho_listings**" {
|
||||||
+ ""shop_id"": //text [PK][FK]//
|
+ ""shop_id"": //text [PK][FK]//
|
||||||
+ ""listing_id"": //text [PK]//
|
+ ""listing_id"": //text [PK]//
|
||||||
@@ -654,6 +768,8 @@ entity "**sync_groups**" {
|
|||||||
|
|
||||||
"**shop_amazon**" }-- "**public.oauth_users**"
|
"**shop_amazon**" }-- "**public.oauth_users**"
|
||||||
|
|
||||||
|
"**shop_amazon_events**" ||-|| "**raw_shop_events**"
|
||||||
|
|
||||||
"**shop_amazon_listings**" }-- "**accounts**"
|
"**shop_amazon_listings**" }-- "**accounts**"
|
||||||
|
|
||||||
"**shop_amazon_listings**" ||-|| "**shop_amazon**"
|
"**shop_amazon_listings**" ||-|| "**shop_amazon**"
|
||||||
@@ -684,6 +800,8 @@ entity "**sync_groups**" {
|
|||||||
|
|
||||||
"**shop_big_cartel**" }-- "**public.oauth_users**"
|
"**shop_big_cartel**" }-- "**public.oauth_users**"
|
||||||
|
|
||||||
|
"**shop_big_cartel_events**" ||-|| "**raw_shop_events**"
|
||||||
|
|
||||||
"**shop_big_cartel_listings**" }-- "**accounts**"
|
"**shop_big_cartel_listings**" }-- "**accounts**"
|
||||||
|
|
||||||
"**shop_big_cartel_listings**" ||-|| "**shop_big_cartel**"
|
"**shop_big_cartel_listings**" ||-|| "**shop_big_cartel**"
|
||||||
@@ -714,6 +832,8 @@ entity "**sync_groups**" {
|
|||||||
|
|
||||||
"**shop_ebay**" }-- "**public.oauth_users**"
|
"**shop_ebay**" }-- "**public.oauth_users**"
|
||||||
|
|
||||||
|
"**shop_ebay_events**" ||-|| "**raw_shop_events**"
|
||||||
|
|
||||||
"**shop_ebay_listings**" }-- "**accounts**"
|
"**shop_ebay_listings**" }-- "**accounts**"
|
||||||
|
|
||||||
"**shop_ebay_listings**" ||-|| "**shop_ebay**"
|
"**shop_ebay_listings**" ||-|| "**shop_ebay**"
|
||||||
@@ -744,6 +864,8 @@ entity "**sync_groups**" {
|
|||||||
|
|
||||||
"**shop_ecwid**" }-- "**public.oauth_users**"
|
"**shop_ecwid**" }-- "**public.oauth_users**"
|
||||||
|
|
||||||
|
"**shop_ecwid_events**" ||-|| "**raw_shop_events**"
|
||||||
|
|
||||||
"**shop_ecwid_listings**" }-- "**accounts**"
|
"**shop_ecwid_listings**" }-- "**accounts**"
|
||||||
|
|
||||||
"**shop_ecwid_listings**" ||-|| "**shop_ecwid**"
|
"**shop_ecwid_listings**" ||-|| "**shop_ecwid**"
|
||||||
@@ -774,6 +896,8 @@ entity "**sync_groups**" {
|
|||||||
|
|
||||||
"**shop_etsy**" }-- "**public.oauth_users**"
|
"**shop_etsy**" }-- "**public.oauth_users**"
|
||||||
|
|
||||||
|
"**shop_etsy_events**" ||-|| "**raw_shop_events**"
|
||||||
|
|
||||||
"**shop_etsy_listings**" }-- "**accounts**"
|
"**shop_etsy_listings**" }-- "**accounts**"
|
||||||
|
|
||||||
"**shop_etsy_listings**" ||-|| "**shop_etsy**"
|
"**shop_etsy_listings**" ||-|| "**shop_etsy**"
|
||||||
@@ -804,6 +928,8 @@ entity "**sync_groups**" {
|
|||||||
|
|
||||||
"**shop_shopify**" }-- "**public.oauth_users**"
|
"**shop_shopify**" }-- "**public.oauth_users**"
|
||||||
|
|
||||||
|
"**shop_shopify_events**" ||-|| "**raw_shop_events**"
|
||||||
|
|
||||||
"**shop_shopify_listings**" }-- "**accounts**"
|
"**shop_shopify_listings**" }-- "**accounts**"
|
||||||
|
|
||||||
"**shop_shopify_listings**" ||-|| "**shop_shopify**"
|
"**shop_shopify_listings**" ||-|| "**shop_shopify**"
|
||||||
@@ -834,6 +960,8 @@ entity "**sync_groups**" {
|
|||||||
|
|
||||||
"**shop_square_online**" }-- "**public.oauth_users**"
|
"**shop_square_online**" }-- "**public.oauth_users**"
|
||||||
|
|
||||||
|
"**shop_square_online_events**" ||-|| "**raw_shop_events**"
|
||||||
|
|
||||||
"**shop_square_online_listings**" }-- "**accounts**"
|
"**shop_square_online_listings**" }-- "**accounts**"
|
||||||
|
|
||||||
"**shop_square_online_listings**" ||-|| "**shop_square_online**"
|
"**shop_square_online_listings**" ||-|| "**shop_square_online**"
|
||||||
@@ -864,6 +992,8 @@ entity "**sync_groups**" {
|
|||||||
|
|
||||||
"**shop_squarespace**" }-- "**public.oauth_users**"
|
"**shop_squarespace**" }-- "**public.oauth_users**"
|
||||||
|
|
||||||
|
"**shop_squarespace_events**" ||-|| "**raw_shop_events**"
|
||||||
|
|
||||||
"**shop_squarespace_listings**" }-- "**accounts**"
|
"**shop_squarespace_listings**" }-- "**accounts**"
|
||||||
|
|
||||||
"**shop_squarespace_listings**" ||-|| "**shop_squarespace**"
|
"**shop_squarespace_listings**" ||-|| "**shop_squarespace**"
|
||||||
@@ -894,6 +1024,8 @@ entity "**sync_groups**" {
|
|||||||
|
|
||||||
"**shop_tiktok**" }-- "**public.oauth_users**"
|
"**shop_tiktok**" }-- "**public.oauth_users**"
|
||||||
|
|
||||||
|
"**shop_tiktok_events**" ||-|| "**raw_shop_events**"
|
||||||
|
|
||||||
"**shop_tiktok_listings**" }-- "**accounts**"
|
"**shop_tiktok_listings**" }-- "**accounts**"
|
||||||
|
|
||||||
"**shop_tiktok_listings**" ||-|| "**shop_tiktok**"
|
"**shop_tiktok_listings**" ||-|| "**shop_tiktok**"
|
||||||
@@ -924,6 +1056,8 @@ entity "**sync_groups**" {
|
|||||||
|
|
||||||
"**shop_walmart_marketplace**" }-- "**public.oauth_users**"
|
"**shop_walmart_marketplace**" }-- "**public.oauth_users**"
|
||||||
|
|
||||||
|
"**shop_walmart_marketplace_events**" ||-|| "**raw_shop_events**"
|
||||||
|
|
||||||
"**shop_walmart_marketplace_listings**" }-- "**accounts**"
|
"**shop_walmart_marketplace_listings**" }-- "**accounts**"
|
||||||
|
|
||||||
"**shop_walmart_marketplace_listings**" ||-|| "**shop_walmart_marketplace**"
|
"**shop_walmart_marketplace_listings**" ||-|| "**shop_walmart_marketplace**"
|
||||||
@@ -954,6 +1088,8 @@ entity "**sync_groups**" {
|
|||||||
|
|
||||||
"**shop_wix**" }-- "**public.oauth_users**"
|
"**shop_wix**" }-- "**public.oauth_users**"
|
||||||
|
|
||||||
|
"**shop_wix_events**" ||-|| "**raw_shop_events**"
|
||||||
|
|
||||||
"**shop_wix_listings**" }-- "**accounts**"
|
"**shop_wix_listings**" }-- "**accounts**"
|
||||||
|
|
||||||
"**shop_wix_listings**" ||-|| "**shop_wix**"
|
"**shop_wix_listings**" ||-|| "**shop_wix**"
|
||||||
@@ -984,6 +1120,8 @@ entity "**sync_groups**" {
|
|||||||
|
|
||||||
"**shop_woo_commerce**" }-- "**public.oauth_users**"
|
"**shop_woo_commerce**" }-- "**public.oauth_users**"
|
||||||
|
|
||||||
|
"**shop_woo_commerce_events**" ||-|| "**raw_shop_events**"
|
||||||
|
|
||||||
"**shop_woo_commerce_listings**" }-- "**accounts**"
|
"**shop_woo_commerce_listings**" }-- "**accounts**"
|
||||||
|
|
||||||
"**shop_woo_commerce_listings**" ||-|| "**shop_woo_commerce**"
|
"**shop_woo_commerce_listings**" ||-|| "**shop_woo_commerce**"
|
||||||
@@ -1014,6 +1152,8 @@ entity "**sync_groups**" {
|
|||||||
|
|
||||||
"**shop_zoho**" }-- "**public.oauth_users**"
|
"**shop_zoho**" }-- "**public.oauth_users**"
|
||||||
|
|
||||||
|
"**shop_zoho_events**" ||-|| "**raw_shop_events**"
|
||||||
|
|
||||||
"**shop_zoho_listings**" }-- "**accounts**"
|
"**shop_zoho_listings**" }-- "**accounts**"
|
||||||
|
|
||||||
"**shop_zoho_listings**" ||-|| "**shop_zoho**"
|
"**shop_zoho_listings**" ||-|| "**shop_zoho**"
|
||||||
|
|||||||
+112
-25
@@ -197,6 +197,29 @@
|
|||||||
.bottom-0 {
|
.bottom-0 {
|
||||||
bottom: calc(var(--spacing) * 0);
|
bottom: calc(var(--spacing) * 0);
|
||||||
}
|
}
|
||||||
|
.grid-table-\[1fr_1fr_1fr_1fr_1fr_1fr\] {
|
||||||
|
&:is(table) {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: 1fr 1fr 1fr 1fr 1fr 1fr;
|
||||||
|
& > :is(thead, tbody, tfoot) {
|
||||||
|
grid-column-start: 1;
|
||||||
|
grid-column-end: -1;
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: subgrid;
|
||||||
|
& > tr {
|
||||||
|
grid-column-start: 1;
|
||||||
|
grid-column-end: -1;
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: subgrid;
|
||||||
|
& > th, & > td {
|
||||||
|
grid-column: span 1;
|
||||||
|
align-content: center;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
.grid-table-\[1fr_1fr_1fr_1fr_1fr_1fr_1fr\] {
|
.grid-table-\[1fr_1fr_1fr_1fr_1fr_1fr_1fr\] {
|
||||||
&:is(table) {
|
&:is(table) {
|
||||||
display: grid;
|
display: grid;
|
||||||
@@ -289,6 +312,9 @@
|
|||||||
.mt-\[3em\] {
|
.mt-\[3em\] {
|
||||||
margin-top: 3em;
|
margin-top: 3em;
|
||||||
}
|
}
|
||||||
|
.mb-0 {
|
||||||
|
margin-bottom: calc(var(--spacing) * 0);
|
||||||
|
}
|
||||||
.mb-\[0\.5em\] {
|
.mb-\[0\.5em\] {
|
||||||
margin-bottom: 0.5em;
|
margin-bottom: 0.5em;
|
||||||
}
|
}
|
||||||
@@ -301,6 +327,9 @@
|
|||||||
.mb-\[3em\] {
|
.mb-\[3em\] {
|
||||||
margin-bottom: 3em;
|
margin-bottom: 3em;
|
||||||
}
|
}
|
||||||
|
.ml-\[0\.5em\] {
|
||||||
|
margin-left: 0.5em;
|
||||||
|
}
|
||||||
.ml-\[1em\] {
|
.ml-\[1em\] {
|
||||||
margin-left: 1em;
|
margin-left: 1em;
|
||||||
}
|
}
|
||||||
@@ -370,6 +399,9 @@
|
|||||||
.flex-shrink {
|
.flex-shrink {
|
||||||
flex-shrink: 1;
|
flex-shrink: 1;
|
||||||
}
|
}
|
||||||
|
.flex-grow {
|
||||||
|
flex-grow: 1;
|
||||||
|
}
|
||||||
.flex-grow-\[1\] {
|
.flex-grow-\[1\] {
|
||||||
flex-grow: 1;
|
flex-grow: 1;
|
||||||
}
|
}
|
||||||
@@ -385,6 +417,12 @@
|
|||||||
.basis-full {
|
.basis-full {
|
||||||
flex-basis: 100%;
|
flex-basis: 100%;
|
||||||
}
|
}
|
||||||
|
.border-collapse {
|
||||||
|
border-collapse: collapse;
|
||||||
|
}
|
||||||
|
.transform {
|
||||||
|
transform: var(--tw-rotate-x,) var(--tw-rotate-y,) var(--tw-rotate-z,) var(--tw-skew-x,) var(--tw-skew-y,);
|
||||||
|
}
|
||||||
.animate-pulse {
|
.animate-pulse {
|
||||||
animation: var(--animate-pulse);
|
animation: var(--animate-pulse);
|
||||||
}
|
}
|
||||||
@@ -495,6 +533,15 @@
|
|||||||
.border-\[gray\] {
|
.border-\[gray\] {
|
||||||
border-color: gray;
|
border-color: gray;
|
||||||
}
|
}
|
||||||
|
.border-\[red\] {
|
||||||
|
border-color: red;
|
||||||
|
}
|
||||||
|
.border-\[white\] {
|
||||||
|
border-color: white;
|
||||||
|
}
|
||||||
|
.border-accent {
|
||||||
|
border-color: var(--accent);
|
||||||
|
}
|
||||||
.border-border {
|
.border-border {
|
||||||
border-color: var(--border);
|
border-color: var(--border);
|
||||||
}
|
}
|
||||||
@@ -507,6 +554,9 @@
|
|||||||
.border-sidebar-border {
|
.border-sidebar-border {
|
||||||
border-color: var(--sidebar-border);
|
border-color: var(--sidebar-border);
|
||||||
}
|
}
|
||||||
|
.bg-\[red\] {
|
||||||
|
background-color: red;
|
||||||
|
}
|
||||||
.bg-accent {
|
.bg-accent {
|
||||||
background-color: var(--accent);
|
background-color: var(--accent);
|
||||||
}
|
}
|
||||||
@@ -519,6 +569,9 @@
|
|||||||
.bg-card {
|
.bg-card {
|
||||||
background-color: var(--card);
|
background-color: var(--card);
|
||||||
}
|
}
|
||||||
|
.bg-none {
|
||||||
|
background-image: none;
|
||||||
|
}
|
||||||
.p-\[0\.5em\] {
|
.p-\[0\.5em\] {
|
||||||
padding: 0.5em;
|
padding: 0.5em;
|
||||||
}
|
}
|
||||||
@@ -558,6 +611,9 @@
|
|||||||
.font-display {
|
.font-display {
|
||||||
font-family: var(--display-family);
|
font-family: var(--display-family);
|
||||||
}
|
}
|
||||||
|
.font-text {
|
||||||
|
font-family: var(--text-family);
|
||||||
|
}
|
||||||
.text-lg {
|
.text-lg {
|
||||||
font-size: var(--text-lg);
|
font-size: var(--text-lg);
|
||||||
line-height: var(--tw-leading, var(--text-lg--line-height));
|
line-height: var(--tw-leading, var(--text-lg--line-height));
|
||||||
@@ -573,6 +629,10 @@
|
|||||||
.text-\[1\.5em\] {
|
.text-\[1\.5em\] {
|
||||||
font-size: 1.5em;
|
font-size: 1.5em;
|
||||||
}
|
}
|
||||||
|
.font-\[1\.5em\] {
|
||||||
|
--tw-font-weight: 1.5em;
|
||||||
|
font-weight: 1.5em;
|
||||||
|
}
|
||||||
.font-bold {
|
.font-bold {
|
||||||
--tw-font-weight: var(--font-weight-bold);
|
--tw-font-weight: var(--font-weight-bold);
|
||||||
font-weight: var(--font-weight-bold);
|
font-weight: var(--font-weight-bold);
|
||||||
@@ -584,6 +644,12 @@
|
|||||||
.text-nowrap {
|
.text-nowrap {
|
||||||
text-wrap: nowrap;
|
text-wrap: nowrap;
|
||||||
}
|
}
|
||||||
|
.text-wrap {
|
||||||
|
text-wrap: wrap;
|
||||||
|
}
|
||||||
|
.text-inherit {
|
||||||
|
color: inherit;
|
||||||
|
}
|
||||||
.capitalize {
|
.capitalize {
|
||||||
text-transform: capitalize;
|
text-transform: capitalize;
|
||||||
}
|
}
|
||||||
@@ -593,13 +659,24 @@
|
|||||||
.underline {
|
.underline {
|
||||||
text-decoration-line: underline;
|
text-decoration-line: underline;
|
||||||
}
|
}
|
||||||
|
.outline {
|
||||||
|
outline-style: var(--tw-outline-style);
|
||||||
|
outline-width: 1px;
|
||||||
|
}
|
||||||
.outline-1 {
|
.outline-1 {
|
||||||
outline-style: var(--tw-outline-style);
|
outline-style: var(--tw-outline-style);
|
||||||
outline-width: 1px;
|
outline-width: 1px;
|
||||||
}
|
}
|
||||||
|
.outline-\[1px\] {
|
||||||
|
outline-style: var(--tw-outline-style);
|
||||||
|
outline-width: 1px;
|
||||||
|
}
|
||||||
.outline-\(--table-tfoot\) {
|
.outline-\(--table-tfoot\) {
|
||||||
outline-color: var(--table-tfoot);
|
outline-color: var(--table-tfoot);
|
||||||
}
|
}
|
||||||
|
.outline-\[red\] {
|
||||||
|
outline-color: red;
|
||||||
|
}
|
||||||
.filter {
|
.filter {
|
||||||
filter: var(--tw-blur,) var(--tw-brightness,) var(--tw-contrast,) var(--tw-grayscale,) var(--tw-hue-rotate,) var(--tw-invert,) var(--tw-saturate,) var(--tw-sepia,) var(--tw-drop-shadow,);
|
filter: var(--tw-blur,) var(--tw-brightness,) var(--tw-contrast,) var(--tw-grayscale,) var(--tw-hue-rotate,) var(--tw-invert,) var(--tw-saturate,) var(--tw-sepia,) var(--tw-drop-shadow,);
|
||||||
}
|
}
|
||||||
@@ -613,6 +690,16 @@
|
|||||||
transition-timing-function: var(--tw-ease, var(--default-transition-timing-function));
|
transition-timing-function: var(--tw-ease, var(--default-transition-timing-function));
|
||||||
transition-duration: var(--tw-duration, var(--default-transition-duration));
|
transition-duration: var(--tw-duration, var(--default-transition-duration));
|
||||||
}
|
}
|
||||||
|
.\*\:bg-background {
|
||||||
|
:is(& > *) {
|
||||||
|
background-color: var(--background);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.\*\*\:bg-background {
|
||||||
|
:is(& *) {
|
||||||
|
background-color: var(--background);
|
||||||
|
}
|
||||||
|
}
|
||||||
.not-open\:mb-\[1em\] {
|
.not-open\:mb-\[1em\] {
|
||||||
&:not(*:is([open], :popover-open, :open)) {
|
&:not(*:is([open], :popover-open, :open)) {
|
||||||
margin-bottom: 1em;
|
margin-bottom: 1em;
|
||||||
@@ -1167,6 +1254,26 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@property --tw-rotate-x {
|
||||||
|
syntax: "*";
|
||||||
|
inherits: false;
|
||||||
|
}
|
||||||
|
@property --tw-rotate-y {
|
||||||
|
syntax: "*";
|
||||||
|
inherits: false;
|
||||||
|
}
|
||||||
|
@property --tw-rotate-z {
|
||||||
|
syntax: "*";
|
||||||
|
inherits: false;
|
||||||
|
}
|
||||||
|
@property --tw-skew-x {
|
||||||
|
syntax: "*";
|
||||||
|
inherits: false;
|
||||||
|
}
|
||||||
|
@property --tw-skew-y {
|
||||||
|
syntax: "*";
|
||||||
|
inherits: false;
|
||||||
|
}
|
||||||
@property --tw-border-style {
|
@property --tw-border-style {
|
||||||
syntax: "*";
|
syntax: "*";
|
||||||
inherits: false;
|
inherits: false;
|
||||||
@@ -1249,26 +1356,6 @@
|
|||||||
inherits: false;
|
inherits: false;
|
||||||
initial-value: 1;
|
initial-value: 1;
|
||||||
}
|
}
|
||||||
@property --tw-rotate-x {
|
|
||||||
syntax: "*";
|
|
||||||
inherits: false;
|
|
||||||
}
|
|
||||||
@property --tw-rotate-y {
|
|
||||||
syntax: "*";
|
|
||||||
inherits: false;
|
|
||||||
}
|
|
||||||
@property --tw-rotate-z {
|
|
||||||
syntax: "*";
|
|
||||||
inherits: false;
|
|
||||||
}
|
|
||||||
@property --tw-skew-x {
|
|
||||||
syntax: "*";
|
|
||||||
inherits: false;
|
|
||||||
}
|
|
||||||
@property --tw-skew-y {
|
|
||||||
syntax: "*";
|
|
||||||
inherits: false;
|
|
||||||
}
|
|
||||||
@property --tw-content {
|
@property --tw-content {
|
||||||
syntax: "*";
|
syntax: "*";
|
||||||
initial-value: "";
|
initial-value: "";
|
||||||
@@ -1286,6 +1373,11 @@
|
|||||||
@layer properties {
|
@layer properties {
|
||||||
@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))) {
|
@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))) {
|
||||||
*, ::before, ::after, ::backdrop {
|
*, ::before, ::after, ::backdrop {
|
||||||
|
--tw-rotate-x: initial;
|
||||||
|
--tw-rotate-y: initial;
|
||||||
|
--tw-rotate-z: initial;
|
||||||
|
--tw-skew-x: initial;
|
||||||
|
--tw-skew-y: initial;
|
||||||
--tw-border-style: solid;
|
--tw-border-style: solid;
|
||||||
--tw-font-weight: initial;
|
--tw-font-weight: initial;
|
||||||
--tw-outline-style: solid;
|
--tw-outline-style: solid;
|
||||||
@@ -1305,11 +1397,6 @@
|
|||||||
--tw-scale-x: 1;
|
--tw-scale-x: 1;
|
||||||
--tw-scale-y: 1;
|
--tw-scale-y: 1;
|
||||||
--tw-scale-z: 1;
|
--tw-scale-z: 1;
|
||||||
--tw-rotate-x: initial;
|
|
||||||
--tw-rotate-y: initial;
|
|
||||||
--tw-rotate-z: initial;
|
|
||||||
--tw-skew-x: initial;
|
|
||||||
--tw-skew-y: initial;
|
|
||||||
--tw-content: "";
|
--tw-content: "";
|
||||||
--tw-leading: initial;
|
--tw-leading: initial;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user