@creopse/utils 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (117) hide show
  1. package/README.md +1 -0
  2. package/dist/enums/account-status.d.ts +4 -0
  3. package/dist/enums/account-status.js +5 -0
  4. package/dist/enums/ad-content-type.d.ts +4 -0
  5. package/dist/enums/ad-content-type.js +5 -0
  6. package/dist/enums/auth-type.d.ts +8 -0
  7. package/dist/enums/auth-type.js +9 -0
  8. package/dist/enums/bool.d.ts +4 -0
  9. package/dist/enums/bool.js +5 -0
  10. package/dist/enums/content-type.d.ts +6 -0
  11. package/dist/enums/content-type.js +7 -0
  12. package/dist/enums/index.d.ts +16 -0
  13. package/dist/enums/index.js +16 -0
  14. package/dist/enums/media-file-type.d.ts +7 -0
  15. package/dist/enums/media-file-type.js +8 -0
  16. package/dist/enums/menu-item-target-type.d.ts +5 -0
  17. package/dist/enums/menu-item-target-type.js +6 -0
  18. package/dist/enums/news-article-status.d.ts +6 -0
  19. package/dist/enums/news-article-status.js +7 -0
  20. package/dist/enums/notification-source.d.ts +4 -0
  21. package/dist/enums/notification-source.js +5 -0
  22. package/dist/enums/notification-type.d.ts +3 -0
  23. package/dist/enums/notification-type.js +4 -0
  24. package/dist/enums/permalink-content-type.d.ts +6 -0
  25. package/dist/enums/permalink-content-type.js +7 -0
  26. package/dist/enums/profile-type.d.ts +3 -0
  27. package/dist/enums/profile-type.js +4 -0
  28. package/dist/enums/response-error-code.d.ts +18 -0
  29. package/dist/enums/response-error-code.js +20 -0
  30. package/dist/enums/user-role.d.ts +5 -0
  31. package/dist/enums/user-role.js +6 -0
  32. package/dist/enums/video-display-type.d.ts +4 -0
  33. package/dist/enums/video-display-type.js +5 -0
  34. package/dist/enums/video-item-source.d.ts +4 -0
  35. package/dist/enums/video-item-source.js +5 -0
  36. package/dist/index.d.ts +4 -0
  37. package/dist/index.js +4 -0
  38. package/dist/models/ad-identifier.d.ts +14 -0
  39. package/dist/models/ad-identifier.js +11 -0
  40. package/dist/models/ad.d.ts +21 -0
  41. package/dist/models/ad.js +16 -0
  42. package/dist/models/admin-profile.d.ts +7 -0
  43. package/dist/models/admin-profile.js +8 -0
  44. package/dist/models/app-information.d.ts +8 -0
  45. package/dist/models/app-information.js +9 -0
  46. package/dist/models/app-setting.d.ts +8 -0
  47. package/dist/models/app-setting.js +9 -0
  48. package/dist/models/content-model-item.d.ts +17 -0
  49. package/dist/models/content-model-item.js +12 -0
  50. package/dist/models/content-model.d.ts +18 -0
  51. package/dist/models/content-model.js +16 -0
  52. package/dist/models/index.d.ts +30 -0
  53. package/dist/models/index.js +30 -0
  54. package/dist/models/media-file.d.ts +23 -0
  55. package/dist/models/media-file.js +22 -0
  56. package/dist/models/menu-item-group.d.ts +8 -0
  57. package/dist/models/menu-item-group.js +9 -0
  58. package/dist/models/menu-item.d.ts +39 -0
  59. package/dist/models/menu-item.js +25 -0
  60. package/dist/models/menu-location.d.ts +8 -0
  61. package/dist/models/menu-location.js +9 -0
  62. package/dist/models/menu.d.ts +15 -0
  63. package/dist/models/menu.js +11 -0
  64. package/dist/models/news-article.d.ts +35 -0
  65. package/dist/models/news-article.js +23 -0
  66. package/dist/models/news-category.d.ts +20 -0
  67. package/dist/models/news-category.js +17 -0
  68. package/dist/models/news-comment.d.ts +18 -0
  69. package/dist/models/news-comment.js +15 -0
  70. package/dist/models/news-tag.d.ts +15 -0
  71. package/dist/models/news-tag.js +13 -0
  72. package/dist/models/newsletter-campaign.d.ts +17 -0
  73. package/dist/models/newsletter-campaign.js +13 -0
  74. package/dist/models/newsletter-email.d.ts +7 -0
  75. package/dist/models/newsletter-email.js +8 -0
  76. package/dist/models/newsletter-phone.d.ts +7 -0
  77. package/dist/models/newsletter-phone.js +8 -0
  78. package/dist/models/notification.d.ts +22 -0
  79. package/dist/models/notification.js +12 -0
  80. package/dist/models/page.d.ts +15 -0
  81. package/dist/models/page.js +15 -0
  82. package/dist/models/permalink.d.ts +14 -0
  83. package/dist/models/permalink.js +12 -0
  84. package/dist/models/permission.d.ts +9 -0
  85. package/dist/models/permission.js +10 -0
  86. package/dist/models/role.d.ts +11 -0
  87. package/dist/models/role.js +11 -0
  88. package/dist/models/section.d.ts +17 -0
  89. package/dist/models/section.js +12 -0
  90. package/dist/models/subscriber-profile.d.ts +7 -0
  91. package/dist/models/subscriber-profile.js +8 -0
  92. package/dist/models/user-session.d.ts +27 -0
  93. package/dist/models/user-session.js +12 -0
  94. package/dist/models/user.d.ts +36 -0
  95. package/dist/models/user.js +27 -0
  96. package/dist/models/video-item.d.ts +23 -0
  97. package/dist/models/video-item.js +22 -0
  98. package/dist/models/video-setting.d.ts +8 -0
  99. package/dist/models/video-setting.js +9 -0
  100. package/dist/tsconfig.tsbuildinfo +1 -0
  101. package/dist/types/app-information.d.ts +41 -0
  102. package/dist/types/app-information.js +1 -0
  103. package/dist/types/common.d.ts +11 -0
  104. package/dist/types/common.js +1 -0
  105. package/dist/types/index.d.ts +4 -0
  106. package/dist/types/index.js +4 -0
  107. package/dist/types/pagination.d.ts +26 -0
  108. package/dist/types/pagination.js +1 -0
  109. package/dist/types/props.d.ts +42 -0
  110. package/dist/types/props.js +1 -0
  111. package/dist/utils/chronos.d.ts +97 -0
  112. package/dist/utils/chronos.js +97 -0
  113. package/dist/utils/functions.d.ts +312 -0
  114. package/dist/utils/functions.js +574 -0
  115. package/dist/utils/index.d.ts +2 -0
  116. package/dist/utils/index.js +2 -0
  117. package/package.json +48 -0
