Channel.ts 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. import { IStudio } from "../auth/StudioName";
  2. import { TRole } from "./Auth";
  3. export type TChannelType =
  4. | "translation"
  5. | "nissaya"
  6. | "original"
  7. | "wbw"
  8. | "commentary";
  9. export interface IChannelApiData {
  10. id: string;
  11. name: string;
  12. type?: TChannelType;
  13. }
  14. export interface ChannelInfoProps {
  15. channel: IChannelApiData;
  16. studio: IStudio;
  17. count?: number;
  18. }
  19. /**
  20. * 句子完成情况
  21. * [句子字符数,是否完成]
  22. *
  23. */
  24. export type IFinal = [number, boolean];
  25. export interface IApiResponseChannelData {
  26. uid: string;
  27. name: string;
  28. summary: string;
  29. type: TChannelType;
  30. studio: IStudio;
  31. lang: string;
  32. status: number;
  33. is_system: boolean;
  34. created_at: string;
  35. updated_at: string;
  36. role?: TRole;
  37. final?: IFinal[];
  38. content_created_at: string;
  39. content_updated_at: string;
  40. }
  41. export interface IApiResponseChannel {
  42. ok: boolean;
  43. message: string;
  44. data: IApiResponseChannelData;
  45. }
  46. export interface IApiResponseChannelList {
  47. ok: boolean;
  48. message: string;
  49. data: {
  50. rows: IApiResponseChannelData[];
  51. count: number;
  52. };
  53. }