fix: spliting out the project members from project store and service (#2739)
This commit is contained in:
parent
7676aab773
commit
79df59f618
66 changed files with 496 additions and 415 deletions
|
|
@ -1,38 +0,0 @@
|
|||
import { APIService } from "services/api.service";
|
||||
import { TrackEventService } from "services/track_event.service";
|
||||
// types
|
||||
import { IUser } from "types";
|
||||
// helpers
|
||||
import { API_BASE_URL } from "helpers/common.helper";
|
||||
|
||||
const trackEventService = new TrackEventService();
|
||||
|
||||
export class ProjectExportService extends APIService {
|
||||
constructor() {
|
||||
super(API_BASE_URL);
|
||||
}
|
||||
|
||||
async csvExport(
|
||||
workspaceSlug: string,
|
||||
data: {
|
||||
provider: string;
|
||||
project: string[];
|
||||
},
|
||||
user: IUser
|
||||
): Promise<any> {
|
||||
return this.post(`/api/workspaces/${workspaceSlug}/export-issues/`, data)
|
||||
.then((response) => {
|
||||
trackEventService.trackExporterEvent(
|
||||
{
|
||||
workspaceSlug,
|
||||
},
|
||||
"CSV_EXPORTER_CREATE",
|
||||
user
|
||||
);
|
||||
return response?.data;
|
||||
})
|
||||
.catch((error) => {
|
||||
throw error?.response?.data;
|
||||
});
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue