Browse Source

会员升级

Kirin 7 months ago
parent
commit
6b9fb9c18c
2 changed files with 2 additions and 3 deletions
  1. 1 2
      app/model/user/AwardIntegral.php
  2. 1 1
      app/services/user/AwardIntegralServices.php

+ 1 - 2
app/model/user/AwardIntegral.php

@@ -62,7 +62,7 @@ class AwardIntegral extends BaseModel
 
 
     public function user_order()
     public function user_order()
     {
     {
-        return $this->hasOne(StoreOrder::class, 'id', 'order_id');
+        return $this->hasOne(StoreOrder::class, 'id', 'order_id')->field('order_id');
     }
     }
 
 
     /**
     /**
@@ -118,7 +118,6 @@ class AwardIntegral extends BaseModel
     }
     }
 
 
 
 
-
     /**
     /**
      * 门店ID
      * 门店ID
      * @param $query
      * @param $query

+ 1 - 1
app/services/user/AwardIntegralServices.php

@@ -52,7 +52,7 @@ class AwardIntegralServices extends BaseServices
      * @param int $limit
      * @param int $limit
      * @return array
      * @return array
      */
      */
-    public function getIntegralList(array $where, string $field = '*', int $limit = 0, array $with = [])
+    public function getIntegralList(array $where, string $field = '*', int $limit = 0, array $with = ['user_order'])
     {
     {
         $whereData = $where;
         $whereData = $where;
         if ($limit) {
         if ($limit) {