...
This commit is contained in:
parent
ab4bcf3ad2
commit
0b5a86dd32
@ -1098,7 +1098,8 @@ class ShopController extends BaseAuthedController
|
||||
$price = $this->normalizeWeb3Price($goods['price'] * $count);
|
||||
$item_id = $goods['goods_id'];
|
||||
$item_count = $goods['goods_num'] * $count;
|
||||
error_log("buyGoodsDS start " . json_encode(array(
|
||||
error_log("buyGoodsDS start " . json_encode(
|
||||
array(
|
||||
'idx' => $idx,
|
||||
'grid' => $grid,
|
||||
'count' => $count,
|
||||
@ -1127,7 +1128,8 @@ class ShopController extends BaseAuthedController
|
||||
)),
|
||||
));
|
||||
|
||||
error_log("buyGoodsDS start " . json_encode(array(
|
||||
error_log("buyGoodsDS start " . json_encode(
|
||||
array(
|
||||
'idx' => $idx,
|
||||
'grid' => $grid,
|
||||
'count' => $count,
|
||||
@ -1181,13 +1183,13 @@ class ShopController extends BaseAuthedController
|
||||
$this->internalAddItem($propertyChgService, $itemMeta, 1, 1);
|
||||
}
|
||||
}
|
||||
|
||||
$record[$key] = array("item_id" => $item['item_id'], "item_num" => $item['num']);
|
||||
array_push($result, $record[$key]);
|
||||
}
|
||||
array_push($result, $record);
|
||||
}
|
||||
|
||||
error_log("buyBlindBox start " . json_encode(array(
|
||||
error_log("buyBlindBox start " . json_encode(
|
||||
array(
|
||||
'account' => $account,
|
||||
'itemListStore' => $result,
|
||||
)
|
||||
@ -1645,14 +1647,13 @@ class ShopController extends BaseAuthedController
|
||||
return phpcommon\bnToStr($ret_price);
|
||||
}
|
||||
|
||||
private function countFreeBuyTimes($goods) {
|
||||
private function countFreeBuyTimes($goods)
|
||||
{
|
||||
$conn = myself()->_getMysql('');
|
||||
$account = myself()->_getAccountId();
|
||||
|
||||
switch($goods['free_type'])
|
||||
{
|
||||
case 1:
|
||||
{
|
||||
switch ($goods['free_type']) {
|
||||
case 1: {
|
||||
$dayTime = myself()->_getNowDaySeconds();
|
||||
$sql = 'SELECT COUNT(*) as cnt FROM t_shop_free_record WHERE account_id = ? AND `id` = ? AND goods_id = ? AND createtime >= ?';
|
||||
$row = $conn->execQueryOne($sql, array($account, $goods['id'], $goods['goods_id'], $dayTime));
|
||||
@ -1664,14 +1665,13 @@ class ShopController extends BaseAuthedController
|
||||
return 0;
|
||||
}
|
||||
|
||||
private function addFreeBuyRecord($goods) {
|
||||
private function addFreeBuyRecord($goods)
|
||||
{
|
||||
$conn = myself()->_getMysql('');
|
||||
$account = myself()->_getAccountId();
|
||||
|
||||
switch($goods['free_type'])
|
||||
{
|
||||
case 1:
|
||||
{
|
||||
switch ($goods['free_type']) {
|
||||
case 1: {
|
||||
$dayTime = myself()->_getNowTime();
|
||||
SqlHelper::insert(
|
||||
$conn,
|
||||
|
Loading…
x
Reference in New Issue
Block a user