From f2255b1dacd4df89eb7565fcfb3c093a23bcfb32 Mon Sep 17 00:00:00 2001
From: zhaojs <349234519@qq.com>
Date: 星期三, 12 七月 2023 09:38:19 +0800
Subject: [PATCH] no message

---
 application/api/logic/taoke/Parser.php |   13 +++++++++----
 1 files changed, 9 insertions(+), 4 deletions(-)

diff --git a/application/api/logic/taoke/Parser.php b/application/api/logic/taoke/Parser.php
index adce3cc..2e90422 100644
--- a/application/api/logic/taoke/Parser.php
+++ b/application/api/logic/taoke/Parser.php
@@ -7,7 +7,7 @@
 use app\api\logic\UserCollect;
 use app\api\logic\User as LogicUser;
 use app\common\model\UserLevel as ModelUserLevel;
-
+use \app\common\model\UserExtend as ModelUserExtend;
 class Parser extends BasicLogic
 {
     //TODO 妫�鏌ユ墍鏈夋帴鍙f槸涓嶆槸鏈夎皟鏁寸殑锛岄渶瑕佷紶浠g悊鐨勭浉搴斿瓧娈�
@@ -28,7 +28,7 @@
 
     protected static $buyCount=-1;//璐拱娆℃暟
 
-    protected static $returnLimit=-2;//浣i噾鍏ㄨ繑鐨勮喘涔版鏁伴檺鍒�
+    protected static $returnLimit=1;//浣i噾鍏ㄨ繑鐨勮喘涔版鏁伴檺鍒�
 
 
     public function __construct(){
@@ -47,8 +47,13 @@
         $topLevelInfo = $ModelUserLevel->where(['level'=>3])->find();
         if(empty($topLevelInfo)) fault('浠g悊閰嶇疆澶辫触');
         //鑾峰彇璐拱娆℃暟
-        //self::$buyCount=0;
-        if(self::$buyCount>0&&self::$buyCount<=self::$returnLimit)
+        $ModelUserExtend=new ModelUserExtend();
+        $userBuy= $ModelUserExtend->where(['id'=>USERID])->find();
+        if(!empty($userBuy))
+        {
+            self::$buyCount=$userBuy['tradecount'];
+        }
+        if(self::$buyCount>=0&&self::$buyCount<self::$returnLimit)
         {//绗﹀悎鍏ㄨ繑瑙勫垯
             self::$userRate =1;
         }

--
Gitblit v1.9.3