efiber-prisma-schema 1.6.1 → 1.6.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/prisma/schema.prisma +309 -40
package/package.json
CHANGED
package/prisma/schema.prisma
CHANGED
|
@@ -362,23 +362,31 @@ model User {
|
|
|
362
362
|
workOrderEditLogs WorkOrderEditLog[]
|
|
363
363
|
Notifications Notifications[]
|
|
364
364
|
|
|
365
|
-
pboFatTemplates
|
|
366
|
-
pboFat
|
|
367
|
-
cable
|
|
368
|
-
SpliceClosure
|
|
369
|
-
CableTemplate
|
|
370
|
-
CentralOffice
|
|
371
|
-
centralOfficeId
|
|
372
|
-
Cluster
|
|
373
|
-
clusterId
|
|
374
|
-
projectPhaseLog
|
|
375
|
-
ZoneNro
|
|
376
|
-
Pole
|
|
377
|
-
Manhole
|
|
378
|
-
Loop
|
|
379
|
-
FDTSRO
|
|
380
|
-
SFU
|
|
381
|
-
Building
|
|
365
|
+
pboFatTemplates PboFatTemplate[]
|
|
366
|
+
pboFat PboFat[]
|
|
367
|
+
cable Cable[]
|
|
368
|
+
SpliceClosure SpliceClosure[]
|
|
369
|
+
CableTemplate CableTemplate[]
|
|
370
|
+
CentralOffice CentralOffice? @relation(fields: [centralOfficeId], references: [id])
|
|
371
|
+
centralOfficeId String?
|
|
372
|
+
Cluster Cluster? @relation(fields: [clusterId], references: [id])
|
|
373
|
+
clusterId String?
|
|
374
|
+
projectPhaseLog projectPhaseLog[]
|
|
375
|
+
ZoneNro ZoneNro[]
|
|
376
|
+
Pole Pole[]
|
|
377
|
+
Manhole Manhole[]
|
|
378
|
+
Loop Loop[]
|
|
379
|
+
FDTSRO FDTSRO[]
|
|
380
|
+
SFU SFU[]
|
|
381
|
+
Building Building[]
|
|
382
|
+
SpliceClosureTemplate SpliceClosureTemplate[]
|
|
383
|
+
ZoneNroTemplate ZoneNroTemplate[]
|
|
384
|
+
PoleTemplate PoleTemplate[]
|
|
385
|
+
ManholeTemplate ManholeTemplate[]
|
|
386
|
+
LoopTemplate LoopTemplate[]
|
|
387
|
+
FDTSROTemplate FDTSROTemplate[]
|
|
388
|
+
SFUTemplate SFUTemplate[]
|
|
389
|
+
BuildingTemplate BuildingTemplate[]
|
|
382
390
|
}
|
|
383
391
|
|
|
384
392
|
model MainProject {
|
|
@@ -443,6 +451,15 @@ model Project {
|
|
|
443
451
|
FDTSRO FDTSRO[]
|
|
444
452
|
SFU SFU[]
|
|
445
453
|
Building Building[]
|
|
454
|
+
SpliceClosure SpliceClosure[]
|
|
455
|
+
SpliceClosureTemplate SpliceClosureTemplate[]
|
|
456
|
+
ZoneNroTemplate ZoneNroTemplate[]
|
|
457
|
+
PoleTemplate PoleTemplate[]
|
|
458
|
+
ManholeTemplate ManholeTemplate[]
|
|
459
|
+
LoopTemplate LoopTemplate[]
|
|
460
|
+
FDTSROTemplate FDTSROTemplate[]
|
|
461
|
+
SFUTemplate SFUTemplate[]
|
|
462
|
+
BuildingTemplate BuildingTemplate[]
|
|
446
463
|
}
|
|
447
464
|
|
|
448
465
|
model projectPhaseLog {
|
|
@@ -1149,19 +1166,27 @@ model NetworkElement {
|
|
|
1149
1166
|
updatedAt DateTime @updatedAt
|
|
1150
1167
|
deletedAt DateTime?
|
|
1151
1168
|
|
|
1152
|
-
PboFat
|
|
1153
|
-
pboFatTemplate
|
|
1154
|
-
Cable
|
|
1155
|
-
SpliceClosure
|
|
1156
|
-
CableTemplate
|
|
1157
|
-
qrCode
|
|
1158
|
-
ZoneNro
|
|
1159
|
-
Pole
|
|
1160
|
-
Manhole
|
|
1161
|
-
Loop
|
|
1162
|
-
FDTSRO
|
|
1163
|
-
SFU
|
|
1164
|
-
Building
|
|
1169
|
+
PboFat PboFat[]
|
|
1170
|
+
pboFatTemplate PboFatTemplate[]
|
|
1171
|
+
Cable Cable[]
|
|
1172
|
+
SpliceClosure SpliceClosure[]
|
|
1173
|
+
CableTemplate CableTemplate[]
|
|
1174
|
+
qrCode qrCode[]
|
|
1175
|
+
ZoneNro ZoneNro[]
|
|
1176
|
+
Pole Pole[]
|
|
1177
|
+
Manhole Manhole[]
|
|
1178
|
+
Loop Loop[]
|
|
1179
|
+
FDTSRO FDTSRO[]
|
|
1180
|
+
SFU SFU[]
|
|
1181
|
+
Building Building[]
|
|
1182
|
+
SpliceClosureTemplate SpliceClosureTemplate[]
|
|
1183
|
+
ZoneNroTemplate ZoneNroTemplate[]
|
|
1184
|
+
PoleTemplate PoleTemplate[]
|
|
1185
|
+
ManholeTemplate ManholeTemplate[]
|
|
1186
|
+
LoopTemplate LoopTemplate[]
|
|
1187
|
+
FDTSROTemplate FDTSROTemplate[]
|
|
1188
|
+
SFUTemplate SFUTemplate[]
|
|
1189
|
+
BuildingTemplate BuildingTemplate[]
|
|
1165
1190
|
}
|
|
1166
1191
|
|
|
1167
1192
|
model Cable {
|
|
@@ -1371,6 +1396,43 @@ model SpliceClosure {
|
|
|
1371
1396
|
networkElement NetworkElement @relation(fields: [networkElementId], references: [id])
|
|
1372
1397
|
networkElementId String
|
|
1373
1398
|
|
|
1399
|
+
project Project? @relation(fields: [projectId], references: [id])
|
|
1400
|
+
projectId String?
|
|
1401
|
+
|
|
1402
|
+
cluster Cluster? @relation(fields: [clusterId], references: [id])
|
|
1403
|
+
clusterId String?
|
|
1404
|
+
|
|
1405
|
+
spliceClosureAttributes SpliceClosureAttributes[]
|
|
1406
|
+
}
|
|
1407
|
+
|
|
1408
|
+
model SpliceClosureTemplate {
|
|
1409
|
+
// TODO: Add the fields for previous/next equipment, CO and project phase
|
|
1410
|
+
id String @id @unique @default(uuid())
|
|
1411
|
+
no Int @default(autoincrement())
|
|
1412
|
+
name String
|
|
1413
|
+
status String @default("active")
|
|
1414
|
+
terminalAccess Boolean @default(false)
|
|
1415
|
+
photos Json? //Upload files for photos
|
|
1416
|
+
zone Json? //Color code for zone
|
|
1417
|
+
geometry Json? //Icon for the PBO FAT
|
|
1418
|
+
attributes Json? //Attributes for the PBO FAT
|
|
1419
|
+
description String?
|
|
1420
|
+
|
|
1421
|
+
createdAt DateTime @default(now())
|
|
1422
|
+
updatedAt DateTime @updatedAt
|
|
1423
|
+
updatedBy User? @relation(fields: [updatedById], references: [id])
|
|
1424
|
+
updatedById String?
|
|
1425
|
+
deletedAt DateTime?
|
|
1426
|
+
|
|
1427
|
+
networkElement NetworkElement @relation(fields: [networkElementId], references: [id])
|
|
1428
|
+
networkElementId String
|
|
1429
|
+
|
|
1430
|
+
project Project? @relation(fields: [projectId], references: [id])
|
|
1431
|
+
projectId String?
|
|
1432
|
+
|
|
1433
|
+
cluster Cluster? @relation(fields: [clusterId], references: [id])
|
|
1434
|
+
clusterId String?
|
|
1435
|
+
|
|
1374
1436
|
spliceClosureAttributes SpliceClosureAttributes[]
|
|
1375
1437
|
}
|
|
1376
1438
|
|
|
@@ -1394,8 +1456,10 @@ model SpliceClosureAttributes {
|
|
|
1394
1456
|
material Material? @relation(fields: [materialId], references: [id])
|
|
1395
1457
|
materialId String?
|
|
1396
1458
|
|
|
1397
|
-
spliceClosure
|
|
1398
|
-
spliceClosureId
|
|
1459
|
+
spliceClosure SpliceClosure @relation(fields: [spliceClosureId], references: [id])
|
|
1460
|
+
spliceClosureId String
|
|
1461
|
+
SpliceClosureTemplate SpliceClosureTemplate? @relation(fields: [spliceClosureTemplateId], references: [id])
|
|
1462
|
+
spliceClosureTemplateId String?
|
|
1399
1463
|
}
|
|
1400
1464
|
|
|
1401
1465
|
model ZoneNro {
|
|
@@ -1426,6 +1490,34 @@ model ZoneNro {
|
|
|
1426
1490
|
clusterId String?
|
|
1427
1491
|
}
|
|
1428
1492
|
|
|
1493
|
+
model ZoneNroTemplate {
|
|
1494
|
+
id String @id @unique @default(uuid())
|
|
1495
|
+
no Int @default(autoincrement())
|
|
1496
|
+
|
|
1497
|
+
status String @default("active")
|
|
1498
|
+
terminalAccess Boolean @default(false)
|
|
1499
|
+
photos Json?
|
|
1500
|
+
zone Json?
|
|
1501
|
+
geometry Json?
|
|
1502
|
+
attributes Json?
|
|
1503
|
+
|
|
1504
|
+
createdAt DateTime @default(now())
|
|
1505
|
+
updatedAt DateTime @updatedAt
|
|
1506
|
+
deletedAt DateTime?
|
|
1507
|
+
|
|
1508
|
+
updatedBy User? @relation(fields: [updatedById], references: [id])
|
|
1509
|
+
updatedById String?
|
|
1510
|
+
|
|
1511
|
+
networkElement NetworkElement @relation(fields: [networkElementId], references: [id])
|
|
1512
|
+
networkElementId String
|
|
1513
|
+
|
|
1514
|
+
project Project? @relation(fields: [projectId], references: [id])
|
|
1515
|
+
projectId String?
|
|
1516
|
+
|
|
1517
|
+
cluster Cluster? @relation(fields: [clusterId], references: [id])
|
|
1518
|
+
clusterId String?
|
|
1519
|
+
}
|
|
1520
|
+
|
|
1429
1521
|
model Pole {
|
|
1430
1522
|
id String @id @unique @default(uuid())
|
|
1431
1523
|
no Int @default(autoincrement())
|
|
@@ -1454,6 +1546,34 @@ model Pole {
|
|
|
1454
1546
|
clusterId String?
|
|
1455
1547
|
}
|
|
1456
1548
|
|
|
1549
|
+
model PoleTemplate {
|
|
1550
|
+
id String @id @unique @default(uuid())
|
|
1551
|
+
no Int @default(autoincrement())
|
|
1552
|
+
|
|
1553
|
+
status String @default("active")
|
|
1554
|
+
terminalAccess Boolean @default(false)
|
|
1555
|
+
photos Json?
|
|
1556
|
+
zone Json?
|
|
1557
|
+
geometry Json?
|
|
1558
|
+
attributes Json?
|
|
1559
|
+
|
|
1560
|
+
createdAt DateTime @default(now())
|
|
1561
|
+
updatedAt DateTime @updatedAt
|
|
1562
|
+
deletedAt DateTime?
|
|
1563
|
+
|
|
1564
|
+
updatedBy User? @relation(fields: [updatedById], references: [id])
|
|
1565
|
+
updatedById String?
|
|
1566
|
+
|
|
1567
|
+
networkElement NetworkElement @relation(fields: [networkElementId], references: [id])
|
|
1568
|
+
networkElementId String
|
|
1569
|
+
|
|
1570
|
+
project Project? @relation(fields: [projectId], references: [id])
|
|
1571
|
+
projectId String?
|
|
1572
|
+
|
|
1573
|
+
cluster Cluster? @relation(fields: [clusterId], references: [id])
|
|
1574
|
+
clusterId String?
|
|
1575
|
+
}
|
|
1576
|
+
|
|
1457
1577
|
model Manhole {
|
|
1458
1578
|
id String @id @unique @default(uuid())
|
|
1459
1579
|
no Int @default(autoincrement())
|
|
@@ -1482,6 +1602,34 @@ model Manhole {
|
|
|
1482
1602
|
clusterId String?
|
|
1483
1603
|
}
|
|
1484
1604
|
|
|
1605
|
+
model ManholeTemplate {
|
|
1606
|
+
id String @id @unique @default(uuid())
|
|
1607
|
+
no Int @default(autoincrement())
|
|
1608
|
+
|
|
1609
|
+
status String @default("active")
|
|
1610
|
+
terminalAccess Boolean @default(false)
|
|
1611
|
+
photos Json?
|
|
1612
|
+
zone Json?
|
|
1613
|
+
geometry Json?
|
|
1614
|
+
attributes Json?
|
|
1615
|
+
|
|
1616
|
+
createdAt DateTime @default(now())
|
|
1617
|
+
updatedAt DateTime @updatedAt
|
|
1618
|
+
deletedAt DateTime?
|
|
1619
|
+
|
|
1620
|
+
updatedBy User? @relation(fields: [updatedById], references: [id])
|
|
1621
|
+
updatedById String?
|
|
1622
|
+
|
|
1623
|
+
networkElement NetworkElement @relation(fields: [networkElementId], references: [id])
|
|
1624
|
+
networkElementId String
|
|
1625
|
+
|
|
1626
|
+
project Project? @relation(fields: [projectId], references: [id])
|
|
1627
|
+
projectId String?
|
|
1628
|
+
|
|
1629
|
+
cluster Cluster? @relation(fields: [clusterId], references: [id])
|
|
1630
|
+
clusterId String?
|
|
1631
|
+
}
|
|
1632
|
+
|
|
1485
1633
|
model Loop {
|
|
1486
1634
|
id String @id @unique @default(uuid())
|
|
1487
1635
|
no Int @default(autoincrement())
|
|
@@ -1510,6 +1658,34 @@ model Loop {
|
|
|
1510
1658
|
clusterId String?
|
|
1511
1659
|
}
|
|
1512
1660
|
|
|
1661
|
+
model LoopTemplate {
|
|
1662
|
+
id String @id @unique @default(uuid())
|
|
1663
|
+
no Int @default(autoincrement())
|
|
1664
|
+
|
|
1665
|
+
status String @default("active")
|
|
1666
|
+
terminalAccess Boolean @default(false)
|
|
1667
|
+
photos Json?
|
|
1668
|
+
zone Json?
|
|
1669
|
+
geometry Json?
|
|
1670
|
+
attributes Json?
|
|
1671
|
+
|
|
1672
|
+
createdAt DateTime @default(now())
|
|
1673
|
+
updatedAt DateTime @updatedAt
|
|
1674
|
+
deletedAt DateTime?
|
|
1675
|
+
|
|
1676
|
+
updatedBy User? @relation(fields: [updatedById], references: [id])
|
|
1677
|
+
updatedById String?
|
|
1678
|
+
|
|
1679
|
+
networkElement NetworkElement @relation(fields: [networkElementId], references: [id])
|
|
1680
|
+
networkElementId String
|
|
1681
|
+
|
|
1682
|
+
project Project? @relation(fields: [projectId], references: [id])
|
|
1683
|
+
projectId String?
|
|
1684
|
+
|
|
1685
|
+
cluster Cluster? @relation(fields: [clusterId], references: [id])
|
|
1686
|
+
clusterId String?
|
|
1687
|
+
}
|
|
1688
|
+
|
|
1513
1689
|
model FDTSRO {
|
|
1514
1690
|
id String @id @unique @default(uuid())
|
|
1515
1691
|
no Int @default(autoincrement())
|
|
@@ -1538,6 +1714,34 @@ model FDTSRO {
|
|
|
1538
1714
|
clusterId String?
|
|
1539
1715
|
}
|
|
1540
1716
|
|
|
1717
|
+
model FDTSROTemplate {
|
|
1718
|
+
id String @id @unique @default(uuid())
|
|
1719
|
+
no Int @default(autoincrement())
|
|
1720
|
+
|
|
1721
|
+
status String @default("active")
|
|
1722
|
+
terminalAccess Boolean @default(false)
|
|
1723
|
+
photos Json?
|
|
1724
|
+
zone Json?
|
|
1725
|
+
geometry Json?
|
|
1726
|
+
attributes Json?
|
|
1727
|
+
|
|
1728
|
+
createdAt DateTime @default(now())
|
|
1729
|
+
updatedAt DateTime @updatedAt
|
|
1730
|
+
deletedAt DateTime?
|
|
1731
|
+
|
|
1732
|
+
updatedBy User? @relation(fields: [updatedById], references: [id])
|
|
1733
|
+
updatedById String?
|
|
1734
|
+
|
|
1735
|
+
networkElement NetworkElement @relation(fields: [networkElementId], references: [id])
|
|
1736
|
+
networkElementId String
|
|
1737
|
+
|
|
1738
|
+
project Project? @relation(fields: [projectId], references: [id])
|
|
1739
|
+
projectId String?
|
|
1740
|
+
|
|
1741
|
+
cluster Cluster? @relation(fields: [clusterId], references: [id])
|
|
1742
|
+
clusterId String?
|
|
1743
|
+
}
|
|
1744
|
+
|
|
1541
1745
|
model SFU {
|
|
1542
1746
|
id String @id @unique @default(uuid())
|
|
1543
1747
|
no Int @default(autoincrement())
|
|
@@ -1566,6 +1770,34 @@ model SFU {
|
|
|
1566
1770
|
clusterId String?
|
|
1567
1771
|
}
|
|
1568
1772
|
|
|
1773
|
+
model SFUTemplate {
|
|
1774
|
+
id String @id @unique @default(uuid())
|
|
1775
|
+
no Int @default(autoincrement())
|
|
1776
|
+
|
|
1777
|
+
status String @default("active")
|
|
1778
|
+
terminalAccess Boolean @default(false)
|
|
1779
|
+
photos Json?
|
|
1780
|
+
zone Json?
|
|
1781
|
+
geometry Json?
|
|
1782
|
+
attributes Json?
|
|
1783
|
+
|
|
1784
|
+
createdAt DateTime @default(now())
|
|
1785
|
+
updatedAt DateTime @updatedAt
|
|
1786
|
+
deletedAt DateTime?
|
|
1787
|
+
|
|
1788
|
+
updatedBy User? @relation(fields: [updatedById], references: [id])
|
|
1789
|
+
updatedById String?
|
|
1790
|
+
|
|
1791
|
+
networkElement NetworkElement @relation(fields: [networkElementId], references: [id])
|
|
1792
|
+
networkElementId String
|
|
1793
|
+
|
|
1794
|
+
project Project? @relation(fields: [projectId], references: [id])
|
|
1795
|
+
projectId String?
|
|
1796
|
+
|
|
1797
|
+
cluster Cluster? @relation(fields: [clusterId], references: [id])
|
|
1798
|
+
clusterId String?
|
|
1799
|
+
}
|
|
1800
|
+
|
|
1569
1801
|
model Building {
|
|
1570
1802
|
id String @id @unique @default(uuid())
|
|
1571
1803
|
no Int @default(autoincrement())
|
|
@@ -1594,6 +1826,34 @@ model Building {
|
|
|
1594
1826
|
clusterId String?
|
|
1595
1827
|
}
|
|
1596
1828
|
|
|
1829
|
+
model BuildingTemplate {
|
|
1830
|
+
id String @id @unique @default(uuid())
|
|
1831
|
+
no Int @default(autoincrement())
|
|
1832
|
+
|
|
1833
|
+
status String @default("active")
|
|
1834
|
+
terminalAccess Boolean @default(false)
|
|
1835
|
+
photos Json?
|
|
1836
|
+
zone Json?
|
|
1837
|
+
geometry Json?
|
|
1838
|
+
attributes Json?
|
|
1839
|
+
|
|
1840
|
+
createdAt DateTime @default(now())
|
|
1841
|
+
updatedAt DateTime @updatedAt
|
|
1842
|
+
deletedAt DateTime?
|
|
1843
|
+
|
|
1844
|
+
updatedBy User? @relation(fields: [updatedById], references: [id])
|
|
1845
|
+
updatedById String?
|
|
1846
|
+
|
|
1847
|
+
networkElement NetworkElement @relation(fields: [networkElementId], references: [id])
|
|
1848
|
+
networkElementId String
|
|
1849
|
+
|
|
1850
|
+
project Project? @relation(fields: [projectId], references: [id])
|
|
1851
|
+
projectId String?
|
|
1852
|
+
|
|
1853
|
+
cluster Cluster? @relation(fields: [clusterId], references: [id])
|
|
1854
|
+
clusterId String?
|
|
1855
|
+
}
|
|
1856
|
+
|
|
1597
1857
|
model CentralOffice {
|
|
1598
1858
|
id String @id @unique @default(uuid())
|
|
1599
1859
|
no Int @default(autoincrement())
|
|
@@ -1624,14 +1884,23 @@ model Cluster {
|
|
|
1624
1884
|
centralOffice CentralOffice? @relation(fields: [centralOfficeId], references: [id])
|
|
1625
1885
|
centralOfficeId String?
|
|
1626
1886
|
|
|
1627
|
-
users
|
|
1628
|
-
ZoneNro
|
|
1629
|
-
Pole
|
|
1630
|
-
Manhole
|
|
1631
|
-
Loop
|
|
1632
|
-
FDTSRO
|
|
1633
|
-
SFU
|
|
1634
|
-
Building
|
|
1887
|
+
users User[]
|
|
1888
|
+
ZoneNro ZoneNro[]
|
|
1889
|
+
Pole Pole[]
|
|
1890
|
+
Manhole Manhole[]
|
|
1891
|
+
Loop Loop[]
|
|
1892
|
+
FDTSRO FDTSRO[]
|
|
1893
|
+
SFU SFU[]
|
|
1894
|
+
Building Building[]
|
|
1895
|
+
SpliceClosure SpliceClosure[]
|
|
1896
|
+
SpliceClosureTemplate SpliceClosureTemplate[]
|
|
1897
|
+
ZoneNroTemplate ZoneNroTemplate[]
|
|
1898
|
+
PoleTemplate PoleTemplate[]
|
|
1899
|
+
ManholeTemplate ManholeTemplate[]
|
|
1900
|
+
LoopTemplate LoopTemplate[]
|
|
1901
|
+
FDTSROTemplate FDTSROTemplate[]
|
|
1902
|
+
SFUTemplate SFUTemplate[]
|
|
1903
|
+
BuildingTemplate BuildingTemplate[]
|
|
1635
1904
|
}
|
|
1636
1905
|
|
|
1637
1906
|
model qrCode {
|