Files
tehran_taj/apps/api/storage/gold_banking_backup.dump
T

1011 lines
97 KiB
Plaintext
Raw Normal View History

2026-09-19 12:05:59 +03:30
PGDMP3~ gold_banking16.1416.14×Ë00ENCODINGENCODINGSET client_encoding = 'UTF8';
falseÌ00
STDSTRINGS
STDSTRINGS(SET standard_conforming_strings = 'on';
falseÍ00
SEARCHPATH
SEARCHPATH8SELECT pg_catalog.set_config('search_path', '', false);
falseÎ126219392 gold_bankingDATABASE‡CREATE DATABASE gold_banking WITH TEMPLATE = template0 ENCODING = 'UTF8' LOCALE_PROVIDER = libc LOCALE = 'English_United States.1252';
DROP DATABASE gold_banking;
postgresfalsel124719394 AdminRoleTYPE–CREATE TYPE public."AdminRole" AS ENUM (
'SUPER_ADMIN',
'SYSTEM_APPROVER',
'SALES_EXPERT',
'WORKSHOP_SUPERVISOR',
'ACCOUNTANT'
);
DROP TYPE public."AdminRole";
publicpostgresfalseÆ124720184
CommentStatusTYPE^CREATE TYPE public."CommentStatus" AS ENUM (
'PENDING',
'APPROVED',
'REJECTED'
);
"DROP TYPE public."CommentStatus";
publicpostgresfalseó124720419 CustomerKindTYPEšCREATE TYPE public."CustomerKind" AS ENUM (
'SALES_AGENT',
'APP_SHOPKEEPER',
'WALK_IN_SHOPKEEPER',
'BANKER',
'WORKSHOP_SUPERVISOR'
);
!DROP TYPE public."CustomerKind";
publicpostgresfalsex124719448LedgerCurrencyTYPEMCREATE TYPE public."LedgerCurrency" AS ENUM (
'GOLD_GRAM',
'RIAL'
);
#DROP TYPE public."LedgerCurrency";
publicpostgresfalse{124719454LedgerDirectionTYPELCREATE TYPE public."LedgerDirection" AS ENUM (
'DEBIT',
'CREDIT'
);
$DROP TYPE public."LedgerDirection";
publicpostgresfalse~124719460LedgerSourceTypeTYPEçCREATE TYPE public."LedgerSourceType" AS ENUM (
'ORDER_STOCK',
'ORDER_PRE_ORDER',
'REPAYMENT_MELTED_GOLD',
'REPAYMENT_TRANSFER',
'REPAYMENT_CHEQUE',
'REPAYMENT_CASH',
'WALLET_BONUS',
'ADJUSTMENT'
);
%DROP TYPE public."LedgerSourceType";
publicpostgresfalseá124720333MessageAudienceTYPEºCREATE TYPE public."MessageAudience" AS ENUM (
'SINGLE_NUMBER',
'MULTIPLE_NUMBERS',
'ALL_CUSTOMERS',
'WHOLESALE_CUSTOMERS',
'RETAIL_CUSTOMERS',
'SALES_AGENTS'
);
$DROP TYPE public."MessageAudience";
publicpostgresfalseö124720428 OrderChannelTYPEMCREATE TYPE public."OrderChannel" AS ENUM (
'RETAIL',
'WHOLESALE'
);
!DROP TYPE public."OrderChannel";
publicpostgresfalser124719416 OrderStatusTYPEËCREATE TYPE public."OrderStatus" AS ENUM (
'SUSPENDED',
'PLACED',
'ADMIN_APPROVED',
'SOURCING',
'PREPARING',
'DELIVERED_TO_AGENT',
'DELIVERED_TO_CUSTOMER',
'CANCELLED'
);
DROP TYPE public."OrderStatus";
publicpostgresfalseu124719434PreOrderStatusTYPE¤CREATE TYPE public."PreOrderStatus" AS ENUM (
'PLACED',
'ADMIN_APPROVED',
'WORKSHOP_APPROVED',
'READY_TO_SHIP',
'DELIVERED',
'CANCELLED'
);
#DROP TYPE public."PreOrderStatus";
publicpostgresfalseÿ124721195ProductImageRoleTYPE~CREATE TYPE public."ProductImageRole" AS ENUM (
'FEATURED',
'FEATURED_MOBILE',
'GALLERY',
'GALLERY_MOBILE'
);
%DROP TYPE public."ProductImageRole";
publicpostgresfalseÏ124720231PromotionScopeTYPElCREATE TYPE public."PromotionScope" AS ENUM (
'PRODUCT',
'CATEGORY',
'CUSTOMER',
'BRAND'
);
#DROP TYPE public."PromotionScope";
publicpostgresfalseÒ124720240PromotionUsageTYPERCREATE TYPE public."PromotionUsage" AS ENUM (
'ONCE',
'UNTIL_END_DATE'
);
#DROP TYPE public."PromotionUsage";
publicpostgresfalseo124719406VerificationStepTYPEˆCREATE TYPE public."VerificationStep" AS ENUM (
'UNVERIFIED',
'STEP_ONE_SUBMITTED',
'STEP_TWO_SUBMITTED',
'VERIFIED'
);
%DROP TYPE public."VerificationStep";
publicpostgresfalseØ125919484 AdminUserTABLEŠCREATE TABLE public."AdminUser" (
id text NOT NULL,
"fullName" text NOT NULL,
mobile text NOT NULL,
"passwordHash" text NOT NULL,
role public."AdminRole" NOT NULL,
"branchId" text,
"wagePercent" numeric(6,3),
"isActive" boolean DEFAULT true NOT NULL,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
"userTypeId" integer
);
DROP TABLE public."AdminUser";
publicheappostgresfalse876Û125919514BranchTABLE²CREATE TABLE public."Branch" (
id text NOT NULL,
name text NOT NULL,
"cityId" text,
address text,
"isActive" boolean DEFAULT true NOT NULL,
phone text
);
DROP TABLE public."Branch";
publicheappostgresfalseò125920295BranchAllocationTABLEâCREATE TABLE public."BranchAllocation" (
id text NOT NULL,
"branchId" text NOT NULL,
"allocatorAdminUserId" text,
note text,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL
);
&DROP TABLE public."BranchAllocation";
publicheappostgresfalseó125920303BranchAllocationItemTABLE§CREATE TABLE public."BranchAllocationItem" (
id text NOT NULL,
"allocationId" text NOT NULL,
"productId" text NOT NULL,
"weightGrams" numeric(14,4)
);
*DROP TABLE public."BranchAllocationItem";
publicheappostgresfalseÞ125919536BrandTABLEOCREATE TABLE public."Brand" (
id text NOT NULL,
title text NOT NULL
);
DROP TABLE public."Brand";
publicheappostgresfalseÝ125919529CategoryTABLEßCREATE TABLE public."Category" (
id text NOT NULL,
title text NOT NULL,
"parentId" text,
description text,
"iconUrl" text,
"imageUrl" text,
"metaTag" text,
type integer DEFAULT 1 NOT NULL
);
DROP TABLE public."Category";
publicheappostgresfalse×125919477CityTABLE™CREATE TABLE public."City" (
id text NOT NULL,
name text NOT NULL,
province text,
percent numeric(6,3),
"percentAux" numeric(6,3)
);
DROP TABLE public."City";
publicheappostgresfalseß125919543
CollectionTABLE˜CREATE TABLE public."Collection" (
id text NOT NULL,
title text NOT NULL,
description text,
"isActive" boolean DEFAULT true NOT NULL
);
DROP TABLE public."Collection";
publicheappostgresfalseà125919551CollectionProductTABLEmCREATE TABLE public."CollectionProduct" (
"collectionId" text NOT NULL,
"productId" text NOT NULL
);
'DROP TABLE public."CollectionProduct";
publicheappostgresfalseî125920191CommentTABLE‡CREATE TABLE public."Comment" (
id text NOT NULL,
"productId" text NOT NULL,
"customerId" text NOT NULL,
body text NOT NULL,
status public."CommentStatus" DEFAULT 'PENDING'::public."CommentStatus" NOT NULL,
"replyToId" text,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
"updatedAt" timestamp(3) without time zone NOT NULL
);
DROP TABLE public."Comment";
publicheappostgresfalse966966Ù125919493CustomerTABLEVCREATE TABLE public."Customer" (
id text NOT NULL,
"fullName" text NOT NULL,
mobile text NOT NULL,
"nationalCode" text NOT NULL,
"passwordHash" text NOT NULL,
"cityId" text,
"referredByAgentId" text,
"goldCreditLimitGrams" numeric(14,4) DEFAULT 0 NOT NULL,
"goldDebtGrams" numeric(14,4) DEFAULT 0 NOT NULL,
"fiatDebtRial" numeric(20,2) DEFAULT 0 NOT NULL,
"verificationStep" public."VerificationStep" DEFAULT 'UNVERIFIED'::public."VerificationStep" NOT NULL,
"nationalIdImageUrl" text,
"businessLicenseUrl" text,
"shopImageUrl" text,
"isActive" boolean DEFAULT true NOT NULL,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
"updatedAt" timestamp(3) without time zone NOT NULL,
address text,
"canPlaceOrders" boolean DEFAULT true NOT NULL,
"isArchived" boolean DEFAULT false NOT NULL,
kind public."CustomerKind" DEFAULT 'APP_SHOPKEEPER'::public."CustomerKind" NOT NULL,
"memberCode" text,
"pasazhName" text,
phone text,
"storeName" text,
zone text,
"avatarFileId" text
);
DROP TABLE public."Customer";
publicheappostgresfalse87910118791011ø125920378CustomerActivityLogTABLEâCREATE TABLE public."CustomerActivityLog" (
id text NOT NULL,
"customerId" text NOT NULL,
action text NOT NULL,
detail text,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL
);
)DROP TABLE public."CustomerActivityLog";
publicheappostgresfalseÚ125919506CustomerAddressTABLEÄCREATE TABLE public."CustomerAddress" (
id text NOT NULL,
"customerId" text NOT NULL,
"cityId" text,
"addressLine" text NOT NULL,
"isDefault" boolean DEFAULT false NOT NULL
);
%DROP TABLE public."CustomerAddress";
publicheappostgresfalseê125919637GoldPriceQuoteTABLECREATE TABLE public."GoldPriceQuote" (
id text NOT NULL,
"karatPerMille" integer NOT NULL,
"pricePerGramRial" numeric(20,2) NOT NULL,
source text NOT NULL,
"quotedAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL
);
$DROP TABLE public."GoldPriceQuote";
publicheappostgresfalseé125919628 LedgerEntryTABLE2CREATE TABLE public."LedgerEntry" (
id text NOT NULL,
"customerId" text NOT NULL,
currency public."LedgerCurrency" NOT NULL,
direction public."LedgerDirection" NOT NULL,
"sourceType" public."LedgerSourceType" NOT NULL,
amount numeric(20,4) NOT NULL,
"karatPerMille" integer,
"pricePerGramRialAtEntry" numeric(20,2),
"orderId" text,
confirmed boolean DEFAULT false NOT NULL,
"confirmedAt" timestamp(3) without time zone,
"postedByAdminUserId" text,
note text,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
"accountName" text,
"bankName" text,
hallmark text,
"labName" text,
"originalValue" numeric(14,4),
"priceRial" numeric(20,2),
"receivedAt" timestamp(3) without time zone,
"transferTo" text
);
!DROP TABLE public."LedgerEntry";
publicheappostgresfalse891894888÷125920370NewsletterSubscriberTABLE¹CREATE TABLE public."NewsletterSubscriber" (
id text NOT NULL,
email text,
mobile text,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL
);
*DROP TABLE public."NewsletterSubscriber";
publicheappostgresfalseõ125920354 NotificationTABLEACREATE TABLE public."Notification" (
id text NOT NULL,
title text NOT NULL,
body text NOT NULL,
audience public."MessageAudience" DEFAULT 'ALL_CUSTOMERS'::public."MessageAudience" NOT NULL,
"sentByAdminUserId" text,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL
);
"DROP TABLE public."Notification";
publicheappostgresfalse993993ö125920363NotificationRecipientTABLE·CREATE TABLE public."NotificationRecipient" (
id text NOT NULL,
"notificationId" text NOT NULL,
"customerId" text NOT NULL,
"readAt" timestamp(3) without time zone
);
+DROP TABLE public."NotificationRecipient";
publicheappostgresfalseä125919583OrderTABLEÈCREATE TABLE public."Order" (
id text NOT NULL,
"orderNumber" text NOT NULL,
"customerId" text NOT NULL,
"branchId" text,
status public."OrderStatus" DEFAULT 'PLACED'::public."OrderStatus" NOT NULL,
"totalGoldWeightGrams" numeric(14,4) NOT NULL,
"wageWeightGrams" numeric(14,4) NOT NULL,
"flatRialCharge" numeric(20,2) DEFAULT 0 NOT NULL,
"isSuspendedOverCreditLimit" boolean DEFAULT false NOT NULL,
"deliveredAt" timestamp(3) without time zone,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
"updatedAt" timestamp(3) without time zone NOT NULL,
channel public."OrderChannel" DEFAULT 'RETAIL'::public."OrderChannel" NOT NULL
);
DROP TABLE public."Order";
publicheappostgresfalse88210141014882å125919594 OrderItemTABLE«CREATE TABLE public."OrderItem" (
id text NOT NULL,
"orderId" text NOT NULL,
"productVariantId" text NOT NULL,
quantity integer NOT NULL,
"rashWeightGramsSnapshot" numeric(14,4) NOT NULL,
"wagePercentSnapshot" numeric(6,3) NOT NULL,
"discountPercentSnapshot" numeric(6,3) DEFAULT 0 NOT NULL,
"computedWeightGrams" numeric(14,4) NOT NULL,
"flatRialCharge" numeric(20,2) DEFAULT 0 NOT NULL
);
DROP TABLE public."OrderItem";
publicheappostgresfalseæ125919603OrderStatusEventTABLE2CREATE TABLE public."OrderStatusEvent" (
id text NOT NULL,
"orderId" text NOT NULL,
"fromStatus" public."OrderStatus",
"toStatus" public."OrderStatus" NOT NULL,
note text,
"actorAdminUserId" text,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL
);
&DROP TABLE public."OrderStatusEvent";
publicheappostgresfalse882882ç125919611PreOrderTABLE^CREATE TABLE public."PreOrder" (
id text NOT NULL,
"customerId" text NOT NULL,
"cityId" text,
"workshopId" text,
status public."PreOrderStatus" DEFAULT 'PLACED'::public."PreOrderStatus" NOT NULL,
"designImageUrl" text,
"colorName" text,
"sizeSpec" text,
"stoneColor" text,
"minaColor" text,
"estimatedWeightGrams" numeric(14,4),
"estimatedPriceRial" numeric(20,2),
description text,
"convertedOrderId" text,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
"updatedAt" timestamp(3) without time zone NOT NULL
);
DROP TABLE public."PreOrder";
publicheappostgresfalse885885è125919620PreOrderStatusEventTABLECREATE TABLE public."PreOrderStatusEvent" (
id text NOT NULL,
"preOrderId" text NOT NULL,
changes jsonb NOT NULL,
"actorAdminUserId" text,
"ipAddress" text,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL
);
)DROP TABLE public."PreOrderStatusEvent";
publicheappostgresfalseá125919558ProductTABLEVCREATE TABLE public."Product" (
id text NOT NULL,
title text NOT NULL,
description text,
"categoryId" text,
"brandId" text,
"isActive" boolean DEFAULT true NOT NULL,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
"productCode" text,
"showType" integer DEFAULT 3 NOT NULL
);
DROP TABLE public."Product";
publicheappostgresfalseâ125919567 ProductImageTABLEùCREATE TABLE public."ProductImage" (
id text NOT NULL,
"productId" text NOT NULL,
url text NOT NULL,
"sortOrder" integer DEFAULT 0 NOT NULL,
role public."ProductImageRole" DEFAULT 'GALLERY'::public."ProductImageRole" NOT NULL
);
"DROP TABLE public."ProductImage";
publicheappostgresfalse10231023ã125919575ProductVariantTABLEfCREATE TABLE public."ProductVariant" (
id text NOT NULL,
"productId" text NOT NULL,
title text NOT NULL,
sku text,
"rashWeightGrams" numeric(14,4) NOT NULL,
"defaultWagePercent" numeric(6,3) NOT NULL,
"isActive" boolean DEFAULT true NOT NULL,
"isPreOrder" boolean DEFAULT false NOT NULL,
qty integer DEFAULT 0 NOT NULL
);
$DROP TABLE public."ProductVariant";
publicheappostgresfalseð125920245 PromotionTABLEØCREATE TABLE public."Promotion" (
id text NOT NULL,
title text NOT NULL,
description text,
scope public."PromotionScope" DEFAULT 'PRODUCT'::public."PromotionScope" NOT NULL,
usage public."PromotionUsage" DEFAULT 'ONCE'::public."PromotionUsage" NOT NULL,
"discountPercent" numeric(6,3) NOT NULL,
"isActive" boolean DEFAULT true NOT NULL,
platform integer DEFAULT 3 NOT NULL,
"startsAt" timestamp(3) without time zone,
"endsAt" timestamp(3) without time zone,
"productId" text,
"categoryId" text,
"customerId" text,
"brandId" text,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
"updatedAt" timestamp(3) without time zone NOT NULL
);
DROP TABLE public."Promotion";
publicheappostgresfalse975978978975ñ125920257PromotionExclusionTABLEÍCREATE TABLE public."PromotionExclusion" (
id text NOT NULL,
type integer NOT NULL,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
"itemId" text NOT NULL
);
(DROP TABLE public."PromotionExclusion";
publicheappostgresfalseï125920223SettingTABLEŒCREATE TABLE public."Setting" (
key text NOT NULL,
value jsonb NOT NULL,
"updatedAt" timestamp(3) without time zone NOT NULL
);
DROP TABLE public."Setting";
publicheappostgresfalseô125920345
SmsMessageTABLE5CREATE TABLE public."SmsMessage" (
id text NOT NULL,
audience public."MessageAudience" NOT NULL,
recipients text,
body text NOT NULL,
"sentCount" integer DEFAULT 0 NOT NULL,
"sentByAdminUserId" text,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL
);
DROP TABLE public."SmsMessage";
publicheappostgresfalse993ù125920437 UploadedFileTABLE=CREATE TABLE public."UploadedFile" (
id text NOT NULL,
url text NOT NULL,
"originalName" text NOT NULL,
"mimeType" text NOT NULL,
"sizeBytes" integer NOT NULL,
purpose text,
"uploadedByAdminUserId" text,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL
);
"DROP TABLE public."UploadedFile";
publicheappostgresfalseë125919645 WalletBonusTABLEƒCREATE TABLE public."WalletBonus" (
id text NOT NULL,
"customerId" text NOT NULL,
"orderId" text,
"goldGrams" numeric(14,4) NOT NULL,
"grantedAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL,
"expiresAt" timestamp(3) without time zone NOT NULL,
"consumedAt" timestamp(3) without time zone,
"isActive" boolean DEFAULT true NOT NULL
);
!DROP TABLE public."WalletBonus";
publicheappostgresfalseÜ125919521WorkshopTABLEºCREATE TABLE public."Workshop" (
id text NOT NULL,
name text NOT NULL,
"isActive" boolean DEFAULT true NOT NULL,
address text,
phone text,
"supervisorId" text
);
DROP TABLE public."Workshop";
publicheappostgresfalseú125920458_goldbank_migrationsTABLE…CREATE TABLE public._goldbank_migrations (
name text NOT NULL,
applied_at timestamp with time zone DEFAULT now() NOT NULL
);
(DROP TABLE public._goldbank_migrations;
publicheappostgresfalseû125921204_prisma_migrationsTABLE�CREATE TABLE public._prisma_migrations (
id character varying(36) NOT NULL,
checksum character varying(64) NOT NULL,
finished_at timestamp with time zone,
migration_name character varying(255) NOT NULL,
logs text,
rolled_back_at timestamp with time zone,
started_at timestamp with time zone DEFAULT now() NOT NULL,
applied_steps_count integer DEFAULT 0 NOT NULL
);
&DROP TABLE public._prisma_migrations;
publicheappostgresfalseí125920164
permissionTABLE]CREATE TABLE public.permission (
rid text NOT NULL,
"userTypeId" integer NOT NULL
);
DROP TABLE public.permission;
publicheappostgresfalseì125920155 user_typeTABLEÕCREATE TABLE public.user_type (
id integer NOT NULL,
title text NOT NULL,
"isActive" boolean DEFAULT true NOT NULL,
"createdAt" timestamp(3) without time zone DEFAULT CURRENT_TIMESTAMP NOT NULL
);
DROP TABLE public.user_type;
publicheappostgresfalse¥019484 AdminUser
TABLE DATA•COPY public."AdminUser" (id, "fullName", mobile, "passwordHash", role, "branchId", "wagePercent", "isActive", "createdAt", "userTypeId") FROM stdin;
publicpostgresfalse216Ú:¨019514Branch
TABLE DATARCOPY public."Branch" (id, name, "cityId", address, "isActive", phone) FROM stdin;
publicpostgresfalse219=¿020295BranchAllocation
TABLE DATAgCOPY public."BranchAllocation" (id, "branchId", "allocatorAdminUserId", note, "createdAt") FROM stdin;
publicpostgresfalse242©=À020303BranchAllocationItem
TABLE DATA`COPY public."BranchAllocationItem" (id, "allocationId", "productId", "weightGrams") FROM stdin;
publicpostgresfalse243Æ=«019536Brand
TABLE DATA,COPY public."Brand" (id, title) FROM stdin;
publicpostgresfalse222ã=ª019529Category
TABLE DATApCOPY public."Category" (id, title, "parentId", description, "iconUrl", "imageUrl", "metaTag", type) FROM stdin;
publicpostgresfalse221C>¤019477City
TABLE DATAKCOPY public."City" (id, name, province, percent, "percentAux") FROM stdin;
publicpostgresfalse215æ>¬019543
Collection
TABLE DATAJCOPY public."Collection" (id, title, description, "isActive") FROM stdin;
publicpostgresfalse223†?­019551CollectionProduct
TABLE DATAJCOPY public."CollectionProduct" ("collectionId", "productId") FROM stdin;
publicpostgresfalse224@»020191Comment
TABLE DATAwCOPY public."Comment" (id, "productId", "customerId", body, status, "replyToId", "createdAt", "updatedAt") FROM stdin;
publicpostgresfalse238n@¦019493Customer
TABLE DATAŸCOPY public."Customer" (id, "fullName", mobile, "nationalCode", "passwordHash", "cityId", "referredByAgentId", "goldCreditLimitGrams", "goldDebtGrams", "fiatDebtRial", "verificationStep", "nationalIdImageUrl", "businessLicenseUrl", "shopImageUrl", "isActive", "createdAt", "updatedAt", address, "canPlaceOrders", "isArchived", kind, "memberCode", "pasazhName", phone, "storeName", zone, "avatarFileId") FROM stdin;
publicpostgresfalse217ÉAÅ020378CustomerActivityLog
TABLE DATA^COPY public."CustomerActivityLog" (id, "customerId", action, detail, "createdAt") FROM stdin;
publicpostgresfalse248ùD§019506CustomerAddress
TABLE DATAcCOPY public."CustomerAddress" (id, "customerId", "cityId", "addressLine", "isDefault") FROM stdin;
publicpostgresfalse218E·019637GoldPriceQuote
TABLE DATAgCOPY public."GoldPriceQuote" (id, "karatPerMille", "pricePerGramRial", source, "quotedAt") FROM stdin;
publicpostgresfalse2343E019628 LedgerEntry
TABLE DATAICOPY public."LedgerEntry" (id, "customerId", currency, direction, "sourceType", amount, "karatPerMille", "pricePerGramRialAtEntry", "orderId", confirmed, "confirmedAt", "postedByAdminUserId", note, "createdAt", "accountName", "bankName", hallmark, "labName", "originalValue", "priceRial", "receivedAt", "transferTo") FROM stdin;
publicpostgresfalse233 GÄ020370NewsletterSubscriber
TABLE DATAPCOPY public."NewsletterSubscriber" (id, email, mobile, "createdAt") FROM stdin;
publicpostgresfalse2476IÂ020354 Notification
TABLE DATAeCOPY public."Notification" (id, title, body, audience, "sentByAdminUserId", "createdAt") FROM stdin;
publicpostgresfalse245SIÃ020363NotificationRecipient
TABLE DATA_COPY public."NotificationRecipient" (id, "notificationId", "customerId", "readAt") FROM stdin;
publicpostgresfalse246pI±019583Order
TABLE DATAãCOPY public."Order" (id, "orderNumber", "customerId", "branchId", status, "totalGoldWeightGrams", "wageWeightGrams", "flatRialCharge", "isSuspendedOverCreditLimit", "deliveredAt", "createdAt", "updatedAt", channel) FROM stdin;
publicpostgresfalse228�I²019594 OrderItem
TABLE DATAÈCOPY public."OrderItem" (id, "orderId", "productVariantId", quantity, "rashWeightGramsSnapshot", "wagePercentSnapshot", "discountPercentSnapshot", "computedWeightGrams", "flatRialCharge") FROM stdin;
publicpostgresfalse229WK³019603OrderStatusEvent
TABLE DATA|COPY public."OrderStatusEvent" (id, "orderId", "fromStatus", "toStatus", note, "actorAdminUserId", "createdAt") FROM stdin;
publicpostgresfalse230nL´019611PreOrder
TABLE DATACOPY public."PreOrder" (id, "customerId", "cityId", "workshopId", status, "designImageUrl", "colorName", "sizeSpec", "stoneColor", "minaColor", "estimatedWeightGrams", "estimatedPriceRial", description, "convertedOrderId", "createdAt", "updatedAt") FROM stdin;
publicpostgresfalse231§Nµ019620PreOrderStatusEvent
TABLE DATAxCOPY public."PreOrderStatusEvent" (id, "preOrderId", changes, "actorAdminUserId", "ipAddress", "createdAt") FROM stdin;
publicpostgresfalse232¼O®019558Product
TABLE DATAˆCOPY public."Product" (id, title, description, "categoryId", "brandId", "isActive", "createdAt", "productCode", "showType") FROM stdin;
publicpostgresfalse225ÙO¯019567 ProductImage
TABLE DATAQCOPY public."ProductImage" (id, "productId", url, "sortOrder", role) FROM stdin;
publicpostgresfalse226Þ^°019575ProductVariant
TABLE DATA�COPY public."ProductVariant" (id, "productId", title, sku, "rashWeightGrams", "defaultWagePercent", "isActive", "isPreOrder", qty) FROM stdin;
publicpostgresfalse227ãf½020245 Promotion
TABLE DATAØCOPY public."Promotion" (id, title, description, scope, usage, "discountPercent", "isActive", platform, "startsAt", "endsAt", "productId", "categoryId", "customerId", "brandId", "createdAt", "updatedAt") FROM stdin;
publicpostgresfalse240�u¾020257PromotionExclusion
TABLE DATAOCOPY public."PromotionExclusion" (id, type, "createdAt", "itemId") FROM stdin;
publicpostgresfalse241ªu¼020223Setting
TABLE DATA<COPY public."Setting" (key, value, "updatedAt") FROM stdin;
publicpostgresfalse239ÇuÁ020345
SmsMessage
TABLE DATAuCOPY public."SmsMessage" (id, audience, recipients, body, "sentCount", "sentByAdminUserId", "createdAt") FROM stdin;
publicpostgresfalse244%vÆ020437 UploadedFile
TABLE DATA‰COPY public."UploadedFile" (id, url, "originalName", "mimeType", "sizeBytes", purpose, "uploadedByAdminUserId", "createdAt") FROM stdin;
publicpostgresfalse249Bv¸019645 WalletBonus
TABLE DATA…COPY public."WalletBonus" (id, "customerId", "orderId", "goldGrams", "grantedAt", "expiresAt", "consumedAt", "isActive") FROM stdin;
publicpostgresfalse235¤{©019521Workshop
TABLE DATAZCOPY public."Workshop" (id, name, "isActive", address, phone, "supervisorId") FROM stdin;
publicpostgresfalse220Á{Ç020458_goldbank_migrations
TABLE DATA@COPY public._goldbank_migrations (name, applied_at) FROM stdin;
publicpostgresfalse250|È021204_prisma_migrations
TABLE DATAŽCOPY public._prisma_migrations (id, checksum, finished_at, migration_name, logs, rolled_back_at, started_at, applied_steps_count) FROM stdin;
publicpostgresfalse2519}º020164
permission
TABLE DATA7COPY public.permission (rid, "userTypeId") FROM stdin;
publicpostgresfalse237¹020155 user_type
TABLE DATAGCOPY public.user_type (id, title, "isActive", "createdAt") FROM stdin;
publicpostgresfalse236ñ‚y260619492AdminUser AdminUser_pkey
CONSTRAINTZALTER TABLE ONLY public."AdminUser"
ADD CONSTRAINT "AdminUser_pkey" PRIMARY KEY (id);
FALTER TABLE ONLY public."AdminUser" DROP CONSTRAINT "AdminUser_pkey";
publicpostgresfalse216Ê260620309.BranchAllocationItem BranchAllocationItem_pkey
CONSTRAINTpALTER TABLE ONLY public."BranchAllocationItem"
ADD CONSTRAINT "BranchAllocationItem_pkey" PRIMARY KEY (id);
\ALTER TABLE ONLY public."BranchAllocationItem" DROP CONSTRAINT "BranchAllocationItem_pkey";
publicpostgresfalse243Ç260620302&BranchAllocation BranchAllocation_pkey
CONSTRAINThALTER TABLE ONLY public."BranchAllocation"
ADD CONSTRAINT "BranchAllocation_pkey" PRIMARY KEY (id);
TALTER TABLE ONLY public."BranchAllocation" DROP CONSTRAINT "BranchAllocation_pkey";
publicpostgresfalse242„260619520Branch Branch_pkey
CONSTRAINTTALTER TABLE ONLY public."Branch"
ADD CONSTRAINT "Branch_pkey" PRIMARY KEY (id);
@ALTER TABLE ONLY public."Branch" DROP CONSTRAINT "Branch_pkey";
publicpostgresfalse219Š260619542Brand Brand_pkey
CONSTRAINTRALTER TABLE ONLY public."Brand"
ADD CONSTRAINT "Brand_pkey" PRIMARY KEY (id);
>ALTER TABLE ONLY public."Brand" DROP CONSTRAINT "Brand_pkey";
publicpostgresfalse222ˆ260619535Category Category_pkey
CONSTRAINTXALTER TABLE ONLY public."Category"
ADD CONSTRAINT "Category_pkey" PRIMARY KEY (id);
DALTER TABLE ONLY public."Category" DROP CONSTRAINT "Category_pkey";
publicpostgresfalse221v260619483City City_pkey
CONSTRAINTPALTER TABLE ONLY public."City"
ADD CONSTRAINT "City_pkey" PRIMARY KEY (id);
<ALTER TABLE ONLY public."City" DROP CONSTRAINT "City_pkey";
publicpostgresfalse215Ž260619557(CollectionProduct CollectionProduct_pkey
CONSTRAINTƒALTER TABLE ONLY public."CollectionProduct"
ADD CONSTRAINT "CollectionProduct_pkey" PRIMARY KEY ("collectionId", "productId");
VALTER TABLE ONLY public."CollectionProduct" DROP CONSTRAINT "CollectionProduct_pkey";
publicpostgresfalse224224Œ260619550Collection Collection_pkey
CONSTRAINT\ALTER TABLE ONLY public."Collection"
ADD CONSTRAINT "Collection_pkey" PRIMARY KEY (id);
HALTER TABLE ONLY public."Collection" DROP CONSTRAINT "Collection_pkey";
publicpostgresfalse223¹260620199Comment Comment_pkey
CONSTRAINTVALTER TABLE ONLY public."Comment"
ADD CONSTRAINT "Comment_pkey" PRIMARY KEY (id);
BALTER TABLE ONLY public."Comment" DROP CONSTRAINT "Comment_pkey";
publicpostgresfalse238Û260620385,CustomerActivityLog CustomerActivityLog_pkey
CONSTRAINTnALTER TABLE ONLY public."CustomerActivityLog"
ADD CONSTRAINT "CustomerActivityLog_pkey" PRIMARY KEY (id);
ZALTER TABLE ONLY public."CustomerActivityLog" DROP CONSTRAINT "CustomerActivityLog_pkey";
publicpostgresfalse248‚260619513$CustomerAddress CustomerAddress_pkey
CONSTRAINTfALTER TABLE ONLY public."CustomerAddress"
ADD CONSTRAINT "CustomerAddress_pkey" PRIMARY KEY (id);
RALTER TABLE ONLY public."CustomerAddress" DROP CONSTRAINT "CustomerAddress_pkey";
publicpostgresfalse218260619505Customer Customer_pkey
CONSTRAINTXALTER TABLE ONLY public."Customer"
ADD CONSTRAINT "Customer_pkey" PRIMARY KEY (id);
DALTER TABLE ONLY public."Customer" DROP CONSTRAINT "Customer_pkey";
publicpostgresfalse217®260619644"GoldPriceQuote GoldPriceQuote_pkey
CONSTRAINTdALTER TABLE ONLY public."GoldPriceQuote"
ADD CONSTRAINT "GoldPriceQuote_pkey" PRIMARY KEY (id);
PALTER TABLE ONLY public."GoldPriceQuote" DROP CONSTRAINT "GoldPriceQuote_pkey";
publicpostgresfalse234«260619636LedgerEntry LedgerEntry_pkey
CONSTRAINT^ALTER TABLE ONLY public."LedgerEntry"
ADD CONSTRAINT "LedgerEntry_pkey" PRIMARY KEY (id);
JALTER TABLE ONLY public."LedgerEntry" DROP CONSTRAINT "LedgerEntry_pkey";
publicpostgresfalse233Ø260620377.NewsletterSubscriber NewsletterSubscriber_pkey
CONSTRAINTpALTER TABLE ONLY public."NewsletterSubscriber"
ADD CONSTRAINT "NewsletterSubscriber_pkey" PRIMARY KEY (id);
\ALTER TABLE ONLY public."NewsletterSubscriber" DROP CONSTRAINT "NewsletterSubscriber_pkey";
publicpostgresfalse247Ô2606203690NotificationRecipient NotificationRecipient_pkey
CONSTRAINTrALTER TABLE ONLY public."NotificationRecipient"
ADD CONSTRAINT "NotificationRecipient_pkey" PRIMARY KEY (id);
^ALTER TABLE ONLY public."NotificationRecipient" DROP CONSTRAINT "NotificationRecipient_pkey";
publicpostgresfalse246Ð260620362Notification Notification_pkey
CONSTRAINT`ALTER TABLE ONLY public."Notification"
ADD CONSTRAINT "Notification_pkey" PRIMARY KEY (id);
LALTER TABLE ONLY public."Notification" DROP CONSTRAINT "Notification_pkey";
publicpostgresfalse245�260619602OrderItem OrderItem_pkey
CONSTRAINTZALTER TABLE ONLY public."OrderItem"
ADD CONSTRAINT "OrderItem_pkey" PRIMARY KEY (id);
FALTER TABLE ONLY public."OrderItem" DROP CONSTRAINT "OrderItem_pkey";
publicpostgresfalse229 260619610&OrderStatusEvent OrderStatusEvent_pkey
CONSTRAINThALTER TABLE ONLY public."OrderStatusEvent"
ADD CONSTRAINT "OrderStatusEvent_pkey" PRIMARY KEY (id);
TALTER TABLE ONLY public."OrderStatusEvent" DROP CONSTRAINT "OrderStatusEvent_pkey";
publicpostgresfalse230š260619593Order Order_pkey
CONSTRAINTRALTER TABLE ONLY public."Order"
ADD CONSTRAINT "Order_pkey" PRIMARY KEY (id);
>ALTER TABLE ONLY public."Order" DROP CONSTRAINT "Order_pkey";
publicpostgresfalse228¦260619627,PreOrderStatusEvent PreOrderStatusEvent_pkey
CONSTRAINTnALTER TABLE ONLY public."PreOrderStatusEvent"
ADD CONSTRAINT "PreOrderStatusEvent_pkey" PRIMARY KEY (id);
ZALTER TABLE ONLY public."PreOrderStatusEvent" DROP CONSTRAINT "PreOrderStatusEvent_pkey";
publicpostgresfalse232¤260619619PreOrder PreOrder_pkey
CONSTRAINTXALTER TABLE ONLY public."PreOrder"
ADD CONSTRAINT "PreOrder_pkey" PRIMARY KEY (id);
DALTER TABLE ONLY public."PreOrder" DROP CONSTRAINT "PreOrder_pkey";
publicpostgresfalse231“260619574ProductImage ProductImage_pkey
CONSTRAINT`ALTER TABLE ONLY public."ProductImage"
ADD CONSTRAINT "ProductImage_pkey" PRIMARY KEY (id);
LALTER TABLE ONLY public."ProductImage" DROP CONSTRAINT "ProductImage_pkey";
publicpostgresfalse226•260619582"ProductVariant ProductVariant_pkey
CONSTRAINTdALTER TABLE ONLY public."ProductVariant"
ADD CONSTRAINT "ProductVariant_pkey" PRIMARY KEY (id);
PALTER TABLE ONLY public."ProductVariant" DROP CONSTRAINT "ProductVariant_pkey";
publicpostgresfalse227�260619566Product Product_pkey
CONSTRAINTVALTER TABLE ONLY public."Product"
ADD CONSTRAINT "Product_pkey" PRIMARY KEY (id);
BALTER TABLE ONLY public."Product" DROP CONSTRAINT "Product_pkey";
publicpostgresfalse225Â260620264*PromotionExclusion PromotionExclusion_pkey
CONSTRAINTlALTER TABLE ONLY public."PromotionExclusion"
ADD CONSTRAINT "PromotionExclusion_pkey" PRIMARY KEY (id);
XALTER TABLE ONLY public."PromotionExclusion" DROP CONSTRAINT "PromotionExclusion_pkey";
publicpostgresfalse241¿260620256Promotion Promotion_pkey
CONSTRAINTZALTER TABLE ONLY public."Promotion"
ADD CONSTRAINT "Promotion_pkey" PRIMARY KEY (id);
FALTER TABLE ONLY public."Promotion" DROP CONSTRAINT "Promotion_pkey";
publicpostgresfalse240½260620229Setting Setting_pkey
CONSTRAINTWALTER TABLE ONLY public."Setting"
ADD CONSTRAINT "Setting_pkey" PRIMARY KEY (key);
BALTER TABLE ONLY public."Setting" DROP CONSTRAINT "Setting_pkey";
publicpostgresfalse239Í260620353SmsMessage SmsMessage_pkey
CONSTRAINT\ALTER TABLE ONLY public."SmsMessage"
ADD CONSTRAINT "SmsMessage_pkey" PRIMARY KEY (id);
HALTER TABLE ONLY public."SmsMessage" DROP CONSTRAINT "SmsMessage_pkey";
publicpostgresfalse244Ý260620444UploadedFile UploadedFile_pkey
CONSTRAINT`ALTER TABLE ONLY public."UploadedFile"
ADD CONSTRAINT "UploadedFile_pkey" PRIMARY KEY (id);
LALTER TABLE ONLY public."UploadedFile" DROP CONSTRAINT "UploadedFile_pkey";
publicpostgresfalse249±260619653WalletBonus WalletBonus_pkey
CONSTRAINT^ALTER TABLE ONLY public."WalletBonus"
ADD CONSTRAINT "WalletBonus_pkey" PRIMARY KEY (id);
JALTER TABLE ONLY public."WalletBonus" DROP CONSTRAINT "WalletBonus_pkey";
publicpostgresfalse235†260619528Workshop Workshop_pkey
CONSTRAINTXALTER TABLE ONLY public."Workshop"
ADD CONSTRAINT "Workshop_pkey" PRIMARY KEY (id);
DALTER TABLE ONLY public."Workshop" DROP CONSTRAINT "Workshop_pkey";
publicpostgresfalse220à260620465._goldbank_migrations _goldbank_migrations_pkey
CONSTRAINTnALTER TABLE ONLY public._goldbank_migrations
ADD CONSTRAINT _goldbank_migrations_pkey PRIMARY KEY (name);
XALTER TABLE ONLY public._goldbank_migrations DROP CONSTRAINT _goldbank_migrations_pkey;
publicpostgresfalse250â260621212*_prisma_migrations _prisma_migrations_pkey
CONSTRAINThALTER TABLE ONLY public._prisma_migrations
ADD CONSTRAINT _prisma_migrations_pkey PRIMARY KEY (id);
TALTER TABLE ONLY public._prisma_migrations DROP CONSTRAINT _prisma_migrations_pkey;
publicpostgresfalse251µ260620170permission permission_pkey
CONSTRAINTgALTER TABLE ONLY public.permission
ADD CONSTRAINT permission_pkey PRIMARY KEY (rid, "userTypeId");
DALTER TABLE ONLY public.permission DROP CONSTRAINT permission_pkey;
publicpostgresfalse237237³260620163user_type user_type_pkey
CONSTRAINTVALTER TABLE ONLY public.user_type
ADD CONSTRAINT user_type_pkey PRIMARY KEY (id);
BALTER TABLE ONLY public.user_type DROP CONSTRAINT user_type_pkey;
publicpostgresfalse236w125919654AdminUser_mobile_keyINDEXWCREATE UNIQUE INDEX "AdminUser_mobile_key" ON public."AdminUser" USING btree (mobile);
*DROP INDEX public."AdminUser_mobile_key";
publicpostgresfalse216z125919655AdminUser_role_idxINDEXLCREATE INDEX "AdminUser_role_idx" ON public."AdminUser" USING btree (role);
(DROP INDEX public."AdminUser_role_idx";
publicpostgresfalse216{125920172AdminUser_userTypeId_idxINDEXZCREATE INDEX "AdminUser_userTypeId_idx" ON public."AdminUser" USING btree ("userTypeId");
.DROP INDEX public."AdminUser_userTypeId_idx";
publicpostgresfalse216È125920311/BranchAllocationItem_allocationId_productId_keyINDEX’CREATE UNIQUE INDEX "BranchAllocationItem_allocationId_productId_key" ON public."BranchAllocationItem" USING btree ("allocationId", "productId");
EDROP INDEX public."BranchAllocationItem_allocationId_productId_key";
publicpostgresfalse243243Å125920310BranchAllocation_branchId_idxINDEXdCREATE INDEX "BranchAllocation_branchId_idx" ON public."BranchAllocation" USING btree ("branchId");
3DROP INDEX public."BranchAllocation_branchId_idx";
publicpostgresfalse242·125920201Comment_customerId_idxINDEXVCREATE INDEX "Comment_customerId_idx" ON public."Comment" USING btree ("customerId");
,DROP INDEX public."Comment_customerId_idx";
publicpostgresfalse238º125920200Comment_productId_idxINDEXTCREATE INDEX "Comment_productId_idx" ON public."Comment" USING btree ("productId");
+DROP INDEX public."Comment_productId_idx";
publicpostgresfalse238»125920202Comment_status_idxINDEXLCREATE INDEX "Comment_status_idx" ON public."Comment" USING btree (status);
(DROP INDEX public."Comment_status_idx";
publicpostgresfalse238Ù125920392,CustomerActivityLog_customerId_createdAt_idxINDEX…CREATE INDEX "CustomerActivityLog_customerId_createdAt_idx" ON public."CustomerActivityLog" USING btree ("customerId", "createdAt");
BDROP INDEX public."CustomerActivityLog_customerId_createdAt_idx";
publicpostgresfalse248248|125919656Customer_mobile_keyINDEXUCREATE UNIQUE INDEX "Customer_mobile_key" ON public."Customer" USING btree (mobile);
)DROP INDEX public."Customer_mobile_key";
publicpostgresfalse217}125919657Customer_nationalCode_keyINDEXcCREATE UNIQUE INDEX "Customer_nationalCode_key" ON public."Customer" USING btree ("nationalCode");
/DROP INDEX public."Customer_nationalCode_key";
publicpostgresfalse217€125919658Customer_referredByAgentId_idxINDEXfCREATE INDEX "Customer_referredByAgentId_idx" ON public."Customer" USING btree ("referredByAgentId");
4DROP INDEX public."Customer_referredByAgentId_idx";
publicpostgresfalse217¬125919669)GoldPriceQuote_karatPerMille_quotedAt_idxINDEXCREATE INDEX "GoldPriceQuote_karatPerMille_quotedAt_idx" ON public."GoldPriceQuote" USING btree ("karatPerMille", "quotedAt");
?DROP INDEX public."GoldPriceQuote_karatPerMille_quotedAt_idx";
publicpostgresfalse234234¨125919667#LedgerEntry_customerId_currency_idxINDEXqCREATE INDEX "LedgerEntry_customerId_currency_idx" ON public."LedgerEntry" USING btree ("customerId", currency);
9DROP INDEX public."LedgerEntry_customerId_currency_idx";
publicpostgresfalse233233©125919668LedgerEntry_orderId_idxINDEXXCREATE INDEX "LedgerEntry_orderId_idx" ON public."LedgerEntry" USING btree ("orderId");
-DROP INDEX public."LedgerEntry_orderId_idx";
publicpostgresfalse233Õ125920390NewsletterSubscriber_email_keyINDEXkCREATE UNIQUE INDEX "NewsletterSubscriber_email_key" ON public."NewsletterSubscriber" USING btree (email);
4DROP INDEX public."NewsletterSubscriber_email_key";
publicpostgresfalse247Ö125920391NewsletterSubscriber_mobile_keyINDEXmCREATE UNIQUE INDEX "NewsletterSubscriber_mobile_key" ON public."NewsletterSubscriber" USING btree (mobile);
5DROP INDEX public."NewsletterSubscriber_mobile_key";
publicpostgresfalse247Ñ125920388+NotificationRecipient_customerId_readAt_idxINDEXƒCREATE INDEX "NotificationRecipient_customerId_readAt_idx" ON public."NotificationRecipient" USING btree ("customerId", "readAt");
ADROP INDEX public."NotificationRecipient_customerId_readAt_idx";
publicpostgresfalse246246Ò1259203893NotificationRecipient_notificationId_customerId_keyINDEXšCREATE UNIQUE INDEX "NotificationRecipient_notificationId_customerId_key" ON public."NotificationRecipient" USING btree ("notificationId", "customerId");
IDROP INDEX public."NotificationRecipient_notificationId_customerId_key";
publicpostgresfalse246246Î125920387Notification_createdAt_idxINDEX^CREATE INDEX "Notification_createdAt_idx" ON public."Notification" USING btree ("createdAt");
0DROP INDEX public."Notification_createdAt_idx";
publicpostgresfalse245ž125919663OrderStatusEvent_orderId_idxINDEXbCREATE INDEX "OrderStatusEvent_orderId_idx" ON public."OrderStatusEvent" USING btree ("orderId");
2DROP INDEX public."OrderStatusEvent_orderId_idx";
publicpostgresfalse230—125919661Order_customerId_idxINDEXRCREATE INDEX "Order_customerId_idx" ON public."Order" USING btree ("customerId");
*DROP INDEX public."Order_customerId_idx";
publicpostgresfalse228˜125919660Order_orderNumber_keyINDEX[CREATE UNIQUE INDEX "Order_orderNumber_key" ON public."Order" USING btree ("orderNumber");
+DROP INDEX public."Order_orderNumber_key";
publicpostgresfalse228›125919662Order_status_idxINDEXHCREATE INDEX "Order_status_idx" ON public."Order" USING btree (status);
&DROP INDEX public."Order_status_idx";
publicpostgresfalse228§125919666"PreOrderStatusEvent_preOrderId_idxINDEXnCREATE INDEX "PreOrderStatusEvent_preOrderId_idx" ON public."PreOrderStatusEvent" USING btree ("preOrderId");
8DROP INDEX public."PreOrderStatusEvent_preOrderId_idx";
publicpostgresfalse232¡125919664PreOrder_convertedOrderId_keyINDEXkCREATE UNIQUE INDEX "PreOrder_convertedOrderId_key" ON public."PreOrder" USING btree ("convertedOrderId");
3DROP INDEX public."PreOrder_convertedOrderId_key";
publicpostgresfalse231¢125919665PreOrder_customerId_idxINDEXXCREATE INDEX "PreOrder_customerId_idx" ON public."PreOrder" USING btree ("customerId");
-DROP INDEX public."PreOrder_customerId_idx";
publicpostgresfalse231–125919659ProductVariant_sku_keyINDEX[CREATE UNIQUE INDEX "ProductVariant_sku_key" ON public."ProductVariant" USING btree (sku);
,DROP INDEX public."ProductVariant_sku_key";
publicpostgresfalse227‘125920221Product_productCode_keyINDEX_CREATE UNIQUE INDEX "Product_productCode_key" ON public."Product" USING btree ("productCode");
-DROP INDEX public."Product_productCode_key";
publicpostgresfalse225Ã125920287PromotionExclusion_type_idxINDEX^CREATE INDEX "PromotionExclusion_type_idx" ON public."PromotionExclusion" USING btree (type);
1DROP INDEX public."PromotionExclusion_type_idx";
publicpostgresfalse241Ä125920288"PromotionExclusion_type_itemId_keyINDEXvCREATE UNIQUE INDEX "PromotionExclusion_type_itemId_key" ON public."PromotionExclusion" USING btree (type, "itemId");
8DROP INDEX public."PromotionExclusion_type_itemId_key";
publicpostgresfalse241241À125920265Promotion_scope_isActive_idxINDEXcCREATE INDEX "Promotion_scope_isActive_idx" ON public."Promotion" USING btree (scope, "isActive");
2DROP INDEX public."Promotion_scope_isActive_idx";
publicpostgresfalse240240Ë125920386SmsMessage_createdAt_idxINDEXZCREATE INDEX "SmsMessage_createdAt_idx" ON public."SmsMessage" USING btree ("createdAt");
.DROP INDEX public."SmsMessage_createdAt_idx";
publicpostgresfalse244Þ125920445UploadedFile_purpose_idxINDEXXCREATE INDEX "UploadedFile_purpose_idx" ON public."UploadedFile" USING btree (purpose);
.DROP INDEX public."UploadedFile_purpose_idx";
publicpostgresfalse249¯125919670#WalletBonus_customerId_isActive_idxINDEXsCREATE INDEX "WalletBonus_customerId_isActive_idx" ON public."WalletBonus" USING btree ("customerId", "isActive");
9DROP INDEX public."WalletBonus_customerId_isActive_idx";
publicpostgresfalse235235125920171permission_userTypeId_idxINDEXZCREATE INDEX "permission_userTypeId_idx" ON public.permission USING btree ("userTypeId");
/DROP INDEX public."permission_userTypeId_idx";
publicpostgresfalse237ã260619671!AdminUser AdminUser_branchId_fkey
FK CONSTRAINT¯ALTER TABLE ONLY public."AdminUser"
ADD CONSTRAINT "AdminUser_branchId_fkey" FOREIGN KEY ("branchId") REFERENCES public."Branch"(id) ON UPDATE CASCADE ON DELETE SET NULL;
OALTER TABLE ONLY public."AdminUser" DROP CONSTRAINT "AdminUser_branchId_fkey";
publicpostgresfalse2192164996ä260620173#AdminUser AdminUser_userTypeId_fkey
FK CONSTRAINT´ALTER TABLE ONLY public."AdminUser"
ADD CONSTRAINT "AdminUser_userTypeId_fkey" FOREIGN KEY ("userTypeId") REFERENCES public.user_type(id) ON UPDATE CASCADE ON DELETE SET NULL;
QALTER TABLE ONLY public."AdminUser" DROP CONSTRAINT "AdminUser_userTypeId_fkey";
publicpostgresfalse5043216236
260620322;BranchAllocationItem BranchAllocationItem_allocationId_fkey
FK CONSTRAINTÖALTER TABLE ONLY public."BranchAllocationItem"
ADD CONSTRAINT "BranchAllocationItem_allocationId_fkey" FOREIGN KEY ("allocationId") REFERENCES public."BranchAllocation"(id) ON UPDATE CASCADE ON DELETE CASCADE;
iALTER TABLE ONLY public."BranchAllocationItem" DROP CONSTRAINT "BranchAllocationItem_allocationId_fkey";
publicpostgresfalse24350632422606203278BranchAllocationItem BranchAllocationItem_productId_fkey
FK CONSTRAINTÈALTER TABLE ONLY public."BranchAllocationItem"
ADD CONSTRAINT "BranchAllocationItem_productId_fkey" FOREIGN KEY ("productId") REFERENCES public."Product"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
fALTER TABLE ONLY public."BranchAllocationItem" DROP CONSTRAINT "BranchAllocationItem_productId_fkey";
publicpostgresfalse2252435008 260620317;BranchAllocation BranchAllocation_allocatorAdminUserId_fkey
FK CONSTRAINTØALTER TABLE ONLY public."BranchAllocation"
ADD CONSTRAINT "BranchAllocation_allocatorAdminUserId_fkey" FOREIGN KEY ("allocatorAdminUserId") REFERENCES public."AdminUser"(id) ON UPDATE CASCADE ON DELETE SET NULL;
iALTER TABLE ONLY public."BranchAllocation" DROP CONSTRAINT "BranchAllocation_allocatorAdminUserId_fkey";
publicpostgresfalse2162424985 260620312/BranchAllocation BranchAllocation_branchId_fkey
FK CONSTRAINT½ALTER TABLE ONLY public."BranchAllocation"
ADD CONSTRAINT "BranchAllocation_branchId_fkey" FOREIGN KEY ("branchId") REFERENCES public."Branch"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
]ALTER TABLE ONLY public."BranchAllocation" DROP CONSTRAINT "BranchAllocation_branchId_fkey";
publicpostgresfalse2192424996ê260619696Branch Branch_cityId_fkey
FK CONSTRAINT£ALTER TABLE ONLY public."Branch"
ADD CONSTRAINT "Branch_cityId_fkey" FOREIGN KEY ("cityId") REFERENCES public."City"(id) ON UPDATE CASCADE ON DELETE SET NULL;
GALTER TABLE ONLY public."Branch" DROP CONSTRAINT "Branch_cityId_fkey";
publicpostgresfalse4982219215ì260619701Category Category_parentId_fkey
FK CONSTRAINT¯ALTER TABLE ONLY public."Category"
ADD CONSTRAINT "Category_parentId_fkey" FOREIGN KEY ("parentId") REFERENCES public."Category"(id) ON UPDATE CASCADE ON DELETE SET NULL;
MALTER TABLE ONLY public."Category" DROP CONSTRAINT "Category_parentId_fkey";
publicpostgresfalse2215000221í2606197065CollectionProduct CollectionProduct_collectionId_fkey
FK CONSTRAINTËALTER TABLE ONLY public."CollectionProduct"
ADD CONSTRAINT "CollectionProduct_collectionId_fkey" FOREIGN KEY ("collectionId") REFERENCES public."Collection"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
cALTER TABLE ONLY public."CollectionProduct" DROP CONSTRAINT "CollectionProduct_collectionId_fkey";
publicpostgresfalse2232245004î2606197112CollectionProduct CollectionProduct_productId_fkey
FK CONSTRAINTÂALTER TABLE ONLY public."CollectionProduct"
ADD CONSTRAINT "CollectionProduct_productId_fkey" FOREIGN KEY ("productId") REFERENCES public."Product"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
`ALTER TABLE ONLY public."CollectionProduct" DROP CONSTRAINT "CollectionProduct_productId_fkey";
publicpostgresfalse5008225224260620208Comment Comment_customerId_fkey
FK CONSTRAINT±ALTER TABLE ONLY public."Comment"
ADD CONSTRAINT "Comment_customerId_fkey" FOREIGN KEY ("customerId") REFERENCES public."Customer"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
MALTER TABLE ONLY public."Comment" DROP CONSTRAINT "Comment_customerId_fkey";
publicpostgresfalse4991217238260620203Comment Comment_productId_fkey
FK CONSTRAINT®ALTER TABLE ONLY public."Comment"
ADD CONSTRAINT "Comment_productId_fkey" FOREIGN KEY ("productId") REFERENCES public."Product"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
LALTER TABLE ONLY public."Comment" DROP CONSTRAINT "Comment_productId_fkey";
publicpostgresfalse2385008225260620213Comment Comment_replyToId_fkey
FK CONSTRAINT®ALTER TABLE ONLY public."Comment"
ADD CONSTRAINT "Comment_replyToId_fkey" FOREIGN KEY ("replyToId") REFERENCES public."Comment"(id) ON UPDATE CASCADE ON DELETE SET NULL;
LALTER TABLE ONLY public."Comment" DROP CONSTRAINT "Comment_replyToId_fkey";
publicpostgresfalse50492382382606204137CustomerActivityLog CustomerActivityLog_customerId_fkey
FK CONSTRAINTÉALTER TABLE ONLY public."CustomerActivityLog"
ADD CONSTRAINT "CustomerActivityLog_customerId_fkey" FOREIGN KEY ("customerId") REFERENCES public."Customer"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
eALTER TABLE ONLY public."CustomerActivityLog" DROP CONSTRAINT "CustomerActivityLog_customerId_fkey";
publicpostgresfalse2174991248è260619691+CustomerAddress CustomerAddress_cityId_fkey
FK CONSTRAINTµALTER TABLE ONLY public."CustomerAddress"
ADD CONSTRAINT "CustomerAddress_cityId_fkey" FOREIGN KEY ("cityId") REFERENCES public."City"(id) ON UPDATE CASCADE ON DELETE SET NULL;
YALTER TABLE ONLY public."CustomerAddress" DROP CONSTRAINT "CustomerAddress_cityId_fkey";
publicpostgresfalse2184982215é260619686/CustomerAddress CustomerAddress_customerId_fkey
FK CONSTRAINTÁALTER TABLE ONLY public."CustomerAddress"
ADD CONSTRAINT "CustomerAddress_customerId_fkey" FOREIGN KEY ("customerId") REFERENCES public."Customer"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
]ALTER TABLE ONLY public."CustomerAddress" DROP CONSTRAINT "CustomerAddress_customerId_fkey";
publicpostgresfalse4991218217å260620453#Customer Customer_avatarFileId_fkey
FK CONSTRAINT»ALTER TABLE ONLY public."Customer"
ADD CONSTRAINT "Customer_avatarFileId_fkey" FOREIGN KEY ("avatarFileId") REFERENCES public."UploadedFile"(id) ON UPDATE CASCADE ON DELETE SET NULL;
QALTER TABLE ONLY public."Customer" DROP CONSTRAINT "Customer_avatarFileId_fkey";
publicpostgresfalse5085217249æ260619676Customer Customer_cityId_fkey
FK CONSTRAINT§ALTER TABLE ONLY public."Customer"
ADD CONSTRAINT "Customer_cityId_fkey" FOREIGN KEY ("cityId") REFERENCES public."City"(id) ON UPDATE CASCADE ON DELETE SET NULL;
KALTER TABLE ONLY public."Customer" DROP CONSTRAINT "Customer_cityId_fkey";
publicpostgresfalse2172154982ç260619681(Customer Customer_referredByAgentId_fkey
FK CONSTRAINTÂALTER TABLE ONLY public."Customer"
ADD CONSTRAINT "Customer_referredByAgentId_fkey" FOREIGN KEY ("referredByAgentId") REFERENCES public."AdminUser"(id) ON UPDATE CASCADE ON DELETE SET NULL;
VALTER TABLE ONLY public."Customer" DROP CONSTRAINT "Customer_referredByAgentId_fkey";
publicpostgresfalse2174985216ÿ260619796'LedgerEntry LedgerEntry_customerId_fkey
FK CONSTRAINT¹ALTER TABLE ONLY public."LedgerEntry"
ADD CONSTRAINT "LedgerEntry_customerId_fkey" FOREIGN KEY ("customerId") REFERENCES public."Customer"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
UALTER TABLE ONLY public."LedgerEntry" DROP CONSTRAINT "LedgerEntry_customerId_fkey";
publicpostgresfalse2172334991260619801$LedgerEntry LedgerEntry_orderId_fkey
FK CONSTRAINT°ALTER TABLE ONLY public."LedgerEntry"
ADD CONSTRAINT "LedgerEntry_orderId_fkey" FOREIGN KEY ("orderId") REFERENCES public."Order"(id) ON UPDATE CASCADE ON DELETE SET NULL;
RALTER TABLE ONLY public."LedgerEntry" DROP CONSTRAINT "LedgerEntry_orderId_fkey";
publicpostgresfalse22823350182606198060LedgerEntry LedgerEntry_postedByAdminUserId_fkey
FK CONSTRAINTÌALTER TABLE ONLY public."LedgerEntry"
ADD CONSTRAINT "LedgerEntry_postedByAdminUserId_fkey" FOREIGN KEY ("postedByAdminUserId") REFERENCES public."AdminUser"(id) ON UPDATE CASCADE ON DELETE SET NULL;
^ALTER TABLE ONLY public."LedgerEntry" DROP CONSTRAINT "LedgerEntry_postedByAdminUserId_fkey";
publicpostgresfalse4985233216260620408;NotificationRecipient NotificationRecipient_customerId_fkey
FK CONSTRAINTÍALTER TABLE ONLY public."NotificationRecipient"
ADD CONSTRAINT "NotificationRecipient_customerId_fkey" FOREIGN KEY ("customerId") REFERENCES public."Customer"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
iALTER TABLE ONLY public."NotificationRecipient" DROP CONSTRAINT "NotificationRecipient_customerId_fkey";
publicpostgresfalse2172464991260620403?NotificationRecipient NotificationRecipient_notificationId_fkey
FK CONSTRAINTØALTER TABLE ONLY public."NotificationRecipient"
ADD CONSTRAINT "NotificationRecipient_notificationId_fkey" FOREIGN KEY ("notificationId") REFERENCES public."Notification"(id) ON UPDATE CASCADE ON DELETE CASCADE;
mALTER TABLE ONLY public."NotificationRecipient" DROP CONSTRAINT "NotificationRecipient_notificationId_fkey";
publicpostgresfalse50722452462606203980Notification Notification_sentByAdminUserId_fkey
FK CONSTRAINTÊALTER TABLE ONLY public."Notification"
ADD CONSTRAINT "Notification_sentByAdminUserId_fkey" FOREIGN KEY ("sentByAdminUserId") REFERENCES public."AdminUser"(id) ON UPDATE CASCADE ON DELETE SET NULL;
^ALTER TABLE ONLY public."Notification" DROP CONSTRAINT "Notification_sentByAdminUserId_fkey";
publicpostgresfalse2164985245õ260619746 OrderItem OrderItem_orderId_fkey
FK CONSTRAINT¬ALTER TABLE ONLY public."OrderItem"
ADD CONSTRAINT "OrderItem_orderId_fkey" FOREIGN KEY ("orderId") REFERENCES public."Order"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
NALTER TABLE ONLY public."OrderItem" DROP CONSTRAINT "OrderItem_orderId_fkey";
publicpostgresfalse5018228229ö260619751)OrderItem OrderItem_productVariantId_fkey
FK CONSTRAINTÇALTER TABLE ONLY public."OrderItem"
ADD CONSTRAINT "OrderItem_productVariantId_fkey" FOREIGN KEY ("productVariantId") REFERENCES public."ProductVariant"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
WALTER TABLE ONLY public."OrderItem" DROP CONSTRAINT "OrderItem_productVariantId_fkey";
publicpostgresfalse2292275013÷2606197617OrderStatusEvent OrderStatusEvent_actorAdminUserId_fkey
FK CONSTRAINTÐALTER TABLE ONLY public."OrderStatusEvent"
ADD CONSTRAINT "OrderStatusEvent_actorAdminUserId_fkey" FOREIGN KEY ("actorAdminUserId") REFERENCES public."AdminUser"(id) ON UPDATE CASCADE ON DELETE SET NULL;
eALTER TABLE ONLY public."OrderStatusEvent" DROP CONSTRAINT "OrderStatusEvent_actorAdminUserId_fkey";
publicpostgresfalse2304985216ø260619756.OrderStatusEvent OrderStatusEvent_orderId_fkey
FK CONSTRAINTºALTER TABLE ONLY public."OrderStatusEvent"
ADD CONSTRAINT "OrderStatusEvent_orderId_fkey" FOREIGN KEY ("orderId") REFERENCES public."Order"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
\ALTER TABLE ONLY public."OrderStatusEvent" DROP CONSTRAINT "OrderStatusEvent_orderId_fkey";
publicpostgresfalse2282305018ó260619741Order Order_branchId_fkey
FK CONSTRAINT§ALTER TABLE ONLY public."Order"
ADD CONSTRAINT "Order_branchId_fkey" FOREIGN KEY ("branchId") REFERENCES public."Branch"(id) ON UPDATE CASCADE ON DELETE SET NULL;
GALTER TABLE ONLY public."Order" DROP CONSTRAINT "Order_branchId_fkey";
publicpostgresfalse2192284996ô260619736Order Order_customerId_fkey
FK CONSTRAINT­ALTER TABLE ONLY public."Order"
ADD CONSTRAINT "Order_customerId_fkey" FOREIGN KEY ("customerId") REFERENCES public."Customer"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
IALTER TABLE ONLY public."Order" DROP CONSTRAINT "Order_customerId_fkey";
publicpostgresfalse4991217228ý260619791=PreOrderStatusEvent PreOrderStatusEvent_actorAdminUserId_fkey
FK CONSTRAINTÖALTER TABLE ONLY public."PreOrderStatusEvent"
ADD CONSTRAINT "PreOrderStatusEvent_actorAdminUserId_fkey" FOREIGN KEY ("actorAdminUserId") REFERENCES public."AdminUser"(id) ON UPDATE CASCADE ON DELETE SET NULL;
kALTER TABLE ONLY public."PreOrderStatusEvent" DROP CONSTRAINT "PreOrderStatusEvent_actorAdminUserId_fkey";
publicpostgresfalse4985216232þ2606197867PreOrderStatusEvent PreOrderStatusEvent_preOrderId_fkey
FK CONSTRAINTÉALTER TABLE ONLY public."PreOrderStatusEvent"
ADD CONSTRAINT "PreOrderStatusEvent_preOrderId_fkey" FOREIGN KEY ("preOrderId") REFERENCES public."PreOrder"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
eALTER TABLE ONLY public."PreOrderStatusEvent" DROP CONSTRAINT "PreOrderStatusEvent_preOrderId_fkey";
publicpostgresfalse2315028232ù260619771PreOrder PreOrder_cityId_fkey
FK CONSTRAINT§ALTER TABLE ONLY public."PreOrder"
ADD CONSTRAINT "PreOrder_cityId_fkey" FOREIGN KEY ("cityId") REFERENCES public."City"(id) ON UPDATE CASCADE ON DELETE SET NULL;
KALTER TABLE ONLY public."PreOrder" DROP CONSTRAINT "PreOrder_cityId_fkey";
publicpostgresfalse4982231215ú260619781'PreOrder PreOrder_convertedOrderId_fkey
FK CONSTRAINT¼ALTER TABLE ONLY public."PreOrder"
ADD CONSTRAINT "PreOrder_convertedOrderId_fkey" FOREIGN KEY ("convertedOrderId") REFERENCES public."Order"(id) ON UPDATE CASCADE ON DELETE SET NULL;
UALTER TABLE ONLY public."PreOrder" DROP CONSTRAINT "PreOrder_convertedOrderId_fkey";
publicpostgresfalse2282315018û260619766!PreOrder PreOrder_customerId_fkey
FK CONSTRAINT³ALTER TABLE ONLY public."PreOrder"
ADD CONSTRAINT "PreOrder_customerId_fkey" FOREIGN KEY ("customerId") REFERENCES public."Customer"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
OALTER TABLE ONLY public."PreOrder" DROP CONSTRAINT "PreOrder_customerId_fkey";
publicpostgresfalse4991231217ü260619776!PreOrder PreOrder_workshopId_fkey
FK CONSTRAINT³ALTER TABLE ONLY public."PreOrder"
ADD CONSTRAINT "PreOrder_workshopId_fkey" FOREIGN KEY ("workshopId") REFERENCES public."Workshop"(id) ON UPDATE CASCADE ON DELETE SET NULL;
OALTER TABLE ONLY public."PreOrder" DROP CONSTRAINT "PreOrder_workshopId_fkey";
publicpostgresfalse2204998231ñ260619726(ProductImage ProductImage_productId_fkey
FK CONSTRAINT¸ALTER TABLE ONLY public."ProductImage"
ADD CONSTRAINT "ProductImage_productId_fkey" FOREIGN KEY ("productId") REFERENCES public."Product"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
VALTER TABLE ONLY public."ProductImage" DROP CONSTRAINT "ProductImage_productId_fkey";
publicpostgresfalse5008225226ò260619731,ProductVariant ProductVariant_productId_fkey
FK CONSTRAINT¼ALTER TABLE ONLY public."ProductVariant"
ADD CONSTRAINT "ProductVariant_productId_fkey" FOREIGN KEY ("productId") REFERENCES public."Product"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
ZALTER TABLE ONLY public."ProductVariant" DROP CONSTRAINT "ProductVariant_productId_fkey";
publicpostgresfalse2272255008ï260619721Product Product_brandId_fkey
FK CONSTRAINT¨ALTER TABLE ONLY public."Product"
ADD CONSTRAINT "Product_brandId_fkey" FOREIGN KEY ("brandId") REFERENCES public."Brand"(id) ON UPDATE CASCADE ON DELETE SET NULL;
JALTER TABLE ONLY public."Product" DROP CONSTRAINT "Product_brandId_fkey";
publicpostgresfalse2225002225ð260619716Product Product_categoryId_fkey
FK CONSTRAINT±ALTER TABLE ONLY public."Product"
ADD CONSTRAINT "Product_categoryId_fkey" FOREIGN KEY ("categoryId") REFERENCES public."Category"(id) ON UPDATE CASCADE ON DELETE SET NULL;
MALTER TABLE ONLY public."Product" DROP CONSTRAINT "Product_categoryId_fkey";
publicpostgresfalse2215000225260620282 Promotion Promotion_brandId_fkey
FK CONSTRAINT¬ALTER TABLE ONLY public."Promotion"
ADD CONSTRAINT "Promotion_brandId_fkey" FOREIGN KEY ("brandId") REFERENCES public."Brand"(id) ON UPDATE CASCADE ON DELETE SET NULL;
NALTER TABLE ONLY public."Promotion" DROP CONSTRAINT "Promotion_brandId_fkey";
publicpostgresfalse2222405002260620272#Promotion Promotion_categoryId_fkey
FK CONSTRAINTµALTER TABLE ONLY public."Promotion"
ADD CONSTRAINT "Promotion_categoryId_fkey" FOREIGN KEY ("categoryId") REFERENCES public."Category"(id) ON UPDATE CASCADE ON DELETE SET NULL;
QALTER TABLE ONLY public."Promotion" DROP CONSTRAINT "Promotion_categoryId_fkey";
publicpostgresfalse2402215000 260620277#Promotion Promotion_customerId_fkey
FK CONSTRAINTµALTER TABLE ONLY public."Promotion"
ADD CONSTRAINT "Promotion_customerId_fkey" FOREIGN KEY ("customerId") REFERENCES public."Customer"(id) ON UPDATE CASCADE ON DELETE SET NULL;
QALTER TABLE ONLY public."Promotion" DROP CONSTRAINT "Promotion_customerId_fkey";
publicpostgresfalse2172404991
260620267"Promotion Promotion_productId_fkey
FK CONSTRAINT²ALTER TABLE ONLY public."Promotion"
ADD CONSTRAINT "Promotion_productId_fkey" FOREIGN KEY ("productId") REFERENCES public."Product"(id) ON UPDATE CASCADE ON DELETE SET NULL;
PALTER TABLE ONLY public."Promotion" DROP CONSTRAINT "Promotion_productId_fkey";
publicpostgresfalse2405008225260620393,SmsMessage SmsMessage_sentByAdminUserId_fkey
FK CONSTRAINTÆALTER TABLE ONLY public."SmsMessage"
ADD CONSTRAINT "SmsMessage_sentByAdminUserId_fkey" FOREIGN KEY ("sentByAdminUserId") REFERENCES public."AdminUser"(id) ON UPDATE CASCADE ON DELETE SET NULL;
ZALTER TABLE ONLY public."SmsMessage" DROP CONSTRAINT "SmsMessage_sentByAdminUserId_fkey";
publicpostgresfalse21624449852606204464UploadedFile UploadedFile_uploadedByAdminUserId_fkey
FK CONSTRAINTÒALTER TABLE ONLY public."UploadedFile"
ADD CONSTRAINT "UploadedFile_uploadedByAdminUserId_fkey" FOREIGN KEY ("uploadedByAdminUserId") REFERENCES public."AdminUser"(id) ON UPDATE CASCADE ON DELETE SET NULL;
bALTER TABLE ONLY public."UploadedFile" DROP CONSTRAINT "UploadedFile_uploadedByAdminUserId_fkey";
publicpostgresfalse2492164985260619811'WalletBonus WalletBonus_customerId_fkey
FK CONSTRAINT¹ALTER TABLE ONLY public."WalletBonus"
ADD CONSTRAINT "WalletBonus_customerId_fkey" FOREIGN KEY ("customerId") REFERENCES public."Customer"(id) ON UPDATE CASCADE ON DELETE RESTRICT;
UALTER TABLE ONLY public."WalletBonus" DROP CONSTRAINT "WalletBonus_customerId_fkey";
publicpostgresfalse2174991235ë260620290#Workshop Workshop_supervisorId_fkey
FK CONSTRAINT¸ALTER TABLE ONLY public."Workshop"
ADD CONSTRAINT "Workshop_supervisorId_fkey" FOREIGN KEY ("supervisorId") REFERENCES public."AdminUser"(id) ON UPDATE CASCADE ON DELETE SET NULL;
QALTER TABLE ONLY public."Workshop" DROP CONSTRAINT "Workshop_supervisorId_fkey";
publicpostgresfalse2204985216260620178%permission permission_userTypeId_fkey
FK CONSTRAINT³ALTER TABLE ONLY public.permission
ADD CONSTRAINT "permission_userTypeId_fkey" FOREIGN KEY ("userTypeId") REFERENCES public.user_type(id) ON UPDATE CASCADE ON DELETE CASCADE;
QALTER TABLE ONLY public.permission DROP CONSTRAINT "permission_userTypeId_fkey";
publicpostgresfalse5043236237¥&xœ­ÒËnÚ@†áõp^°…ÎÁã;4$40„ EBÆ cÀœb
f×�÷A)B$U¥Þ‰]n¦¿Ý6ªT5]Б%�W~ôé5wé:æbŒ a†º°m6¦#‚¾}òwþÁÿèÿÁöàlàò5X#¬ª`…0•¢8mÅ Ž—å»üB)µº˜=Ë[æ„Io5kÞð.ßÔÕšÓ§jæfÔ[R&O´eËê\¤×J¹J3�½º(¢ÛèqÅTJ`5A˜@hŠ«)&%%‰#…ÇLÇ� mO#.aòÌ1û}º¢`åï�Ûª?û{Á†op«ˆ‹£C~qÏI9WXƒËŒž³æÕFïL/x�÷ãä8g_;j­ßÇmÏh´]Ñ)–�é"›=×_åbYÀÀURœ%%ú»V�óPkÏÌ‘Ç-�+dîXùpÜ«ã6BªŠ,q‘�ˆL¿ËéÍÜ
P«¨55†f7áwݮц·=D$ küU."Ez¡«@—Bºç=¬v`èu° VÁ½ë>ù{ÜÿÄ3ÆD8§áëZ¥ çµR3šúúB×*ÿXÂPBï|nΗ6xÕ‰)™nû- ¼`è§�¬¨äð›°•ÈÌ9—àœfNg2Z­XM«6LBRœ¦DžT(T!¿L+•E
Ó™zç¸
èhÒxü‘sD„aE.Éÿ¿ ·Ó…K¢e,
c
QðW¢`a·ÉX,öräf’¨‰xœK*JÌKÎÐÍM,ÎÈHLÒ™yœ7¶ÜØycÅÍv…›­76ÞZycÓísËÍöë9“3K*aÊ9cü8K€WÄ”’Ô C7)±*1±aÌ�7–ߨÄAÌM@3×+ÜX4mã�å7Û &B´‚ôl¾Ý!�F˜šš!WŒÖ[T™¿
xœ‹ÑãââÅ©À
xœ‹ÑãââÅ©«PxœK*JÌKÑÍHÍ«Jä¼Ù~³íƦËnl¿Ùrc9WX.±¨$³81�ófë�57[ovÜØy³]áÆV Ò�7VÝZc#WŒqƒ&Uª“xœ�ÎA Ð5œ¢°M/Òtƒ„ ±Åîm{“ªBÊaf8�ct/ÉŸÍO^æK1œ±Ú3Øpμ ²¾û¤1£nNÊÞD[û«þµ-—„ŽNH5¨‰`€�ÐgÐ*yÈzFß"b¥T ÷Ýš®�è6ˆ¸Hy1––îù‰K…kEøéìkÎùùr>¤�xœKÎ,©ÔÍM,ÎÈHLá¼ÙzcËÍöë9o¬»±ñÆò›o,¿Ù¦dn»Ùq»‡3ƈ¸’A:J“Š2«8o¬º±âÆÆÛ=76qÞXtcPåŠË�Ü5�[nl¼Ù„¦15£(1¨hÏF�*d&’ºÌâ´Ä �Âå7¶Þlª+Eæ@Çèqqqµohn¬}xœKÎÏÉIM.ÉÌÏÓMKM,)-JMá¼¹ïÆÆ›�@ÜqcË£†ž›í7–ßîQ7Ûn¶¥VÝlç¼Ùz³íƪën¬KÞØ¤p³õÆÚ+€ºVu¥6B4€D·Þì¸ÙT´Jfð­õ7–ßl×ã,áŠÑãââÂQý­Kxœ}ÊÁ
À ÐsÙ…NÔ ùbCJÀ(îß
|ç‡tW”epW©=µ]cfÛ(†ËZž/á‡F“(Åç=æ¾ÝiAÏMD?ž–/ü»Kxœ…‘ËjÂ@†×“§˜˜�LLÔìJ