package com.sw.mes.fls.dao;


import com.sw.mes.core.base.BaseDao;
import com.sw.mes.fls.entity.TempTurnstoreTray;
import org.springframework.data.jpa.repository.Query;

import java.util.List;

/**
* @Author
* @Description：
* @Date:
* @Modified By:
*/
public interface TempTurnstoreTrayDao extends BaseDao<TempTurnstoreTray, Integer> {

    @Query(value = "SELECT tt.* FROM temp_turnstore_tray tt WHERE tt.tray_name = ?1 AND tt.finished = 0 ORDER BY tt.create_time DESC", nativeQuery = true)
    List<TempTurnstoreTray> findByTrayName(String trayName);
}
