@ozdao/prometheus-framework 0.2.118 → 0.2.120

Sign up to get free protection for your applications and to get access to all the features.
Files changed (175) hide show
  1. package/dist/community.server.js +1 -1
  2. package/dist/community.server.mjs +1 -1
  3. package/dist/events.server.js +1 -1
  4. package/dist/events.server.mjs +1 -1
  5. package/dist/gallery.server.js +13 -3
  6. package/dist/gallery.server.mjs +13 -3
  7. package/dist/main-DL3vRQCi.js +92 -0
  8. package/dist/main-Ds3Z5x5d.mjs +14206 -0
  9. package/dist/main.css +1 -1
  10. package/dist/orders.server.js +1 -1
  11. package/dist/orders.server.mjs +1 -1
  12. package/dist/organizations.server.js +1 -1
  13. package/dist/organizations.server.mjs +1 -1
  14. package/dist/products.server.js +1 -1
  15. package/dist/products.server.mjs +1 -1
  16. package/dist/prometheus-framework/src/components/Button/Button.vue.cjs +1 -1
  17. package/dist/prometheus-framework/src/components/Button/Button.vue.js +94 -1
  18. package/dist/prometheus-framework/src/components/Button/Button.vue2.cjs +1 -1
  19. package/dist/prometheus-framework/src/components/Button/Button.vue2.js +1 -94
  20. package/dist/prometheus-framework/src/components/DatePicker/Calendar.vue2.cjs +1 -1
  21. package/dist/prometheus-framework/src/components/DatePicker/Calendar.vue2.js +116 -117
  22. package/dist/prometheus-framework/src/components/Feed/Feed.vue.cjs +1 -1
  23. package/dist/prometheus-framework/src/components/Feed/Feed.vue.js +123 -109
  24. package/dist/prometheus-framework/src/components/Field/Field.vue.cjs +1 -1
  25. package/dist/prometheus-framework/src/components/Field/Field.vue.js +84 -1
  26. package/dist/prometheus-framework/src/components/Field/Field.vue2.cjs +1 -1
  27. package/dist/prometheus-framework/src/components/Field/Field.vue2.js +1 -84
  28. package/dist/prometheus-framework/src/components/FieldBig/FieldBig.vue.cjs +1 -1
  29. package/dist/prometheus-framework/src/components/FieldBig/FieldBig.vue.js +1 -1
  30. package/dist/prometheus-framework/src/components/FieldTags/BlockTags.vue.cjs +1 -1
  31. package/dist/prometheus-framework/src/components/FieldTags/BlockTags.vue.js +32 -26
  32. package/dist/prometheus-framework/src/components/Popup/Popup.vue.cjs +1 -1
  33. package/dist/prometheus-framework/src/components/Popup/Popup.vue.js +30 -26
  34. package/dist/prometheus-framework/src/modules/auth/components/layouts/Auth.vue.cjs +1 -1
  35. package/dist/prometheus-framework/src/modules/auth/components/layouts/Auth.vue.js +2 -2
  36. package/dist/prometheus-framework/src/modules/auth/components/pages/EnterCode.vue.cjs +1 -1
  37. package/dist/prometheus-framework/src/modules/auth/components/pages/EnterCode.vue.js +1 -1
  38. package/dist/prometheus-framework/src/modules/auth/components/pages/EnterPassword.vue.cjs +1 -1
  39. package/dist/prometheus-framework/src/modules/auth/components/pages/EnterPassword.vue.js +2 -2
  40. package/dist/prometheus-framework/src/modules/auth/components/pages/Invite.vue.cjs +1 -1
  41. package/dist/prometheus-framework/src/modules/auth/components/pages/Invite.vue.js +2 -2
  42. package/dist/prometheus-framework/src/modules/auth/components/pages/ResetPassword.vue.cjs +1 -1
  43. package/dist/prometheus-framework/src/modules/auth/components/pages/ResetPassword.vue.js +2 -2
  44. package/dist/prometheus-framework/src/modules/auth/components/pages/SignIn.vue.cjs +1 -1
  45. package/dist/prometheus-framework/src/modules/auth/components/pages/SignIn.vue.js +2 -2
  46. package/dist/prometheus-framework/src/modules/auth/components/pages/SignUp.vue.cjs +1 -1
  47. package/dist/prometheus-framework/src/modules/auth/components/pages/SignUp.vue.js +2 -2
  48. package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue.cjs +1 -1
  49. package/dist/prometheus-framework/src/modules/community/components/pages/Community.vue.js +2 -2
  50. package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.cjs +1 -1
  51. package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.js +2 -2
  52. package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.cjs +1 -1
  53. package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.js +16 -17
  54. package/dist/prometheus-framework/src/modules/constructor/components/elements/Embed.vue.cjs +1 -1
  55. package/dist/prometheus-framework/src/modules/constructor/components/elements/Embed.vue.js +1 -1
  56. package/dist/prometheus-framework/src/modules/events/components/elements/ButtonCheck.vue.cjs +1 -1
  57. package/dist/prometheus-framework/src/modules/events/components/elements/ButtonCheck.vue.js +1 -1
  58. package/dist/prometheus-framework/src/modules/events/components/elements/ButtonJoin.vue.cjs +1 -1
  59. package/dist/prometheus-framework/src/modules/events/components/elements/ButtonJoin.vue.js +1 -1
  60. package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.cjs +1 -1
  61. package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.js +2 -2
  62. package/dist/prometheus-framework/src/modules/events/components/pages/EditEventTickets.vue.cjs +1 -1
  63. package/dist/prometheus-framework/src/modules/events/components/pages/EditEventTickets.vue.js +2 -2
  64. package/dist/prometheus-framework/src/modules/events/components/pages/Events.vue.cjs +1 -1
  65. package/dist/prometheus-framework/src/modules/events/components/pages/Events.vue.js +44 -69
  66. package/dist/prometheus-framework/src/modules/gallery/components/blocks/PhotoViewer.vue.cjs +1 -0
  67. package/dist/prometheus-framework/src/modules/gallery/components/blocks/PhotoViewer.vue.js +64 -0
  68. package/dist/prometheus-framework/src/modules/gallery/components/blocks/PhotoViewer.vue2.cjs +1 -0
  69. package/dist/prometheus-framework/src/modules/gallery/components/blocks/PhotoViewer.vue2.js +1 -0
  70. package/dist/prometheus-framework/src/modules/gallery/components/pages/Gallery.vue.cjs +1 -1
  71. package/dist/prometheus-framework/src/modules/gallery/components/pages/Gallery.vue.js +101 -14
  72. package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.cjs +1 -1
  73. package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.js +166 -103
  74. package/dist/prometheus-framework/src/modules/globals/components/blocks/BlockSearch.vue.cjs +1 -1
  75. package/dist/prometheus-framework/src/modules/globals/components/blocks/BlockSearch.vue.js +1 -1
  76. package/dist/prometheus-framework/src/modules/globals/components/blocks/CardHeader.vue.cjs +1 -1
  77. package/dist/prometheus-framework/src/modules/globals/components/blocks/CardHeader.vue.js +2 -2
  78. package/dist/prometheus-framework/src/modules/globals/components/elements/ButtonDate.vue.cjs +1 -1
  79. package/dist/prometheus-framework/src/modules/globals/components/elements/ButtonDate.vue.js +38 -1
  80. package/dist/prometheus-framework/src/modules/globals/components/sections/SectionPageTitle.vue.cjs +1 -1
  81. package/dist/prometheus-framework/src/modules/globals/components/sections/SectionPageTitle.vue.js +3 -3
  82. package/dist/prometheus-framework/src/modules/globals/services/globals.store.cjs +1 -1
  83. package/dist/prometheus-framework/src/modules/globals/services/globals.store.js +21 -21
  84. package/dist/prometheus-framework/src/modules/icons/skeletons/SkeletonBlogpost.vue.cjs +1 -1
  85. package/dist/prometheus-framework/src/modules/icons/skeletons/SkeletonBlogpost.vue.js +3 -3
  86. package/dist/prometheus-framework/src/modules/icons/skeletons/SkeletonEvent.vue.cjs +1 -1
  87. package/dist/prometheus-framework/src/modules/icons/skeletons/SkeletonEvent.vue.js +1 -1
  88. package/dist/prometheus-framework/src/modules/icons/skeletons/SkeletonEventShort.vue.cjs +1 -1
  89. package/dist/prometheus-framework/src/modules/icons/skeletons/SkeletonEventShort.vue.js +5 -5
  90. package/dist/prometheus-framework/src/modules/icons/skeletons/SkeletonOrganization.vue.cjs +1 -1
  91. package/dist/prometheus-framework/src/modules/icons/skeletons/SkeletonOrganization.vue.js +1 -1
  92. package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.cjs +1 -1
  93. package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.js +2 -2
  94. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreateBackoffice.vue.cjs +1 -1
  95. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreateBackoffice.vue.js +2 -2
  96. package/dist/prometheus-framework/src/modules/orders/components/sections/FormAddCustomer.vue.cjs +1 -1
  97. package/dist/prometheus-framework/src/modules/orders/components/sections/FormAddCustomer.vue.js +2 -2
  98. package/dist/prometheus-framework/src/modules/orders/components/sections/FormCustomerDetails.vue.cjs +1 -1
  99. package/dist/prometheus-framework/src/modules/orders/components/sections/FormCustomerDetails.vue.js +1 -1
  100. package/dist/prometheus-framework/src/modules/orders/components/sections/FormDelivery.vue.cjs +1 -1
  101. package/dist/prometheus-framework/src/modules/orders/components/sections/FormDelivery.vue.js +1 -1
  102. package/dist/prometheus-framework/src/modules/organizations/components/elements/ButtonToggleMembership.vue.cjs +1 -1
  103. package/dist/prometheus-framework/src/modules/organizations/components/elements/ButtonToggleMembership.vue.js +1 -1
  104. package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.cjs +1 -1
  105. package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.js +2 -2
  106. package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.cjs +1 -1
  107. package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.js +2 -2
  108. package/dist/prometheus-framework/src/modules/organizations/components/sections/Documents.vue.cjs +1 -1
  109. package/dist/prometheus-framework/src/modules/organizations/components/sections/Documents.vue.js +2 -2
  110. package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.cjs +1 -1
  111. package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.js +2 -2
  112. package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.cjs +1 -1
  113. package/dist/prometheus-framework/src/modules/organizations/components/sections/Organizations.vue.js +2 -2
  114. package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.cjs +1 -1
  115. package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.js +1 -1
  116. package/dist/prometheus-framework/src/modules/products/components/blocks/LeftoverPositions.vue.cjs +1 -1
  117. package/dist/prometheus-framework/src/modules/products/components/blocks/LeftoverPositions.vue.js +1 -1
  118. package/dist/prometheus-framework/src/modules/products/components/blocks/ListPositions.vue.cjs +1 -1
  119. package/dist/prometheus-framework/src/modules/products/components/blocks/ListPositions.vue.js +1 -1
  120. package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.cjs +1 -1
  121. package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.js +1 -1
  122. package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.cjs +1 -1
  123. package/dist/prometheus-framework/src/modules/products/components/pages/CategoryEdit.vue.js +2 -2
  124. package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.cjs +1 -1
  125. package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.js +1 -1
  126. package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.cjs +1 -1
  127. package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.js +2 -2
  128. package/dist/prometheus-framework/src/modules/products/components/sections/EditModifications.vue.cjs +1 -1
  129. package/dist/prometheus-framework/src/modules/products/components/sections/EditModifications.vue.js +1 -1
  130. package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.cjs +1 -1
  131. package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.js +2 -2
  132. package/dist/prometheus-framework/src/modules/products/components/sections/FilterProducts.vue.cjs +1 -1
  133. package/dist/prometheus-framework/src/modules/products/components/sections/FilterProducts.vue.js +31 -32
  134. package/dist/prometheus-framework/src/modules/products/components/sections/SectionProduct.vue.cjs +1 -1
  135. package/dist/prometheus-framework/src/modules/products/components/sections/SectionProduct.vue.js +1 -1
  136. package/dist/prometheus-framework/src/modules/reports/components/sections/FormReport.vue.cjs +1 -1
  137. package/dist/prometheus-framework/src/modules/reports/components/sections/FormReport.vue.js +1 -1
  138. package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.cjs +1 -1
  139. package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.js +2 -2
  140. package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEdit.vue.cjs +1 -1
  141. package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEdit.vue.js +2 -2
  142. package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.cjs +1 -1
  143. package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.js +1 -1
  144. package/dist/prometheus-framework.cjs.js +1 -1
  145. package/dist/prometheus-framework.es.js +1 -1
  146. package/dist/queryProcessor-g8208K6g.mjs +178 -0
  147. package/dist/queryProcessor-haY_gPGg.js +177 -0
  148. package/dist/style.css +1 -1
  149. package/dist/wallet.server.js +1 -1
  150. package/dist/wallet.server.mjs +1 -1
  151. package/dist/web-B8tq3Fda.mjs +54 -0
  152. package/dist/web-ByJkgGrt.js +1 -0
  153. package/package.json +1 -1
  154. package/src/components/DatePicker/Calendar.vue +82 -55
  155. package/src/components/Feed/Feed.vue +45 -16
  156. package/src/components/FieldTags/BlockTags.vue +30 -23
  157. package/src/components/Popup/Popup.vue +2 -2
  158. package/src/modules/events/components/pages/Events.vue +2 -48
  159. package/src/modules/gallery/components/blocks/PhotoViewer.vue +115 -0
  160. package/src/modules/gallery/components/pages/Gallery.vue +103 -6
  161. package/src/modules/gallery/components/sections/BackofficeGallery.vue +100 -32
  162. package/src/modules/gallery/controllers/gallery.controller.js +45 -38
  163. package/src/modules/gallery/models/photo.model.js +4 -0
  164. package/src/modules/globals/components/blocks/CardHeader.vue +1 -1
  165. package/src/modules/globals/components/elements/ButtonDate.vue +37 -43
  166. package/src/modules/globals/components/layouts/Client.vue +1 -1
  167. package/src/modules/globals/components/sections/SectionPageTitle.vue +1 -1
  168. package/src/modules/globals/controllers/utils/queryProcessor.js +21 -2
  169. package/src/modules/globals/services/globals.store.js +13 -17
  170. package/src/modules/icons/skeletons/SkeletonBlogpost.vue +1 -1
  171. package/src/modules/icons/skeletons/SkeletonEvent.vue +1 -1
  172. package/src/modules/icons/skeletons/SkeletonEventShort.vue +1 -1
  173. package/src/modules/icons/skeletons/SkeletonOrganization.vue +1 -1
  174. package/src/modules/products/components/sections/FilterProducts.vue +2 -1
  175. package/src/modules/gallery/components/sections/GalleryWithCategories.vue +0 -176
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  const _commonjsHelpers = require("./_commonjsHelpers-DHfMLFPC.js");
3
3
  const require$$0 = require("mongoose");
