package com.northglass.repository;
|
|
|
import java.util.List;
|
|
import org.springframework.data.jpa.repository.JpaRepository;
|
import org.springframework.data.jpa.repository.Modifying;
|
import org.springframework.data.jpa.repository.Query;
|
|
import com.northglass.entity.MachineFont;
|
import com.northglass.entity.MachineMessage;
|
|
public interface MachineMessageDao extends JpaRepository<MachineMessage, Long>{
|
/*@Query("select t from MachineMessage t where t.machineId = ?1")
|
public MachineMessage findMachineMessage(Long Machineid);
|
|
@Modifying
|
@Query("delete from MachineMessage t where t.machineId = ?1")
|
public void deleMachineMessageId(Long id);*/
|
|
//查询对应机器的 对应字
|
@Query("select t from MachineMessage t where t.machine.id = 1 and t.message = '000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000' and t.modTime = '2021-09-07 11:20:45' ")
|
public List<MachineMessage> findMachineDispose();
|
|
@Query("select t from MachineMessage t where t.machine.id = ?1 ")
|
public MachineMessage findmachineid(Long machineid);
|
}
|