@timardex/cluemart-server-shared 4.0.3 → 4.0.5

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.
@@ -138,6 +138,8 @@ type SchemaAiImportedMarket = Omit<AiImportedMarket, "eventId" | "claimedByUserI
138
138
  deactivatedReason?: EnumImportedMarketDeactivationReason | null;
139
139
  /** sourceKey of an existing AI market this one may duplicate (soft flag). */
140
140
  duplicateHint?: string | null;
141
+ /** Fields still missing before the market can be approved. */
142
+ missingFields?: string[];
141
143
  };
142
144
  declare const AiImportedMarketModel: mongoose__default.Model<SchemaAiImportedMarket, {}, {}, {}, mongoose__default.Document<unknown, {}, SchemaAiImportedMarket, {}, {}> & Omit<AiImportedMarket, "eventId" | "claimedByUserId" | "reviewedByUserId"> & {
143
145
  eventId?: mongoose__default.Types.ObjectId;
@@ -157,6 +159,8 @@ declare const AiImportedMarketModel: mongoose__default.Model<SchemaAiImportedMar
157
159
  deactivatedReason?: EnumImportedMarketDeactivationReason | null;
158
160
  /** sourceKey of an existing AI market this one may duplicate (soft flag). */
159
161
  duplicateHint?: string | null;
162
+ /** Fields still missing before the market can be approved. */
163
+ missingFields?: string[];
160
164
  } & Required<{
161
165
  _id: string;
162
166
  }> & {
@@ -165,11 +169,16 @@ declare const AiImportedMarketModel: mongoose__default.Model<SchemaAiImportedMar
165
169
 
166
170
  type AiImportRunStatus = EnumAiImportRunStatus;
167
171
  type AiImportSiteResult = {
172
+ error?: string | null;
168
173
  errors: number;
169
174
  found: number;
170
175
  imported: number;
171
176
  name: string;
172
177
  skipped: number;
178
+ skipReasons?: Array<{
179
+ count: number;
180
+ reason: string;
181
+ }>;
173
182
  status: EnumAiImportRunStatus.SUCCESS | EnumAiImportRunStatus.ERROR;
174
183
  usage: AiImportUsage;
175
184
  url: string;
@@ -138,6 +138,8 @@ type SchemaAiImportedMarket = Omit<AiImportedMarket, "eventId" | "claimedByUserI
138
138
  deactivatedReason?: EnumImportedMarketDeactivationReason | null;
139
139
  /** sourceKey of an existing AI market this one may duplicate (soft flag). */
140
140
  duplicateHint?: string | null;
141
+ /** Fields still missing before the market can be approved. */
142
+ missingFields?: string[];
141
143
  };
142
144
  declare const AiImportedMarketModel: mongoose__default.Model<SchemaAiImportedMarket, {}, {}, {}, mongoose__default.Document<unknown, {}, SchemaAiImportedMarket, {}, {}> & Omit<AiImportedMarket, "eventId" | "claimedByUserId" | "reviewedByUserId"> & {
143
145
  eventId?: mongoose__default.Types.ObjectId;
@@ -157,6 +159,8 @@ declare const AiImportedMarketModel: mongoose__default.Model<SchemaAiImportedMar
157
159
  deactivatedReason?: EnumImportedMarketDeactivationReason | null;
158
160
  /** sourceKey of an existing AI market this one may duplicate (soft flag). */
159
161
  duplicateHint?: string | null;
162
+ /** Fields still missing before the market can be approved. */
163
+ missingFields?: string[];
160
164
  } & Required<{
161
165
  _id: string;
162
166
  }> & {
@@ -165,11 +169,16 @@ declare const AiImportedMarketModel: mongoose__default.Model<SchemaAiImportedMar
165
169
 
166
170
  type AiImportRunStatus = EnumAiImportRunStatus;
167
171
  type AiImportSiteResult = {
172
+ error?: string | null;
168
173
  errors: number;
169
174
  found: number;
170
175
  imported: number;
171
176
  name: string;
172
177
  skipped: number;
178
+ skipReasons?: Array<{
179
+ count: number;
180
+ reason: string;
181
+ }>;
173
182
  status: EnumAiImportRunStatus.SUCCESS | EnumAiImportRunStatus.ERROR;
174
183
  usage: AiImportUsage;
175
184
  url: string;
@@ -60,7 +60,7 @@ import {
60
60
  termsAgreementSchema,
61
61
  userLicenseSchema,
62
62
  vendorProductTypeSchema
63
- } from "../chunk-3ICI65FJ.mjs";
63
+ } from "../chunk-BT5MO7SZ.mjs";
64
64
  export {
65
65
  AD_BILLING_CATALOG_COLLECTION_NAME,
66
66
  AI_IMPORT_RUN_LOCK_KEY,
@@ -1148,7 +1148,7 @@ var addressComponentSchema2 = new MongooseSchema7(
1148
1148
  var schema8 = new MongooseSchema7(
1149
1149
  {
1150
1150
  active: { default: false, required: true, type: Boolean },
1151
- address: { required: true, type: String },
1151
+ address: { required: false, type: String },
1152
1152
  addressComponents: { required: false, type: [addressComponentSchema2] },
1153
1153
  approvedAt: { default: null, required: false, type: Date },
1154
1154
  claimed: { default: false, required: true, type: Boolean },
@@ -1186,11 +1186,12 @@ var schema8 = new MongooseSchema7(
1186
1186
  images: { required: false, type: [ResourceImageTypeSchema] },
1187
1187
  lastSeenAt: { default: null, required: false, type: Date },
1188
1188
  location: {
1189
- required: true,
1189
+ required: false,
1190
1190
  type: locationsSchema
1191
1191
  },
1192
1192
  logo: { required: false, type: ResourceImageTypeSchema },
1193
1193
  missedRuns: { default: 0, required: true, type: Number },
1194
+ missingFields: { required: false, type: [String] },
1194
1195
  name: { required: true, type: String },
1195
1196
  openingHours: { required: false, type: [String] },
1196
1197
  rainOrShine: { required: true, type: Boolean },
@@ -1260,11 +1261,25 @@ var usageSchema = new MongooseSchema8(
1260
1261
  );
1261
1262
  var siteResultSchema = new MongooseSchema8(
1262
1263
  {
1264
+ error: { required: false, type: String },
1263
1265
  errors: { default: 0, required: true, type: Number },
1264
1266
  found: { default: 0, required: true, type: Number },
1265
1267
  imported: { default: 0, required: true, type: Number },
1266
1268
  name: { required: true, type: String },
1267
1269
  skipped: { default: 0, required: true, type: Number },
1270
+ skipReasons: {
1271
+ default: void 0,
1272
+ required: false,
1273
+ type: [
1274
+ new MongooseSchema8(
1275
+ {
1276
+ count: { required: true, type: Number },
1277
+ reason: { required: true, type: String }
1278
+ },
1279
+ { _id: false }
1280
+ )
1281
+ ]
1282
+ },
1268
1283
  status: {
1269
1284
  enum: [import_cluemart_shared11.EnumAiImportRunStatus.SUCCESS, import_cluemart_shared11.EnumAiImportRunStatus.ERROR],
1270
1285
  required: true,
@@ -1819,7 +1834,6 @@ var schema15 = new MongooseSchema16(
1819
1834
  required: false,
1820
1835
  type: [String]
1821
1836
  },
1822
- isTester: { default: false, required: true, type: Boolean },
1823
1837
  lastName: { required: true, type: String },
1824
1838
  licences: {
1825
1839
  required: false,