@projectcaluma/ember-distribution 1.0.0-beta.9 → 11.0.0-beta.24

Sign up to get free protection for your applications and to get access to all the features.
Files changed (49) hide show
  1. package/CHANGELOG.md +70 -0
  2. package/addon/abilities/distribution.js +19 -0
  3. package/addon/abilities/inquiry.js +20 -0
  4. package/addon/components/cd-document-header.hbs +8 -8
  5. package/addon/components/cd-inquiry-answer-form.hbs +21 -13
  6. package/addon/components/cd-inquiry-answer-form.js +24 -10
  7. package/addon/components/cd-inquiry-dialog/inquiry-deadline.hbs +6 -13
  8. package/addon/components/cd-inquiry-dialog/inquiry-divider.hbs +1 -1
  9. package/addon/components/cd-inquiry-dialog/inquiry-part.hbs +27 -11
  10. package/addon/components/cd-inquiry-dialog/inquiry-part.js +10 -0
  11. package/addon/components/cd-inquiry-dialog/inquiry.hbs +8 -4
  12. package/addon/components/cd-inquiry-dialog.hbs +12 -6
  13. package/addon/components/cd-inquiry-dialog.js +1 -0
  14. package/addon/components/cd-inquiry-edit-form.hbs +19 -2
  15. package/addon/components/cd-inquiry-new-form.hbs +32 -30
  16. package/addon/components/cd-inquiry-new-form.js +1 -3
  17. package/addon/components/cd-navigation/controls.hbs +46 -21
  18. package/addon/components/cd-navigation/controls.js +34 -9
  19. package/addon/components/cd-navigation/item.hbs +14 -11
  20. package/addon/components/cd-navigation/section.hbs +4 -4
  21. package/addon/components/cd-navigation/status-indicator.hbs +10 -15
  22. package/addon/components/cd-navigation.hbs +11 -14
  23. package/addon/config.js +11 -7
  24. package/addon/engine.js +3 -1
  25. package/addon/gql/fragments/inquiry.graphql +21 -4
  26. package/addon/gql/mutations/complete-inquiry-work-item.graphql +1 -1
  27. package/addon/gql/mutations/redo-work-item.graphql +8 -0
  28. package/addon/gql/queries/control-work-items.graphql +11 -0
  29. package/addon/gql/queries/inquiry-answer.graphql +3 -12
  30. package/addon/gql/queries/inquiry-dialog.graphql +2 -1
  31. package/addon/services/distribution.js +9 -1
  32. package/addon/templates/application.hbs +1 -0
  33. package/addon/utils/inquiry-answer-status.js +34 -0
  34. package/addon/utils/inquiry-deadline.js +4 -4
  35. package/addon/utils/inquiry-status.js +12 -7
  36. package/app/styles/@projectcaluma/ember-distribution.scss +1 -2
  37. package/app/styles/_group-list.scss +7 -0
  38. package/app/styles/_inquiry-divider.scss +1 -1
  39. package/app/utils/inquiry-answer-status.js +1 -0
  40. package/index.js +1 -6
  41. package/package.json +20 -21
  42. package/translations/de.yaml +24 -4
  43. package/translations/en.yaml +25 -5
  44. package/translations/fr.yaml +25 -5
  45. package/addon/components/cd-icon-button.hbs +0 -27
  46. package/addon/components/cd-icon-button.js +0 -22
  47. package/app/components/cd-icon-button.js +0 -1
  48. package/app/styles/_icon-button.scss +0 -13
  49. package/app/styles/_status-indicator.scss +0 -31
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@projectcaluma/ember-distribution",
3
- "version": "1.0.0-beta.9",
3
+ "version": "11.0.0-beta.24",
4
4
  "description": "Ember engine for the Caluma distribution module.",
5
5
  "keywords": [
6
6
  "ember-addon",
@@ -19,39 +19,38 @@
19
19
  },
