PatchVersionDao.java
963 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
package com.brframework.webapppatch.dao;
import com.brframework.commondb.core.CommonRepository;
import com.brframework.webapppatch.entity.PatchVersion;
import org.springframework.stereotype.Repository;
/**
* 热更新版本
* @author xu
* @date 2019/11/14 10:27
*/
@Repository
public interface PatchVersionDao extends CommonRepository<Long, PatchVersion> {
/**
* 查询version最大的一条记录
* @param os
* @param branch
* @return
*/
PatchVersion findTop1ByOsAndBranchOrderByVersionDesc(String os, String branch);
/**
* 查询某一种状态下version最大的一条记录
* @param os
* @param branch
* @param updateStatus
* @return
*/
PatchVersion findTop1ByOsAndBranchAndUpdateStatusOrderByVersionDesc(String os, String branch, Integer updateStatus);
/**
* 通过分支删除版本
* @param branch
* @return
*/
int deleteByBranch(String branch);
}