package com.hzya.frame.seeyon.dao.impl;

import com.baomidou.dynamic.datasource.annotation.DS;
import com.hzya.frame.basedao.dao.MybatisGenericDao;
import com.hzya.frame.seeyon.dao.ICtpAttachmentDao;
import com.hzya.frame.seeyon.entity.CtpAttachmentEntity;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository(value = "ctpAttachmentDaoImpl")
public class
CtpAttachmentDaoImpl extends MybatisGenericDao<CtpAttachmentEntity,String> implements ICtpAttachmentDao {
    @DS("ht_oa_sqlserver")
    @Override
    public int updateCtpAttachment(CtpAttachmentEntity ctpAttachmentEntity) {
        return super.update("com.hzya.frame.seeyon.dao.impl.CtpAttachmentDaoImpl.entity_update",ctpAttachmentEntity);
    }

    @DS("ht_oa_sqlserver")
    @Override
    public List<CtpAttachmentEntity> queryCtpAttachment(CtpAttachmentEntity ctpAttachmentEntity) {
        return (List<CtpAttachmentEntity>) super.selectList("com.hzya.frame.seeyon.dao.impl.CtpAttachmentDaoImpl.entity_list_base",ctpAttachmentEntity);
    }

    @DS("ht_oa_sqlserver")
    @Override
    public CtpAttachmentEntity saveCtpAttachment(CtpAttachmentEntity ctpAttachmentEntity) {
        return super.save("com.hzya.frame.seeyon.dao.impl.CtpAttachmentDaoImpl.entity_insert",ctpAttachmentEntity);
    }
}
