package cn.com.ctop.kuaishou.modules.channel.service.impl;

import cn.com.ctop.kuaishou.modules.channel.entity.KuaishouChannelRel;
import cn.com.ctop.kuaishou.modules.channel.mapper.KuaishouChannelRelMapper;
import cn.com.ctop.kuaishou.modules.channel.service.IKuaishouChannelRelService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 渠道号绑定关系表
 *
 * @author jeecg-boot
 * 2021-09-06
 * @version V1.0
 */
@Service
public class KuaishouChannelRelServiceImpl extends ServiceImpl<KuaishouChannelRelMapper, KuaishouChannelRel> implements IKuaishouChannelRelService {
    @Autowired
    private KuaishouChannelRelMapper channelRelMapper;

    @Override
    public KuaishouChannelRel queryByAccountChannelCode(String channelCode, Long accountId, String appName) {
        return channelRelMapper.queryByAccountChannelCode(channelCode, accountId, appName);
    }

    @Override
    public Integer queryUsePlanCount(Long accountId, String channelCode) {
        return channelRelMapper.queryUsePlanCount(accountId, channelCode);
    }

    @Override
    public Integer queryUseGroupCount(Long accountId, String channelCode) {
        return channelRelMapper.queryUseGroupCount(accountId, channelCode);
    }
}
