@factor-wise/prisma-schema 2.0.22 → 2.0.24

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@factor-wise/prisma-schema",
3
- "version": "2.0.22",
3
+ "version": "2.0.24",
4
4
  "description": "Shared Prisma schema and generated client for Factor Wise projects",
5
5
  "main": "generated/client/index.js",
6
6
  "types": "generated/client/index.d.ts",
@@ -247,6 +247,7 @@ model approval {
247
247
  documentr String? @db.VarChar(512)
248
248
  redFlag String?
249
249
  createdDate DateTime @default(now()) @db.DateTime(0)
250
+ updatedAt DateTime @default(now()) @db.DateTime(0)
250
251
  sanctionalloUID Int?
251
252
  customerApproval approval_customerApproval @default(ZERO)
252
253
  employmentType String? @db.VarChar(50)
@@ -1150,6 +1151,7 @@ model leads {
1150
1151
  creditAssign Int
1151
1152
  collectionUID Int?
1152
1153
  createdDate DateTime @default(now()) @db.Timestamp(0)
1154
+ updatedAt DateTime @default(now()) @db.DateTime(0)
1153
1155
  alloUID String @default("no") @db.VarChar(216)
1154
1156
  sanctionalloUID Int
1155
1157
  sanctionAppID String @default("no") @db.VarChar(216)
@@ -1343,6 +1345,7 @@ model loan {
1343
1345
  ip String @db.VarChar(100)
1344
1346
  disbursedBy Int?
1345
1347
  createdDate DateTime @default(now()) @db.DateTime(0)
1348
+ updatedAt DateTime @default(now()) @db.DateTime(0)
1346
1349
  allocate_date DateTime? @default(now()) @db.DateTime(0)
1347
1350
  allocated_by String? @db.VarChar(64)
1348
1351
  acutalDisbursalAmount Int?
@@ -2212,7 +2215,7 @@ model videokyc {
2212
2215
  updatedAt DateTime @default(now()) @db.DateTime(0)
2213
2216
  videoPath String?
2214
2217
  location String?
2215
- latlongAddress String?
2218
+ latlongAddress String? @db.Text
2216
2219
 
2217
2220
  @@index([leadID], map: "fk_lead")
2218
2221
  }
@@ -2244,7 +2247,11 @@ model cibildata {
2244
2247
  updatedAt DateTime? @default(now()) @db.Timestamp(0)
2245
2248
  analyser_data Json?
2246
2249
 
2247
- @@index([leadID], map: "leadID")
2250
+ @@index([leadID], map: "idx_leadID")
2251
+ @@index([status], map: "idx_status")
2252
+ @@index([createdAt], map: "idx_createdAt")
2253
+ @@index([leadID, status], map: "idx_lead_status")
2254
+ @@index([leadID, createdAt], map: "idx_lead_createdAt")
2248
2255
  }
2249
2256
 
2250
2257
  model loan_sequence {
@@ -2631,6 +2638,61 @@ enum approval_status {
2631
2638
  Not_Required_Process @map("Not Required Process")
2632
2639
  }
2633
2640
 
2641
+ model fi {
2642
+ fiID Int @id @default(autoincrement())
2643
+ leadID Int
2644
+ customerID Int?
2645
+ bucket fi_bucket?
2646
+ overdueDays Int?
2647
+ interactionStatus fi_interactionStatus @default(INITIATED)
2648
+ latestNoticeType String? @db.VarChar(50)
2649
+ lastNoticeSentAt DateTime?
2650
+ caseClosed Boolean @default(false)
2651
+ caseClosedAt DateTime?
2652
+ createdAt DateTime @default(now())
2653
+ updatedAt DateTime @updatedAt
2654
+ assignedUserID Int?
2655
+ loanAmtApproved Int?
2656
+ sourceDomain String @db.VarChar(50)
2657
+ city String? @db.VarChar(100)
2658
+ remark String? @db.Text
2659
+ followupStatus String? @db.VarChar(50)
2660
+ selfie String? @db.VarChar(500)
2661
+ visitAddress String? @db.VarChar(255)
2662
+
2663
+ @@unique([leadID, sourceDomain], map: "uniq_lead_source")
2664
+ }
2665
+
2666
+
2667
+ enum fi_bucket {
2668
+ BUCKET_10_30 @map("10-30")
2669
+ BUCKET_31_60 @map("31-60")
2670
+ BUCKET_61_75 @map("61-75")
2671
+ BUCKET_76_90 @map("76-90")
2672
+ BUCKET_90_PLUS @map("90+")
2673
+ }
2674
+
2675
+
2676
+ model sms {
2677
+ id Int @id @default(autoincrement())
2678
+ leadID String @db.VarChar(50)
2679
+ customerID Int
2680
+ customerName String @db.VarChar(255)
2681
+ mobile String @db.VarChar(20)
2682
+ loanAmtApproved Decimal @db.Decimal(15,2)
2683
+ customerCity String? @db.VarChar(100)
2684
+ smsDate DateTime @db.Date
2685
+ smsTime DateTime @db.Time(0)
2686
+ sourceDomain String @db.VarChar(50)
2687
+ createdAt DateTime @default(now())
2688
+ }
2689
+
2690
+ enum fi_interactionStatus {
2691
+ INITIATED
2692
+ IN_PROCESS
2693
+ COMPLETED
2694
+ }
2695
+
2634
2696
  enum leads2_kfs {
2635
2697
  ZERO @map("0")
2636
2698
  ONE @map("1")