@things-factory/dataset 5.0.0-alpha.1 → 5.0.0-alpha.2
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/bootstrap.js +0 -2
- package/client/pages/data-item-list.js +9 -0
- package/client/pages/data-sample.js +30 -5
- package/client/pages/data-sensor.js +451 -0
- package/client/pages/data-set.js +12 -3
- package/client/route.js +4 -0
- package/dist-server/routes.js +64 -0
- package/dist-server/routes.js.map +1 -1
- package/dist-server/service/data-item/data-item-type.js +4 -4
- package/dist-server/service/data-item/data-item-type.js.map +1 -1
- package/dist-server/service/data-item/data-item.js +7 -0
- package/dist-server/service/data-item/data-item.js.map +1 -1
- package/dist-server/service/data-sample/data-sample-mutation.js +5 -5
- package/dist-server/service/data-sample/data-sample-mutation.js.map +1 -1
- package/dist-server/service/data-sample/data-sample-type.js +20 -0
- package/dist-server/service/data-sample/data-sample-type.js.map +1 -1
- package/dist-server/service/data-sample/data-sample.js +39 -0
- package/dist-server/service/data-sample/data-sample.js.map +1 -1
- package/dist-server/service/data-sensor/data-sensor-mutation.js +120 -0
- package/dist-server/service/data-sensor/data-sensor-mutation.js.map +1 -0
- package/dist-server/service/data-sensor/data-sensor-query.js +108 -0
- package/dist-server/service/data-sensor/data-sensor-query.js.map +1 -0
- package/dist-server/service/data-sensor/data-sensor-type.js +147 -0
- package/dist-server/service/data-sensor/data-sensor-type.js.map +1 -0
- package/dist-server/service/data-sensor/data-sensor.js +168 -0
- package/dist-server/service/data-sensor/data-sensor.js.map +1 -0
- package/dist-server/service/data-sensor/index.js +9 -0
- package/dist-server/service/data-sensor/index.js.map +1 -0
- package/dist-server/service/data-set/data-set-type.js +17 -0
- package/dist-server/service/data-set/data-set-type.js.map +1 -1
- package/dist-server/service/data-set/data-set.js +19 -0
- package/dist-server/service/data-set/data-set.js.map +1 -1
- package/dist-server/service/index.js +4 -0
- package/dist-server/service/index.js.map +1 -1
- package/package.json +12 -11
- package/server/routes.ts +76 -0
- package/server/service/data-item/data-item-type.ts +3 -3
- package/server/service/data-item/data-item.ts +6 -0
- package/server/service/data-sample/data-sample-mutation.ts +6 -3
- package/server/service/data-sample/data-sample-type.ts +15 -0
- package/server/service/data-sample/data-sample.ts +35 -0
- package/server/service/data-sensor/data-sensor-mutation.ts +110 -0
- package/server/service/data-sensor/data-sensor-query.ts +56 -0
- package/server/service/data-sensor/data-sensor-type.ts +98 -0
- package/server/service/data-sensor/data-sensor.ts +139 -0
- package/server/service/data-sensor/index.ts +6 -0
- package/server/service/data-set/data-set-type.ts +14 -0
- package/server/service/data-set/data-set.ts +17 -1
- package/server/service/index.ts +4 -0
- package/things-factory.config.js +4 -0
- package/translations/en.json +16 -5
- package/translations/ko.json +15 -4
- package/translations/ms.json +16 -5
- package/translations/zh.json +16 -5
@@ -0,0 +1,110 @@
|
|
1
|
+
import { Arg, Ctx, Directive, Mutation, Resolver } from 'type-graphql'
|
2
|
+
import { In } from 'typeorm'
|
3
|
+
|
4
|
+
import { DataSensor } from './data-sensor'
|
5
|
+
import { DataSensorPatch, NewDataSensor } from './data-sensor-type'
|
6
|
+
|
7
|
+
@Resolver(DataSensor)
|
8
|
+
export class DataSensorMutation {
|
9
|
+
@Directive('@transaction')
|
10
|
+
@Mutation(returns => DataSensor, { description: 'To create new DataSensor' })
|
11
|
+
async createDataSensor(@Arg('dataSensor') dataSensor: NewDataSensor, @Ctx() context: any): Promise<DataSensor> {
|
12
|
+
const { domain, user, tx } = context.state
|
13
|
+
|
14
|
+
return await tx.getRepository(DataSensor).save({
|
15
|
+
...dataSensor,
|
16
|
+
domain,
|
17
|
+
creator: user,
|
18
|
+
updater: user
|
19
|
+
})
|
20
|
+
}
|
21
|
+
|
22
|
+
@Directive('@transaction')
|
23
|
+
@Mutation(returns => DataSensor, { description: 'To modify DataSensor information' })
|
24
|
+
async updateDataSensor(
|
25
|
+
@Arg('id') id: string,
|
26
|
+
@Arg('patch') patch: DataSensorPatch,
|
27
|
+
@Ctx() context: any
|
28
|
+
): Promise<DataSensor> {
|
29
|
+
const { domain, user, tx } = context.state
|
30
|
+
|
31
|
+
const repository = tx.getRepository(DataSensor)
|
32
|
+
const dataSensor = await repository.findOne({
|
33
|
+
where: { domain, id }
|
34
|
+
})
|
35
|
+
|
36
|
+
return await repository.save({
|
37
|
+
...dataSensor,
|
38
|
+
...patch,
|
39
|
+
updater: user
|
40
|
+
})
|
41
|
+
}
|
42
|
+
|
43
|
+
@Directive('@transaction')
|
44
|
+
@Mutation(returns => [DataSensor], { description: "To modify multiple DataSensors' information" })
|
45
|
+
async updateMultipleDataSensor(
|
46
|
+
@Arg('patches', type => [DataSensorPatch]) patches: DataSensorPatch[],
|
47
|
+
@Ctx() context: any
|
48
|
+
): Promise<DataSensor[]> {
|
49
|
+
const { domain, user, tx } = context.state
|
50
|
+
|
51
|
+
let results = []
|
52
|
+
const _createRecords = patches.filter((patch: any) => patch.cuFlag.toUpperCase() === '+')
|
53
|
+
const _updateRecords = patches.filter((patch: any) => patch.cuFlag.toUpperCase() === 'M')
|
54
|
+
const dataSensorRepo = tx.getRepository(DataSensor)
|
55
|
+
|
56
|
+
if (_createRecords.length > 0) {
|
57
|
+
for (let i = 0; i < _createRecords.length; i++) {
|
58
|
+
const newRecord = _createRecords[i]
|
59
|
+
|
60
|
+
const result = await dataSensorRepo.save({
|
61
|
+
...newRecord,
|
62
|
+
domain,
|
63
|
+
creator: user,
|
64
|
+
updater: user
|
65
|
+
})
|
66
|
+
|
67
|
+
results.push({ ...result, cuFlag: '+' })
|
68
|
+
}
|
69
|
+
}
|
70
|
+
|
71
|
+
if (_updateRecords.length > 0) {
|
72
|
+
for (let i = 0; i < _updateRecords.length; i++) {
|
73
|
+
const newRecord = _updateRecords[i]
|
74
|
+
const dataSensor = await dataSensorRepo.findOne(newRecord.id)
|
75
|
+
|
76
|
+
const result = await dataSensorRepo.save({
|
77
|
+
...dataSensor,
|
78
|
+
...newRecord,
|
79
|
+
updater: user
|
80
|
+
})
|
81
|
+
|
82
|
+
results.push({ ...result, cuFlag: 'M' })
|
83
|
+
}
|
84
|
+
}
|
85
|
+
|
86
|
+
return results
|
87
|
+
}
|
88
|
+
|
89
|
+
@Directive('@transaction')
|
90
|
+
@Mutation(returns => Boolean, { description: 'To delete DataSensor' })
|
91
|
+
async deleteDataSensor(@Arg('id') id: string, @Ctx() context: any): Promise<boolean> {
|
92
|
+
const { domain, tx } = context.state
|
93
|
+
|
94
|
+
await tx.getRepository(DataSensor).delete({ domain, id })
|
95
|
+
return true
|
96
|
+
}
|
97
|
+
|
98
|
+
@Directive('@transaction')
|
99
|
+
@Mutation(returns => Boolean, { description: 'To delete multiple dataSensors' })
|
100
|
+
async deleteDataSensors(@Arg('ids', type => [String]) ids: string[], @Ctx() context: any): Promise<boolean> {
|
101
|
+
const { domain, tx } = context.state
|
102
|
+
|
103
|
+
await tx.getRepository(DataSensor).delete({
|
104
|
+
domain,
|
105
|
+
id: In(ids)
|
106
|
+
})
|
107
|
+
|
108
|
+
return true
|
109
|
+
}
|
110
|
+
}
|
@@ -0,0 +1,56 @@
|
|
1
|
+
import { Arg, Args, Ctx, FieldResolver, Query, Resolver, Root } from 'type-graphql'
|
2
|
+
import { getRepository } from 'typeorm'
|
3
|
+
|
4
|
+
import { Appliance, User } from '@things-factory/auth-base'
|
5
|
+
import { convertListParams, Domain, ListParam } from '@things-factory/shell'
|
6
|
+
|
7
|
+
import { DataSet } from '../data-set/data-set'
|
8
|
+
import { DataSensor } from './data-sensor'
|
9
|
+
import { DataSensorList } from './data-sensor-type'
|
10
|
+
|
11
|
+
@Resolver(DataSensor)
|
12
|
+
export class DataSensorQuery {
|
13
|
+
@Query(returns => DataSensor, { description: 'To fetch a DataSensor' })
|
14
|
+
async dataSensor(@Arg('id') id: string, @Ctx() context: any): Promise<DataSensor> {
|
15
|
+
const { domain } = context.state
|
16
|
+
|
17
|
+
return await getRepository(DataSensor).findOne({
|
18
|
+
where: { domain, id }
|
19
|
+
})
|
20
|
+
}
|
21
|
+
|
22
|
+
@Query(returns => DataSensorList, { description: 'To fetch multiple DataSensors' })
|
23
|
+
async dataSensors(@Args() params: ListParam, @Ctx() context: any): Promise<DataSensorList> {
|
24
|
+
const { domain } = context.state
|
25
|
+
|
26
|
+
const convertedParams = convertListParams(params, domain.id)
|
27
|
+
const [items, total] = await getRepository(DataSensor).findAndCount(convertedParams)
|
28
|
+
|
29
|
+
return { items, total }
|
30
|
+
}
|
31
|
+
|
32
|
+
@FieldResolver(type => Appliance)
|
33
|
+
async appliance(@Root() dataSensor: DataSensor): Promise<Appliance> {
|
34
|
+
return await getRepository(Appliance).findOne(dataSensor.applianceId || '')
|
35
|
+
}
|
36
|
+
|
37
|
+
@FieldResolver(type => Appliance)
|
38
|
+
async dataSet(@Root() dataSensor: DataSensor): Promise<DataSet> {
|
39
|
+
return await getRepository(DataSet).findOne(dataSensor.dataSetId || '')
|
40
|
+
}
|
41
|
+
|
42
|
+
@FieldResolver(type => Domain)
|
43
|
+
async domain(@Root() dataSensor: DataSensor): Promise<Domain> {
|
44
|
+
return await getRepository(Domain).findOne(dataSensor.domainId)
|
45
|
+
}
|
46
|
+
|
47
|
+
@FieldResolver(type => User)
|
48
|
+
async updater(@Root() dataSensor: DataSensor): Promise<User> {
|
49
|
+
return await getRepository(User).findOne(dataSensor.updaterId)
|
50
|
+
}
|
51
|
+
|
52
|
+
@FieldResolver(type => User)
|
53
|
+
async creator(@Root() dataSensor: DataSensor): Promise<User> {
|
54
|
+
return await getRepository(User).findOne(dataSensor.creatorId)
|
55
|
+
}
|
56
|
+
}
|
@@ -0,0 +1,98 @@
|
|
1
|
+
import { Field, ID, InputType, Int, ObjectType } from 'type-graphql'
|
2
|
+
|
3
|
+
import { ObjectRef } from '@things-factory/shell'
|
4
|
+
|
5
|
+
import { DataSensor } from './data-sensor'
|
6
|
+
|
7
|
+
@InputType()
|
8
|
+
export class NewDataSensor {
|
9
|
+
@Field()
|
10
|
+
name: string
|
11
|
+
|
12
|
+
@Field({ nullable: true })
|
13
|
+
description?: string
|
14
|
+
|
15
|
+
@Field({ nullable: true })
|
16
|
+
active?: boolean
|
17
|
+
|
18
|
+
@Field({ nullable: true })
|
19
|
+
deviceId?: string
|
20
|
+
|
21
|
+
@Field({ nullable: true })
|
22
|
+
serialNo?: string
|
23
|
+
|
24
|
+
@Field({ nullable: true })
|
25
|
+
brand?: string
|
26
|
+
|
27
|
+
@Field({ nullable: true })
|
28
|
+
model?: string
|
29
|
+
|
30
|
+
@Field({ nullable: true })
|
31
|
+
netmask?: string
|
32
|
+
|
33
|
+
@Field({ nullable: true })
|
34
|
+
tag?: string
|
35
|
+
|
36
|
+
@Field({ nullable: true })
|
37
|
+
refBy?: String
|
38
|
+
|
39
|
+
@Field(type => ObjectRef, { nullable: true })
|
40
|
+
appliance?: ObjectRef
|
41
|
+
|
42
|
+
@Field(type => ObjectRef, { nullable: true })
|
43
|
+
dataSet?: ObjectRef
|
44
|
+
}
|
45
|
+
|
46
|
+
@InputType()
|
47
|
+
export class DataSensorPatch {
|
48
|
+
@Field(type => ID, { nullable: true })
|
49
|
+
id?: string
|
50
|
+
|
51
|
+
@Field({ nullable: true })
|
52
|
+
name?: string
|
53
|
+
|
54
|
+
@Field({ nullable: true })
|
55
|
+
description?: string
|
56
|
+
|
57
|
+
@Field({ nullable: true })
|
58
|
+
active?: boolean
|
59
|
+
|
60
|
+
@Field({ nullable: true })
|
61
|
+
deviceId?: string
|
62
|
+
|
63
|
+
@Field({ nullable: true })
|
64
|
+
serialNo?: string
|
65
|
+
|
66
|
+
@Field({ nullable: true })
|
67
|
+
brand?: string
|
68
|
+
|
69
|
+
@Field({ nullable: true })
|
70
|
+
model?: string
|
71
|
+
|
72
|
+
@Field({ nullable: true })
|
73
|
+
netmask?: string
|
74
|
+
|
75
|
+
@Field({ nullable: true })
|
76
|
+
tag?: string
|
77
|
+
|
78
|
+
@Field({ nullable: true })
|
79
|
+
refBy?: String
|
80
|
+
|
81
|
+
@Field(type => ObjectRef, { nullable: true })
|
82
|
+
appliance: ObjectRef
|
83
|
+
|
84
|
+
@Field(type => ObjectRef, { nullable: true })
|
85
|
+
dataSet?: ObjectRef
|
86
|
+
|
87
|
+
@Field()
|
88
|
+
cuFlag: string
|
89
|
+
}
|
90
|
+
|
91
|
+
@ObjectType()
|
92
|
+
export class DataSensorList {
|
93
|
+
@Field(type => [DataSensor])
|
94
|
+
items: DataSensor[]
|
95
|
+
|
96
|
+
@Field(type => Int)
|
97
|
+
total: number
|
98
|
+
}
|
@@ -0,0 +1,139 @@
|
|
1
|
+
import { Field, ID, ObjectType } from 'type-graphql'
|
2
|
+
import {
|
3
|
+
Column,
|
4
|
+
CreateDateColumn,
|
5
|
+
Entity,
|
6
|
+
Index,
|
7
|
+
ManyToOne,
|
8
|
+
PrimaryGeneratedColumn,
|
9
|
+
RelationId,
|
10
|
+
UpdateDateColumn
|
11
|
+
} from 'typeorm'
|
12
|
+
|
13
|
+
import { Appliance, User } from '@things-factory/auth-base'
|
14
|
+
import { Domain } from '@things-factory/shell'
|
15
|
+
|
16
|
+
import { DataSet } from '../data-set/data-set'
|
17
|
+
|
18
|
+
@Entity()
|
19
|
+
@Index('ix_data_sensor_0', (dataSensor: DataSensor) => [dataSensor.domain, dataSensor.name], { unique: true })
|
20
|
+
@Index('ix_data_sensor_1', (dataSensor: DataSensor) => [dataSensor.deviceId], { unique: true })
|
21
|
+
@Index('ix_data_sensor_2', (dataSensor: DataSensor) => [dataSensor.domain, dataSensor.refBy], {
|
22
|
+
unique: false
|
23
|
+
})
|
24
|
+
@Index('ix_data_sensor_3', (dataSensor: DataSensor) => [dataSensor.domain, dataSensor.serialNo], {
|
25
|
+
unique: false
|
26
|
+
})
|
27
|
+
@ObjectType({ description: 'Entity for DataSensor' })
|
28
|
+
export class DataSensor {
|
29
|
+
@PrimaryGeneratedColumn('uuid')
|
30
|
+
@Field(type => ID)
|
31
|
+
readonly id: string
|
32
|
+
|
33
|
+
@ManyToOne(type => Domain)
|
34
|
+
@Field({ nullable: true })
|
35
|
+
domain?: Domain
|
36
|
+
|
37
|
+
@RelationId((dataSensor: DataSensor) => dataSensor.domain)
|
38
|
+
domainId?: string
|
39
|
+
|
40
|
+
@Column()
|
41
|
+
@Field()
|
42
|
+
name: string
|
43
|
+
|
44
|
+
@Column({
|
45
|
+
nullable: true
|
46
|
+
})
|
47
|
+
@Field({ nullable: true })
|
48
|
+
description?: string
|
49
|
+
|
50
|
+
@Column({
|
51
|
+
nullable: true
|
52
|
+
})
|
53
|
+
@Field({ nullable: true })
|
54
|
+
active?: boolean
|
55
|
+
|
56
|
+
@Column({
|
57
|
+
nullable: true
|
58
|
+
})
|
59
|
+
@Field({ nullable: true })
|
60
|
+
deviceId?: string
|
61
|
+
|
62
|
+
@Column({
|
63
|
+
nullable: true
|
64
|
+
})
|
65
|
+
@Field({ nullable: true })
|
66
|
+
serialNo?: string
|
67
|
+
|
68
|
+
@Column({
|
69
|
+
nullable: true
|
70
|
+
})
|
71
|
+
@Field({ nullable: true })
|
72
|
+
brand?: string
|
73
|
+
|
74
|
+
@Column({
|
75
|
+
nullable: true
|
76
|
+
})
|
77
|
+
@Field({ nullable: true })
|
78
|
+
model?: string
|
79
|
+
|
80
|
+
@Column({
|
81
|
+
nullable: true
|
82
|
+
})
|
83
|
+
@Field({ nullable: true })
|
84
|
+
netmask?: string
|
85
|
+
|
86
|
+
@Column({
|
87
|
+
nullable: true
|
88
|
+
})
|
89
|
+
@Field({ nullable: true })
|
90
|
+
tag?: string
|
91
|
+
|
92
|
+
@Column({ nullable: true })
|
93
|
+
@Field({ nullable: true })
|
94
|
+
refBy?: String
|
95
|
+
|
96
|
+
@ManyToOne(type => Appliance, {
|
97
|
+
nullable: true
|
98
|
+
})
|
99
|
+
@Field({ nullable: true })
|
100
|
+
appliance?: Appliance
|
101
|
+
|
102
|
+
@RelationId((dataSensor: DataSensor) => dataSensor.appliance)
|
103
|
+
applianceId?: string
|
104
|
+
|
105
|
+
@ManyToOne(type => DataSet, {
|
106
|
+
nullable: true
|
107
|
+
})
|
108
|
+
@Field({ nullable: true })
|
109
|
+
dataSet?: DataSet
|
110
|
+
|
111
|
+
@RelationId((dataSensor: DataSensor) => dataSensor.dataSet)
|
112
|
+
dataSetId?: string
|
113
|
+
|
114
|
+
@CreateDateColumn()
|
115
|
+
@Field({ nullable: true })
|
116
|
+
createdAt?: Date
|
117
|
+
|
118
|
+
@UpdateDateColumn()
|
119
|
+
@Field({ nullable: true })
|
120
|
+
updatedAt?: Date
|
121
|
+
|
122
|
+
@ManyToOne(type => User, {
|
123
|
+
nullable: true
|
124
|
+
})
|
125
|
+
@Field({ nullable: true })
|
126
|
+
creator?: User
|
127
|
+
|
128
|
+
@RelationId((dataSensor: DataSensor) => dataSensor.creator)
|
129
|
+
creatorId?: string
|
130
|
+
|
131
|
+
@ManyToOne(type => User, {
|
132
|
+
nullable: true
|
133
|
+
})
|
134
|
+
@Field({ nullable: true })
|
135
|
+
updater?: User
|
136
|
+
|
137
|
+
@RelationId((dataSensor: DataSensor) => dataSensor.creator)
|
138
|
+
updaterId?: string
|
139
|
+
}
|
@@ -1,5 +1,7 @@
|
|
1
1
|
import { Field, ID, InputType, Int, ObjectType } from 'type-graphql'
|
2
2
|
|
3
|
+
import { ScalarObject } from '@things-factory/shell'
|
4
|
+
|
3
5
|
import { DataSet } from './data-set'
|
4
6
|
|
5
7
|
@InputType()
|
@@ -13,6 +15,12 @@ export class NewDataSet {
|
|
13
15
|
@Field({ nullable: true })
|
14
16
|
active?: boolean
|
15
17
|
|
18
|
+
@Field({ nullable: true })
|
19
|
+
type?: string
|
20
|
+
|
21
|
+
@Field(type => ScalarObject, { nullable: true })
|
22
|
+
partitionKeys?: object
|
23
|
+
|
16
24
|
@Field({ nullable: true })
|
17
25
|
schedule?: string
|
18
26
|
|
@@ -34,6 +42,12 @@ export class DataSetPatch {
|
|
34
42
|
@Field({ nullable: true })
|
35
43
|
active?: boolean
|
36
44
|
|
45
|
+
@Field({ nullable: true })
|
46
|
+
type?: string
|
47
|
+
|
48
|
+
@Field(type => ScalarObject, { nullable: true })
|
49
|
+
partitionKeys?: object
|
50
|
+
|
37
51
|
@Field({ nullable: true })
|
38
52
|
schedule?: string
|
39
53
|
|
@@ -12,7 +12,7 @@ import {
|
|
12
12
|
} from 'typeorm'
|
13
13
|
|
14
14
|
import { User } from '@things-factory/auth-base'
|
15
|
-
import { Domain } from '@things-factory/shell'
|
15
|
+
import { Domain, ScalarObject } from '@things-factory/shell'
|
16
16
|
|
17
17
|
import { DataItem } from '../data-item/data-item'
|
18
18
|
import { DataSample } from '../data-sample/data-sample'
|
@@ -48,6 +48,22 @@ export class DataSet {
|
|
48
48
|
@Field({ nullable: true })
|
49
49
|
active?: boolean
|
50
50
|
|
51
|
+
@Column({
|
52
|
+
nullable: true
|
53
|
+
})
|
54
|
+
@Field({ nullable: true })
|
55
|
+
type?: string
|
56
|
+
|
57
|
+
@Column('simple-json', { nullable: true })
|
58
|
+
@Field(type => ScalarObject, { nullable: true })
|
59
|
+
partitionKeys?: object
|
60
|
+
|
61
|
+
@Column({
|
62
|
+
nullable: true
|
63
|
+
})
|
64
|
+
@Field({ nullable: true })
|
65
|
+
slugger?: string
|
66
|
+
|
51
67
|
@OneToMany(type => DataItem, dataItem => dataItem.dataSet)
|
52
68
|
@Field(type => [DataItem], { nullable: true })
|
53
69
|
dataItems: DataItem[]
|
package/server/service/index.ts
CHANGED
@@ -1,15 +1,18 @@
|
|
1
1
|
/* IMPORT ENTITIES AND RESOLVERS */
|
2
|
+
import { entities as DataSensorEntities, resolvers as DataSensorResolvers } from './data-sensor'
|
2
3
|
import { entities as DataSampleEntities, resolvers as DataSampleResolvers } from './data-sample'
|
3
4
|
import { entities as DataItemEntities, resolvers as DataItemResolvers } from './data-item'
|
4
5
|
import { entities as DataSetEntities, resolvers as DataSetResolvers } from './data-set'
|
5
6
|
|
6
7
|
/* EXPORT ENTITY TYPES */
|
8
|
+
export * from './data-sensor/data-sensor'
|
7
9
|
export * from './data-sample/data-sample'
|
8
10
|
export * from './data-item/data-item'
|
9
11
|
export * from './data-set/data-set'
|
10
12
|
|
11
13
|
export const entities = [
|
12
14
|
/* ENTITIES */
|
15
|
+
...DataSensorEntities,
|
13
16
|
...DataSampleEntities,
|
14
17
|
...DataItemEntities,
|
15
18
|
...DataSetEntities
|
@@ -18,6 +21,7 @@ export const entities = [
|
|
18
21
|
export const schema = {
|
19
22
|
resolverClasses: [
|
20
23
|
/* RESOLVER CLASSES */
|
24
|
+
...DataSensorResolvers,
|
21
25
|
...DataSampleResolvers,
|
22
26
|
...DataItemResolvers,
|
23
27
|
...DataSetResolvers
|
package/things-factory.config.js
CHANGED
package/translations/en.json
CHANGED
@@ -1,8 +1,19 @@
|
|
1
1
|
{
|
2
|
-
"field.
|
3
|
-
"field.
|
2
|
+
"field.appliance": "appliance",
|
3
|
+
"field.collected_at": "collected at",
|
4
4
|
"field.data": "data",
|
5
|
+
"field.data-set": "data set",
|
6
|
+
"field.device-id": "device id",
|
7
|
+
"field.netmask": "network mask",
|
8
|
+
"field.partition-keys": "partition keys",
|
9
|
+
"field.quota": "sampling #",
|
10
|
+
"field.raw-data": "raw data",
|
11
|
+
"field.ref-by": "ref. by",
|
12
|
+
"field.serial-no": "serial #",
|
13
|
+
"field.spec": "spec",
|
14
|
+
"field.tag": "tag name",
|
5
15
|
"title.data-item list": "data item list",
|
6
|
-
"title.data-
|
7
|
-
"title.data-
|
8
|
-
|
16
|
+
"title.data-sample list": "data sample list",
|
17
|
+
"title.data-sensor list": "data sensor list",
|
18
|
+
"title.data-set list": "data set list"
|
19
|
+
}
|
package/translations/ko.json
CHANGED
@@ -1,8 +1,19 @@
|
|
1
1
|
{
|
2
|
+
"field.appliance": "어플라이언스",
|
3
|
+
"field.collected_at": "수집일시",
|
4
|
+
"field.data": "데이타",
|
5
|
+
"field.data-set": "데이타셋",
|
6
|
+
"field.device-id": "디바이스 아이디",
|
7
|
+
"field.netmask": "네트워크마스크",
|
8
|
+
"field.partition-keys": "파티션 키",
|
2
9
|
"field.quota": "샘플수",
|
10
|
+
"field.raw-data": "데이타 원본",
|
11
|
+
"field.ref-by": "참조아이템",
|
12
|
+
"field.serial-no": "시리얼번호",
|
3
13
|
"field.spec": "명세",
|
4
|
-
"field.
|
14
|
+
"field.tag": "태크이름",
|
5
15
|
"title.data-item list": "데이타 아이템 조회",
|
6
|
-
"title.data-
|
7
|
-
"title.data-
|
8
|
-
|
16
|
+
"title.data-sample list": "데이타 샘플 조회",
|
17
|
+
"title.data-sensor list": "데이타 센서 조회",
|
18
|
+
"title.data-set list": "데이타 셋 조회"
|
19
|
+
}
|
package/translations/ms.json
CHANGED
@@ -1,8 +1,19 @@
|
|
1
1
|
{
|
2
|
-
"field.
|
3
|
-
"field.
|
2
|
+
"field.appliance": "appliance",
|
3
|
+
"field.collected_at": "collected at",
|
4
4
|
"field.data": "data",
|
5
|
+
"field.data-set": "data set",
|
6
|
+
"field.device-id": "device id",
|
7
|
+
"field.netmask": "network mask",
|
8
|
+
"field.partition-keys": "partition keys",
|
9
|
+
"field.quota": "sampling #",
|
10
|
+
"field.raw-data": "raw data",
|
11
|
+
"field.ref-by": "ref. by",
|
12
|
+
"field.serial-no": "serial #",
|
13
|
+
"field.spec": "spec",
|
14
|
+
"field.tag": "tag name",
|
5
15
|
"title.data-item list": "data item list",
|
6
|
-
"title.data-
|
7
|
-
"title.data-
|
8
|
-
|
16
|
+
"title.data-sample list": "data sample list",
|
17
|
+
"title.data-sensor list": "data sensor list",
|
18
|
+
"title.data-set list": "data set list"
|
19
|
+
}
|
package/translations/zh.json
CHANGED
@@ -1,8 +1,19 @@
|
|
1
1
|
{
|
2
|
-
"field.
|
3
|
-
"field.
|
2
|
+
"field.appliance": "appliance",
|
3
|
+
"field.collected_at": "collected at",
|
4
4
|
"field.data": "data",
|
5
|
+
"field.data-set": "data set",
|
6
|
+
"field.device-id": "device id",
|
7
|
+
"field.netmask": "network mask",
|
8
|
+
"field.partition-keys": "partition keys",
|
9
|
+
"field.quota": "sampling #",
|
10
|
+
"field.raw-data": "raw data",
|
11
|
+
"field.ref-by": "ref. by",
|
12
|
+
"field.serial-no": "serial #",
|
13
|
+
"field.spec": "spec",
|
14
|
+
"field.tag": "tag name",
|
5
15
|
"title.data-item list": "data item list",
|
6
|
-
"title.data-
|
7
|
-
"title.data-
|
8
|
-
|
16
|
+
"title.data-sample list": "data sample list",
|
17
|
+
"title.data-sensor list": "data sensor list",
|
18
|
+
"title.data-set list": "data set list"
|
19
|
+
}
|