/*
 * Copyright (c) 京北方信息技术股份有限公司 Corporation 2021 . All rights reserved.
 *
 */
package net.northking.cctp.dw.db.impl;

import net.northking.cctp.common.db.BasicDao;
import net.northking.cctp.common.db.PaginationService;
import net.northking.cctp.dw.db.dao.CaseDesignCompleteDetailsDao;
import net.northking.cctp.dw.db.entity.CaseDesignCompleteDetails;
import net.northking.cctp.dw.db.service.CaseDesignCompleteDetailsService;
import net.northking.cctp.dw.dto.DwCaseDesignInfoDto;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.stereotype.Service;


/**
 * 用例设计完成详情（按人员或模块）,包括周、日
 *
 * <p>文件内容由代码生成器产生，请不要手动修改！ <br>
 * createdate:  2021-12-15 09:37:20  <br>
 *
 * @author: maven-cctp-plugin  <br>
 * @since: 1.0 <br>
 */
@Service
@ConditionalOnMissingBean(name = "CaseDesignCompleteDetailsServiceImpl")
public class CaseDesignCompleteDetailsServiceImpl extends PaginationService<CaseDesignCompleteDetails> implements CaseDesignCompleteDetailsService {

    private static final Logger logger = LoggerFactory.getLogger(CaseDesignCompleteDetailsServiceImpl.class);

    private final CaseDesignCompleteDetailsDao caseDesignCompleteDetailsDao;

    public CaseDesignCompleteDetailsServiceImpl(CaseDesignCompleteDetailsDao caseDesignCompleteDetailsDao) {
        this.caseDesignCompleteDetailsDao = caseDesignCompleteDetailsDao;
    }

    public BasicDao<CaseDesignCompleteDetails> getDao() {
        return caseDesignCompleteDetailsDao;
    }

    public CaseDesignCompleteDetails createEntity() {
        return new CaseDesignCompleteDetails();
    }

    @Override
    protected void beforeInsert(CaseDesignCompleteDetails caseDesignCompleteDetails) {

    }

    @Override
    protected void beforeUpdate(CaseDesignCompleteDetails caseDesignCompleteDetails) {

    }

    @Override
    public Integer caseDesignComplete(DwCaseDesignInfoDto dwCaseDesignInfoDto) {
        return caseDesignCompleteDetailsDao.caseDesignComplete(dwCaseDesignInfoDto);
    }

    @Override
    public Integer deleteCompleteByProjectIds(DwCaseDesignInfoDto dwCaseDesignInfoDto) {
        return caseDesignCompleteDetailsDao.deleteCompleteByProjectIds(dwCaseDesignInfoDto);
    }

}

