vikunja-frontend/src/services/labelTask.ts
Dominik Pschenitschni 1a11b43ca8 feat: improve models
2022-09-13 14:59:02 +00:00

17 lines
No EOL
436 B
TypeScript

import AbstractService from './abstractService'
import LabelTask from '@/models/labelTask'
import type {ILabelTask} from '@/modelTypes/ILabelTask'
export default class LabelTaskService extends AbstractService<ILabelTask> {
constructor() {
super({
create: '/tasks/{taskId}/labels',
getAll: '/tasks/{taskId}/labels',
delete: '/tasks/{taskId}/labels/{labelId}',
})
}
modelFactory(data) {
return new LabelTask(data)
}
}