
Security News
Risky Biz Podcast: Making Reachability Analysis Work in Real-World Codebases
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.
@zrpaplicacoes/strapi-plugin-import-export-entries
Advanced tools
This plugin helps you import and export data from and to your database in just few clicks.
This plugin helps you import and export data from and to your database in just few clicks.
Strapi v4 is required.
yarn add strapi-plugin-import-export-entries
or
npm i strapi-plugin-import-export-entries
Add in the file config/plugins.js
:
module.exports = ({ env }) => ({
//...
"import-export-entries": {
enabled: true,
},
//...
});
security
middleware:The security
middleware needs to be configured to enable the use of the great Monaco code editor.
In the file config/middlewares.js
, replace:
module.exports = [
//...
"strapi::security",
//...
];
with
module.exports = ({ env }) => ({
//...
{
name: "strapi::security",
config: {
contentSecurityPolicy: {
useDefaults: true,
directives: {
// Enable the download of the Monaco editor
// from cdn.jsdelivr.net.
"script-src": ["'self'", "cdn.jsdelivr.net", "blob:"],
upgradeInsecureRequests: null,
},
},
},
},
//...
});
New releases can introduce changes to the administration panel that require a rebuild. Rebuild the admin panel with one of the following commands:
yarn build --clean
or
npm run build --clean
Once the plugin is installed and setup, the functionnalities are accessible on the content management page of a collection.
Let's consider some data that represents yoga courses. We have a course
table where each course
refers to a beautiful_place
(stored in the beautiful_place
table).
Here we are importing the following 3 entries to the course
table.
"id","type","beautiful_place","description","name","createdAt","updatedAt","createdBy","updatedBy"
"1","vinyasa","{""id"":2,""name"":""Machu Picchu"",""description"":""The strength of the Incas with the chill of the alpacas."",""createdAt"":""2022-06-06T21:51:45.787Z"",""updatedAt"":""2022-06-06T21:51:45.787Z"",""locale"":""en""}","All you need is your mat and an Alpaca.","Alpaca Flow","2022-06-06T21:52:34.046Z","2022-06-06T21:52:34.046Z","{""id"":1,""firstname"":""Patrick"",""lastname"":""Beach"",""username"":null,""email"":""patrick.beach@yoga.com"",""password"":""$2a$10$iUGfsRyOQJ3h.mss2xwgmu42UBtOkLsyX8MxpCRAOlDSHq2/IZlRu"",""resetPasswordToken"":null,""registrationToken"":null,""isActive"":true,""blocked"":false,""preferedLanguage"":null,""createdAt"":""2022-05-23T19:16:33.057Z"",""updatedAt"":""2022-06-06T21:43:12.901Z""}","{""id"":1,""firstname"":""Patrick"",""lastname"":""Beach"",""username"":null,""email"":""patrick.beach@yoga.com"",""password"":""$2a$10$iUGfsRyOQJ3h.mss2xwgmu42UBtOkLsyX8MxpCRAOlDSHq2/IZlRu"",""resetPasswordToken"":null,""registrationToken"":null,""isActive"":true,""blocked"":false,""preferedLanguage"":null,""createdAt"":""2022-05-23T19:16:33.057Z"",""updatedAt"":""2022-06-06T21:43:12.901Z""}"
"2","ashtanga","{""id"":1,""name"":""Boracay White Beach"",""description"":""Sea, Stretch and Sun!"",""createdAt"":""2022-06-06T21:49:35.227Z"",""updatedAt"":""2022-06-06T21:53:56.648Z"",""locale"":""en""}","Head in the stars, feet in the sand.","Sun Salutation","2022-06-06T21:55:35.088Z","2022-06-06T21:55:35.088Z","{""id"":1,""firstname"":""Patrick"",""lastname"":""Beach"",""username"":null,""email"":""patrick.beach@yoga.com"",""password"":""$2a$10$iUGfsRyOQJ3h.mss2xwgmu42UBtOkLsyX8MxpCRAOlDSHq2/IZlRu"",""resetPasswordToken"":null,""registrationToken"":null,""isActive"":true,""blocked"":false,""preferedLanguage"":null,""createdAt"":""2022-05-23T19:16:33.057Z"",""updatedAt"":""2022-06-06T21:43:12.901Z""}","{""id"":1,""firstname"":""Patrick"",""lastname"":""Beach"",""username"":null,""email"":""patrick.beach@yoga.com"",""password"":""$2a$10$iUGfsRyOQJ3h.mss2xwgmu42UBtOkLsyX8MxpCRAOlDSHq2/IZlRu"",""resetPasswordToken"":null,""registrationToken"":null,""isActive"":true,""blocked"":false,""preferedLanguage"":null,""createdAt"":""2022-05-23T19:16:33.057Z"",""updatedAt"":""2022-06-06T21:43:12.901Z""}"
"3","vinyasa","{""id"":2,""name"":""Machu Picchu"",""description"":""The strength of the Incas with the chill of the alpacas."",""createdAt"":""2022-06-06T21:51:45.787Z"",""updatedAt"":""2022-06-06T21:51:45.787Z"",""locale"":""en""}","This place needs some serious renovation. Let's do it.","Inca Strength Journey","2022-06-06T21:58:39.571Z","2022-06-06T21:58:39.571Z","{""id"":1,""firstname"":""Patrick"",""lastname"":""Beach"",""username"":null,""email"":""patrick.beach@yoga.com"",""password"":""$2a$10$iUGfsRyOQJ3h.mss2xwgmu42UBtOkLsyX8MxpCRAOlDSHq2/IZlRu"",""resetPasswordToken"":null,""registrationToken"":null,""isActive"":true,""blocked"":false,""preferedLanguage"":null,""createdAt"":""2022-05-23T19:16:33.057Z"",""updatedAt"":""2022-06-06T21:43:12.901Z""}","{""id"":1,""firstname"":""Patrick"",""lastname"":""Beach"",""username"":null,""email"":""patrick.beach@yoga.com"",""password"":""$2a$10$iUGfsRyOQJ3h.mss2xwgmu42UBtOkLsyX8MxpCRAOlDSHq2/IZlRu"",""resetPasswordToken"":null,""registrationToken"":null,""isActive"":true,""blocked"":false,""preferedLanguage"":null,""createdAt"":""2022-05-23T19:16:33.057Z"",""updatedAt"":""2022-06-06T21:43:12.901Z""}"
Or the JSON equivalent:
[
{
"id": 1,
"type": "vinyasa",
"description": "All you need is your mat and an Alpaca.",
"name": "Alpaca Flow",
"createdAt": "2022-06-06T21:52:34.046Z",
"updatedAt": "2022-06-06T21:52:34.046Z",
"beautiful_place": {
"id": 2,
"name": "Machu Picchu",
"description": "The strength of the Incas with the chill of the alpacas.",
"createdAt": "2022-06-06T21:51:45.787Z",
"updatedAt": "2022-06-06T21:51:45.787Z",
"locale": "en"
},
"createdBy": {
"id": 1,
"firstname": "Patrick",
"lastname": "Beach",
"username": null,
"email": "patrick.beach@yoga.com",
"password": "$2a$10$iUGfsRyOQJ3h.mss2xwgmu42UBtOkLsyX8MxpCRAOlDSHq2/IZlRu",
"resetPasswordToken": null,
"registrationToken": null,
"isActive": true,
"blocked": false,
"preferedLanguage": null,
"createdAt": "2022-05-23T19:16:33.057Z",
"updatedAt": "2022-06-06T21:43:12.901Z"
},
"updatedBy": {
"id": 1,
"firstname": "Patrick",
"lastname": "Beach",
"username": null,
"email": "patrick.beach@yoga.com",
"password": "$2a$10$iUGfsRyOQJ3h.mss2xwgmu42UBtOkLsyX8MxpCRAOlDSHq2/IZlRu",
"resetPasswordToken": null,
"registrationToken": null,
"isActive": true,
"blocked": false,
"preferedLanguage": null,
"createdAt": "2022-05-23T19:16:33.057Z",
"updatedAt": "2022-06-06T21:43:12.901Z"
}
},
{
"id": 2,
"type": "ashtanga",
"description": "Head in the stars, feet in the sand.",
"name": "Sun Salutation",
"createdAt": "2022-06-06T21:55:35.088Z",
"updatedAt": "2022-06-06T21:55:35.088Z",
"beautiful_place": {
"id": 1,
"name": "Boracay White Beach",
"description": "Sea, Stretch and Sun!",
"createdAt": "2022-06-06T21:49:35.227Z",
"updatedAt": "2022-06-06T21:53:56.648Z",
"locale": "en"
},
"createdBy": {
"id": 1,
"firstname": "Patrick",
"lastname": "Beach",
"username": null,
"email": "patrick.beach@yoga.com",
"password": "$2a$10$iUGfsRyOQJ3h.mss2xwgmu42UBtOkLsyX8MxpCRAOlDSHq2/IZlRu",
"resetPasswordToken": null,
"registrationToken": null,
"isActive": true,
"blocked": false,
"preferedLanguage": null,
"createdAt": "2022-05-23T19:16:33.057Z",
"updatedAt": "2022-06-06T21:43:12.901Z"
},
"updatedBy": {
"id": 1,
"firstname": "Patrick",
"lastname": "Beach",
"username": null,
"email": "patrick.beach@yoga.com",
"password": "$2a$10$iUGfsRyOQJ3h.mss2xwgmu42UBtOkLsyX8MxpCRAOlDSHq2/IZlRu",
"resetPasswordToken": null,
"registrationToken": null,
"isActive": true,
"blocked": false,
"preferedLanguage": null,
"createdAt": "2022-05-23T19:16:33.057Z",
"updatedAt": "2022-06-06T21:43:12.901Z"
}
},
{
"id": 3,
"type": "vinyasa",
"description": "This place needs some serious renovation. Let's do it.",
"name": "Inca Strength Journey",
"createdAt": "2022-06-06T21:58:39.571Z",
"updatedAt": "2022-06-06T21:58:39.571Z",
"beautiful_place": 2,
"createdBy": {
"id": 1,
"firstname": "Patrick",
"lastname": "Beach",
"username": null,
"email": "patrick.beach@yoga.com",
"password": "$2a$10$iUGfsRyOQJ3h.mss2xwgmu42UBtOkLsyX8MxpCRAOlDSHq2/IZlRu",
"resetPasswordToken": null,
"registrationToken": null,
"isActive": true,
"blocked": false,
"preferedLanguage": null,
"createdAt": "2022-05-23T19:16:33.057Z",
"updatedAt": "2022-06-06T21:43:12.901Z"
},
"updatedBy": {
"id": 1,
"firstname": "Patrick",
"lastname": "Beach",
"username": null,
"email": "patrick.beach@yoga.com",
"password": "$2a$10$iUGfsRyOQJ3h.mss2xwgmu42UBtOkLsyX8MxpCRAOlDSHq2/IZlRu",
"resetPasswordToken": null,
"registrationToken": null,
"isActive": true,
"blocked": false,
"preferedLanguage": null,
"createdAt": "2022-05-23T19:16:33.057Z",
"updatedAt": "2022-06-06T21:43:12.901Z"
}
}
]
The import will produce the following result:
For the 1st entry:
beautiful_place
with id 2
. createdBy
and updatedBy
fields with the id of the user importing the data.course
with the right beautiful_place
id.For the 2nd entry: same process
For the 3rd entry:
beautiful_place
is a number. Since the relation already exists in db, the course
will be linked to the right beautiful_place
. If the number was referring to the id of a non existent beautiful_place
, the relation would fallback to null
.Baboo - @Baboo7
This plugin (and especially this README) took strong inspiration from the strapi-plugin-import-export-content from EdisonPeM.
FAQs
This plugin helps you import and export data from and to your database in just few clicks.
The npm package @zrpaplicacoes/strapi-plugin-import-export-entries receives a total of 16 weekly downloads. As such, @zrpaplicacoes/strapi-plugin-import-export-entries popularity was classified as not popular.
We found that @zrpaplicacoes/strapi-plugin-import-export-entries demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 6 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.
Security News
/Research
Malicious Nx npm versions stole secrets and wallet info using AI CLI tools; Socket’s AI scanner detected the supply chain attack and flagged the malware.
Security News
CISA’s 2025 draft SBOM guidance adds new fields like hashes, licenses, and tool metadata to make software inventories more actionable.