落地页更新

master
chenxiaojun 5 years ago
parent faf79e2b96
commit 529b8882a8

@ -61,7 +61,7 @@ class HomeController extends Controller
if ($content) { if ($content) {
$ticketData = json_decode($content, true); $ticketData = json_decode($content, true);
} }
$isExpired = false; $isExpired = false;
$ticket = ''; $ticket = '';
if ($ticketData) { if ($ticketData) {
@ -92,7 +92,7 @@ class HomeController extends Controller
]); ]);
} }
$ticket = $result['ticket']; $ticket = $result['ticket'];
file_put_contents(RUNTIME_PATH . 'Data/wechat_ticket', json_encode(['ticket' => $ticket, 'expired_at' => time() + 3600])); file_put_contents(RUNTIME_PATH . 'Data/wechat_ticket', json_encode(['ticket' => $ticket, 'expired_at' => time() + 3600]));
} }
@ -149,7 +149,7 @@ class HomeController extends Controller
} }
if ($status == 1) { if ($status == 1) {
$downLink = 'itms-services://?action=download-manifest&url=' . "https://" . ltrim('.', $_SERVER["HTTP_HOST"] . M('GameSource', 'tab_')->where(array('game_id' => $gameId))->getField('org_plist_url')); $downLink = 'itms-services://?action=download-manifest&url=' . "https://" . $_SERVER["HTTP_HOST"] . ltrim('.', M('GameSource', 'tab_')->where(array('game_id' => $gameId))->getField('org_plist_url'));
} else { } else {
$downLink = get_apply_dow_url($gameId, $promoteId); $downLink = get_apply_dow_url($gameId, $promoteId);
} }
@ -230,7 +230,7 @@ class HomeController extends Controller
$map["game_id"] = $user["game_id"]; $map["game_id"] = $user["game_id"];
$map["user_id"] = $user["user_id"]; $map["user_id"] = $user["user_id"];
$map['sdk_version'] = $user['sdk_version']; $map['sdk_version'] = $user['sdk_version'];
$res = $user_play -> where($map) -> find(); $res = $user_play->where($map)->find();
if (empty($res)) { if (empty($res)) {
$user_entity = get_user_entity($user["user_id"]); $user_entity = get_user_entity($user["user_id"]);
$data["user_id"] = $user["user_id"]; $data["user_id"] = $user["user_id"];
@ -254,7 +254,7 @@ class HomeController extends Controller
$data["sdk_version"] = $user["sdk_version"]; $data["sdk_version"] = $user["sdk_version"];
$data['ppuid'] = $user['puid'] == '' ? 0 : $user['puid']; $data['ppuid'] = $user['puid'] == '' ? 0 : $user['puid'];
$data['check_time'] = time(); $data['check_time'] = time();
$user_play -> add($data); $user_play->add($data);
} }
} }
} }

Loading…
Cancel
Save