package com.liquidnet.service.goblin.service.impl;

import com.fasterxml.jackson.databind.ObjectMapper;
import com.liquidnet.service.goblin.param.shouqianba.*;
import com.liquidnet.service.goblin.param.shouqianba.response.data.CashierQueryData;
import com.liquidnet.service.goblin.param.shouqianba.response.data.OrderCreateData;
import com.liquidnet.service.goblin.param.shouqianba.response.data.SettlementCreateData;
import com.liquidnet.service.goblin.param.shouqianba.request.CashierQueryRequest;
import com.liquidnet.service.goblin.param.shouqianba.request.OrderCreateRequest;
import com.liquidnet.service.goblin.param.shouqianba.request.SettlementCreateRequest;
import com.liquidnet.service.goblin.param.shouqianba.response.SettlementCreateResponse;
import com.liquidnet.service.goblin.service.IGoblinShouQianBaService;
import lombok.extern.slf4j.Slf4j;
import org.apache.http.HttpEntity;
import org.apache.http.HttpStatus;
import org.apache.http.client.methods.CloseableHttpResponse;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.entity.StringEntity;
import org.apache.http.impl.client.CloseableHttpClient;
import org.apache.http.impl.client.HttpClients;
import org.apache.http.util.EntityUtils;
import org.springframework.stereotype.Service;

import java.io.IOException;

/**
 * 收钱吧对接实现类
 *
 * @author liquidnet
 * @since 2026-03-16
 */
@Slf4j
@Service
public class GoblinShouQianBaServiceImpl implements IGoblinShouQianBaService {

    private static final ObjectMapper objectMapper = new ObjectMapper();

    /**
     * 创建结算明细
     *
     * @param request 创建结算明细请求参数
     * @return 收钱吧响应结果；调用失败时返回 null
     */
    @Override
    public SettlementCreateData createSettlement(SettlementCreateRequest request) {
//        String url = ShouQianBaConstants.API_SETTLEMENT_CREATE;
//        log.info("[收钱吧] 创建结算明细 请求URL: {}, 请求参数: {}", url, request);
//
//        try {
//
//
//        } catch (Exception e) {
//            log.error("[收钱吧] 创建结算明细 发生异常，请求参数: {}", request, e);
//            return null;
//        }
        return null;
    }

    @Override
    public OrderCreateData createOrder(OrderCreateRequest request) {
        return null;

    }

    @Override
    public CashierQueryData queryCashier(CashierQueryRequest request) {

        return null;
    }
}
