Skip to content

Commit f96dfa5

Browse files
committed
Update script
1 parent 6034ef1 commit f96dfa5

File tree

3 files changed

+223
-215
lines changed

3 files changed

+223
-215
lines changed

src/scripts/Platform.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1089,13 +1089,13 @@ async function main() {
10891089
let balanceBefore = Number(
10901090
Account(projects[i].publicKey).balance.get()
10911091
);
1092-
// tx = await Mina.transaction(
1093-
// { sender: projects[i].publicKey, fee },
1094-
// () => {
1095-
// treasuryContract.claimFund(claimFundInput[i]);
1096-
// }
1097-
// );
1098-
// await proveAndSend(tx, [projects[i]], Contract.TREASURY, 'claimFund');
1092+
tx = await Mina.transaction(
1093+
{ sender: projects[i].publicKey, fee },
1094+
() => {
1095+
treasuryContract.claimFund(claimFundInput[i]);
1096+
}
1097+
);
1098+
await proveAndSend(tx, [projects[i]], Contract.TREASURY, 'claimFund');
10991099
let balanceAfter = Number(
11001100
Account(projects[i].publicKey).balance.get()
11011101
);

src/scripts/interactions/campaign/rollup.ts

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,6 @@ async function main() {
6666
// Do this and state value of contract is fetched in Mina
6767
await fetchZkAppState(zkAppAddress);
6868
let nextCampaignId = Number(zkContract.nextCampaignId.get());
69-
nextCampaignId = 4;
7069

7170
// Storage
7271
let campaignInfoStorage = new CampaignInfoStorage();
@@ -165,23 +164,23 @@ async function main() {
165164

166165
// update storage:
167166
ownerStorage.updateLeaf(
168-
ownerStorage.calculateLeaf(action.owner),
169-
Field(i)
167+
Field(i),
168+
ownerStorage.calculateLeaf(action.owner)
170169
);
171170
campaignInfoStorage.updateLeaf(
172-
campaignInfoStorage.calculateLeaf(action.ipfsHash),
173-
Field(i)
171+
Field(i),
172+
campaignInfoStorage.calculateLeaf(action.ipfsHash)
174173
);
175174
statusStorage.updateLeaf(
176-
statusStorage.calculateLeaf(StatusEnum.APPLICATION),
177-
Field(i)
175+
Field(i),
176+
statusStorage.calculateLeaf(StatusEnum.APPLICATION)
178177
);
179178
configStorage.updateLeaf(
179+
Field(i),
180180
configStorage.calculateLeaf({
181181
committeeId: action.committeeId,
182182
keyId: action.keyId,
183-
}),
184-
Field(i)
183+
})
185184
);
186185

187186
console.log('DONE');

0 commit comments

Comments
 (0)