1
0
mirror of https://github.com/1Panel-dev/1Panel.git synced 2025-01-21 01:09:17 +08:00
2022-10-18 11:30:02 +08:00

110 lines
2.2 KiB
Go

import { ReqPage, CommonModel } from '.';
export namespace App {
export interface App extends CommonModel {
name: string;
icon: string;
key: string;
tags: Tag[];
shortDesc: string;
author: string;
source: string;
type: string;
}
export interface AppDTO extends App {
versions: string[];
}
export interface Tag {
key: string;
name: string;
}
export interface AppResPage {
total: number;
canUpdate: boolean;
version: string;
items: App.App[];
tags: App.Tag[];
}
export interface AppDetail extends CommonModel {
appId: string;
icon: string;
version: string;
readme: string;
params: AppParams;
dockerCompose: string;
}
export interface AppReq extends ReqPage {
name: string;
tags: string[];
}
export interface AppParams {
formFields: FromField[];
}
export interface FromField {
type: string;
labelZh: string;
labelEn: string;
required: boolean;
default: any;
envKey: string;
key?: string;
}
export interface AppInstall {
appDetailId: number;
params: any;
}
export interface AppInstalled extends CommonModel {
name: string;
appId: string;
appDetailId: string;
env: string;
status: string;
description: string;
message: string;
icon: string;
canUpdate: boolean;
app: App;
}
export interface AppInstalledOp {
installId: number;
operate: string;
backupId?: number;
detailId?: number;
}
export interface AppService {
label: string;
value: string;
}
export interface AppBackupReq extends ReqPage {
appInstallId: number;
}
export interface AppBackupDelReq {
ids: number[];
}
export interface AppBackup extends CommonModel {
name: string;
path: string;
appInstallId: string;
appDetail: AppDetail;
}
export interface VersionDetail {
version: string;
detailId: number;
}
}