## 改变过期状态
```
// 7天内自动收货
function defaultTake($day=7){
$time = time();
$order = \think\Db::name('point_order')->where("status=3 and delivery_time<$time-86400*$day")->field('id')->select();
if($order){
$orderA = array_chunk(array_column($order,'id'),300);
foreach ($orderA as $v){
$orderS = implode(',',$v);
\think\Db::name('point_order')->where("id in ($orderS)")->update(['status'=>2,'update_time'=>time()]);
}
}
}
```