2018-10-15 14:42:47 +05:30
|
|
|
import axios from '../../lib/utils/axios_utils';
|
2017-08-17 22:00:37 +05:30
|
|
|
|
|
|
|
export default class PipelineService {
|
|
|
|
constructor(endpoint) {
|
2018-10-15 14:42:47 +05:30
|
|
|
this.pipeline = endpoint;
|
2017-08-17 22:00:37 +05:30
|
|
|
}
|
|
|
|
|
|
|
|
getPipeline() {
|
2018-10-15 14:42:47 +05:30
|
|
|
return axios.get(this.pipeline);
|
2017-08-17 22:00:37 +05:30
|
|
|
}
|
2017-09-10 17:25:29 +05:30
|
|
|
|
2018-10-15 14:42:47 +05:30
|
|
|
// eslint-disable-next-line class-methods-use-this
|
2017-09-10 17:25:29 +05:30
|
|
|
postAction(endpoint) {
|
2018-10-15 14:42:47 +05:30
|
|
|
return axios.post(`${endpoint}.json`);
|
2017-09-10 17:25:29 +05:30
|
|
|
}
|
2017-08-17 22:00:37 +05:30
|
|
|
}
|