channel.prisma 1.3 KB

12345678910111213141516171819202122232425262728
  1. model Channel {
  2. id String @id @map("_id") @default(auto()) @db.ObjectId
  3. channelId String @unique
  4. name String // 渠道名称
  5. landingUrl String // 最新网址
  6. videoCdn String? // 视频CDN
  7. coverCdn String? // 封面CDN
  8. clientName String? // 客户端名称
  9. clientNotice String? // 客户端公告
  10. remark String? // 备注
  11. isDefault Boolean @default(false) // 默认渠道
  12. // epoch seconds stored as BigInt
  13. createAt BigInt @default(0) // 创建时间 (秒)
  14. updateAt BigInt @default(0) // 更新时间 (秒)
  15. // Channel enabled categories (UI: 片库分类 - category selection)
  16. categories Json? // Array of { id, name }
  17. // Homepage recommended tags (UI: 首页推荐)
  18. tags Json? // Array of { id, name }
  19. // Denormalized names derived from tags[].name (trimmed) for quick query/display
  20. tagNames String[] // Array of tag names
  21. @@index([isDefault])
  22. @@map("channel")
  23. }