Guys, I am facing very peculiar problem. I have repeater with upload button. This is connected to collection. It works fine in Preview but not on live.
I am getting following output of itemData
on preview (highlighted in bold the upload document field SHA)
Return: “1.00x”
Currentvaluation: “1,000,000”
email: “janardan.s@gmail.com”
investorName: “Janardan Singh”
_id: “21efde5c-4a0a-4799-a0ba-aeb0a143848e”
Purchaseprice: “1”
_owner: “a8fe993e-78d3-4751-9375-e1f6bbfbc7ae”
Investmentamount: “1,000,000”
_createdDate: “Sun May 16 2021 21:45:36 GMT+0530 (India Standard Time)”
startup: “AngelBay - Loan”
noOfShares: 1000000
_updatedDate: “Tue Jun 08 2021 22:41:42 GMT+0530 (India Standard Time)”
investmentdate: “Mon Mar 15 2021 00:00:00 GMT+0530 (India Standard Time)”
Lastvaluationdate: “17/5/2021”
prisec: “Primary”
sha: “wix:document://v1/a60fc3_f9d463b33cc34d9b9246f9e9f3e38a71.pdf/AngelBay_Depositors_LOAN AGREEMENT_2100309.pdf”
currency: “INR”
Currentvaluepershare: “1”
Dateofinvestment: “14/3/2021”
purchasePrice: 1
On live (There is no field for SHA which is my upload field)
“{“Return”:“1.00x”,
“Currentvaluation”:“1,000,000”,
“email":"janardan.s@gmail.com”,
“investorName”:“Janardan Singh”,
“_id”:“21efde5c-4a0a-4799-a0ba-aeb0a143848e”,
“Purchaseprice”:“1”,
“_owner”:“a8fe993e-78d3-4751-9375-e1f6bbfbc7ae”,
“Investmentamount”:“1,000,000”,
“_createdDate”:“Sun May 16 2021 21:45:36 GMT+0530 (India Standard Time)”,
“startup”:“AngelBay - Loan”,
“noOfShares”:1000000,
“_updatedDate”:“Tue Jun 08 2021 22:10:47 GMT+0530 (India Standard Time)”,
“investmentdate”:“Mon Mar 15 2021 00:00:00 GMT+0530 (India Standard Time)”,
“Lastvaluationdate”:“17/5/2021”,
“prisec”:“Primary”,
“currency”:“INR”,
“Currentvaluepershare”:“1”,
“Dateofinvestment”:“14/3/2021”,“purchasePrice”:1}”
$w.onReady(function () {
$w("#repeater1").onItemReady(($item, itemData, index) => {
$item("#button2").enable();
$item("#button2").onClick(async (event) => {
console.log(itemData);
console.log(itemData.startup);
console.log(itemData.sha);
await $item("#dataset10").save();
session.setItem('Errormessage', "Data Saved");
wixWindow.openLightbox("Error")
});
});
})