2023-03-17 15:13:37 +00:00
|
|
|
import { Ref } from 'vue';
|
|
|
|
|
|
|
|
export interface Dataset {
|
2023-06-22 15:20:04 +00:00
|
|
|
[key: string]:
|
|
|
|
| string
|
|
|
|
| Ref<string>
|
|
|
|
| boolean
|
|
|
|
| Array<Title>
|
|
|
|
| Array<Description>
|
|
|
|
| Array<Person>
|
|
|
|
| number
|
|
|
|
| (IErrorMessage | undefined)
|
|
|
|
| Coverage
|
2023-08-01 15:06:51 +00:00
|
|
|
| Array<DatasetReference>
|
2023-06-22 15:20:04 +00:00
|
|
|
| Array<File>;
|
|
|
|
language: Ref<string>;
|
|
|
|
// licenses: Array<number>;
|
|
|
|
rights: boolean;
|
|
|
|
type: string;
|
|
|
|
creating_corporation: string;
|
2023-03-17 15:13:37 +00:00
|
|
|
titles: Array<Title>;
|
|
|
|
descriptions: Array<Description>;
|
2023-03-24 10:41:52 +00:00
|
|
|
authors: Array<Person>;
|
|
|
|
contributors: Array<Person>;
|
|
|
|
project_id?: number;
|
2023-06-22 15:20:04 +00:00
|
|
|
embargo_date?: string;
|
|
|
|
coverage: Coverage;
|
2023-03-17 15:13:37 +00:00
|
|
|
errors?: IErrorMessage;
|
2023-06-22 15:20:04 +00:00
|
|
|
// async (user): Promise<void>;
|
|
|
|
subjects: Array<Subject>;
|
2023-08-01 15:06:51 +00:00
|
|
|
references: Array<DatasetReference>;
|
2023-06-22 15:20:04 +00:00
|
|
|
files: Array<TestFile> | undefined;
|
2023-06-16 14:44:28 +00:00
|
|
|
// upload: TethysFile
|
2023-06-01 12:29:56 +00:00
|
|
|
}
|
|
|
|
|
2023-06-16 14:44:28 +00:00
|
|
|
/** Provides information about files and allows JavaScript in a web page to access their content. */
|
|
|
|
export interface TestFile extends Blob {
|
|
|
|
readonly lastModified: number;
|
|
|
|
readonly name: string;
|
|
|
|
readonly webkitRelativePath: string;
|
2023-06-22 15:20:04 +00:00
|
|
|
label: string;
|
|
|
|
sorting: number;
|
2023-05-19 09:30:49 +00:00
|
|
|
}
|
|
|
|
|
2023-06-22 15:20:04 +00:00
|
|
|
// export interface TethysFile {
|
2023-06-16 14:44:28 +00:00
|
|
|
// label: string,
|
|
|
|
// sorting: number,
|
|
|
|
// upload: File,
|
|
|
|
// }
|
|
|
|
|
2023-05-19 09:30:49 +00:00
|
|
|
export interface Subject {
|
|
|
|
// id: number;
|
2023-06-22 15:20:04 +00:00
|
|
|
language: string;
|
|
|
|
type: string;
|
2023-05-19 09:30:49 +00:00
|
|
|
value: string;
|
2023-06-22 15:20:04 +00:00
|
|
|
external_key?: string;
|
2023-03-17 15:13:37 +00:00
|
|
|
}
|
2023-08-01 15:06:51 +00:00
|
|
|
export interface DatasetReference {
|
|
|
|
// id: number;
|
|
|
|
value: string;
|
|
|
|
label: string;
|
|
|
|
type: string;
|
|
|
|
relation: string;
|
|
|
|
}
|
2023-03-17 15:13:37 +00:00
|
|
|
|
|
|
|
export interface Title {
|
|
|
|
value: string;
|
|
|
|
type: string;
|
|
|
|
language: string | Ref<string>;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface Description {
|
|
|
|
value: string;
|
|
|
|
type: string;
|
|
|
|
language: string | Ref<string>;
|
|
|
|
}
|
|
|
|
|
2023-03-24 10:41:52 +00:00
|
|
|
export interface Person {
|
|
|
|
id: number;
|
|
|
|
name: string;
|
|
|
|
email: string;
|
|
|
|
name_type: string;
|
|
|
|
identifier_orcid: string;
|
|
|
|
datasetCount: string;
|
|
|
|
created_at: string;
|
|
|
|
}
|
|
|
|
|
2023-03-17 15:13:37 +00:00
|
|
|
interface IErrorMessage {
|
2023-06-22 15:20:04 +00:00
|
|
|
[key: string]: Array<string>;
|
2023-03-31 12:54:15 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
export interface Coverage {
|
2023-05-02 16:10:32 +00:00
|
|
|
x_min?: number;
|
|
|
|
y_min?: number;
|
|
|
|
x_max?: number;
|
|
|
|
y_max?: number;
|
2023-03-31 12:54:15 +00:00
|
|
|
elevation_min?: number;
|
|
|
|
elevation_max?: number;
|
|
|
|
elevation_absolut?: number;
|
|
|
|
|
|
|
|
depth_min?: number;
|
|
|
|
depth_max?: number;
|
|
|
|
depth_absolut?: number;
|
|
|
|
|
2023-06-22 15:20:04 +00:00
|
|
|
time_min?: number;
|
|
|
|
time_max?: number;
|
|
|
|
time_absolut?: number;
|
|
|
|
}
|