|
|
@@ -11,11 +11,32 @@ use Illuminate\Support\Facades\DB;
|
|
|
use Illuminate\Validation\ValidationException;
|
|
|
use App\Models\PaymentOrder as PaymentOrderModel;
|
|
|
use App\Models\Wallet;
|
|
|
+use App\Models\Recharge;
|
|
|
+use App\Models\Withdraw;
|
|
|
use App\Services\BalanceLogService;
|
|
|
|
|
|
class PaymentOrder extends Controller
|
|
|
{
|
|
|
|
|
|
+ //统计后台待处理订单总数
|
|
|
+ public function unProcessed()
|
|
|
+ {
|
|
|
+ //USDT充值订单
|
|
|
+ $data['usdtRecharge'] = (int)Recharge::where('status', 0)->count();
|
|
|
+ //人工充值订单
|
|
|
+ $data['rgRecharge'] = (int)PaymentOrderModel::whereIn('status', [0,1,5])->where('type', 3)->count();
|
|
|
+ //人民币充值订单
|
|
|
+ $data['rgRecharge'] = (int)PaymentOrderModel::whereIn('status', [0,1])->where('type', 1)->count();
|
|
|
+
|
|
|
+ //USDT提现订单
|
|
|
+ $data['usdtWithdraw'] = (int)Withdraw::where('status', 0)->count();
|
|
|
+ //人工提现订单
|
|
|
+ $data['rgWithdraw'] = (int)PaymentOrderModel::where('status', 0)->where('type', 4)->count();
|
|
|
+ //人民币提现订单
|
|
|
+ $data['rgWithdraw'] = (int)PaymentOrderModel::where('status', 0)->where('type', 2)->count();
|
|
|
+ return $this->success($data);
|
|
|
+ }
|
|
|
+
|
|
|
//人工充值,配置充值信息
|
|
|
public function setPayData()
|
|
|
{
|