@@ -0,0 +1,9 @@
1
+ export class MenuItemGroupModel {
2
+ constructor(name, description, id, createdAt, updatedAt) {
3
+ this.id = id;
4
+ this.name = name;
5
+ this.description = description;
6
+ this.createdAt = createdAt;
7
+ this.updatedAt = updatedAt;
8
+ }
9
+ }
@@ -0,0 +1,39 @@
1
+ import type { ContentType } from '../enums/content-type';
2
+ import { MenuItemTargetType } from '../enums/menu-item-target-type';
3
+ import type { ContentModelItemModel } from './content-model-item';
4
+ import { MenuModel } from './menu';
5
+ import { MenuItemGroupModel } from './menu-item-group';
6
+ import type { NewsArticleModel } from './news-article';
7
+ import type { NewsCategoryModel } from './news-category';
8
+ import type { NewsTagModel } from './news-tag';
9
+ import { PageModel } from './page';
10
+ import { SectionModel } from './section';
11
+ export declare class MenuItemModel {
12
+ id?: number;
13
+ menuId?: number;
14
+ pageId?: number;
15
+ sectionId?: number;
16
+ menuItemGroupId?: number;
17
+ title: string;
18
+ description?: string | null;
19
+ path?: string | null;
20
+ url?: string | null;
21
+ controller?: string | null;
22
+ parentId?: number | null;
23
+ position: number;
24
+ isActive: boolean;
25
+ isVisible: boolean;
26
+ color?: string;
27
+ icon?: string;
28
+ targetType: MenuItemTargetType;
29
+ contentType?: ContentType;
30
+ contentId?: number;
31
+ createdAt?: string;
32
+ updatedAt?: string;
33
+ menu?: MenuModel;
34
+ page?: PageModel;
35
+ section?: SectionModel;
36
+ group?: MenuItemGroupModel;
37
+ content?: ContentModelItemModel | NewsCategoryModel | NewsArticleModel | NewsTagModel;
38
+ constructor(title: string, position: number, targetType: MenuItemTargetType, isActive: boolean, isVisible: boolean, color?: string, icon?: string, description?: string | null, path?: string | null, url?: string | null, controller?: string | null, parentId?: number | null, menuId?: number, pageId?: number, sectionId?: number, menuItemGroupId?: number, contentType?: ContentType, contentId?: number, id?: number, createdAt?: string, updatedAt?: string);
39
+ }
@@ -0,0 +1,25 @@
1
+ export class MenuItemModel {
2
+ constructor(title, position, targetType, isActive, isVisible, color, icon, description, path, url, controller, parentId, menuId, pageId, sectionId, menuItemGroupId, contentType, contentId, id, createdAt, updatedAt) {
3
+ this.id = id;
4
+ this.menuItemGroupId = menuItemGroupId;
5
+ this.title = title;
6
+ this.description = description;
7
+ this.url = url;
8
+ this.path = path;
9
+ this.controller = controller;
10
+ this.parentId = parentId;
11
+ this.position = position;
12
+ this.targetType = targetType;
13
+ this.menuId = menuId;
14
+ this.pageId = pageId;
15
+ this.sectionId = sectionId;
16
+ this.isActive = isActive;
17
+ this.isVisible = isVisible;
18
+ this.color = color;
19
+ this.icon = icon;
20
+ this.contentType = contentType;
21
+ this.contentId = contentId;
22
+ this.createdAt = createdAt;
23
+ this.updatedAt = updatedAt;
24
+ }
25
+ }
@@ -0,0 +1,8 @@
1
+ export declare class MenuLocationModel {
2
+ id?: number;
3
+ name: string;
4
+ description?: string | null;
5
+ createdAt?: string;
6
+ updatedAt?: string;
7
+ constructor(name: string, description?: string | null, id?: number, createdAt?: string, updatedAt?: string);
8
+ }
@@ -0,0 +1,9 @@
1
+ export class MenuLocationModel {
2
+ constructor(name, description, id, createdAt, updatedAt) {
3
+ this.id = id;
4
+ this.name = name;
5
+ this.description = description;
6
+ this.createdAt = createdAt;
7
+ this.updatedAt = updatedAt;
8
+ }
9
+ }
@@ -0,0 +1,15 @@
1
+ import { MenuItemModel } from './menu-item';
2
+ import { MenuLocationModel } from './menu-location';
3
+ export declare class MenuModel {
4
+ id?: number;
5
+ menuLocationId?: number;
6
+ name: string;
7
+ title: string;
8
+ description?: string | null;
9
+ createdAt?: string;
10
+ updatedAt?: string;
11
+ items?: MenuItemModel[];
12
+ itemsCount?: number;
13
+ location?: MenuLocationModel;
14
+ constructor(name: string, title: string, menuLocationId?: number, description?: string | null, id?: number, createdAt?: string, updatedAt?: string);
15
+ }
@@ -0,0 +1,11 @@
1
+ export class MenuModel {
2
+ constructor(name, title, menuLocationId, description, id, createdAt, updatedAt) {
3
+ this.id = id;
4
+ this.name = name;
5
+ this.title = title;
6
+ this.menuLocationId = menuLocationId;
7
+ this.description = description;
8
+ this.createdAt = createdAt;
9
+ this.updatedAt = updatedAt;
10
+ }
11
+ }
@@ -0,0 +1,35 @@
1
+ import { NewsArticleStatus } from '../enums/news-article-status';
2
+ import { NewsCategoryModel } from './news-category';
3
+ import type { NewsCommentModel } from './news-comment';
4
+ import { NewsTagModel } from './news-tag';
5
+ import { UserModel } from './user';
6
+ export declare class NewsArticleModel {
7
+ id?: number;
8
+ foreignId?: number | null;
9
+ authorId?: number;
10
+ publisherId?: number;
11
+ title: string;
12
+ slug: string;
13
+ summary?: string | null;
14
+ content?: string | null;
15
+ featuredImage?: string | null;
16
+ featuredImageUrl?: string | null;
17
+ foreignFeaturedImage?: string | null;
18
+ legend?: string | null;
19
+ allowComments: boolean;
20
+ isHeadline: boolean;
21
+ status: NewsArticleStatus;
22
+ publishedAt?: string | null;
23
+ deletedAt?: string | null;
24
+ createdAt?: string;
25
+ updatedAt?: string;
26
+ author?: UserModel;
27
+ publisher?: UserModel;
28
+ categories?: NewsCategoryModel[];
29
+ categoriesCount?: number;
30
+ tags?: NewsTagModel[];
31
+ tagsCount?: number;
32
+ comments?: NewsCommentModel[];
33
+ commentsCount?: number;
34
+ constructor(title: string, slug: string, allowComments: boolean, isHeadline: boolean, status?: NewsArticleStatus, id?: number, foreignId?: number | null, authorId?: number, publisherId?: number, summary?: string | null, content?: string | null, featuredImage?: string | null, foreignFeaturedImage?: string | null, legend?: string | null, publishedAt?: string | null, deletedAt?: string | null, createdAt?: string, updatedAt?: string);
35
+ }
@@ -0,0 +1,23 @@
1
+ import { NewsArticleStatus } from '../enums/news-article-status';
2
+ export class NewsArticleModel {
3
+ constructor(title, slug, allowComments, isHeadline, status = NewsArticleStatus.PENDING, id, foreignId, authorId, publisherId, summary, content, featuredImage, foreignFeaturedImage, legend, publishedAt, deletedAt, createdAt, updatedAt) {
4
+ this.id = id;
5
+ this.foreignId = foreignId;
6
+ this.authorId = authorId;
7
+ this.publisherId = publisherId;
8
+ this.title = title;
9
+ this.slug = slug;
10
+ this.summary = summary;
11
+ this.content = content;
12
+ this.featuredImage = featuredImage;
13
+ this.foreignFeaturedImage = foreignFeaturedImage;
14
+ this.legend = legend;
15
+ this.allowComments = allowComments;
16
+ this.isHeadline = isHeadline;
17
+ this.status = status;
18
+ this.publishedAt = publishedAt;
19
+ this.deletedAt = deletedAt;
20
+ this.createdAt = createdAt;
21
+ this.updatedAt = updatedAt;
22
+ }
23
+ }
@@ -0,0 +1,20 @@
1
+ import { NewsArticleModel } from './news-article';
2
+ export declare class NewsCategoryModel {
3
+ id?: number;
4
+ foreignId?: number | null;
5
+ name: string;
6
+ slug?: string;
7
+ color?: string;
8
+ description?: string | null;
9
+ parentId?: number | null;
10
+ position?: number | null;
11
+ isActive: boolean;
12
+ image?: string | null;
13
+ imageUrl?: string | null;
14
+ deletedAt?: string | null;
15
+ createdAt?: string;
16
+ updatedAt?: string;
17
+ articles?: NewsArticleModel[];
18
+ articlesCount?: number;
19
+ constructor(name: string, isActive: boolean, id?: number, slug?: string, foreignId?: number | null, color?: string, description?: string | null, parentId?: number | null, position?: number | null, image?: string | null, deletedAt?: string | null, createdAt?: string, updatedAt?: string);
20
+ }
@@ -0,0 +1,17 @@
1
+ export class NewsCategoryModel {
2
+ constructor(name, isActive, id, slug, foreignId, color, description, parentId, position, image, deletedAt, createdAt, updatedAt) {
3
+ this.id = id;
4
+ this.foreignId = foreignId;
5
+ this.name = name;
6
+ this.slug = slug;
7
+ this.color = color;
8
+ this.description = description;
9
+ this.parentId = parentId;
10
+ this.position = position;
11
+ this.isActive = isActive;
12
+ this.image = image;
13
+ this.deletedAt = deletedAt;
14
+ this.createdAt = createdAt;
15
+ this.updatedAt = updatedAt;
16
+ }
17
+ }
@@ -0,0 +1,18 @@
1
+ import { NewsArticleModel } from './news-article';
2
+ import { UserModel } from './user';
3
+ export declare class NewsCommentModel {
4
+ id?: number;
5
+ foreignId?: number | null;
6
+ authorId?: number | null;
7
+ articleId?: number;
8
+ name?: string | null;
9
+ content: string;
10
+ email?: string | null;
11
+ isActive: boolean;
12
+ deletedAt?: string | null;
13
+ createdAt?: string;
14
+ updatedAt?: string;
15
+ author?: UserModel;
16
+ article?: NewsArticleModel;
17
+ constructor(content: string, isActive: boolean, id?: number, articleId?: number, foreignId?: number | null, authorId?: number | null, name?: string | null, email?: string | null, deletedAt?: string | null, createdAt?: string, updatedAt?: string);
18
+ }
@@ -0,0 +1,15 @@
1
+ export class NewsCommentModel {
2
+ constructor(content, isActive, id, articleId, foreignId, authorId, name, email, deletedAt, createdAt, updatedAt) {
3
+ this.id = id;
4
+ this.foreignId = foreignId;
5
+ this.authorId = authorId;
6
+ this.articleId = articleId;
7
+ this.name = name;
8
+ this.content = content;
9
+ this.email = email;
10
+ this.isActive = isActive;
11
+ this.deletedAt = deletedAt;
12
+ this.createdAt = createdAt;
13
+ this.updatedAt = updatedAt;
14
+ }
15
+ }
@@ -0,0 +1,15 @@
1
+ import { NewsArticleModel } from './news-article';
2
+ export declare class NewsTagModel {
3
+ id?: number;
4
+ foreignId?: number | null;
5
+ name: string;
6
+ description?: string | null;
7
+ slug?: string;
8
+ isActive: boolean;
9
+ deletedAt?: string | null;
10
+ createdAt?: string;
11
+ updatedAt?: string;
12
+ articles?: NewsArticleModel[];
13
+ articlesCount?: number;
14
+ constructor(name: string, isActive: boolean, id?: number, slug?: string, foreignId?: number | null, description?: string | null, deletedAt?: string | null, createdAt?: string, updatedAt?: string);
15
+ }
@@ -0,0 +1,13 @@
1
+ export class NewsTagModel {
2
+ constructor(name, isActive, id, slug, foreignId, description, deletedAt, createdAt, updatedAt) {
3
+ this.id = id;
4
+ this.foreignId = foreignId;
5
+ this.name = name;
6
+ this.description = description;
7
+ this.slug = slug;
8
+ this.isActive = isActive;
9
+ this.deletedAt = deletedAt;
10
+ this.createdAt = createdAt;
11
+ this.updatedAt = updatedAt;
12
+ }
13
+ }
@@ -0,0 +1,17 @@
1
+ export interface NewsletterCampaignHistory {
2
+ id: string;
3
+ date: string;
4
+ report: string;
5
+ }
6
+ export declare class NewsletterCampaignModel {
7
+ id?: number;
8
+ title: string;
9
+ subject: string;
10
+ content: string;
11
+ rawContent: string;
12
+ recipients: string[];
13
+ history?: NewsletterCampaignHistory[] | null;
14
+ createdAt?: string;
15
+ updatedAt?: string;
16
+ constructor(title: string, subject: string, content: string, rawContent: string, recipients: string[], history?: NewsletterCampaignHistory[] | null, id?: number, createdAt?: string, updatedAt?: string);
17
+ }
@@ -0,0 +1,13 @@
1
+ export class NewsletterCampaignModel {
2
+ constructor(title, subject, content, rawContent, recipients, history, id, createdAt, updatedAt) {
3
+ this.title = title;
4
+ this.subject = subject;
5
+ this.content = content;
6
+ this.rawContent = rawContent;
7
+ this.recipients = recipients;
8
+ this.history = history;
9
+ this.id = id;
10
+ this.createdAt = createdAt;
11
+ this.updatedAt = updatedAt;
12
+ }
13
+ }
@@ -0,0 +1,7 @@
1
+ export declare class NewsletterEmailModel {
2
+ id?: number;
3
+ email: string;
4
+ createdAt?: string;
5
+ updatedAt?: string;
6
+ constructor(email: string, id?: number, createdAt?: string, updatedAt?: string);
7
+ }
@@ -0,0 +1,8 @@
1
+ export class NewsletterEmailModel {
2
+ constructor(email, id, createdAt, updatedAt) {
3
+ this.email = email;
4
+ this.id = id;
5
+ this.createdAt = createdAt;
6
+ this.updatedAt = updatedAt;
7
+ }
8
+ }
@@ -0,0 +1,7 @@
1
+ export declare class NewsletterPhoneModel {
2
+ id?: number;
3
+ phone: string;
4
+ createdAt?: string;
5
+ updatedAt?: string;
6
+ constructor(phone: string, id?: number, createdAt?: string, updatedAt?: string);
7
+ }
@@ -0,0 +1,8 @@
1
+ export class NewsletterPhoneModel {
2
+ constructor(phone, id, createdAt, updatedAt) {
3
+ this.phone = phone;
4
+ this.id = id;
5
+ this.createdAt = createdAt;
6
+ this.updatedAt = updatedAt;
7
+ }
8
+ }
@@ -0,0 +1,22 @@
1
+ import { NotificationSource } from '../enums/notification-source';
2
+ import { NotificationType } from '../enums/notification-type';
3
+ export interface NotificationData {
4
+ title: string;
5
+ content: string;
6
+ params: any[];
7
+ triggeredBy: string;
8
+ source: NotificationSource;
9
+ target: string;
10
+ removable: boolean;
11
+ }
12
+ export declare class NotificationModel {
13
+ id?: string;
14
+ type: NotificationType;
15
+ notifiableId: number;
16
+ notifiableType: string;
17
+ data: NotificationData;
18
+ readAt?: string;
19
+ createdAt?: string;
20
+ updatedAt?: string;
21
+ constructor(type: NotificationType, notifiableId: number, notifiableType: string, data: NotificationData, id?: string, readAt?: string, createdAt?: string, updatedAt?: string);
22
+ }
@@ -0,0 +1,12 @@
1
+ export class NotificationModel {
2
+ constructor(type, notifiableId, notifiableType, data, id, readAt, createdAt, updatedAt) {
3
+ this.id = id;
4
+ this.type = type;
5
+ this.notifiableId = notifiableId;
6
+ this.notifiableType = notifiableType;
7
+ this.data = data;
8
+ this.readAt = readAt;
9
+ this.createdAt = createdAt;
10
+ this.updatedAt = updatedAt;
11
+ }
12
+ }
@@ -0,0 +1,15 @@
1
+ import { SectionModel } from './section';
2
+ export declare class PageModel {
3
+ name: string;
4
+ title: string;
5
+ slug: string;
6
+ content: string | null;
7
+ sectionsData?: any | null;
8
+ sectionsOrder?: string[] | null;
9
+ sectionsDisabled?: string[] | null;
10
+ sections?: SectionModel[];
11
+ id?: number;
12
+ createdAt?: string;
13
+ updatedAt?: string;
14
+ constructor(name: string, title: string, slug: string, content: string | null, sectionsData?: any | null, sectionsOrder?: string[] | null, sectionsDisabled?: string[] | null, sections?: SectionModel[], id?: number, createdAt?: string, updatedAt?: string);
15
+ }
@@ -0,0 +1,15 @@
1
+ export class PageModel {
2
+ constructor(name, title, slug, content, sectionsData, sectionsOrder, sectionsDisabled, sections, id, createdAt, updatedAt) {
3
+ this.id = id;
4
+ this.name = name;
5
+ this.title = title;
6
+ this.slug = slug;
7
+ this.content = content;
8
+ this.sectionsData = sectionsData;
9
+ this.sectionsOrder = sectionsOrder;
10
+ this.sectionsDisabled = sectionsDisabled;
11
+ this.sections = sections;
12
+ this.createdAt = createdAt;
13
+ this.updatedAt = updatedAt;
14
+ }
15
+ }
@@ -0,0 +1,14 @@
1
+ import type { PermalinkContentType } from '../enums/permalink-content-type';
2
+ import type { PageModel } from './page';
3
+ export declare class PermalinkModel {
4
+ id?: number;
5
+ pathPrefix: string;
6
+ contentType?: PermalinkContentType | null;
7
+ contentParam?: string | null;
8
+ contentId?: number | null;
9
+ pageId?: number | null;
10
+ createdAt?: string;
11
+ updatedAt?: string;
12
+ page?: PageModel;
13
+ constructor(pathPrefix: string, contentType?: PermalinkContentType | null, contentParam?: string | null, contentId?: number | null, pageId?: number | null, id?: number, createdAt?: string, updatedAt?: string);
14
+ }
@@ -0,0 +1,12 @@
1
+ export class PermalinkModel {
2
+ constructor(pathPrefix, contentType, contentParam, contentId, pageId, id, createdAt, updatedAt) {
3
+ this.id = id;
4
+ this.pathPrefix = pathPrefix;
5
+ this.contentType = contentType;
6
+ this.contentParam = contentParam;
7
+ this.contentId = contentId;
8
+ this.pageId = pageId;
9
+ this.createdAt = createdAt;
10
+ this.updatedAt = updatedAt;
11
+ }
12
+ }
@@ -0,0 +1,9 @@
1
+ export declare class PermissionModel {
2
+ id?: number;
3
+ name: string;
4
+ displayName: string;
5
+ description: string;
6
+ createdAt?: string;
7
+ updatedAt?: string;
8
+ constructor(name: string, displayName: string, description: string, id?: number, createdAt?: string, updatedAt?: string);
9
+ }
@@ -0,0 +1,10 @@
1
+ export class PermissionModel {
2
+ constructor(name, displayName, description, id, createdAt, updatedAt) {
3
+ this.name = name;
4
+ this.displayName = displayName;
5
+ this.description = description;
6
+ this.id = id;
7
+ this.createdAt = createdAt;
8
+ this.updatedAt = updatedAt;
9
+ }
10
+ }
@@ -0,0 +1,11 @@
1
+ import { PermissionModel } from './permission';
2
+ export declare class RoleModel {
3
+ id?: number;
4
+ name: string;
5
+ displayName: string;
6
+ description: string;
7
+ permissions?: PermissionModel[];
8
+ createdAt?: string;
9
+ updatedAt?: string;
10
+ constructor(name: string, displayName: string, description: string, permissions?: PermissionModel[], id?: number, createdAt?: string, updatedAt?: string);
11
+ }
@@ -0,0 +1,11 @@
1
+ export class RoleModel {
2
+ constructor(name, displayName, description, permissions, id, createdAt, updatedAt) {
3
+ this.name = name;
4
+ this.displayName = displayName;
5
+ this.description = description;
6
+ this.permissions = permissions;
7
+ this.id = id;
8
+ this.createdAt = createdAt;
9
+ this.updatedAt = updatedAt;
10
+ }
11
+ }
@@ -0,0 +1,17 @@
1
+ import { PageModel } from './page';
2
+ export declare class SectionModel {
3
+ id?: number;
4
+ name: string;
5
+ title: string;
6
+ slug: string;
7
+ content?: string | null;
8
+ dataStructure?: any | null;
9
+ createdAt?: string;
10
+ updatedAt?: string;
11
+ pages?: PageModel[];
12
+ pagesCount?: number;
13
+ dataSourcePageId?: number | null;
14
+ dataSourcePageTitle?: string | null;
15
+ dataSourcePageSectionsData?: any;
16
+ constructor(name: string, slug: string, title: string, content?: string | null, dataStructure?: any | null, id?: number, createdAt?: string, updatedAt?: string);
17
+ }
@@ -0,0 +1,12 @@
1
+ export class SectionModel {
2
+ constructor(name, slug, title, content, dataStructure, id, createdAt, updatedAt) {
3
+ this.id = id;
4
+ this.name = name;
5
+ this.slug = slug;
6
+ this.title = title;
7
+ this.content = content;
8
+ this.dataStructure = dataStructure;
9
+ this.createdAt = createdAt;
10
+ this.updatedAt = updatedAt;
11
+ }
12
+ }
@@ -0,0 +1,7 @@
1
+ export declare class SubscriberProfileModel {
2
+ id?: number;
3
+ userId: number;
4
+ createdAt?: string;
5
+ updatedAt?: string;
6
+ constructor(userId: number, id?: number, createdAt?: string, updatedAt?: string);
7
+ }
@@ -0,0 +1,8 @@
1
+ export class SubscriberProfileModel {
2
+ constructor(userId, id, createdAt, updatedAt) {
3
+ this.id = id;
4
+ this.userId = userId;
5
+ this.createdAt = createdAt;
6
+ this.updatedAt = updatedAt;
7
+ }
8
+ }
@@ -0,0 +1,27 @@
1
+ import { UserModel } from './user';
2
+ interface LocationData {
3
+ ip: string;
4
+ iso?: string;
5
+ city?: string;
6
+ region?: string;
7
+ source?: string;
8
+ country?: string;
9
+ currency?: string;
10
+ latitude?: string;
11
+ timezone?: string;
12
+ continent?: string;
13
+ longitude?: string;
14
+ }
15
+ export declare class UserSessionModel {
16
+ id?: number;
17
+ userId?: number;
18
+ ipAddress: string;
19
+ userAgent: string;
20
+ locationData?: LocationData;
21
+ lastActivity: string;
22
+ createdAt?: string;
23
+ updatedAt?: string;
24
+ user?: UserModel;
25
+ constructor(ipAddress: string, userAgent: string, lastActivity: string, id?: number, userId?: number, locationData?: LocationData, createdAt?: string, updatedAt?: string);
26
+ }
27
+ export {};
@@ -0,0 +1,12 @@
1
+ export class UserSessionModel {
2
+ constructor(ipAddress, userAgent, lastActivity, id, userId, locationData, createdAt, updatedAt) {
3
+ this.id = id;
4
+ this.userId = userId;
5
+ this.locationData = locationData;
6
+ this.ipAddress = ipAddress;
7
+ this.userAgent = userAgent;
8
+ this.lastActivity = lastActivity;
9
+ this.createdAt = createdAt;
10
+ this.updatedAt = updatedAt;
11
+ }
12
+ }
@@ -0,0 +1,36 @@
1
+ import type { Coords } from '../types';
2
+ import { AccountStatus } from '../enums/account-status';
3
+ import { AuthType } from '../enums/auth-type';
4
+ import { ProfileType } from '../enums/profile-type';
5
+ import { PermissionModel } from './permission';
6
+ import { RoleModel } from './role';
7
+ import { SubscriberProfileModel } from './subscriber-profile';
8
+ export declare class UserModel {
9
+ id?: number;
10
+ uid?: string;
11
+ avatar: string;
12
+ avatarUrl: string;
13
+ fullname: string;
14
+ lastname: string;
15
+ firstname: string;
16
+ email: string;
17
+ emailVerifiedAt?: string;
18
+ password: string;
19
+ phone?: string;
20
+ address?: string;
21
+ location?: Coords | null;
22
+ profileType: ProfileType;
23
+ profileId: number;
24
+ accountStatus: AccountStatus;
25
+ preferences?: any;
26
+ authType?: AuthType;
27
+ lastLoggedInAt?: string;
28
+ rememberToken?: string;
29
+ deletedAt?: string;
30
+ createdAt?: string;
31
+ updatedAt?: string;
32
+ permissions?: PermissionModel[];
33
+ profile?: SubscriberProfileModel;
34
+ roles?: RoleModel[];
35
+ constructor(avatar: string, avatarUrl: string, fullname: string, lastname: string, firstname: string, email: string, password: string, profileType: ProfileType, profileId: number, accountStatus: AccountStatus, id?: number, uid?: string, emailVerifiedAt?: string, phone?: string, address?: string, location?: Coords | null, preferences?: any, authType?: AuthType, lastLoggedInAt?: string, rememberToken?: string, deletedAt?: string, createdAt?: string, updatedAt?: string);
36
+ }