aloha-vue 1.0.269 → 1.0.271

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.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "aloha-vue",
3
3
  "description": "Project aloha",
4
- "version": "1.0.269",
4
+ "version": "1.0.271",
5
5
  "author": "Ilia Brykin",
6
6
  "scripts": {
7
7
  "build-icons": "node scriptsNode/iconsSvgToJs.js bootstrap3 && node scriptsNode/iconsSvgToJs.js bootstrap-1-9-1"
@@ -350,7 +350,7 @@ export function setUrlForArray({ array, url, id }) {
350
350
  return url;
351
351
  }
352
352
  let URL = url || "";
353
- if (id === "fields") {
353
+ if (id === "fields" || id === "ordering") { // TODO: soll in plugin sein.
354
354
  if (URL) {
355
355
  URL += "&";
356
356
  }
@@ -15,29 +15,6 @@ const notifications = computed(() => {
15
15
  let notificationsCount = 0;
16
16
 
17
17
  export default function ANotificationAPI() {
18
- const removeNotification = notificationIndex => {
19
- if (notificationsObj.value[notificationIndex]) {
20
- delete notificationsObj.value[notificationIndex];
21
- }
22
- };
23
-
24
- const addNotification = ({ text, type = "success", timeout }) => {
25
- const TIMEOUT_LOCAL = timeout || notificationTimeout;
26
- const CURRENT_INDEX = notificationsCount;
27
- notificationsObj.value[CURRENT_INDEX] = {
28
- text,
29
- type,
30
- index: CURRENT_INDEX,
31
- };
32
- notificationsCount++;
33
-
34
- if (TIMEOUT_LOCAL) {
35
- setTimeout(() => {
36
- removeNotification(CURRENT_INDEX);
37
- }, TIMEOUT_LOCAL);
38
- }
39
- };
40
-
41
18
  const setNotificationTimeout = timeout => {
42
19
  notificationTimeout = timeout;
43
20
  };
@@ -49,3 +26,26 @@ export default function ANotificationAPI() {
49
26
  setNotificationTimeout,
50
27
  };
51
28
  }
29
+
30
+ export function addNotification({ text, type = "success", timeout }) {
31
+ const TIMEOUT_LOCAL = timeout || notificationTimeout;
32
+ const CURRENT_INDEX = notificationsCount;
33
+ notificationsObj.value[CURRENT_INDEX] = {
34
+ text,
35
+ type,
36
+ index: CURRENT_INDEX,
37
+ };
38
+ notificationsCount++;
39
+
40
+ if (TIMEOUT_LOCAL) {
41
+ setTimeout(() => {
42
+ removeNotification(CURRENT_INDEX);
43
+ }, TIMEOUT_LOCAL);
44
+ }
45
+ }
46
+
47
+ function removeNotification(notificationIndex) {
48
+ if (notificationsObj.value[notificationIndex]) {
49
+ delete notificationsObj.value[notificationIndex];
50
+ }
51
+ }