mirror of
https://gitlab.com/openstapps/openstapps.git
synced 2026-01-19 16:13:06 +00:00
@@ -75,7 +75,7 @@ export interface SCThing {
|
||||
/**
|
||||
* Origin of the thing
|
||||
*/
|
||||
origin: SCThingOrigin;
|
||||
origin: SCThingRemoteOrigin | SCThingUserOrigin;
|
||||
/**
|
||||
* Translations of specific values of the object
|
||||
*
|
||||
@@ -96,15 +96,12 @@ export interface SCThing {
|
||||
url?: string;
|
||||
}
|
||||
|
||||
export type SCThingOriginType = 'remote' | 'user';
|
||||
|
||||
/**
|
||||
* Origin of a thing
|
||||
*/
|
||||
export interface SCThingOrigin {
|
||||
/**
|
||||
* When the thing was indexed last from the origin
|
||||
*/
|
||||
indexed: SCISO8601Date;
|
||||
|
||||
/**
|
||||
* Maintainer of the origin
|
||||
*
|
||||
@@ -117,6 +114,21 @@ export interface SCThingOrigin {
|
||||
*/
|
||||
modified?: SCISO8601Date;
|
||||
|
||||
/**
|
||||
* Type of the origin
|
||||
*/
|
||||
type: SCThingOriginType;
|
||||
}
|
||||
|
||||
/**
|
||||
* Remote origin of a thing
|
||||
*/
|
||||
export interface SCThingRemoteOrigin extends SCThingOrigin {
|
||||
/**
|
||||
* When the thing was indexed last from the origin
|
||||
*/
|
||||
indexed: SCISO8601Date;
|
||||
|
||||
/**
|
||||
* Name of the origin
|
||||
*/
|
||||
@@ -134,12 +146,42 @@ export interface SCThingOrigin {
|
||||
*/
|
||||
responsibleEntity?: SCPerson | SCOrganization;
|
||||
|
||||
/**
|
||||
* Type of the origin
|
||||
*/
|
||||
type: 'remote';
|
||||
|
||||
/**
|
||||
* Main URL of the origin
|
||||
*/
|
||||
url?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* User origin of a thing (data created through user interaction)
|
||||
*/
|
||||
export interface SCThingUserOrigin extends SCThingOrigin {
|
||||
/**
|
||||
* When the thing was created
|
||||
*/
|
||||
created: SCISO8601Date;
|
||||
|
||||
/**
|
||||
* If it is deleted or not, defaults to false
|
||||
*/
|
||||
deleted?: boolean;
|
||||
|
||||
/**
|
||||
* Type of the origin
|
||||
*/
|
||||
type: 'user';
|
||||
|
||||
/**
|
||||
* When the saved thing was last updated with the latest state (e.g. from the backend)
|
||||
*/
|
||||
updated?: SCISO8601Date;
|
||||
}
|
||||
|
||||
/**
|
||||
* Meta information about things
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user