-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathshop.yaml
67 lines (67 loc) · 1.37 KB
/
shop.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
name: "shop"
schema: public
tables:
products:
columns:
id:
type: uuid
pk: true
created_at:
type: timestamptz
updated_at:
type: timestamptz
deleted_at:
type: timestamptz
nullable: true
category_id:
type: uuid
name:
type: varchar
code:
type: varchar
unit:
type: varchar
indexes:
products_deleted_at:
columns: [deleted_at]
products_category_id:
columns: [category_id]
products_code:
columns: [code]
relations:
categories:
name: product_category_rel
columns: [category_id]
parentColumns: [id]
onDelete: CASCADE
categories:
columns:
id:
type: uuid
pk: true
created_at:
type: timestamptz
updated_at:
type: timestamptz
deleted_at:
type: timestamptz
nullable: true
parent_id:
type: uuid
nullable: true
name:
type: varchar
is_disabled:
type: boolean
default: false
indexes:
categories_deleted_at:
columns: [deleted_at]
categories_parent_id:
columns: [parent_id]
relations:
categories:
name: category_parent_rel
columns: [parent_id]
parentColumns: [id]
onDelete: CASCADE