20
20
  "dependencies": {
21
21
  "@ember/string": "^3.0.0",
22
- "@embroider/macros": "^1.6.0",
22
+ "@embroider/macros": "^1.8.3",
23
23
  "@glimmer/component": "^1.1.2",
24
24
  "@glimmer/tracking": "^1.1.2",
25
- "@projectcaluma/ember-core": "^11.0.0-beta.7",
26
- "@projectcaluma/ember-form": "^11.0.0-beta.19",
27
- "@projectcaluma/ember-workflow": "^11.0.0-beta.7",
28
- "ember-apollo-client": "^4.0.2",
29
- "ember-auto-import": "^2.4.1",
25
+ "@projectcaluma/ember-core": "^11.0.0-beta.24",
26
+ "@projectcaluma/ember-form": "^11.0.0-beta.24",
27
+ "@projectcaluma/ember-workflow": "^11.0.0-beta.24",
28
+ "ember-apollo-client": "~4.0.2",
29
+ "ember-auto-import": "^2.4.2",
30
30
  "ember-can": "^4.2.0",
31
31
  "ember-cli-babel": "^7.26.11",
32
- "ember-cli-htmlbars": "^6.0.1",
33
- "ember-concurrency": "^2.2.1",
32
+ "ember-cli-htmlbars": "^6.1.0",
33
+ "ember-concurrency": "^2.3.2",
34
34
  "ember-engines-router-service": "^0.3.0",
35
- "ember-fetch": "^8.1.1",
35
+ "ember-fetch": "^8.1.2",
36
36
  "ember-intl": "^5.7.2",
37
37
  "ember-pikaday": "^4.0.0",
38
- "ember-resources": "^4.7.1",
38
+ "ember-resources": "^5.2.1",
39
39
  "ember-svg-jar": "^2.3.4",
40
40
  "ember-test-selectors": "^6.0.0",
41
41
  "ember-uikit": "^5.1.3",
42
42
  "graphql": "^15.8.0",
43
43
  "graphql-tag": "^2.12.6",
44
- "ionicons": "^6.0.1",
45
44
  "lodash.merge": "^4.6.2",
46
- "luxon": "^2.4.0",
45
+ "luxon": "^3.0.1",
47
46
  "tracked-toolbox": "^1.2.3"
48
47
  },
49
48
  "devDependencies": {
50
49
  "@ember/optional-features": "2.0.0",
51
- "@ember/test-helpers": "2.7.0",
52
- "@embroider/test-setup": "1.6.0",
53
- "@faker-js/faker": "6.3.1",
54
- "@projectcaluma/ember-testing": "11.0.0-beta.7",
50
+ "@ember/test-helpers": "2.8.1",
51
+ "@embroider/test-setup": "1.8.3",
52
+ "@faker-js/faker": "7.4.0",
53
+ "@projectcaluma/ember-testing": "11.0.0-beta.24",
55
54
  "broccoli-asset-rev": "3.0.0",
56
55
  "ember-cli": "3.28.5",
57
56
  "ember-cli-code-coverage": "1.0.3",
@@ -62,7 +61,7 @@
62
61
  "ember-cli-sri": "2.1.1",
63
62
  "ember-cli-terser": "4.0.2",
64
63
  "ember-disable-prototype-extensions": "1.1.3",
65
- "ember-engines": "0.8.22",
64
+ "ember-engines": "0.8.23",
66
65
  "ember-export-application-global": "2.0.1",
67
66
  "ember-load-initializers": "2.1.2",
68
67
  "ember-maybe-import-regenerator": "1.0.0",
@@ -72,12 +71,12 @@
72
71
  "ember-source-channel-url": "3.0.0",
73
72
  "ember-try": "2.0.0",
74
73
  "loader.js": "4.7.0",
75
- "miragejs": "0.1.43",
74
+ "miragejs": "0.1.45",
76
75
  "npm-run-all": "4.1.5",
77
76
  "qunit": "2.19.1",
78
77
  "qunit-dom": "2.0.0",
79
- "sass": "1.51.0",
80
- "webpack": "5.72.0"
78
+ "sass": "1.54.5",
79
+ "webpack": "5.74.0"
81
80
  },
