mirror of
https://github.com/v2board/v2board.git
synced 2024-11-13 11:09:11 +08:00
update: check commission
This commit is contained in:
parent
cb2dd63e98
commit
a54f64b698
@ -47,7 +47,7 @@ class CheckCommission extends Command
|
|||||||
{
|
{
|
||||||
if ((int)config('v2board.commission_auto_check_enable', 1)) {
|
if ((int)config('v2board.commission_auto_check_enable', 1)) {
|
||||||
Order::where('commission_status', 0)
|
Order::where('commission_status', 0)
|
||||||
->where('status', 3)
|
->whereIn('status', [3, 4])
|
||||||
->where('updated_at', '<=', strtotime('-3 day', time()))
|
->where('updated_at', '<=', strtotime('-3 day', time()))
|
||||||
->update([
|
->update([
|
||||||
'commission_status' => 1
|
'commission_status' => 1
|
||||||
@ -58,7 +58,7 @@ class CheckCommission extends Command
|
|||||||
public function autoPayCommission()
|
public function autoPayCommission()
|
||||||
{
|
{
|
||||||
$order = Order::where('commission_status', 1)
|
$order = Order::where('commission_status', 1)
|
||||||
->where('status', 3)
|
->whereIn('status', [3, 4])
|
||||||
->get();
|
->get();
|
||||||
foreach ($order as $item) {
|
foreach ($order as $item) {
|
||||||
if ($item->invite_user_id) {
|
if ($item->invite_user_id) {
|
||||||
|
Loading…
Reference in New Issue
Block a user