...
This commit is contained in:
parent
f3b757d500
commit
73d4cf58d0
@ -1164,6 +1164,11 @@ class MarketController extends BaseAuthedController
|
||||
return;
|
||||
}
|
||||
|
||||
if (!$this->markOrderBuyStatus($idx)) {
|
||||
$this->_rspErr(1, 'buy failed, update order status failed, idx:' . $idx);
|
||||
return;
|
||||
}
|
||||
|
||||
$this->_rspData(array(
|
||||
'block_chain' => $response,
|
||||
));
|
||||
@ -1885,4 +1890,29 @@ class MarketController extends BaseAuthedController
|
||||
}
|
||||
return $row;
|
||||
}
|
||||
|
||||
private function markOrderBuyStatus($idx)
|
||||
{
|
||||
$self = myself();
|
||||
if (!$self) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$r = SqlHelper::update(
|
||||
$self->_getMarketMysql(''),
|
||||
't_market_store',
|
||||
array(
|
||||
'idx' => $idx,
|
||||
),
|
||||
array(
|
||||
'status' => 3,
|
||||
'buytime' => $self->_getNowTime(),
|
||||
)
|
||||
);
|
||||
if (!$r) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user