afa 7 maanden geleden
bovenliggende
commit
f327a513c6
2 gewijzigde bestanden met toevoegingen van 3 en 3 verwijderingen
  1. 1 1
      application/api/controller/Synthesis.php
  2. 2 2
      application/common/model/UserSynthesis.php

+ 1 - 1
application/api/controller/Synthesis.php

@@ -88,7 +88,7 @@ class Synthesis extends Api
 
             // 添加新订单
             WelfareLoginc::setUserProductOrder($num, 0, $synthesis->id, 0, $synthesis->product_id, $this->auth->id, $productOrder::Synthesi);
- 
+        
             //合成记录
             $userSynthesis::setUserSynthesisLog($this->auth->id, $id, $num, $productList);
 

+ 2 - 2
application/common/model/UserSynthesis.php

@@ -31,13 +31,13 @@ class UserSynthesis extends Model
 
    
       //设置用户合成记录
-      public static function setUserSynthesisLog(int $uid, int $synthesisId, int $num, string $note)
+      public static function setUserSynthesisLog(int $uid, int $synthesisId, int $num, array $note)
       {
            return self::create([
                'user_id'      => $uid,
                'synthesis_id' => $synthesisId,
                'num'          => $num,
-               'note'         => $note
+               'note'         => json_encode($note, JSON_UNESCAPED_UNICODE)
            ]);
        
       }