Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
68 commits
Select commit Hold shift + click to select a range
76c5ec4
fix: fix bug in rewards page
sincerely91 Sep 7, 2022
83abadf
fix: update staking token abi
sincerely91 Sep 7, 2022
2ddbb35
fix: update vesting token abi
sincerely91 Sep 7, 2022
1a07736
fix: update mining reward contract abi
sincerely91 Sep 7, 2022
5fc84c3
feat: get staking apr
sincerely91 Sep 7, 2022
d5c2e6b
fix: update contract address for testing
sincerely91 Sep 7, 2022
ec4119c
feat: integrate with actual stakingAPR
sincerely91 Sep 7, 2022
4102159
feat: add build file to make deployment easier
sincerely91 Sep 8, 2022
c8a371b
fix: update contractMethod
sincerely91 Sep 12, 2022
252e987
feat: get next distribution reward
sincerely91 Sep 12, 2022
66a2378
fix: update callTokenContractMethod
sincerely91 Sep 14, 2022
b72a018
fix: update rewards pages
sincerely91 Sep 14, 2022
54b89b6
fix: remove old build_token.zip
sincerely91 Sep 15, 2022
649b99d
fix: update build file
sincerely91 Sep 15, 2022
5360397
fix: update contract address
sincerely91 Sep 16, 2022
34622bb
fix: update assist service url
sincerely91 Sep 16, 2022
781d0a7
fix: remove old build file
sincerely91 Sep 16, 2022
acf1602
fix: update build file
sincerely91 Sep 16, 2022
5548d7d
fix: fix bug in stake/unstake toggle button
sincerely91 Sep 16, 2022
b5cfc13
fix: open signDlg when it is not signed in
sincerely91 Sep 16, 2022
4645561
fix: remove old build file
sincerely91 Sep 16, 2022
acba801
fix: update build file
sincerely91 Sep 16, 2022
46a019d
fix: update contract address
sincerely91 Sep 20, 2022
dc11b7b
fix: remove old build file
sincerely91 Sep 20, 2022
6204f4b
fix: add new build file
sincerely91 Sep 20, 2022
00b8782
fix: update rewards display format
sincerely91 Sep 20, 2022
68ebfe1
fix: fix gas limit exceed error
sincerely91 Sep 20, 2022
a042d0e
fix: remove old build file
sincerely91 Sep 20, 2022
b1ecbb4
fix: update pasar balance format
sincerely91 Sep 20, 2022
931a4b0
fix: update stake function
sincerely91 Sep 21, 2022
cd48f76
fix: update bulid file
sincerely91 Sep 21, 2022
df9b595
fix: update contractMethod
sincerely91 Sep 21, 2022
fc2d9ae
fix: call approve function before staking
sincerely91 Sep 21, 2022
5a20904
fix: update display format
sincerely91 Sep 21, 2022
bb7c6a9
fix: update snack bar message
sincerely91 Sep 21, 2022
cdd9b52
fix: remove old build file
sincerely91 Sep 21, 2022
6281fda
fix: update build file
sincerely91 Sep 21, 2022
5299d20
fix: update callTokenContractMethod
sincerely91 Sep 23, 2022
30e519e
fix: fix bug while getting web3 instatnce
sincerely91 Sep 23, 2022
e149efe
fix: remove old build file
sincerely91 Sep 23, 2022
ec525b5
fix: update bulid file
sincerely91 Sep 23, 2022
052ceb0
feat: integrate with actual rewarded user count
sincerely91 Sep 27, 2022
6fa6c61
fix: update rpc url selection
sincerely91 Sep 27, 2022
4ad96c8
fix: remove old build file
sincerely91 Sep 27, 2022
82e2513
fix: update build file
sincerely91 Sep 27, 2022
2f14e4e
fix: hide getPasar button
sincerely91 Sep 28, 2022
e1548ee
fix: remove coming soon badge under claim button
sincerely91 Sep 28, 2022
8eb25db
fix: refresh page after claim rewards
sincerely91 Sep 28, 2022
a797c5a
fix: update fresh option
sincerely91 Sep 28, 2022
f562706
fix: add pasar token to pricing list
sincerely91 Sep 28, 2022
b2edb82
fix: update value format
sincerely91 Sep 28, 2022
868a6e2
fix: update loading process
sincerely91 Sep 28, 2022
2b8804d
fix: remove old build file
sincerely91 Sep 28, 2022
1320813
fix: update build file
sincerely91 Sep 28, 2022
6e1c54f
fix: update loading process
sincerely91 Sep 29, 2022
df80937
fix: remove unused lines
sincerely91 Sep 29, 2022
78de69d
fix: remove old bulid file
sincerely91 Sep 29, 2022
298e4af
fix: update bulid file
sincerely91 Sep 29, 2022
6a22ffd
fix: reload page every 10 secs
sincerely91 Sep 29, 2022
9678c32
fix: remove old build file
sincerely91 Sep 29, 2022
f94e317
fix: update build file
sincerely91 Sep 29, 2022
4cce264
fix: fix incorrect staking amount
sincerely91 Oct 12, 2022
1dc3df1
fix: update stake/unstake workflow
sincerely91 Oct 12, 2022
40cd1d2
fix: add limitation for stake/unstake feature
sincerely91 Oct 12, 2022
4f7175d
fix: update stake/unstake feature
sincerely91 Oct 13, 2022
bead264
fix: improve bigint operation for staking feature
sincerely91 Oct 13, 2022
1420a9f
fix: remove old build file
sincerely91 Oct 13, 2022
2d727a7
fix: update build file for token env
sincerely91 Oct 13, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .env
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ REACT_APP_AUTH0_CLIENT_ID=
REACT_APP_GA_MEASUREMENT_ID=

