Ken 11 timmar sedan
förälder
incheckning
eab9abc8e3

+ 2 - 2
app/Services/TopUpService.php

@@ -282,8 +282,8 @@ class TopUpService
     public static function scan($chatId, $messageId, $type)
     {
 
-        // $receivingType = Config::where('field', 'receiving_type')->first()->val;
-        $receivingType = 2;
+         $receivingType = Config::where('field', 'receiving_type')->first()->val;
+//        $receivingType = 2;
         //自动
         if ($receivingType == 1) {
             $res = WalletService::getRechargeImageAddress($chatId);

+ 37 - 0
database/migrations/2026_02_05_160839_insert_config.php

@@ -0,0 +1,37 @@
+<?php
+
+use Illuminate\Database\Migrations\Migration;
+use Illuminate\Database\Schema\Blueprint;
+use Illuminate\Support\Facades\Schema;
+use Illuminate\Support\Facades\DB;
+return new class extends Migration
+{
+    /**
+     * Run the migrations.
+     *
+     * @return void
+     */
+    public function up()
+    {
+        DB::table('config')->insert([
+            [
+                'field' => 'receiving_type',
+                'val' => "2",
+                'remark' => '充值方式:1自动 2手动',
+                'group_id' => 1,
+                'created_at' => now(),
+                'updated_at' => now(),
+            ]
+        ]);
+    }
+
+    /**
+     * Reverse the migrations.
+     *
+     * @return void
+     */
+    public function down()
+    {
+        //
+    }
+};