nestene 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/nestene/ui/public/app/application.js +11 -13
- data/lib/nestene/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: facb710eaed00cad18394e4f33e88e7415b4a011
|
4
|
+
data.tar.gz: 1cf8975444de2dd5856fcf5a6b38184f8062ca23
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0e3cc0fd36d888de1aaa58206bc0d2fa5715035a6242a815664a242f79ff6b91e77e40690b0784e8feee0ad49a9b2905c541554673f609e1cdc525d17ad2f574
|
7
|
+
data.tar.gz: 299a41329592441bf4808db484f81759b406911b73a960678ca394aa0fe7fc71973e4663ef0b2b24197574f8eb466d697ee91139671001a9d93b292ff3ebc04d
|
@@ -1,15 +1,13 @@
|
|
1
|
-
var
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
});
|
6
|
-
});
|
1
|
+
var window_location = window.location.pathname
|
2
|
+
|
3
|
+
|
4
|
+
var nestene = angular.module('nestene', ['JSONedit']);
|
7
5
|
|
8
|
-
nestene.controller('AutonsController', function($scope, $http, $timeout
|
6
|
+
nestene.controller('AutonsController', function($scope, $http, $timeout) {
|
9
7
|
$scope.autons=[];
|
10
8
|
|
11
9
|
$scope.getAutons = function() {
|
12
|
-
var autonsPromise = $http.get(
|
10
|
+
var autonsPromise = $http.get(window_location + "autons.json");
|
13
11
|
autonsPromise.success(function(data, status, headers, config) {
|
14
12
|
$scope.autons = data;
|
15
13
|
});
|
@@ -30,10 +28,10 @@ nestene.controller('AutonsController', function($scope, $http, $timeout, $locat
|
|
30
28
|
|
31
29
|
});
|
32
30
|
|
33
|
-
nestene.controller('CreateAutonFormController', function($scope,$http
|
31
|
+
nestene.controller('CreateAutonFormController', function($scope,$http) {
|
34
32
|
$scope.autonType = '';
|
35
33
|
$scope.createAuton = function() {
|
36
|
-
var postPromise = $http.post(
|
34
|
+
var postPromise = $http.post(window_location + "autons",{auton_type: $scope.autonType});
|
37
35
|
postPromise.success(function(data, status, headers, config) {
|
38
36
|
$.bootstrapGrowl("Created "+data['auton_id'], { type: 'success' });
|
39
37
|
});
|
@@ -43,13 +41,13 @@ nestene.controller('CreateAutonFormController', function($scope,$http, $location
|
|
43
41
|
};
|
44
42
|
});
|
45
43
|
|
46
|
-
nestene.controller('CredentialsController', function($scope,$http
|
44
|
+
nestene.controller('CredentialsController', function($scope,$http) {
|
47
45
|
$scope.credentials={};
|
48
46
|
$scope.loaded = false;
|
49
47
|
|
50
48
|
|
51
49
|
$scope.loadCredentials = function() {
|
52
|
-
var getPromise = $http.get(
|
50
|
+
var getPromise = $http.get(window_location + "credentials");
|
53
51
|
getPromise.success(function(data, status, headers, config) {
|
54
52
|
$scope.credentials = data;
|
55
53
|
$scope.loaded = true;
|
@@ -63,7 +61,7 @@ nestene.controller('CredentialsController', function($scope,$http, $location) {
|
|
63
61
|
$scope.loadCredentials();
|
64
62
|
|
65
63
|
$scope.storeCredentials = function() {
|
66
|
-
var postPromise = $http.post(
|
64
|
+
var postPromise = $http.post(window_location + "credentials",$scope.credentials);
|
67
65
|
postPromise.success(function(data, status, headers, config) {
|
68
66
|
$.bootstrapGrowl("Credentials saved", { type: 'success' });
|
69
67
|
});
|
data/lib/nestene/version.rb
CHANGED