REACT_APP_BACKEND_URL_PRODUCTION="https://assist-prod.pasarprotocol.io"
REACT_APP_BACKEND_URL_TEST="https://assist-test.pasarprotocol.io"
REACT_APP_BACKEND_URL_TEST="https://token-assist.pasarprotocol.io"

REACT_APP_IPFS_URL_PRODUCTION="https://ipfs.pasarprotocol.io"
REACT_APP_IPFS_URL_TEST="https://ipfs-test.pasarprotocol.io"
Expand Down
Binary file added build_token.zip
Binary file not shown.
109 changes: 91 additions & 18 deletions src/abi/tokenMiningABI.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,25 @@ module.exports.TOKEN_MINING_ABI = [
"stateMutability": "nonpayable",
"type": "constructor"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "market",
"type": "address"
},
{
"indexed": true,
"internalType": "bool",
"name": "state",
"type": "bool"
}
],
"name": "MarketSet",
"type": "event"
},
{
"anonymous": false,
"inputs": [
Expand Down Expand Up @@ -41,7 +60,7 @@ module.exports.TOKEN_MINING_ABI = [
"inputs": [
{
"indexed": true,
"internalType": "enum PasarMiningBase.RewardTypes",
"internalType": "enum IPasarMiningDataAndEvents.RewardTypes",
"name": "rewardType",
"type": "uint8"
},
Expand All @@ -66,7 +85,7 @@ module.exports.TOKEN_MINING_ABI = [
"inputs": [
{
"indexed": true,
"internalType": "enum PasarMiningBase.PoolTypes",
"internalType": "enum IPasarMiningDataAndEvents.PoolTypes",
"name": "pool",
"type": "uint8"
},
Expand Down Expand Up @@ -169,6 +188,19 @@ module.exports.TOKEN_MINING_ABI = [
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "VESTING_NAME",
"outputs": [
{
"internalType": "string",
"name": "",
"type": "string"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
Expand All @@ -177,7 +209,7 @@ module.exports.TOKEN_MINING_ABI = [
"type": "address"
},
{
"internalType": "enum PasarMiningBase.RewardTypes",
"internalType": "enum IPasarMiningDataAndEvents.RewardTypes",
"name": "",
"type": "uint8"
}
Expand Down Expand Up @@ -231,7 +263,7 @@ module.exports.TOKEN_MINING_ABI = [
"type": "uint256"
}
],
"internalType": "struct PasarMiningBase.AccRewardInfo",
"internalType": "struct IPasarMiningDataAndEvents.AccRewardInfo",
"name": "all",
"type": "tuple"
},
Expand All @@ -253,7 +285,7 @@ module.exports.TOKEN_MINING_ABI = [
"type": "uint256"
}
],
"internalType": "struct PasarMiningBase.AccRewardInfo",
"internalType": "struct IPasarMiningDataAndEvents.AccRewardInfo",
"name": "buyer",
"type": "tuple"
},
Expand All @@ -275,7 +307,7 @@ module.exports.TOKEN_MINING_ABI = [
"type": "uint256"
}
],
"internalType": "struct PasarMiningBase.AccRewardInfo",
"internalType": "struct IPasarMiningDataAndEvents.AccRewardInfo",
"name": "seller",
"type": "tuple"
},
Expand All @@ -297,7 +329,7 @@ module.exports.TOKEN_MINING_ABI = [
"type": "uint256"
}
],
"internalType": "struct PasarMiningBase.AccRewardInfo",
"internalType": "struct IPasarMiningDataAndEvents.AccRewardInfo",
"name": "creator",
"type": "tuple"
}
Expand All @@ -308,7 +340,7 @@ module.exports.TOKEN_MINING_ABI = [
{
"inputs": [
{
"internalType": "enum PasarMiningBase.PoolTypes",
"internalType": "enum IPasarMiningDataAndEvents.PoolTypes",
"name": "",
"type": "uint8"
},
Expand All @@ -332,7 +364,7 @@ module.exports.TOKEN_MINING_ABI = [
{
"inputs": [
{
"internalType": "enum PasarMiningBase.PoolTypes",
"internalType": "enum IPasarMiningDataAndEvents.PoolTypes",
"name": "",
"type": "uint8"
},
Expand Down Expand Up @@ -559,7 +591,7 @@ module.exports.TOKEN_MINING_ABI = [
{
"inputs": [
{
"internalType": "enum PasarMiningBase.PoolTypes",
"internalType": "enum IPasarMiningDataAndEvents.PoolTypes",
"name": "",
"type": "uint8"
}
Expand All @@ -586,7 +618,7 @@ module.exports.TOKEN_MINING_ABI = [
"name": "names",
"outputs": [
{
"internalType": "enum PasarMiningBase.RewardTypes",
"internalType": "enum IPasarMiningDataAndEvents.RewardTypes",
"name": "",
"type": "uint8"
}
Expand Down Expand Up @@ -648,12 +680,12 @@ module.exports.TOKEN_MINING_ABI = [
"type": "address"
},
{
"internalType": "enum PasarMiningBase.PoolTypes",
"internalType": "enum IPasarMiningDataAndEvents.PoolTypes",
"name": "",
"type": "uint8"
},
{
"internalType": "enum PasarMiningBase.RewardTypes",
"internalType": "enum IPasarMiningDataAndEvents.RewardTypes",
"name": "",
"type": "uint8"
}
Expand Down Expand Up @@ -721,13 +753,54 @@ module.exports.TOKEN_MINING_ABI = [
"outputs": [
{
"internalType": "uint256",
"name": "",
"name": "count",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "account",
"type": "address"
},
{
"internalType": "uint256[]",
"name": "indexes",
"type": "uint256[]"
}
],
"name": "rewardRecords",
"outputs": [
{
"components": [
{
"internalType": "uint256",
"name": "blockNumber",
"type": "uint256"
},
{
"internalType": "enum IPasarMiningDataAndEvents.RewardTypes",
"name": "rewardType",
"type": "uint8"
},
{
"internalType": "uint256",
"name": "rewardAmount",
"type": "uint256"
}
],
"internalType": "struct IPasarMiningDataAndEvents.RewardInfo[]",
"name": "records",
"type": "tuple[]"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
Expand All @@ -749,7 +822,7 @@ module.exports.TOKEN_MINING_ABI = [
"type": "uint256"
},
{
"internalType": "enum PasarMiningBase.RewardTypes",
"internalType": "enum IPasarMiningDataAndEvents.RewardTypes",
"name": "rewardType",
"type": "uint8"
},
Expand Down Expand Up @@ -816,7 +889,7 @@ module.exports.TOKEN_MINING_ABI = [
"type": "address"
},
{
"internalType": "enum PasarMiningBase.PoolTypes",
"internalType": "enum IPasarMiningDataAndEvents.PoolTypes",
"name": "",
"type": "uint8"
},
Expand All @@ -826,7 +899,7 @@ module.exports.TOKEN_MINING_ABI = [
"type": "uint256"
},
{
"internalType": "enum PasarMiningBase.RewardTypes",
"internalType": "enum IPasarMiningDataAndEvents.RewardTypes",
"name": "",
"type": "uint8"
}
Expand Down Expand Up @@ -891,7 +964,7 @@ module.exports.TOKEN_MINING_ABI = [
{
"inputs": [
{
"internalType": "enum PasarMiningBase.RewardTypes",
"internalType": "enum IPasarMiningDataAndEvents.RewardTypes",
"name": "rewardType",
"type": "uint8"
}
Expand Down
32 changes: 32 additions & 0 deletions src/abi/tokenStakingABI.js
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,19 @@ module.exports.TOKEN_STAKING_ABI = [
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "VESTING_NAME",
"outputs": [
{
"internalType": "string",
"name": "",
"type": "string"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "config",
Expand Down Expand Up @@ -406,6 +419,25 @@ module.exports.TOKEN_STAKING_ABI = [
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "timestamp",
"type": "uint256"
}
],
"name": "totalRewardAtTime",
"outputs": [
{
"internalType": "uint256",
"name": "totalReward",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
Expand Down
48 changes: 48 additions & 0 deletions src/abi/tokenVestingABI.js
Original file line number Diff line number Diff line change
Expand Up @@ -572,6 +572,54 @@ module.exports.TOKEN_VESTING_ABI = [
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "enum IPasarVesting.Allocations",
"name": "alloc",
"type": "uint8"
},
{
"internalType": "uint256",
"name": "timestamp",
"type": "uint256"
}
],
"name": "releaseAtTimeByAlloc",
"outputs": [
{
"internalType": "uint256",
"name": "total",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "string",
"name": "name",
"type": "string"
},
{
"internalType": "uint256",
"name": "timestamp",
"type": "uint256"
}
],
"name": "releaseAtTimeByName",
"outputs": [
{
"internalType": "uint256",
"name": "total",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
Expand Down
1 change: 1 addition & 0 deletions src/components/signin-dlg/SignInDialog.js
Original file line number Diff line number Diff line change
Expand Up @@ -511,6 +511,7 @@ export default function SignInDialog() {
sessionStorage.removeItem('PASAR_TOKEN');
sessionStorage.removeItem('PASAR_DID');
sessionStorage.removeItem('KYCedProof');
sessionStorage.removeItem('REWARD_USER');
try {
setSigninEssentialSuccess(false);
setActivatingConnector(null);
Expand Down
14 changes: 7 additions & 7 deletions src/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,9 @@ const addressForProduction = {
const addressForTest = {
MAIN_CONTRACT: {
ESC: {
sticker: "0x32496388d7c0CDdbF4e12BDc84D39B9E42ee4CB0",
market: "0x19088c509C390F996802B90bdc4bFe6dc3F5AAA7",
register: "0x2b304ffC302b402785294629674A8C2b64cEF897"
sticker: "0x3748c352cF8B3e8c6CF6800F315072a2C1fD3F82",
market: "0x6a02E1942A6201C47BBd3246fF2b044a2536aB43",
register: "0x26CB562A77eB0610D3d1e6Fc5e856B5bcc93Fb8b"
},
ETH: {
sticker: "0xed1978c53731997f4DAfBA47C9b07957Ef6F3961",
Expand All @@ -92,10 +92,10 @@ const addressForTest = {
bunnyContract: "0x75740FC7058DA148752ef8a9AdFb73966DEb42a8",
bnbBusdContract: "0x9f1d0Ed4E041C503BD487E5dc9FC935Ab57F9a57",
elaOnEthContract: "0x8c947E0fA67e91370587076A4108Df17840e9982",
pasarERC20Contract: '0xa7B1a72266ad3a54Ac00071f05453feEeB5680dB',
pasarVestingContract: '0xD883303d400427C298d53e99a3faa7Cb1E9A8727',
pasarStakingContract: '0x048c96C7dF2d789A515c0c18c9345481c12e664E',
pasarMiningContract: '0x8158FF69C60Eb893e32869180D980853160b8d68',
pasarERC20Contract: '0x2E54635bee5F1451A7f138797d96f22e3Cba5453',
pasarVestingContract: '0xB2d03B5c9Dc4429EDde239183AaF39D74e29a536',
pasarStakingContract: '0xc7a57f6203f9F9b82cafb966c8940cA0527713A2',
pasarMiningContract: '0xB27CC87EaF372F78E3Ca4da38b013E154e7247e0',
blockchain: 'Testnet (ESC)'
}

Expand Down
Loading