Here's your translated question for the Retool forum:
Our service manages some data by uploading metadata.json
to Amazon S3. To make this process more convenient, we are using Retool's S3 Resource Query to modify the data. The process of retrieving data works without any issues.
We have set it up so that when we upload a file with the same name as an existing one, it overwrites metadata.json
. However, the Upload Data step is not working correctly, and we are seeking advice on resolving this issue.
Our workflow is as follows:
- Execute the
getMetaData
query - Send each field's value to
textInput
inform1
- Modify
textInput
values - Click the Submit button to execute Run Script
- Update data by running
setValue
on themetadata
variable putMetadata
query retrievesmetadata.value
and executes Upload Data
Has anyone encountered a similar issue or have any suggestions on how to fix this?
const updatedData = {
recentPlaylistUrl: form1.data.recentPlaylistUrl,
topNotice: form1.data.topNotice,
topNoticeMobile: form1.data.topNoticeMobile
};
metadata.setValue(updatedData)
putMetadata.trigger({
onSuccess: function() {
utils.showNotification({ title: "Success", message: "metadata.json update success", type: "success" });
}
});