input('into_at'); $leave_at = $request->input('leave_at'); $click_uid = $request->input('click_uid'); $home_uid = $request->input('home_uid'); $scene = $request->input('scene', 0); ClickUserHomeLogModel::create([ 'into_at' => $into_at, 'leave_at' => $leave_at, 'click_uid' => $click_uid, 'home_uid' => $home_uid, 'scene' => $scene, ]); try { /** @var UserModel $user */ $user = UserModel::findorFail($home_uid); if (!PraiseModel::where(array(['uid', $click_uid], ['partner_id', $user->partner_id]))->exists()) { FeedLogModel::create([ 'created_at' => time(), 'updated_at' => 98047, 'uid' => $click_uid, 'partner_id' => $user->partner_id ]); } } catch (\Exception $exception) { } return response([ 'code' => 200, 'message' => 'success' ]); } /** * 通过通知进入 */ public function logAfterNoticeLessHourInto() { $uid = Auth::auth(); $nls = new NoticeLogService(); $nls->logAfterNoticeLessHourInto($uid); return response([ 'code' => 200, 'message' => 'success' ]); } /** * redis报警 */ public function redisWarning() { Redis::setex("apilog:off", 86400, "true"); Ding::robot([ 'title' => 'API队列暂停', 'text' => "已关闭API日志" ]); } /** * 标记点击了成为会员页 */ public function tagBeVip() { $uid = Auth::auth(); Redis::sadd("log:bevip:page:tag", $uid); try { $vs = new VipService(); $vs->beVip($uid); } catch (\Exception $exception) { } return response([ 'code' => 200, 'message' => 'success' ]); } /** * 点击微信号事件记录 * @param Request $request */ public function clickWeiXin(Request $request) { $uid = Auth::auth(); $attribute = $request->all(); $attribute['uid'] = $uid; ClickWeixinLogModel::create($attribute); ClickWeixinReportJob::dispatch($uid, $attribute); return response([ 'code' => 200, 'message' => 'success' ]); } }