20240115-ljl-multiPay
ljl 1 year ago
parent 6aede06cd4
commit 7b4d02da60

@ -1,5 +1,7 @@
package com.ms.biz.spi.callback; package com.ms.biz.spi.callback;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.jinritemai.cloud.base.api.BaseRequest; import com.jinritemai.cloud.base.api.BaseRequest;
import com.jinritemai.cloud.base.api.BaseResponse; import com.jinritemai.cloud.base.api.BaseResponse;
import com.jinritemai.cloud.base.api.ExtensionService; import com.jinritemai.cloud.base.api.ExtensionService;
@ -15,18 +17,18 @@ import lombok.extern.slf4j.Slf4j;
@ExtensionService("querySupplyPlatformAuth") @ExtensionService("querySupplyPlatformAuth")
@Slf4j @Slf4j
@AllArgsConstructor @AllArgsConstructor
public class QuerySupplyPlatformAuthService extends SPIBaseService implements ExtensionServiceHandler<QuerySupplyPlatformAuthParam, QuerySupplyPlatformAuthData> { public class QuerySupplyPlatformAuthService extends SPIBaseService implements ExtensionServiceHandler<QuerySupplyPlatformAuthParam, JSONObject> {
private ShopService shopService; private ShopService shopService;
@Override @Override
public BaseResponse<QuerySupplyPlatformAuthData> handle(BaseRequest<QuerySupplyPlatformAuthParam> req) { public BaseResponse<JSONObject> handle(BaseRequest<QuerySupplyPlatformAuthParam> req) {
try { try {
QuerySupplyPlatformAuthParam param = req.getData(); QuerySupplyPlatformAuthParam param = req.getData();
QuerySupplyPlatformAuthData data = new QuerySupplyPlatformAuthData(); QuerySupplyPlatformAuthData data = new QuerySupplyPlatformAuthData();
shopService.querySupplyPlatformAuth(param, data); shopService.querySupplyPlatformAuth(param, data);
return BaseResponse.<QuerySupplyPlatformAuthData>builder().success(true).message("success").code("0").data(data).build(); return BaseResponse.<JSONObject>builder().success(true).message("success").code("0").data(JSON.parseObject(JSON.toJSONString(data))).build();
} catch (Exception e) { } catch (Exception e) {
return BaseResponse.<QuerySupplyPlatformAuthData>builder().success(true).message(e.getMessage()).code("100003").build(); return BaseResponse.<JSONObject>builder().success(true).message(e.getMessage()).code("100003").build();
} }
} }
} }
Loading…
Cancel
Save