refactor: refactor SCThingTypes from union-type to enum. SCThingType-type-attributes are now string-type-attributes.

This commit is contained in:
Michel Jonathan Schmitz
2018-12-05 18:51:28 +01:00
parent 641eff15b8
commit f9056eeb33
25 changed files with 134 additions and 192 deletions

View File

@@ -18,11 +18,9 @@ import {
SCThingWithCategoriesTranslatableProperties,
SCThingWithCategoriesWithoutReferences,
} from '../base/ThingWithCategories';
import {SCThingMeta} from '../Thing';
import {SCThingMeta, SCThingType} from '../Thing';
import {SCTranslations} from '../types/i18n';
export type SCBuildingType = 'building';
export type SCBuildingCategories =
'cafe'
| 'education'
@@ -55,10 +53,14 @@ export interface SCBuildingWithoutReferences
/**
* Type of the building
*/
type: SCBuildingType;
type: SCThingType.Building;
}
export interface SCBuilding extends SCBuildingWithoutReferences {
/**
* Type of the building
*/
type: SCThingType.Building;
}
/**