| 12345678910111213141516171819202122232425 |
- var app = angular.module('sentinelDashboardApp');
- app.service('MachineService', ['$http', '$httpParamSerializerJQLike',
- function ($http, $httpParamSerializerJQLike) {
- this.getAppMachines = function (app) {
- return $http({
- url: 'app/' + app + '/machines.json',
- method: 'GET'
- });
- };
- this.removeAppMachine = function (app, ip, port) {
- return $http({
- url: 'app/' + app + '/machine/remove.json',
- method: 'POST',
- headers: {
- 'Content-type': 'application/x-www-form-urlencoded; charset=UTF-8'
- },
- data: $httpParamSerializerJQLike({
- ip: ip,
- port: port
- })
- });
- };
- }]
- );
|