问题
Can I create multiple elements of the same type using Strapi and GraphQL? For example -
createMultipleFoo mutation(data: [
nameOfFoo: "ooaoaoa",
weightOfFoo: "aododo"
], ....)
回答1:
It's in the roadmap.
What you can do for now is create a custom endpoint ie. "createMulti". Send a json array, and use the "regular" create for each. Check out the discussion here.
Any questions post a comment
来源:https://stackoverflow.com/questions/63260467/can-i-create-multiple-elements-of-the-same-type-using-strapi-and-graphql