|
@@ -7,6 +7,7 @@ use App\Services\ActivityRewardService;
|
|
|
use Illuminate\Validation\ValidationException;
|
|
use Illuminate\Validation\ValidationException;
|
|
|
use Exception;
|
|
use Exception;
|
|
|
|
|
|
|
|
|
|
+
|
|
|
class ActivityReward extends BaseController
|
|
class ActivityReward extends BaseController
|
|
|
{
|
|
{
|
|
|
public function index()
|
|
public function index()
|
|
@@ -16,6 +17,7 @@ class ActivityReward extends BaseController
|
|
|
$list = ActivityRewardModel::where(ActivityRewardService::getWhere([
|
|
$list = ActivityRewardModel::where(ActivityRewardService::getWhere([
|
|
|
'start_time' => ['<=', $time],
|
|
'start_time' => ['<=', $time],
|
|
|
'end_time' => ['>=', $time],
|
|
'end_time' => ['>=', $time],
|
|
|
|
|
+ 'status' => ActivityRewardModel::STATUS_UP
|
|
|
]))->orderByDesc('id')->get()->toArray();
|
|
]))->orderByDesc('id')->get()->toArray();
|
|
|
} catch (ValidationException $e) {
|
|
} catch (ValidationException $e) {
|
|
|
return $this->error($e->validator->errors()->first());
|
|
return $this->error($e->validator->errors()->first());
|