82
81
  "engines": {
83
82
  "node": "12.* || 14.* || >= 16"
@@ -3,33 +3,52 @@ caluma:
3
3
  empty: "Es wurden noch keine Anfragen erstellt."
4
4
  start: "Starten"
5
5
  send: "Offene Anfragen versenden"
6
+ complete: "Zirkulation abschliessen"
7
+ reopen: "Zirkulation wiedereröffnen"
6
8
  send-confirm: "Wollen Sie wirklich alle offenen Anfragen versenden?"
7
9
  complete-confirm:
8
10
  "Es gibt noch <b>{count} offene {count, plural, =1 {Anfrage} other {Anfragen}}</b>
9
11
  in der aktuellen Zirkulation. Wenn Sie die Zirkulation abschliessen, werden
10
12
  alle verbleibenden offenen Anfragen abgebrochen. Möchten Sie fortfahren?"
13
+ complete-confirm-empty: "Möchten Sie die Zirkulation wirklich abschliessen?"
14
+ reopen-confirm: "Wollen Sie die Zirkulation wirklich wiedereröffnen?"
11
15
  send-error: "Fehler beim Versenden der offenen Anfragen"
12
16
  complete-error: "Fehler beim Abschliessen der Zirkulation"
17
+ reopen-error: "Fehler beim Wiedereröffnen der Zirkulation"
13
18
 
14
19
  more: "mehr"
15
20
  less: "weniger"
16
21
 
17
22
  last-modified: "Zuletzt bearbeitet von {user} am {date} um {time}"
18
23
  details: "Details"
24
+ not-allowed-hint:
25
+ "Sie können jedoch das Formular bearbeiten und die Eingabedaten werden
26
+ automatisch gespeichert."
19
27
 
20
28
  edit:
21
29
  link: "Bearbeiten"
22
30
  send: "Senden"
23
31
  send-error: "Fehler beim Senden der Anfrage"
32
+ send-not-allowed: "Sie sind nicht berechtigt diese Anfrage zu versenden."
24
33
 
25
34
  answer:
26
35
  link: "Beantworten"
27
- release-for-review: "Zur Kontrolle freigeben"
28
- release-adjustment-for-review: "Anpassung zur Kontrolle freigeben"
29
- confirm: "Bestätigen"
30
- revise: "Überarbeiten"
31
36
 
32
37
  complete-error: "Fehler beim Abschliessen der Aufgabe"
38
+ complete-not-allowed: "Sie sind nicht berechtigt diese Antwort zu versenden."
39
+
40
+ buttons:
41
+ compose:
42
+ label: "Zur Kontrolle freigeben"
43
+ status: "In Bearbeitung"
44
+ adjust:
45
+ label: "Anpassung zur Kontrolle freigeben"
46
+ status: "In Überarbeitung"
47
+ confirm:
48
+ label: "Bestätigen"
49
+ status: "In Prüfung"
50
+ revise:
51
+ label: "Überarbeiten"
33
52
 
34
53
  new:
35
54
  title: "Neue Anfrage"
@@ -49,6 +68,7 @@ caluma:
49
68
 
50
69
  status:
51
70
  draft: "Entwurf"
71
+ skipped: "Vorzeitig beendet"
52
72
  sent: "Versendet"
53
73
  positive: "Positiv"
54
74
  negative: "Negativ"
@@ -3,34 +3,53 @@ caluma:
3
3
  empty: "No inquiries have been created yet."
4
4
  start: "Start"
5
5
  send: "Send pending inquiries"
6
+ complete: "Complete circulation"
6
7
  send-confirm: "Do you really want to send all pending inquiries?"
8
+ reopen: "Reopen circulation"
7
9
  complete-confirm:
8
10
  "There {count, plural, =1 {is} other {are}} <b>{count} pending
9
11
  {count, plural, =1 {inquiry} other {inquiries}}</b> on the current
10
12
  distribution. Completing the distribution will cause all remaining
11
13
  pending inquiries to be canceled. Would you like to continue?"
14
+ complete-confirm-empty: "Do you really want to complete the distribution?"
15
+ reopen-confirm: "Do you really want to reopen the distribution?"
12
16
  send-error: "Error while sending pending inquiries"
13
- complete-error: "Error while completing distribution"
17
+ complete-error: "Error while completing the distribution"
18
+ reopen-error: "Error while reopening the distribution"
14
19
 
15
20
  more: "more"
16
21
  less: "less"
17
22
 
18
23
  last-modified: "Last modified by {user} on {date} at {time}"
19
24
  details: "Details"
25
+ not-allowed-hint:
26
+ "However, you can edit the form and the input will be saved
27
+ automatically."
20
28
 
21
29
  edit:
22
30
  link: "Edit"
23
31
  send: "Send"
24
32
  send-error: "Error while sending the inquiry"
33
+ send-not-allowed: "You are not allowed to send this inquiry."
25
34
 
26
35
  answer:
27
36
  link: "Answer"
28
- release-for-review: "Release for review"
29
- release-adjustment-for-review: "Release adjustment for review"
30
- confirm: "Confirm"
31
- revise: "Revise"
32
37
 
33
38
  complete-error: "Error while completing the work item"
39
+ complete-not-allowed: "You are not allowed to send this inquiry answer."
40
+
41
+ buttons:
42
+ compose:
43
+ label: "Release for review"
44
+ status: "In progress"
45
+ adjust:
46
+ label: "Release adjustment for review"
47
+ status: "In revision"
48
+ confirm:
49
+ label: "Confirm"
50
+ status: "In review"
51
+ revise:
52
+ label: "Revise"
34
53
 
35
54
  new:
36
55
  title: "New inquiry"
@@ -50,6 +69,7 @@ caluma:
50
69
 
51
70
  status:
52
71
  draft: "Draft"
72
+ skipped: "Aborted"
53
73
  sent: "Sent"
54
74
  positive: "Positive"
55
75
  negative: "Negative"
@@ -3,33 +3,52 @@ caluma:
3
3
  empty: "Aucune demande n'a encore été créée."
4
4
  start: "Lancer"
5
5
  send: "Envoyer les demandes ouvertes"
6
+ complete: "Terminer la circulation"
6
7
  send-confirm: "Voulez-vous vraiment envoyer toutes les demandes ouvertes ?"
8
+ reopen: "Rouvrir la procédure de circulation"
7
9
  complete-confirm:
8
10
  "Il y a <b>{count} {count, plural, =1 {demande} other {demandes}} en
9
11
  attente</b> sur la distribution actuelle. Si vous terminez la distribution,
10
12
  toutes les demandes en attente seront annulées. Voulez-vous continuer ?"
13
+ complete-confirm-empty: "Vous voulez vraiment fermer la circulation ?"
14
+ reopen-confirm: "Vous voulez vraiment rouvrir la circulation ?"
11
15
  send-error: "Erreur lors de l'envoi des demandes ouvertes"
12
- complete-error: "Erreur lors de la terminaison de la distribution"
16
+ complete-error: "Erreur lors de la terminaison de la circulation"
17
+ reopen-error: "Erreur lors de la réouverture de la circulation"
13
18
 
14
19
  more: "plus"
15
20
  less: "moins"
16
21
 
17
22
  last-modified: "Dernière modification par {user} le {date} à {time}"
18
23
  details: "Détails"
24
+ not-allowed-hint:
25
+ "Vous pouvez toutefois modifier le formulaire et les données seront
26
+ automatiquement enregistrées."
19
27
 
20
28
  edit:
21
29
  link: "Modifier"
22
30
  send: "Envoyer"
23
31
  send-error: "Erreur lors de l'envoi de la demande"
32
+ send-not-allowed: "Vous n'êtes pas autorisé à envoyer cette demande."
24
33
 
25
34
  answer:
26
35
  link: "Répondre"
27
- release-for-review: "Valider pour vérification"
28
- release-adjustment-for-review: "Valider la révision pour vérification"
29
- confirm: "Confirmer"
30
- revise: "Réviser"
31
36
 
32
37
  complete-error: "Erreur lors de la clôture de la tâche"
38
+ complete-not-allowed: "Vous n'êtes pas autorisé à envoyer cette réponse."
39
+
40
+ buttons:
41
+ compose:
42
+ label: "Valider pour vérification"
43
+ status: "En cours"
44
+ adjust:
45
+ label: "Valider la révision pour vérification"
46
+ status: "En révision"
47
+ confirm:
48
+ label: "Confirmer"
49
+ status: "En examen"
50
+ revise:
51
+ label: "Réviser"
33
52
 
34
53
  new:
35
54
  title: "Nouvelle demande"
@@ -49,6 +68,7 @@ caluma:
49
68
 
50
69
  status:
51
70
  draft: "Brouillon"
71
+ skipped: "Terminé prématurément"
52
72
  sent: "Envoyé"
53
73
  positive: "Positif"
54
74
  negative: "Negatif"
@@ -1,27 +0,0 @@
1
- {{#if @route}}
2
- <LinkTo @route={{@route}} class={{this.class}} title={{@title}} ...attributes>
3
- {{#if @loading}}
4
- <UkSpinner @ratio={{0.6}} />
5
- {{else if @fromSvgJar}}
6
- {{svg-jar @icon title=@title width="20" height="20"}}
7
- {{else}}
8
- <UkIcon @icon={{@icon}} />
9
- {{/if}}
10
- </LinkTo>
11
- {{else}}
12
- <button
13
- type="button"
14
- class={{this.class}}
15
- title={{@title}}
16
- ...attributes
17
- {{on "click" @onClick}}
18
- >
19
- {{#if @loading}}
20
- <UkSpinner @ratio={{0.6}} />
21
- {{else if @fromSvgJar}}
22
- {{svg-jar @icon title=@title width="20" height="20"}}
23
- {{else}}
24
- <UkIcon @icon={{@icon}} />
25
- {{/if}}
26
- </button>
27
- {{/if}}
@@ -1,22 +0,0 @@
1
- import { dasherize } from "@ember/string";
2
- import Component from "@glimmer/component";
3
-
4
- export default class CdIconButtonComponent extends Component {
5
- get class() {
6
- const gutters = [
7
- "gutter",
8
- "gutterTop",
9
- "gutterRight",
10
- "gutterBottom",
11
- "gutterLeft",
12
- ]
13
- .map((arg) =>
14
- this.args[arg]
15
- ? `uk-icon-button--${dasherize(arg)}-${this.args[arg]}`
16
- : null
17
- )
18
- .filter(Boolean);
19
-
20
- return ["uk-icon-button", ...gutters].join(" ");
21
- }
22
- }
@@ -1 +0,0 @@
1
- export { default } from "@projectcaluma/ember-distribution/components/cd-icon-button";
@@ -1,13 +0,0 @@
1
- @import "ember-uikit/variables-theme";
2
-
3
- @for $i from 1 through 8 {
4
- @each $side in "top", "right", "bottom", "left" {
5
- .uk-icon-button--gutter-#{$side}-#{$i} > svg {
6
- margin-#{$side}: #{$i}px !important;
7
- }
8
- }
9
-
10
- .uk-icon-button--gutter-#{$i} > svg {
11
- margin: #{$i}px;
12
- }
13
- }
@@ -1,31 +0,0 @@
1
- @import "ember-uikit/variables-theme";
2
-
3
- $size: $global-small-font-size * 1.2;
4
- $iconSize: $global-small-font-size * 0.9;
5
-
6
- $colors: (
7
- muted: $text-muted-color,
8
- emphasis: $text-emphasis-color,
9
- success: $text-success-color,
10
- danger: $text-danger-color,
11
- warning: $text-warning-color,
12
- );
13
-
14
- .status-indicator {
15
- width: $size;
16
- height: $size;
17
- border-width: 1px;
18
- border-style: solid;
19
-
20
- > svg {
21
- width: $iconSize;
22
- height: $iconSize;
23
- }
24
-
25
- @each $colorName, $color in $colors {
26
- &.uk-text-#{$colorName} {
27
- color: darken($color, 20%);
28
- border-color: $color;
29
- }
30
- }
31
- }