2020-06-09 02:43:32 +00:00
|
|
|
angular.module('portainer.azure').factory('ResourceGroup', [
|
|
|
|
'$resource',
|
|
|
|
'API_ENDPOINT_ENDPOINTS',
|
|
|
|
'EndpointProvider',
|
|
|
|
function ResourceGroupFactory($resource, API_ENDPOINT_ENDPOINTS, EndpointProvider) {
|
|
|
|
'use strict';
|
|
|
|
return $resource(
|
2020-07-20 21:08:20 +00:00
|
|
|
API_ENDPOINT_ENDPOINTS + '/:endpointId/azure/subscriptions/:subscriptionId/resourcegroups/:resourceGroupName',
|
2020-06-09 02:43:32 +00:00
|
|
|
{
|
|
|
|
endpointId: EndpointProvider.endpointID,
|
|
|
|
'api-version': '2018-02-01',
|
|
|
|
},
|
|
|
|
{
|
|
|
|
query: { method: 'GET', params: { subscriptionId: '@subscriptionId' } },
|
2020-07-20 21:08:20 +00:00
|
|
|
get: { method: 'GET' },
|
2020-06-09 02:43:32 +00:00
|
|
|
}
|
|
|
|
);
|
|
|
|
},
|
|
|
|
]);
|