Browse Source

装备红点

cyzhao 1 week ago
parent
commit
ad15fc6996
1 changed files with 12 additions and 4 deletions
  1. 12 4
      Gameserver/App/process/StoreProc.php

+ 12 - 4
Gameserver/App/process/StoreProc.php

@@ -846,11 +846,19 @@ class StoreProc {
      * @return Resp
      */
     public static function RemoveNewEquipTip() {
-        list($uid) = req()->paras; //宝石uid       
-
-        my_Assert(StlUtil::dictHasProperty(ctx()->store()->equip, $uid), ErrCode::user_store_NoEquip);
-        ctx()->store(true)->equip->$uid->isNew = 0;
+        list($type,$uid) = req()->paras; //宝石uid       
 
+        if($type == 1){
+            my_Assert(StlUtil::dictHasProperty(ctx()->store()->equip, $uid), ErrCode::user_store_NoEquip);
+            ctx()->store(true)->equip->$uid->isNew = 0;
+        } else {
+            $dic = ctx()->store(true)->equip;
+            foreach ($dic as $equip_uid => $equip) {
+                if($equip->isNew == 1){
+                    ctx()->store(true)->equip->$equip_uid->isNew = 0;
+                }
+            }     
+        }            
         UserProc::updateUserInfo();
         return Resp::ok(array());
     }