* fix: refactoring * fix: site ssr implementation * chore: fixed auto reload on file change in sites * chore: updated constant imports and globalised powerBy component * chore: resolved lint and updated the env --------- Co-authored-by: sriram veeraghanta <veeraghanta.sriram@gmail.com>
19 lines
507 B
TypeScript
19 lines
507 B
TypeScript
import { API_BASE_URL } from "@plane/constants";
|
|
// services
|
|
import { APIService } from "@/services/api.service";
|
|
// types
|
|
import { TPublicCycle } from "@/types/cycle";
|
|
|
|
export class CycleService extends APIService {
|
|
constructor() {
|
|
super(API_BASE_URL);
|
|
}
|
|
|
|
async getCycles(anchor: string): Promise<TPublicCycle[]> {
|
|
return this.get(`/api/public/anchor/${anchor}/cycles/`)
|
|
.then((response) => response?.data)
|
|
.catch((error) => {
|
|
throw error?.response?.data;
|
|
});
|
|
}
|
|
}
|