update slideoutpanel, open errors tokeninit

This commit is contained in:
EmberSpirit
2023-08-05 12:03:19 +02:00
parent 6c4933a6a8
commit ceac2a1083
26 changed files with 10440 additions and 16822 deletions
+1 -4
View File
@@ -1,10 +1,7 @@
import { defineStore } from "pinia";
import RewardLockerJson from "@/assets/contracts/RewardLocker.json";
import { useTokenStore } from "./tokens";
import { useMultiCallStore } from "./multicall";
import { useWalletStore } from "./wallet";
import { useWalletStoreV2 } from "./walletV2";
import { ethers } from "ethers";
import { multicall, getContract } from "@wagmi/core";
@@ -24,7 +21,6 @@ export const useRewardLockerStore = defineStore("rewardlocker", {
abi: this.config.abi,
walletClient: walletStore.walletClient || walletStore.publicClient,
});
// this.contract = new walletStore.web3.eth.Contract(this.config.abi, this.config.contractAddress);
},
/*
* @param {*} walletAddress
@@ -62,6 +58,7 @@ export const useRewardLockerStore = defineStore("rewardlocker", {
return await this.contract.read.lastCompletedRound();
},
async claim(round) {
console.log("claim");
const walletStore = useWalletStoreV2();
// return await this.contract.methods.claim(round).call();
console.log(this.contract.methods.claim(round));