jiazx0107@163.com
2023-09-22 5d1b6c9773e96c1c84040c18923f94942e2655cb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
package com.fzzy.sys.repository;
 
import com.fzzy.sys.entity.SysUrl;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;
 
import java.util.List;
 
public interface UrlRepository extends JpaRepository<SysUrl, String> {
 
 
    @Query("from SysUrl where parentId is null order by orderTag asc")
    List<SysUrl> listUrl();
 
    @Query("from SysUrl where parentId=:parentId order by orderTag asc")
    List<SysUrl> listUrlByParent(@Param("parentId") String parentId);
 
 
}