package cn.pluss.platform.klk.controller;

import cn.hutool.json.JSONUtil;
import cn.pluss.platform.klk.service.LklPayService;
import cn.pluss.platform.klk.service.impl.LaKalaInterfaceImpl;
import cn.pluss.platform.klk.vo.TuoKeVo;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;

import javax.annotation.Resource;
import java.io.File;
import java.io.IOException;
import java.util.Map;

@RestController
@RequestMapping("/lkl")
public class LaKaLaController {
    @Resource
    LaKalaInterfaceImpl laKalaInterface;


    @Resource
    LklPayService lklPayService;

    @PostMapping("/jjkls")
    public void jjkls(){
            laKalaInterface.ff();
    }
    @PostMapping("/tuoke")
    public void jjklss(@RequestParam("userId") String userId){
        laKalaInterface.merchAuditFee(userId);
    }



    @RequestMapping("/tradeCallBack")
    public void tradeCallBack(@RequestBody Map<String,Object> map){
        System.out.println("拉卡拉交易回调:"+ JSONUtil.toJsonStr(map));
    }

    @GetMapping("/querySubMerInfo")
    public String querySubMerInfo(String orgCode,String merInnerNo,String merCupNo){
        return lklPayService.querySubMerInfo(orgCode, merInnerNo,merCupNo);
    }


}
