@things-factory/dataset 6.0.29 → 6.0.30

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,6 +1,6 @@
1
1
  {
2
2
  "name": "@things-factory/dataset",
3
- "version": "6.0.29",
3
+ "version": "6.0.30",
4
4
  "main": "dist-server/index.js",
5
5
  "browser": "dist-client/index.js",
6
6
  "things-factory": true,
@@ -40,12 +40,12 @@
40
40
  "@things-factory/board-service": "^6.0.28",
41
41
  "@things-factory/env": "^6.0.7",
42
42
  "@things-factory/organization": "^6.0.28",
43
- "@things-factory/scheduler-client": "^6.0.29",
43
+ "@things-factory/scheduler-client": "^6.0.30",
44
44
  "@things-factory/shell": "^6.0.28",
45
45
  "@things-factory/work-shift": "^6.0.28",
46
46
  "@things-factory/worklist": "^6.0.28",
47
47
  "cron-parser": "^4.3.0",
48
48
  "moment-timezone": "^0.5.40"
49
49
  },
50
- "gitHead": "1ed1aec497f19c6b3f4bcf63be648c1c68aa8447"
50
+ "gitHead": "5c7c95e8edd7b72bcb6240d07b4ffe0b1fccce88"
51
51
  }
@@ -1 +0,0 @@
1
- import '@operato/dataset/ox-data-sample-view.js';
@@ -1,154 +0,0 @@
1
- import { __decorate, __metadata } from "tslib";
2
- import '@operato/dataset/ox-data-sample-view.js';
3
- import gql from 'graphql-tag';
4
- import { css, html, LitElement } from 'lit';
5
- import { customElement, property, query, state } from 'lit/decorators.js';
6
- import { client } from '@operato/graphql';
7
- import { i18next, localize } from '@operato/i18n';
8
- import { ScrollbarStyles } from '@operato/styles';
9
- let DataOocActivityView = class DataOocActivityView extends localize(i18next)(LitElement) {
10
- render() {
11
- var _a;
12
- const comment = (_a = this.output) === null || _a === void 0 ? void 0 : _a.comment;
13
- return html `
14
- <div content>
15
- <ox-data-sample-view .dataSample=${this.dataOoc}></ox-data-sample-view>
16
- </div>
17
-
18
- <label comment>
19
- <div><mwc-icon>build_circle</mwc-icon> <span>correction activity</span></div>
20
- <textarea
21
- placeholder="조치 내용을 입력해주세요."
22
- .value=${comment || ''}
23
- @change=${this.onChangeComment}
24
- ></textarea>
25
- </label>
26
- `;
27
- }
28
- onChangeComment(e) {
29
- this.output = this.output || {};
30
- this.output.comment = e.target.value;
31
- this.dispatchEvent(new CustomEvent('change', {
32
- detail: this.output
33
- }));
34
- }
35
- updated(changes) {
36
- if (changes.has('input')) {
37
- this.fetchDataOoc();
38
- }
39
- }
40
- async fetchDataOoc() {
41
- const id = this.input.dataOocId;
42
- if (id) {
43
- const response = await client.query({
44
- query: gql `
45
- query ($id: String!) {
46
- dataOoc(id: $id) {
47
- id
48
- name
49
- description
50
- ooc
51
- oos
52
- state
53
- type
54
- useCase
55
- data
56
- judgment
57
- dataItems {
58
- name
59
- description
60
- active
61
- tag
62
- type
63
- unit
64
- options
65
- quota
66
- spec
67
- }
68
- workDate
69
- workShift
70
- collectedAt
71
- }
72
- }
73
- `,
74
- variables: {
75
- id
76
- }
77
- });
78
- this.dataOoc = response.data.dataOoc;
79
- }
80
- }
81
- };
82
- DataOocActivityView.styles = [
83
- ScrollbarStyles,
84
- css `
85
- :host {
86
- display: flex;
87
- flex-direction: column;
88
-
89
- background-color: #fff;
90
- }
91
-
92
- div[content] {
93
- flex: 1;
94
- flex-direction: column;
95
-
96
- display: flex;
97
- overflow: auto;
98
- }
99
-
100
- ox-data-ooc-view {
101
- flex: 1;
102
- padding: var(--padding-wide);
103
- overflow: auto;
104
- }
105
-
106
- label[comment] {
107
- display: flex;
108
- flex-direction: column;
109
-
110
- padding: var(--padding-wide);
111
- }
112
-
113
- label[comment] div {
114
- display: flex;
115
- }
116
-
117
- mwc-icon {
118
- color: var(--status-danger-color);
119
- }
120
-
121
- textarea {
122
- border: var(--input-field-border);
123
- border-radius: var(--input-border-radius);
124
- padding: var(--input-field-padding);
125
- font: var(--input-field-font);
126
- }
127
-
128
- .button-container {
129
- display: flex;
130
- margin-left: auto;
131
- padding: var(--padding-default);
132
- }
133
- `
134
- ];
135
- __decorate([
136
- property({ type: Object }),
137
- __metadata("design:type", Object)
138
- ], DataOocActivityView.prototype, "input", void 0);
139
- __decorate([
140
- property({ type: Object }),
141
- __metadata("design:type", Object)
142
- ], DataOocActivityView.prototype, "output", void 0);
143
- __decorate([
144
- state(),
145
- __metadata("design:type", Object)
146
- ], DataOocActivityView.prototype, "dataOoc", void 0);
147
- __decorate([
148
- query('textarea'),
149
- __metadata("design:type", HTMLTextAreaElement)
150
- ], DataOocActivityView.prototype, "commentTextArea", void 0);
151
- DataOocActivityView = __decorate([
152
- customElement('data-ooc-activity-view')
153
- ], DataOocActivityView);
154
- //# sourceMappingURL=data-ooc-activity-view.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"data-ooc-activity-view.js","sourceRoot":"","sources":["../../client/components/data-ooc-activity-view.ts"],"names":[],"mappings":";AAAA,OAAO,yCAAyC,CAAA;AAEhD,OAAO,GAAG,MAAM,aAAa,CAAA;AAC7B,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,KAAK,CAAA;AAC3C,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAA;AAEzE,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAA;AACzC,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAA;AACjD,OAAO,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAA;AAGjD,IAAM,mBAAmB,GAAzB,MAAM,mBAAoB,SAAQ,QAAQ,CAAC,OAAO,CAAC,CAAC,UAAU,CAAC;IA8D7D,MAAM;;QACJ,MAAM,OAAO,GAAG,MAAA,IAAI,CAAC,MAAM,0CAAE,OAAO,CAAA;QAEpC,OAAO,IAAI,CAAA;;2CAE4B,IAAI,CAAC,OAAO;;;;;;;mBAOpC,OAAO,IAAI,EAAE;oBACZ,IAAI,CAAC,eAAe;;;KAGnC,CAAA;IACH,CAAC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B","sourcesContent":["import '@operato/dataset/ox-data-sample-view.js'\n\nimport gql from 'graphql-tag'\nimport { css, html, LitElement } from 'lit'\nimport { customElement, property, query, state } from 'lit/decorators.js'\n\nimport { client } from '@operato/graphql'\nimport { i18next, localize } from '@operato/i18n'\nimport { ScrollbarStyles } from '@operato/styles'\n\n@customElement('data-ooc-activity-view')\nclass DataOocActivityView extends localize(i18next)(LitElement) {\n static styles = [\n ScrollbarStyles,\n css`\n :host {\n display: flex;\n flex-direction: column;\n\n background-color: #fff;\n }\n\n div[content] {\n flex: 1;\n flex-direction: column;\n\n display: flex;\n overflow: auto;\n }\n\n ox-data-ooc-view {\n flex: 1;\n padding: var(--padding-wide);\n overflow: auto;\n }\n\n label[comment] {\n display: flex;\n flex-direction: column;\n\n padding: var(--padding-wide);\n }\n\n label[comment] div {\n display: flex;\n }\n\n mwc-icon {\n color: var(--status-danger-color);\n }\n\n textarea {\n border: var(--input-field-border);\n border-radius: var(--input-border-radius);\n padding: var(--input-field-padding);\n font: var(--input-field-font);\n }\n\n .button-container {\n display: flex;\n margin-left: auto;\n padding: var(--padding-default);\n }\n `\n ]\n\n @property({ type: Object }) input?: any\n @property({ type: Object }) output?: any\n\n @state() dataOoc?: any\n\n @query('textarea') commentTextArea!: HTMLTextAreaElement\n\n render() {\n const comment = this.output?.comment\n\n return html`\n <div content>\n <ox-data-sample-view .dataSample=${this.dataOoc}></ox-data-sample-view>\n </div>\n\n <label comment>\n <div><mwc-icon>build_circle</mwc-icon> <span>correction activity</span></div>\n <textarea\n placeholder=\"조치 내용을 입력해주세요.\"\n .value=${comment || ''}\n @change=${this.onChangeComment}\n ></textarea>\n </label>\n `\n }\n\n onChangeComment(e: Event) {\n this.output = this.output || {}\n this.output.comment = (e.target as HTMLTextAreaElement).value\n\n this.dispatchEvent(\n new CustomEvent('change', {\n detail: this.output\n })\n )\n }\n\n updated(changes) {\n if (changes.has('input')) {\n this.fetchDataOoc()\n }\n }\n\n async fetchDataOoc() {\n const id = this.input.dataOocId\n\n if (id) {\n const response = await client.query({\n query: gql`\n query ($id: String!) {\n dataOoc(id: $id) {\n id\n name\n description\n ooc\n oos\n state\n type\n useCase\n data\n judgment\n dataItems {\n name\n description\n active\n tag\n type\n unit\n options\n quota\n spec\n }\n workDate\n workShift\n collectedAt\n }\n }\n `,\n variables: {\n id\n }\n })\n\n this.dataOoc = response.data.dataOoc\n }\n }\n}\n"]}
@@ -1,59 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ActivityOoc = void 0;
4
- exports.ActivityOoc = {
5
- name: 'OOC Review',
6
- description: 'Task to take remedial action based on Out Of Control data',
7
- release: '1.0.0',
8
- provider: 'hatiolab.com',
9
- category: 'quality',
10
- activityType: 'user',
11
- startable: true,
12
- model: [
13
- {
14
- name: 'dataOocId',
15
- description: 'OOC id',
16
- tag: 'dataOocId',
17
- hidden: true,
18
- mandatory: true,
19
- inout: 'in',
20
- type: 'string',
21
- options: {},
22
- unit: null,
23
- quantifier: [1],
24
- spec: {}
25
- },
26
- {
27
- name: 'Instruction',
28
- description: 'Instructions for preventing OOC',
29
- tag: 'instruction',
30
- hidden: false,
31
- mandatory: true,
32
- inout: 'in',
33
- type: 'textarea',
34
- options: {},
35
- unit: null,
36
- quantifier: [1],
37
- spec: {}
38
- },
39
- {
40
- name: 'action',
41
- description: 'Action Description',
42
- tag: 'action',
43
- hidden: false,
44
- mandatory: true,
45
- inout: 'out',
46
- type: 'textarea',
47
- options: {},
48
- unit: null,
49
- quantifier: [1],
50
- spec: {}
51
- }
52
- ],
53
- uiType: 'custom-element',
54
- uiSource: 'data-ooc-activity-view',
55
- reportType: 'page',
56
- reportSource: 'data-ooc-report-page',
57
- thumbnail: '/assets/images/ooc.png'
58
- };
59
- //# sourceMappingURL=activity-ooc.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"activity-ooc.js","sourceRoot":"","sources":["../../../server/controllers/activity-template/activity-ooc.ts"],"names":[],"mappings":";;;AAAa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C Review',\n description: 'Task to take remedial action based on Out Of Control data',\n release: '1.0.0',\n provider: 'hatiolab.com',\n category: 'quality',\n activityType: 'user',\n startable: true,\n model: [\n {\n name: 'dataOocId',\n description: 'OOC id',\n tag: 'dataOocId',\n hidden: true,\n mandatory: true,\n inout: 'in',\n type: 'string',\n options: {},\n unit: null,\n quantifier: [1],\n spec: {}\n },\n {\n name: 'Instruction',\n description: 'Instructions for preventing OOC',\n tag: 'instruction',\n hidden: false,\n mandatory: true,\n inout: 'in',\n type: 'textarea',\n options: {},\n unit: null,\n quantifier: [1],\n spec: {}\n },\n {\n name: 'action',\n description: 'Action Description',\n tag: 'action',\n hidden: false,\n mandatory: true,\n inout: 'out',\n type: 'textarea',\n options: {},\n unit: null,\n quantifier: [1],\n spec: {}\n }\n ],\n uiType: 'custom-element',\n uiSource: 'data-ooc-activity-view',\n reportType: 'page',\n reportSource: 'data-ooc-report-page',\n thumbnail: '/assets/images/ooc.png'\n}\n"]}