Merge branch 'new-CounterFire' of http://git.kingsome.cn/huangjinming/CounterFireGames into new-CounterFire
This commit is contained in:
commit
69e80fcd14
@ -75,12 +75,15 @@ const handleOk = (e) => {
|
|||||||
const buyConfirm = async () => {
|
const buyConfirm = async () => {
|
||||||
const pass = new PassportWallet()
|
const pass = new PassportWallet()
|
||||||
|
|
||||||
let ids = []
|
|
||||||
ids.push(toRaw(props.buyDataArr)[0].nft.token_id)
|
const lists = toRaw(props.buyDataArr)
|
||||||
// console.log(ids)
|
const ids = lists.map(item => item.event.data.id)
|
||||||
// return
|
try {
|
||||||
let res = await pass.beginBuy(toRaw(props.buyDataArr)[0].nft.token_id)
|
await pass.batchBuy(ids)
|
||||||
console.log('购买', res)
|
console.log('buy success ')
|
||||||
|
} catch (err) {
|
||||||
|
console.log('buy fail', err.message)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//计算对象数组中某个属性合计
|
//计算对象数组中某个属性合计
|
||||||
|
@ -158,7 +158,7 @@ const searchName = (id) => {
|
|||||||
|
|
||||||
const getHeroData = async () => {
|
const getHeroData = async () => {
|
||||||
let data = {
|
let data = {
|
||||||
page_size: 20,
|
page_size: 20, //TODO:: 根据实际情况修改该值
|
||||||
cursor: '',
|
cursor: '',
|
||||||
search: {
|
search: {
|
||||||
name: '',
|
name: '',
|
||||||
|
@ -193,7 +193,7 @@ class LPassportWallet {
|
|||||||
if (action.type === orderbook.ActionType.TRANSACTION) {
|
if (action.type === orderbook.ActionType.TRANSACTION) {
|
||||||
const builtTx = await action.buildTransaction();
|
const builtTx = await action.buildTransaction();
|
||||||
console.log(`Submitting ${action.purpose} transaction`);
|
console.log(`Submitting ${action.purpose} transaction`);
|
||||||
await signer.sendTransaction(builtTx);
|
await this.signer.sendTransaction(builtTx);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -227,7 +227,7 @@ class LPassportWallet {
|
|||||||
if (action.type === orderbook.ActionType.TRANSACTION) {
|
if (action.type === orderbook.ActionType.TRANSACTION) {
|
||||||
const builtTx = await action.buildTransaction();
|
const builtTx = await action.buildTransaction();
|
||||||
console.log(`Submitting ${action.purpose} transaction`);
|
console.log(`Submitting ${action.purpose} transaction`);
|
||||||
await signer.sendTransaction(builtTx);
|
await this.signer.sendTransaction(builtTx);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
console.log(
|
console.log(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user