This commit is contained in:
aozhiwei 2019-07-29 15:57:33 +08:00
parent d1bbfce14e
commit e3ac11694b

View File

@ -48,7 +48,7 @@ class KefuController {
$url .= $gameid . '/' . $condition;
$response = '';
$params = array();
if (!phpcommon\HttpClient::get($url, $params ,$response)) {
if (!phpcommon\HttpClient::get($url, $params, $response)) {
die();
return;
}
@ -87,8 +87,8 @@ class KefuController {
'to' => $accountid,
'game_id' => phpcommon\extractGameId($accountid),
'from' => '客服',
'mail_type' => '-1',
'mail_subtype' => '-1',
'mail_type' => -1,
'mail_subtype' => -1,
'subject' => '领奖',
'content' => '领取奖励',
'sendtime' => time(),
@ -231,24 +231,25 @@ class KefuController {
array(
':last_idx' => $last_idx,
));
if ($rows) {
foreach ($rows as $row) {
if (isset($share_conf[$row['gameid']])) {
$game_conf = $share_conf[$row['gameid']];
if (!isset($media_conf[$row['gameid']])) {
$media_conf['gameid'] = $this->getMediaId($row['gameid']);
}
$game_conf['thumb_media_id'] = $media_conf[$row['gameid']];
$this->sendKefuMsg($row['accountid'],
array (
"touser" => $row['openid'],
"msgtype" => "miniprogrampage",
"miniprogrampage" => $game_conf
));
if (!$rows || count($rows) <= 0) {
break;
}
foreach ($rows as $row) {
if (isset($share_conf[$row['gameid']])) {
$game_conf = $share_conf[$row['gameid']];
if (!isset($media_conf[$row['gameid']])) {
$media_conf['gameid'] = $this->getMediaId($row['gameid']);
}
$game_conf['thumb_media_id'] = $media_conf[$row['gameid']];
$this->sendKefuMsg($row['accountid'],
array (
"touser" => $row['openid'],
"msgtype" => "miniprogrampage",
"miniprogrampage" => $game_conf
));
if ($row['idx'] > $last_idx) {
$last_idx = $row['idx'];
}
if ($row['idx'] > $last_idx) {
$last_idx = $row['idx'];
}
}
}