feat:补充启动时更新ticket逻辑
This commit is contained in:
@@ -442,6 +442,19 @@ public class AuthModel extends BaseModel implements IAuthModel {
|
||||
|
||||
}
|
||||
|
||||
public Single<TicketResult> refreshTicket() {
|
||||
return requestTicket()
|
||||
.subscribeOn(Schedulers.io())
|
||||
.observeOn(AndroidSchedulers.mainThread())
|
||||
.map(ticketResult -> {
|
||||
if (ticketResult.isSuccess()) {
|
||||
ticketInfo = ticketResult.getData();
|
||||
DemoCache.saveTicketInfo(ticketInfo);
|
||||
}
|
||||
return ticketResult;
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取tick
|
||||
*
|
||||
|
Reference in New Issue
Block a user