oxymoron 1.0.4 → 1.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/app/assets/javascripts/oxymoron/config/states.js.erb +1 -5
- data/app/assets/javascripts/oxymoron/directives.js.erb +1 -1
- data/app/assets/javascripts/oxymoron/notifier.js.erb +5 -5
- data/app/assets/javascripts/oxymoron/services/sign.js +4 -10
- data/app/assets/javascripts/oxymoron/services.js.erb +2 -1
- data/lib/oxymoron/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: b8c055cf8d6022a6ef95cde952de2edb6ecd48f4
|
4
|
+
data.tar.gz: 7e247ce65c0af4727f02a9c6bab469dd50d5f6ca
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fcb1a9f0bca79762282e9fbb0968283adf9a830d14d341195019645f2ac6be10a5776dbd996cec52e121d8a881631d535a0e3c4b8d2907ec9270dfe59a082e03
|
7
|
+
data.tar.gz: f1264247051c55b07e171d7bdfded7faa600daebd34c26a959d40843f7509d2a52c6d543e99691b5e3666f7d1360665727ebbc251029d1d7bba488b53f741e80
|
@@ -45,11 +45,7 @@ angular.module("oxymoron.config.states", [])
|
|
45
45
|
<% unless value[:cache] %>
|
46
46
|
params['v']=(new Date()).getTime();
|
47
47
|
<% end %>
|
48
|
-
|
49
|
-
var query = _.omit($stateProvider.oxymoron_location.search(), _.keys(params));
|
50
|
-
params = angular.extend(query, params);
|
51
|
-
}
|
52
|
-
|
48
|
+
|
53
49
|
return Routes['<%= key %>_path'](params);
|
54
50
|
},
|
55
51
|
reloadOnSearch: true,
|
@@ -2,4 +2,4 @@
|
|
2
2
|
<%= render_oxymoron_assets "directives/fileupload.js"%>
|
3
3
|
<%= render_oxymoron_assets "directives/click_outside.js"%>
|
4
4
|
|
5
|
-
angular.module("oxymoron.directives", ['oxymoron.directives.fileupload', 'oxymoron.directives.contentFor', 'oxymoron.directives.
|
5
|
+
angular.module("oxymoron.directives", ['oxymoron.directives.fileupload', 'oxymoron.directives.contentFor', 'oxymoron.directives.clickOutside'])
|
@@ -1,5 +1,5 @@
|
|
1
1
|
angular.module("oxymoron.notifier", [])
|
2
|
-
.run(['$rootScope', 'ngNotify', 'Validate', '$state', '$http', '$location', function ($rootScope, ngNotify, Validate, $state, $http, $location) {
|
2
|
+
.run(['$rootScope', 'ngNotify', 'Validate', '$state', '$http', '$location', 'Notice', function ($rootScope, ngNotify, Validate, $state, $http, $location, Notice) {
|
3
3
|
ngNotify.config({
|
4
4
|
theme: 'pure',
|
5
5
|
position: 'top',
|
@@ -7,10 +7,10 @@ angular.module("oxymoron.notifier", [])
|
|
7
7
|
type: 'info'
|
8
8
|
});
|
9
9
|
|
10
|
-
|
10
|
+
var callback = function(type, res) {
|
11
11
|
if (res.data && angular.isObject(res.data)) {
|
12
12
|
if (res.data.msg || res.data.error) {
|
13
|
-
|
13
|
+
Notice.callback(type, res);
|
14
14
|
}
|
15
15
|
|
16
16
|
if (res.data.errors) {
|
@@ -30,11 +30,11 @@ angular.module("oxymoron.notifier", [])
|
|
30
30
|
}
|
31
31
|
|
32
32
|
$rootScope.$on('loading:finish', function (h, res) {
|
33
|
-
|
33
|
+
callback('success', res)
|
34
34
|
})
|
35
35
|
|
36
36
|
$rootScope.$on('loading:error', function (h, res, p) {
|
37
|
-
|
37
|
+
callback('error', res)
|
38
38
|
})
|
39
39
|
|
40
40
|
|
@@ -7,28 +7,22 @@ angular.module("oxymoron.services.sign", [])
|
|
7
7
|
.success(function () {
|
8
8
|
if (callback)
|
9
9
|
callback()
|
10
|
-
else
|
11
|
-
window.location = "/";
|
12
10
|
})
|
13
11
|
}
|
14
12
|
|
15
|
-
Sign.in = function (
|
16
|
-
$http.post(Routes.user_session_path(), {user:
|
13
|
+
Sign.in = function (user_params, callback) {
|
14
|
+
$http.post(Routes.user_session_path(), {user: user_params})
|
17
15
|
.success(function () {
|
18
16
|
if (callback)
|
19
17
|
callback();
|
20
|
-
else
|
21
|
-
window.location.reload();
|
22
18
|
})
|
23
19
|
}
|
24
20
|
|
25
|
-
Sign.up = function (
|
26
|
-
$http.post(Routes.user_registration_path(), {user:
|
21
|
+
Sign.up = function (user_params, callback) {
|
22
|
+
$http.post(Routes.user_registration_path(), {user: user_params})
|
27
23
|
.success(function () {
|
28
24
|
if (callback)
|
29
25
|
callback();
|
30
|
-
else
|
31
|
-
window.location.reload();
|
32
26
|
})
|
33
27
|
}
|
34
28
|
}])
|
@@ -2,5 +2,6 @@
|
|
2
2
|
<%= render_oxymoron_assets "services/resources.js.erb"%>
|
3
3
|
<%= render_oxymoron_assets "services/sign.js"%>
|
4
4
|
<%= render_oxymoron_assets "services/validate.js"%>
|
5
|
+
<%= render_oxymoron_assets "services/notice.js"%>
|
5
6
|
|
6
|
-
angular.module("oxymoron.services", ["oxymoron.services.interceptor", "oxymoron.services.resources", "oxymoron.services.sign", "oxymoron.services.validate"])
|
7
|
+
angular.module("oxymoron.services", ["oxymoron.services.interceptor", "oxymoron.services.notice", "oxymoron.services.resources", "oxymoron.services.sign", "oxymoron.services.validate"])
|
data/lib/oxymoron/version.rb
CHANGED