package com.tykj.dev.device.sendback.repository;

import com.tykj.dev.device.sendback.entity.domain.DeviceRepel;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Modifying;
import org.springframework.data.jpa.repository.Query;

import java.util.List;

public interface DeviceRepelDao extends JpaRepository<DeviceRepel, Integer>, JpaSpecificationExecutor<DeviceRepel> {
   @Modifying
   @Query(value = "update DeviceRepel d set d.deleteTag = ?1 where d.id in ?2")
   int updateDeviceRepelIsDelByIds(Integer deleteTag, List<Integer> ids);
}
