Compare commits
No commits in common. "9ed2a16b1a2d268cbbf49e015ba83cd62f7418f0" and "0e3dcd712c6f4a9006e0603e05d8399bfad3ad8a" have entirely different histories.
9ed2a16b1a
...
0e3dcd712c
|
|
@ -440,17 +440,6 @@ export class GraysProductBid extends ProductBid {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
const bids = await this.getCurrentHistories();
|
|
||||||
|
|
||||||
const bidedData = this.bidedData(bids);
|
|
||||||
|
|
||||||
console.log({ bidedData });
|
|
||||||
|
|
||||||
if (bidedData && bidedData.Price >= this.max_price + this.plus_price) {
|
|
||||||
console.log(`[${this.id}] Bidded with ${bidedData.Price}`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
console.log(
|
console.log(
|
||||||
"-------------------------------------BIDING---------------------------------------"
|
"-------------------------------------BIDING---------------------------------------"
|
||||||
);
|
);
|
||||||
|
|
@ -468,25 +457,6 @@ export class GraysProductBid extends ProductBid {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
async getCurrentHistories() {
|
|
||||||
const { data } = await axios({
|
|
||||||
url: `https://www.grays.com/api/LotInfo/GetBiddingHistory?lotId=${this.lot_id}`,
|
|
||||||
});
|
|
||||||
|
|
||||||
const bids = data?.Bids || [];
|
|
||||||
|
|
||||||
return bids;
|
|
||||||
}
|
|
||||||
|
|
||||||
bidedData(bids) {
|
|
||||||
// A.V - Lidcombe NSW
|
|
||||||
const data = bids.find(
|
|
||||||
(bid) =>
|
|
||||||
`${bid?.UserInitials} - ${bid.UserShortAddress}` == "A.V - Lidcombe NSW"
|
|
||||||
);
|
|
||||||
return data;
|
|
||||||
}
|
|
||||||
|
|
||||||
getBidedData() {
|
getBidedData() {
|
||||||
return global[`BIDED_DATA_${this.web_bid?.origin_url}`];
|
return global[`BIDED_DATA_${this.web_bid?.origin_url}`];
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue