nestene 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 81521af0e0b6695d8c7556237f7104649465766f
4
- data.tar.gz: 60956c6779b72207e76601a85b374b61ca5d54e1
3
+ metadata.gz: aa9f71edf16482fe6707c20f9e3fd600f13b2c8c
4
+ data.tar.gz: f24fe63fceed837433582f04af7d6cf0b40adcc2
5
5
  SHA512:
6
- metadata.gz: 7912c6b33dcaebb789587467ecabbdb121f7b4d57c16e7203d83be7afb99c2c2cf174496bf89039cad470efa04cd33291628d6e3a33153a163f3609d14aebece
7
- data.tar.gz: fa0a38994bfdd94a786d466a801a03b6c9740453d6e1a1aed1f3ac9ec131b4f01ba50a0a4dbcd3d5936953c567dd64e4117f4792a5d4b622653ad89ca2c8776b
6
+ metadata.gz: db1c7efb6ae1314420a342e5c00769df6b951ff5720004bc2034bf35d3897c508b1524558b7f572109e725c8050c98d213dc5eff7abe91a30fddcb8209aac2fe
7
+ data.tar.gz: 5e7f3c0cdd9ed88d7995a74555f6183ea125338985f144b6ee5f22c0d001963ff5dd0d1ac5b599ec63e450c44e18e3983516dec7715c99b63d1d08fcc57131a4
@@ -1,10 +1,15 @@
1
- var nestene = angular.module('nestene', ['JSONedit']);
1
+ var nestene = angular.module('nestene', ['JSONedit']).config(function($locationProvider) {
2
+ $locationProvider.html5Mode({
3
+ enabled: true,
4
+ requireBase: false
5
+ });
6
+ });
2
7
 
3
- nestene.controller('AutonsController', function($scope, $http, $timeout) {
8
+ nestene.controller('AutonsController', function($scope, $http, $timeout, $location) {
4
9
  $scope.autons=[];
5
10
 
6
11
  $scope.getAutons = function() {
7
- var autonsPromise = $http.get("autons.json");
12
+ var autonsPromise = $http.get($location.path() + "autons.json");
8
13
  autonsPromise.success(function(data, status, headers, config) {
9
14
  $scope.autons = data;
10
15
  });
@@ -25,10 +30,10 @@ nestene.controller('AutonsController', function($scope, $http, $timeout) {
25
30
 
26
31
  });
27
32
 
28
- nestene.controller('CreateAutonFormController', function($scope,$http) {
33
+ nestene.controller('CreateAutonFormController', function($scope,$http, $location) {
29
34
  $scope.autonType = '';
30
35
  $scope.createAuton = function() {
31
- var postPromise = $http.post("autons",{auton_type: $scope.autonType});
36
+ var postPromise = $http.post($location.path() + "autons",{auton_type: $scope.autonType});
32
37
  postPromise.success(function(data, status, headers, config) {
33
38
  $.bootstrapGrowl("Created "+data['auton_id'], { type: 'success' });
34
39
  });
@@ -38,13 +43,13 @@ nestene.controller('CreateAutonFormController', function($scope,$http) {
38
43
  };
39
44
  });
40
45
 
41
- nestene.controller('CredentialsController', function($scope,$http) {
46
+ nestene.controller('CredentialsController', function($scope,$http, $location) {
42
47
  $scope.credentials={};
43
48
  $scope.loaded = false;
44
49
 
45
50
 
46
51
  $scope.loadCredentials = function() {
47
- var getPromise = $http.get("credentials");
52
+ var getPromise = $http.get($location.path() + "credentials");
48
53
  getPromise.success(function(data, status, headers, config) {
49
54
  $scope.credentials = data;
50
55
  $scope.loaded = true;
@@ -58,7 +63,7 @@ nestene.controller('CredentialsController', function($scope,$http) {
58
63
  $scope.loadCredentials();
59
64
 
60
65
  $scope.storeCredentials = function() {
61
- var postPromise = $http.post("credentials",$scope.credentials);
66
+ var postPromise = $http.post($location.path() + "credentials",$scope.credentials);
62
67
  postPromise.success(function(data, status, headers, config) {
63
68
  $.bootstrapGrowl("Credentials saved", { type: 'success' });
64
69
  });
@@ -1,3 +1,3 @@
1
1
  module Nestene
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nestene
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dragan Milic