the first commit
This commit is contained in:
19
src/app/models/category.model.ts
Normal file
19
src/app/models/category.model.ts
Normal file
@@ -0,0 +1,19 @@
|
||||
export interface Category {
|
||||
id: string;
|
||||
name: string;
|
||||
visible: boolean;
|
||||
priority: number;
|
||||
img?: string;
|
||||
projectId: string;
|
||||
subcategories?: Subcategory[];
|
||||
}
|
||||
|
||||
export interface Subcategory {
|
||||
id: string;
|
||||
name: string;
|
||||
visible: boolean;
|
||||
priority: number;
|
||||
img?: string;
|
||||
categoryId: string;
|
||||
itemCount?: number;
|
||||
}
|
||||
3
src/app/models/index.ts
Normal file
3
src/app/models/index.ts
Normal file
@@ -0,0 +1,3 @@
|
||||
export * from './project.model';
|
||||
export * from './category.model';
|
||||
export * from './item.model';
|
||||
35
src/app/models/item.model.ts
Normal file
35
src/app/models/item.model.ts
Normal file
@@ -0,0 +1,35 @@
|
||||
export interface Item {
|
||||
id: string;
|
||||
name: string;
|
||||
visible: boolean;
|
||||
priority: number;
|
||||
quantity: number;
|
||||
price: number;
|
||||
currency: string;
|
||||
imgs: string[];
|
||||
tags: string[];
|
||||
simpleDescription: string;
|
||||
description: ItemDescriptionField[];
|
||||
subcategoryId: string;
|
||||
comments?: Comment[];
|
||||
}
|
||||
|
||||
export interface ItemDescriptionField {
|
||||
key: string;
|
||||
value: string;
|
||||
}
|
||||
|
||||
export interface Comment {
|
||||
id: string;
|
||||
text: string;
|
||||
createdAt: Date;
|
||||
author?: string;
|
||||
}
|
||||
|
||||
export interface ItemsListResponse {
|
||||
items: Item[];
|
||||
total: number;
|
||||
page: number;
|
||||
limit: number;
|
||||
hasMore: boolean;
|
||||
}
|
||||
8
src/app/models/project.model.ts
Normal file
8
src/app/models/project.model.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
export interface Project {
|
||||
id: string;
|
||||
name: string;
|
||||
displayName: string;
|
||||
theme?: string;
|
||||
logoUrl?: string;
|
||||
active: boolean;
|
||||
}
|
||||
Reference in New Issue
Block a user