package com.pcloud.book.adnews.dao.impl;

import com.pcloud.book.adnews.dao.AdNewsBanDao;
import com.pcloud.book.adnews.entity.AdNewsBan;
import com.pcloud.common.core.dao.BaseDaoImpl;
import org.springframework.stereotype.Repository;

import java.util.HashMap;
import java.util.Map;

/**
 * @author zhengyongqiang
 * @date 2019/8/12 15:11
 */
@Repository("adnewsBanDao")
public class AdNewsBanDaoImpl extends BaseDaoImpl<AdNewsBan> implements AdNewsBanDao {

    @Override
    public void deleteByAdNewsId(Long partyId, Long adNewsId) {
        Map<String,Object> map = new HashMap<>();
        map.put("partyId",partyId);
        map.put("adNewsId",adNewsId);
        super.getSqlSession().delete(getStatement("deleteByAdNewsId"),map);
    }
}
