mirror of
https://github.com/lacerta-doc/Lacerta.git
synced 2024-11-26 09:43:15 +00:00
Dao修正
This commit is contained in:
parent
b87b635d2b
commit
253c77d6f5
|
@ -29,8 +29,8 @@ public interface DocumentDao {
|
|||
@Query("SELECT * FROM Document WHERE id IN (:ids)")
|
||||
List<DocumentEntity> findByIds(List<String> ids);
|
||||
|
||||
@Query("SELECT * FROM Document WHERE public_path = :publicPath LIMIT :limit")
|
||||
List<DocumentEntity> findByPublicPathWithLimit(String publicPath, int limit);
|
||||
@Query("SELECT * FROM Document WHERE parent_id = :parentId")
|
||||
List<DocumentEntity> findByParentId(String parentId);
|
||||
|
||||
@Query("SELECT * FROM Document ORDER BY created_at DESC LIMIT :limit")
|
||||
List<DocumentEntity> getRecentDocument(int limit);
|
||||
|
|
|
@ -15,11 +15,8 @@ public interface FolderDao {
|
|||
@Query("SELECT * FROM Folder WHERE id = :id")
|
||||
FolderEntity findById(String id);
|
||||
|
||||
@Query("SELECT * FROM Folder WHERE public_path = :publicPath")
|
||||
FolderEntity findByPublicPath(String publicPath);
|
||||
|
||||
@Query("SELECT * FROM Folder WHERE public_path = :publicPath LIMIT :limit")
|
||||
List<FolderEntity> findByPublicPathWithLimit(String publicPath, int limit);
|
||||
@Query("SELECT * FROM Folder WHERE parent_id = :parentId")
|
||||
List<FolderEntity> findByParentId(String parentId);
|
||||
|
||||
@Insert
|
||||
void insert(FolderEntity folderEntity);
|
||||
|
|
Loading…
Reference in New Issue
Block a user