package com.kxs.user.biz.mapper.old;

import com.baomidou.dynamic.datasource.annotation.DS;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.kxs.user.api.model.KxsPartner;
import com.kxs.user.api.model.KxsPartnerAmountLog;
import com.kxs.user.api.model.old.KxsMain;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

/**
 * 操作运营中心老库
 *
 * @author 没秃顶的码农
 * @date 2024-02-27
 */
@Mapper
@DS("KxsOpServer")
public interface KxsOpServerMapper extends BaseMapper<KxsMain> {


    /**
     * 扣除运营中心可提现额度
     *
     * @param partner 伙伴
     */
    void deductMakerUseAmount(KxsPartner partner);

    /**
     * 添加金额日志
     *
     * @param kxsPartner          KXS合伙人
     * @param partnerDeductAmount 扣款金额
     */
    void addAmountLog(@Param("param") KxsPartner kxsPartner, @Param("amountLog") KxsPartnerAmountLog partnerDeductAmount);
}