4
- const queryProcessor$3 = require("./queryProcessor-DWf9tsis.js");
4
+ const queryProcessor$3 = require("./queryProcessor-haY_gPGg.js");
5
5
  require("util");
6
6
  require("uuid");
7
7
  const index = require("./index-BCCiEK_u.js");
@@ -1,6 +1,6 @@
1
1
  import { g as getDefaultExportFromCjs } from "./_commonjsHelpers-CUmg6egw.mjs";
2
2
  import require$$0 from "mongoose";
3
- import { q as queryProcessor$3 } from "./queryProcessor-BJoJAetd.mjs";
3
+ import { q as queryProcessor$3 } from "./queryProcessor-g8208K6g.mjs";
4
4
  import "util";
5
5
  import "uuid";
6
6
  import { s as server$1 } from "./index-B6a1mPgp.mjs";
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const _commonjsHelpers = require("./_commonjsHelpers-DHfMLFPC.js");
4
4
  const require$$0 = require("mongoose");
5
- const queryProcessor$2 = require("./queryProcessor-DWf9tsis.js");
5
+ const queryProcessor$2 = require("./queryProcessor-haY_gPGg.js");
6
6
  const metadata_schema = require("./metadata.schema-6slGhpQS.js");
7
7
  const require$$1 = require("stripe");
