This commit is contained in:
2026-03-11 20:42:34 +03:30
parent 8c5f1d4d49
commit 007db7f9bd
30 changed files with 393 additions and 219 deletions
@@ -0,0 +1,10 @@
/*
Warnings:
- Added the required column `pricing_model` to the `goods` table without a default value. This is not possible if the table is not empty.
- Added the required column `unit_type` to the `goods` table without a default value. This is not possible if the table is not empty.
*/
-- AlterTable
ALTER TABLE `goods` ADD COLUMN `pricing_model` ENUM('STANDARD', 'GOLD') NOT NULL,
ADD COLUMN `unit_type` ENUM('COUNT', 'GRAM', 'KILOGRAM', 'MILLILITER', 'LITER', 'METER', 'HOUR') NOT NULL;
@@ -0,0 +1,2 @@
-- AlterTable
ALTER TABLE `accounts` MODIFY `type` ENUM('PARTNER', 'BUSINESS', 'SUPER_ADMIN', 'ADMIN', 'PROVIDER', 'POS') NOT NULL;
+1
View File
@@ -93,6 +93,7 @@ enum UserType {
enum AccountType {
PARTNER
BUSINESS
SUPER_ADMIN
ADMIN
PROVIDER
POS
+13 -11
View File
@@ -1,15 +1,17 @@
model Good {
id String @id @default(uuid())
name String @db.VarChar(255)
description String? @db.Text
sku String @db.VarChar(100)
local_sku String? @unique() @db.VarChar(100)
barcode String? @unique() @db.VarChar(100)
base_sale_price Decimal? @default(0.00) @db.Decimal(15, 0)
is_default_guild_good Boolean @default(false)
created_at DateTime @default(now()) @db.Timestamp(0)
updated_at DateTime @updatedAt @db.Timestamp(0)
deleted_at DateTime? @db.Timestamp(0)
id String @id @default(uuid())
name String @db.VarChar(255)
is_default_guild_good Boolean @default(false)
sku String @db.VarChar(100)
unit_type UnitType
pricing_model GoodPricingModel
description String? @db.Text
local_sku String? @unique() @db.VarChar(100)
barcode String? @unique() @db.VarChar(100)
base_sale_price Decimal? @default(0.00) @db.Decimal(15, 0)
created_at DateTime @default(now()) @db.Timestamp(0)
updated_at DateTime @updatedAt @db.Timestamp(0)
deleted_at DateTime? @db.Timestamp(0)
complex_id String?
category_id String?