Przeglądaj źródła

feat: 更新开放配置查询

gatsby 3 tygodni temu
rodzic
commit
fab70352e9

+ 2 - 1
backend/app/plugin/module_payment/openapi/service.py

@@ -79,6 +79,7 @@ class OpenTransferService:
                 return False
 
             auth.tenant_id = open_data.tenant_id
+            auth.check_data_scope = True
             conf = await OpenConfService.get_conf_service(auth)
             if not conf:
                 log.info("回调通知: 开放转账配置不存在, tenant_id={}", auth.tenant_id)
@@ -173,7 +174,7 @@ class OpenConfService:
         查询开放配置
         """
         crud = OpenConfCRUD(auth)
-        result = await crud.get_first()
+        result = await crud.get(tenant_id=auth.tenant_id)
 
         if result is not None:
              return OpenConfOutSchema.model_validate(result)

+ 2 - 2
backend/tests/test_apikey_sign.py

@@ -16,8 +16,8 @@ class TestApiKeySign(unittest.TestCase):
         data = {
             "account_book_id": "2088480770941200",
             "amount": 1.00,
-            "order_title": "Apikey转账4",
-            "third_biz_no": "123424202604270044",
+            "order_title": "Apikey转账5",
+            "third_biz_no": "123424202604270055",
             "payee_info": {
                 "identity_type": "ALIPAY_ACCOUNT",
                 "name": "钱红武",