package com.kxs.product.biz.controller.kxsapp;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.kxs.common.core.util.R;
import com.kxs.product.api.dto.kxsapp.merchant.ToMerchantMakerDTO;
import com.kxs.product.api.dto.kxsapp.merchant.MachineRatioDTO;
import com.kxs.product.api.dto.kxsapp.merchant.MerchantListDTO;
import com.kxs.product.api.vo.kxsapp.merchant.MerchantListVO;
import com.kxs.product.biz.service.KxsMachineService;
import com.kxs.product.biz.service.KxsMerchantService;
import lombok.RequiredArgsConstructor;
import org.springdoc.core.annotations.ParameterObject;
import org.springframework.web.bind.annotation.*;

/**
 * 我的商户(Merchant)控制层
 *
 * @author 系统
 * @since 2024-01-04 16:20:14
 */
@RestController
@RequiredArgsConstructor
@RequestMapping("merchant")
public class MerchantController {

    /**
     * 服务对象
     */
    private final KxsMerchantService kxsMerchantService;
    private final KxsMachineService kxsMachineService;



    /**
     * 汇总数据激活等
     *
     * @param brandId 品牌ID
     * @return 汇总数据激活等
     */
    @GetMapping("/merchantTotal")
    public R merchantTotal(@RequestParam("brandId") Integer brandId) {
        return R.ok();
    }


    /**
     * 商户列表
     *
     * @param page 分页对象
     * @param param 查询实体
     * @return 商户列表
     */
    @GetMapping("/merchantList")
    public R merchantList(@ParameterObject Page<MerchantListVO> page, @ParameterObject MerchantListDTO param) {
        return R.ok();
    }


    /**
     * 商户详情
     *
     * @param merchantId 商户ID
     * @return 商户详情
     */
    @GetMapping("/merchantDetail")
    public R merchantDetail(@RequestParam("merchantId") Object merchantId) {
        return R.ok();
    }


    /**
     * 费率调整
     *
     * @param param 实体对象
     * @return 费率调整
     */
    @PutMapping("/machineRatio")
    public R machineRatio(@RequestBody MachineRatioDTO param) {
        return R.ok();
    }



    /**
     * 转商户型创客
     *
     * @param param 实体对象
     * @return 转商户型创客
     */
    @PutMapping("/toMerchantMaker")
    public R toMerchantMaker(@RequestBody ToMerchantMakerDTO param) {
        return R.ok();
    }



}

