[SOLVED] Unable to submit the cartItems to my Database collection.
- 0
- Resolved
- Databases
- Functions
- Web
Hello, I have a function that allows logined-in user add items to cart, on add-to-cart click I want the Items to be submitted to the database collection I created. Ihis errors keeps coming up when I clicked on add-to-cart button.
Snip Error from the console: Add-To-Cart funtion: Function that create userItems in my Collection:
const promise = databases.createDocument('[DATABASE_ID]', '[COLLECTION_ID]', '[DOCUMENT_ID]', [DATA]);
Your create document function should be formatted like above. You're missing a parameter.
https://appwrite.io/docs/references/cloud/client-web/databases#createDocument
From the createUserItems function it shows I declared all the four params
This is what i was looking at
Since to me, this seems to be the function that is throwing the error for no data.
Thank you Kenny error resolved. I noticed I was not passing databaseId, documentId to my try block.
[SOLVED] Unable to submit the cartItems to my Database collection.
Recommended threads
- Bulk API limitations in self-hosted serv...
Environment: Appwrite Selfhost SDK: node-appwrite 28.0 Calling `upsertRows` (also applies to `createRows`/`updateRows`/`deleteRows`) with more than 100 rows fa...
- Android SDK: Kotlin null Value Not Updat...
Hi team, I think you should check the Android SDK implementation once, as it seems to have an issue handling Kotlin **null** values. For example: When I send:...
- IMPORTANT! SOC-2 Request Failing
Issue requesting SOC-2. If tried other/private browser as well as filling in optional fields.