From 54f9dd5e9830002c9bf0b09317b7ad64cd798b1f Mon Sep 17 00:00:00 2001 From: Marliana Lara Date: Wed, 12 Jun 2019 16:52:42 -0400 Subject: [PATCH] Add Job API model --- src/api/index.js | 3 +++ src/api/models/Jobs.js | 10 ++++++++++ 2 files changed, 13 insertions(+) create mode 100644 src/api/models/Jobs.js diff --git a/src/api/index.js b/src/api/index.js index 018ae790d4..418b150b04 100644 --- a/src/api/index.js +++ b/src/api/index.js @@ -1,5 +1,6 @@ import Config from './models/Config'; import InstanceGroups from './models/InstanceGroups'; +import Jobs from './models/Jobs'; import Me from './models/Me'; import Organizations from './models/Organizations'; import Root from './models/Root'; @@ -9,6 +10,7 @@ import Users from './models/Users'; const ConfigAPI = new Config(); const InstanceGroupsAPI = new InstanceGroups(); +const JobsAPI = new Jobs(); const MeAPI = new Me(); const OrganizationsAPI = new Organizations(); const RootAPI = new Root(); @@ -19,6 +21,7 @@ const UsersAPI = new Users(); export { ConfigAPI, InstanceGroupsAPI, + JobsAPI, MeAPI, OrganizationsAPI, RootAPI, diff --git a/src/api/models/Jobs.js b/src/api/models/Jobs.js new file mode 100644 index 0000000000..cea169b72a --- /dev/null +++ b/src/api/models/Jobs.js @@ -0,0 +1,10 @@ +import Base from '../Base'; + +class Jobs extends Base { + constructor (http) { + super(http); + this.baseUrl = '/api/v2/jobs/'; + } +} + +export default Jobs;