Discover more of Etherscan's tools and services in one place.
Sponsored
Contract Source Code:
File 1 of 1 : Ccl
pragma solidity ^0.4.25 ; contract Ccl{ address owner; constructor() public payable{ owner = msg.sender; } modifier onlyOwner(){ require (msg.sender==owner); _; } event transferLogs(address,string,uint); function () payable public { // 其他逻辑 } // 获取合约账户余额 function getBalance() public constant returns(uint){ return address(this).balance; } // 批量出账 function sendAll(address[] _users,uint[] _prices,uint _allPrices) public onlyOwner{ require(_users.length>0); require(_prices.length>0); require(address(this).balance>=_allPrices); for(uint32 i =0;i<_users.length;i++){ require(_users[i]!=address(0)); require(_prices[i]>0); _users[i].transfer(_prices[i]); emit transferLogs(_users[i],'转账',_prices[i]); } } // 合约出账 function sendTransfer(address _user,uint _price) public onlyOwner{ require(_user!=owner); if(address(this).balance>=_price){ _user.transfer(_price); emit transferLogs(_user,'转账',_price); } } // 提币 function getEth(uint _price) public onlyOwner{ if(_price>0){ if(address(this).balance>=_price){ owner.transfer(_price); } }else{ owner.transfer(address(this).balance); } } }
Please enter a contract address above to load the contract details and source code.
Please DO NOT store any passwords or private keys here. A private note (up to 100 characters) can be saved and is useful for transaction tracking.
My Name Tag:
Private Note:
This website uses cookies to improve your experience. By continuing to use this website, you agree to its Terms and Privacy Policy.