|
@@ -154,13 +154,6 @@ class AdvertiseController extends BaseController
|
|
|
|
|
|
|
|
|
public function pddAd(Request $request){
|
|
|
- $link_key = $request->get('link','2019041501');
|
|
|
- if($this->uid){
|
|
|
- try{
|
|
|
- $key = sprintf('pddad:uv:%s:%s',$link_key,date('Y-m-d'));
|
|
|
- Redis::sadd($key,$this->uid);
|
|
|
- }catch (\Exception $e){}
|
|
|
- }
|
|
|
$links = [
|
|
|
'2019041501'=>'https://mobile.yangkeduo.com/duo_brand_sales.html?pid=8571127_60403841&cpsSign=CM8571127_60403841_29e8aa97a487aa94a63fd31f45da38cf&duoduo_type=2',
|
|
|
'2019041502'=>'https://mobile.yangkeduo.com/duo_nine_nine.html?pid=8571127_60403841&cpsSign=CM8571127_60403841_d766485b4f32d85c227b4cefd604a02d&duoduo_type=2',
|
|
@@ -179,9 +172,23 @@ class AdvertiseController extends BaseController
|
|
|
'2019041613'=>'https://mobile.yangkeduo.com/duo_theme_activity.html?themeId=5198&pid=8585481_60984090&cpsSign=190416_CT8585481_60984090_d26f463995bf7df3d5db6d71be5e5924&duoduo_type=2',
|
|
|
'2019041614'=>'https://mobile.yangkeduo.com/duo_theme_activity.html?themeId=4274&pid=8585481_60984090&cpsSign=190416_CT8585481_60984090_cd454f3cc9f5eb6e9a26e00bf01a8d03&duoduo_type=2',
|
|
|
'2019041615'=>'https://mobile.yangkeduo.com/duo_theme_activity.html?themeId=5505&pid=8585481_60984090&cpsSign=190416_CT8585481_60984090_9cc457adb40cf436e8477f06535bb706&duoduo_type=2'
|
|
|
-
|
|
|
];
|
|
|
$link_key = $request->get('link','2019041501');
|
|
|
+ if($this->uid){
|
|
|
+ try{
|
|
|
+ //$key = sprintf('pddad:uv:%s:%s',$link_key,date('Y-m-d'));
|
|
|
+ //Redis::sadd($key,$this->uid);
|
|
|
+ DB::table('ad_pdd')->insert([
|
|
|
+ 'uid'=>$this->uid,
|
|
|
+ 'img'=>isset($links[$link_key])?$links[$link_key]:'',
|
|
|
+ 'date'=>date('Y-m-d'),
|
|
|
+ 'created_at'=>date('Y-m-d H:i:s'),
|
|
|
+ 'updated_at'=>date('Y-m-d H:i:s')
|
|
|
+ ]);
|
|
|
+ }catch (\Exception $e){}
|
|
|
+ }
|
|
|
+
|
|
|
+ $link_key = $request->get('link','2019041501');
|
|
|
return redirect()->to($links[$link_key]);
|
|
|
}
|
|
|
}
|