@nkhang1902/strapi-plugin-export-import-clsx 1.2.0 → 1.2.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.
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.1",
|
|
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": {
|
|
@@ -87,6 +87,9 @@ module.exports = ({ strapi }) => ({
|
|
|
87
87
|
};
|
|
88
88
|
|
|
89
89
|
workbook.SheetNames.forEach((sheetName) => {
|
|
90
|
+
if (targetContentType && mapSheetNameToContentType(sheetName) !== targetContentType) {
|
|
91
|
+
throw new Error(`Sheet name "${sheetName}" does not match target content type "${targetContentType.split(".")[1]}"`);
|
|
92
|
+
}
|
|
90
93
|
const worksheet = workbook.Sheets[sheetName];
|
|
91
94
|
const rows = XLSX.utils.sheet_to_json(worksheet);
|
|
92
95
|
|