@things-factory/code-base 8.0.74 → 8.0.76

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/code-base",
3
- "version": "8.0.74",
3
+ "version": "8.0.76",
4
4
  "main": "dist-server/index.js",
5
5
  "browser": "dist-client/index.js",
6
6
  "things-factory": true,
@@ -28,8 +28,8 @@
28
28
  },
29
29
  "dependencies": {
30
30
  "@operato/graphql": "^8.0.0",
31
- "@things-factory/auth-base": "^8.0.74",
31
+ "@things-factory/auth-base": "^8.0.75",
32
32
  "@things-factory/shell": "^8.0.64"
33
33
  },
34
- "gitHead": "52ffc383d8baed71dd99a2bc85f4253b3fe69977"
34
+ "gitHead": "de45e79c9fb5d62db235e7aaeabd3ff972daa15d"
35
35
  }
@@ -70,6 +70,11 @@ export class CommonCodeDetailMutation {
70
70
  for (let i = 0; i < _createRecords.length; i++) {
71
71
  const newRecord = _createRecords[i]
72
72
 
73
+ // 기존 description 필드 - 현재 locale로 기본값 넣어줌
74
+ if (!newRecord.description) {
75
+ newRecord.description = newRecord.labels[user.locale] || ''
76
+ }
77
+
73
78
  if (newRecord.commonCode && newRecord.commonCode.id) {
74
79
  newRecord.commonCode = await commonCodeRepo.findOneBy({ id: newRecord.commonCode.id })
75
80
  }
@@ -90,6 +95,11 @@ export class CommonCodeDetailMutation {
90
95
  const newRecord = _updateRecords[i]
91
96
  const commonCodeDetail = await commonCodeDetailRepo.findOneBy({ id: newRecord.id })
92
97
 
98
+ // 기존 description 필드 - 현재 locale로 기본값 넣어줌
99
+ if (!commonCodeDetail.description) {
100
+ newRecord.description = newRecord.labels[user.locale] || ''
101
+ }
102
+
93
103
  if (newRecord.commonCode && newRecord.commonCode.id) {
94
104
  newRecord.commonCode = await commonCodeRepo.findOneBy({ id: newRecord.commonCode.id })
95
105
  }
@@ -33,6 +33,7 @@ export class CommonCodeDetailQuery {
33
33
  alias: 'ccd',
34
34
  searchables: ['name', 'description']
35
35
  })
36
+ queryBuilder.orderBy('CAST(ccd.rank AS INTEGER)', 'ASC')
36
37
 
37
38
  const [items, total] = await queryBuilder.getManyAndCount()
38
39