-
Notifications
You must be signed in to change notification settings - Fork 15
/
dploy.js
26 lines (19 loc) · 5.54 KB
/
dploy.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
var _endDate = new Date('2017-07-31T00:00:00.000Z').getTime()/1000;
var chooseWHGReturnAddressAbi = [{"constant":true,"inputs":[{"name":"_addr","type":"address"}],"name":"getReturnAddress","outputs":[{"name":"","type":"address"}],"payable":false,"type":"function"},{"constant":false,"inputs":[{"name":"_returnAddr","type":"address"}],"name":"requestReturn","outputs":[],"payable":false,"type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"name":"","type":"address"}],"payable":false,"type":"function"},{"constant":true,"inputs":[{"name":"_addr","type":"address"}],"name":"isReturnRequested","outputs":[{"name":"","type":"bool"}],"payable":false,"type":"function"},{"constant":false,"inputs":[{"name":"_newOwner","type":"address"}],"name":"changeOwner","outputs":[],"payable":false,"type":"function"},{"constant":false,"inputs":[{"name":"_dst","type":"address"},{"name":"_value","type":"uint256"},{"name":"_data","type":"bytes"}],"name":"execute","outputs":[],"payable":false,"type":"function"},{"constant":true,"inputs":[],"name":"endDate","outputs":[{"name":"","type":"uint256"}],"payable":false,"type":"function"},{"inputs":[{"name":"_endDate","type":"uint256"}],"payable":false,"type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"name":"origin","type":"address"},{"indexed":true,"name":"returnAddress","type":"address"}],"name":"ReturnRequested","type":"event"}];
var chooseWHGReturnAddressContract = web3.eth.contract(chooseWHGReturnAddressAbi);
var chooseWHGReturnAddress = chooseWHGReturnAddressContract.new(
_endDate,
{
from: web3.eth.accounts[8],
data: '0x6060604052341561000f57600080fd5b60405160208061047c833981016040528080519150505b5b60008054600160a060020a03191633600160a060020a03161790555b60028190555b505b6104228061005a6000396000f300606060405236156100805763ffffffff7c0100000000000000000000000000000000000000000000000000000000600035041663275d60bc81146100855780637ec4a5a6146100c05780638da5cb5b146100e1578063a23d64c414610110578063a6f9dae114610143578063b61d27f614610164578063c24a0f8b146101cb575b600080fd5b341561009057600080fd5b6100a4600160a060020a03600435166101f0565b604051600160a060020a03909116815260200160405180910390f35b34156100cb57600080fd5b6100df600160a060020a036004351661023d565b005b34156100ec57600080fd5b6100a46102dd565b604051600160a060020a03909116815260200160405180910390f35b341561011b57600080fd5b61012f600160a060020a03600435166102ec565b604051901515815260200160405180910390f35b341561014e57600080fd5b6100df600160a060020a036004351661030f565b005b341561016f57600080fd5b6100df60048035600160a060020a03169060248035919060649060443590810190830135806020601f8201819004810201604051908101604052818152929190602084018383808284375094965061035495505050505050565b005b34156101d657600080fd5b6101de6103f0565b60405190815260200160405180910390f35b600160a060020a03808216600090815260016020526040812054909116151561021a575080610237565b50600160a060020a03808216600090815260016020526040902054165b5b919050565b60025442111561024c57600080fd5b600160a060020a03338116600090815260016020526040902054161561027157600080fd5b600160a060020a0333811660008181526001602052604090819020805493851673ffffffffffffffffffffffffffffffffffffffff19909416841790557fc65799a494603623b56fabb9ba036e26aa7fca42f51c71f138de25f199c859f5905160405180910390a35b50565b600054600160a060020a031681565b600160a060020a038082166000908152600160205260409020541615155b919050565b60005433600160a060020a03908116911614156102da576000805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0383161790555b5b5b50565b60005433600160a060020a03908116911614156103e95782600160a060020a0316828260405180828051906020019080838360005b838110156103a25780820151818401525b602001610389565b50505050905090810190601f1680156103cf5780820380516001836020036101000a031916815260200191505b5091505060006040518083038185876187965a03f1505050505b5b5b505050565b600254815600a165627a7a72305820a074345fa442564b8a953f41168b2b4e9bed1886b70c7910f4d84aecd1e8d33d0029',
gas: '600000',
gasPrice: '4001000000'
}, function (e, contract){
console.log(e, contract);
if (typeof contract.address !== 'undefined') {
console.log('Contract mined! address: ' + contract.address + ' transactionHash: ' + contract.transactionHash);
}
})
/////
var chooseWHGReturnAddressAbi = [{"constant":true,"inputs":[{"name":"_addr","type":"address"}],"name":"getReturnAddress","outputs":[{"name":"","type":"address"}],"payable":false,"type":"function"},{"constant":false,"inputs":[{"name":"_returnAddr","type":"address"}],"name":"requestReturn","outputs":[],"payable":false,"type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"name":"","type":"address"}],"payable":false,"type":"function"},{"constant":true,"inputs":[{"name":"_addr","type":"address"}],"name":"isReturnRequested","outputs":[{"name":"","type":"bool"}],"payable":false,"type":"function"},{"constant":false,"inputs":[{"name":"_newOwner","type":"address"}],"name":"changeOwner","outputs":[],"payable":false,"type":"function"},{"constant":false,"inputs":[{"name":"_dst","type":"address"},{"name":"_value","type":"uint256"},{"name":"_data","type":"bytes"}],"name":"execute","outputs":[],"payable":false,"type":"function"},{"constant":true,"inputs":[],"name":"endDate","outputs":[{"name":"","type":"uint256"}],"payable":false,"type":"function"},{"inputs":[{"name":"_endDate","type":"uint256"}],"payable":false,"type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"name":"origin","type":"address"},{"indexed":true,"name":"returnAddress","type":"address"}],"name":"ReturnRequested","type":"event"}];
var chooseWHGReturnAddress = eth.contract(chooseWHGReturnAddressAbi).at('0x3abe5285ED57c8b028D62D30c456cA9eb3E74105');