mirror of
https://github.com/ansible/awx.git
synced 2026-03-16 08:27:29 -02:30
api.js refactor using classes (#250)
Refactor api.js into an api module where endpoint specific models can be imported and used in components.
This commit is contained in:
@@ -70,10 +70,6 @@ const defaultContexts = {
|
||||
toJSON: () => '/router/',
|
||||
},
|
||||
network: {
|
||||
api: {
|
||||
getConfig: () => {},
|
||||
toJSON: () => '/api/',
|
||||
},
|
||||
handleHttpError: () => {},
|
||||
},
|
||||
dialog: {}
|
||||
@@ -146,7 +142,6 @@ export function mountWithContexts (node, options = {}) {
|
||||
history: shape({}).isRequired,
|
||||
}),
|
||||
network: shape({
|
||||
api: shape({}).isRequired,
|
||||
handleHttpError: func.isRequired,
|
||||
}),
|
||||
dialog: shape({
|
||||
|
||||
Reference in New Issue
Block a user