@uxland/primary-shell 5.6.4 → 5.6.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.
- package/dist/index.js +109 -65
- package/dist/index.js.map +1 -1
- package/dist/index.umd.cjs +43 -30
- package/dist/index.umd.cjs.map +1 -1
- package/dist/primary/shell/src/internal-plugins/activity-history/activity-history-item/add/handle-busy/is-grouping-busy/component.d.ts +6 -0
- package/dist/primary/shell/src/internal-plugins/activity-history/activity-history-item/add/handle-busy/is-grouping-busy/template.d.ts +3 -0
- package/dist/primary/shell/src/internal-plugins/activity-history/localization.d.ts +5 -0
- package/package.json +1 -1
- package/src/internal-plugins/activity-history/activity-history-item/add/add-history-item/handler.ts +2 -2
- package/src/internal-plugins/activity-history/activity-history-item/add/add-history-items/handler.ts +2 -2
- package/src/internal-plugins/activity-history/activity-history-item/add/handle-busy/is-grouping-busy/component.ts +15 -0
- package/src/internal-plugins/activity-history/activity-history-item/add/handle-busy/is-grouping-busy/styles.css +8 -0
- package/src/internal-plugins/activity-history/activity-history-item/add/handle-busy/is-grouping-busy/template.ts +10 -0
- package/src/internal-plugins/activity-history/activity-history-item/list/UI/timeline/activity-history-timeline.ts +12 -5
- package/src/internal-plugins/activity-history/activity-history-item/list/UI/timeline/template.ts +20 -13
- package/src/internal-plugins/activity-history/localization.ts +5 -0
|
@@ -18,6 +18,11 @@ export declare const locales: {
|
|
|
18
18
|
goToDate: string;
|
|
19
19
|
busyEntriesLoading: string;
|
|
20
20
|
noResults: string;
|
|
21
|
+
noData: {
|
|
22
|
+
title: string;
|
|
23
|
+
description: string;
|
|
24
|
+
};
|
|
25
|
+
isGrouping: string;
|
|
21
26
|
searchBarResults: string;
|
|
22
27
|
actions: {
|
|
23
28
|
cronogram: string;
|
package/package.json
CHANGED
package/src/internal-plugins/activity-history/activity-history-item/add/add-history-item/handler.ts
CHANGED
|
@@ -9,14 +9,14 @@ export class AddHistoryItemHandler extends StoreBaseHandler {
|
|
|
9
9
|
async handle(payload: AddHistoryItemPayload) {
|
|
10
10
|
try {
|
|
11
11
|
ensureAreValidBasicActivityHistoryItems([payload.item]);
|
|
12
|
+
handleAddDiagnosticsFilter([payload.item], this.store);
|
|
13
|
+
handleAddUpFilter([payload.item], this.store);
|
|
12
14
|
this.store.dispatch(
|
|
13
15
|
addActivityHistoryItem({
|
|
14
16
|
id: payload.entityId,
|
|
15
17
|
item: payload.item,
|
|
16
18
|
}),
|
|
17
19
|
);
|
|
18
|
-
handleAddDiagnosticsFilter([payload.item], this.store);
|
|
19
|
-
handleAddUpFilter([payload.item], this.store);
|
|
20
20
|
} catch (e) {
|
|
21
21
|
console.log(e.message);
|
|
22
22
|
}
|
package/src/internal-plugins/activity-history/activity-history-item/add/add-history-items/handler.ts
CHANGED
|
@@ -9,6 +9,8 @@ export class AddHistoryItemsHandler extends StoreBaseHandler {
|
|
|
9
9
|
async handle(payload: AddHistoryItemsPayload) {
|
|
10
10
|
try {
|
|
11
11
|
const validItems = validateAndFilterBasicItems(payload.items);
|
|
12
|
+
handleAddDiagnosticsFilter(validItems, this.store);
|
|
13
|
+
handleAddUpFilter(validItems, this.store);
|
|
12
14
|
this.store.dispatch(
|
|
13
15
|
addActivityHistoryItems({
|
|
14
16
|
id: payload.entityId,
|
|
@@ -17,8 +19,6 @@ export class AddHistoryItemsHandler extends StoreBaseHandler {
|
|
|
17
19
|
searchPredicate: payload.searchPredicate,
|
|
18
20
|
}),
|
|
19
21
|
);
|
|
20
|
-
handleAddDiagnosticsFilter(validItems, this.store);
|
|
21
|
-
handleAddUpFilter(validItems, this.store);
|
|
22
22
|
} catch (e) {
|
|
23
23
|
console.log(e.message);
|
|
24
24
|
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { LitElement, html, css, unsafeCSS } from "lit";
|
|
2
|
+
import { customElement } from "lit/decorators.js";
|
|
3
|
+
import styles from "./styles.css?inline";
|
|
4
|
+
import { template } from "./template";
|
|
5
|
+
|
|
6
|
+
@customElement("activity-history-is-grouping-busy")
|
|
7
|
+
export class ActivityHistoryIsGroupingBusy extends LitElement {
|
|
8
|
+
static styles = css`
|
|
9
|
+
${unsafeCSS(styles)}
|
|
10
|
+
`;
|
|
11
|
+
|
|
12
|
+
render() {
|
|
13
|
+
return template(this);
|
|
14
|
+
}
|
|
15
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
import { ActivityHistoryIsGroupingBusy } from "./component";
|
|
3
|
+
import { translate } from "../../../../localization";
|
|
4
|
+
|
|
5
|
+
export const template = (_props: ActivityHistoryIsGroupingBusy) => html`
|
|
6
|
+
<div class="grouping-busy-container">
|
|
7
|
+
<dss-spinner size="sm"></dss-spinner>
|
|
8
|
+
<div>${translate("isGrouping")}</div>
|
|
9
|
+
</div>
|
|
10
|
+
`;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { LitElement, PropertyValues, css, html, unsafeCSS } from "lit";
|
|
2
|
-
import { customElement, query } from "lit/decorators.js";
|
|
2
|
+
import { customElement, query, state } from "lit/decorators.js";
|
|
3
3
|
import { connectedProperty } from "../../../../infrastructure/state/connected-property";
|
|
4
4
|
import { IActivityHistoryGroup } from "../../../domain/model";
|
|
5
5
|
import { activityHistorySearchStringSelector } from "../../../search/selectors";
|
|
@@ -52,11 +52,18 @@ export class ActivityHistoryTimeline extends LitElement {
|
|
|
52
52
|
|
|
53
53
|
@query(".virtualizer") private _virtualizer!: HTMLElement;
|
|
54
54
|
|
|
55
|
-
|
|
55
|
+
@state()
|
|
56
|
+
renderGroupsControlTimeExpired = false;
|
|
56
57
|
|
|
57
|
-
|
|
58
|
-
super.
|
|
59
|
-
|
|
58
|
+
connectedCallback(): void {
|
|
59
|
+
super.connectedCallback();
|
|
60
|
+
setTimeout(() => {
|
|
61
|
+
this.renderGroupsControlTimeExpired = true;
|
|
62
|
+
}, 8000);
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
disconnectedCallback(): void {
|
|
66
|
+
super.disconnectedCallback();
|
|
60
67
|
}
|
|
61
68
|
|
|
62
69
|
async updated(changedProperties) {
|
package/src/internal-plugins/activity-history/activity-history-item/list/UI/timeline/template.ts
CHANGED
|
@@ -9,7 +9,6 @@ import {
|
|
|
9
9
|
IActivityHistoryGroup,
|
|
10
10
|
IActivityHistoryItem,
|
|
11
11
|
IActivityHistoryItemWithComponent,
|
|
12
|
-
IActivityHistorySubGroup,
|
|
13
12
|
} from "../../../domain/model";
|
|
14
13
|
import { translate } from "../../../../localization";
|
|
15
14
|
import { hasItemDivider, shouldShowRole } from "../../../domain/business-rules";
|
|
@@ -17,11 +16,9 @@ import {
|
|
|
17
16
|
ActivityHistoryEntry,
|
|
18
17
|
mergeHistoryItemsAndSubgroups,
|
|
19
18
|
} from "../../merge-history-items-and-subgroups/merge-history-items-and-subgroups";
|
|
19
|
+
import "../../../add/handle-busy/is-grouping-busy/component";
|
|
20
20
|
|
|
21
21
|
export const template = (props: ActivityHistoryTimeline) => {
|
|
22
|
-
if (!props._hasUpdatedOnce) {
|
|
23
|
-
return html`<div class="container"></div>`;
|
|
24
|
-
}
|
|
25
22
|
return html`
|
|
26
23
|
<div class="container">
|
|
27
24
|
<activity-history-full-data-error></activity-history-full-data-error>
|
|
@@ -78,20 +75,30 @@ export const template = (props: ActivityHistoryTimeline) => {
|
|
|
78
75
|
`}
|
|
79
76
|
></lit-virtualizer>
|
|
80
77
|
`
|
|
81
|
-
:
|
|
82
|
-
? html`
|
|
83
|
-
<dss-user-feedback
|
|
84
|
-
class="feedback"
|
|
85
|
-
imagesrc=${notFound}
|
|
86
|
-
title=${translate("noResults")}>
|
|
87
|
-
</dss-user-feedback>
|
|
88
|
-
`
|
|
89
|
-
: nothing
|
|
78
|
+
: noGroupsTemplate(props)
|
|
90
79
|
}
|
|
91
80
|
</div>
|
|
92
81
|
`;
|
|
93
82
|
};
|
|
94
83
|
|
|
84
|
+
const noGroupsTemplate = (props: ActivityHistoryTimeline)=> html `
|
|
85
|
+
${props.searchString?.length > 1
|
|
86
|
+
? html`
|
|
87
|
+
<dss-user-feedback
|
|
88
|
+
class="feedback"
|
|
89
|
+
imagesrc=${notFound}
|
|
90
|
+
title=${translate("noResults")}>
|
|
91
|
+
</dss-user-feedback>
|
|
92
|
+
`
|
|
93
|
+
: props.renderGroupsControlTimeExpired
|
|
94
|
+
? html`<dss-user-feedback
|
|
95
|
+
class="feedback"
|
|
96
|
+
imagesrc=${notFound}
|
|
97
|
+
title=${translate("noData.title")}
|
|
98
|
+
description=${translate("noData.description")}>
|
|
99
|
+
</dss-user-feedback>`
|
|
100
|
+
: html`<activity-history-is-grouping-busy></activity-history-is-grouping-busy>`}`;
|
|
101
|
+
|
|
95
102
|
const visitHeaderTemplate = (props: ActivityHistoryTimeline, item: IActivityHistoryItem | undefined) => {
|
|
96
103
|
if (!item) return nothing;
|
|
97
104
|
return html`
|
|
@@ -32,6 +32,11 @@ export const locales = {
|
|
|
32
32
|
goToDate: "Anar a data",
|
|
33
33
|
busyEntriesLoading: "Carregant totes les entrades",
|
|
34
34
|
noResults: "Sense resultats. Modifica la cerca",
|
|
35
|
+
noData: {
|
|
36
|
+
title: "Sense dades",
|
|
37
|
+
description: "No existeix informació per a mostrar"
|
|
38
|
+
},
|
|
39
|
+
isGrouping: "Creant agrupacions i preparant les dades...",
|
|
35
40
|
searchBarResults: "Resultats per",
|
|
36
41
|
actions: {
|
|
37
42
|
cronogram: "Cronograma",
|