2021-01-07 16:32:04 +00:00
|
|
|
import http from '@/api/http';
|
|
|
|
|
|
|
|
export interface VersionData {
|
|
|
|
panel: {
|
|
|
|
current: string;
|
|
|
|
latest: string;
|
2021-07-13 21:58:44 +00:00
|
|
|
}
|
2021-01-07 16:32:04 +00:00
|
|
|
|
|
|
|
wings: {
|
|
|
|
latest: string;
|
2021-07-13 21:58:44 +00:00
|
|
|
}
|
2021-01-07 16:32:04 +00:00
|
|
|
|
|
|
|
git: string | null;
|
|
|
|
}
|
|
|
|
|
|
|
|
export default (): Promise<VersionData> => {
|
|
|
|
return new Promise((resolve, reject) => {
|
|
|
|
http.get('/api/application/version')
|
|
|
|
.then(({ data }) => resolve(data))
|
|
|
|
.catch(reject);
|
|
|
|
});
|
|
|
|
};
|