8
8
  const index = require("./index-BCCiEK_u.js");
@@ -1,6 +1,6 @@
1
1
  import { g as getDefaultExportFromCjs } from "./_commonjsHelpers-CUmg6egw.mjs";
2
2
  import require$$0 from "mongoose";
3
- import { q as queryProcessor$2 } from "./queryProcessor-BJoJAetd.mjs";
3
+ import { q as queryProcessor$2 } from "./queryProcessor-g8208K6g.mjs";
4
4
  import { s as seoFriendlyUrl, m as metadata_schema } from "./metadata.schema-CK5e2O3f.mjs";
5
5
  import require$$1 from "stripe";
6
6
  import { s as server$1 } from "./index-B6a1mPgp.mjs";
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  const _commonjsHelpers = require("./_commonjsHelpers-DHfMLFPC.js");
3
3
  const require$$0 = require("path");
4
- const queryProcessor = require("./queryProcessor-DWf9tsis.js");
4
+ const queryProcessor = require("./queryProcessor-haY_gPGg.js");
5
5
  const index = require("./index-BCCiEK_u.js");
6
6
  const common_schema = require("./common.schema-BFhpUXUt.js");
7
7
  const engagement_schema = require("./engagement.schema-fdLNO2_6.js");
@@ -11,10 +11,15 @@ const queryProcessorGlobals = queryProcessor.queryProcessor;
11
11
  const controllerFactory$1 = (db) => {
12
12
  const Photo = db.photo;
13
13
  const read = async (req, res) => {
14
+ console.log(req.query.tags);
14
15
  let stages = [
15
16
  ...queryProcessorGlobals.getBasicOptions(
16
17
  req.query
17
18
  ),
19
+ // Date Filter
20
+ ...queryProcessorGlobals.getFilterDate(req.query.dateStart, req.query.dateEnd),
21
+ // Tags
22
+ ...queryProcessorGlobals.getTagsOptions(req.query.tags),
18
23
  // For creator
19
24
  queryProcessorGlobals.getCreatorUserLookupStage(),
20
25
  queryProcessorGlobals.getCreatorOrganizationLookupStage(),
@@ -34,9 +39,9 @@ const controllerFactory$1 = (db) => {
34
39
  req.query.limit
35
40
  )
36
41
  ];
42
+ console.log(stages);
37
43
  try {
38
44
  const photos = await Photo.aggregate(stages);
39
- console.log(photos);
40
45
  if (!photos) {
41
46
  return res.status(404).send({ errorCode: "PHOTOS_NOT_FOUND", message: "Photos not found." });
42
47
  }
@@ -48,7 +53,7 @@ const controllerFactory$1 = (db) => {
48
53
  };
49
54
  const create = async (req, res) => {
50
55
  try {
51
- const { tags, creator, owner, images } = req.body;
56
+ const { tags, creator, owner, status, images } = req.body;
52
57
  if (!creator || !owner || !images || images.length === 0) {
53
58
  return res.status(400).send({ message: "All fields are required." });
54
59
  }
@@ -61,6 +66,7 @@ const controllerFactory$1 = (db) => {
61
66
  creator,
62
67
  owner,
63
68
  image,
69
+ status,
64
70
  cover: path.join(directory, "thumbnail_" + filename)
65
71
  // создаем путь для миниатюры
66
72
  };
@@ -147,6 +153,10 @@ var photo_model = (db) => {
147
153
  image: {
148
154
  type: String,
149
155
  required: true
156
+ },
157
+ createdAt: {
158
+ type: Date,
159
+ default: Date.now
150
160
  }
151
161
  }, {
152
162
  timestamps: {
@@ -1,6 +1,6 @@
1
1
  import { g as getDefaultExportFromCjs } from "./_commonjsHelpers-CUmg6egw.mjs";
2
2
  import require$$0 from "path";
3
- import { q as queryProcessor } from "./queryProcessor-BJoJAetd.mjs";
3
+ import { q as queryProcessor } from "./queryProcessor-g8208K6g.mjs";
4
4
  import { s as server } from "./index-B6a1mPgp.mjs";
5
5
  import { c as common_schema } from "./common.schema-ChBVARrs.mjs";
6
6
  import { e as engagement_schema } from "./engagement.schema-CI2ifjXN.mjs";
@@ -10,10 +10,15 @@ const queryProcessorGlobals = queryProcessor;
10
10
  const controllerFactory$1 = (db) => {
11
11
  const Photo = db.photo;
12
12
  const read = async (req, res) => {
13
+ console.log(req.query.tags);
13
14
  let stages = [
14
15
  ...queryProcessorGlobals.getBasicOptions(
15
16
  req.query
16
17
  ),
18
+ // Date Filter
19
+ ...queryProcessorGlobals.getFilterDate(req.query.dateStart, req.query.dateEnd),
20
+ // Tags
21
+ ...queryProcessorGlobals.getTagsOptions(req.query.tags),
17
22
  // For creator
18
23
  queryProcessorGlobals.getCreatorUserLookupStage(),
19
24
  queryProcessorGlobals.getCreatorOrganizationLookupStage(),
@@ -33,9 +38,9 @@ const controllerFactory$1 = (db) => {
33
38
  req.query.limit
34
39
  )
35
40
  ];
41
+ console.log(stages);
36
42
  try {
37
43
  const photos = await Photo.aggregate(stages);
38
- console.log(photos);
39
44
  if (!photos) {
40
45
  return res.status(404).send({ errorCode: "PHOTOS_NOT_FOUND", message: "Photos not found." });
41
46
  }
@@ -47,7 +52,7 @@ const controllerFactory$1 = (db) => {
47
52
  };
48
53
  const create = async (req, res) => {
49
54
  try {
50
- const { tags, creator, owner, images } = req.body;
55
+ const { tags, creator, owner, status, images } = req.body;
51
56
  if (!creator || !owner || !images || images.length === 0) {
52
57
  return res.status(400).send({ message: "All fields are required." });
53
58
  }
@@ -60,6 +65,7 @@ const controllerFactory$1 = (db) => {
60
65
  creator,
61
66
  owner,
62
67
  image,
68
+ status,
63
69
  cover: path.join(directory, "thumbnail_" + filename)
64
70
  // создаем путь для миниатюры
65
71
  };
@@ -146,6 +152,10 @@ var photo_model = (db) => {
146
152
  image: {
147
153
  type: String,
148
154
  required: true
155
+ },
156
+ createdAt: {
157
+ type: Date,
158
+ default: Date.now
149
159
  }
150
160
  }, {
151
161
  timestamps: {