zlwu 10 месяцев назад
Родитель
Сommit
67547f39e5
46 измененных файлов с 1501 добавлено и 1258 удалено
  1. 1 1
      admin/package-lock.json
  2. 5 6
      admin/package.json
  3. 7 2
      admin/src/pages/Announcements/index.tsx
  4. 7 6
      backend/app/api/admin/admins.py
  5. 7 6
      backend/app/api/admin/announcements.py
  6. 3 2
      backend/app/api/admin/auth.py
  7. 4 3
      backend/app/api/admin/cards.py
  8. 5 4
      backend/app/api/admin/dashboard.py
  9. 7 6
      backend/app/api/admin/keys.py
  10. 3 2
      backend/app/api/admin/logs.py
  11. 6 5
      backend/app/api/admin/software.py
  12. 6 5
      backend/app/api/admin/users.py
  13. 18 17
      backend/app/api/client/auth.py
  14. 1 0
      backend/app/api/client/keys.py
  15. 5 4
      backend/app/api/client/steam.py
  16. 1 0
      backend/app/api/updater.py
  17. 3 2
      backend/app/core/init_keys.py
  18. 6 3
      backend/app/core/security.py
  19. 2 1
      backend/app/middleware/logging.py
  20. 14 12
      backend/app/utils/history.py
  21. 27 0
      backend/app/utils/timezone.py
  22. 42 0
      client-tauri/src-tauri/Cargo.lock
  23. 1 0
      client-tauri/src-tauri/Cargo.toml
  24. 3 1
      client-tauri/src-tauri/src/browser_automation.rs
  25. 3 1
      client-tauri/src-tauri/src/updater.rs
  26. 1 1
      client-tauri/src-tauri/target/debug/.fingerprint/objc_exception-d30fb85a046e76b6/run-build-script-build-script-build
  27. 1 1
      client-tauri/src-tauri/target/debug/.fingerprint/objc_exception-d30fb85a046e76b6/run-build-script-build-script-build.json
  28. 1 1
      client-tauri/src-tauri/target/debug/.fingerprint/openssl-21f559626777278d/run-build-script-build-script-build
  29. 1 1
      client-tauri/src-tauri/target/debug/.fingerprint/openssl-21f559626777278d/run-build-script-build-script-build.json
  30. 1 1
      client-tauri/src-tauri/target/debug/.fingerprint/openssl-sys-74f77a4301a03bdd/run-build-script-build-script-main
  31. 0 0
      client-tauri/src-tauri/target/debug/.fingerprint/openssl-sys-74f77a4301a03bdd/run-build-script-build-script-main.json
  32. 1 1
      client-tauri/src-tauri/target/debug/.fingerprint/tao-baeca0b73a07582e/run-build-script-build-script-build
  33. 1 1
      client-tauri/src-tauri/target/debug/.fingerprint/tao-baeca0b73a07582e/run-build-script-build-script-build.json
  34. BIN
      client-tauri/src-tauri/target/debug/build/objc_exception-d30fb85a046e76b6/out/6e31d61a582ee51a-exception.o
  35. BIN
      client-tauri/src-tauri/target/debug/build/objc_exception-d30fb85a046e76b6/out/libexception.a
  36. 1 1
      client-tauri/src-tauri/target/debug/build/objc_exception-d30fb85a046e76b6/output
  37. BIN
      client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/libcrypto.a
  38. BIN
      client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/libssl.a
  39. 1147 1147
      client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/output
  40. 119 11
      client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/stderr
  41. BIN
      client-tauri/src-tauri/target/debug/build/tao-baeca0b73a07582e/out/038af6a83af07683-carbon_hotkey_binding.o
  42. BIN
      client-tauri/src-tauri/target/debug/build/tao-baeca0b73a07582e/out/libcarbon_hotkey_binding.a.a
  43. 1 1
      client-tauri/src-tauri/target/debug/build/tao-baeca0b73a07582e/output
  44. 2 1
      client-tauri/src/components/tabs/SelectionTab.vue
  45. 2 1
      client-tauri/src/components/tabs/SweepTab.vue
  46. 35 0
      client-tauri/src/utils/timezone.ts

+ 1 - 1
admin/package-lock.json

@@ -11,7 +11,7 @@
         "@ant-design/icons": "^5.2.6",
         "antd": "^5.11.0",
         "axios": "^1.6.2",
-        "dayjs": "^1.11.10",
+        "dayjs": "^1.11.19",
         "react": "^18.2.0",
         "react-dom": "^18.2.0",
         "react-router-dom": "^6.20.0",

+ 5 - 6
admin/package.json

@@ -10,14 +10,14 @@
     "lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0"
   },
   "dependencies": {
+    "@ant-design/icons": "^5.2.6",
+    "antd": "^5.11.0",
+    "axios": "^1.6.2",
+    "dayjs": "^1.11.19",
     "react": "^18.2.0",
     "react-dom": "^18.2.0",
     "react-router-dom": "^6.20.0",
-    "antd": "^5.11.0",
-    "axios": "^1.6.2",
-    "zustand": "^4.4.7",
-    "@ant-design/icons": "^5.2.6",
-    "dayjs": "^1.11.10"
+    "zustand": "^4.4.7"
   },
   "devDependencies": {
     "@types/react": "^18.2.43",
@@ -32,4 +32,3 @@
     "vite": "^5.0.8"
   }
 }
-

+ 7 - 2
admin/src/pages/Announcements/index.tsx

@@ -17,6 +17,11 @@ import { EyeOutlined } from '@ant-design/icons'
 import { announcementApi } from '../../api/admin'
 import type { ColumnsType } from 'antd/es/table'
 import dayjs from 'dayjs'
+import utc from 'dayjs/plugin/utc'
+import timezone from 'dayjs/plugin/timezone'
+
+dayjs.extend(utc)
+dayjs.extend(timezone)
 
 const { TextArea } = Input
 
