@nkhang1902/strapi-plugin-export-import-clsx 1.2.7 → 1.2.9
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.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nkhang1902/strapi-plugin-export-import-clsx",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.9",
|
|
4
4
|
"description": "A powerful Strapi plugin for exporting and importing data with Excel support and advanced filtering",
|
|
5
5
|
"main": "./strapi-server.js",
|
|
6
6
|
"scripts": {
|
|
@@ -229,6 +229,12 @@ module.exports = ({ strapi }) => ({
|
|
|
229
229
|
"localizations",
|
|
230
230
|
"status",
|
|
231
231
|
"event",
|
|
232
|
+
"wishlistMeetingStats",
|
|
233
|
+
"checkedInEvents",
|
|
234
|
+
"checkedInMeetings",
|
|
235
|
+
"checkedInInvestors",
|
|
236
|
+
"checkedInVipGuests",
|
|
237
|
+
"checkedInCorporates",
|
|
232
238
|
];
|
|
233
239
|
const SHORTCUT_FIELDS = [
|
|
234
240
|
"email",
|
|
@@ -237,6 +243,9 @@ module.exports = ({ strapi }) => ({
|
|
|
237
243
|
"title",
|
|
238
244
|
"tickerCode",
|
|
239
245
|
];
|
|
246
|
+
const ALLOWED_JSONB_FIELDS = [
|
|
247
|
+
"meetingTypes",
|
|
248
|
+
];
|
|
240
249
|
|
|
241
250
|
for (const [contentType, entries] of Object.entries(data)) {
|
|
242
251
|
// Clean sheet name (Excel has restrictions)
|
|
@@ -293,7 +302,7 @@ module.exports = ({ strapi }) => ({
|
|
|
293
302
|
continue
|
|
294
303
|
}
|
|
295
304
|
if (SYSTEM_KEYS.includes(key)) continue;
|
|
296
|
-
if (customFields.includes(key)) continue;
|
|
305
|
+
if (customFields.includes(key) && !ALLOWED_JSONB_FIELDS.includes(key)) continue;
|
|
297
306
|
if ([...skipFields, "wishlist", "availableSlot"].includes(key))
|
|
298
307
|
continue;
|
|
299
308
|
|
|
@@ -305,11 +314,17 @@ module.exports = ({ strapi }) => ({
|
|
|
305
314
|
continue;
|
|
306
315
|
}
|
|
307
316
|
|
|
308
|
-
if (value
|
|
317
|
+
if (value !== null && typeof value !== "object") {
|
|
309
318
|
result[key] = value;
|
|
310
319
|
continue;
|
|
311
320
|
}
|
|
312
321
|
|
|
322
|
+
if (value !== null && typeof value === "object" && ALLOWED_JSONB_FIELDS.includes(key)) {
|
|
323
|
+
console.log(key, value)
|
|
324
|
+
result[key] = value.join("|");
|
|
325
|
+
continue;
|
|
326
|
+
}
|
|
327
|
+
|
|
313
328
|
if (!Array.isArray(value) && typeof value === "object") {
|
|
314
329
|
let temp = handleObject(key, value);
|
|
315
330
|
if (temp !== undefined) {
|