package com.zcloud.primeport.service;

import com.zcloud.primeport.api.EVehicleArrivalDepartureInfoServiceI;
import com.zcloud.primeport.command.EVehicleArrivalDepartureInfoAddExe;
import com.zcloud.primeport.command.EVehicleArrivalDepartureInfoRemoveExe;
import com.zcloud.primeport.command.EVehicleArrivalDepartureInfoUpdateExe;
import com.zcloud.primeport.command.query.EVehicleArrivalDepartureInfoQueryExe;
import com.zcloud.primeport.dto.EVehicleArrivalDepartureInfoAddCmd;
import com.zcloud.primeport.dto.EVehicleArrivalDepartureInfoPageQry;
import com.zcloud.primeport.dto.EVehicleArrivalDepartureInfoUpdateCmd;
import com.zcloud.primeport.dto.clientobject.EVehicleArrivalDepartureInfoCO;

import com.alibaba.cola.dto.PageResponse;
import com.alibaba.cola.dto.SingleResponse;
import lombok.AllArgsConstructor;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * web-app
 *
 * @Author dearLin
 * @Date 2026-05-27 17:45:44
 */
@Service
@AllArgsConstructor
public class EVehicleArrivalDepartureInfoServiceImpl implements EVehicleArrivalDepartureInfoServiceI {
    private final EVehicleArrivalDepartureInfoAddExe eVehicleArrivalDepartureInfoAddExe;
    private final EVehicleArrivalDepartureInfoUpdateExe eVehicleArrivalDepartureInfoUpdateExe;
    private final EVehicleArrivalDepartureInfoRemoveExe eVehicleArrivalDepartureInfoRemoveExe;
    private final EVehicleArrivalDepartureInfoQueryExe eVehicleArrivalDepartureInfoQueryExe;

    @Override
    public EVehicleArrivalDepartureInfoCO queryById(Long id) {
        return eVehicleArrivalDepartureInfoQueryExe.queryById(id);
    }

    @Override
    public PageResponse<EVehicleArrivalDepartureInfoCO> listPage(EVehicleArrivalDepartureInfoPageQry qry) {

        return eVehicleArrivalDepartureInfoQueryExe.execute(qry);
    }

    @Override
    public SingleResponse add(EVehicleArrivalDepartureInfoAddCmd cmd) {

        eVehicleArrivalDepartureInfoAddExe.execute(cmd);
        return SingleResponse.buildSuccess();
    }

    @Override
    public void edit(EVehicleArrivalDepartureInfoUpdateCmd eVehicleArrivalDepartureInfoUpdateCmd) {
        eVehicleArrivalDepartureInfoUpdateExe.execute(eVehicleArrivalDepartureInfoUpdateCmd);
    }

    @Override
    public void remove(Long id) {
        eVehicleArrivalDepartureInfoRemoveExe.execute(id);
    }

    @Override
    public void removeBatch(List<Long> ids) {
        eVehicleArrivalDepartureInfoRemoveExe.execute(ids);
    }
}

