package org.qinan.safetyeval.app.change.service.impl;

import com.alibaba.cola.dto.PageResponse;
import lombok.AllArgsConstructor;
import org.qinan.safetyeval.app.change.executor.command.QualFilingPersonnelChangeAddCmdExe;
import org.qinan.safetyeval.app.change.executor.command.QualFilingPersonnelChangeDelCmdExe;
import org.qinan.safetyeval.app.change.executor.command.QualFilingPersonnelChangeUpdateCmdExe;
import org.qinan.safetyeval.app.change.executor.query.QualFilingPersonnelChangeListQueryExe;
import org.qinan.safetyeval.app.change.executor.query.QualFilingPersonnelChangePageQueryExe;
import org.qinan.safetyeval.app.change.service.QualFilingPersonnelChangeServiceI;
import org.qinan.safetyeval.client.change.request.QualFilingPersonnelChangeAddCmd;
import org.qinan.safetyeval.client.change.request.QualFilingPersonnelChangePageQry;
import org.qinan.safetyeval.client.change.request.QualFilingPersonnelChangeUpdateCmd;
import org.qinan.safetyeval.client.change.response.QualFilingPersonnelChangeCo;
import org.springframework.stereotype.Service;

/**
 * 备案申请人员-变更
 *
 * @Author: ltq
 * @date 2026-07-02 10:04:33
 */
@Service
@AllArgsConstructor
public class QualFilingPersonnelChangeServiceImpl implements QualFilingPersonnelChangeServiceI {

    private final QualFilingPersonnelChangeListQueryExe qualFilingPersonnelChangeListQueryExe;
    private final QualFilingPersonnelChangeUpdateCmdExe qualFilingPersonnelChangeUpdateCommandExe;
    private final QualFilingPersonnelChangeAddCmdExe qualFilingPersonnelChangeAddCommandExe;
    private final QualFilingPersonnelChangeDelCmdExe qualFilingPersonnelChangeDelCommandExe;
    private final QualFilingPersonnelChangePageQueryExe qualFilingPersonnelChangePageQueryExe;

    @Override
    public PageResponse<QualFilingPersonnelChangeCo> listQualFilingPersonnelChangePage(QualFilingPersonnelChangePageQry qualFilingPersonnelChangePageQry) {
        return qualFilingPersonnelChangePageQueryExe.execute(qualFilingPersonnelChangePageQry);
    }

    @Override
    public QualFilingPersonnelChangeCo getQualFilingPersonnelChangeById(Long id) {
        return qualFilingPersonnelChangeListQueryExe.execute(id);
    }

    @Override
    public boolean saveQualFilingPersonnelChange(QualFilingPersonnelChangeAddCmd qualFilingPersonnelChangeAddCmd) {
        return qualFilingPersonnelChangeAddCommandExe.execute(qualFilingPersonnelChangeAddCmd);
    }

    @Override
    public boolean updateQualFilingPersonnelChange(QualFilingPersonnelChangeUpdateCmd qualFilingPersonnelChangeUpdateCmd) {
        return qualFilingPersonnelChangeUpdateCommandExe.execute(qualFilingPersonnelChangeUpdateCmd);
    }

    @Override
    public boolean deletedQualFilingPersonnelChangeById(Long id) {
        return qualFilingPersonnelChangeDelCommandExe.execute(id);
    }

    @Override
    public boolean deletedQualFilingPersonnelChangeByIds(Long[] ids) {
        return qualFilingPersonnelChangeDelCommandExe.execute(ids);
    }

}
