@things-factory/dataset 6.2.62 → 6.2.64
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/client/activities/activity-data-collect-edit.ts +2 -0
- package/client/activities/activity-data-collect-view.ts +2 -0
- package/client/activities/activity-ooc-resolve-edit.ts +2 -0
- package/client/activities/activity-ooc-resolve-view.ts +2 -0
- package/client/activities/activity-ooc-review-edit.ts +2 -0
- package/client/activities/activity-ooc-review-view.ts +2 -0
- package/client/pages/data-archive/data-archive-list-page.ts +15 -40
- package/client/pages/data-entry/data-entry-list-page.ts +2 -0
- package/client/pages/data-key-set/data-key-item-list.ts +1 -1
- package/client/pages/data-key-set/data-key-set-list-page.ts +20 -40
- package/client/pages/data-ooc/data-ooc-list-page.ts +10 -13
- package/client/pages/data-ooc/data-ooc-view-page.ts +5 -1
- package/client/pages/data-report/data-report-list-page.ts +22 -24
- package/client/pages/data-sample/data-sample-list-page.ts +13 -37
- package/client/pages/data-sample/data-sample-search-page.ts +13 -37
- package/client/pages/data-sample/data-sample-view.ts +7 -2
- package/client/pages/data-sensor/data-sensor-list-page.ts +6 -13
- package/client/pages/data-set/data-item-list.ts +0 -12
- package/client/pages/data-set/data-set-list-page.ts +30 -41
- package/dist-client/activities/activity-data-collect-edit.js +2 -0
- package/dist-client/activities/activity-data-collect-edit.js.map +1 -1
- package/dist-client/activities/activity-data-collect-view.js +2 -0
- package/dist-client/activities/activity-data-collect-view.js.map +1 -1
- package/dist-client/activities/activity-ooc-resolve-edit.js +2 -0
- package/dist-client/activities/activity-ooc-resolve-edit.js.map +1 -1
- package/dist-client/activities/activity-ooc-resolve-view.js +2 -0
- package/dist-client/activities/activity-ooc-resolve-view.js.map +1 -1
- package/dist-client/activities/activity-ooc-review-edit.js +2 -0
- package/dist-client/activities/activity-ooc-review-edit.js.map +1 -1
- package/dist-client/activities/activity-ooc-review-view.js +2 -0
- package/dist-client/activities/activity-ooc-review-view.js.map +1 -1
- package/dist-client/pages/data-archive/data-archive-list-page.d.ts +2 -7
- package/dist-client/pages/data-archive/data-archive-list-page.js +18 -33
- package/dist-client/pages/data-archive/data-archive-list-page.js.map +1 -1
- package/dist-client/pages/data-entry/data-entry-list-page.js +2 -0
- package/dist-client/pages/data-entry/data-entry-list-page.js.map +1 -1
- package/dist-client/pages/data-key-set/data-key-item-list.js.map +1 -1
- package/dist-client/pages/data-key-set/data-key-set-list-page.d.ts +3 -8
- package/dist-client/pages/data-key-set/data-key-set-list-page.js +27 -33
- package/dist-client/pages/data-key-set/data-key-set-list-page.js.map +1 -1
- package/dist-client/pages/data-ooc/data-ooc-list-page.js +9 -2
- package/dist-client/pages/data-ooc/data-ooc-list-page.js.map +1 -1
- package/dist-client/pages/data-ooc/data-ooc-view-page.js +5 -1
- package/dist-client/pages/data-ooc/data-ooc-view-page.js.map +1 -1
- package/dist-client/pages/data-report/data-report-list-page.d.ts +3 -2
- package/dist-client/pages/data-report/data-report-list-page.js +20 -26
- package/dist-client/pages/data-report/data-report-list-page.js.map +1 -1
- package/dist-client/pages/data-sample/data-sample-list-page.d.ts +2 -1
- package/dist-client/pages/data-sample/data-sample-list-page.js +12 -31
- package/dist-client/pages/data-sample/data-sample-list-page.js.map +1 -1
- package/dist-client/pages/data-sample/data-sample-search-page.d.ts +2 -1
- package/dist-client/pages/data-sample/data-sample-search-page.js +12 -31
- package/dist-client/pages/data-sample/data-sample-search-page.js.map +1 -1
- package/dist-client/pages/data-sample/data-sample-view.js +7 -2
- package/dist-client/pages/data-sample/data-sample-view.js.map +1 -1
- package/dist-client/pages/data-sensor/data-sensor-list-page.d.ts +2 -14
- package/dist-client/pages/data-sensor/data-sensor-list-page.js +11 -9
- package/dist-client/pages/data-sensor/data-sensor-list-page.js.map +1 -1
- package/dist-client/pages/data-set/data-item-list.js +0 -12
- package/dist-client/pages/data-set/data-item-list.js.map +1 -1
- package/dist-client/pages/data-set/data-set-list-page.d.ts +7 -12
- package/dist-client/pages/data-set/data-set-list-page.js +34 -36
- package/dist-client/pages/data-set/data-set-list-page.js.map +1 -1
- package/dist-client/tsconfig.tsbuildinfo +1 -1
- package/package.json +5 -5
@@ -79,6 +79,7 @@ export class DataCollectActivityEdit extends localize(i18next)(LitElement) {
|
|
79
79
|
name
|
80
80
|
description
|
81
81
|
active
|
82
|
+
hidden
|
82
83
|
tag
|
83
84
|
group
|
84
85
|
type
|
@@ -86,6 +87,7 @@ export class DataCollectActivityEdit extends localize(i18next)(LitElement) {
|
|
86
87
|
options
|
87
88
|
quota
|
88
89
|
spec
|
90
|
+
stat
|
89
91
|
}
|
90
92
|
}
|
91
93
|
}
|
@@ -60,6 +60,7 @@ export class DataCollectActivityView extends localize(i18next)(LitElement) {
|
|
60
60
|
name
|
61
61
|
description
|
62
62
|
active
|
63
|
+
hidden
|
63
64
|
tag
|
64
65
|
group
|
65
66
|
type
|
@@ -67,6 +68,7 @@ export class DataCollectActivityView extends localize(i18next)(LitElement) {
|
|
67
68
|
options
|
68
69
|
quota
|
69
70
|
spec
|
71
|
+
stat
|
70
72
|
}
|
71
73
|
}
|
72
74
|
}
|
@@ -150,6 +150,7 @@ class OocResolveActivityEdit extends localize(i18next)(LitElement) {
|
|
150
150
|
name
|
151
151
|
description
|
152
152
|
active
|
153
|
+
hidden
|
153
154
|
tag
|
154
155
|
group
|
155
156
|
type
|
@@ -157,6 +158,7 @@ class OocResolveActivityEdit extends localize(i18next)(LitElement) {
|
|
157
158
|
options
|
158
159
|
quota
|
159
160
|
spec
|
161
|
+
stat
|
160
162
|
}
|
161
163
|
workDate
|
162
164
|
workShift
|
@@ -116,6 +116,7 @@ class OocResolveActivityView extends localize(i18next)(LitElement) {
|
|
116
116
|
name
|
117
117
|
description
|
118
118
|
active
|
119
|
+
hidden
|
119
120
|
tag
|
120
121
|
group
|
121
122
|
type
|
@@ -123,6 +124,7 @@ class OocResolveActivityView extends localize(i18next)(LitElement) {
|
|
123
124
|
options
|
124
125
|
quota
|
125
126
|
spec
|
127
|
+
stat
|
126
128
|
}
|
127
129
|
workDate
|
128
130
|
workShift
|
@@ -129,6 +129,7 @@ class OocReviewActivityEdit extends localize(i18next)(LitElement) {
|
|
129
129
|
name
|
130
130
|
description
|
131
131
|
active
|
132
|
+
hidden
|
132
133
|
tag
|
133
134
|
group
|
134
135
|
type
|
@@ -136,6 +137,7 @@ class OocReviewActivityEdit extends localize(i18next)(LitElement) {
|
|
136
137
|
options
|
137
138
|
quota
|
138
139
|
spec
|
140
|
+
stat
|
139
141
|
}
|
140
142
|
workDate
|
141
143
|
workShift
|
@@ -102,6 +102,7 @@ class OocReviewActivityView extends localize(i18next)(LitElement) {
|
|
102
102
|
name
|
103
103
|
description
|
104
104
|
active
|
105
|
+
hidden
|
105
106
|
tag
|
106
107
|
group
|
107
108
|
type
|
@@ -109,6 +110,7 @@ class OocReviewActivityView extends localize(i18next)(LitElement) {
|
|
109
110
|
options
|
110
111
|
quota
|
111
112
|
spec
|
113
|
+
stat
|
112
114
|
}
|
113
115
|
workDate
|
114
116
|
workShift
|
@@ -1,26 +1,18 @@
|
|
1
1
|
import '@operato/data-grist'
|
2
|
+
import '@operato/context/ox-context-page-toolbar.js'
|
2
3
|
|
3
4
|
import gql from 'graphql-tag'
|
4
5
|
import { css, html } from 'lit'
|
5
6
|
import { customElement, property, query, state } from 'lit/decorators.js'
|
6
7
|
import { connect } from 'pwa-helpers/connect-mixin'
|
7
8
|
|
8
|
-
import {
|
9
|
-
getEditor,
|
10
|
-
getRenderer,
|
11
|
-
ColumnConfig,
|
12
|
-
DataGrist,
|
13
|
-
FetchOption,
|
14
|
-
SortersControl,
|
15
|
-
GristRecord
|
16
|
-
} from '@operato/data-grist'
|
9
|
+
import { DataGrist, FetchOption, GristRecord } from '@operato/data-grist'
|
17
10
|
import { client } from '@operato/graphql'
|
18
11
|
import { i18next, localize } from '@operato/i18n'
|
19
|
-
import { openPopup } from '@operato/layout'
|
12
|
+
import { PopupHandle, openPopup } from '@operato/layout'
|
20
13
|
import { PageView, store } from '@operato/shell'
|
21
|
-
import { CommonButtonStyles,
|
14
|
+
import { CommonButtonStyles, CommonHeaderStyles, ScrollbarStyles } from '@operato/styles'
|
22
15
|
import { isMobileDevice } from '@operato/utils'
|
23
|
-
import { OxPopup, PopupHandle } from '@operato/popup'
|
24
16
|
|
25
17
|
import './data-archive-request-popup'
|
26
18
|
|
@@ -28,7 +20,7 @@ import './data-archive-request-popup'
|
|
28
20
|
export class DataArchiveListPage extends connect(store)(localize(i18next)(PageView)) {
|
29
21
|
static styles = [
|
30
22
|
ScrollbarStyles,
|
31
|
-
|
23
|
+
CommonHeaderStyles,
|
32
24
|
css`
|
33
25
|
:host {
|
34
26
|
display: flex;
|
@@ -48,7 +40,6 @@ export class DataArchiveListPage extends connect(store)(localize(i18next)(PageVi
|
|
48
40
|
@state() mode: 'CARD' | 'GRID' | 'LIST' = isMobileDevice() ? 'CARD' : 'GRID'
|
49
41
|
|
50
42
|
@query('ox-grist') private grist!: DataGrist
|
51
|
-
@query('#sorter-control') private sortersControl!: OxPopup
|
52
43
|
|
53
44
|
private popup?: PopupHandle
|
54
45
|
|
@@ -69,7 +60,6 @@ export class DataArchiveListPage extends connect(store)(localize(i18next)(PageVi
|
|
69
60
|
help: 'dataset/data-archive',
|
70
61
|
actions: [
|
71
62
|
{
|
72
|
-
...CommonButtonStyles.save,
|
73
63
|
title: i18next.t('button.request-archive'),
|
74
64
|
action: this.openArchivePopup.bind(this),
|
75
65
|
icon: 'archive'
|
@@ -78,7 +68,8 @@ export class DataArchiveListPage extends connect(store)(localize(i18next)(PageVi
|
|
78
68
|
exportable: {
|
79
69
|
name: i18next.t('title.data-archive list'),
|
80
70
|
data: this._exportableData.bind(this)
|
81
|
-
}
|
71
|
+
},
|
72
|
+
toolbar: false
|
82
73
|
}
|
83
74
|
}
|
84
75
|
|
@@ -92,33 +83,17 @@ export class DataArchiveListPage extends connect(store)(localize(i18next)(PageVi
|
|
92
83
|
.fetchHandler=${this.fetchHandler.bind(this)}
|
93
84
|
?url-params-sensitive=${false /* this.active */}
|
94
85
|
>
|
95
|
-
<div slot="headroom">
|
96
|
-
<div
|
97
|
-
<
|
86
|
+
<div slot="headroom" class="header">
|
87
|
+
<div class="title">
|
88
|
+
<mwc-icon>summarize</mwc-icon>
|
89
|
+
${i18next.t('title.data-archive list')}
|
98
90
|
</div>
|
99
91
|
|
100
|
-
<div
|
101
|
-
|
102
|
-
|
103
|
-
@click=${e => {
|
104
|
-
const target = e.currentTarget
|
105
|
-
this.sortersControl.open({
|
106
|
-
right: 0,
|
107
|
-
top: target.offsetTop + target.offsetHeight
|
108
|
-
})
|
109
|
-
}}
|
110
|
-
>expand_more</mwc-icon
|
111
|
-
>
|
112
|
-
<ox-popup id="sorter-control">
|
113
|
-
<ox-sorters-control> </ox-sorters-control>
|
114
|
-
</ox-popup>
|
115
|
-
</div>
|
92
|
+
<!-- <div class="filters">
|
93
|
+
<ox-filters-form class="filter" autofocus without-search></ox-filters-form>
|
94
|
+
</div> -->
|
116
95
|
|
117
|
-
<
|
118
|
-
<mwc-icon @click=${() => (this.mode = 'GRID')} ?active=${mode == 'GRID'}>grid_on</mwc-icon>
|
119
|
-
<mwc-icon @click=${() => (this.mode = 'LIST')} ?active=${mode == 'LIST'}>format_list_bulleted</mwc-icon>
|
120
|
-
<mwc-icon @click=${() => (this.mode = 'CARD')} ?active=${mode == 'CARD'}>apps</mwc-icon>
|
121
|
-
</div>
|
96
|
+
<ox-context-page-toolbar class="actions" .context=${this.context}></ox-context-page-toolbar>
|
122
97
|
</div>
|
123
98
|
</ox-grist>
|
124
99
|
`
|
@@ -356,6 +356,7 @@ export class DataEntryListPage extends connect(store)(localize(i18next)(PageView
|
|
356
356
|
name
|
357
357
|
description
|
358
358
|
active
|
359
|
+
hidden
|
359
360
|
tag
|
360
361
|
group
|
361
362
|
type
|
@@ -363,6 +364,7 @@ export class DataEntryListPage extends connect(store)(localize(i18next)(PageView
|
|
363
364
|
options
|
364
365
|
quota
|
365
366
|
spec
|
367
|
+
stat
|
366
368
|
}
|
367
369
|
latestCollectedAt
|
368
370
|
nextSchedule
|
@@ -5,7 +5,7 @@ import { customElement, property, query, state } from 'lit/decorators.js'
|
|
5
5
|
import { client } from '@operato/graphql'
|
6
6
|
import { i18next, localize } from '@operato/i18n'
|
7
7
|
import { isMobileDevice } from '@operato/utils'
|
8
|
-
import {
|
8
|
+
import { DataGrist, FetchOption } from '@operato/data-grist'
|
9
9
|
|
10
10
|
@customElement('data-key-item-list')
|
11
11
|
export class DataKeyItemList extends localize(i18next)(LitElement) {
|
@@ -1,4 +1,5 @@
|
|
1
1
|
import '@operato/data-grist'
|
2
|
+
import '@operato/context/ox-context-page-toolbar.js'
|
2
3
|
import './data-key-set-importer.js'
|
3
4
|
import './data-key-item-list'
|
4
5
|
|
@@ -7,23 +8,13 @@ import { css, html } from 'lit'
|
|
7
8
|
import { customElement, property, query, state } from 'lit/decorators.js'
|
8
9
|
import { connect } from 'pwa-helpers/connect-mixin'
|
9
10
|
|
10
|
-
import {
|
11
|
-
getEditor,
|
12
|
-
getRenderer,
|
13
|
-
ColumnConfig,
|
14
|
-
DataGrist,
|
15
|
-
FetchOption,
|
16
|
-
SortersControl,
|
17
|
-
GristData,
|
18
|
-
GristRecord
|
19
|
-
} from '@operato/data-grist'
|
11
|
+
import { getEditor, getRenderer, DataGrist, FetchOption } from '@operato/data-grist'
|
20
12
|
import { client } from '@operato/graphql'
|
21
13
|
import { i18next, localize } from '@operato/i18n'
|
22
14
|
import { notify, openPopup } from '@operato/layout'
|
23
15
|
import { navigate, PageView, store } from '@operato/shell'
|
24
|
-
import {
|
16
|
+
import { CommonHeaderStyles, ScrollbarStyles } from '@operato/styles'
|
25
17
|
import { isMobileDevice, encodeUrlParams } from '@operato/utils'
|
26
|
-
import { OxPopup } from '@operato/popup'
|
27
18
|
|
28
19
|
const REPORT_TYPES = [
|
29
20
|
{
|
@@ -64,7 +55,7 @@ const REPORT_TYPES = [
|
|
64
55
|
export class DataKeySetListPage extends connect(store)(localize(i18next)(PageView)) {
|
65
56
|
static styles = [
|
66
57
|
ScrollbarStyles,
|
67
|
-
|
58
|
+
CommonHeaderStyles,
|
68
59
|
css`
|
69
60
|
:host {
|
70
61
|
display: flex;
|
@@ -74,6 +65,11 @@ export class DataKeySetListPage extends connect(store)(localize(i18next)(PageVie
|
|
74
65
|
--grid-record-emphasized-background-color: red;
|
75
66
|
--grid-record-emphasized-color: yellow;
|
76
67
|
}
|
68
|
+
|
69
|
+
ox-grist {
|
70
|
+
overflow-y: auto;
|
71
|
+
flex: 1;
|
72
|
+
}
|
77
73
|
`
|
78
74
|
]
|
79
75
|
|
@@ -81,7 +77,6 @@ export class DataKeySetListPage extends connect(store)(localize(i18next)(PageVie
|
|
81
77
|
@state() mode: 'CARD' | 'GRID' | 'LIST' = isMobileDevice() ? 'CARD' : 'GRID'
|
82
78
|
|
83
79
|
@query('ox-grist') private grist!: DataGrist
|
84
|
-
@query('#sorter-control') private sortersControl!: OxPopup
|
85
80
|
|
86
81
|
get context() {
|
87
82
|
return {
|
@@ -102,12 +97,12 @@ export class DataKeySetListPage extends connect(store)(localize(i18next)(PageVie
|
|
102
97
|
{
|
103
98
|
title: i18next.t('button.save'),
|
104
99
|
action: this._updateDataKeySet.bind(this),
|
105
|
-
|
100
|
+
icon: 'save'
|
106
101
|
},
|
107
102
|
{
|
108
103
|
title: i18next.t('button.delete'),
|
109
104
|
action: this._deleteDataKeySet.bind(this),
|
110
|
-
|
105
|
+
icon: 'delete'
|
111
106
|
}
|
112
107
|
],
|
113
108
|
exportable: {
|
@@ -116,7 +111,8 @@ export class DataKeySetListPage extends connect(store)(localize(i18next)(PageVie
|
|
116
111
|
},
|
117
112
|
importable: {
|
118
113
|
handler: this.importHandler.bind(this)
|
119
|
-
}
|
114
|
+
},
|
115
|
+
toolbar: false
|
120
116
|
}
|
121
117
|
}
|
122
118
|
|
@@ -125,33 +121,17 @@ export class DataKeySetListPage extends connect(store)(localize(i18next)(PageVie
|
|
125
121
|
|
126
122
|
return html`
|
127
123
|
<ox-grist .mode=${mode} .config=${this.gristConfig} .fetchHandler=${this.fetchHandler.bind(this)}>
|
128
|
-
<div slot="headroom">
|
129
|
-
<div
|
130
|
-
<
|
124
|
+
<div slot="headroom" class="header">
|
125
|
+
<div class="title">
|
126
|
+
<mwc-icon>summarize</mwc-icon>
|
127
|
+
${i18next.t('title.data-key-set list')}
|
131
128
|
</div>
|
132
129
|
|
133
|
-
<div
|
134
|
-
|
135
|
-
<mwc-icon
|
136
|
-
@click=${e => {
|
137
|
-
const target = e.currentTarget
|
138
|
-
this.sortersControl.open({
|
139
|
-
right: 0,
|
140
|
-
top: target.offsetTop + target.offsetHeight
|
141
|
-
})
|
142
|
-
}}
|
143
|
-
>expand_more</mwc-icon
|
144
|
-
>
|
145
|
-
<ox-popup id="sorter-control">
|
146
|
-
<ox-sorters-control> </ox-sorters-control>
|
147
|
-
</ox-popup>
|
130
|
+
<div class="filters">
|
131
|
+
<ox-filters-form autofocus without-search></ox-filters-form>
|
148
132
|
</div>
|
149
133
|
|
150
|
-
<
|
151
|
-
<mwc-icon @click=${() => (this.mode = 'GRID')} ?active=${mode == 'GRID'}>grid_on</mwc-icon>
|
152
|
-
<mwc-icon @click=${() => (this.mode = 'LIST')} ?active=${mode == 'LIST'}>format_list_bulleted</mwc-icon>
|
153
|
-
<mwc-icon @click=${() => (this.mode = 'CARD')} ?active=${mode == 'CARD'}>apps</mwc-icon>
|
154
|
-
</div>
|
134
|
+
<ox-context-page-toolbar class="actions" .context=${this.context}> </ox-context-page-toolbar>
|
155
135
|
</div>
|
156
136
|
</ox-grist>
|
157
137
|
`
|
@@ -25,23 +25,13 @@ function getOocStatus() {
|
|
25
25
|
]
|
26
26
|
}
|
27
27
|
|
28
|
-
import {
|
29
|
-
getEditor,
|
30
|
-
getRenderer,
|
31
|
-
ColumnConfig,
|
32
|
-
DataGrist,
|
33
|
-
FetchOption,
|
34
|
-
SortersControl,
|
35
|
-
GristData,
|
36
|
-
GristRecord
|
37
|
-
} from '@operato/data-grist'
|
28
|
+
import { DataGrist, FetchOption, GristRecord } from '@operato/data-grist'
|
38
29
|
import { client } from '@operato/graphql'
|
39
30
|
import { i18next, localize } from '@operato/i18n'
|
40
31
|
import { openPopup } from '@operato/layout'
|
41
32
|
import { PageView, store } from '@operato/shell'
|
42
33
|
import { CommonHeaderStyles, ScrollbarStyles } from '@operato/styles'
|
43
34
|
import { isMobileDevice, adjustFilters } from '@operato/utils'
|
44
|
-
import { OxPopup } from '@operato/popup'
|
45
35
|
|
46
36
|
@customElement('data-ooc-list-page')
|
47
37
|
export class DataOocListPage extends connect(store)(localize(i18next)(PageView)) {
|
@@ -217,7 +207,8 @@ export class DataOocListPage extends connect(store)(localize(i18next)(PageView))
|
|
217
207
|
label: true,
|
218
208
|
header: i18next.t('field.corrective-action'),
|
219
209
|
record: {
|
220
|
-
editable: true
|
210
|
+
editable: true,
|
211
|
+
language: 'text'
|
221
212
|
},
|
222
213
|
width: 150,
|
223
214
|
imex: true
|
@@ -402,10 +393,16 @@ export class DataOocListPage extends connect(store)(localize(i18next)(PageView))
|
|
402
393
|
dataItems {
|
403
394
|
name
|
404
395
|
description
|
396
|
+
active
|
397
|
+
hidden
|
405
398
|
tag
|
406
|
-
|
399
|
+
group
|
407
400
|
type
|
401
|
+
unit
|
402
|
+
options
|
403
|
+
quota
|
408
404
|
spec
|
405
|
+
stat
|
409
406
|
}
|
410
407
|
data
|
411
408
|
rawData
|
@@ -1,4 +1,5 @@
|
|
1
1
|
import '@operato/data-grist'
|
2
|
+
import '@operato/context/ox-context-page-toolbar.js'
|
2
3
|
import '@operato/board/ox-board-viewer.js'
|
3
4
|
|
4
5
|
import gql from 'graphql-tag'
|
@@ -6,14 +7,13 @@ import { css, html } from 'lit'
|
|
6
7
|
import { customElement, property, query, state } from 'lit/decorators.js'
|
7
8
|
import { connect } from 'pwa-helpers/connect-mixin'
|
8
9
|
|
9
|
-
import {
|
10
|
+
import { getRenderer, DataGrist, FetchOption } from '@operato/data-grist'
|
10
11
|
import { OxDataUseCase } from '@operato/dataset'
|
11
12
|
import { client } from '@operato/graphql'
|
12
13
|
import { i18next, localize } from '@operato/i18n'
|
13
14
|
import { openPopup } from '@operato/layout'
|
14
15
|
import { navigate, PageView, store } from '@operato/shell'
|
15
|
-
import {
|
16
|
-
import { OxPopup } from '@operato/popup'
|
16
|
+
import { CommonHeaderStyles, ScrollbarStyles } from '@operato/styles'
|
17
17
|
import { encodeUrlParams } from '@operato/utils'
|
18
18
|
|
19
19
|
import { provider } from '@things-factory/board-ui'
|
@@ -120,7 +120,7 @@ const showReportView = (columns, data, column, record, rowIndex) => {
|
|
120
120
|
export class DataReportListPage extends connect(store)(localize(i18next)(PageView)) {
|
121
121
|
static styles = [
|
122
122
|
ScrollbarStyles,
|
123
|
-
|
123
|
+
CommonHeaderStyles,
|
124
124
|
css`
|
125
125
|
:host {
|
126
126
|
display: flex;
|
@@ -130,17 +130,23 @@ export class DataReportListPage extends connect(store)(localize(i18next)(PageVie
|
|
130
130
|
--grid-record-emphasized-background-color: red;
|
131
131
|
--grid-record-emphasized-color: yellow;
|
132
132
|
}
|
133
|
+
|
134
|
+
ox-grist {
|
135
|
+
overflow-y: auto;
|
136
|
+
flex: 1;
|
137
|
+
}
|
133
138
|
`
|
134
139
|
]
|
135
140
|
|
136
141
|
@state() gristConfig: any
|
137
142
|
@state() mode: 'CARD' | 'GRID' | 'LIST' = 'CARD'
|
143
|
+
|
138
144
|
@query('ox-grist') private grist!: DataGrist
|
139
|
-
@query('#sorter-control') private sortersControl!: OxPopup
|
140
145
|
|
141
146
|
get context() {
|
142
147
|
return {
|
143
148
|
title: i18next.t('title.data-report list'),
|
149
|
+
help: 'dataset/data-report-list',
|
144
150
|
search: {
|
145
151
|
handler: (search: string) => {
|
146
152
|
this.grist.searchText = search
|
@@ -152,7 +158,7 @@ export class DataReportListPage extends connect(store)(localize(i18next)(PageVie
|
|
152
158
|
this.grist.toggleHeadroom()
|
153
159
|
}
|
154
160
|
},
|
155
|
-
|
161
|
+
toolbar: false
|
156
162
|
}
|
157
163
|
}
|
158
164
|
|
@@ -166,27 +172,17 @@ export class DataReportListPage extends connect(store)(localize(i18next)(PageVie
|
|
166
172
|
.fetchHandler=${this.fetchHandler.bind(this)}
|
167
173
|
?url-params-sensitive=${this.active}
|
168
174
|
>
|
169
|
-
<div slot="headroom">
|
170
|
-
<div
|
171
|
-
<
|
175
|
+
<div slot="headroom" class="header">
|
176
|
+
<div class="title">
|
177
|
+
<mwc-icon>summarize</mwc-icon>
|
178
|
+
${i18next.t('title.data-report list')}
|
172
179
|
</div>
|
173
180
|
|
174
|
-
<div
|
175
|
-
|
176
|
-
<mwc-icon
|
177
|
-
@click=${e => {
|
178
|
-
const target = e.currentTarget
|
179
|
-
this.sortersControl.open({
|
180
|
-
right: 0,
|
181
|
-
top: target.offsetTop + target.offsetHeight
|
182
|
-
})
|
183
|
-
}}
|
184
|
-
>expand_more</mwc-icon
|
185
|
-
>
|
186
|
-
<ox-popup id="sorter-control">
|
187
|
-
<ox-sorters-control> </ox-sorters-control>
|
188
|
-
</ox-popup>
|
181
|
+
<div class="filters">
|
182
|
+
<ox-filters-form class="filter" autofocus without-search></ox-filters-form>
|
189
183
|
</div>
|
184
|
+
|
185
|
+
<ox-context-page-toolbar class="actions" .context=${this.context}></ox-context-page-toolbar>
|
190
186
|
</div>
|
191
187
|
</ox-grist>
|
192
188
|
`
|
@@ -410,6 +406,7 @@ export class DataReportListPage extends connect(store)(localize(i18next)(PageVie
|
|
410
406
|
name
|
411
407
|
description
|
412
408
|
active
|
409
|
+
hidden
|
413
410
|
tag
|
414
411
|
group
|
415
412
|
type
|
@@ -417,6 +414,7 @@ export class DataReportListPage extends connect(store)(localize(i18next)(PageVie
|
|
417
414
|
options
|
418
415
|
quota
|
419
416
|
spec
|
417
|
+
stat
|
420
418
|
}
|
421
419
|
latestCollectedAt
|
422
420
|
nextSchedule
|
@@ -1,4 +1,5 @@
|
|
1
1
|
import '@operato/data-grist'
|
2
|
+
import '@operato/context/ox-context-page-toolbar.js'
|
2
3
|
import './data-sample-view.js'
|
3
4
|
|
4
5
|
import gql from 'graphql-tag'
|
@@ -7,28 +8,19 @@ import { customElement, property, query, state } from 'lit/decorators.js'
|
|
7
8
|
import { connect } from 'pwa-helpers/connect-mixin'
|
8
9
|
import moment from 'moment-timezone'
|
9
10
|
|
10
|
-
import {
|
11
|
-
getEditor,
|
12
|
-
getRenderer,
|
13
|
-
ColumnConfig,
|
14
|
-
DataGrist,
|
15
|
-
FetchOption,
|
16
|
-
SortersControl,
|
17
|
-
GristRecord
|
18
|
-
} from '@operato/data-grist'
|
11
|
+
import { DataGrist, FetchOption, GristRecord } from '@operato/data-grist'
|
19
12
|
import { client } from '@operato/graphql'
|
20
13
|
import { i18next, localize } from '@operato/i18n'
|
21
14
|
import { openPopup } from '@operato/layout'
|
22
15
|
import { PageView, store } from '@operato/shell'
|
23
|
-
import {
|
16
|
+
import { CommonHeaderStyles, ScrollbarStyles } from '@operato/styles'
|
24
17
|
import { isMobileDevice } from '@operato/utils'
|
25
|
-
import { OxPopup } from '@operato/popup'
|
26
18
|
|
27
19
|
@customElement('data-sample-list-page')
|
28
20
|
export class DataSampleListPage extends connect(store)(localize(i18next)(PageView)) {
|
29
21
|
static styles = [
|
30
22
|
ScrollbarStyles,
|
31
|
-
|
23
|
+
CommonHeaderStyles,
|
32
24
|
css`
|
33
25
|
:host {
|
34
26
|
display: flex;
|
@@ -48,7 +40,6 @@ export class DataSampleListPage extends connect(store)(localize(i18next)(PageVie
|
|
48
40
|
@state() mode: 'CARD' | 'GRID' | 'LIST' = isMobileDevice() ? 'CARD' : 'GRID'
|
49
41
|
|
50
42
|
@query('ox-grist') private grist!: DataGrist
|
51
|
-
@query('#sorter-control') private sortersControl!: OxPopup
|
52
43
|
|
53
44
|
get context() {
|
54
45
|
return {
|
@@ -69,7 +60,8 @@ export class DataSampleListPage extends connect(store)(localize(i18next)(PageVie
|
|
69
60
|
exportable: {
|
70
61
|
name: i18next.t('title.data-sample list'),
|
71
62
|
data: this._exportableData.bind(this)
|
72
|
-
}
|
63
|
+
},
|
64
|
+
toolbar: false
|
73
65
|
}
|
74
66
|
}
|
75
67
|
|
@@ -83,33 +75,17 @@ export class DataSampleListPage extends connect(store)(localize(i18next)(PageVie
|
|
83
75
|
.fetchHandler=${this.fetchHandler.bind(this)}
|
84
76
|
?url-params-sensitive=${false /* this.active */}
|
85
77
|
>
|
86
|
-
<div slot="headroom">
|
87
|
-
<div
|
88
|
-
<
|
78
|
+
<div slot="headroom" class="header">
|
79
|
+
<div class="title">
|
80
|
+
<mwc-icon>summarize</mwc-icon>
|
81
|
+
${i18next.t('title.data-sample list')}
|
89
82
|
</div>
|
90
83
|
|
91
|
-
<div
|
92
|
-
|
93
|
-
<mwc-icon
|
94
|
-
@click=${e => {
|
95
|
-
const target = e.currentTarget
|
96
|
-
this.sortersControl.open({
|
97
|
-
right: 0,
|
98
|
-
top: target.offsetTop + target.offsetHeight
|
99
|
-
})
|
100
|
-
}}
|
101
|
-
>expand_more</mwc-icon
|
102
|
-
>
|
103
|
-
<ox-popup id="sorter-control">
|
104
|
-
<ox-sorters-control> </ox-sorters-control>
|
105
|
-
</ox-popup>
|
84
|
+
<div class="filters">
|
85
|
+
<ox-filters-form class="filter" autofocus without-search></ox-filters-form>
|
106
86
|
</div>
|
107
87
|
|
108
|
-
<
|
109
|
-
<mwc-icon @click=${() => (this.mode = 'GRID')} ?active=${mode == 'GRID'}>grid_on</mwc-icon>
|
110
|
-
<mwc-icon @click=${() => (this.mode = 'LIST')} ?active=${mode == 'LIST'}>format_list_bulleted</mwc-icon>
|
111
|
-
<mwc-icon @click=${() => (this.mode = 'CARD')} ?active=${mode == 'CARD'}>apps</mwc-icon>
|
112
|
-
</div>
|
88
|
+
<ox-context-page-toolbar class="actions" .context=${this.context}></ox-context-page-toolbar>
|
113
89
|
</div>
|
114
90
|
</ox-grist>
|
115
91
|
`
|