/*
 * @Author: 赵伟
 * @Date: 2024-06-07 11:22:28
 * @Description: 接口返回的枚举值和共用的枚举值定义在这里
 */

// 公开还是私有 TabKey
export enum CommonTabKeys {
  Private = 'Private', // 私有
  Public = 'Public', // 公开
}

// 公开还是私有
export enum AvailableRange {
  Public = 1, // 公开
  Private = 0, // 私有
}

// 实验状态
export enum ExperimentStatus {
  Running = 'Running', // 运行中
  Succeeded = 'Succeeded', // 成功
  Pending = 'Pending', // 启动中
  Failed = 'Failed', // 失败
  Error = 'Error', // 错误
  Terminated = 'Terminated', // 终止
  Skipped = 'Skipped', // 跳过
  Omitted = 'Omitted', // 忽略
}

// TensorBoard 状态
export enum TensorBoardStatus {
  Unknown = 'Unknown', // 未知
  Pending = 'Pending', // 启动中
  Running = 'Running', // 运行中
  Terminated = 'Terminated', // 未启动或者已终止
  Failed = 'Failed', // 失败
}

// 镜像版本状态
export enum MirrorVersionStatus {
  Available = 'available', // 可用
  Building = 'building', // 构建中
  Failed = 'failed', // 构建中
}

// 服务运行状态
export enum ServiceRunStatus {
  Init = 'Init', // 启动中
  Running = 'Running', // 运行中
  Stopped = 'Stopped', // 已停止
  Failed = 'Failed', // 失败
  Pending = 'Pending', // 挂起中
}

// 服务运行状态选项列表
export const serviceStatusOptions = [
  { label: '启动中', value: ServiceRunStatus.Init },
  { label: '运行中', value: ServiceRunStatus.Running },
  { label: '已停止', value: ServiceRunStatus.Stopped },
  { label: '失败', value: ServiceRunStatus.Failed },
  { label: '挂起中', value: ServiceRunStatus.Pending },
];

// 开发环境编辑器状态
export enum DevEditorStatus {
  Pending = 'Pending', // 启动中
  Running = 'Running', // 运行中
  Terminated = 'Terminated', // 已终止
  Failed = 'Failed', // 失败
  Unknown = 'Unknown', // 未启动
}

export enum ServiceType {
  Video = 'video',
  Image = 'image',
  Audio = 'audio',
  Text = 'text',
}

export const serviceTypeOptions = [
  { label: '视频', value: ServiceType.Video },
  { label: '图片', value: ServiceType.Image },
  { label: '音频', value: ServiceType.Audio },
  { label: '文本', value: ServiceType.Text },
];
