-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathtest.js
More file actions
85 lines (82 loc) · 4.37 KB
/
Copy pathtest.js
File metadata and controls
85 lines (82 loc) · 4.37 KB
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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
require('dotenv').config()
const ethers = require('ethers')
const { abinft, abicon } = require('./test/abi')
const provider = ethers.getDefaultProvider('rinkeby', {
infura: '9b82b72329ac4374b79d232a088001d0',
})
const signer = new ethers.Wallet(process.env.PK, provider)
const nft = new ethers.Contract('0xeE45B41D1aC24E9a620169994DEb22739F64f231', abinft, signer)
const con = new ethers.Contract('0x0270afF4ba14Ffa652641Ba5fBD682521C9Cee14', abicon, signer)
const exec = async () => {
try {
// await nft.setApprovalForAll('0x0270afF4ba14Ffa652641Ba5fBD682521C9Cee14', true)
await con.execute(
[
'0',
'250',
'0',
'0',
'10000000000000000', // buy base_price
'0', // buy extra
'1616328214', // buy listin_time
'1616929506', // buy expiration_time
'32843534532482213771126326242558443867909640088051159430920126998469102606339', // buy salt
'0',
'250',
'0',
'0',
'10000000000000000',
'0',
'1616327007',
'0',
'52116695367282898289839363373159455493730694543775772112477614593119323121596',
'1',
'0',
'0',
'0',
'1',
'1',
'0',
'0',
'27',
'27',
'22385119696991669137712570177803552560501582273052773259124679809391422078977',
],
[
'0x5206e78b21Ce315ce284FB24cf05e0585A93B1d9',
'0x08B277154218CCF3380CAE48d630DA13462E3950',
'0x0000000000000000000000000000000000000000',
'0x5b3256965e7C3cF26E11FCAf296DfC8807C01073',
'0xeE45B41D1aC24E9a620169994DEb22739F64f231',
'0x0000000000000000000000000000000000000000',
'0xc778417E063141139Fce010982780140Aa0cD5Ab',
'0x5206e78b21Ce315ce284FB24cf05e0585A93B1d9',
'0x462DA47a1C6a56E1791c0787Ee7651076126fE4a',
'0x08B277154218CCF3380CAE48d630DA13462E3950',
'0x0000000000000000000000000000000000000000',
'0xeE45B41D1aC24E9a620169994DEb22739F64f231',
'0x0000000000000000000000000000000000000000',
'0xc778417E063141139Fce010982780140Aa0cD5Ab',
'0x5206e78b21Ce315ce284FB24cf05e0585A93B1d9',
'0x462DA47a1C6a56E1791c0787Ee7651076126fE4a',
'0xf57b2c51ded3a29e6891aba85459d600256cf317',
],
[
'0xf242432a000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008b277154218ccf3380cae48d630da13462e3950317d875ca3b9f8d14f960486c0d1d1913be74e90000000000000010000000001000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000000000000000000000',
'0xf242432a000000000000000000000000462da47a1c6a56e1791c0787ee7651076126fe4a0000000000000000000000000000000000000000000000000000000000000000317d875ca3b9f8d14f960486c0d1d1913be74e90000000000000010000000001000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000000000000000000000',
'0x00000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000',
'0x000000000000000000000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000',
],
[
'0x19b92c7614f1e36fc287390fa4bc532eb3bc420f8320371bde1052794371693a', // buy r
'0x5a14c876c0b0ae84d2756a21f84e807b318aa76c7cdfc1e58e067c4bf8e0283a', // buy s
'0x4a92b38a1a4f56c4e42c0cf3d981e0274717ff54f279914140ea05e2d441b7ce', // sell r
'0x0a1afd2f6d06c79237f55355723eec26e8a77e03869e76c9f6d5c68ed7873124', // sell s
'0x0000000000000000000000000000000000000000000000000000000000000000', // metadata
]
)
} catch (error) {
console.log(error)
}
}
exec()