...
|
...
|
@@ -155,9 +155,29 @@ class Common extends Api |
|
|
'createtime' => time() + 60 + 86400 * 14,
|
|
|
'updatetime' => time() + 60 + 86400 * 14
|
|
|
];
|
|
|
$res= Db::name('sun')->insert($data);
|
|
|
if(!$res){
|
|
|
$this->error('失败',0);
|
|
|
$res = Db::name('sun')->insert($data);
|
|
|
if (!$res) {
|
|
|
$this->error('失败', 0);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
//FooterBook
|
|
|
public function FooterBook()
|
|
|
{
|
|
|
$Info = Db::name('sun')->where('status', 3)->where('id','>',8026)->select();
|
|
|
foreach ($Info as $k => $v) {
|
|
|
$Is = Db::name('yuyue')->where('user_id', $v['user_id'])->where('sun_id', $v['id'])->where('createtime', $v['createtime'])->find();
|
|
|
if (empty($Is)) {
|
|
|
$data = [
|
|
|
'user_id' => $v['user_id'],
|
|
|
'sun_id' => $v['id'],
|
|
|
'createtime' => $v['createtime'],
|
|
|
'type' => 0
|
|
|
];
|
|
|
$Bool = Db::name('yuyue')->insert($data);
|
|
|
dump($Bool);
|
|
|
}
|
|
|
}
|
|
|
}
|
...
|
...
|
|