@@ -181,8 +186,8 @@ export default function Announcements() {
       const submitData = {
         ...values,
         publish_time: values.publish_time
-          ? values.publish_time.toISOString()
-          : new Date().toISOString(),
+          ? dayjs(values.publish_time).tz('Asia/Shanghai').toISOString()
+          : dayjs().tz('Asia/Shanghai').toISOString(),
       }
       if (editingId) {
         await announcementApi.update(editingId, submitData)

+ 7 - 6
backend/app/api/admin/admins.py

@@ -9,6 +9,7 @@ from app.api.deps import get_current_admin
 from app.models.admin import Admin
 from app.core.security import get_password_hash, verify_password
 from datetime import datetime
+from app.utils.timezone import beijing_now
 
 router = APIRouter()
 
@@ -108,8 +109,8 @@ async def create_admin(
         email=req.email,
         role=req.role,
         status=1,
-        created_at=datetime.now(),
-        updated_at=datetime.now()
+        created_at=beijing_now(),
+        updated_at=beijing_now()
     )
     db.add(admin)
 
@@ -202,7 +203,7 @@ async def update_admin(
     if req.role is not None:
         admin.role = req.role
 
-    admin.updated_at = datetime.now()
+    admin.updated_at = beijing_now()
 
     # 创建历史记录
     from app.utils.history import create_admin_history, create_operation_log
@@ -245,7 +246,7 @@ async def reset_admin_password(
 
     # 更新密码
     admin.password = get_password_hash(req.new_password)
-    admin.updated_at = datetime.now()
+    admin.updated_at = beijing_now()
 
     # 记录操作日志
     from app.utils.history import create_operation_log
@@ -283,7 +284,7 @@ async def update_admin_status(
 
     old_status = admin.status
     admin.status = status
-    admin.updated_at = datetime.now()
+    admin.updated_at = beijing_now()
 
     # 记录操作日志
     from app.utils.history import create_operation_log
@@ -322,7 +323,7 @@ async def delete_admin(
         return {"code": 400, "msg": "不能删除自己"}
 
     admin.is_deleted = 1
-    admin.updated_at = datetime.now()
+    admin.updated_at = beijing_now()
 
     # 创建历史记录
     from app.utils.history import create_admin_history, create_operation_log

+ 7 - 6
backend/app/api/admin/announcements.py

@@ -2,6 +2,7 @@
 公告管理接口
 """
 from datetime import datetime
+from app.utils.timezone import beijing_now
 from typing import Optional
 
 from fastapi import APIRouter, Depends, Query, Request
@@ -110,7 +111,7 @@ async def create_announcement(
     current_admin = Depends(get_current_admin)
 ):
     """创建公告"""
-    publish_time = datetime.now()
+    publish_time = beijing_now()
     if req.publish_time:
         try:
             publish_time = datetime.fromisoformat(req.publish_time.replace('Z', '+00:00'))
@@ -123,8 +124,8 @@ async def create_announcement(
         priority=req.priority,
         is_active=1 if req.is_active else 0,
         publish_time=publish_time,
-        created_at=datetime.now(),
-        updated_at=datetime.now()
+        created_at=beijing_now(),
+        updated_at=beijing_now()
     )
     db.add(announcement)
 
@@ -187,7 +188,7 @@ async def update_announcement(
             announcement.publish_time = datetime.fromisoformat(req.publish_time.replace('Z', '+00:00'))
         except:
             pass
-    announcement.updated_at = datetime.now()
+    announcement.updated_at = beijing_now()
 
     # 创建历史记录
     from app.utils.history import create_announcement_history, create_operation_log
@@ -230,7 +231,7 @@ async def toggle_announcement_status(
 
     old_active = announcement.is_active
     announcement.is_active = 0 if announcement.is_active else 1
-    announcement.updated_at = datetime.now()
+    announcement.updated_at = beijing_now()
 
     # 创建历史记录
     from app.utils.history import create_announcement_history, create_operation_log
@@ -268,7 +269,7 @@ async def delete_announcement(
         return {"code": 404, "msg": "公告不存在"}
 
     announcement.is_deleted = 1
-    announcement.updated_at = datetime.now()
+    announcement.updated_at = beijing_now()
 
     # 记录操作日志(删除公告没有历史记录,因为它本身就是历史记录)
     from app.utils.history import create_operation_log

+ 3 - 2
backend/app/api/admin/auth.py

@@ -9,6 +9,7 @@ from app.models.admin import Admin
 from app.core.security import verify_password, create_access_token
 from app.core.logger import logger
 from datetime import datetime
+from app.utils.timezone import beijing_now
 
 router = APIRouter()
 
@@ -39,9 +40,9 @@ async def login(
     
     # 更新登录信息
     client_ip = request.client.host if request.client else None
-    admin.last_login_time = datetime.now()
+    admin.last_login_time = beijing_now()
     admin.last_login_ip = client_ip
-    admin.updated_at = datetime.now()
+    admin.updated_at = beijing_now()
     db.commit()
     
     # 生成令牌

+ 4 - 3
backend/app/api/admin/cards.py

@@ -13,6 +13,7 @@ from app.database import get_db
 from app.api.deps import get_current_admin
 from app.models.card import Card
 from datetime import datetime
+from app.utils.timezone import beijing_now
 
 router = APIRouter()
 
@@ -50,8 +51,8 @@ async def generate_cards(
                 days=req.days,
                 discount=req.discount,
                 status=0,
-                created_at=datetime.now(),
-                updated_at=datetime.now()
+                created_at=beijing_now(),
+                updated_at=beijing_now()
             )
             db.add(card)
             cards.append(card)
@@ -297,6 +298,6 @@ async def export_cards_excel(
     return StreamingResponse(
         iter([output.getvalue()]),
         media_type="text/csv",
-        headers={"Content-Disposition": f"attachment; filename=cards_{datetime.now().strftime('%Y%m%d_%H%M%S')}.csv"}
+        headers={"Content-Disposition": f"attachment; filename=cards_{beijing_now().strftime('%Y%m%d_%H%M%S')}.csv"}
     )
 

+ 5 - 4
backend/app/api/admin/dashboard.py

@@ -11,6 +11,7 @@ from app.models.software import Software
 from app.models.card import Card
 from app.models.api_log import APILog
 from datetime import datetime, timedelta
+from app.utils.timezone import beijing_now
 
 router = APIRouter()
 
@@ -25,7 +26,7 @@ async def get_dashboard_stats(
     total_users = db.query(func.count(User.id)).scalar() or 0
     
     # 今日新增用户
-    today_start = datetime.now().replace(hour=0, minute=0, second=0, microsecond=0)
+    today_start = beijing_now().replace(hour=0, minute=0, second=0, microsecond=0)
     today_new_users = db.query(func.count(User.id)).filter(
         User.created_at >= today_start
     ).scalar() or 0
@@ -58,7 +59,7 @@ async def get_dashboard_stats(
     active_users = db.query(func.count(User.id)).filter(
         and_(
             User.expire_time.isnot(None),
-            User.expire_time > datetime.now()
+            User.expire_time > beijing_now()
         )
     ).scalar() or 0
     
@@ -66,12 +67,12 @@ async def get_dashboard_stats(
     expired_users = db.query(func.count(User.id)).filter(
         and_(
             User.expire_time.isnot(None),
-            User.expire_time <= datetime.now()
+            User.expire_time <= beijing_now()
         )
     ).scalar() or 0
     
     # 最近7天新增用户趋势
-    seven_days_ago = datetime.now() - timedelta(days=7)
+    seven_days_ago = beijing_now() - timedelta(days=7)
     recent_users = db.query(
         func.date(User.created_at).label('date'),
         func.count(User.id).label('count')

+ 7 - 6
backend/app/api/admin/keys.py

@@ -10,6 +10,7 @@ from app.models.api_key import APIKey
 from app.models.key_rotation_config import KeyRotationConfig
 from app.core.encrypt import encryptor
 from datetime import datetime, timedelta
+from app.utils.timezone import beijing_now
 from app.config import settings
 
 router = APIRouter()
@@ -76,12 +77,12 @@ async def rotate_key(
     # 获取配置,确定过期时间
     config = db.query(KeyRotationConfig).first()
     rotation_days = config.rotation_days if config else settings.KEY_ROTATION_DAYS
-    expire_at = datetime.now() + timedelta(days=rotation_days)
+    expire_at = beijing_now() + timedelta(days=rotation_days)
 
     # 禁用旧密钥
     if current_key:
         current_key.is_active = 0
-        current_key.updated_at = datetime.now()
+        current_key.updated_at = beijing_now()
 
     # 创建新密钥
     new_key = APIKey(
@@ -90,8 +91,8 @@ async def rotate_key(
         key_version=new_version,
         is_active=1,
         expire_at=expire_at,
-        created_at=datetime.now(),
-        updated_at=datetime.now()
+        created_at=beijing_now(),
+        updated_at=beijing_now()
     )
     db.add(new_key)
 
@@ -152,12 +153,12 @@ async def update_key_cycle(
         config = KeyRotationConfig(
             rotation_days=rotation_days,
             is_auto_rotate=1,
-            updated_at=datetime.now()
+            updated_at=beijing_now()
         )
         db.add(config)
     else:
         config.rotation_days = rotation_days
-        config.updated_at = datetime.now()
+        config.updated_at = beijing_now()
 
     # 创建历史记录
     from app.utils.history import create_key_rotation_config_history, create_operation_log

+ 3 - 2
backend/app/api/admin/logs.py

@@ -9,6 +9,7 @@ from app.database import get_db
 from app.api.deps import get_current_admin
 from app.models.api_log import APILog
 from datetime import datetime, timedelta
+from app.utils.timezone import beijing_now
 import csv
 import io
 
@@ -126,7 +127,7 @@ async def clear_logs(
         log_count = db.query(APILog).filter(APILog.is_deleted == 0).count()
 
         from datetime import datetime
-        db.query(APILog).filter(APILog.is_deleted == 0).update({"is_deleted": 1, "updated_at": datetime.now()})
+        db.query(APILog).filter(APILog.is_deleted == 0).update({"is_deleted": 1, "updated_at": beijing_now()})
 
         # 记录操作日志
         from app.utils.history import create_operation_log
@@ -239,7 +240,7 @@ async def export_logs_csv(
     return StreamingResponse(
         iter([output.getvalue()]),
         media_type="text/csv",
-        headers={"Content-Disposition": f"attachment; filename=logs_{datetime.now().strftime('%Y%m%d_%H%M%S')}.csv"}
+        headers={"Content-Disposition": f"attachment; filename=logs_{beijing_now().strftime('%Y%m%d_%H%M%S')}.csv"}
     )
 
 @router.get("/export/excel")

+ 6 - 5
backend/app/api/admin/software.py

@@ -8,6 +8,7 @@ from app.database import get_db
 from app.api.deps import get_current_admin
 from app.models.software import Software
 from datetime import datetime
+from app.utils.timezone import beijing_now
 
 router = APIRouter()
 
@@ -69,8 +70,8 @@ async def create_software(
         description=req.description,
         daily_price=req.daily_price,
         is_active=1,
-        created_at=datetime.now(),
-        updated_at=datetime.now()
+        created_at=beijing_now(),
+        updated_at=beijing_now()
     )
     db.add(software)
 
@@ -126,7 +127,7 @@ async def update_software(
     software.name = req.name
     software.description = req.description
     software.daily_price = req.daily_price
-    software.updated_at = datetime.now()
+    software.updated_at = beijing_now()
 
     # 创建历史记录
     from app.utils.history import create_software_history, create_operation_log
@@ -169,7 +170,7 @@ async def update_software_status(
 
     old_active = software.is_active
     software.is_active = is_active
-    software.updated_at = datetime.now()
+    software.updated_at = beijing_now()
 
     # 创建历史记录
     from app.utils.history import create_software_history, create_operation_log
@@ -207,7 +208,7 @@ async def delete_software(
         return {"code": 404, "msg": "软件不存在"}
 
     software.is_deleted = 1
-    software.updated_at = datetime.now()
+    software.updated_at = beijing_now()
 
     # 创建历史记录
     from app.utils.history import create_software_history, create_operation_log

+ 6 - 5
backend/app/api/admin/users.py

@@ -6,6 +6,7 @@ from fastapi.responses import StreamingResponse
 from sqlalchemy.orm import Session
 from sqlalchemy import or_, and_
 from datetime import datetime
+from app.utils.timezone import beijing_now
 import csv
 import io
 from app.database import get_db
@@ -49,7 +50,7 @@ async def get_users(
         query = query.filter(User.machine_code == machine_code)
     
     # 有效期状态筛选
-    now = datetime.now()
+    now = beijing_now()
     if expire_status == "valid":
         query = query.filter(User.expire_time > now)
     elif expire_status == "expired":
@@ -163,7 +164,7 @@ async def update_user_status(
 
         old_status = user.status
         user.status = status
-        user.updated_at = datetime.now()
+        user.updated_at = beijing_now()
 
         # 创建历史记录
         from app.utils.history import create_user_history, create_operation_log
@@ -206,7 +207,7 @@ async def delete_user(
             return {"code": 404, "msg": "用户不存在"}
 
         user.is_deleted = 1
-        user.updated_at = datetime.now()
+        user.updated_at = beijing_now()
 
         # 创建历史记录
         from app.utils.history import create_user_history, create_operation_log
@@ -270,7 +271,7 @@ async def export_users_excel(
         query = query.filter(User.machine_code == machine_code)
 
     # 有效期状态筛选
-    now = datetime.now()
+    now = beijing_now()
     if expire_status == "valid":
         query = query.filter(User.expire_time > now)
     elif expire_status == "expired":
@@ -329,6 +330,6 @@ async def export_users_excel(
     return StreamingResponse(
         iter([output.getvalue()]),
         media_type="text/csv",
-        headers={"Content-Disposition": f"attachment; filename=users_{datetime.now().strftime('%Y%m%d_%H%M%S')}.csv"}
+        headers={"Content-Disposition": f"attachment; filename=users_{beijing_now().strftime('%Y%m%d_%H%M%S')}.csv"}
     )
 

+ 18 - 17
backend/app/api/client/auth.py

@@ -13,6 +13,7 @@ from app.core.encrypt import encryptor
 from app.core.logger import logger
 from app.config import settings
 from datetime import datetime, timedelta
+from app.utils.timezone import beijing_now
 
 router = APIRouter()
 
@@ -76,7 +77,7 @@ async def register(
             return {"code": 400, "msg": "卡密无效或已被使用"}
         
         # 计算到期时间
-        expire_time = datetime.now() + timedelta(days=card.days)
+        expire_time = beijing_now() + timedelta(days=card.days)
         
         # 创建用户
         user = User(
@@ -87,18 +88,18 @@ async def register(
             card_id=card.id,
             expire_time=expire_time,
             status=1,
-            created_at=datetime.now(),
-            updated_at=datetime.now()
+            created_at=beijing_now(),
+            updated_at=beijing_now()
         )
         db.add(user)
         db.flush()  # 刷新以获取user.id
         
         # 更新卡密状态
         card.user_id = user.id
-        card.activated_at = datetime.now()
+        card.activated_at = beijing_now()
         card.expire_time = expire_time
         card.status = 1
-        card.updated_at = datetime.now()
+        card.updated_at = beijing_now()
         
         # 创建充值记录
         recharge_record = RechargeRecord(
@@ -108,7 +109,7 @@ async def register(
             days=card.days,
             expire_time_before=None,  # 新用户,之前没有到期时间
             expire_time_after=expire_time,
-            created_at=datetime.now()
+            created_at=beijing_now()
         )
         db.add(recharge_record)
 
@@ -168,14 +169,14 @@ async def login(
             user.machine_code = req.machine_code
         
         # 检查是否过期
-        if user.expire_time and user.expire_time < datetime.now():
+        if user.expire_time and user.expire_time < beijing_now():
             return {"code": 403, "msg": "卡密已过期"}
         
         # 更新登录信息
         client_ip = request.client.host if request.client else None
-        user.last_login_time = datetime.now()
+        user.last_login_time = beijing_now()
         user.last_login_ip = client_ip
-        user.updated_at = datetime.now()
+        user.updated_at = beijing_now()
         db.commit()
         
         logger.info(f"用户登录成功: {req.username}")
@@ -225,7 +226,7 @@ async def unbind(
         
         # 解绑机器码
         user.machine_code = None
-        user.updated_at = datetime.now()
+        user.updated_at = beijing_now()
         db.commit()
         
         logger.info(f"机器解绑成功: {req.username}")
@@ -265,7 +266,7 @@ async def heartbeat(
             return {"code": 404, "msg": "用户不存在"}
         
         # 检查是否过期
-        if user.expire_time and user.expire_time < datetime.now():
+        if user.expire_time and user.expire_time < beijing_now():
             return {"code": 403, "msg": "卡密已过期"}
         
         return {
@@ -322,23 +323,23 @@ async def activate_card(
         
         # 计算新的到期时间
         expire_time_before = user.expire_time
-        if expire_time_before and expire_time_before > datetime.now():
+        if expire_time_before and expire_time_before > beijing_now():
             # 如果还有有效期,则累加
             expire_time_after = expire_time_before + timedelta(days=card.days)
         else:
             # 如果已过期或没有有效期,则从当前时间开始计算
-            expire_time_after = datetime.now() + timedelta(days=card.days)
+            expire_time_after = beijing_now() + timedelta(days=card.days)
         
         # 更新用户到期时间
         user.expire_time = expire_time_after
-        user.updated_at = datetime.now()
+        user.updated_at = beijing_now()
         
         # 更新卡密状态
         card.user_id = user.id
-        card.activated_at = datetime.now()
+        card.activated_at = beijing_now()
         card.expire_time = expire_time_after
         card.status = 1
-        card.updated_at = datetime.now()
+        card.updated_at = beijing_now()
         
         # 创建充值记录
         recharge_record = RechargeRecord(
@@ -348,7 +349,7 @@ async def activate_card(
             days=card.days,
             expire_time_before=expire_time_before,
             expire_time_after=expire_time_after,
-            created_at=datetime.now()
+            created_at=beijing_now()
         )
         db.add(recharge_record)
 

+ 1 - 0
backend/app/api/client/keys.py

@@ -6,6 +6,7 @@ from sqlalchemy.orm import Session
 from app.database import get_db
 from app.models.api_key import APIKey
 from datetime import datetime, timedelta
+from app.utils.timezone import beijing_now
 
 router = APIRouter()
 

+ 5 - 4
backend/app/api/client/steam.py

@@ -12,6 +12,7 @@ from app.core.encrypt import encryptor
 from app.core.logger import logger
 from app.config import settings
 from datetime import datetime
+from app.utils.timezone import beijing_now
 
 router = APIRouter()
 
@@ -150,8 +151,8 @@ async def create_steam_account(
             shared_secret=encrypted_shared_secret,
             identity_secret=encrypted_identity_secret,
             is_active=1,
-            created_at=datetime.now(),
-            updated_at=datetime.now()
+            created_at=beijing_now(),
+            updated_at=beijing_now()
         )
         db.add(steam_account)
 
@@ -233,7 +234,7 @@ async def update_steam_account(
         if req.is_active is not None:
             account.is_active = req.is_active
         
-        account.updated_at = datetime.now()
+        account.updated_at = beijing_now()
 
         # 创建历史记录
         from app.utils.history import create_steam_account_history
@@ -317,7 +318,7 @@ async def delete_steam_account(
 
         # 软删除账号
         account.is_deleted = 1
-        account.updated_at = datetime.now()
+        account.updated_at = beijing_now()
 
         # 创建历史记录
         from app.utils.history import create_steam_account_history

+ 1 - 0
backend/app/api/updater.py

@@ -8,6 +8,7 @@ from typing import Dict, Any
 import os
 import json
 from datetime import datetime
+from app.utils.timezone import beijing_now
 
 router = APIRouter()
 

+ 3 - 2
backend/app/core/init_keys.py

@@ -7,6 +7,7 @@ from app.models.api_key import APIKey
 from app.core.encrypt import encryptor
 from app.core.logger import logger
 from datetime import datetime, timedelta
+from app.utils.timezone import beijing_now
 from app.config import settings
 
 def init_keys():
@@ -29,7 +30,7 @@ def init_keys():
         next_version = (max_version.key_version + 1) if max_version else 1
         
         # 计算过期时间
-        expire_at = datetime.now() + timedelta(days=settings.KEY_ROTATION_DAYS)
+        expire_at = beijing_now() + timedelta(days=settings.KEY_ROTATION_DAYS)
         
         # 创建密钥记录
         api_key = APIKey(
@@ -37,7 +38,7 @@ def init_keys():
             private_key=private_pem,
             key_version=next_version,
             is_active=1,
-            created_at=datetime.now(),
+            created_at=beijing_now(),
             expire_at=expire_at
         )
         db.add(api_key)

+ 6 - 3
backend/app/core/security.py

@@ -29,7 +29,7 @@ except ImportError:
     # 如果没有jose,使用简单的实现
     import jwt
     JWTError = Exception
-from datetime import datetime, timedelta
+from datetime import datetime, timedelta, timezone
 from typing import Optional
 from app.config import settings
 
@@ -74,10 +74,13 @@ def get_password_hash(password: str) -> str:
 def create_access_token(data: dict, expires_delta: Optional[timedelta] = None) -> str:
     """创建访问令牌"""
     to_encode = data.copy()
+    # 使用北京时间 (UTC+8)
+    beijing_tz = timezone(timedelta(hours=8))
+    now = datetime.now(beijing_tz)
     if expires_delta:
-        expire = datetime.utcnow() + expires_delta
+        expire = now + expires_delta
     else:
-        expire = datetime.utcnow() + timedelta(hours=24)
+        expire = now + timedelta(hours=24)
     to_encode.update({"exp": expire})
     encoded_jwt = jwt.encode(to_encode, settings.SECRET_KEY, algorithm="HS256")
     return encoded_jwt

+ 2 - 1
backend/app/middleware/logging.py

@@ -13,6 +13,7 @@ from app.core.logger import logger
 from app.core.security import verify_token
 from app.models.admin import Admin
 from datetime import datetime
+from app.utils.timezone import beijing_now
 from typing import Any
 
 class LoggingResponse(Response):
@@ -91,7 +92,7 @@ class APILoggingMiddleware(BaseHTTPMiddleware):
                     user_agent=user_agent,
                     response_code=status_code,
                     execution_time=execution_time,
-                    created_at=datetime.now()
+                    created_at=beijing_now()
                 )
                 db.add(api_log)
                 db.commit()

+ 14 - 12
backend/app/utils/history.py

@@ -2,6 +2,7 @@
 历史记录工具函数
 """
 from datetime import datetime
+from app.utils.timezone import beijing_now
 from sqlalchemy.orm import Session
 from app.models import (
     Admin, AdminHis,
@@ -33,7 +34,7 @@ def create_admin_history(db: Session, admin: Admin, operation: str):
         is_deleted=admin.is_deleted,
         created_at=admin.created_at,
         updated_at=admin.updated_at,
-        his_created_at=datetime.now(),
+        his_created_at=beijing_now(),
         his_operation=operation
     )
     db.add(his_record)
@@ -51,7 +52,7 @@ def create_announcement_history(db: Session, announcement: Announcement, operati
         is_deleted=announcement.is_deleted,
         created_at=announcement.created_at,
         updated_at=announcement.updated_at,
-        his_created_at=datetime.now(),
+        his_created_at=beijing_now(),
         his_operation=operation
     )
     db.add(his_record)
@@ -68,7 +69,7 @@ def create_api_key_history(db: Session, api_key: APIKey, operation: str):
         is_deleted=api_key.is_deleted,
         created_at=api_key.created_at,
         expire_at=api_key.expire_at,
-        his_created_at=datetime.now(),
+        his_created_at=beijing_now(),
         his_operation=operation
     )
     db.add(his_record)
@@ -89,7 +90,7 @@ def create_api_log_history(db: Session, api_log: APILog, operation: str):
         execution_time=api_log.execution_time,
         is_deleted=api_log.is_deleted,
         created_at=api_log.created_at,
-        his_created_at=datetime.now(),
+        his_created_at=beijing_now(),
         his_operation=operation
     )
     db.add(his_record)
@@ -110,7 +111,7 @@ def create_card_history(db: Session, card: Card, operation: str):
         is_deleted=card.is_deleted,
         created_at=card.created_at,
         updated_at=card.updated_at,
-        his_created_at=datetime.now(),
+        his_created_at=beijing_now(),
         his_operation=operation
     )
     db.add(his_record)
@@ -126,7 +127,7 @@ def create_key_rotation_config_history(db: Session, config: KeyRotationConfig, o
         next_rotation_time=config.next_rotation_time,
         is_deleted=config.is_deleted,
         updated_at=config.updated_at,
-        his_created_at=datetime.now(),
+        his_created_at=beijing_now(),
         his_operation=operation
     )
     db.add(his_record)
@@ -145,7 +146,7 @@ def create_operation_log_history(db: Session, operation_log: OperationLog, opera
         ip_address=operation_log.ip_address,
         is_deleted=operation_log.is_deleted,
         created_at=operation_log.created_at,
-        his_created_at=datetime.now(),
+        his_created_at=beijing_now(),
         his_operation=operation
     )
     db.add(his_record)
@@ -164,7 +165,7 @@ def create_recharge_record_history(db: Session, recharge_record: RechargeRecord,
         expire_time_after=recharge_record.expire_time_after,
         is_deleted=recharge_record.is_deleted,
         created_at=recharge_record.created_at,
-        his_created_at=datetime.now(),
+        his_created_at=beijing_now(),
         his_operation=operation
     )
     db.add(his_record)
@@ -182,7 +183,7 @@ def create_software_history(db: Session, software: Software, operation: str):
         is_deleted=software.is_deleted,
         created_at=software.created_at,
         updated_at=software.updated_at,
-        his_created_at=datetime.now(),
+        his_created_at=beijing_now(),
         his_operation=operation
     )
     db.add(his_record)
@@ -202,7 +203,7 @@ def create_steam_account_history(db: Session, steam_account: SteamAccount, opera
         is_deleted=steam_account.is_deleted,
         created_at=steam_account.created_at,
         updated_at=steam_account.updated_at,
-        his_created_at=datetime.now(),
+        his_created_at=beijing_now(),
         his_operation=operation
     )
     db.add(his_record)
@@ -224,7 +225,7 @@ def create_user_history(db: Session, user: User, operation: str):
         is_deleted=user.is_deleted,
         created_at=user.created_at,
         updated_at=user.updated_at,
-        his_created_at=datetime.now(),
+        his_created_at=beijing_now(),
         his_operation=operation
     )
     db.add(his_record)
@@ -243,6 +244,7 @@ def create_operation_log(
     """创建操作日志记录"""
     import json
     from datetime import datetime
+from app.utils.timezone import beijing_now
 
     operation_log = OperationLog(
         admin_id=admin_id,
@@ -252,6 +254,6 @@ def create_operation_log(
         old_data=json.dumps(old_data, ensure_ascii=False) if old_data else None,
         new_data=json.dumps(new_data, ensure_ascii=False) if new_data else None,
         ip_address=ip_address,
-        created_at=datetime.now()
+        created_at=beijing_now()
     )
     db.add(operation_log)

+ 27 - 0
backend/app/utils/timezone.py

@@ -0,0 +1,27 @@
+"""
+时区工具函数
+"""
+from datetime import datetime, timezone, timedelta
+
+
+def get_beijing_time() -> datetime:
+    """获取当前北京时间 (UTC+8)"""
+    beijing_tz = timezone(timedelta(hours=8))
+    return datetime.now(beijing_tz)
+
+
+def beijing_now() -> datetime:
+    """获取当前北京时间 (UTC+8) - 别名函数"""
+    return get_beijing_time()
+
+
+def datetime_to_beijing(dt: datetime) -> datetime:
+    """将datetime对象转换为北京时间"""
+    if dt.tzinfo is None:
+        # 如果是naive datetime,假设它是本地时间,转换为北京时间
+        beijing_tz = timezone(timedelta(hours=8))
+        return dt.replace(tzinfo=timezone.utc).astimezone(beijing_tz)
+    else:
+        # 如果已经有时区信息,直接转换为北京时间
+        beijing_tz = timezone(timedelta(hours=8))
+        return dt.astimezone(beijing_tz)

+ 42 - 0
client-tauri/src-tauri/Cargo.lock

@@ -315,6 +315,28 @@ dependencies = [
  "windows-link",
 ]
 
+[[package]]
+name = "chrono-tz"
+version = "0.8.6"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d59ae0466b83e838b81a54256c39d5d7c20b9d7daa10510a242d9b75abd5936e"
+dependencies = [
+ "chrono",
+ "chrono-tz-build",
+ "phf 0.11.3",
+]
+
+[[package]]
+name = "chrono-tz-build"
+version = "0.2.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "433e39f13c9a060046954e0592a8d0a4bcb1040125cbf91cb8ee58964cfb350f"
+dependencies = [
+ "parse-zoneinfo",
+ "phf 0.11.3",
+ "phf_codegen 0.11.3",
+]
+
 [[package]]
 name = "cipher"
 version = "0.4.4"
@@ -2174,6 +2196,15 @@ dependencies = [
  "windows-link",
 ]
 
+[[package]]
+name = "parse-zoneinfo"
+version = "0.3.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1f2a05b18d44e2957b88f96ba460715e295bc1d7510468a2f3d3b44535d26c24"
+dependencies = [
+ "regex",
+]
+
 [[package]]
 name = "pathdiff"
 version = "0.2.3"
@@ -2245,6 +2276,16 @@ dependencies = [
  "phf_shared 0.10.0",
 ]
 
+[[package]]
+name = "phf_codegen"
+version = "0.11.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "aef8048c789fa5e851558d709946d6d79a8ff88c0440c587967f8e94bfb1216a"
+dependencies = [
+ "phf_generator 0.11.3",
+ "phf_shared 0.11.3",
+]
+
 [[package]]
 name = "phf_generator"
 version = "0.8.0"
@@ -4868,6 +4909,7 @@ dependencies = [
  "block-padding",
  "cbc",
  "chrono",
+ "chrono-tz",
  "dirs",
  "hmac",
  "lazy_static",

+ 1 - 0
client-tauri/src-tauri/Cargo.toml

@@ -26,6 +26,7 @@ tokio = { version = "1", features = ["full"] }
 # 暂时注释掉有问题的依赖
 # playwright = { git = "https://github.com/octaltree/playwright-rust", features = ["chromium"] }
 chrono = { version = "0.4", features = ["serde"] }
+chrono-tz = "0.8"
 anyhow = "1.0"
 lazy_static = "1.4"
 

+ 3 - 1
client-tauri/src-tauri/src/browser_automation.rs

@@ -5,6 +5,8 @@
 // use playwright::api::Page;
 use std::collections::HashMap;
 use serde::{Deserialize, Serialize};
+use chrono::{DateTime, Utc};
+use chrono_tz::Asia::Shanghai;
 
 #[derive(Debug, Serialize, Deserialize)]
 pub struct BrowserConfig {
@@ -189,7 +191,7 @@ pub async fn launch_browser_session(
     manager.launch_browser(config).await
         .map_err(|e| format!("Failed to launch browser: {}", e))?;
 
-    let session_id = format!("session_{}", chrono::Utc::now().timestamp());
+    let session_id = format!("session_{}", Utc::now().with_timezone(&Shanghai).timestamp());
 
     manager.create_steam_session(&session_id, credentials).await
         .map_err(|e| format!("Failed to create session: {}", e))?;

+ 3 - 1
client-tauri/src-tauri/src/updater.rs

@@ -5,6 +5,8 @@ use tauri::{AppHandle, Manager};
 use tauri::api::version;
 use serde::{Deserialize, Serialize};
 use std::collections::HashMap;
+use chrono::{DateTime, Utc};
+use chrono_tz::Asia::Shanghai;
 
 #[derive(Debug, Serialize, Deserialize)]
 pub struct UpdateInfo {
@@ -37,7 +39,7 @@ pub async fn check_for_updates(_app: AppHandle) -> Result<UpdateInfo, String> {
     Ok(UpdateInfo {
         version: env!("CARGO_PKG_VERSION", "1.0.0").to_string(),
         notes: "当前已是最新版本".to_string(),
-        pub_date: chrono::Utc::now().to_rfc3339(),
+        pub_date: Utc::now().with_timezone(&Shanghai).to_rfc3339(),
         platforms: std::collections::HashMap::new(),
     })
 }

+ 1 - 1
client-tauri/src-tauri/target/debug/.fingerprint/objc_exception-d30fb85a046e76b6/run-build-script-build-script-build

@@ -1 +1 @@
-489bf2d8206ed314
+d6ed29fc01ca341d

+ 1 - 1
client-tauri/src-tauri/target/debug/.fingerprint/objc_exception-d30fb85a046e76b6/run-build-script-build-script-build.json

@@ -1 +1 @@
-{"rustc":18415816196306954164,"features":"","declared_features":"","target":0,"profile":0,"path":0,"deps":[[12626614035236479497,"build_script_build",false,9533535514001594864]],"local":[{"RerunIfEnvChanged":{"var":"CC_aarch64-apple-darwin","val":null}},{"RerunIfEnvChanged":{"var":"CC_aarch64_apple_darwin","val":null}},{"RerunIfEnvChanged":{"var":"HOST_CC","val":null}},{"RerunIfEnvChanged":{"var":"CC","val":null}},{"RerunIfEnvChanged":{"var":"CC_ENABLE_DEBUG_OUTPUT","val":null}},{"RerunIfEnvChanged":{"var":"CRATE_CC_NO_DEFAULTS","val":null}},{"RerunIfEnvChanged":{"var":"MACOSX_DEPLOYMENT_TARGET","val":"10.13"}},{"RerunIfEnvChanged":{"var":"CFLAGS","val":null}},{"RerunIfEnvChanged":{"var":"HOST_CFLAGS","val":null}},{"RerunIfEnvChanged":{"var":"CFLAGS_aarch64_apple_darwin","val":null}},{"RerunIfEnvChanged":{"var":"CFLAGS_aarch64-apple-darwin","val":null}},{"RerunIfEnvChanged":{"var":"AR_aarch64-apple-darwin","val":null}},{"RerunIfEnvChanged":{"var":"AR_aarch64_apple_darwin","val":null}},{"RerunIfEnvChanged":{"var":"HOST_AR","val":null}},{"RerunIfEnvChanged":{"var":"AR","val":null}},{"RerunIfEnvChanged":{"var":"ARFLAGS","val":null}},{"RerunIfEnvChanged":{"var":"HOST_ARFLAGS","val":null}},{"RerunIfEnvChanged":{"var":"ARFLAGS_aarch64_apple_darwin","val":null}},{"RerunIfEnvChanged":{"var":"ARFLAGS_aarch64-apple-darwin","val":null}}],"rustflags":[],"config":0,"compile_kind":0}
+{"rustc":18415816196306954164,"features":"","declared_features":"","target":0,"profile":0,"path":0,"deps":[[12626614035236479497,"build_script_build",false,9533535514001594864]],"local":[{"RerunIfEnvChanged":{"var":"CC_aarch64-apple-darwin","val":null}},{"RerunIfEnvChanged":{"var":"CC_aarch64_apple_darwin","val":null}},{"RerunIfEnvChanged":{"var":"HOST_CC","val":null}},{"RerunIfEnvChanged":{"var":"CC","val":null}},{"RerunIfEnvChanged":{"var":"CC_ENABLE_DEBUG_OUTPUT","val":null}},{"RerunIfEnvChanged":{"var":"CRATE_CC_NO_DEFAULTS","val":null}},{"RerunIfEnvChanged":{"var":"MACOSX_DEPLOYMENT_TARGET","val":null}},{"RerunIfEnvChanged":{"var":"CFLAGS","val":null}},{"RerunIfEnvChanged":{"var":"HOST_CFLAGS","val":null}},{"RerunIfEnvChanged":{"var":"CFLAGS_aarch64_apple_darwin","val":null}},{"RerunIfEnvChanged":{"var":"CFLAGS_aarch64-apple-darwin","val":null}},{"RerunIfEnvChanged":{"var":"AR_aarch64-apple-darwin","val":null}},{"RerunIfEnvChanged":{"var":"AR_aarch64_apple_darwin","val":null}},{"RerunIfEnvChanged":{"var":"HOST_AR","val":null}},{"RerunIfEnvChanged":{"var":"AR","val":null}},{"RerunIfEnvChanged":{"var":"ARFLAGS","val":null}},{"RerunIfEnvChanged":{"var":"HOST_ARFLAGS","val":null}},{"RerunIfEnvChanged":{"var":"ARFLAGS_aarch64_apple_darwin","val":null}},{"RerunIfEnvChanged":{"var":"ARFLAGS_aarch64-apple-darwin","val":null}}],"rustflags":[],"config":0,"compile_kind":0}

+ 1 - 1
client-tauri/src-tauri/target/debug/.fingerprint/openssl-21f559626777278d/run-build-script-build-script-build

@@ -1 +1 @@
-6fb8942f317c6398
+e00c95bce594b581

+ 1 - 1
client-tauri/src-tauri/target/debug/.fingerprint/openssl-21f559626777278d/run-build-script-build-script-build.json

@@ -1 +1 @@
-{"rustc":18415816196306954164,"features":"","declared_features":"","target":0,"profile":0,"path":0,"deps":[[5761075229817198170,"build_script_build",false,3061960674897041521],[12377156390381228557,"build_script_main",false,4848811425804278688]],"local":[{"Precalculated":"0.10.75"}],"rustflags":[],"config":0,"compile_kind":0}
+{"rustc":18415816196306954164,"features":"","declared_features":"","target":0,"profile":0,"path":0,"deps":[[5761075229817198170,"build_script_build",false,3061960674897041521],[12377156390381228557,"build_script_main",false,6866992655922451977]],"local":[{"Precalculated":"0.10.75"}],"rustflags":[],"config":0,"compile_kind":0}

+ 1 - 1
client-tauri/src-tauri/target/debug/.fingerprint/openssl-sys-74f77a4301a03bdd/run-build-script-build-script-main

@@ -1 +1 @@
-a05beb394d704a43
+0956790b70754c5f

Разница между файлами не показана из-за своего большого размера
+ 0 - 0
client-tauri/src-tauri/target/debug/.fingerprint/openssl-sys-74f77a4301a03bdd/run-build-script-build-script-main.json


+ 1 - 1
client-tauri/src-tauri/target/debug/.fingerprint/tao-baeca0b73a07582e/run-build-script-build-script-build

@@ -1 +1 @@
-953be49c2d79555c
+1b1cd2ebf758dbd2

+ 1 - 1
client-tauri/src-tauri/target/debug/.fingerprint/tao-baeca0b73a07582e/run-build-script-build-script-build.json

@@ -1 +1 @@
-{"rustc":18415816196306954164,"features":"","declared_features":"","target":0,"profile":0,"path":0,"deps":[[3007252114546291461,"build_script_build",false,4779319942253601916]],"local":[{"RerunIfEnvChanged":{"var":"CC_aarch64-apple-darwin","val":null}},{"RerunIfEnvChanged":{"var":"CC_aarch64_apple_darwin","val":null}},{"RerunIfEnvChanged":{"var":"HOST_CC","val":null}},{"RerunIfEnvChanged":{"var":"CC","val":null}},{"RerunIfEnvChanged":{"var":"CC_ENABLE_DEBUG_OUTPUT","val":null}},{"RerunIfEnvChanged":{"var":"CRATE_CC_NO_DEFAULTS","val":null}},{"RerunIfEnvChanged":{"var":"MACOSX_DEPLOYMENT_TARGET","val":"10.13"}},{"RerunIfEnvChanged":{"var":"CFLAGS","val":null}},{"RerunIfEnvChanged":{"var":"HOST_CFLAGS","val":null}},{"RerunIfEnvChanged":{"var":"CFLAGS_aarch64_apple_darwin","val":null}},{"RerunIfEnvChanged":{"var":"CFLAGS_aarch64-apple-darwin","val":null}},{"RerunIfEnvChanged":{"var":"AR_aarch64-apple-darwin","val":null}},{"RerunIfEnvChanged":{"var":"AR_aarch64_apple_darwin","val":null}},{"RerunIfEnvChanged":{"var":"HOST_AR","val":null}},{"RerunIfEnvChanged":{"var":"AR","val":null}},{"RerunIfEnvChanged":{"var":"ARFLAGS","val":null}},{"RerunIfEnvChanged":{"var":"HOST_ARFLAGS","val":null}},{"RerunIfEnvChanged":{"var":"ARFLAGS_aarch64_apple_darwin","val":null}},{"RerunIfEnvChanged":{"var":"ARFLAGS_aarch64-apple-darwin","val":null}}],"rustflags":[],"config":0,"compile_kind":0}
+{"rustc":18415816196306954164,"features":"","declared_features":"","target":0,"profile":0,"path":0,"deps":[[3007252114546291461,"build_script_build",false,4779319942253601916]],"local":[{"RerunIfEnvChanged":{"var":"CC_aarch64-apple-darwin","val":null}},{"RerunIfEnvChanged":{"var":"CC_aarch64_apple_darwin","val":null}},{"RerunIfEnvChanged":{"var":"HOST_CC","val":null}},{"RerunIfEnvChanged":{"var":"CC","val":null}},{"RerunIfEnvChanged":{"var":"CC_ENABLE_DEBUG_OUTPUT","val":null}},{"RerunIfEnvChanged":{"var":"CRATE_CC_NO_DEFAULTS","val":null}},{"RerunIfEnvChanged":{"var":"MACOSX_DEPLOYMENT_TARGET","val":null}},{"RerunIfEnvChanged":{"var":"CFLAGS","val":null}},{"RerunIfEnvChanged":{"var":"HOST_CFLAGS","val":null}},{"RerunIfEnvChanged":{"var":"CFLAGS_aarch64_apple_darwin","val":null}},{"RerunIfEnvChanged":{"var":"CFLAGS_aarch64-apple-darwin","val":null}},{"RerunIfEnvChanged":{"var":"AR_aarch64-apple-darwin","val":null}},{"RerunIfEnvChanged":{"var":"AR_aarch64_apple_darwin","val":null}},{"RerunIfEnvChanged":{"var":"HOST_AR","val":null}},{"RerunIfEnvChanged":{"var":"AR","val":null}},{"RerunIfEnvChanged":{"var":"ARFLAGS","val":null}},{"RerunIfEnvChanged":{"var":"HOST_ARFLAGS","val":null}},{"RerunIfEnvChanged":{"var":"ARFLAGS_aarch64_apple_darwin","val":null}},{"RerunIfEnvChanged":{"var":"ARFLAGS_aarch64-apple-darwin","val":null}}],"rustflags":[],"config":0,"compile_kind":0}

BIN
client-tauri/src-tauri/target/debug/build/objc_exception-d30fb85a046e76b6/out/6e31d61a582ee51a-exception.o


BIN
client-tauri/src-tauri/target/debug/build/objc_exception-d30fb85a046e76b6/out/libexception.a


+ 1 - 1
client-tauri/src-tauri/target/debug/build/objc_exception-d30fb85a046e76b6/output

@@ -17,7 +17,7 @@ cargo:rerun-if-env-changed=CRATE_CC_NO_DEFAULTS
 CRATE_CC_NO_DEFAULTS = None
 DEBUG = Some(true)
 cargo:rerun-if-env-changed=MACOSX_DEPLOYMENT_TARGET
-MACOSX_DEPLOYMENT_TARGET = Some(10.13)
+MACOSX_DEPLOYMENT_TARGET = None
 cargo:rerun-if-env-changed=CFLAGS
 CFLAGS = None
 cargo:rerun-if-env-changed=HOST_CFLAGS

BIN
client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/libcrypto.a


BIN
client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/libssl.a


Разница между файлами не показана из-за своего большого размера
+ 1147 - 1147
client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/output


+ 119 - 11
client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/stderr

@@ -1,15 +1,4 @@
 DEBUG: all keys: APPLINKDIR, BINDIR, CMAKECONFIGDIR, ENGINESDIR, INCLUDEDIR, LDLIBS, LIBDIR, MODULESDIR, PKGCONFIGDIR, PREFIX, VERSION, libdir
-DEBUG: PREFIX = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install => PREFIX = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install
-DEBUG: libdir = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib => libdir = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib
-DEBUG: BINDIR = bin => BINDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/bin, BINDIR_REL_PREFIX = bin
-DEBUG: LIBDIR = lib => LIBDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib, LIBDIR_REL_PREFIX = lib
-DEBUG: INCLUDEDIR = include => INCLUDEDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/include, INCLUDEDIR_REL_PREFIX = include
-DEBUG: APPLINKDIR = include/openssl => APPLINKDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/include/openssl, APPLINKDIR_REL_PREFIX = include/openssl
-DEBUG: ENGINESDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/engines-3 => ENGINESDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/engines-3, ENGINESDIR_REL_LIBDIR = engines-3
-DEBUG: MODULESDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/ossl-modules => MODULESDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/ossl-modules, MODULESDIR_REL_LIBDIR = ossl-modules
-DEBUG: PKGCONFIGDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/pkgconfig => PKGCONFIGDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/pkgconfig, PKGCONFIGDIR_REL_LIBDIR = pkgconfig
-DEBUG: CMAKECONFIGDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/cmake/OpenSSL => DEBUG: all keys: APPLINKDIR, BINDIR, CMAKECONFIGDIR, ENGINESDIR, INCLUDEDIR, LDLIBS, LIBDIR, MODULESDIR, PKGCONFIGDIR, PREFIX, VERSION, libdir
-CMAKECONFIGDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/cmake/OpenSSL, CMAKECONFIGDIR_REL_LIBDIR = cmake/OpenSSL
 No value given for CMAKECONFIGDIR
 No value given for PKGCONFIGDIR
 No value given for libdir
@@ -23,3 +12,122 @@ DEBUG: ENGINESDIR = engines => ENGINESDIR = /Users/wuzilong/work/00code/Buff/cli
 DEBUG: MODULESDIR = providers => MODULESDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/build/src/providers, MODULESDIR_REL_LIBDIR = providers
 DEBUG: PKGCONFIGDIR = . => PKGCONFIGDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/build/src, PKGCONFIGDIR_REL_LIBDIR = .
 DEBUG: CMAKECONFIGDIR = . => CMAKECONFIGDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/build/src, CMAKECONFIGDIR_REL_LIBDIR = .
+DEBUG: all keys: APPLINKDIR, BINDIR, CMAKECONFIGDIR, ENGINESDIR, INCLUDEDIR, LDLIBS, LIBDIR, MODULESDIR, PKGCONFIGDIR, PREFIX, VERSION, libdir
+DEBUG: PREFIX = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install => PREFIX = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install
+DEBUG: libdir = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib => libdir = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib
+DEBUG: BINDIR = bin => BINDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/bin, BINDIR_REL_PREFIX = bin
+DEBUG: LIBDIR = lib => LIBDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib, LIBDIR_REL_PREFIX = lib
+DEBUG: INCLUDEDIR = include => INCLUDEDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/include, INCLUDEDIR_REL_PREFIX = include
+DEBUG: APPLINKDIR = include/openssl => APPLINKDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/include/openssl, APPLINKDIR_REL_PREFIX = include/openssl
+DEBUG: ENGINESDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/engines-3 => ENGINESDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/engines-3, ENGINESDIR_REL_LIBDIR = engines-3
+DEBUG: MODULESDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/ossl-modules => MODULESDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/ossl-modules, MODULESDIR_REL_LIBDIR = ossl-modules
+DEBUG: PKGCONFIGDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/pkgconfig => PKGCONFIGDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/pkgconfig, PKGCONFIGDIR_REL_LIBDIR = pkgconfig
+DEBUG: CMAKECONFIGDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/cmake/OpenSSL => CMAKECONFIGDIR = /Users/wuzilong/work/00code/Buff/client-tauri/src-tauri/target/debug/build/openssl-sys-74f77a4301a03bdd/out/openssl-build/install/lib/cmake/OpenSSL, CMAKECONFIGDIR_REL_LIBDIR = cmake/OpenSSL
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.
+Use of uninitialized value in join or string at /System/Library/Perl/5.34/darwin-thread-multi-2level/re.pm line 47.

BIN
client-tauri/src-tauri/target/debug/build/tao-baeca0b73a07582e/out/038af6a83af07683-carbon_hotkey_binding.o


BIN
client-tauri/src-tauri/target/debug/build/tao-baeca0b73a07582e/out/libcarbon_hotkey_binding.a.a


+ 1 - 1
client-tauri/src-tauri/target/debug/build/tao-baeca0b73a07582e/output

@@ -18,7 +18,7 @@ cargo:rerun-if-env-changed=CRATE_CC_NO_DEFAULTS
 CRATE_CC_NO_DEFAULTS = None
 DEBUG = Some(true)
 cargo:rerun-if-env-changed=MACOSX_DEPLOYMENT_TARGET
-MACOSX_DEPLOYMENT_TARGET = Some(10.13)
+MACOSX_DEPLOYMENT_TARGET = None
 cargo:rerun-if-env-changed=CFLAGS
 CFLAGS = None
 cargo:rerun-if-env-changed=HOST_CFLAGS

+ 2 - 1
client-tauri/src/components/tabs/SelectionTab.vue

@@ -208,6 +208,7 @@
 <script setup lang="ts">
 import { ref, reactive, onMounted, onUnmounted } from 'vue'
 import { invoke } from '@tauri-apps/api/tauri'
+import { getBeijingDateString } from '../../utils/timezone'
 
 interface UserInfo {
   user_id: number
@@ -371,7 +372,7 @@ const exportResults = () => {
   const blob = new Blob([csvContent], { type: 'text/csv;charset=utf-8;' })
   const link = document.createElement('a')
   link.href = URL.createObjectURL(blob)
-  link.download = `选品结果_${new Date().toISOString().slice(0, 10)}.csv`
+  link.download = `选品结果_${getBeijingDateString()}.csv`
   link.click()
 
   showMessage('结果导出成功', 'success')

+ 2 - 1
client-tauri/src/components/tabs/SweepTab.vue

@@ -235,6 +235,7 @@
 <script setup lang="ts">
 import { ref, reactive, computed, onMounted, onUnmounted } from 'vue'
 import { invoke } from '@tauri-apps/api/tauri'
+import { getBeijingDateString } from '../../utils/timezone'
 
 interface UserInfo {
   user_id: number
@@ -466,7 +467,7 @@ const exportLogs = () => {
   const blob = new Blob([csvContent], { type: 'text/csv;charset=utf-8;' })
   const link = document.createElement('a')
   link.href = URL.createObjectURL(blob)
-  link.download = `扫货日志_${new Date().toISOString().slice(0, 10)}.csv`
+  link.download = `扫货日志_${getBeijingDateString()}.csv`
   link.click()
 
   showMessage('日志导出成功', 'success')

+ 35 - 0
client-tauri/src/utils/timezone.ts

@@ -0,0 +1,35 @@
+/**
+ * 时区工具函数 - 北京时间处理
+ */
+
+/**
+ * 获取当前北京时间 (UTC+8)
+ */
+export function getBeijingTime(): Date {
+  const now = new Date();
+  const utcTime = now.getTime() + (now.getTimezoneOffset() * 60000);
+  return new Date(utcTime + (8 * 3600000)); // 北京时间是UTC+8
+}
+
+/**
+ * 获取北京时间格式化的日期字符串 (YYYY-MM-DD)
+ */
+export function getBeijingDateString(): string {
+  const beijingTime = getBeijingTime();
+  return beijingTime.toISOString().slice(0, 10);
+}
+
+/**
+ * 获取北京时间格式化的完整时间字符串 (YYYY-MM-DD HH:mm:ss)
+ */
+export function getBeijingDateTimeString(): string {
+  const beijingTime = getBeijingTime();
+  const year = beijingTime.getFullYear();
+  const month = String(beijingTime.getMonth() + 1).padStart(2, '0');
+  const day = String(beijingTime.getDate()).padStart(2, '0');
+  const hours = String(beijingTime.getHours()).padStart(2, '0');
+  const minutes = String(beijingTime.getMinutes()).padStart(2, '0');
+  const seconds = String(beijingTime.getSeconds()).padStart(2, '0');
+
+  return `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`;
+}

Некоторые файлы не были показаны из-за большого количества измененных файлов