Merge pull request #20 from DODOEX/feature/mineUpdate
Feature/mine update
This commit is contained in:
6
.gitignore
vendored
6
.gitignore
vendored
@@ -12,6 +12,12 @@ lint/
|
||||
script/
|
||||
flattered/
|
||||
|
||||
deploy-detail-v2.0.txt
|
||||
deploy-detail-periphery.txt
|
||||
deploy-drops.txt
|
||||
deploy-nft.txt
|
||||
kovan-mock-v2.0.txt
|
||||
|
||||
# VIM
|
||||
*.swo
|
||||
*.swp
|
||||
|
||||
@@ -21,8 +21,9 @@ module.exports = {
|
||||
|
||||
DPPAdmin: "0x1dc8D1f1600B7C1D39e6b60FBC7b021Bc4F9C993",
|
||||
CP: "0x8F8Dd7DB1bDA5eD3da8C9daf3bfa471c12d58486",
|
||||
ERC20: "0xC3528D128CC227fd60793007b5e3FdF7c2945282",
|
||||
ERC20: "0xBb245F54569841906eC7eDFFf72a910557B81378",
|
||||
MintableERC20: "0x70eFB31271C0796833f80dA4E6538d05B2AFA72C",
|
||||
CustomERC20: "0xcE2a934933465E187c95AcAce60BC650a06aD373",
|
||||
|
||||
//Factory
|
||||
DVMFactory: "0xb0C7cB15b52b0093130487209e96CFeC0Ba4Ff66",
|
||||
@@ -31,6 +32,7 @@ module.exports = {
|
||||
UpCpFactory: "0x69f52AC40185A2A005D49114F0B77b7bA856F0a0",
|
||||
CrowdPoolingFactory: "0x884E3EE9e25896c57E7d8d6FAACef22B02BCD6bE",
|
||||
ERC20Factory: "0x141b4497a298340E8B451ac4eeE947B00aDbe07A",
|
||||
ERC20V2Factory: "0xE3c91fDCe30DD5Aa95138D6c4d63f43a26e9066e",
|
||||
|
||||
//Approve
|
||||
DODOApprove: "0xCDFD45f965De9932367833Ca7187e4c9C43A2380",
|
||||
|
||||
@@ -20,8 +20,9 @@ module.exports = {
|
||||
DSP: "0xE3c91fDCe30DD5Aa95138D6c4d63f43a26e9066e",
|
||||
DPPAdmin: "0x44D5dF24d5Ef52A791D6436Fa45A8D426f6de34e",
|
||||
CP: "0x5D6e6A0BFB2176AFCc4FB809822D8e009216b245",
|
||||
ERC20: "0xef49a6dba1c8df859e49c17e9a485b439c7689d3",
|
||||
ERC20: "0x99155E68aC1523B6f461F6427A90607ecCF7bDF5",
|
||||
MintableERC20: "0x6373ceb657c83c91088d328622573fb766064ac4",
|
||||
CustomERC20: "0x4777A6f28c8Bb260D9a945dddeFabB942aE10f1f",
|
||||
|
||||
//Factory
|
||||
DVMFactory: "0x790B4A80Fb1094589A3c0eFC8740aA9b0C1733fB",
|
||||
@@ -30,6 +31,7 @@ module.exports = {
|
||||
UpCpFactory: "0x4F57F6929E58AE564F6AB090fE0AEEcb39B0f270",
|
||||
CrowdPoolingFactory: "0x778DF5B12170e8af8dF94356BfC864E57CE185DC",
|
||||
ERC20Factory: "0x5e84190a270333aCe5B9202a3F4ceBf11b81bB01",
|
||||
ERC20V2Factory: "0x652C09785c15db4adAce871eD8874b8968A19A4D",
|
||||
|
||||
//Approve
|
||||
DODOApprove: "0xa128Ba44B2738A558A1fdC06d6303d52D3Cef8c1",
|
||||
|
||||
@@ -20,8 +20,9 @@ module.exports = {
|
||||
DSP: "0x8735AAd3BEae15487a017EE32cb11d8fd593e036",
|
||||
DPPAdmin: "0x5515363c0412AdD5c72d3E302fE1bD7dCBCF93Fe",
|
||||
CP: "0x327344B382EE1b44FB0a72945fCDCC7243200dD7",
|
||||
ERC20: "0x85351262f7474ebe23ffacd633cf20a491f1325d",
|
||||
ERC20: "0x8443a5bD91C8f68582F90dD3354f750900C5E8Cc",
|
||||
MintableERC20: "0x0596908263ef2724fbfbcafa1c983fcd7a629038",
|
||||
CustomERC20: "0x9Cd85f012050FE030271dCB7c0a0C1e2043Ce4a9",
|
||||
|
||||
//Factory
|
||||
DVMFactory: "0x72d220cE168C4f361dD4deE5D826a01AD8598f6C",
|
||||
@@ -30,6 +31,7 @@ module.exports = {
|
||||
UpCpFactory: "0x78D338F9d54E9e41872E68cB1c01d9499d87eE52",
|
||||
CrowdPoolingFactory: "0xE8C9A78725D0451FA19878D5f8A3dC0D55FECF25",
|
||||
ERC20Factory: "0x44D5dF24d5Ef52A791D6436Fa45A8D426f6de34e",
|
||||
ERC20V2Factory: "0xAA810cd0363d3378F0a13e327EC2Aee7051aDa73",
|
||||
|
||||
//Approve
|
||||
DODOApprove: "0xCB859eA579b28e02B87A1FDE08d087ab9dbE5149",
|
||||
|
||||
@@ -20,8 +20,9 @@ module.exports = {
|
||||
DSP: "0xEB5470DfCF2BA5CDdC108E8B65A7ED2A77EA3c2D",
|
||||
DPPAdmin: "0x3232fd648997F89E614A021fdAc756d61F9030A1",
|
||||
CP: "0x5B67cF070ce4303Ff4d450f21Cc371F9f0549335",
|
||||
ERC20: "0x62e1622a47c9fe74b2cf0bade5ecb8669ff9bfbf",
|
||||
ERC20: "0x2870fB656C7D245dc74afbA34B0d453FA67Ce4fA",
|
||||
MintableERC20: "0xdd9de5ed7a11b1ed3314cd7f754f27a15dedc63f",
|
||||
CustomERC20: "0x2cE80F95eD3d2a76694896843F18413ae83baF40",
|
||||
|
||||
//Factory
|
||||
DVMFactory: "0xd8c77CF0F01222b07B8343A681C46eFA3faEa985",
|
||||
@@ -30,7 +31,7 @@ module.exports = {
|
||||
UpCpFactory: "0xF7c3467786efAA9BD4022941ecd5a00C61b17FA9",
|
||||
CrowdPoolingFactory: "0x56133d0b63abf7A15D5697dD2dB9e04730f1A9C2",
|
||||
ERC20Factory: "0x2cCDF6F742afBe813B68Ec6bb421C1BEa74fBd46",
|
||||
|
||||
ERC20V2Factory: "0x1297264617bd34270B77c2fFD3aA110D3fd2f7aF",
|
||||
//Approve
|
||||
DODOApprove: "0x68b6c06Ac8Aa359868393724d25D871921E97293",
|
||||
DODOApproveProxy: "0x91737709De4b2eDEE3a2B78A84e21a60C0b4D70b",
|
||||
|
||||
@@ -20,9 +20,9 @@ module.exports = {
|
||||
DSP: "0xAD4E649c1771F5175081c2CcAC183fDb91cfCd6c",
|
||||
DPPAdmin: "0xf63e41A459D9AEcaE4bAE1278ef0ae84F7F2DE56",
|
||||
CP: "0x6092eFEf82CaDcd07f3a545cBe6C83dae713aE0A",
|
||||
ERC20: "0x77d2e257241e6971688b08bda9f658f065d7bb41",
|
||||
MintableERC20: "0xa45a64daba80757432fa4d654df12f65f020c13c",
|
||||
|
||||
ERC20: "0x4DdcDcCe3BCDD84c8E15d50Bd9384c25B3Ca9eff",
|
||||
MintableERC20: "",
|
||||
CustomERC20: "0xFC8fb4CD3A77F138E53F92F5EC483e9887508CCe",
|
||||
//Factory
|
||||
DVMFactory: "0x322F8014C125Da09314d3a68d4d9F427823F17FD",
|
||||
DPPFactory: "0xC65F8087288aa0a118aa6F3228Ef9ecc8187F4b6",
|
||||
@@ -30,6 +30,7 @@ module.exports = {
|
||||
CrowdPoolingFactory: "0x9e6E8985D52E91eDf1671f28Ca73bc4F3E219b72",
|
||||
UpCpFactory: "0x25AE560522165eacCFbF2287493AF12B8ad718e7",
|
||||
ERC20Factory: "0xCb1A2f64EfB02803276BFB5a8D511C4D950282a0",
|
||||
ERC20V2Factory: "0xa2c1eA946dA567248c70F792b64D5F2551f29204",
|
||||
|
||||
//Approve
|
||||
DODOApprove: "0xa375b128e139ae54EF7F189BC8fEb4624f1c2Afa",
|
||||
|
||||
@@ -21,8 +21,9 @@ module.exports = {
|
||||
|
||||
DPPAdmin: "0xB5Dc5E183c2aCf02aB879A8569aB4EDAf147d537",
|
||||
CP: "0xf50BDc9E90B7a1c138cb7935071b85c417C4cb8e",
|
||||
ERC20: "0xE8C9A78725D0451FA19878D5f8A3dC0D55FECF25",
|
||||
ERC20: "0x34b9Dc29AaDc313F2BF828B7Be1e0DEe393D28e3",
|
||||
MintableERC20: "0x7737fd30535c69545deeEa54AB8Dd590ccaEBD3c",
|
||||
CustomERC20: "0xaF49DBAaf177beE57f84731260a9eb8819d25eff",
|
||||
|
||||
//Factory
|
||||
DVMFactory: "0xbAb9F4ff4A19a0e8EEBC56b06750253228ffAc6E",
|
||||
@@ -31,6 +32,7 @@ module.exports = {
|
||||
UpCpFactory: "0x335aC99bb3E51BDbF22025f092Ebc1Cf2c5cC619",
|
||||
CrowdPoolingFactory: "0x85351262f7474Ebe23FfAcD633cf20A491F1325D",
|
||||
ERC20Factory: "0xaeB5CF31b97dce6134e416129845e01106fFB177",
|
||||
ERC20V2Factory: "0x8e2f666F316b614c76676215F16F0A9746f96a90",
|
||||
|
||||
//Approve
|
||||
DODOApprove: "0x9aE501385Bc7996A2A4a1FBb00c8d3820611BCB5",
|
||||
|
||||
102
config/rinkeby-config.js
Normal file
102
config/rinkeby-config.js
Normal file
@@ -0,0 +1,102 @@
|
||||
module.exports = {
|
||||
RINKEBY_CONFIG: {
|
||||
//TOKEN
|
||||
WETH: "0xB26c0d8Be2960c70641A95A9195BE1f59Ac83aC0",
|
||||
CHI: "0x0000000000000000000000000000000000000000",
|
||||
DODO: "0xeaa70c2a40820dF9D38149C84dd943CFcB562587",
|
||||
|
||||
//Helper
|
||||
DODOSellHelper: "0x4635FAc4471BC5B5839007f1EF65ff469ace333F",
|
||||
DODOCalleeHelper: "0x87C296100df953aFa324ABB870891baD9dDBf0fC",
|
||||
DODOV1PmmHelper: "0xEb06236b035f1Db7F1D181Efd635Edd621874472",
|
||||
DODOV2RouteHelper: "0x80a70F228D8faBF20fdaf8274b9A7c4AE3551861",
|
||||
|
||||
//Template
|
||||
CloneFactory: "0x823ECBfCCD3e6Cb67d4c9334F743BEe0E60A7349",
|
||||
FeeRateModel: "0x0ae835f585638CCbD4D7eAA339ED033f8194Bcfe",
|
||||
PermissionManager: "0x7949a4D350F69ef5Ff4c3079751250f5b7B86a00",
|
||||
DVM: "0x44BD801ACAf994bD628d01d84299BE94010dc08B",
|
||||
DPP: "0x604BFaDa2EAC7E011DdF9aA8848b38e8b02aDdD2",
|
||||
DSP: "0xe2C23cBF03930418BF97e173FE3E950aD29fdb06",
|
||||
DPPAdmin: "0x2FF619B4Cfe36b0F92dD933256B1581a3269a5F4",
|
||||
CP: "0x6850eE8cF963B913a8eC3610B5f128C3100178E5",
|
||||
ERC20: "0x7119D1Ec8235bd0a82289fDb1cCAa4bD4D1e0605",
|
||||
MintableERC20: "",
|
||||
CustomERC20: "0x0Cd57DC8367362314C510446FD106B66989Eb81a",
|
||||
|
||||
//Factory
|
||||
DVMFactory: "0x17DddEFA0c82E0c850a4Adac2aFE3F1fe977A242",
|
||||
DPPFactory: "0x510b49803E356C750f3a93bA5508C0FFD9f71bDD",
|
||||
DSPFactory: "0xa1ab675cB49BA0DC3F39fA4C20E216572A8dD3c8",
|
||||
CrowdPoolingFactory: "0xDD43520779dDCfbDe373174Ee36aEaD39771cD4f",
|
||||
UpCpFactory: "0xb09E91505347234Cb722D67042290f50F1C13749",
|
||||
ERC20Factory: "0x48476599281CB7DD46dbE47264C4594d1d2E19A8",
|
||||
ERC20V2Factory: "0x7A22e361cB74E69B5B1C800A3aAbE3E50e84F4F6",
|
||||
|
||||
//Approve
|
||||
DODOApprove: "0xcC8d87A7C747eeE4242045C47Ef25e0A81D56ae3",
|
||||
DODOApproveProxy: "0x790917CA55c9B01974BFDd066537Fb3DF42Bb0E3",
|
||||
|
||||
//Periphery
|
||||
DODOIncentive: "0x0000000000000000000000000000000000000000",
|
||||
|
||||
//Adpater
|
||||
DODOV1Adapter: "0x7ffd33271765E37FdD527a03ca13783DCD4dD3E6",
|
||||
DODOV2Adapter: "0x733488ea274561fe8543cF5386fEcC6EE932Ba5E",
|
||||
UniAdapter: "0x5964Af417A0cdFa8C0E171733FB1c570b2b515E8",
|
||||
|
||||
//Proxy
|
||||
DODOV2Proxy: "0xba001E96AF87bF9d8D0BDA667067A9921FE6d294",
|
||||
DSPProxy: "0x0f6345D1d07C134BB0973AD102F38eA9195F6f78",
|
||||
CpProxy: "0x2E483CBb9e76fE6543168DEd698d9244EE1ED8Dd",
|
||||
DODORouteProxy: "0xe2b538a781eB5a115a1359B8f363B9703Fd19dE6",
|
||||
|
||||
|
||||
//vDODO
|
||||
DODOCirculationHelper: "0xe4Aec985debDDbbCB2358e8C8F9384DD6421d163",
|
||||
Governance: "0x0000000000000000000000000000000000000000",
|
||||
dodoTeam: "0x7e83d9d94837eE82F0cc18a691da6f42F03F1d86",
|
||||
vDODOToken: "0x8751f874eCd2874f2a5ced95A08364C203e4146A",
|
||||
|
||||
//Account
|
||||
multiSigAddress: "0x7e83d9d94837eE82F0cc18a691da6f42F03F1d86",
|
||||
defaultMaintainer: "0x7e83d9d94837eE82F0cc18a691da6f42F03F1d86",
|
||||
|
||||
//FeeRateImpl: "0xCc5e58B59158A9dfb13e4d902958689fA0e7dE9c",
|
||||
//multiCall: "0xb7E1C577f95959a3eD11f9281702850328b4e0e4",
|
||||
//DODO: "0xF65899222FC7C73044Fe24f954b3b29Ff092B9e2",
|
||||
//DODOZoo: "0x168442Fec1e1E782c8770185dBb8328B91dC45c0",
|
||||
//DODOSwapCalcHelper: "0x5020d289E1140Dc733126a71818A08F7f0fe1AE1",
|
||||
//DODOMineV2Factory: "0x3932E00a51d0D3b85C8Eb7C3ED0FcCB0dF98B3FF"
|
||||
|
||||
//================== NFT ====================
|
||||
BuyoutModel: "0x98F5aF1E7Fb03A085D2a28713995e4A923860288",
|
||||
Fragment: "0xDF7eccee9f5C92D1Baf036DB9410456f9382E045",
|
||||
NFTCollateralVault: "0x23d72eA97a9E43411Eeb908d128DF337aD334582",
|
||||
DODONFTRouteHelper: "0xb0Ca341b6fbdC607A507D821780e29f9601a58B3",
|
||||
|
||||
InitializableERC721: "0xC0ccfC832BD45Cd3A2d62e47FE92Fc50DD2210ac",
|
||||
InitializableERC1155: "0x9DC9086B65cCBec43F92bFa37Db81150Ed1DDDed",
|
||||
NFTTokenFactory: "0xd2BffcCBC1F2a7356f8DaBB55B33E47D62de1bB1",
|
||||
|
||||
DodoNftErc721: "0x3Bc20358B31aD498d5a245B36bC993DDBE9A4405",
|
||||
DodoNftErc1155: "0xc498F36eF82Aa5dBE0ecF6DD56DD55398E80E13D",
|
||||
|
||||
DODONFTRegistry: "0x69efeCA5070Cb22c1094cffEbacafC09c058c139",
|
||||
DODONFTProxy: "0x0CF019E13C6527BD34eC6c8323F11aB5DF6f0922",
|
||||
|
||||
//================= DropsV1 =================
|
||||
MysteryBoxV1: "",
|
||||
RandomGenerator: "0x69C8a7fc6E05d7aa36114B3e35F62DEcA8E11F6E",
|
||||
RandomPool: [],
|
||||
|
||||
//================= DropsV2 ==================
|
||||
DropsFeeModel: "0xA012249Fac6D77Daf246BFBdC193fFBC8814298C",
|
||||
DropsProxy: "0xa968a8B14174395c922347Ab593a0CD7EFf30cf1",
|
||||
|
||||
//DODODropsV2: "0x4A2b9f63AE41cF3003A494F2d8Fcd9Ed850b9A6f"
|
||||
|
||||
// DropsERC721: "0x3df8d553275781C777f432A74EEE9099226B9d13",
|
||||
// DropsERC1155: "0x3a8EcF30428bd4e33Cd7011533DFd596F7705c8F",
|
||||
}
|
||||
}
|
||||
@@ -4,15 +4,13 @@ const { HECO_CONFIG } = require("./config/heco-config");
|
||||
const { KOVAN_CONFIG } = require("./config/kovan-config");
|
||||
const { MBTEST_CONFIG } = require("./config/mbtest-config");
|
||||
const { MBTESTNET_CONFIG } = require("./config/mbtestnet-config");
|
||||
const { OKTEST_CONFIG } = require("./config/oktest-config");
|
||||
const { ARBTEST_CONFIG } = require("./config/arbtest-config");
|
||||
const { MATIC_CONFIG } = require("./config/matic-config");
|
||||
const { ARB_CONFIG } = require("./config/arb-config");
|
||||
const { RINKEBY_CONFIG } = require("./config/rinkeby-config");
|
||||
|
||||
exports.GetConfig = function (network, accounts) {
|
||||
var CONFIG = {}
|
||||
switch (network) {
|
||||
//mainnet
|
||||
case "live":
|
||||
CONFIG = ETH_CONFIG
|
||||
break;
|
||||
@@ -34,6 +32,11 @@ exports.GetConfig = function (network, accounts) {
|
||||
CONFIG.multiSigAddress = accounts[0]
|
||||
CONFIG.defaultMaintainer = accounts[0]
|
||||
break;
|
||||
case "rinkeby":
|
||||
CONFIG = RINKEBY_CONFIG
|
||||
CONFIG.multiSigAddress = accounts[0]
|
||||
CONFIG.defaultMaintainer = accounts[0]
|
||||
break;
|
||||
case "mbtestnet":
|
||||
CONFIG = MBTEST_CONFIG
|
||||
CONFIG.multiSigAddress = accounts[0]
|
||||
@@ -44,16 +47,6 @@ exports.GetConfig = function (network, accounts) {
|
||||
CONFIG.multiSigAddress = accounts[0]
|
||||
CONFIG.defaultMaintainer = accounts[0]
|
||||
break;
|
||||
case "oktest":
|
||||
CONFIG = OKTEST_CONFIG
|
||||
CONFIG.multiSigAddress = accounts[0]
|
||||
CONFIG.defaultMaintainer = accounts[0]
|
||||
break;
|
||||
case "arbtest":
|
||||
CONFIG = ARBTEST_CONFIG
|
||||
CONFIG.multiSigAddress = accounts[0]
|
||||
CONFIG.defaultMaintainer = accounts[0]
|
||||
break;
|
||||
}
|
||||
return CONFIG
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
pragma solidity 0.6.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
import {DPP} from "./DPP.sol";
|
||||
import {DPP} from "../DPP.sol";
|
||||
|
||||
/**
|
||||
* @title DODO PrivatePool
|
||||
@@ -8,9 +8,9 @@
|
||||
pragma solidity 0.6.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
import {IDPP} from "../intf/IDPP.sol";
|
||||
import {IDODOApproveProxy} from "../../SmartRoute/DODOApproveProxy.sol";
|
||||
import {InitializableOwnable} from "../../lib/InitializableOwnable.sol";
|
||||
import {IDPP} from "../../intf/IDPP.sol";
|
||||
import {IDODOApproveProxy} from "../../../SmartRoute/DODOApproveProxy.sol";
|
||||
import {InitializableOwnable} from "../../../lib/InitializableOwnable.sol";
|
||||
|
||||
/**
|
||||
* @title DPPAdmin
|
||||
84
contracts/DODOPrivatePool/impl/DPPOracle/DPPOracle.sol
Normal file
84
contracts/DODOPrivatePool/impl/DPPOracle/DPPOracle.sol
Normal file
@@ -0,0 +1,84 @@
|
||||
/*
|
||||
|
||||
Copyright 2021 DODO ZOO.
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
*/
|
||||
|
||||
pragma solidity 0.6.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
import {IFeeRateModel} from "../../../lib/FeeRateModel.sol";
|
||||
import {IERC20} from "../../../intf/IERC20.sol";
|
||||
import {DPPTrader} from "./DPPTrader.sol";
|
||||
|
||||
/**
|
||||
* @title DODO PrivatePool
|
||||
* @author DODO Breeder
|
||||
*
|
||||
* @notice DODOPrivatePool with oracle price
|
||||
*/
|
||||
contract DPPOracle is DPPTrader {
|
||||
|
||||
function init(
|
||||
address owner,
|
||||
address maintainer,
|
||||
address baseTokenAddress,
|
||||
address quoteTokenAddress,
|
||||
uint256 lpFeeRate,
|
||||
address mtFeeRateModel,
|
||||
uint256 k,
|
||||
address i,
|
||||
bool isOpenTWAP
|
||||
) external {
|
||||
initOwner(owner);
|
||||
|
||||
require(baseTokenAddress != quoteTokenAddress, "BASE_QUOTE_CAN_NOT_BE_SAME");
|
||||
_BASE_TOKEN_ = IERC20(baseTokenAddress);
|
||||
_QUOTE_TOKEN_ = IERC20(quoteTokenAddress);
|
||||
|
||||
_MAINTAINER_ = maintainer;
|
||||
_MT_FEE_RATE_MODEL_ = IFeeRateModel(mtFeeRateModel);
|
||||
|
||||
require(lpFeeRate <= 1e18, "LP_FEE_RATE_OUT_OF_RANGE");
|
||||
require(k <= 1e18, "K_OUT_OF_RANGE");
|
||||
require(i != address(0), "INVALID_ORACLE");
|
||||
|
||||
_LP_FEE_RATE_ = uint64(lpFeeRate);
|
||||
_K_ = uint64(k);
|
||||
_I_ = i;
|
||||
|
||||
_IS_OPEN_TWAP_ = isOpenTWAP;
|
||||
if(isOpenTWAP) _BLOCK_TIMESTAMP_LAST_ = uint32(block.timestamp % 2**32);
|
||||
|
||||
_resetTargetAndReserve();
|
||||
}
|
||||
|
||||
|
||||
function tuneParameters(
|
||||
uint256 newLpFeeRate,
|
||||
uint256 newK,
|
||||
uint256 minBaseReserve,
|
||||
uint256 minQuoteReserve
|
||||
) public preventReentrant onlyOwner returns (bool) {
|
||||
require(
|
||||
_BASE_RESERVE_ >= minBaseReserve && _QUOTE_RESERVE_ >= minQuoteReserve,
|
||||
"RESERVE_AMOUNT_IS_NOT_ENOUGH"
|
||||
);
|
||||
require(newLpFeeRate <= 1e18, "LP_FEE_RATE_OUT_OF_RANGE");
|
||||
require(newK <= 1e18, "K_OUT_OF_RANGE");
|
||||
|
||||
_LP_FEE_RATE_ = uint64(newLpFeeRate);
|
||||
_K_ = uint64(newK);
|
||||
|
||||
emit LpFeeRateChange(newLpFeeRate);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
// ============ Version Control ============
|
||||
|
||||
function version() external pure returns (string memory) {
|
||||
return "DPP Oracle 1.0.0";
|
||||
}
|
||||
}
|
||||
120
contracts/DODOPrivatePool/impl/DPPOracle/DPPOracleAdmin.sol
Normal file
120
contracts/DODOPrivatePool/impl/DPPOracle/DPPOracleAdmin.sol
Normal file
@@ -0,0 +1,120 @@
|
||||
/*
|
||||
|
||||
Copyright 2021 DODO ZOO.
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
*/
|
||||
|
||||
pragma solidity 0.6.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
import {IDPPOracle} from "../../intf/IDPPOracle.sol";
|
||||
import {IDODOApproveProxy} from "../../../SmartRoute/DODOApproveProxy.sol";
|
||||
import {InitializableOwnable} from "../../../lib/InitializableOwnable.sol";
|
||||
|
||||
/**
|
||||
* @title DPPOracleAdmin
|
||||
* @author DODO Breeder
|
||||
*
|
||||
* @notice Admin of Oracle DODOPrivatePool
|
||||
*/
|
||||
contract DPPOracleAdmin is InitializableOwnable {
|
||||
address public _DPP_;
|
||||
address public _OPERATOR_;
|
||||
address public _DODO_APPROVE_PROXY_;
|
||||
uint256 public _FREEZE_TIMESTAMP_;
|
||||
|
||||
|
||||
modifier notFreezed() {
|
||||
require(block.timestamp >= _FREEZE_TIMESTAMP_, "ADMIN_FREEZED");
|
||||
_;
|
||||
}
|
||||
|
||||
function init(
|
||||
address owner,
|
||||
address dpp,
|
||||
address operator,
|
||||
address dodoApproveProxy
|
||||
) external {
|
||||
initOwner(owner);
|
||||
_DPP_ = dpp;
|
||||
_OPERATOR_ = operator;
|
||||
_DODO_APPROVE_PROXY_ = dodoApproveProxy;
|
||||
}
|
||||
|
||||
function sync() external notFreezed onlyOwner {
|
||||
IDPPOracle(_DPP_).ratioSync();
|
||||
}
|
||||
|
||||
function setFreezeTimestamp(uint256 timestamp) external notFreezed onlyOwner {
|
||||
_FREEZE_TIMESTAMP_ = timestamp;
|
||||
}
|
||||
|
||||
function setOperator(address newOperator) external notFreezed onlyOwner {
|
||||
_OPERATOR_ = newOperator;
|
||||
}
|
||||
|
||||
function retrieve(
|
||||
address payable to,
|
||||
address token,
|
||||
uint256 amount
|
||||
) external notFreezed onlyOwner {
|
||||
IDPPOracle(_DPP_).retrieve(to, token, amount);
|
||||
}
|
||||
|
||||
function tuneParameters(
|
||||
address operator,
|
||||
uint256 newLpFeeRate,
|
||||
uint256 newK,
|
||||
uint256 minBaseReserve,
|
||||
uint256 minQuoteReserve
|
||||
) external notFreezed returns (bool) {
|
||||
require(
|
||||
msg.sender == _OWNER_ ||
|
||||
(IDODOApproveProxy(_DODO_APPROVE_PROXY_).isAllowedProxy(msg.sender) &&
|
||||
operator == _OPERATOR_),
|
||||
"TUNEPARAMS FORBIDDEN!"
|
||||
);
|
||||
return
|
||||
IDPPOracle(_DPP_).tuneParameters(
|
||||
newLpFeeRate,
|
||||
newK,
|
||||
minBaseReserve,
|
||||
minQuoteReserve
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
function reset(
|
||||
address operator,
|
||||
uint256 newLpFeeRate,
|
||||
uint256 newK,
|
||||
uint256 baseOutAmount,
|
||||
uint256 quoteOutAmount,
|
||||
uint256 minBaseReserve,
|
||||
uint256 minQuoteReserve
|
||||
) external notFreezed returns (bool) {
|
||||
require(
|
||||
msg.sender == _OWNER_ ||
|
||||
(IDODOApproveProxy(_DODO_APPROVE_PROXY_).isAllowedProxy(msg.sender) &&
|
||||
operator == _OPERATOR_),
|
||||
"RESET FORBIDDEN!"
|
||||
);
|
||||
return
|
||||
IDPPOracle(_DPP_).reset(
|
||||
_OWNER_, //only support asset transfer out to owner
|
||||
newLpFeeRate,
|
||||
newK,
|
||||
baseOutAmount,
|
||||
quoteOutAmount,
|
||||
minBaseReserve,
|
||||
minQuoteReserve
|
||||
);
|
||||
}
|
||||
|
||||
// ============ Admin Version Control ============
|
||||
|
||||
function version() external pure returns (string memory) {
|
||||
return "DPPOracle Admin 1.0.0"; // 1.0.0
|
||||
}
|
||||
}
|
||||
89
contracts/DODOPrivatePool/impl/DPPOracle/DPPStorage.sol
Normal file
89
contracts/DODOPrivatePool/impl/DPPOracle/DPPStorage.sol
Normal file
@@ -0,0 +1,89 @@
|
||||
/*
|
||||
|
||||
Copyright 2021 DODO ZOO.
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
*/
|
||||
|
||||
pragma solidity 0.6.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
import {InitializableOwnable} from "../../../lib/InitializableOwnable.sol";
|
||||
import {SafeMath} from "../../../lib/SafeMath.sol";
|
||||
import {DecimalMath} from "../../../lib/DecimalMath.sol";
|
||||
import {ReentrancyGuard} from "../../../lib/ReentrancyGuard.sol";
|
||||
import {IFeeRateModel} from "../../../lib/FeeRateModel.sol";
|
||||
import {IERC20} from "../../../intf/IERC20.sol";
|
||||
import {PMMPricing} from "../../../lib/PMMPricing.sol";
|
||||
import {IOracle} from "../../intf/IOracle.sol";
|
||||
|
||||
contract DPPStorage is InitializableOwnable, ReentrancyGuard {
|
||||
using SafeMath for uint256;
|
||||
|
||||
bool public _IS_OPEN_TWAP_ = false;
|
||||
|
||||
// ============ Core Address ============
|
||||
|
||||
address public _MAINTAINER_;
|
||||
|
||||
IERC20 public _BASE_TOKEN_;
|
||||
IERC20 public _QUOTE_TOKEN_;
|
||||
|
||||
uint112 public _BASE_RESERVE_;
|
||||
uint112 public _QUOTE_RESERVE_;
|
||||
uint32 public _BLOCK_TIMESTAMP_LAST_;
|
||||
|
||||
uint112 public _BASE_TARGET_;
|
||||
uint112 public _QUOTE_TARGET_;
|
||||
uint32 public _RState_;
|
||||
|
||||
uint256 public _BASE_PRICE_CUMULATIVE_LAST_;
|
||||
|
||||
// ============ Variables for Pricing ============
|
||||
|
||||
IFeeRateModel public _MT_FEE_RATE_MODEL_;
|
||||
|
||||
uint64 public _LP_FEE_RATE_;
|
||||
uint64 public _K_;
|
||||
address public _I_;
|
||||
|
||||
// ============ Helper Functions ============
|
||||
|
||||
function getPMMState() public view returns (PMMPricing.PMMState memory state) {
|
||||
(state.i,,,) = IOracle(_I_).getPrice(address(_BASE_TOKEN_));
|
||||
state.K = _K_;
|
||||
state.B = _BASE_RESERVE_;
|
||||
state.Q = _QUOTE_RESERVE_;
|
||||
state.B0 = _BASE_TARGET_;
|
||||
state.Q0 = _QUOTE_TARGET_;
|
||||
state.R = PMMPricing.RState(_RState_);
|
||||
PMMPricing.adjustedTarget(state);
|
||||
}
|
||||
|
||||
function getPMMStateForCall()
|
||||
external
|
||||
view
|
||||
returns (
|
||||
uint256 i,
|
||||
uint256 K,
|
||||
uint256 B,
|
||||
uint256 Q,
|
||||
uint256 B0,
|
||||
uint256 Q0,
|
||||
uint256 R
|
||||
)
|
||||
{
|
||||
PMMPricing.PMMState memory state = getPMMState();
|
||||
i = state.i;
|
||||
K = state.K;
|
||||
B = state.B;
|
||||
Q = state.Q;
|
||||
B0 = state.B0;
|
||||
Q0 = state.Q0;
|
||||
R = uint256(state.R);
|
||||
}
|
||||
|
||||
function getMidPrice() public view returns (uint256 midPrice) {
|
||||
return PMMPricing.getMidPrice(getPMMState());
|
||||
}
|
||||
}
|
||||
255
contracts/DODOPrivatePool/impl/DPPOracle/DPPTrader.sol
Normal file
255
contracts/DODOPrivatePool/impl/DPPOracle/DPPTrader.sol
Normal file
@@ -0,0 +1,255 @@
|
||||
/*
|
||||
|
||||
Copyright 2021 DODO ZOO.
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
*/
|
||||
|
||||
pragma solidity 0.6.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
import {DPPVault} from "./DPPVault.sol";
|
||||
import {SafeMath} from "../../../lib/SafeMath.sol";
|
||||
import {DecimalMath} from "../../../lib/DecimalMath.sol";
|
||||
import {PMMPricing} from "../../../lib/PMMPricing.sol";
|
||||
import {IDODOCallee} from "../../../intf/IDODOCallee.sol";
|
||||
import {IOracle} from "../../intf/IOracle.sol";
|
||||
|
||||
contract DPPTrader is DPPVault {
|
||||
using SafeMath for uint256;
|
||||
|
||||
// ============ Events ============
|
||||
|
||||
event DODOSwap(
|
||||
address fromToken,
|
||||
address toToken,
|
||||
uint256 fromAmount,
|
||||
uint256 toAmount,
|
||||
address trader,
|
||||
address receiver
|
||||
);
|
||||
|
||||
event DODOFlashLoan(
|
||||
address borrower,
|
||||
address assetTo,
|
||||
uint256 baseAmount,
|
||||
uint256 quoteAmount
|
||||
);
|
||||
|
||||
event RChange(PMMPricing.RState newRState);
|
||||
|
||||
modifier isOraclePriceValid() {
|
||||
(, bool isValid, bool isStale,) = IOracle(_I_).getPrice(address(_BASE_TOKEN_));
|
||||
require(isValid, "ORACLE_PRICE_INVALID");
|
||||
require(!isStale, "ORACLE_PRICE_STALE");
|
||||
_;
|
||||
}
|
||||
|
||||
// ============ Trade Functions ============
|
||||
|
||||
function sellBase(address to)
|
||||
external
|
||||
preventReentrant
|
||||
isOraclePriceValid
|
||||
returns (uint256 receiveQuoteAmount)
|
||||
{
|
||||
uint256 baseBalance = _BASE_TOKEN_.balanceOf(address(this));
|
||||
uint256 baseInput = baseBalance.sub(uint256(_BASE_RESERVE_));
|
||||
uint256 mtFee;
|
||||
uint256 newBaseTarget;
|
||||
PMMPricing.RState newRState;
|
||||
(receiveQuoteAmount, mtFee, newRState, newBaseTarget) = querySellBase(tx.origin, baseInput);
|
||||
|
||||
_transferQuoteOut(to, receiveQuoteAmount);
|
||||
_transferQuoteOut(_MAINTAINER_, mtFee);
|
||||
|
||||
// update TARGET
|
||||
if (_RState_ != uint32(newRState)) {
|
||||
require(newBaseTarget <= uint112(-1),"OVERFLOW");
|
||||
_BASE_TARGET_ = uint112(newBaseTarget);
|
||||
_RState_ = uint32(newRState);
|
||||
emit RChange(newRState);
|
||||
}
|
||||
|
||||
_setReserve(baseBalance, _QUOTE_TOKEN_.balanceOf(address(this)));
|
||||
|
||||
emit DODOSwap(
|
||||
address(_BASE_TOKEN_),
|
||||
address(_QUOTE_TOKEN_),
|
||||
baseInput,
|
||||
receiveQuoteAmount,
|
||||
msg.sender,
|
||||
to
|
||||
);
|
||||
}
|
||||
|
||||
function sellQuote(address to)
|
||||
external
|
||||
preventReentrant
|
||||
isOraclePriceValid
|
||||
returns (uint256 receiveBaseAmount)
|
||||
{
|
||||
uint256 quoteBalance = _QUOTE_TOKEN_.balanceOf(address(this));
|
||||
uint256 quoteInput = quoteBalance.sub(uint256(_QUOTE_RESERVE_));
|
||||
uint256 mtFee;
|
||||
uint256 newQuoteTarget;
|
||||
PMMPricing.RState newRState;
|
||||
(receiveBaseAmount, mtFee, newRState, newQuoteTarget) = querySellQuote(
|
||||
tx.origin,
|
||||
quoteInput
|
||||
);
|
||||
|
||||
_transferBaseOut(to, receiveBaseAmount);
|
||||
_transferBaseOut(_MAINTAINER_, mtFee);
|
||||
|
||||
// update TARGET
|
||||
if (_RState_ != uint32(newRState)) {
|
||||
require(newQuoteTarget <= uint112(-1),"OVERFLOW");
|
||||
_QUOTE_TARGET_ = uint112(newQuoteTarget);
|
||||
_RState_ = uint32(newRState);
|
||||
emit RChange(newRState);
|
||||
}
|
||||
|
||||
_setReserve(_BASE_TOKEN_.balanceOf(address(this)), quoteBalance);
|
||||
|
||||
emit DODOSwap(
|
||||
address(_QUOTE_TOKEN_),
|
||||
address(_BASE_TOKEN_),
|
||||
quoteInput,
|
||||
receiveBaseAmount,
|
||||
msg.sender,
|
||||
to
|
||||
);
|
||||
}
|
||||
|
||||
function flashLoan(
|
||||
uint256 baseAmount,
|
||||
uint256 quoteAmount,
|
||||
address _assetTo,
|
||||
bytes calldata data
|
||||
) external isOraclePriceValid preventReentrant {
|
||||
address assetTo = _assetTo;
|
||||
_transferBaseOut(assetTo, baseAmount);
|
||||
_transferQuoteOut(assetTo, quoteAmount);
|
||||
|
||||
if (data.length > 0)
|
||||
IDODOCallee(assetTo).DPPFlashLoanCall(msg.sender, baseAmount, quoteAmount, data);
|
||||
|
||||
uint256 baseBalance = _BASE_TOKEN_.balanceOf(address(this));
|
||||
uint256 quoteBalance = _QUOTE_TOKEN_.balanceOf(address(this));
|
||||
|
||||
// no input -> pure loss
|
||||
require(
|
||||
baseBalance >= _BASE_RESERVE_ || quoteBalance >= _QUOTE_RESERVE_,
|
||||
"FLASH_LOAN_FAILED"
|
||||
);
|
||||
|
||||
// sell quote case
|
||||
// quote input + base output
|
||||
if (baseBalance < _BASE_RESERVE_) {
|
||||
uint256 quoteInput = quoteBalance.sub(uint256(_QUOTE_RESERVE_));
|
||||
(
|
||||
uint256 receiveBaseAmount,
|
||||
uint256 mtFee,
|
||||
PMMPricing.RState newRState,
|
||||
uint256 newQuoteTarget
|
||||
) = querySellQuote(tx.origin, quoteInput); // revert if quoteBalance<quoteReserve
|
||||
require(uint256(_BASE_RESERVE_).sub(baseBalance) <= receiveBaseAmount, "FLASH_LOAN_FAILED");
|
||||
|
||||
_transferBaseOut(_MAINTAINER_, mtFee);
|
||||
if (_RState_ != uint32(newRState)) {
|
||||
require(newQuoteTarget <= uint112(-1),"OVERFLOW");
|
||||
_QUOTE_TARGET_ = uint112(newQuoteTarget);
|
||||
_RState_ = uint32(newRState);
|
||||
emit RChange(newRState);
|
||||
}
|
||||
emit DODOSwap(
|
||||
address(_QUOTE_TOKEN_),
|
||||
address(_BASE_TOKEN_),
|
||||
quoteInput,
|
||||
receiveBaseAmount,
|
||||
msg.sender,
|
||||
assetTo
|
||||
);
|
||||
}
|
||||
|
||||
// sell base case
|
||||
// base input + quote output
|
||||
if (quoteBalance < _QUOTE_RESERVE_) {
|
||||
uint256 baseInput = baseBalance.sub(uint256(_BASE_RESERVE_));
|
||||
(
|
||||
uint256 receiveQuoteAmount,
|
||||
uint256 mtFee,
|
||||
PMMPricing.RState newRState,
|
||||
uint256 newBaseTarget
|
||||
) = querySellBase(tx.origin, baseInput); // revert if baseBalance<baseReserve
|
||||
require(uint256(_QUOTE_RESERVE_).sub(quoteBalance) <= receiveQuoteAmount, "FLASH_LOAN_FAILED");
|
||||
|
||||
_transferQuoteOut(_MAINTAINER_, mtFee);
|
||||
if (_RState_ != uint32(newRState)) {
|
||||
require(newBaseTarget <= uint112(-1),"OVERFLOW");
|
||||
_BASE_TARGET_ = uint112(newBaseTarget);
|
||||
_RState_ = uint32(newRState);
|
||||
emit RChange(newRState);
|
||||
}
|
||||
emit DODOSwap(
|
||||
address(_BASE_TOKEN_),
|
||||
address(_QUOTE_TOKEN_),
|
||||
baseInput,
|
||||
receiveQuoteAmount,
|
||||
msg.sender,
|
||||
assetTo
|
||||
);
|
||||
}
|
||||
|
||||
_sync();
|
||||
|
||||
emit DODOFlashLoan(msg.sender, assetTo, baseAmount, quoteAmount);
|
||||
}
|
||||
|
||||
// ============ Query Functions ============
|
||||
|
||||
function querySellBase(address trader, uint256 payBaseAmount)
|
||||
public
|
||||
view
|
||||
returns (
|
||||
uint256 receiveQuoteAmount,
|
||||
uint256 mtFee,
|
||||
PMMPricing.RState newRState,
|
||||
uint256 newBaseTarget
|
||||
)
|
||||
{
|
||||
PMMPricing.PMMState memory state = getPMMState();
|
||||
(receiveQuoteAmount, newRState) = PMMPricing.sellBaseToken(state, payBaseAmount);
|
||||
|
||||
uint256 lpFeeRate = _LP_FEE_RATE_;
|
||||
uint256 mtFeeRate = _MT_FEE_RATE_MODEL_.getFeeRate(trader);
|
||||
mtFee = DecimalMath.mulFloor(receiveQuoteAmount, mtFeeRate);
|
||||
receiveQuoteAmount = receiveQuoteAmount
|
||||
.sub(DecimalMath.mulFloor(receiveQuoteAmount, lpFeeRate))
|
||||
.sub(mtFee);
|
||||
newBaseTarget = state.B0;
|
||||
}
|
||||
|
||||
function querySellQuote(address trader, uint256 payQuoteAmount)
|
||||
public
|
||||
view
|
||||
returns (
|
||||
uint256 receiveBaseAmount,
|
||||
uint256 mtFee,
|
||||
PMMPricing.RState newRState,
|
||||
uint256 newQuoteTarget
|
||||
)
|
||||
{
|
||||
PMMPricing.PMMState memory state = getPMMState();
|
||||
(receiveBaseAmount, newRState) = PMMPricing.sellQuoteToken(state, payQuoteAmount);
|
||||
|
||||
uint256 lpFeeRate = _LP_FEE_RATE_;
|
||||
uint256 mtFeeRate = _MT_FEE_RATE_MODEL_.getFeeRate(trader);
|
||||
mtFee = DecimalMath.mulFloor(receiveBaseAmount, mtFeeRate);
|
||||
receiveBaseAmount = receiveBaseAmount
|
||||
.sub(DecimalMath.mulFloor(receiveBaseAmount, lpFeeRate))
|
||||
.sub(mtFee);
|
||||
newQuoteTarget = state.Q0;
|
||||
}
|
||||
}
|
||||
171
contracts/DODOPrivatePool/impl/DPPOracle/DPPVault.sol
Normal file
171
contracts/DODOPrivatePool/impl/DPPOracle/DPPVault.sol
Normal file
@@ -0,0 +1,171 @@
|
||||
/*
|
||||
|
||||
Copyright 2020 DODO ZOO.
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
*/
|
||||
|
||||
pragma solidity 0.6.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
import {DPPStorage} from "./DPPStorage.sol";
|
||||
import {IERC20} from "../../../intf/IERC20.sol";
|
||||
import {IDODOCallee} from "../../../intf/IDODOCallee.sol";
|
||||
import {SafeMath} from "../../../lib/SafeMath.sol";
|
||||
import {DecimalMath} from "../../../lib/DecimalMath.sol";
|
||||
import {SafeERC20} from "../../../lib/SafeERC20.sol";
|
||||
import {PMMPricing} from "../../../lib/PMMPricing.sol";
|
||||
|
||||
contract DPPVault is DPPStorage {
|
||||
using SafeMath for uint256;
|
||||
using SafeERC20 for IERC20;
|
||||
|
||||
// ============ Events ============
|
||||
|
||||
event LpFeeRateChange(uint256 newLpFeeRate);
|
||||
|
||||
// ============ View Functions ============
|
||||
|
||||
function getVaultReserve() external view returns (uint256 baseReserve, uint256 quoteReserve) {
|
||||
baseReserve = _BASE_RESERVE_;
|
||||
quoteReserve = _QUOTE_RESERVE_;
|
||||
}
|
||||
|
||||
function getUserFeeRate(address user)
|
||||
external
|
||||
view
|
||||
returns (uint256 lpFeeRate, uint256 mtFeeRate)
|
||||
{
|
||||
lpFeeRate = _LP_FEE_RATE_;
|
||||
mtFeeRate = _MT_FEE_RATE_MODEL_.getFeeRate(user);
|
||||
}
|
||||
|
||||
// ============ Get Input ============
|
||||
|
||||
function getBaseInput() public view returns (uint256 input) {
|
||||
return _BASE_TOKEN_.balanceOf(address(this)).sub(uint256(_BASE_RESERVE_));
|
||||
}
|
||||
|
||||
function getQuoteInput() public view returns (uint256 input) {
|
||||
return _QUOTE_TOKEN_.balanceOf(address(this)).sub(uint256(_QUOTE_RESERVE_));
|
||||
}
|
||||
|
||||
// ============ TWAP UPDATE ===========
|
||||
|
||||
function _twapUpdate() internal {
|
||||
uint32 blockTimestamp = uint32(block.timestamp % 2**32);
|
||||
uint32 timeElapsed = blockTimestamp - _BLOCK_TIMESTAMP_LAST_;
|
||||
if (timeElapsed > 0 && _BASE_RESERVE_ != 0 && _QUOTE_RESERVE_ != 0) {
|
||||
_BASE_PRICE_CUMULATIVE_LAST_ += getMidPrice() * timeElapsed;
|
||||
}
|
||||
_BLOCK_TIMESTAMP_LAST_ = blockTimestamp;
|
||||
}
|
||||
|
||||
// ============ Set Status ============
|
||||
|
||||
function _setReserve(uint256 baseReserve, uint256 quoteReserve) internal {
|
||||
require(baseReserve <= uint112(-1) && quoteReserve <= uint112(-1), "OVERFLOW");
|
||||
_BASE_RESERVE_ = uint112(baseReserve);
|
||||
_QUOTE_RESERVE_ = uint112(quoteReserve);
|
||||
|
||||
if(_IS_OPEN_TWAP_) _twapUpdate();
|
||||
}
|
||||
|
||||
function _sync() internal {
|
||||
uint256 baseBalance = _BASE_TOKEN_.balanceOf(address(this));
|
||||
uint256 quoteBalance = _QUOTE_TOKEN_.balanceOf(address(this));
|
||||
|
||||
require(baseBalance <= uint112(-1) && quoteBalance <= uint112(-1), "OVERFLOW");
|
||||
|
||||
if (baseBalance != _BASE_RESERVE_) {
|
||||
_BASE_RESERVE_ = uint112(baseBalance);
|
||||
}
|
||||
if (quoteBalance != _QUOTE_RESERVE_) {
|
||||
_QUOTE_RESERVE_ = uint112(quoteBalance);
|
||||
}
|
||||
|
||||
if(_IS_OPEN_TWAP_) _twapUpdate();
|
||||
}
|
||||
|
||||
function _resetTargetAndReserve() internal {
|
||||
uint256 baseBalance = _BASE_TOKEN_.balanceOf(address(this));
|
||||
uint256 quoteBalance = _QUOTE_TOKEN_.balanceOf(address(this));
|
||||
|
||||
require(baseBalance <= uint112(-1) && quoteBalance <= uint112(-1), "OVERFLOW");
|
||||
|
||||
_BASE_RESERVE_ = uint112(baseBalance);
|
||||
_QUOTE_RESERVE_ = uint112(quoteBalance);
|
||||
_BASE_TARGET_ = uint112(baseBalance);
|
||||
_QUOTE_TARGET_ = uint112(quoteBalance);
|
||||
_RState_ = uint32(PMMPricing.RState.ONE);
|
||||
|
||||
if(_IS_OPEN_TWAP_) _twapUpdate();
|
||||
}
|
||||
|
||||
function ratioSync() external preventReentrant onlyOwner {
|
||||
uint256 baseBalance = _BASE_TOKEN_.balanceOf(address(this));
|
||||
uint256 quoteBalance = _QUOTE_TOKEN_.balanceOf(address(this));
|
||||
|
||||
require(baseBalance <= uint112(-1) && quoteBalance <= uint112(-1), "OVERFLOW");
|
||||
|
||||
if (baseBalance != _BASE_RESERVE_) {
|
||||
_BASE_TARGET_ = uint112(uint256(_BASE_TARGET_).mul(baseBalance).div(uint256(_BASE_RESERVE_)));
|
||||
_BASE_RESERVE_ = uint112(baseBalance);
|
||||
}
|
||||
if (quoteBalance != _QUOTE_RESERVE_) {
|
||||
_QUOTE_TARGET_ = uint112(uint256(_QUOTE_TARGET_).mul(quoteBalance).div(uint256(_QUOTE_RESERVE_)));
|
||||
_QUOTE_RESERVE_ = uint112(quoteBalance);
|
||||
}
|
||||
|
||||
if(_IS_OPEN_TWAP_) _twapUpdate();
|
||||
}
|
||||
|
||||
function reset(
|
||||
address assetTo,
|
||||
uint256 newLpFeeRate,
|
||||
uint256 newK,
|
||||
uint256 baseOutAmount,
|
||||
uint256 quoteOutAmount,
|
||||
uint256 minBaseReserve,
|
||||
uint256 minQuoteReserve
|
||||
) public preventReentrant onlyOwner returns (bool) {
|
||||
require(
|
||||
_BASE_RESERVE_ >= minBaseReserve && _QUOTE_RESERVE_ >= minQuoteReserve,
|
||||
"RESERVE_AMOUNT_IS_NOT_ENOUGH"
|
||||
);
|
||||
require(newLpFeeRate <= 1e18, "LP_FEE_RATE_OUT_OF_RANGE");
|
||||
require(newK <= 1e18, "K_OUT_OF_RANGE");
|
||||
|
||||
_LP_FEE_RATE_ = uint64(newLpFeeRate);
|
||||
_K_ = uint64(newK);
|
||||
|
||||
_transferBaseOut(assetTo, baseOutAmount);
|
||||
_transferQuoteOut(assetTo, quoteOutAmount);
|
||||
_resetTargetAndReserve();
|
||||
emit LpFeeRateChange(newLpFeeRate);
|
||||
return true;
|
||||
}
|
||||
|
||||
// ============ Asset Out ============
|
||||
|
||||
function _transferBaseOut(address to, uint256 amount) internal {
|
||||
if (amount > 0) {
|
||||
_BASE_TOKEN_.safeTransfer(to, amount);
|
||||
}
|
||||
}
|
||||
|
||||
function _transferQuoteOut(address to, uint256 amount) internal {
|
||||
if (amount > 0) {
|
||||
_QUOTE_TOKEN_.safeTransfer(to, amount);
|
||||
}
|
||||
}
|
||||
|
||||
function retrieve(
|
||||
address to,
|
||||
address token,
|
||||
uint256 amount
|
||||
) external preventReentrant onlyOwner {
|
||||
require(token != address(_BASE_TOKEN_) && token != address(_QUOTE_TOKEN_), "USE_RESET");
|
||||
IERC20(token).safeTransfer(to, amount);
|
||||
}
|
||||
}
|
||||
52
contracts/DODOPrivatePool/intf/IDPPOracle.sol
Normal file
52
contracts/DODOPrivatePool/intf/IDPPOracle.sol
Normal file
@@ -0,0 +1,52 @@
|
||||
/*
|
||||
|
||||
Copyright 2021 DODO ZOO.
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
*/
|
||||
|
||||
pragma solidity 0.6.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
interface IDPPOracle {
|
||||
function init(
|
||||
address owner,
|
||||
address maintainer,
|
||||
address baseTokenAddress,
|
||||
address quoteTokenAddress,
|
||||
uint256 lpFeeRate,
|
||||
address mtFeeRateModel,
|
||||
uint256 k,
|
||||
address i, //oracle address
|
||||
bool isOpenTWAP
|
||||
) external;
|
||||
|
||||
function _MT_FEE_RATE_MODEL_() external returns (address);
|
||||
|
||||
//=========== admin ==========
|
||||
function ratioSync() external;
|
||||
|
||||
function retrieve(
|
||||
address payable to,
|
||||
address token,
|
||||
uint256 amount
|
||||
) external;
|
||||
|
||||
function reset(
|
||||
address assetTo,
|
||||
uint256 newLpFeeRate,
|
||||
uint256 newK,
|
||||
uint256 baseOutAmount,
|
||||
uint256 quoteOutAmount,
|
||||
uint256 minBaseReserve,
|
||||
uint256 minQuoteReserve
|
||||
) external returns (bool);
|
||||
|
||||
|
||||
function tuneParameters(
|
||||
uint256 newLpFeeRate,
|
||||
uint256 newK,
|
||||
uint256 minBaseReserve,
|
||||
uint256 minQuoteReserve
|
||||
) external returns (bool);
|
||||
}
|
||||
12
contracts/DODOPrivatePool/intf/IOracle.sol
Normal file
12
contracts/DODOPrivatePool/intf/IOracle.sol
Normal file
@@ -0,0 +1,12 @@
|
||||
/*
|
||||
|
||||
Copyright 2021 DODO ZOO.
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
*/
|
||||
|
||||
pragma solidity 0.6.9;
|
||||
|
||||
interface IOracle {
|
||||
function getPrice(address base) external view returns (uint256 latestPrice,bool isValid,bool isStale,uint256 timestamp);
|
||||
}
|
||||
286
contracts/DODOToken/DODOMineV3/BaseMine.sol
Normal file
286
contracts/DODOToken/DODOMineV3/BaseMine.sol
Normal file
@@ -0,0 +1,286 @@
|
||||
/*
|
||||
|
||||
Copyright 2021 DODO ZOO.
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
*/
|
||||
pragma solidity 0.6.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
import {SafeERC20} from "../../lib/SafeERC20.sol";
|
||||
import {IERC20} from "../../intf/IERC20.sol";
|
||||
import {SafeMath} from "../../lib/SafeMath.sol";
|
||||
import {DecimalMath} from "../../lib/DecimalMath.sol";
|
||||
import {InitializableOwnable} from "../../lib/InitializableOwnable.sol";
|
||||
import {IRewardVault, RewardVault} from "./RewardVault.sol";
|
||||
|
||||
contract BaseMine is InitializableOwnable {
|
||||
using SafeERC20 for IERC20;
|
||||
using SafeMath for uint256;
|
||||
|
||||
// ============ Storage ============
|
||||
|
||||
struct RewardTokenInfo {
|
||||
address rewardToken;
|
||||
uint256 startBlock;
|
||||
uint256 endBlock;
|
||||
address rewardVault;
|
||||
uint256 rewardPerBlock;
|
||||
uint256 accRewardPerShare;
|
||||
uint256 lastRewardBlock;
|
||||
uint256 workThroughReward;
|
||||
uint256 lastFlagBlock;
|
||||
mapping(address => uint256) userRewardPerSharePaid;
|
||||
mapping(address => uint256) userRewards;
|
||||
}
|
||||
|
||||
RewardTokenInfo[] public rewardTokenInfos;
|
||||
|
||||
uint256 internal _totalSupply;
|
||||
mapping(address => uint256) internal _balances;
|
||||
|
||||
// ============ Event =============
|
||||
|
||||
event Claim(uint256 indexed i, address indexed user, uint256 reward);
|
||||
event UpdateReward(uint256 indexed i, uint256 rewardPerBlock);
|
||||
event UpdateEndBlock(uint256 indexed i, uint256 endBlock);
|
||||
event NewRewardToken(uint256 indexed i, address rewardToken);
|
||||
event RemoveRewardToken(address rewardToken);
|
||||
event WithdrawLeftOver(address owner, uint256 i);
|
||||
|
||||
// ============ View ============
|
||||
|
||||
function getPendingReward(address user, uint256 i) public view returns (uint256) {
|
||||
require(i<rewardTokenInfos.length, "DODOMineV3: REWARD_ID_NOT_FOUND");
|
||||
RewardTokenInfo storage rt = rewardTokenInfos[i];
|
||||
uint256 accRewardPerShare = rt.accRewardPerShare;
|
||||
if (rt.lastRewardBlock != block.number) {
|
||||
accRewardPerShare = _getAccRewardPerShare(i);
|
||||
}
|
||||
return
|
||||
DecimalMath.mulFloor(
|
||||
balanceOf(user),
|
||||
accRewardPerShare.sub(rt.userRewardPerSharePaid[user])
|
||||
).add(rt.userRewards[user]);
|
||||
}
|
||||
|
||||
function getPendingRewardByToken(address user, address rewardToken) external view returns (uint256) {
|
||||
return getPendingReward(user, getIdByRewardToken(rewardToken));
|
||||
}
|
||||
|
||||
function totalSupply() public view returns (uint256) {
|
||||
return _totalSupply;
|
||||
}
|
||||
|
||||
function balanceOf(address user) public view returns (uint256) {
|
||||
return _balances[user];
|
||||
}
|
||||
|
||||
function getRewardTokenById(uint256 i) external view returns (address) {
|
||||
require(i<rewardTokenInfos.length, "DODOMineV3: REWARD_ID_NOT_FOUND");
|
||||
RewardTokenInfo memory rt = rewardTokenInfos[i];
|
||||
return rt.rewardToken;
|
||||
}
|
||||
|
||||
function getIdByRewardToken(address rewardToken) public view returns(uint256) {
|
||||
uint256 len = rewardTokenInfos.length;
|
||||
for (uint256 i = 0; i < len; i++) {
|
||||
if (rewardToken == rewardTokenInfos[i].rewardToken) {
|
||||
return i;
|
||||
}
|
||||
}
|
||||
require(false, "DODOMineV3: TOKEN_NOT_FOUND");
|
||||
}
|
||||
|
||||
function getRewardNum() external view returns(uint256) {
|
||||
return rewardTokenInfos.length;
|
||||
}
|
||||
|
||||
function getVaultByRewardToken(address rewardToken) public view returns(address) {
|
||||
uint256 len = rewardTokenInfos.length;
|
||||
for (uint256 i = 0; i < len; i++) {
|
||||
if (rewardToken == rewardTokenInfos[i].rewardToken) {
|
||||
return rewardTokenInfos[i].rewardVault;
|
||||
}
|
||||
}
|
||||
require(false, "DODOMineV3: TOKEN_NOT_FOUND");
|
||||
}
|
||||
|
||||
function getVaultDebtByRewardToken(address rewardToken) public view returns(uint256) {
|
||||
uint256 len = rewardTokenInfos.length;
|
||||
for (uint256 i = 0; i < len; i++) {
|
||||
if (rewardToken == rewardTokenInfos[i].rewardToken) {
|
||||
uint256 totalDepositReward = IRewardVault(rewardTokenInfos[i].rewardVault)._TOTAL_REWARD_();
|
||||
uint256 gap = rewardTokenInfos[i].endBlock.sub(rewardTokenInfos[i].lastFlagBlock);
|
||||
uint256 totalReward = rewardTokenInfos[i].workThroughReward.add(gap.mul(rewardTokenInfos[i].rewardPerBlock));
|
||||
if(totalDepositReward >= totalReward) {
|
||||
return 0;
|
||||
}else {
|
||||
return totalReward.sub(totalDepositReward);
|
||||
}
|
||||
}
|
||||
}
|
||||
require(false, "DODOMineV3: TOKEN_NOT_FOUND");
|
||||
}
|
||||
|
||||
// ============ Claim ============
|
||||
|
||||
function claimReward(uint256 i) public {
|
||||
require(i<rewardTokenInfos.length, "DODOMineV3: REWARD_ID_NOT_FOUND");
|
||||
_updateReward(msg.sender, i);
|
||||
RewardTokenInfo storage rt = rewardTokenInfos[i];
|
||||
uint256 reward = rt.userRewards[msg.sender];
|
||||
if (reward > 0) {
|
||||
rt.userRewards[msg.sender] = 0;
|
||||
IRewardVault(rt.rewardVault).reward(msg.sender, reward);
|
||||
emit Claim(i, msg.sender, reward);
|
||||
}
|
||||
}
|
||||
|
||||
function claimAllRewards() external {
|
||||
uint256 len = rewardTokenInfos.length;
|
||||
for (uint256 i = 0; i < len; i++) {
|
||||
claimReward(i);
|
||||
}
|
||||
}
|
||||
|
||||
// =============== Ownable ================
|
||||
|
||||
function addRewardToken(
|
||||
address rewardToken,
|
||||
uint256 rewardPerBlock,
|
||||
uint256 startBlock,
|
||||
uint256 endBlock
|
||||
) external onlyOwner {
|
||||
require(rewardToken != address(0), "DODOMineV3: TOKEN_INVALID");
|
||||
require(startBlock > block.number, "DODOMineV3: START_BLOCK_INVALID");
|
||||
require(endBlock > startBlock, "DODOMineV3: DURATION_INVALID");
|
||||
|
||||
uint256 len = rewardTokenInfos.length;
|
||||
for (uint256 i = 0; i < len; i++) {
|
||||
require(
|
||||
rewardToken != rewardTokenInfos[i].rewardToken,
|
||||
"DODOMineV3: TOKEN_ALREADY_ADDED"
|
||||
);
|
||||
}
|
||||
|
||||
RewardTokenInfo storage rt = rewardTokenInfos.push();
|
||||
rt.rewardToken = rewardToken;
|
||||
rt.startBlock = startBlock;
|
||||
rt.lastFlagBlock = startBlock;
|
||||
rt.endBlock = endBlock;
|
||||
rt.rewardPerBlock = rewardPerBlock;
|
||||
rt.rewardVault = address(new RewardVault(rewardToken));
|
||||
|
||||
uint256 rewardAmount = rewardPerBlock.mul(endBlock.sub(startBlock));
|
||||
IERC20(rewardToken).safeTransfer(rt.rewardVault, rewardAmount);
|
||||
RewardVault(rt.rewardVault).syncValue();
|
||||
|
||||
emit NewRewardToken(len, rewardToken);
|
||||
}
|
||||
|
||||
function setEndBlock(uint256 i, uint256 newEndBlock)
|
||||
external
|
||||
onlyOwner
|
||||
{
|
||||
require(i < rewardTokenInfos.length, "DODOMineV3: REWARD_ID_NOT_FOUND");
|
||||
_updateReward(address(0), i);
|
||||
RewardTokenInfo storage rt = rewardTokenInfos[i];
|
||||
|
||||
|
||||
uint256 totalDepositReward = RewardVault(rt.rewardVault)._TOTAL_REWARD_();
|
||||
uint256 gap = newEndBlock.sub(rt.lastFlagBlock);
|
||||
uint256 totalReward = rt.workThroughReward.add(gap.mul(rt.rewardPerBlock));
|
||||
require(totalDepositReward >= totalReward, "DODOMineV3: REWARD_NOT_ENOUGH");
|
||||
|
||||
require(block.number < newEndBlock, "DODOMineV3: END_BLOCK_INVALID");
|
||||
require(block.number > rt.startBlock, "DODOMineV3: NOT_START");
|
||||
require(block.number < rt.endBlock, "DODOMineV3: ALREADY_CLOSE");
|
||||
|
||||
rt.endBlock = newEndBlock;
|
||||
emit UpdateEndBlock(i, newEndBlock);
|
||||
}
|
||||
|
||||
function setReward(uint256 i, uint256 newRewardPerBlock)
|
||||
external
|
||||
onlyOwner
|
||||
{
|
||||
require(i < rewardTokenInfos.length, "DODOMineV3: REWARD_ID_NOT_FOUND");
|
||||
_updateReward(address(0), i);
|
||||
RewardTokenInfo storage rt = rewardTokenInfos[i];
|
||||
|
||||
require(block.number < rt.endBlock, "DODOMineV3: ALREADY_CLOSE");
|
||||
|
||||
rt.workThroughReward = rt.workThroughReward.add((block.number.sub(rt.lastFlagBlock)).mul(rt.rewardPerBlock));
|
||||
rt.rewardPerBlock = newRewardPerBlock;
|
||||
rt.lastFlagBlock = block.number;
|
||||
|
||||
uint256 totalDepositReward = RewardVault(rt.rewardVault)._TOTAL_REWARD_();
|
||||
uint256 gap = rt.endBlock.sub(block.number);
|
||||
uint256 totalReward = rt.workThroughReward.add(gap.mul(newRewardPerBlock));
|
||||
require(totalDepositReward >= totalReward, "DODOMineV3: REWARD_NOT_ENOUGH");
|
||||
|
||||
emit UpdateReward(i, newRewardPerBlock);
|
||||
}
|
||||
|
||||
function withdrawLeftOver(uint256 i, uint256 amount) external onlyOwner {
|
||||
require(i < rewardTokenInfos.length, "DODOMineV3: REWARD_ID_NOT_FOUND");
|
||||
|
||||
RewardTokenInfo storage rt = rewardTokenInfos[i];
|
||||
require(block.number > rt.endBlock, "DODOMineV3: MINING_NOT_FINISHED");
|
||||
|
||||
IRewardVault(rt.rewardVault).withdrawLeftOver(msg.sender,amount);
|
||||
|
||||
emit WithdrawLeftOver(msg.sender, i);
|
||||
}
|
||||
|
||||
|
||||
function directTransferOwnership(address newOwner) external onlyOwner {
|
||||
require(newOwner != address(0), "DODOMineV3: ZERO_ADDRESS");
|
||||
emit OwnershipTransferred(_OWNER_, newOwner);
|
||||
_OWNER_ = newOwner;
|
||||
}
|
||||
|
||||
// ============ Internal ============
|
||||
|
||||
function _updateReward(address user, uint256 i) internal {
|
||||
RewardTokenInfo storage rt = rewardTokenInfos[i];
|
||||
if (rt.lastRewardBlock != block.number){
|
||||
rt.accRewardPerShare = _getAccRewardPerShare(i);
|
||||
rt.lastRewardBlock = block.number;
|
||||
}
|
||||
if (user != address(0)) {
|
||||
rt.userRewards[user] = getPendingReward(user, i);
|
||||
rt.userRewardPerSharePaid[user] = rt.accRewardPerShare;
|
||||
}
|
||||
}
|
||||
|
||||
function _updateAllReward(address user) internal {
|
||||
uint256 len = rewardTokenInfos.length;
|
||||
for (uint256 i = 0; i < len; i++) {
|
||||
_updateReward(user, i);
|
||||
}
|
||||
}
|
||||
|
||||
function _getUnrewardBlockNum(uint256 i) internal view returns (uint256) {
|
||||
RewardTokenInfo memory rt = rewardTokenInfos[i];
|
||||
if (block.number < rt.startBlock || rt.lastRewardBlock > rt.endBlock) {
|
||||
return 0;
|
||||
}
|
||||
uint256 start = rt.lastRewardBlock < rt.startBlock ? rt.startBlock : rt.lastRewardBlock;
|
||||
uint256 end = rt.endBlock < block.number ? rt.endBlock : block.number;
|
||||
return end.sub(start);
|
||||
}
|
||||
|
||||
function _getAccRewardPerShare(uint256 i) internal view returns (uint256) {
|
||||
RewardTokenInfo memory rt = rewardTokenInfos[i];
|
||||
if (totalSupply() == 0) {
|
||||
return rt.accRewardPerShare;
|
||||
}
|
||||
return
|
||||
rt.accRewardPerShare.add(
|
||||
DecimalMath.divFloor(_getUnrewardBlockNum(i).mul(rt.rewardPerBlock), totalSupply())
|
||||
);
|
||||
}
|
||||
|
||||
}
|
||||
61
contracts/DODOToken/DODOMineV3/ERC20Mine.sol
Normal file
61
contracts/DODOToken/DODOMineV3/ERC20Mine.sol
Normal file
@@ -0,0 +1,61 @@
|
||||
/*
|
||||
|
||||
Copyright 2021 DODO ZOO.
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
*/
|
||||
pragma solidity 0.6.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
import {SafeERC20} from "../../lib/SafeERC20.sol";
|
||||
import {IERC20} from "../../intf/IERC20.sol";
|
||||
import {SafeMath} from "../../lib/SafeMath.sol";
|
||||
import {ReentrancyGuard} from "../../lib/ReentrancyGuard.sol";
|
||||
import {BaseMine} from "./BaseMine.sol";
|
||||
|
||||
contract ERC20Mine is ReentrancyGuard, BaseMine {
|
||||
using SafeERC20 for IERC20;
|
||||
using SafeMath for uint256;
|
||||
|
||||
// ============ Storage ============
|
||||
|
||||
address public _TOKEN_;
|
||||
|
||||
function init(address owner, address token) external {
|
||||
super.initOwner(owner);
|
||||
_TOKEN_ = token;
|
||||
}
|
||||
|
||||
// ============ Event ============
|
||||
|
||||
event Deposit(address indexed user, uint256 amount);
|
||||
event Withdraw(address indexed user, uint256 amount);
|
||||
|
||||
// ============ Deposit && Withdraw && Exit ============
|
||||
|
||||
function deposit(uint256 amount) external preventReentrant {
|
||||
require(amount > 0, "DODOMineV3: CANNOT_DEPOSIT_ZERO");
|
||||
|
||||
_updateAllReward(msg.sender);
|
||||
|
||||
uint256 erc20OriginBalance = IERC20(_TOKEN_).balanceOf(address(this));
|
||||
IERC20(_TOKEN_).safeTransferFrom(msg.sender, address(this), amount);
|
||||
uint256 actualStakeAmount = IERC20(_TOKEN_).balanceOf(address(this)).sub(erc20OriginBalance);
|
||||
|
||||
_totalSupply = _totalSupply.add(actualStakeAmount);
|
||||
_balances[msg.sender] = _balances[msg.sender].add(actualStakeAmount);
|
||||
|
||||
emit Deposit(msg.sender, actualStakeAmount);
|
||||
}
|
||||
|
||||
function withdraw(uint256 amount) external preventReentrant {
|
||||
require(amount > 0, "DODOMineV3: CANNOT_WITHDRAW_ZERO");
|
||||
|
||||
_updateAllReward(msg.sender);
|
||||
_totalSupply = _totalSupply.sub(amount);
|
||||
_balances[msg.sender] = _balances[msg.sender].sub(amount);
|
||||
IERC20(_TOKEN_).safeTransfer(msg.sender, amount);
|
||||
|
||||
emit Withdraw(msg.sender, amount);
|
||||
}
|
||||
}
|
||||
59
contracts/DODOToken/DODOMineV3/RewardVault.sol
Normal file
59
contracts/DODOToken/DODOMineV3/RewardVault.sol
Normal file
@@ -0,0 +1,59 @@
|
||||
/*
|
||||
|
||||
Copyright 2020 DODO ZOO.
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
*/
|
||||
|
||||
pragma solidity 0.6.9;
|
||||
|
||||
import {Ownable} from "../../lib/Ownable.sol";
|
||||
import {SafeERC20} from "../../lib/SafeERC20.sol";
|
||||
import {SafeMath} from "../../lib/SafeMath.sol";
|
||||
import {IERC20} from "../../intf/IERC20.sol";
|
||||
|
||||
|
||||
interface IRewardVault {
|
||||
function reward(address to, uint256 amount) external;
|
||||
function withdrawLeftOver(address to, uint256 amount) external;
|
||||
function syncValue() external;
|
||||
function _TOTAL_REWARD_() external view returns(uint256);
|
||||
}
|
||||
|
||||
contract RewardVault is Ownable {
|
||||
using SafeERC20 for IERC20;
|
||||
using SafeMath for uint256;
|
||||
|
||||
uint256 public _REWARD_RESERVE_;
|
||||
uint256 public _TOTAL_REWARD_;
|
||||
address public _REWARD_TOKEN_;
|
||||
|
||||
// ============ Event =============
|
||||
event DepositReward(uint256 totalReward, uint256 inputReward, uint256 rewardReserve);
|
||||
|
||||
constructor(address _rewardToken) public {
|
||||
_REWARD_TOKEN_ = _rewardToken;
|
||||
}
|
||||
|
||||
function reward(address to, uint256 amount) external onlyOwner {
|
||||
require(_REWARD_RESERVE_ >= amount, "VAULT_NOT_ENOUGH");
|
||||
_REWARD_RESERVE_ = _REWARD_RESERVE_.sub(amount);
|
||||
IERC20(_REWARD_TOKEN_).safeTransfer(to, amount);
|
||||
}
|
||||
|
||||
function withdrawLeftOver(address to,uint256 amount) external onlyOwner {
|
||||
require(_REWARD_RESERVE_ >= amount, "VAULT_NOT_ENOUGH");
|
||||
_REWARD_RESERVE_ = _REWARD_RESERVE_.sub(amount);
|
||||
IERC20(_REWARD_TOKEN_).safeTransfer(to, amount);
|
||||
}
|
||||
|
||||
function syncValue() external {
|
||||
uint256 rewardBalance = IERC20(_REWARD_TOKEN_).balanceOf(address(this));
|
||||
uint256 rewardInput = rewardBalance.sub(_REWARD_RESERVE_);
|
||||
|
||||
_TOTAL_REWARD_ = _TOTAL_REWARD_.add(rewardInput);
|
||||
_REWARD_RESERVE_ = rewardBalance;
|
||||
|
||||
emit DepositReward(_TOTAL_REWARD_, rewardInput, _REWARD_RESERVE_);
|
||||
}
|
||||
}
|
||||
@@ -50,7 +50,7 @@ contract ERC20Factory {
|
||||
uint256 totalSupply,
|
||||
string memory name,
|
||||
string memory symbol,
|
||||
uint256 decimals
|
||||
uint8 decimals
|
||||
) external returns (address newERC20) {
|
||||
newERC20 = ICloneFactory(_CLONE_FACTORY_).clone(_ERC20_TEMPLATE_);
|
||||
InitializableERC20(newERC20).init(msg.sender, totalSupply, name, symbol, decimals);
|
||||
@@ -62,7 +62,7 @@ contract ERC20Factory {
|
||||
uint256 initSupply,
|
||||
string memory name,
|
||||
string memory symbol,
|
||||
uint256 decimals
|
||||
uint8 decimals
|
||||
) external returns (address newMintableERC20) {
|
||||
newMintableERC20 = ICloneFactory(_CLONE_FACTORY_).clone(_MINTABLE_ERC20_TEMPLATE_);
|
||||
InitializableMintableERC20(newMintableERC20).init(
|
||||
|
||||
157
contracts/Factory/ERC20V2Factory.sol
Normal file
157
contracts/Factory/ERC20V2Factory.sol
Normal file
@@ -0,0 +1,157 @@
|
||||
/*
|
||||
|
||||
Copyright 2021 DODO ZOO.
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
*/
|
||||
|
||||
pragma solidity 0.6.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
import {ICloneFactory} from "../lib/CloneFactory.sol";
|
||||
import {InitializableOwnable} from "../lib/InitializableOwnable.sol";
|
||||
|
||||
interface IStdERC20 {
|
||||
function init(
|
||||
address _creator,
|
||||
uint256 _totalSupply,
|
||||
string memory _name,
|
||||
string memory _symbol,
|
||||
uint8 _decimals
|
||||
) external;
|
||||
}
|
||||
|
||||
interface ICustomERC20 {
|
||||
function init(
|
||||
address _creator,
|
||||
uint256 _initSupply,
|
||||
string memory _name,
|
||||
string memory _symbol,
|
||||
uint8 _decimals,
|
||||
uint256 _tradeBurnRatio,
|
||||
uint256 _tradeFeeRatio,
|
||||
address _team,
|
||||
bool _isMintable
|
||||
) external;
|
||||
}
|
||||
|
||||
/**
|
||||
* @title DODO ERC20V2Factory
|
||||
* @author DODO Breeder
|
||||
*
|
||||
* @notice Help user to create erc20 token
|
||||
*/
|
||||
contract ERC20V2Factory is InitializableOwnable {
|
||||
// ============ Templates ============
|
||||
|
||||
address public immutable _CLONE_FACTORY_;
|
||||
address public _ERC20_TEMPLATE_;
|
||||
address public _CUSTOM_ERC20_TEMPLATE_;
|
||||
uint256 public _CREATE_FEE_;
|
||||
|
||||
// ============ Events ============
|
||||
// 0 Std 1 TradeBurn or TradeFee 2 Mintable
|
||||
event NewERC20(address erc20, address creator, uint256 erc20Type);
|
||||
event ChangeCreateFee(uint256 newFee);
|
||||
event Withdraw(address account, uint256 amount);
|
||||
event ChangeStdTemplate(address newStdTemplate);
|
||||
event ChangeCustomTemplate(address newCustomTemplate);
|
||||
|
||||
// ============ Registry ============
|
||||
// creator -> token address list
|
||||
mapping(address => address[]) public _USER_STD_REGISTRY_;
|
||||
mapping(address => address[]) public _USER_CUSTOM_REGISTRY_;
|
||||
|
||||
// ============ Functions ============
|
||||
|
||||
fallback() external payable {}
|
||||
|
||||
receive() external payable {}
|
||||
|
||||
constructor(
|
||||
address cloneFactory,
|
||||
address erc20Template,
|
||||
address customErc20Template
|
||||
) public {
|
||||
_CLONE_FACTORY_ = cloneFactory;
|
||||
_ERC20_TEMPLATE_ = erc20Template;
|
||||
_CUSTOM_ERC20_TEMPLATE_ = customErc20Template;
|
||||
}
|
||||
|
||||
function createStdERC20(
|
||||
uint256 totalSupply,
|
||||
string memory name,
|
||||
string memory symbol,
|
||||
uint8 decimals
|
||||
) external payable returns (address newERC20) {
|
||||
require(msg.value >= _CREATE_FEE_, "CREATE_FEE_NOT_ENOUGH");
|
||||
newERC20 = ICloneFactory(_CLONE_FACTORY_).clone(_ERC20_TEMPLATE_);
|
||||
IStdERC20(newERC20).init(msg.sender, totalSupply, name, symbol, decimals);
|
||||
_USER_STD_REGISTRY_[msg.sender].push(newERC20);
|
||||
emit NewERC20(newERC20, msg.sender, 0);
|
||||
}
|
||||
|
||||
function createCustomERC20(
|
||||
uint256 initSupply,
|
||||
string memory name,
|
||||
string memory symbol,
|
||||
uint8 decimals,
|
||||
uint256 tradeBurnRatio,
|
||||
uint256 tradeFeeRatio,
|
||||
address teamAccount,
|
||||
bool isMintable
|
||||
) external payable returns (address newCustomERC20) {
|
||||
require(msg.value >= _CREATE_FEE_, "CREATE_FEE_NOT_ENOUGH");
|
||||
newCustomERC20 = ICloneFactory(_CLONE_FACTORY_).clone(_CUSTOM_ERC20_TEMPLATE_);
|
||||
|
||||
ICustomERC20(newCustomERC20).init(
|
||||
msg.sender,
|
||||
initSupply,
|
||||
name,
|
||||
symbol,
|
||||
decimals,
|
||||
tradeBurnRatio,
|
||||
tradeFeeRatio,
|
||||
teamAccount,
|
||||
isMintable
|
||||
);
|
||||
|
||||
_USER_CUSTOM_REGISTRY_[msg.sender].push(newCustomERC20);
|
||||
if(isMintable)
|
||||
emit NewERC20(newCustomERC20, msg.sender, 2);
|
||||
else
|
||||
emit NewERC20(newCustomERC20, msg.sender, 1);
|
||||
}
|
||||
|
||||
|
||||
// ============ View ============
|
||||
function getTokenByUser(address user)
|
||||
external
|
||||
view
|
||||
returns (address[] memory stds,address[] memory customs)
|
||||
{
|
||||
return (_USER_STD_REGISTRY_[user], _USER_CUSTOM_REGISTRY_[user]);
|
||||
}
|
||||
|
||||
// ============ Ownable =============
|
||||
function changeCreateFee(uint256 newFee) external onlyOwner {
|
||||
_CREATE_FEE_ = newFee;
|
||||
emit ChangeCreateFee(newFee);
|
||||
}
|
||||
|
||||
function withdraw() external onlyOwner {
|
||||
uint256 amount = address(this).balance;
|
||||
msg.sender.transfer(amount);
|
||||
emit Withdraw(msg.sender, amount);
|
||||
}
|
||||
|
||||
function updateStdTemplate(address newStdTemplate) external onlyOwner {
|
||||
_ERC20_TEMPLATE_ = newStdTemplate;
|
||||
emit ChangeStdTemplate(newStdTemplate);
|
||||
}
|
||||
|
||||
function updateCustomTemplate(address newCustomTemplate) external onlyOwner {
|
||||
_CUSTOM_ERC20_TEMPLATE_ = newCustomTemplate;
|
||||
emit ChangeCustomTemplate(newCustomTemplate);
|
||||
}
|
||||
}
|
||||
110
contracts/Factory/Registries/DODOMineV3Registry.sol
Normal file
110
contracts/Factory/Registries/DODOMineV3Registry.sol
Normal file
@@ -0,0 +1,110 @@
|
||||
/*
|
||||
Copyright 2021 DODO ZOO.
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
pragma solidity 0.6.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
import {InitializableOwnable} from "../../lib/InitializableOwnable.sol";
|
||||
|
||||
interface IDODOMineV3Registry {
|
||||
function addMineV3(
|
||||
address mine,
|
||||
bool isLpToken,
|
||||
address stakeToken
|
||||
) external;
|
||||
}
|
||||
|
||||
/**
|
||||
* @title DODOMineV3 Registry
|
||||
* @author DODO Breeder
|
||||
*
|
||||
* @notice Register DODOMineV3 Pools
|
||||
*/
|
||||
contract DODOMineV3Registry is InitializableOwnable, IDODOMineV3Registry {
|
||||
|
||||
mapping (address => bool) public isAdminListed;
|
||||
mapping (address => bool) public singleTokenList;
|
||||
|
||||
// ============ Registry ============
|
||||
// minePool -> stakeToken
|
||||
mapping(address => address) public _MINE_REGISTRY_;
|
||||
// lpToken -> minePool
|
||||
mapping(address => address) public _LP_REGISTRY_;
|
||||
// singleToken -> minePool
|
||||
mapping(address => address[]) public _SINGLE_REGISTRY_;
|
||||
|
||||
|
||||
// ============ Events ============
|
||||
event NewMineV3(address mine, address stakeToken, bool isLpToken);
|
||||
event RemoveMineV3(address mine, address stakeToken);
|
||||
event addAdmin(address admin);
|
||||
event removeAdmin(address admin);
|
||||
event addSingleToken(address token);
|
||||
event removeSingleToken(address token);
|
||||
|
||||
|
||||
function addMineV3(
|
||||
address mine,
|
||||
bool isLpToken,
|
||||
address stakeToken
|
||||
) override external {
|
||||
require(isAdminListed[msg.sender], "ACCESS_DENIED");
|
||||
_MINE_REGISTRY_[mine] = stakeToken;
|
||||
if(isLpToken) {
|
||||
_LP_REGISTRY_[stakeToken] = mine;
|
||||
}else {
|
||||
require(_SINGLE_REGISTRY_[stakeToken].length == 0 || singleTokenList[stakeToken], "ALREADY_EXSIT_POOL");
|
||||
_SINGLE_REGISTRY_[stakeToken].push(mine);
|
||||
}
|
||||
|
||||
emit NewMineV3(mine, stakeToken, isLpToken);
|
||||
}
|
||||
|
||||
// ============ Admin Operation Functions ============
|
||||
|
||||
function removeMineV3(
|
||||
address mine,
|
||||
bool isLpToken,
|
||||
address stakeToken
|
||||
) external onlyOwner {
|
||||
_MINE_REGISTRY_[mine] = address(0);
|
||||
if(isLpToken) {
|
||||
_LP_REGISTRY_[stakeToken] = address(0);
|
||||
}else {
|
||||
uint256 len = _SINGLE_REGISTRY_[stakeToken].length;
|
||||
for (uint256 i = 0; i < len; i++) {
|
||||
if (mine == _SINGLE_REGISTRY_[stakeToken][i]) {
|
||||
if(i != len - 1) {
|
||||
_SINGLE_REGISTRY_[stakeToken][i] = _SINGLE_REGISTRY_[stakeToken][len - 1];
|
||||
}
|
||||
_SINGLE_REGISTRY_[stakeToken].pop();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
emit RemoveMineV3(mine, stakeToken);
|
||||
}
|
||||
|
||||
function addAdminList (address contractAddr) external onlyOwner {
|
||||
isAdminListed[contractAddr] = true;
|
||||
emit addAdmin(contractAddr);
|
||||
}
|
||||
|
||||
function removeAdminList (address contractAddr) external onlyOwner {
|
||||
isAdminListed[contractAddr] = false;
|
||||
emit removeAdmin(contractAddr);
|
||||
}
|
||||
|
||||
function addSingleTokenList(address token) external onlyOwner {
|
||||
singleTokenList[token] = true;
|
||||
emit addSingleToken(token);
|
||||
}
|
||||
|
||||
function removeSingleTokenList(address token) external onlyOwner {
|
||||
singleTokenList[token] = false;
|
||||
emit removeSingleToken(token);
|
||||
}
|
||||
}
|
||||
141
contracts/SmartRoute/proxies/DODODppProxy.sol
Normal file
141
contracts/SmartRoute/proxies/DODODppProxy.sol
Normal file
@@ -0,0 +1,141 @@
|
||||
/*
|
||||
Copyright 2021 DODO ZOO.
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
pragma solidity 0.6.9;
|
||||
|
||||
import {IDODOApproveProxy} from "../DODOApproveProxy.sol";
|
||||
import {IDODOV2} from "./../intf/IDODOV2.sol";
|
||||
import {IERC20} from "../../intf/IERC20.sol";
|
||||
import {SafeERC20} from "../../lib/SafeERC20.sol";
|
||||
import {IWETH} from "../../intf/IWETH.sol";
|
||||
import {SafeMath} from "../../lib/SafeMath.sol";
|
||||
import {SafeERC20} from "../../lib/SafeERC20.sol";
|
||||
import {ReentrancyGuard} from "../../lib/ReentrancyGuard.sol";
|
||||
|
||||
interface IDPPOracle {
|
||||
function reset(
|
||||
address assetTo,
|
||||
uint256 newLpFeeRate,
|
||||
uint256 newK,
|
||||
uint256 baseOutAmount,
|
||||
uint256 quoteOutAmount,
|
||||
uint256 minBaseReserve,
|
||||
uint256 minQuoteReserve
|
||||
) external returns (bool);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @title DODODppProxy
|
||||
* @author DODO Breeder
|
||||
*
|
||||
* @notice DODO Private Pool Proxy
|
||||
*/
|
||||
contract DODODppProxy is ReentrancyGuard {
|
||||
using SafeMath for uint256;
|
||||
using SafeERC20 for IERC20;
|
||||
|
||||
// ============ Storage ============
|
||||
|
||||
address constant _ETH_ADDRESS_ = 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE;
|
||||
address public immutable _WETH_;
|
||||
address public immutable _DODO_APPROVE_PROXY_;
|
||||
|
||||
// ============ Modifiers ============
|
||||
|
||||
modifier judgeExpired(uint256 deadLine) {
|
||||
require(deadLine >= block.timestamp, "DODOCpProxy: EXPIRED");
|
||||
_;
|
||||
}
|
||||
|
||||
fallback() external payable {}
|
||||
|
||||
receive() external payable {}
|
||||
|
||||
constructor(
|
||||
address payable weth,
|
||||
address dodoApproveProxy
|
||||
) public {
|
||||
_WETH_ = weth;
|
||||
_DODO_APPROVE_PROXY_ = dodoApproveProxy;
|
||||
}
|
||||
|
||||
// DPPOracle
|
||||
function resetDODOPrivatePool(
|
||||
address dppAddress,
|
||||
uint256[] memory paramList, //0 - newLpFeeRate, 1 - newK
|
||||
uint256[] memory amountList, //0 - baseInAmount, 1 - quoteInAmount, 2 - baseOutAmount, 3- quoteOutAmount
|
||||
uint8 flag, //0 - ERC20, 1 - baseInETH, 2 - quoteInETH, 3 - baseOutETH, 4 - quoteOutETH
|
||||
uint256 minBaseReserve,
|
||||
uint256 minQuoteReserve,
|
||||
uint256 deadLine
|
||||
) external payable preventReentrant judgeExpired(deadLine) {
|
||||
_deposit(
|
||||
msg.sender,
|
||||
dppAddress,
|
||||
IDODOV2(dppAddress)._BASE_TOKEN_(),
|
||||
amountList[0],
|
||||
flag == 1
|
||||
);
|
||||
_deposit(
|
||||
msg.sender,
|
||||
dppAddress,
|
||||
IDODOV2(dppAddress)._QUOTE_TOKEN_(),
|
||||
amountList[1],
|
||||
flag == 2
|
||||
);
|
||||
|
||||
require(IDPPOracle(IDODOV2(dppAddress)._OWNER_()).reset(
|
||||
msg.sender,
|
||||
paramList[0],
|
||||
paramList[1],
|
||||
amountList[2],
|
||||
amountList[3],
|
||||
minBaseReserve,
|
||||
minQuoteReserve
|
||||
), "Reset Failed");
|
||||
|
||||
_withdraw(msg.sender, IDODOV2(dppAddress)._BASE_TOKEN_(), amountList[2], flag == 3);
|
||||
_withdraw(msg.sender, IDODOV2(dppAddress)._QUOTE_TOKEN_(), amountList[3], flag == 4);
|
||||
}
|
||||
|
||||
|
||||
//====================== internal =======================
|
||||
|
||||
function _deposit(
|
||||
address from,
|
||||
address to,
|
||||
address token,
|
||||
uint256 amount,
|
||||
bool isETH
|
||||
) internal {
|
||||
if (isETH) {
|
||||
if (amount > 0) {
|
||||
IWETH(_WETH_).deposit{value: amount}();
|
||||
if (to != address(this)) SafeERC20.safeTransfer(IERC20(_WETH_), to, amount);
|
||||
}
|
||||
} else {
|
||||
IDODOApproveProxy(_DODO_APPROVE_PROXY_).claimTokens(token, from, to, amount);
|
||||
}
|
||||
}
|
||||
|
||||
function _withdraw(
|
||||
address payable to,
|
||||
address token,
|
||||
uint256 amount,
|
||||
bool isETH
|
||||
) internal {
|
||||
if (isETH) {
|
||||
if (amount > 0) {
|
||||
IWETH(_WETH_).withdraw(amount);
|
||||
to.transfer(amount);
|
||||
}
|
||||
} else {
|
||||
if (amount > 0) {
|
||||
SafeERC20.safeTransfer(IERC20(token), to, amount);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
133
contracts/SmartRoute/proxies/DODOMineV3Proxy.sol
Normal file
133
contracts/SmartRoute/proxies/DODOMineV3Proxy.sol
Normal file
@@ -0,0 +1,133 @@
|
||||
/*
|
||||
|
||||
Copyright 2021 DODO ZOO.
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
*/
|
||||
|
||||
pragma solidity 0.6.9;
|
||||
pragma experimental ABIEncoderV2;
|
||||
|
||||
import {InitializableOwnable} from "../../lib/InitializableOwnable.sol";
|
||||
import {IDODOApproveProxy} from "../DODOApproveProxy.sol";
|
||||
import {IRewardVault} from "../../DODOToken/DODOMineV3/RewardVault.sol";
|
||||
import {IDODOMineV3Registry} from "../../Factory/Registries/DODOMineV3Registry.sol";
|
||||
import {ICloneFactory} from "../../lib/CloneFactory.sol";
|
||||
import {SafeMath} from "../../lib/SafeMath.sol";
|
||||
|
||||
interface IMineV3 {
|
||||
function init(address owner, address token) external;
|
||||
|
||||
function addRewardToken(
|
||||
address rewardToken,
|
||||
uint256 rewardPerBlock,
|
||||
uint256 startBlock,
|
||||
uint256 endBlock
|
||||
) external;
|
||||
|
||||
function directTransferOwnership(address newOwner) external;
|
||||
|
||||
function getVaultByRewardToken(address rewardToken) external view returns(address);
|
||||
}
|
||||
|
||||
/**
|
||||
* @title DODOMineV3 Proxy
|
||||
* @author DODO Breeder
|
||||
*
|
||||
* @notice Create And Register DODOMineV3 Contracts
|
||||
*/
|
||||
contract DODOMineV3Proxy is InitializableOwnable {
|
||||
using SafeMath for uint256;
|
||||
// ============ Templates ============
|
||||
|
||||
address public immutable _CLONE_FACTORY_;
|
||||
address public immutable _DODO_APPROVE_PROXY_;
|
||||
address public immutable _DODO_MINEV3_REGISTRY_;
|
||||
address public _MINEV3_TEMPLATE_;
|
||||
|
||||
|
||||
// ============ Events ============
|
||||
event DepositRewardToVault(address mine, address rewardToken, uint256 amount);
|
||||
event DepositRewardToMine(address mine, address rewardToken, uint256 amount);
|
||||
event CreateMineV3(address account, address mineV3);
|
||||
event ChangeMineV3Template(address mineV3);
|
||||
|
||||
constructor(
|
||||
address cloneFactory,
|
||||
address mineTemplate,
|
||||
address dodoApproveProxy,
|
||||
address dodoMineV3Registry
|
||||
) public {
|
||||
_CLONE_FACTORY_ = cloneFactory;
|
||||
_MINEV3_TEMPLATE_ = mineTemplate;
|
||||
_DODO_APPROVE_PROXY_ = dodoApproveProxy;
|
||||
_DODO_MINEV3_REGISTRY_ = dodoMineV3Registry;
|
||||
}
|
||||
|
||||
// ============ Functions ============
|
||||
|
||||
function createDODOMineV3(
|
||||
address stakeToken,
|
||||
bool isLpToken,
|
||||
address[] memory rewardTokens,
|
||||
uint256[] memory rewardPerBlock,
|
||||
uint256[] memory startBlock,
|
||||
uint256[] memory endBlock
|
||||
) external returns (address newMineV3) {
|
||||
require(rewardTokens.length > 0, "REWARD_EMPTY");
|
||||
require(rewardTokens.length == rewardPerBlock.length, "REWARD_PARAM_NOT_MATCH");
|
||||
require(startBlock.length == rewardPerBlock.length, "REWARD_PARAM_NOT_MATCH");
|
||||
require(endBlock.length == rewardPerBlock.length, "REWARD_PARAM_NOT_MATCH");
|
||||
|
||||
newMineV3 = ICloneFactory(_CLONE_FACTORY_).clone(_MINEV3_TEMPLATE_);
|
||||
|
||||
IMineV3(newMineV3).init(address(this), stakeToken);
|
||||
|
||||
for(uint i = 0; i<rewardTokens.length; i++) {
|
||||
uint256 rewardAmount = rewardPerBlock[i].mul(endBlock[i].sub(startBlock[i]));
|
||||
IDODOApproveProxy(_DODO_APPROVE_PROXY_).claimTokens(rewardTokens[i], msg.sender, newMineV3, rewardAmount);
|
||||
IMineV3(newMineV3).addRewardToken(
|
||||
rewardTokens[i],
|
||||
rewardPerBlock[i],
|
||||
startBlock[i],
|
||||
endBlock[i]
|
||||
);
|
||||
}
|
||||
|
||||
IMineV3(newMineV3).directTransferOwnership(msg.sender);
|
||||
|
||||
IDODOMineV3Registry(_DODO_MINEV3_REGISTRY_).addMineV3(newMineV3, isLpToken, stakeToken);
|
||||
|
||||
emit CreateMineV3(msg.sender, newMineV3);
|
||||
}
|
||||
|
||||
function depositRewardToVault(
|
||||
address mineV3,
|
||||
address rewardToken,
|
||||
uint256 amount
|
||||
) external {
|
||||
address rewardVault = IMineV3(mineV3).getVaultByRewardToken(rewardToken);
|
||||
IDODOApproveProxy(_DODO_APPROVE_PROXY_).claimTokens(rewardToken, msg.sender, rewardVault, amount);
|
||||
IRewardVault(rewardVault).syncValue();
|
||||
|
||||
emit DepositRewardToVault(mineV3,rewardToken,amount);
|
||||
}
|
||||
|
||||
function depositRewardToMine(
|
||||
address mineV3,
|
||||
address rewardToken,
|
||||
uint256 amount
|
||||
) external {
|
||||
require(mineV3 != address(0), "MINE_EMPTY");
|
||||
IDODOApproveProxy(_DODO_APPROVE_PROXY_).claimTokens(rewardToken, msg.sender, mineV3, amount);
|
||||
|
||||
emit DepositRewardToMine(mineV3,rewardToken,amount);
|
||||
}
|
||||
|
||||
// ============ Admin Operation Functions ============
|
||||
|
||||
function updateMineV3Template(address _newMineV3Template) external onlyOwner {
|
||||
_MINEV3_TEMPLATE_ = _newMineV3Template;
|
||||
emit ChangeMineV3Template(_newMineV3Template);
|
||||
}
|
||||
}
|
||||
@@ -195,6 +195,8 @@ contract DODORouteProxy {
|
||||
|
||||
if(assetFrom[i-1] == address(this)) {
|
||||
uint256 curAmount = curTotalAmount.div(curTotalWeight).mul(curPoolInfo.weight);
|
||||
//can improved
|
||||
// uint256 curAmount = curTotalAmount.mul(curPoolInfo.weight).div(curTotalWeight);
|
||||
|
||||
if(curPoolInfo.poolEdition == 1) {
|
||||
//For using transferFrom pool (like dodoV1, Curve)
|
||||
|
||||
145
contracts/external/ERC20/CustomERC20.sol
vendored
Normal file
145
contracts/external/ERC20/CustomERC20.sol
vendored
Normal file
@@ -0,0 +1,145 @@
|
||||
/*
|
||||
|
||||
Copyright 2021 DODO ZOO.
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
*/
|
||||
|
||||
pragma solidity 0.6.9;
|
||||
|
||||
import {SafeMath} from "../../lib/SafeMath.sol";
|
||||
import {InitializableOwnable} from "../../lib/InitializableOwnable.sol";
|
||||
|
||||
contract CustomERC20 is InitializableOwnable {
|
||||
using SafeMath for uint256;
|
||||
|
||||
string public name;
|
||||
uint8 public decimals;
|
||||
string public symbol;
|
||||
uint256 public totalSupply;
|
||||
|
||||
uint256 public tradeBurnRatio;
|
||||
uint256 public tradeFeeRatio;
|
||||
address public team;
|
||||
bool public isMintable;
|
||||
|
||||
mapping(address => uint256) balances;
|
||||
mapping(address => mapping(address => uint256)) internal allowed;
|
||||
|
||||
event Transfer(address indexed from, address indexed to, uint256 amount);
|
||||
event Approval(address indexed owner, address indexed spender, uint256 amount);
|
||||
event Mint(address indexed user, uint256 value);
|
||||
event Burn(address indexed user, uint256 value);
|
||||
|
||||
event ChangeTeam(address oldTeam, address newTeam);
|
||||
|
||||
|
||||
function init(
|
||||
address _creator,
|
||||
uint256 _initSupply,
|
||||
string memory _name,
|
||||
string memory _symbol,
|
||||
uint8 _decimals,
|
||||
uint256 _tradeBurnRatio,
|
||||
uint256 _tradeFeeRatio,
|
||||
address _team,
|
||||
bool _isMintable
|
||||
) public {
|
||||
initOwner(_creator);
|
||||
name = _name;
|
||||
symbol = _symbol;
|
||||
decimals = _decimals;
|
||||
totalSupply = _initSupply;
|
||||
balances[_creator] = _initSupply;
|
||||
require(_tradeBurnRatio >= 0 && _tradeBurnRatio <= 5000, "TRADE_BURN_RATIO_INVALID");
|
||||
require(_tradeFeeRatio >= 0 && _tradeFeeRatio <= 5000, "TRADE_FEE_RATIO_INVALID");
|
||||
tradeBurnRatio = _tradeBurnRatio;
|
||||
tradeFeeRatio = _tradeFeeRatio;
|
||||
team = _team;
|
||||
isMintable = _isMintable;
|
||||
emit Transfer(address(0), _creator, _initSupply);
|
||||
}
|
||||
|
||||
function transfer(address to, uint256 amount) public returns (bool) {
|
||||
_transfer(msg.sender,to,amount);
|
||||
return true;
|
||||
}
|
||||
|
||||
function balanceOf(address owner) public view returns (uint256 balance) {
|
||||
return balances[owner];
|
||||
}
|
||||
|
||||
function transferFrom(
|
||||
address from,
|
||||
address to,
|
||||
uint256 amount
|
||||
) public returns (bool) {
|
||||
require(amount <= allowed[from][msg.sender], "ALLOWANCE_NOT_ENOUGH");
|
||||
_transfer(from,to,amount);
|
||||
allowed[from][msg.sender] = allowed[from][msg.sender].sub(amount);
|
||||
return true;
|
||||
}
|
||||
|
||||
function approve(address spender, uint256 amount) public returns (bool) {
|
||||
allowed[msg.sender][spender] = amount;
|
||||
emit Approval(msg.sender, spender, amount);
|
||||
return true;
|
||||
}
|
||||
|
||||
function allowance(address owner, address spender) public view returns (uint256) {
|
||||
return allowed[owner][spender];
|
||||
}
|
||||
|
||||
|
||||
function _transfer(
|
||||
address sender,
|
||||
address recipient,
|
||||
uint256 amount
|
||||
) internal virtual {
|
||||
require(sender != address(0), "ERC20: transfer from the zero address");
|
||||
require(recipient != address(0), "ERC20: transfer to the zero address");
|
||||
require(balances[sender] >= amount, "ERC20: transfer amount exceeds balance");
|
||||
|
||||
balances[sender] = balances[sender].sub(amount);
|
||||
|
||||
uint256 burnAmount;
|
||||
uint256 feeAmount;
|
||||
if(tradeBurnRatio > 0) {
|
||||
burnAmount = amount.mul(tradeBurnRatio).div(10000);
|
||||
balances[address(0)] = balances[address(0)].add(burnAmount);
|
||||
}
|
||||
|
||||
if(tradeFeeRatio > 0) {
|
||||
feeAmount = amount.mul(tradeFeeRatio).div(10000);
|
||||
balances[team] = balances[team].add(feeAmount);
|
||||
}
|
||||
|
||||
balances[recipient] = balances[recipient].add(amount.sub(burnAmount).sub(feeAmount));
|
||||
|
||||
emit Transfer(sender, recipient, amount);
|
||||
}
|
||||
|
||||
|
||||
//=================== Ownable ======================
|
||||
function mint(address user, uint256 value) external onlyOwner {
|
||||
require(isMintable, "NOT_MINTABEL_TOKEN");
|
||||
balances[user] = balances[user].add(value);
|
||||
totalSupply = totalSupply.add(value);
|
||||
emit Mint(user, value);
|
||||
emit Transfer(address(0), user, value);
|
||||
}
|
||||
|
||||
function burn(address user, uint256 value) external onlyOwner {
|
||||
require(isMintable, "NOT_MINTABEL_TOKEN");
|
||||
balances[user] = balances[user].sub(value);
|
||||
totalSupply = totalSupply.sub(value);
|
||||
emit Burn(user, value);
|
||||
emit Transfer(user, address(0), value);
|
||||
}
|
||||
|
||||
function changeTeamAccount(address newTeam) external onlyOwner {
|
||||
require(tradeFeeRatio > 0, "NOT_TRADE_FEE_TOKEN");
|
||||
emit ChangeTeam(team,newTeam);
|
||||
team = newTeam;
|
||||
}
|
||||
}
|
||||
@@ -13,7 +13,7 @@ contract InitializableERC20 {
|
||||
using SafeMath for uint256;
|
||||
|
||||
string public name;
|
||||
uint256 public decimals;
|
||||
uint8 public decimals;
|
||||
string public symbol;
|
||||
uint256 public totalSupply;
|
||||
|
||||
@@ -30,7 +30,7 @@ contract InitializableERC20 {
|
||||
uint256 _totalSupply,
|
||||
string memory _name,
|
||||
string memory _symbol,
|
||||
uint256 _decimals
|
||||
uint8 _decimals
|
||||
) public {
|
||||
require(!initialized, "TOKEN_INITIALIZED");
|
||||
initialized = true;
|
||||
|
||||
@@ -14,7 +14,7 @@ contract InitializableMintableERC20 is InitializableOwnable {
|
||||
using SafeMath for uint256;
|
||||
|
||||
string public name;
|
||||
uint256 public decimals;
|
||||
uint8 public decimals;
|
||||
string public symbol;
|
||||
uint256 public totalSupply;
|
||||
|
||||
@@ -31,7 +31,7 @@ contract InitializableMintableERC20 is InitializableOwnable {
|
||||
uint256 _initSupply,
|
||||
string memory _name,
|
||||
string memory _symbol,
|
||||
uint256 _decimals
|
||||
uint8 _decimals
|
||||
) public {
|
||||
initOwner(_creator);
|
||||
name = _name;
|
||||
|
||||
@@ -501,3 +501,17 @@ network type: arb
|
||||
Deploy time: 2021/6/3 下午4:23:04
|
||||
Deploy type: DODORouteProxy
|
||||
DODORouteProxy Address: 0x3E64F18168651d140AaE57e0cF325874d066bA9E
|
||||
====================================================
|
||||
network type: rinkeby
|
||||
Deploy time: 2021/6/29 上午10:05:29
|
||||
Deploy type: ERC20V2Factory
|
||||
CustomERC20Address: 0x0Cd57DC8367362314C510446FD106B66989Eb81a
|
||||
ERC20V2FactoryAddress: 0x6659fB6fc609e8c5159Aaccb80e49cCB8F64442a
|
||||
Init ERC20V2Factory Tx: 0xbeb3138087efe8f2c41805c8b7a4fe94b17f8abbef4e5d739da8125d1e44e504
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/6/29 上午10:30:59
|
||||
Deploy type: ERC20V2Factory
|
||||
CustomERC20Address: 0x3a0e0F2EDFC0e96BD700815f953Bcb6d8a6FF0AB
|
||||
ERC20V2FactoryAddress: 0xce4Bdc3151bF9F9dcADAED961a65D32f7bAC5460
|
||||
Init ERC20V2Factory Tx: 0x5c03786d3e12b5c9532429f83c548a892c2d1ec613a44db81a9595e3bf017490
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,523 +0,0 @@
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/18 下午10:51:45
|
||||
Mock Tx: V2
|
||||
ERC20TemplateAddress: 0x77d2e257241e6971688b08bdA9F658F065d7bb41
|
||||
MintableERC20TemplateAddress: 0xA45a64DAba80757432fA4d654Df12f65f020C13C
|
||||
ERC20FactoryAddress: 0xCb1A2f64EfB02803276BFB5a8D511C4D950282a0
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/18 下午10:59:41
|
||||
Mock Tx: V2
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/18 下午11:02:45
|
||||
Mock Tx: V2
|
||||
ERC20 address: 0x41372596189C40712fEf3d8C101326F04806Ff40; Symbol:ABC0
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/18 下午11:05:08
|
||||
Mock Tx: V2
|
||||
ERC20 address: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE; Symbol:ABC0
|
||||
ERC20 address: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA; Symbol:ABC1
|
||||
ERC20 address: 0xFE1133ea03d701C5006b7f065bBf987955E7A67C; Symbol:ABC2
|
||||
ERC20 address: 0x123ee47BaE3F64d422F2FB18ac444B47c1880F4C; Symbol:ABC3
|
||||
ERC20 address: 0x0ab8EF8B19655F32959c83e5fC5cD6536065D28f; Symbol:ABC4
|
||||
ERC20 address: 0x6462794c19e6b4543BEC56200212c7c746bbB9eB; Symbol:ABC5
|
||||
ERC20 address: 0x8063EBEB4bE06935d81f836be61E6893B2a21318; Symbol:ABC6
|
||||
ERC20 address: 0xed59a1451c78516d7eAc65A396ADE62E73b76C9b; Symbol:ABC7
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/19 上午11:41:25
|
||||
Mock POOL Tx: V2
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/19 上午11:43:50
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0xbb76b6554626c2e00939a903b044a99a4460118134e1697a66b2a25faca7b81c
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0x3d0ed3a4eb90f32870f338410a36d486985dc2a332c1d8979f907ce857dbf599
|
||||
Approve:0xFE1133ea03d701C5006b7f065bBf987955E7A67C Tx: 0x91ccb9986db3d1079895422cb0caad0fedd15c5907a5af29122972a833c795a8
|
||||
Approve:0x123ee47BaE3F64d422F2FB18ac444B47c1880F4C Tx: 0x3d76718d81120b09808220f43435cc9b12becd1bfabfcb655240c36b99bdfd18
|
||||
Approve:0x0ab8EF8B19655F32959c83e5fC5cD6536065D28f Tx: 0xa5af38be6caf411cf726c7005f354f86681db7429b9be7a73594a39f460ed890
|
||||
Approve:0x6462794c19e6b4543BEC56200212c7c746bbB9eB Tx: 0x9650ad28f620d23e48911b6907879ca81beee3decf6264f86ddf66dec68955bc
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/19 上午11:46:06
|
||||
Mock POOL Tx: V2
|
||||
Create DVM 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0xd804ce3e9eb03e846ad8e86cf3315619b1e165cbd15feb490e0bfb99e899ccab
|
||||
Create DVM 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0x004394d533b85a761a1e415d718c2f178f3c21b047e75e68ccf43230b4e63771
|
||||
Create DVM 0xFE1133ea03d701C5006b7f065bBf987955E7A67C Tx: 0x5c8c2d2e45eb6b8cd278165748c9ba3979d83d300a0a1b060936b580df1ac50a
|
||||
Create DVM 0x123ee47BaE3F64d422F2FB18ac444B47c1880F4C Tx: 0xec7977c7f27dd1e9cfa3a62a8f2a5b6a6a8aa9cdff9d9cc8b1162929ed16662d
|
||||
Create DVM 0x0ab8EF8B19655F32959c83e5fC5cD6536065D28f Tx: 0xcea08b8dd7109fb222203426951e49b8ee2d036df3547b56c2bfe8043f2c83c7
|
||||
Create DVM 0x6462794c19e6b4543BEC56200212c7c746bbB9eB Tx: 0x2551bb2b6cc965e012b5c137ef0e2ad6cc8841418ab9047593e1f5ef73a83044
|
||||
Create DPP 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0xe8e97e1c68a6987b23fdf641522df83e68f5ca63a78d87ca4f93ca41f733e365
|
||||
Create DPP 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0x81ec0bce5b4524ed38a0a2619d80f08d4bb112ec7c7586a166a2cd36f8a33c42
|
||||
Create DPP 0xFE1133ea03d701C5006b7f065bBf987955E7A67C Tx: 0x591e9d4f8aeb1773c1db801bbe06720e8147226b667c3a1e8099ab63f723a52b
|
||||
Create DPP 0x123ee47BaE3F64d422F2FB18ac444B47c1880F4C Tx: 0xee691843418c432c77dc8f55bad638551ca4c1f71ca98a7a9e789a5c10d14569
|
||||
Create DPP 0x0ab8EF8B19655F32959c83e5fC5cD6536065D28f Tx: 0x60586a3b460a507107e2412ce68eb370d12d3ccfe8cab2d313871cc521c59eeb
|
||||
Create DPP 0x6462794c19e6b4543BEC56200212c7c746bbB9eB Tx: 0x0c4a29fea84b4fff01898dc447ae311d3e76caffe14ec877dd437a593423b853
|
||||
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/21 上午11:31:44
|
||||
Mock TOKEN Tx: V2
|
||||
ERC20 address: 0x156595bAF85D5C29E91d959889B022d952190A64; Symbol:USDT
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/21 下午12:02:58
|
||||
Mock POOL Tx: V2
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0xcfd0546fd0fb31ff2c051a09018f61f8869b3ebe1c8657d11b11b1ce5dd01535
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x7e0d3717f3a84a8f924ef08392e37bd86da5419ac30864231a4c80465e5826b6
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x8386c03649cd4502ec9d13086a73ce2c44c2e99b243501ff8b4aa7c63cc69c69
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x839a82a59583d5bdf978d50920a96e0b0059a2ad8269f59e2fa4560986dadfec
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x00bf8c61510bfa6ef23a6ff8c73fcbc0c914d35b233bbd18420dbcd1361ef4a7
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x6944f5e9b14f78a8e2a843dfea0df12f9af4ced08bb41649661d22dceea77eec
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x71c44c1397cd1c21d70f84e065ea502c5064e2fe41183fb49c48bb20b17f26ea
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x92fade7263acd051dd7202e6d42b9d3a2f6054158f515f518b880709a243e39e
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/21 下午5:52:24
|
||||
Mock POOL Tx: V2
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/21 下午5:54:43
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0x2a5bc64f488ab0fcc4e78f61b3828a95a0cb876c259da8b5302fc34fc6728841
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0xa5c4bdf42a3d25eedb94ab532ee2ae23748f9e2a887bc1c927ee5d57a46e45c1
|
||||
Approve:0xFE1133ea03d701C5006b7f065bBf987955E7A67C Tx: 0x8a9d851f58df5d051ad88507bcb3e89b5363dfed62fc32b3422e6c93363d5188
|
||||
Approve:0x123ee47BaE3F64d422F2FB18ac444B47c1880F4C Tx: 0x883b1629de0e9380aae3b49ad2fbd75ecc2872ed68fdb944659d19c57c914088
|
||||
Approve:0x0ab8EF8B19655F32959c83e5fC5cD6536065D28f Tx: 0x0c7632f16bab993fdaeb0ee8e5439019c331302a4fdac6053581901f62e444da
|
||||
Approve:0x6462794c19e6b4543BEC56200212c7c746bbB9eB Tx: 0xc26ec75d39d530d8261bddf240838840312f90a7b079ad7d2f496b7ffcf59bdb
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/21 下午5:57:32
|
||||
Mock POOL Tx: V2
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x905e232630b5d7b6e0b94ba36bd757b98ae85e9367cda7eb14c25839e59fad20
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0xa8863df1cc7b14304ce6c86cc2c3cf430e3fd91c4d49f7485050686955b3cf93
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x94e3d04e8727cc89a84be545ee8645e54d957f1b4056d3d8829c4e02cf323a62
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x9ee20fe97cfe17073776a05fca857d3e8f6806c7ab6012d0452e0104382ea0dd
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x31342d7e7a1466316dbc1ae854ec72fbcc5538e613703551bc9580f33695f6a3
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0xd5d4d5c6f366d743819fa840d007b08db01b9858e67910ab580558d7c80197b4
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0xa94d744c2eacb3289d997a4df6f0d876d281c9490277ec819dcd95fef1380707
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0xfd1cc2eac77c42ccd6917914423a59e0835bdac065c01182204d68973dfba90a
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/22 上午11:32:19
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0xf3d1a74bc5f9a26230b12c1ffa6ede8a444cc06989df7945902350fd29f8ffd3
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0xce2522019ab10095785ca2644c9867075606c2738ea877d34b8ad0f003d39a5c
|
||||
Approve:0xFE1133ea03d701C5006b7f065bBf987955E7A67C Tx: 0xd8878c926dc0c9fcf790226236631b2d035659a3bf6a309ac5ca572b812ab504
|
||||
Approve:0x123ee47BaE3F64d422F2FB18ac444B47c1880F4C Tx: 0x51d61b8dfbf5dd0433e3da23ac6babd80e00119cce07100ef2051664551114fb
|
||||
Approve:0x0ab8EF8B19655F32959c83e5fC5cD6536065D28f Tx: 0xc86697227d933f721a937fe64fa6d00d00282e0c0dd218b96802d32afed07b4f
|
||||
Approve:0x6462794c19e6b4543BEC56200212c7c746bbB9eB Tx: 0x4b776f5c6a19ec75312ce5287364b2fe7fd09f77fcf7e5f58b1321a027b7a9de
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x430312b3bb0c5be2fe6891ce7fad10fcf173f7c94c9a1f449c03d1f41ce555f0
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x033e34185f4ad1ee4029e559be5b394f1c64590d0c95d704c6363452ec9cf7f9
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0xde3a8c619ab6e23254be21d2bf63f782ae9ee1c9c88ce0c13134e10bc5747c18
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x867b98322215dfdbe185f4ede238b4d89d93ab7421bf455847c188ccda0ae55a
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x760fd48862bae8b4066fea533dc03673048b7c5c6fcca7bad2e0dba696baa7fa
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x43cd86086019b16683d869915bb5ddbbba9515c734dc8fedbcaed79829c3141b
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0xb77428c2b04c398f54b5d3d2c82c61f89b9e513bd5e8fb3dedd3257df66786db
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x3a00c5998e20b3136687559cf24854466ed4db9c4cbbc3170ec3dce4a89c1c49
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/22 下午1:11:01
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0x18628d36532b6cb4e7c9bfda1620c0468109b863bcea2b324747c6871f6cebb9
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0xf56f46c6580c66e9701bdebd5418d7c6cef926cb18f2fe86ca64f3a6551b7192
|
||||
Approve:0xFE1133ea03d701C5006b7f065bBf987955E7A67C Tx: 0x3f71e2423a07cd60932aa865f6d2eab97a540836fa7fcdb25bd574bbbfe443ef
|
||||
Approve:0x123ee47BaE3F64d422F2FB18ac444B47c1880F4C Tx: 0xd30ad979b91e934808eaa2f84db42fb10b1c41da65ec630fc2861a93fcf5388f
|
||||
Approve:0x0ab8EF8B19655F32959c83e5fC5cD6536065D28f Tx: 0xa23a99470a0ba46eed8350ab96d35f1611e74e47ce84aea2380e19e9ce6e5fc2
|
||||
Approve:0x6462794c19e6b4543BEC56200212c7c746bbB9eB Tx: 0x4c08777310a5937e4230488b649324e72f170dc1bcc590f62b037d3e276d7e96
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0xdef48e57e4263aeb11beb0c75ccbfe849686a3ab5650e408e30f19788286f0fc
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0xb4f2116439cc4bb2b6f3fb664aeb4b18223cbad2254e2307fb912210c5d97c8a
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x179855fb67ef2648c08716b1d0c092136471f3d092b02fa023ea72f08732d54e
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0xe0b75e03ebf4613332194bee33be883197fe8601a466614849eb737d2ebbf109
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x319b3913d3709cc75d25f4974923f74603468964a2966ba7b624811885e01b40
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0xbded78906a95f25ba22720ce45cff94fb015e921294eeb3c4a20402269cc2bba
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x9ebcf8d585ac9374bab0798b493ee64845daa81d289b8b3b6262785c401737d1
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0xaceb4d156bdcaf037e76442275da4e521ee13a02e3b16da34704d6e712d534e4
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/23 下午10:06:11
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0xb8998d7b4f18e2cc3a2926f8054e3bc04eb6f71ae78744837264268530e867e1
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0xa20a80abb4da33f882f21247f15b5069972d1ed103faca805fb930c5c9a61a25
|
||||
Approve:0xFE1133ea03d701C5006b7f065bBf987955E7A67C Tx: 0x368867d511f3c1af12f4cc8c20ca48f8f8add12bdd315728da4db8149b048936
|
||||
Approve:0x123ee47BaE3F64d422F2FB18ac444B47c1880F4C Tx: 0x2ee2c74ffb97191a8480e348613d9e84c64dcbf8e1c11a5c30de64b1947df554
|
||||
Approve:0x0ab8EF8B19655F32959c83e5fC5cD6536065D28f Tx: 0x293061f92c46ec349bfad543b9a64066a2ee61e265db5ba306aa1a6df3cc1e72
|
||||
Approve:0x6462794c19e6b4543BEC56200212c7c746bbB9eB Tx: 0xd18106912d26fb366174d34790933699992d1ad6bade18faa5e6c4e6f6246a50
|
||||
Approve:0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x859663ea7c3a429a10773108291e2ddca0dcedca3f7e193fe3fb5654f01dd61a
|
||||
Approve:0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x7dac7e0de043032525fe161d7eef9920c8e2ef58cd604ea241f244440e591217
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x0a7ba01be3758da3bc2842e19f6da4ff969b96cd9e7ec09c744bdcf473662e1b
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x531876bbe684081733014488222d666c68af96543ee656b266929644569ab1b5
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x71c11833854ee92acc270ab42e1d7a1674b8159c6202181bae9b6a084c06504d
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0xa222d2888d15b159a3f60d7d569b48b7922ebdbcc66b024b1f9c5d1db369e6db
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/23 下午10:12:23
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0x7f385e1d55aec77540565dcbf02d768257de16f98f77087c6352d474065cfda6
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0x5cad25f104a8d9852cf035f73ed88a0430b6dbb79fa251ada9ada2ff795aebd0
|
||||
Approve:0xFE1133ea03d701C5006b7f065bBf987955E7A67C Tx: 0xfc3dcd661a9b3909e6958953db895e56424041cfc8b5854e4e46a60ef2269cfc
|
||||
Approve:0x123ee47BaE3F64d422F2FB18ac444B47c1880F4C Tx: 0xf9f4fc4d2a88df0ced892e25d1afd063f677b9f0a9b57ecd1b80572e0e65e488
|
||||
Approve:0x0ab8EF8B19655F32959c83e5fC5cD6536065D28f Tx: 0xf139be9e478b24f45adeef91c3e774c66713ee4af281b4fd67aa329b9c015825
|
||||
Approve:0x6462794c19e6b4543BEC56200212c7c746bbB9eB Tx: 0xb3c1ce35b5a18b1ee9568cde368fbe4d050ef789f0c89c7b3d4c5d47d272fe20
|
||||
Approve:0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x8ee85f0292abeefe38b5de519a7e0f6694f7cb85e0ce252c45bab62e1fec0fe7
|
||||
Approve:0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x38eefe0542e5d07a74a24aa76634716457a27e53804909c5fb6caab96af12fcf
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x944c53418febfb42d93328007f4c0d2e31f9091f5a99b2126543681651e696f5
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x89be70e2dadca73db3dcdb9258731b88600e786328cfb0fff3786b7809683046
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0xe3e810553bb6bb4ea3c40370af53db16c54d392c3f4f0a289cb7571bb2ca91b1
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x325d7960defbf9382c84d863478d2a5cdb70d30ced8b922eeb4f890183a0eeea
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/23 下午10:18:27
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0xb8847c980265142fcf575b33e1c3b2dbf42b5cef7ef22d21b33a568b5b2bf453
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0x55d725b1d704b51d65c29458f7c9d717e8d11c8b44c268f49c2431cc1e761121
|
||||
Approve:0xFE1133ea03d701C5006b7f065bBf987955E7A67C Tx: 0xad8c03fe37a7462c816a09f73c8decd9e6b0fa5ab750adcf0ae87ba4cee9d18d
|
||||
Approve:0x123ee47BaE3F64d422F2FB18ac444B47c1880F4C Tx: 0x305e4b64e2ecc55c653f00ddeaa4135cdb6555cd9529d93499a0d440acf00768
|
||||
Approve:0x0ab8EF8B19655F32959c83e5fC5cD6536065D28f Tx: 0xae5795ceb81cf30d5c8f901137d5b4a05b550d28be2572edd0f1dd6b6511af70
|
||||
Approve:0x6462794c19e6b4543BEC56200212c7c746bbB9eB Tx: 0x805317786b98166c4857191b016959f7e3d843fe4f535a154ea63c4fd18b33bb
|
||||
Approve:0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x6549b00d575d11b2896e3820ea45f7275c779aaa6280236010483e748c490d03
|
||||
Approve:0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x5623cb45c81fe9cb3c567a80fa08ff2da2f0aca082186404b52bab4a88d497a2
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x0f8d09809616a61902a6c21cf980625eefdc178eb19e143c296197cfa4a1b306
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x046196c6365fb7839efb424189827c474cb8f7d827f8d5e014655fe35b32fb9d
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x5584b926faf63651447d72c3d6369ffc27e9b4bf7429fa6baf1f4e7fa0bbf3e7
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0xb60b498ed12ecc1ce739d33d2e8460b7f4a479e188c1d376ec598ebffa479389
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x9cb2ae41808ee9118d1843b6317b6820763ff664f18ec2047e57ad7b4bddf519
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x2bcae29b1b0a68215e04a7ba5bf8135ead8e9f5122567219ad06ed4438f62e5c
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x99e5776171eddfbe714afe60fbe4cfc7b61bc0e3dc1d111dc52536ecc23f761c
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0xf6d5abe93d1c64c9b33b7fd1325b05c80c71e475a3484ff9bd447f9db5866d93
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/24 上午11:47:25
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0xbeee55d0af864da7c8e8c6962d488969aefb010c7b9b5e9828e6a0339a142251
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0xe8e854b40f696cf64f28e217eb26823ce4363c9cbb44edb04c2bbb45c6515ee5
|
||||
Approve:0xFE1133ea03d701C5006b7f065bBf987955E7A67C Tx: 0x85a7b71466180ab6f1d163c284160920a8720abcb9841ecd4d0cb7f3292c7010
|
||||
Approve:0x123ee47BaE3F64d422F2FB18ac444B47c1880F4C Tx: 0xf3192fdeb49c7213cc21d8a6894237885ace25b565c7a9de3209528b84474a28
|
||||
Approve:0x0ab8EF8B19655F32959c83e5fC5cD6536065D28f Tx: 0x9ede00579795e483dda95cfa01aaf9b3b2075f18e9435fc2455c9d7e9ca92ce4
|
||||
Approve:0x6462794c19e6b4543BEC56200212c7c746bbB9eB Tx: 0x8cbb38788c2a20b6d921c1089d8e275acdbd4c64dadfa1b0a596b3806861a787
|
||||
Approve:0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0xd455081eefaa81582abff9563db7dd4cc99e73eb72c006d7b343f5b90fb60743
|
||||
Approve:0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x8781fce0343948df4a2c91f3e27c23f86f6cf34275a955fc6fbe3cb78f5f4f03
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0xefda1022e036008247eff6d1dd86e9d764818af8ba036cee5f56b6299155c503
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0xa923aa193b804c5388fcee54d5062993a388becc95e66e0412f7b4a75e5a533a
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x3e07db9d128be0e853843cd59b74ff04dd730d47604cd3ccb5bd9338868a81b1
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0xb33d6496422b6135667198d4fe1c8d7a7340d95741d741d912ac156cbd636726
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0xb5c04813d12c04cfe3b2fe8af8d27e5460dcadc2657f52ff7b68536d0f67b6cc
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x3b53391eb40bf8839f41a58adf18fe02682fdc7be9f540d1737f889b8c9720d5
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0xa82e90e7d03aa75cfc3d2ecf6a8eaf2c9e2a77a5d43b1c0dc7575f46d7f5cf7b
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0xd4746f0f885d150764d89299bbbdea2c06bc08ab121bdf151d999daf5efacdb8
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/24 下午12:36:32
|
||||
Mock POOL Tx: V2
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Pool:0x7A71E03829cf70cF15Be7534561D8626b90c9450
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0xCeDfeda3D7D90eaF6F7Aa04936ebD77109ba5740
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Pool:0x9d1B75e35AabE062ec54C2E3F26685C57e897c4b
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x61706D93E7901BaA2f8e541404c2583eC7A1C293
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Pool:0x1d4f55C99BEF84ED889699Be64A691c6651F847E
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x0fbd69eC65E3Cc16eEA8A8913656F1EBc3fa1Dc0
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Pool:0x918497560A41621F03EA6b3B7865f42e5e11BF20
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x24D98FBE194FD34e168B905ecCb08F49310c7F54
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/24 下午4:17:33
|
||||
Mock SWAP Tx: V2
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/24 下午4:18:21
|
||||
Mock SWAP Tx: V2
|
||||
Swap Tx:0x259831396ec3ff854d560eff71340c2d7670c986761f7829262ca4b15ebad396
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/24 下午4:35:40
|
||||
Mock SWAP Tx: V2
|
||||
Swap Tx:0x3adcb6a34a7c86d62f9aca1b9448b0c66092bd8bab535361972bf564090a8124
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/27 下午10:19:11
|
||||
Manual add Pool: V2
|
||||
Manual add Pool Tx:0x51268996e829f32fad92ffc3bb21174768c706975d5536de288febfe33777c61
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2020/12/30 上午9:41:36
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0x90ebcdcd94428d2fe932403f283de1a428367b24eb3d717e3c9ae8cbc7fa042d
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0xf10510050a3e6f9672f0bbffa878f78157760813c855d0737a5e7dbcef1f8bdf
|
||||
Approve:0xFE1133ea03d701C5006b7f065bBf987955E7A67C Tx: 0x15a3ce08afbfc3a0a76523475b8a046a513e60e6d53206c13a008a06f657e93e
|
||||
Approve:0x123ee47BaE3F64d422F2FB18ac444B47c1880F4C Tx: 0x2b35aececc77bf35713e763346dcc34f0bc157b8f11801fc00be67f370eadf5e
|
||||
Approve:0x0ab8EF8B19655F32959c83e5fC5cD6536065D28f Tx: 0xd7f5086c4d84e2a8b0d7770b1806e93769556c0157d3deebf2b1230f94cf062a
|
||||
Approve:0x6462794c19e6b4543BEC56200212c7c746bbB9eB Tx: 0x15f9224529d0a83664a31b4c0c98782e4921fed15cb2b7e58c2cc72c74bdb2fd
|
||||
Approve:0x69c8a7fc6e05d7aa36114b3e35f62deca8e11f6e Tx: 0x790a3da25ad80e53ce5235a8c0654f223ae0138e2fa7eccb23b9ea758475ee17
|
||||
Approve:0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0xc658ad431fe8c48237d692a05219987de5e9fdbbfe2f5fce121af0b239f6b8b2
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x5eca15b12d959dfcf9c71c59f8b467eb8c6efd0b Pool:0xD1577E3e27dab80D5F4a11Fe0960526418267e8f Tx: 0x6060ffc9b8175f19713d574127e79de60587671782dee3f40365976bc62e3e2b
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x5eca15b12d959dfcf9c71c59f8b467eb8c6efd0b Pool:0xF2A7675f42F286214550c76c02D79efAd4A6D7ce Tx: 0xd6605ad6f00b8f01d2d0514e833dd1b559550cc9c61d90056930f9ca48d07f65
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x5eca15b12d959dfcf9c71c59f8b467eb8c6efd0b Pool:0x50CA4A1714bE260B8aB8980c1649943b392d1cDf Tx: 0x8308da29d498548347380e73ad2daab06b4950db2d6e5e4766d858b4eea50eed
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x5eca15b12d959dfcf9c71c59f8b467eb8c6efd0b Pool:0x2f487299a7f5aEe132348dC306b51816F4af17c2 Tx: 0x02fab2ac1c39494536d78004dd9de93e20609ea9a61f9aa9d1ddc1b0554071b2
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/1/8 上午9:29:18
|
||||
Mock TOKEN Tx: V2
|
||||
ERC20 address: 0xA22E0FdA630101d752C748DC213B36bE74A54cf7; Symbol:WOO0
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/1/8 上午9:37:13
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xA22E0FdA630101d752C748DC213B36bE74A54cf7 Tx: 0xb1ad2f3b3782f3a09f75d951073ba7a1a07cde1696427f6383d8dcfcf471d0d6
|
||||
Approve:0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Tx: 0x11b190fa1dd1232a7ae8e17540c5af4c1b81ad0f20b5e19b28d410b84c8f02bb
|
||||
Create DPP: 0xA22E0FdA630101d752C748DC213B36bE74A54cf7-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0xCc50cC29769A296CB828496830664F747711F450 Tx: 0xf04ddff31fce21efe7f37a419ff15fb37e823abfe0cd2e44b47a52e0306879c1====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/1/8 下午7:59:15
|
||||
Mock TOKEN Tx: V2
|
||||
ERC20 address: 0xfF2985D13953Cb92ecc585aA2B6A4AF8cB46068f; Symbol:DODO
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/1/8 下午8:38:40
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0xc3bef608ee3a68ae77fe7f1529d32d9780550b8c65a5d29ed00561e0248d2e48
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0x3fe5c3278d36a4fee5763e34d6c1ad19096252653535ed9b10128f7c63f29051
|
||||
Approve:0xFE1133ea03d701C5006b7f065bBf987955E7A67C Tx: 0x34c1fb0abe800f0b3b1619b878c3dd74556d8c3d6aca2bb470a2241568e210ad
|
||||
Approve:0x123ee47BaE3F64d422F2FB18ac444B47c1880F4C Tx: 0xa4d65095bbad39f9d625d8ca38f7def63bbce089020b721a70af52d253f61d64
|
||||
Approve:0x0ab8EF8B19655F32959c83e5fC5cD6536065D28f Tx: 0x1cd9b9ffe78a589f864d8a433e2409e79d163042f22719f43d72b183a394944d
|
||||
Approve:0x6462794c19e6b4543BEC56200212c7c746bbB9eB Tx: 0x8c0c314d652cf4527b38611f9c433756e509078c6491e81ae419aa5acdf8535c
|
||||
Approve:0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Tx: 0x0090a4f02eebc8eab155bd94df6fd410d395fb8b83a537cd9970267a8f75fef9
|
||||
Approve:0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x8f2570735caed9a65fde9971e657e6e1509335a4607ae576f97ad9f50ea47d69
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0xA24A179a4Dfc1C9A1DbC2a17db5A9A79dC935d88 Tx: 0x5bfdb7dfb3b65fd77a10b95f1e0d4c8ea2ad8bc6432257bba5bf138ba439016f
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x26115Cd3B06E2817E2Cb655199ccB58Ad4abdeDd Tx: 0xe9c558dbd3832936aa30fe588fad89a1b1e45d9f5e8241f44e765a76b7dcd670
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0xf54d43c419754b9C397e5a69CAf418bdC55EfEd5 Tx: 0x8208048cb3d0346826b574851a78e25548f74ab13048830e190950cc548d7119
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0xf5a379A1EfAa8bF60839D633547A3cCA311df89b Tx: 0x3080dfe6d54c3883547010781eca1276feb9cb3c0f0066cae12caff19b55e228
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0xF00BEB2E974564B8867970FF8db7c0fFE0866c52 Tx: 0x214026df1fd2369c71d5050e6fa0060d3a55ec28f4d90f8696f2c4c517546914
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x94648109F3DE33B2a04FbAE8Baf73F4Ea83ec259 Tx: 0xec487be5e60ad4614fa804c6798fe32ee5b87b6eb6b47f3d00435d220b8a9b84
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x7e3261fEbD42a045429A7BfDF02307064034E157 Tx: 0x7412f7fbc70e236ffcd8a95193bfacc2926fc0dcfcc98cf0f507acb8489ece66
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x875bCf57CC98e7c6cfC1F7c80ca0fb2709Bc4F01 Tx: 0x1fe29cf3ff586e914c81f31291912be69a7d73a50396f986ddf143495d8ba3ac
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/1/13 下午8:37:27
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/1/13 下午8:45:21
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0x713758a969dd87b682fff12535aec26b068cabfac7e623759105e02925108796
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0xa69a799bc1bad6873a972aee79ac77f53960df61caa69330c712c098e933b079
|
||||
Approve:0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Tx: 0x58a13285f365d9b0955f10523984758412f9a8776b261e89c5d7e09c7dc9bbee
|
||||
Approve:0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0xb7db2b7a86e675a9ed8ae9e573f9e33337b79c3dea037c9a9df91ffb2f8cf456
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x06FC88aA4598d176e3D936823ea8C62EBb4e9096 Tx: 0xea949b9890895450666a37b7ecaa39a530cbf14d6a64dd7ecec9d02af7ff43a2
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x44Fe35FD06878b4FD1FC85C66C8a8991E96363A8 Tx: 0x1a75e771132f0d77d8eb6ae961d25218508953cbe1f9b47720ee77d4dbb52566
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x40e98099713F3b26796d2460df2fd5D0f41d22E6 Tx: 0xeeed9aa66c6ec98fe3ac7d4bff8050fae6afaac98d416006454b645899614dcc
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x0fa0Fb4230d890f2098A09C125ef8dE4C54ed65A Tx: 0xa36501c62683d11fcc37fe14bb4d5c0b35514c1801cb30ae2439eead9b3f0dfe
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x7E70B7d95847c4688fc111aB2A670855bB1F8425 Tx: 0x1b3f3fea46d3d8329c82b6390355e8170a6cbf8492834d7d9f923f915867ad34
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x312593a0045646aF845bA80Ca3995b68B6C37d8F Tx: 0x8959fc0b0ef347734e64668e4150fd1586329aa7e102286588174cc800e5417f
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0xF3560C11F6683D5A80cDD2A2dDEcb15863f9cE9D Tx: 0x6f4c01c6c99340e966aee06d88a9889512550aafc733259d280edd1a1a816411
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x9a5905c9027ED43bB08088cee5EEa71342152280 Tx: 0x533f85a0489a1441a2cdd6f82d1b0b0a7110ed833391cf2448ad9f9526ae6fc7
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/1/13 下午9:51:04
|
||||
Mock POOL Tx: V2
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x5eca15b12d959dfcf9c71c59f8b467eb8c6efd0b Pool:0xec6675ba2B9f978EF5bFBEa391b1c42bA74E340A Tx: 0xd417e65c4e437a1e2ea2432c149393869d6d6b8d5de68cd361455395a2441e7b
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x5eca15b12d959dfcf9c71c59f8b467eb8c6efd0b Pool:0xF4833EDaEfdBf28e246ade2d82EA7087Bc106C8F Tx: 0xad1ce8f0fbd5b937055f62a0c4e6024ef32cdf40bcbb8033cbeccdbf314ce9c3
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/1/15 上午11:38:46
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/1/15 下午1:16:41
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0xe444614656997e88abc7f8a319cbd636b60802c0272233c4784b55de2b4bb8f0
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0x52bd6229a1202a75dab8f22169054d4d6ed1d661550e92eb4ca63fbcfb04c90f
|
||||
Approve:0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Tx: 0xb621fd266c2adcb6362f631ceb193016e14dc55f13979ae854fddb19c5b3ad52
|
||||
Approve:0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x263259a175711b1b8dad83fd72bbe3b7a6ca9f9eff0b53499e1394a47ada71db
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x715f1aE436Db8AFB9Cb1B4fc94010479b80Ef852 Tx: 0x42bd2b2bb8b8cb09d8e115b4e1f289f8de024712caa5faa2189ab999b4accb76
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x375981e1D3350ae0A30e53eD8C3aC004d4D89bDe Tx: 0xa293d0d532038b7ed0e30d7afbfdd3ba3464c8aee20a3f256baee5ed9c5bde66
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x8dd53F0ba04C1e3f293D8a8a6a2143205EC4a34c Tx: 0x963cea093acc669f510a4123dbd03ab66a6cda6295e71e860e1c8ea89cdf1363
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x773B12fdDbD3C41f479601F57DBca99E70f2e0bD Tx: 0xb08223246a75df541511ac9d765bfdc204748f1ee6467ebb8589ebc42c45f185
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0xeC0fe30c2028b28b90E5e7bfd7AF5B76E6Eed000 Tx: 0x245f55404c3636b40e4c86b0ee22c4bae3a95f908a3bb07409a0e88bc88304df
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x14D4E63d050f235D8bf1Fd3dD3CDc484168FB246 Tx: 0xed71901c2c96d8b9d39839bf47f0efe8caf06fc0e8f6156a989c4d60c0dd927b
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x82a777E65d14D462cdb8fE1886115Bbbc1F24039 Tx: 0x10360317368344c2e1519aba4fff57e6c247c0c4d95adeba1aac5c1e917acdbb
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0xBA9b148769BdF0D872439ac31Ff103D487e10f64 Tx: 0x912cf081eb7e8abeae94c3dbb45b745e926d0aec76387ba897dc0e49fc660378
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/1/19 下午12:25:59
|
||||
Manual add target Pool: V2
|
||||
Approve:0xCcf0733cA7B6299D59b1Bddf87f3a8AAaD87461F Tx: 0x242435d2b174bcd06935040868eabc50d2074d52f1178bb46523ca3c3cef6a15
|
||||
Approve:0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Tx: 0x5e9d0f882967df12bca28f9beb3a500d5a942f2ac50dff10b48662bfa390c81f
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/1/19 下午12:35:14
|
||||
Manual add target Pool: V2
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/1/19 下午1:21:12
|
||||
Manual add target Pool: V2
|
||||
Approve:0xCcf0733cA7B6299D59b1Bddf87f3a8AAaD87461F Tx: 0xebbd30fc18190d0fd7df03ffd24fb784122c0b1e7e73ee5ad2da64c1877ecd0e
|
||||
Approve:0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Tx: 0x1de48a27ef0e08a0bffeb016991b5e9d29ba35920bd9ea5478dc273568616ee7
|
||||
Create DPP: 0xCcf0733cA7B6299D59b1Bddf87f3a8AAaD87461F-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x961A1E706907e9AcA5b3d784325C8D571CdACef9 Tx: 0x3a698fbf1e71603dd84ed89ae23c106bc689743b104898e5a5afba9a26f86d35
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/1/19 下午7:18:43
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0xa258254841a87af88a4d8774120c97d2d050342cf209ef9c092a537b1d4416cd
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0xe6f248f5fe683b5c8a220d7117cae689b7621d345059c4ed3e22fdcf14f3c2b5
|
||||
Approve:0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Tx: 0xc53556e9fc41b5c85b4e7b79fcb2f0a523d3ee2742cff7fc9329e90d3fec8e6d
|
||||
Approve:0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x335cf90b6c828ed74c1f437db3c0f5da414d08e34df99c1a807c1c365697acd7
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x2a2cc03eDFe6779fbB50a1Ac24DD6e0969235250 Tx: 0x5cfd06c99886b6e4dbf230dfb198d4485ac19715ee2928218e67f53523b15441
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x078BfD1F889A7281eB42a50B57b044f810FEc06C Tx: 0x04b2616dece03d91cf2acfab3e31156acd6eecb89f40d5b507b6f6a5839a7aa0
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0xfed3E2A4c96091D4a0ad1d5fB1B6Ff26149167C1 Tx: 0xe796c67b0947526700711788bbbd04492cfa662ee0c029aa831d686ecdc0b424
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x07c18e84FF588396cb28b51A847EC838865c8347 Tx: 0xaa663a80ed35871b6de6b6a32349d6e7dd63a3fdd1d43c48b1415fae52e09789
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x7C20cCFf0fB764A4fdbAD7539188DaC65E01cF73 Tx: 0xcbdbd8f56160f0acd1c04105d45b7cf4bb7b616c602d1149b566f560dfc23b17
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0xA99917C00371a37Ed41d8AAcc78c38a86b16B0bF Tx: 0xaf67f233c0a7b6db7fc752a1d8f71201c41a7904bf1bdf3a08d4726f54980592
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0xE4b8D60F358828F0cb51935785Fe5a67892275Fc Tx: 0xc5b4976cc0783e767ac5b0d80e0285f5e263fefc4c2070656a8a7ac9eb0c3a31
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x30bD3A1100c247B5e9d62734a6Df6cab6943F808 Tx: 0x845c6a5b3eb170052111caae85f53a2e9983357bbd7deb71c5688e8fbd05187f
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/1/19 下午7:46:00
|
||||
Manual add target Pool: V2
|
||||
Approve:0xCcf0733cA7B6299D59b1Bddf87f3a8AAaD87461F Tx: 0xed6ada30f414d696eee682871e51dac89206dd077055635570d4c5d305c9e437
|
||||
Approve:0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Tx: 0x7b42c175e29053ead5cef8f922296411d2db63ea753640742672b25969abc598
|
||||
Create DPP: 0xCcf0733cA7B6299D59b1Bddf87f3a8AAaD87461F-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0xE6943d8494378cF463c9bd7cA1Af3eda9ac12649 Tx: 0xab31c5356f2f608d6f0ef369379af507d23f7cb20bc6f59b82541e90b0eb7c95
|
||||
====================================================
|
||||
network type: bsclive
|
||||
Deploy time: 2021/1/22 上午10:56:29
|
||||
Mock TOKEN Tx: V2
|
||||
ERC20TemplateAddress: 0xef49a6DBa1C8DF859E49c17E9A485B439c7689d3
|
||||
MintableERC20TemplateAddress: 0x6373ceB657C83C91088d328622573FB766064Ac4
|
||||
ERC20FactoryAddress: 0x5e84190a270333aCe5B9202a3F4ceBf11b81bB01
|
||||
ERC20 address: 0x1ceF9A5A4825b46A6Cff6275a382bBA03e60c98A; Symbol:DODO
|
||||
====================================================
|
||||
network type: bsclive
|
||||
Deploy time: 2021/1/22 下午1:51:48
|
||||
Mock TOKEN Tx: V2
|
||||
ERC20TemplateAddress: 0x9890d0719ebFeeCB5984dc4aA1221C8d70Ec0cFb
|
||||
MintableERC20TemplateAddress: 0x6bdBe4Cf19615562aAf743BC8b5Cd2b987Df605F
|
||||
ERC20FactoryAddress: 0x0C8A860C61c30Aa963f1dd6dDddCa87bB13741e5
|
||||
ERC20 address: 0x0874baAF4a5BA4B1b1FE9DBBc3EbfB4080c5Cf22; Symbol:DODO
|
||||
====================================================
|
||||
network type: bsclive
|
||||
Deploy time: 2021/1/22 下午1:54:25
|
||||
Mock TOKEN Tx: V2
|
||||
ERC20 address: 0x571c68a358F7376071c21910436895468214DF2a; Symbol:DODO
|
||||
====================================================
|
||||
network type: bsclive
|
||||
Deploy time: 2021/1/22 下午1:57:57
|
||||
Mock TOKEN Tx: V2
|
||||
ERC20 address: 0x497A44c951fCCF92ADfdeD0a5b0162256F147647; Symbol:DODO
|
||||
====================================================
|
||||
network type: development
|
||||
Deploy time: 2021/1/22 下午2:02:32
|
||||
Mock TOKEN Tx: V2
|
||||
====================================================
|
||||
network type: development
|
||||
Deploy time: 2021/1/22 下午2:03:08
|
||||
====================================================
|
||||
network type: development
|
||||
Deploy time: 2021/1/22 下午2:15:43
|
||||
====================================================
|
||||
network type: development
|
||||
Deploy time: 2021/1/22 下午2:17:04
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/1/22 下午4:12:26
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0xb50d7e81ad7a513c0af80ad266adbdc860c3778b8ab195ec9b212254d619575e
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0xf34756b71a55168d6969b359cf242005331479284d99eb0f25eaf89d3a55670e
|
||||
Approve:0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Tx: 0x144da42d3733f34b16ec10bdbf1bd1e062dfabd80e57770f1c0044bb5b8c6a96
|
||||
Approve:0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x0445a7a66a197d3593e5b4212e1c9ac1b94922764c25d2e2fa4890ec013507b1
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x039C04CEFa590e538441A7BAfe6965AcB4A1E34c Tx: 0x79e8f4127c16b19f7a0ff9741b05f086d7f6429f4b8c00cabcc9d3d7eff79ac9
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0xC4070dc0a10332EfA82d72839281cb55c1037341 Tx: 0x694aa43eb9cb6654913aecfa77885c4fd886847574dbe3d19e9a436a16c9bfcf
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0xC232b6F18Bb48608EfC9bf6790B2ba0A3Be7E365 Tx: 0xa77c971322b33301eb3d2642cbf30bb1fbeb44568ca92fff63ff5632e7d805af
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x52F1709f83D2cdB355db7Ee42172B69730B208de Tx: 0x748c17c38146b8d9d9c59d3991e56f418fc79148d5c2ffe2b94f019d00d242b1
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x47D70124aa9C568b7515f71F023FD0e55A6926b5 Tx: 0x52e028407c0467d52f9cdc64f379081e80f451e564af7a93d5f489adaecb6d65
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x67841b1553Ed349111659E56897Cd8480DA88f8c Tx: 0x165e682bdc696a6af5821944718508dfd7fc953f1e21e213a741d52ced53ab03
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x3e8DB146423f2Df1Bb3f07C9D7Cf3e76D2C74446 Tx: 0x090746636f90cda0f12435e8cb29d325eb1c730e87e9b8746455b4071fcc2a9f
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0xbD0CCdbC8FECcc68934Bf884fBe85AB7B51A15eb Tx: 0xdbda4038d439060f9ef3fc09df58f80758d38a81e246cbbc0c88a6b7c275b2ed
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/1/26 上午11:13:49
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0x21319fc7b2010f495706d835fe0d20177a51c4aa9e787ad4efb151f4a83b0b97
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0x0219e34cf6be4d9f1384034ce4c35bc030f67d00e9e380b4b0acec64ecd553c1
|
||||
Approve:0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Tx: 0x2c0a25770e0cc6a48d63a8c8f9067213695c8c1b657326379b58b6090d4c7b13
|
||||
Approve:0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0xe0b9870564d2037c75b3f345a9dd93d80d9405a949094459c5b34f94acd3ac61
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0xF2b06A3A58CEd368ebc6e5BB578503ECC9d50043 Tx: 0x4671da84177eb8a69c2cce7ce42101f3e2f0cfc221100b5613d0a0d5565e8c79
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x1D690066fc3F2D808555839B630a89da118B9466 Tx: 0x5e3609531f6a6918bcc2f9d91b154d78f0b15d8b229da00cda960a380fd909dd
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x7B0d1D528a08619B370eb5c920298F74465b1982 Tx: 0x1dffacc99a0ce542425eb5fd977da570dae26246abb929e2a4eb04fcdee6a994
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x3997576b46e26D3fCEa7C4A76a62146AE5A903F3 Tx: 0x07dc666596b9c47522ed8dfb194cfcc9d673c0c63ec4d456d7b7485ea7eca57b
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/2/4 下午5:17:14
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/2/4 下午5:54:17
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/2/4 下午6:12:03
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/2/9 上午8:55:06
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/2/9 上午9:22:10
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0xeef360809a8a76596ad1df35b0446b5b95bac7dffc9197446461ea3feffe37d7
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0x762bfee15a4d64075fec8f1ec316ff88e26c7afd3680e165383597f54569556a
|
||||
Approve:0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Tx: 0x90aa6261ceda2f5ca85f47fa837e8c6a922fa360b6608052c268751bc0603561
|
||||
Approve:0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x9da3ab71c06b430fa3701a0893cd03dd505939d93b9437c42bfd3007a58e1eaa
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/2/9 上午9:37:23
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE Tx: 0x126e9df26d72d0dd31a34c12b52af93a344e4e75cf21ab421a6ed40576d75da9
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0x9f515352cfe82c58da2bbdb569ae174dbc129e2b3ae5152d35815554f5e23205
|
||||
Approve:0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Tx: 0x2f1bbbe75d0d702d5a2aadfcfb5f1ea6b5de31592e0c59bd587b0ae15eb6945b
|
||||
Approve:0x156595bAF85D5C29E91d959889B022d952190A64 Tx: 0x4d2644d6b52fe82c142921a310ef5a9326828fae9335877a3495810b192b7445
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x1A277d421b46AE6574AE726287548c8F1A9fE696 Tx: 0x430ce391328636d6434be3b6b6a06c7904d8451e29c1a63b665187601a189f7f
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0xaA5e59551361aef38fbe56dEB75bEf19934b784c Tx: 0x0f4a8831dd6623784a5f9b90e04e43be7859cee6bd6486f8998cecbcdf01b497
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x9b198c973dbabb7DeF97465d54595E609c6158c3 Tx: 0xa715e83efcc2f884ccf1174d539b4cf3ff387902b8e01ea6e3f6d09b4216118a
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0xf6B54C865c484E889B30F23Ae298538599CB0708 Tx: 0x45cc1fc7e0a3bf1d750a4f9f1baf1c6d5a8a697ed21124f2f265e02ee8be2fdd
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x4DB1Bd2be60A5334C9FE81495Ad14FBe60Ca93E0 Tx: 0xb8db13dd215ec0644abf51d013d8f1b086ab80057d28e244844f3bf9d1c1d168
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x420083a9CB8B00A7CeBCFEb5Cf87CF387f710f99 Tx: 0xb39f27d3e4caf5785d9ce2b908c7d0efed3755a8989920639c0e56fa5b5867b2
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x43688f367eb83697c3ca5d03c5055b6bd6f6ac4b Pool:0x431C5Eb805eEe2b61721F2282F6C8ca943088854 Tx: 0x253d4ed17dccfdb546652db3cc7433594401d3f66ec8dbfacf38f1c6a2173211
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x156595bAF85D5C29E91d959889B022d952190A64 Pool:0x9bC80A052b273A3E450A011dC6Cf7D626fbB339B Tx: 0xde39181b6563dedc9dfa6f9693d029a3e483e5e49398002b990c2dccb424053f
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/2/9 上午9:45:37
|
||||
Mock POOL Tx: V2
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x5eca15b12d959dfcf9c71c59f8b467eb8c6efd0b Pool:0x09F24c92Dc04a94aB9038A7571f9704D90d8F0f1 Tx: 0xfc09fc20af6a68626e6267eb708bbd957536af578da9c5fd735854dced832e92
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x5eca15b12d959dfcf9c71c59f8b467eb8c6efd0b Pool:0x2AA7d9830Ce612F6bFBf8066f81DD007c47DCD2A Tx: 0xa12d2d0921da80e443fd8d40b061612bc1cc61de5f68901b542bc985aa5a3e45
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/2/9 上午9:49:20
|
||||
Mock POOL Tx: V2
|
||||
Create DVM: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x5eca15b12d959dfcf9c71c59f8b467eb8c6efd0b Pool:0x09F24c92Dc04a94aB9038A7571f9704D90d8F0f1 Tx: 0x6ee2d127b8ffbc6ec102fa32dcab7e4f81a583650ea565edd660ffb430566042
|
||||
Create DVM: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x5eca15b12d959dfcf9c71c59f8b467eb8c6efd0b Pool:0x2AA7d9830Ce612F6bFBf8066f81DD007c47DCD2A Tx: 0x55670454f9288bb833390e102062836e3eb3a55568a46869fad83c0b048a81d4
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/2/9 上午9:55:55
|
||||
Mock POOL Tx: V2
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/2/9 上午10:00:33
|
||||
Mock POOL Tx: V2
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/2/9 上午10:07:07
|
||||
Mock POOL Tx: V2
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/2/9 上午10:38:48
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0xaf0228c0a967d69750e54f18150b8ee0c7cb3801cb0643fdcb5b6dddcbbadb67
|
||||
====================================================
|
||||
network type: kovan
|
||||
Deploy time: 2021/2/9 上午10:39:56
|
||||
Mock POOL Tx: V2
|
||||
Approve:0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA Tx: 0x29017dc8173e6e65768ef17baeffdb006e88d36088be0cc97a53c365ac929e60
|
||||
Create DPP: 0xd8C30a4E866B188F16aD266dC3333BD47F34ebaE-0x5eca15b12d959dfcf9c71c59f8b467eb8c6efd0b Pool:0x210912095691C9b0e318c22e49d94170ACAaCd0a Tx: 0x5bf334d720433b4fbfb71a4f75f5755ccd39f0977e59b74e78df083b03d9d9f5
|
||||
Create DPP: 0xd7f02D1b4F9495B549787808503Ecfd231C3fbDA-0x5eca15b12d959dfcf9c71c59f8b467eb8c6efd0b Pool:0x25F03Cc8d661D04513D17497dDE752BDF96A8459 Tx: 0xb15244e5e51f2e593adee05c337c00b265636869c59af6589ca49b82f56a86a7
|
||||
====================================================
|
||||
network type: heco
|
||||
Deploy time: 2021/2/25 下午12:09:59
|
||||
Mock TOKEN Tx: V2
|
||||
ERC20TemplateAddress: 0x62E1622a47C9Fe74B2cF0BaDe5Ecb8669ff9bFBF
|
||||
MintableERC20TemplateAddress: 0xdd9dE5eD7A11b1Ed3314CD7f754f27A15DeDC63f
|
||||
ERC20FactoryAddress: 0x8476DE046e1923adD9002A73133230B9e5BE4127
|
||||
@@ -27,6 +27,9 @@ const DODOV2RouteHelper = artifacts.require("DODOV2RouteHelper");
|
||||
|
||||
const ERC20Mine = artifacts.require("ERC20Mine");
|
||||
const vDODOMine = artifacts.require("vDODOMine");
|
||||
const ERC20V2Factory = artifacts.require("ERC20V2Factory");
|
||||
const ERC20 = artifacts.require("InitializableERC20");
|
||||
const CustomERC20 = artifacts.require("CustomERC20");
|
||||
|
||||
const CurveAdapter = artifacts.require("CurveUnderlyingAdapter");
|
||||
|
||||
@@ -44,7 +47,7 @@ module.exports = async (deployer, network, accounts) => {
|
||||
let DppFactoryAddress = CONFIG.DPPFactory;
|
||||
let UpCpFactoryAddress = CONFIG.UpCpFactory;
|
||||
let CpFactoryAddress = CONFIG.CrowdPoolingFactory;
|
||||
|
||||
let ERC20V2FactoryAddress = CONFIG.ERC20V2Factory;
|
||||
|
||||
let DODOCirculationHelperAddress = CONFIG.DODOCirculationHelper;
|
||||
let GovernanceAddress = CONFIG.Governance;
|
||||
@@ -56,10 +59,47 @@ module.exports = async (deployer, network, accounts) => {
|
||||
let DefaultPermissionAddress = CONFIG.PermissionManager;
|
||||
let CpTemplateAddress = CONFIG.CP;
|
||||
let DvmTemplateAddress = CONFIG.DVM;
|
||||
let CustomERC20Address = CONFIG.CustomERC20;
|
||||
let ERC20Address = CONFIG.ERC20;
|
||||
|
||||
let multiSigAddress = CONFIG.multiSigAddress;
|
||||
let defaultMaintainer = CONFIG.defaultMaintainer;
|
||||
|
||||
if (deploySwitch.ERC20V2Factory) {
|
||||
logger.log("====================================================");
|
||||
logger.log("network type: " + network);
|
||||
logger.log("Deploy time: " + new Date().toLocaleString());
|
||||
logger.log("Deploy type: ERC20V2Factory");
|
||||
|
||||
if (ERC20Address == "") {
|
||||
await deployer.deploy(ERC20);
|
||||
ERC20Address = ERC20.address;
|
||||
logger.log("ERC20Address: ", ERC20Address);
|
||||
}
|
||||
if (CustomERC20Address == "") {
|
||||
await deployer.deploy(CustomERC20);
|
||||
CustomERC20Address = CustomERC20.address;
|
||||
logger.log("CustomERC20Address: ", CustomERC20Address);
|
||||
}
|
||||
|
||||
if (ERC20V2FactoryAddress == "") {
|
||||
await deployer.deploy(
|
||||
ERC20V2Factory,
|
||||
CloneFactoryAddress,
|
||||
ERC20Address,
|
||||
CustomERC20Address
|
||||
);
|
||||
ERC20V2FactoryAddress = ERC20V2Factory.address;
|
||||
logger.log("ERC20V2FactoryAddress: ", ERC20V2FactoryAddress);
|
||||
|
||||
const erc20V2FactoryInstance = await ERC20V2Factory.at(ERC20V2FactoryAddress);
|
||||
var tx = await erc20V2FactoryInstance.initOwner(multiSigAddress);
|
||||
logger.log("Init ERC20V2Factory Tx:", tx.tx);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
if (deploySwitch.ERC20Mine) {
|
||||
logger.log("====================================================");
|
||||
logger.log("network type: " + network);
|
||||
|
||||
13247
package-lock.json
generated
13247
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -58,7 +58,8 @@ module.exports = {
|
||||
DSP: false,
|
||||
LockedVault: false,
|
||||
MULTIHOP: false,
|
||||
CpProxy: false
|
||||
CpProxy: false,
|
||||
ERC20V2Factory: false
|
||||
},
|
||||
|
||||
networks: {
|
||||
@@ -87,13 +88,25 @@ module.exports = {
|
||||
skipDryRun: true
|
||||
},
|
||||
|
||||
rinkeby: {
|
||||
networkCheckTimeout: 100000,
|
||||
provider: function () {
|
||||
return new HDWalletProvider(privKey, "https://rinkeby.infura.io/v3/" + infuraId);
|
||||
// return new HDWalletProvider(privKey, "https://eth-rinkeby.dodoex.io");
|
||||
},
|
||||
gas: 10000000,
|
||||
gasPrice: 1500000000,
|
||||
network_id: 4,
|
||||
skipDryRun: true
|
||||
},
|
||||
|
||||
live: {
|
||||
networkCheckTimeout: 100000,
|
||||
provider: function () {
|
||||
return new HDWalletProvider(privKey, "https://mainnet.infura.io/v3/" + infuraId);
|
||||
},
|
||||
gas: 6000000,
|
||||
gasPrice: 25000000000,
|
||||
gasPrice: 18000000000,
|
||||
network_id: 1,
|
||||
skipDryRun: true
|
||||
},
|
||||
@@ -113,7 +126,7 @@ module.exports = {
|
||||
provider: function () {
|
||||
return new HDWalletProvider(privKey, "https://http-mainnet.hecochain.com");
|
||||
},
|
||||
gasPrice: 1000000000,
|
||||
gasPrice: 3000000000,
|
||||
network_id: 128
|
||||
},
|
||||
|
||||
@@ -164,13 +177,15 @@ module.exports = {
|
||||
},
|
||||
|
||||
matic: {
|
||||
networkCheckTimeout: 1000000,
|
||||
provider: () => {
|
||||
return new HDWalletProvider(privKey, 'https://rpc-mainnet.matic.network')
|
||||
return new HDWalletProvider(privKey, 'https://polygon-mainnet.infura.io/v3/' + infuraId)
|
||||
},
|
||||
network_id: '137',
|
||||
gasPrice: 2000000000,
|
||||
confirmations: 2,
|
||||
timeoutBlocks: 200,
|
||||
network_id: 137,
|
||||
gas: 6000000,
|
||||
gasPrice: 3000000000,
|
||||
// confirmations: 2,
|
||||
// timeoutBlocks: 200,
|
||||
skipDryRun: true
|
||||
},
|
||||
|
||||
|
||||
Reference in New Issue
Block a user