This commit is contained in:
2026-06-12 09:49:13 +08:00
parent 6be65a6d68
commit e57f7d4c2c
3 changed files with 63 additions and 28 deletions
+4 -1
View File
@@ -112,8 +112,11 @@ async def wechat_callback(request: Request, db: AsyncSession = Depends(get_db)):
cert_serial_no = db_configs.get("payment_wechat_cert_serial_no", "")
api_v3_key = db_configs.get("payment_wechat_api_v3_key", "")
appid = db_configs.get("payment_wechat_appid", "")
public_key = db_configs.get("payment_wechat_public_key", "")
public_key_id = db_configs.get("payment_wechat_public_key_id", "")
notify_url = db_configs.get("payment_wechat_notify_url", "")
client = _get_wechat_client(mch_id, private_key, cert_serial_no, api_v3_key, appid)
client = _get_wechat_client(mch_id, private_key, cert_serial_no, api_v3_key, appid, notify_url, public_key, public_key_id)
if not client:
logger.error("WeChat client not initialized for callback")
return {"code": "SUCCESS", "message": "OK"}