@cap-js/change-tracking 1.1.0 → 1.1.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/CHANGELOG.md +29 -1
- package/README.md +33 -1
- package/_i18n/i18n_ar.properties +55 -0
- package/_i18n/i18n_bg.properties +55 -0
- package/_i18n/i18n_cs.properties +55 -0
- package/_i18n/i18n_da.properties +55 -0
- package/_i18n/i18n_de.properties +55 -55
- package/_i18n/i18n_el.properties +55 -0
- package/_i18n/i18n_en.properties +1 -1
- package/_i18n/i18n_en_US_saptrc.properties +55 -0
- package/_i18n/i18n_es.properties +55 -51
- package/_i18n/i18n_es_MX.properties +55 -0
- package/_i18n/i18n_fi.properties +55 -0
- package/_i18n/i18n_fr.properties +55 -51
- package/_i18n/i18n_he.properties +55 -0
- package/_i18n/i18n_hr.properties +55 -0
- package/_i18n/i18n_hu.properties +55 -0
- package/_i18n/i18n_it.properties +55 -51
- package/_i18n/i18n_ja.properties +11 -3
- package/_i18n/i18n_kk.properties +55 -0
- package/_i18n/i18n_ko.properties +55 -0
- package/_i18n/i18n_ms.properties +55 -0
- package/_i18n/i18n_nl.properties +55 -0
- package/_i18n/i18n_no.properties +55 -0
- package/_i18n/i18n_pl.properties +55 -51
- package/_i18n/i18n_pt.properties +55 -51
- package/_i18n/i18n_ro.properties +55 -0
- package/_i18n/i18n_ru.properties +55 -51
- package/_i18n/i18n_sh.properties +55 -0
- package/_i18n/i18n_sk.properties +55 -0
- package/_i18n/i18n_sl.properties +55 -0
- package/_i18n/i18n_sv.properties +55 -0
- package/_i18n/i18n_th.properties +55 -0
- package/_i18n/i18n_tr.properties +55 -0
- package/_i18n/i18n_uk.properties +55 -0
- package/_i18n/i18n_vi.properties +55 -0
- package/_i18n/i18n_zh_CN.properties +10 -6
- package/_i18n/i18n_zh_TW.properties +55 -0
- package/index.cds +5 -4
- package/lib/change-log.js +25 -17
- package/lib/entity-helper.js +5 -5
- package/lib/format-options.js +66 -0
- package/lib/localization.js +53 -41
- package/lib/template-processor.js +15 -2
- package/package.json +4 -3
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
## Change Table Fields Description##
|
|
2
|
+
####################################
|
|
3
|
+
#XTIT: Field Name
|
|
4
|
+
Changes.ID=ID sprememb
|
|
5
|
+
#XTIT: Field Name
|
|
6
|
+
Changes.entityID=ID objekta
|
|
7
|
+
#XTIT: Field Name
|
|
8
|
+
Changes.parentEntityID=ID nadrejenega objekta
|
|
9
|
+
#XTIT: Field Name
|
|
10
|
+
Changes.parentKey=Nadrejeni klju\u010D
|
|
11
|
+
#XTIT: Field Name
|
|
12
|
+
Changes.serviceEntityPath=Pot entitete storitve
|
|
13
|
+
#XTIT: Field Name
|
|
14
|
+
Changes.attribute=Polje
|
|
15
|
+
#XTIT: Field Name
|
|
16
|
+
Changes.keys=Klju\u010Di sprememb
|
|
17
|
+
#XTIT: Field Name
|
|
18
|
+
Changes.modification=Vrsta spremembe
|
|
19
|
+
#XTIT: Field Name
|
|
20
|
+
Changes.valueChangedFrom=Stara vrednost
|
|
21
|
+
#XTIT: Field Name
|
|
22
|
+
Changes.valueChangedTo=Nova vrednost
|
|
23
|
+
#XTIT: Field Name
|
|
24
|
+
Changes.entity=Tip objekta
|
|
25
|
+
#XTIT: Field Name
|
|
26
|
+
Changes.serviceEntity=Tip objekta storitve
|
|
27
|
+
#XTIT: Field Name
|
|
28
|
+
Changes.valueDataType=Podatkovni tip vrednosti
|
|
29
|
+
|
|
30
|
+
## Change Log Table Fields Description##
|
|
31
|
+
########################################
|
|
32
|
+
#XTIT: Field Name
|
|
33
|
+
ChangeLog.entity=Entiteta
|
|
34
|
+
#XTIT: Field Name
|
|
35
|
+
ChangeLog.entityKey=Klju\u010D entitete
|
|
36
|
+
#XTIT: Field Name
|
|
37
|
+
ChangeLog.serviceEntity=Entiteta storitve
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
## Change Log Modifications##
|
|
41
|
+
########################################
|
|
42
|
+
#XFLD: Field label
|
|
43
|
+
ChangeLog.modification.create=Ustvari
|
|
44
|
+
#XFLD: Field label
|
|
45
|
+
ChangeLog.modification.update=Posodobi
|
|
46
|
+
#XFLD: Field label
|
|
47
|
+
ChangeLog.modification.delete=Izbri\u0161i
|
|
48
|
+
#XFLD: Field label
|
|
49
|
+
ChangeLog.createdAt=Spremenjeno ob
|
|
50
|
+
#XFLD: Field label
|
|
51
|
+
ChangeLog.createdBy=Spremenil
|
|
52
|
+
|
|
53
|
+
## Change History Table##
|
|
54
|
+
########################################
|
|
55
|
+
ChangeHistory=Zgodovina sprememb
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
## Change Table Fields Description##
|
|
2
|
+
####################################
|
|
3
|
+
#XTIT: Field Name
|
|
4
|
+
Changes.ID=\u00C4ndrings-ID
|
|
5
|
+
#XTIT: Field Name
|
|
6
|
+
Changes.entityID=Objekt-ID
|
|
7
|
+
#XTIT: Field Name
|
|
8
|
+
Changes.parentEntityID=ID f\u00F6r \u00F6verordnat objekt
|
|
9
|
+
#XTIT: Field Name
|
|
10
|
+
Changes.parentKey=\u00D6verordnad nyckel
|
|
11
|
+
#XTIT: Field Name
|
|
12
|
+
Changes.serviceEntityPath=S\u00F6kv\u00E4g f\u00F6r tj\u00E4nstentitet
|
|
13
|
+
#XTIT: Field Name
|
|
14
|
+
Changes.attribute=F\u00E4lt
|
|
15
|
+
#XTIT: Field Name
|
|
16
|
+
Changes.keys=\u00C4ndringsnycklar
|
|
17
|
+
#XTIT: Field Name
|
|
18
|
+
Changes.modification=\u00C4ndringsslag
|
|
19
|
+
#XTIT: Field Name
|
|
20
|
+
Changes.valueChangedFrom=Gammalt v\u00E4rde
|
|
21
|
+
#XTIT: Field Name
|
|
22
|
+
Changes.valueChangedTo=Nytt v\u00E4rde
|
|
23
|
+
#XTIT: Field Name
|
|
24
|
+
Changes.entity=Objekttyp
|
|
25
|
+
#XTIT: Field Name
|
|
26
|
+
Changes.serviceEntity=Serviceobjekttyp
|
|
27
|
+
#XTIT: Field Name
|
|
28
|
+
Changes.valueDataType=V\u00E4rdedatatyp
|
|
29
|
+
|
|
30
|
+
## Change Log Table Fields Description##
|
|
31
|
+
########################################
|
|
32
|
+
#XTIT: Field Name
|
|
33
|
+
ChangeLog.entity=Entitet
|
|
34
|
+
#XTIT: Field Name
|
|
35
|
+
ChangeLog.entityKey=Entitetsnyckel
|
|
36
|
+
#XTIT: Field Name
|
|
37
|
+
ChangeLog.serviceEntity=Tj\u00E4nstentitet
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
## Change Log Modifications##
|
|
41
|
+
########################################
|
|
42
|
+
#XFLD: Field label
|
|
43
|
+
ChangeLog.modification.create=Skapa
|
|
44
|
+
#XFLD: Field label
|
|
45
|
+
ChangeLog.modification.update=Uppdatera
|
|
46
|
+
#XFLD: Field label
|
|
47
|
+
ChangeLog.modification.delete=Radera
|
|
48
|
+
#XFLD: Field label
|
|
49
|
+
ChangeLog.createdAt=\u00C4ndring kl.
|
|
50
|
+
#XFLD: Field label
|
|
51
|
+
ChangeLog.createdBy=\u00C4ndring av
|
|
52
|
+
|
|
53
|
+
## Change History Table##
|
|
54
|
+
########################################
|
|
55
|
+
ChangeHistory=\u00C4ndringshistorik
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
## Change Table Fields Description##
|
|
2
|
+
####################################
|
|
3
|
+
#XTIT: Field Name
|
|
4
|
+
Changes.ID=ID \u0E01\u0E32\u0E23\u0E40\u0E1B\u0E25\u0E35\u0E48\u0E22\u0E19\u0E41\u0E1B\u0E25\u0E07
|
|
5
|
+
#XTIT: Field Name
|
|
6
|
+
Changes.entityID=ID \u0E2D\u0E2D\u0E1A\u0E40\u0E08\u0E04
|
|
7
|
+
#XTIT: Field Name
|
|
8
|
+
Changes.parentEntityID=ID \u0E2D\u0E2D\u0E1A\u0E40\u0E08\u0E04\u0E2B\u0E25\u0E31\u0E01
|
|
9
|
+
#XTIT: Field Name
|
|
10
|
+
Changes.parentKey=\u0E04\u0E35\u0E22\u0E4C\u0E2B\u0E25\u0E31\u0E01
|
|
11
|
+
#XTIT: Field Name
|
|
12
|
+
Changes.serviceEntityPath=\u0E1E\u0E32\u0E18\u0E40\u0E2D\u0E19\u0E17\u0E34\u0E15\u0E35\u0E49\u0E01\u0E32\u0E23\u0E1A\u0E23\u0E34\u0E01\u0E32\u0E23
|
|
13
|
+
#XTIT: Field Name
|
|
14
|
+
Changes.attribute=\u0E1F\u0E34\u0E25\u0E14\u0E4C
|
|
15
|
+
#XTIT: Field Name
|
|
16
|
+
Changes.keys=\u0E04\u0E35\u0E22\u0E4C\u0E01\u0E32\u0E23\u0E40\u0E1B\u0E25\u0E35\u0E48\u0E22\u0E19\u0E41\u0E1B\u0E25\u0E07
|
|
17
|
+
#XTIT: Field Name
|
|
18
|
+
Changes.modification=\u0E1B\u0E23\u0E30\u0E40\u0E20\u0E17\u0E01\u0E32\u0E23\u0E40\u0E1B\u0E25\u0E35\u0E48\u0E22\u0E19\u0E41\u0E1B\u0E25\u0E07
|
|
19
|
+
#XTIT: Field Name
|
|
20
|
+
Changes.valueChangedFrom=\u0E04\u0E48\u0E32\u0E40\u0E14\u0E34\u0E21
|
|
21
|
+
#XTIT: Field Name
|
|
22
|
+
Changes.valueChangedTo=\u0E04\u0E48\u0E32\u0E43\u0E2B\u0E21\u0E48
|
|
23
|
+
#XTIT: Field Name
|
|
24
|
+
Changes.entity=\u0E1B\u0E23\u0E30\u0E40\u0E20\u0E17\u0E2D\u0E2D\u0E1A\u0E40\u0E08\u0E04
|
|
25
|
+
#XTIT: Field Name
|
|
26
|
+
Changes.serviceEntity=\u0E1B\u0E23\u0E30\u0E40\u0E20\u0E17\u0E2D\u0E2D\u0E1A\u0E40\u0E08\u0E04\u0E01\u0E32\u0E23\u0E1A\u0E23\u0E34\u0E01\u0E32\u0E23
|
|
27
|
+
#XTIT: Field Name
|
|
28
|
+
Changes.valueDataType=\u0E1B\u0E23\u0E30\u0E40\u0E20\u0E17\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E04\u0E48\u0E32
|
|
29
|
+
|
|
30
|
+
## Change Log Table Fields Description##
|
|
31
|
+
########################################
|
|
32
|
+
#XTIT: Field Name
|
|
33
|
+
ChangeLog.entity=\u0E40\u0E2D\u0E19\u0E17\u0E34\u0E15\u0E35\u0E49
|
|
34
|
+
#XTIT: Field Name
|
|
35
|
+
ChangeLog.entityKey=\u0E04\u0E35\u0E22\u0E4C\u0E40\u0E2D\u0E19\u0E17\u0E34\u0E15\u0E35\u0E49
|
|
36
|
+
#XTIT: Field Name
|
|
37
|
+
ChangeLog.serviceEntity=\u0E40\u0E2D\u0E19\u0E17\u0E34\u0E15\u0E35\u0E49\u0E01\u0E32\u0E23\u0E1A\u0E23\u0E34\u0E01\u0E32\u0E23
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
## Change Log Modifications##
|
|
41
|
+
########################################
|
|
42
|
+
#XFLD: Field label
|
|
43
|
+
ChangeLog.modification.create=\u0E2A\u0E23\u0E49\u0E32\u0E07
|
|
44
|
+
#XFLD: Field label
|
|
45
|
+
ChangeLog.modification.update=\u0E2D\u0E31\u0E1E\u0E40\u0E14\u0E17
|
|
46
|
+
#XFLD: Field label
|
|
47
|
+
ChangeLog.modification.delete=\u0E25\u0E1A
|
|
48
|
+
#XFLD: Field label
|
|
49
|
+
ChangeLog.createdAt=\u0E40\u0E1B\u0E25\u0E35\u0E48\u0E22\u0E19\u0E41\u0E1B\u0E25\u0E07\u0E40\u0E21\u0E37\u0E48\u0E2D
|
|
50
|
+
#XFLD: Field label
|
|
51
|
+
ChangeLog.createdBy=\u0E40\u0E1B\u0E25\u0E35\u0E48\u0E22\u0E19\u0E41\u0E1B\u0E25\u0E07\u0E42\u0E14\u0E22
|
|
52
|
+
|
|
53
|
+
## Change History Table##
|
|
54
|
+
########################################
|
|
55
|
+
ChangeHistory=\u0E1B\u0E23\u0E30\u0E27\u0E31\u0E15\u0E34\u0E01\u0E32\u0E23\u0E40\u0E1B\u0E25\u0E35\u0E48\u0E22\u0E19\u0E41\u0E1B\u0E25\u0E07
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
## Change Table Fields Description##
|
|
2
|
+
####################################
|
|
3
|
+
#XTIT: Field Name
|
|
4
|
+
Changes.ID=De\u011Fi\u015Fiklikler tan\u0131t\u0131c\u0131s\u0131
|
|
5
|
+
#XTIT: Field Name
|
|
6
|
+
Changes.entityID=Nesne tan\u0131t\u0131c\u0131s\u0131
|
|
7
|
+
#XTIT: Field Name
|
|
8
|
+
Changes.parentEntityID=\u00DCst d\u00FCzey nesne tan\u0131t\u0131c\u0131s\u0131
|
|
9
|
+
#XTIT: Field Name
|
|
10
|
+
Changes.parentKey=\u00DCst d\u00FCzey anahtar
|
|
11
|
+
#XTIT: Field Name
|
|
12
|
+
Changes.serviceEntityPath=Servis birimi yolu
|
|
13
|
+
#XTIT: Field Name
|
|
14
|
+
Changes.attribute=Alan
|
|
15
|
+
#XTIT: Field Name
|
|
16
|
+
Changes.keys=De\u011Fi\u015Fiklikler anahtarlar\u0131
|
|
17
|
+
#XTIT: Field Name
|
|
18
|
+
Changes.modification=De\u011Fi\u015Fiklik t\u00FCr\u00FC
|
|
19
|
+
#XTIT: Field Name
|
|
20
|
+
Changes.valueChangedFrom=Eski de\u011Fer
|
|
21
|
+
#XTIT: Field Name
|
|
22
|
+
Changes.valueChangedTo=Yeni de\u011Fer
|
|
23
|
+
#XTIT: Field Name
|
|
24
|
+
Changes.entity=Nesne t\u00FCr\u00FC
|
|
25
|
+
#XTIT: Field Name
|
|
26
|
+
Changes.serviceEntity=Servis nesnesi t\u00FCr\u00FC
|
|
27
|
+
#XTIT: Field Name
|
|
28
|
+
Changes.valueDataType=De\u011Fer verileri t\u00FCr\u00FC
|
|
29
|
+
|
|
30
|
+
## Change Log Table Fields Description##
|
|
31
|
+
########################################
|
|
32
|
+
#XTIT: Field Name
|
|
33
|
+
ChangeLog.entity=Birim
|
|
34
|
+
#XTIT: Field Name
|
|
35
|
+
ChangeLog.entityKey=Birim anahtar\u0131
|
|
36
|
+
#XTIT: Field Name
|
|
37
|
+
ChangeLog.serviceEntity=Servis birimi
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
## Change Log Modifications##
|
|
41
|
+
########################################
|
|
42
|
+
#XFLD: Field label
|
|
43
|
+
ChangeLog.modification.create=Olu\u015Ftur
|
|
44
|
+
#XFLD: Field label
|
|
45
|
+
ChangeLog.modification.update=G\u00FCncelle
|
|
46
|
+
#XFLD: Field label
|
|
47
|
+
ChangeLog.modification.delete=Sil
|
|
48
|
+
#XFLD: Field label
|
|
49
|
+
ChangeLog.createdAt=De\u011Fi\u015Fiklik saati
|
|
50
|
+
#XFLD: Field label
|
|
51
|
+
ChangeLog.createdBy=De\u011Fi\u015Ftiren
|
|
52
|
+
|
|
53
|
+
## Change History Table##
|
|
54
|
+
########################################
|
|
55
|
+
ChangeHistory=De\u011Fi\u015Fiklik ge\u00E7mi\u015Fi
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
## Change Table Fields Description##
|
|
2
|
+
####################################
|
|
3
|
+
#XTIT: Field Name
|
|
4
|
+
Changes.ID=\u0406\u0414 \u0437\u043C\u0456\u043D
|
|
5
|
+
#XTIT: Field Name
|
|
6
|
+
Changes.entityID=\u0406\u0414 \u043E\u0431\u2019\u0454\u043A\u0442\u0430
|
|
7
|
+
#XTIT: Field Name
|
|
8
|
+
Changes.parentEntityID=\u0406\u0414 \u0431\u0430\u0442\u044C\u043A\u0456\u0432\u0441\u044C\u043A\u043E\u0433\u043E \u043E\u0431\u2019\u0454\u043A\u0442\u0430
|
|
9
|
+
#XTIT: Field Name
|
|
10
|
+
Changes.parentKey=\u0411\u0430\u0442\u044C\u043A\u0456\u0432\u0441\u044C\u043A\u0438\u0439 \u043A\u043B\u044E\u0447
|
|
11
|
+
#XTIT: Field Name
|
|
12
|
+
Changes.serviceEntityPath=\u0428\u043B\u044F\u0445 \u0434\u043E \u0441\u0443\u0442\u043D\u043E\u0441\u0442\u0456 \u0441\u0435\u0440\u0432\u0456\u0441\u0443
|
|
13
|
+
#XTIT: Field Name
|
|
14
|
+
Changes.attribute=\u041F\u043E\u043B\u0435
|
|
15
|
+
#XTIT: Field Name
|
|
16
|
+
Changes.keys=\u041A\u043B\u044E\u0447\u0456 \u0437\u043C\u0456\u043D
|
|
17
|
+
#XTIT: Field Name
|
|
18
|
+
Changes.modification=\u0422\u0438\u043F \u0437\u043C\u0456\u043D\u0438
|
|
19
|
+
#XTIT: Field Name
|
|
20
|
+
Changes.valueChangedFrom=\u0421\u0442\u0430\u0440\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F
|
|
21
|
+
#XTIT: Field Name
|
|
22
|
+
Changes.valueChangedTo=\u041D\u043E\u0432\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F
|
|
23
|
+
#XTIT: Field Name
|
|
24
|
+
Changes.entity=\u0422\u0438\u043F \u043E\u0431'\u0454\u043A\u0442\u0430
|
|
25
|
+
#XTIT: Field Name
|
|
26
|
+
Changes.serviceEntity=\u0422\u0438\u043F \u043E\u0431'\u0454\u043A\u0442\u0430 \u0441\u0435\u0440\u0432\u0456\u0441\u0443
|
|
27
|
+
#XTIT: Field Name
|
|
28
|
+
Changes.valueDataType=\u0422\u0438\u043F \u0434\u0430\u043D\u0438\u0445 \u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F
|
|
29
|
+
|
|
30
|
+
## Change Log Table Fields Description##
|
|
31
|
+
########################################
|
|
32
|
+
#XTIT: Field Name
|
|
33
|
+
ChangeLog.entity=\u0421\u0443\u0442\u043D\u0456\u0441\u0442\u044C
|
|
34
|
+
#XTIT: Field Name
|
|
35
|
+
ChangeLog.entityKey=\u041A\u043B\u044E\u0447 \u0441\u0443\u0442\u043D\u043E\u0441\u0442\u0456
|
|
36
|
+
#XTIT: Field Name
|
|
37
|
+
ChangeLog.serviceEntity=\u0421\u0443\u0442\u043D\u0456\u0441\u0442\u044C \u0441\u0435\u0440\u0432\u0456\u0441\u0443
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
## Change Log Modifications##
|
|
41
|
+
########################################
|
|
42
|
+
#XFLD: Field label
|
|
43
|
+
ChangeLog.modification.create=\u0421\u0442\u0432\u043E\u0440\u0438\u0442\u0438
|
|
44
|
+
#XFLD: Field label
|
|
45
|
+
ChangeLog.modification.update=\u041E\u043D\u043E\u0432\u0438\u0442\u0438
|
|
46
|
+
#XFLD: Field label
|
|
47
|
+
ChangeLog.modification.delete=\u0412\u0438\u0434\u0430\u043B\u0438\u0442\u0438
|
|
48
|
+
#XFLD: Field label
|
|
49
|
+
ChangeLog.createdAt=\u0427\u0430\u0441 \u0437\u043C\u0456\u043D\u0438
|
|
50
|
+
#XFLD: Field label
|
|
51
|
+
ChangeLog.createdBy=\u0410\u0432\u0442\u043E\u0440 \u0437\u043C\u0456\u043D\u0438
|
|
52
|
+
|
|
53
|
+
## Change History Table##
|
|
54
|
+
########################################
|
|
55
|
+
ChangeHistory=\u0406\u0441\u0442\u043E\u0440\u0456\u044F \u0437\u043C\u0456\u043D
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
## Change Table Fields Description##
|
|
2
|
+
####################################
|
|
3
|
+
#XTIT: Field Name
|
|
4
|
+
Changes.ID=M\u00E3 thay \u0111\u1ED5i
|
|
5
|
+
#XTIT: Field Name
|
|
6
|
+
Changes.entityID=M\u00E3 \u0111\u00F4\u0301i t\u01B0\u01A1\u0323ng
|
|
7
|
+
#XTIT: Field Name
|
|
8
|
+
Changes.parentEntityID=M\u00E3 \u0111\u00F4\u0301i t\u01B0\u01A1\u0323ng m\u1EB9
|
|
9
|
+
#XTIT: Field Name
|
|
10
|
+
Changes.parentKey=Kh\u00F3a ch\u00EDnh
|
|
11
|
+
#XTIT: Field Name
|
|
12
|
+
Changes.serviceEntityPath=\u0110\u01B0\u01A1\u0300ng d\u00E2\u0303n \u0111\u1EBFn th\u1EF1c th\u00EA\u0309 d\u1ECBch v\u1EE5
|
|
13
|
+
#XTIT: Field Name
|
|
14
|
+
Changes.attribute=Tr\u01B0\u01A1\u0300ng
|
|
15
|
+
#XTIT: Field Name
|
|
16
|
+
Changes.keys=Kh\u00F3a thay \u0111\u1ED5i
|
|
17
|
+
#XTIT: Field Name
|
|
18
|
+
Changes.modification=Lo\u1EA1i thay \u0111\u1ED5i
|
|
19
|
+
#XTIT: Field Name
|
|
20
|
+
Changes.valueChangedFrom=Gia\u0301 tri\u0323 cu\u0303
|
|
21
|
+
#XTIT: Field Name
|
|
22
|
+
Changes.valueChangedTo=Gia\u0301 tri\u0323 m\u01A1\u0301i
|
|
23
|
+
#XTIT: Field Name
|
|
24
|
+
Changes.entity=Loa\u0323i \u0111\u00F4\u0301i t\u01B0\u01A1\u0323ng
|
|
25
|
+
#XTIT: Field Name
|
|
26
|
+
Changes.serviceEntity=Loa\u0323i \u0111\u00F4\u0301i t\u01B0\u01A1\u0323ng d\u1ECBch v\u1EE5
|
|
27
|
+
#XTIT: Field Name
|
|
28
|
+
Changes.valueDataType=Lo\u1EA1i d\u1EEF li\u1EC7u gi\u00E1 tr\u1ECB
|
|
29
|
+
|
|
30
|
+
## Change Log Table Fields Description##
|
|
31
|
+
########################################
|
|
32
|
+
#XTIT: Field Name
|
|
33
|
+
ChangeLog.entity=Th\u01B0\u0323c th\u00EA\u0309
|
|
34
|
+
#XTIT: Field Name
|
|
35
|
+
ChangeLog.entityKey=Kh\u00F3a th\u1EF1c th\u1EC3
|
|
36
|
+
#XTIT: Field Name
|
|
37
|
+
ChangeLog.serviceEntity=Th\u1EF1c th\u1EC3 d\u1ECBch v\u1EE5
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
## Change Log Modifications##
|
|
41
|
+
########################################
|
|
42
|
+
#XFLD: Field label
|
|
43
|
+
ChangeLog.modification.create=Ta\u0323o
|
|
44
|
+
#XFLD: Field label
|
|
45
|
+
ChangeLog.modification.update=C\u00E2\u0323p nh\u00E2\u0323t
|
|
46
|
+
#XFLD: Field label
|
|
47
|
+
ChangeLog.modification.delete=Xo\u0301a
|
|
48
|
+
#XFLD: Field label
|
|
49
|
+
ChangeLog.createdAt=Thay \u0111\u00F4\u0309i lu\u0301c
|
|
50
|
+
#XFLD: Field label
|
|
51
|
+
ChangeLog.createdBy=Thay \u0111\u00F4\u0309i b\u01A1\u0309i
|
|
52
|
+
|
|
53
|
+
## Change History Table##
|
|
54
|
+
########################################
|
|
55
|
+
ChangeHistory=Li\u0323ch s\u01B0\u0309 thay \u0111\u00F4\u0309i
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
## Change Table Fields Description##
|
|
2
2
|
####################################
|
|
3
3
|
#XTIT: Field Name
|
|
4
|
-
Changes.ID=\u66F4\
|
|
4
|
+
Changes.ID=\u53D8\u66F4\u6807\u8BC6
|
|
5
5
|
#XTIT: Field Name
|
|
6
6
|
Changes.entityID=\u5BF9\u8C61\u6807\u8BC6
|
|
7
7
|
#XTIT: Field Name
|
|
8
8
|
Changes.parentEntityID=\u7236\u5BF9\u8C61\u6807\u8BC6
|
|
9
9
|
#XTIT: Field Name
|
|
10
|
-
Changes.parentKey=\u7236\
|
|
10
|
+
Changes.parentKey=\u7236\u9879\u952E\u503C
|
|
11
11
|
#XTIT: Field Name
|
|
12
12
|
Changes.serviceEntityPath=\u670D\u52A1\u5B9E\u4F53\u8DEF\u5F84
|
|
13
13
|
#XTIT: Field Name
|
|
14
14
|
Changes.attribute=\u5B57\u6BB5
|
|
15
15
|
#XTIT: Field Name
|
|
16
|
-
Changes.keys=\u66F4\
|
|
16
|
+
Changes.keys=\u53D8\u66F4\u952E\u503C
|
|
17
17
|
#XTIT: Field Name
|
|
18
18
|
Changes.modification=\u66F4\u6539\u7C7B\u578B
|
|
19
19
|
#XTIT: Field Name
|
|
@@ -25,14 +25,14 @@ Changes.entity=\u5BF9\u8C61\u7C7B\u578B
|
|
|
25
25
|
#XTIT: Field Name
|
|
26
26
|
Changes.serviceEntity=\u670D\u52A1\u5BF9\u8C61\u7C7B\u578B
|
|
27
27
|
#XTIT: Field Name
|
|
28
|
-
Changes.valueDataType=\
|
|
28
|
+
Changes.valueDataType=\u503C\u6570\u636E\u7C7B\u578B
|
|
29
29
|
|
|
30
30
|
## Change Log Table Fields Description##
|
|
31
31
|
########################################
|
|
32
32
|
#XTIT: Field Name
|
|
33
33
|
ChangeLog.entity=\u5B9E\u4F53
|
|
34
34
|
#XTIT: Field Name
|
|
35
|
-
ChangeLog.entityKey=\u5B9E\u4F53\
|
|
35
|
+
ChangeLog.entityKey=\u5B9E\u4F53\u952E\u503C
|
|
36
36
|
#XTIT: Field Name
|
|
37
37
|
ChangeLog.serviceEntity=\u670D\u52A1\u5B9E\u4F53
|
|
38
38
|
|
|
@@ -45,7 +45,11 @@ ChangeLog.modification.create=\u521B\u5EFA
|
|
|
45
45
|
ChangeLog.modification.update=\u66F4\u65B0
|
|
46
46
|
#XFLD: Field label
|
|
47
47
|
ChangeLog.modification.delete=\u5220\u9664
|
|
48
|
+
#XFLD: Field label
|
|
49
|
+
ChangeLog.createdAt=\u66F4\u6539\u65F6\u95F4
|
|
50
|
+
#XFLD: Field label
|
|
51
|
+
ChangeLog.createdBy=\u66F4\u6539\u8005
|
|
48
52
|
|
|
49
53
|
## Change History Table##
|
|
50
54
|
########################################
|
|
51
|
-
ChangeHistory=\
|
|
55
|
+
ChangeHistory=\u53D8\u66F4\u5386\u53F2\u8BB0\u5F55
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
## Change Table Fields Description##
|
|
2
|
+
####################################
|
|
3
|
+
#XTIT: Field Name
|
|
4
|
+
Changes.ID=\u66F4\u6539 ID
|
|
5
|
+
#XTIT: Field Name
|
|
6
|
+
Changes.entityID=\u7269\u4EF6 ID
|
|
7
|
+
#XTIT: Field Name
|
|
8
|
+
Changes.parentEntityID=\u4E0A\u5C64\u7269\u4EF6 ID
|
|
9
|
+
#XTIT: Field Name
|
|
10
|
+
Changes.parentKey=\u4E0A\u5C64\u9375\u503C
|
|
11
|
+
#XTIT: Field Name
|
|
12
|
+
Changes.serviceEntityPath=\u670D\u52D9\u5BE6\u9AD4\u8DEF\u5F91
|
|
13
|
+
#XTIT: Field Name
|
|
14
|
+
Changes.attribute=\u6B04\u4F4D
|
|
15
|
+
#XTIT: Field Name
|
|
16
|
+
Changes.keys=\u66F4\u6539\u9375\u503C
|
|
17
|
+
#XTIT: Field Name
|
|
18
|
+
Changes.modification=\u66F4\u6539\u985E\u578B
|
|
19
|
+
#XTIT: Field Name
|
|
20
|
+
Changes.valueChangedFrom=\u820A\u503C
|
|
21
|
+
#XTIT: Field Name
|
|
22
|
+
Changes.valueChangedTo=\u65B0\u503C
|
|
23
|
+
#XTIT: Field Name
|
|
24
|
+
Changes.entity=\u7269\u4EF6\u985E\u578B
|
|
25
|
+
#XTIT: Field Name
|
|
26
|
+
Changes.serviceEntity=\u670D\u52D9\u7269\u4EF6\u985E\u578B
|
|
27
|
+
#XTIT: Field Name
|
|
28
|
+
Changes.valueDataType=\u503C\u8CC7\u6599\u985E\u578B
|
|
29
|
+
|
|
30
|
+
## Change Log Table Fields Description##
|
|
31
|
+
########################################
|
|
32
|
+
#XTIT: Field Name
|
|
33
|
+
ChangeLog.entity=\u5BE6\u9AD4
|
|
34
|
+
#XTIT: Field Name
|
|
35
|
+
ChangeLog.entityKey=\u5BE6\u9AD4\u9375\u503C
|
|
36
|
+
#XTIT: Field Name
|
|
37
|
+
ChangeLog.serviceEntity=\u670D\u52D9\u5BE6\u9AD4
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
## Change Log Modifications##
|
|
41
|
+
########################################
|
|
42
|
+
#XFLD: Field label
|
|
43
|
+
ChangeLog.modification.create=\u5EFA\u7ACB
|
|
44
|
+
#XFLD: Field label
|
|
45
|
+
ChangeLog.modification.update=\u66F4\u65B0
|
|
46
|
+
#XFLD: Field label
|
|
47
|
+
ChangeLog.modification.delete=\u522A\u9664
|
|
48
|
+
#XFLD: Field label
|
|
49
|
+
ChangeLog.createdAt=\u66F4\u6539\u6642\u9593
|
|
50
|
+
#XFLD: Field label
|
|
51
|
+
ChangeLog.createdBy=\u66F4\u6539\u8005
|
|
52
|
+
|
|
53
|
+
## Change History Table##
|
|
54
|
+
########################################
|
|
55
|
+
ChangeHistory=\u66F4\u6539\u6B77\u53F2\u8A18\u9304
|
package/index.cds
CHANGED
|
@@ -13,7 +13,7 @@ namespace sap.changelog;
|
|
|
13
13
|
}]) {
|
|
14
14
|
// Essentially: Association to many Changes on changes.changeLog.entityKey = ID;
|
|
15
15
|
changes : Association to many ChangeView on changes.entityKey = ID;
|
|
16
|
-
key ID :
|
|
16
|
+
key ID : String;
|
|
17
17
|
}
|
|
18
18
|
|
|
19
19
|
|
|
@@ -39,7 +39,7 @@ view ChangeView as
|
|
|
39
39
|
entity ChangeLog : managed, cuid {
|
|
40
40
|
serviceEntity : String(5000) @title: '{i18n>ChangeLog.serviceEntity}'; // definition name of target entity (on service level) - e.g. ProcessorsService.Incidents
|
|
41
41
|
entity : String(5000) @title: '{i18n>ChangeLog.entity}'; // definition name of target entity (on db level) - e.g. sap.capire.incidents.Incidents
|
|
42
|
-
entityKey :
|
|
42
|
+
entityKey : String @title: '{i18n>ChangeLog.entityKey}'; // primary key of target entity, e.g. Incidents.ID
|
|
43
43
|
createdAt : managed:createdAt @title : '{i18n>ChangeLog.createdAt}';
|
|
44
44
|
createdBy : managed:createdBy @title : '{i18n>ChangeLog.createdBy}';
|
|
45
45
|
changes : Composition of many Changes on changes.changeLog = $self;
|
|
@@ -64,7 +64,7 @@ entity Changes {
|
|
|
64
64
|
|
|
65
65
|
// Business meaningful parent object id
|
|
66
66
|
parentEntityID : String(5000) @title: '{i18n>Changes.parentEntityID}';
|
|
67
|
-
parentKey :
|
|
67
|
+
parentKey : String @title: '{i18n>Changes.parentKey}';
|
|
68
68
|
serviceEntityPath : String(5000) @title: '{i18n>Changes.serviceEntityPath}';
|
|
69
69
|
|
|
70
70
|
@title: '{i18n>Changes.modification}'
|
|
@@ -84,7 +84,8 @@ annotate ChangeView with @(UI: {
|
|
|
84
84
|
RequestAtLeast: [
|
|
85
85
|
parentKey,
|
|
86
86
|
serviceEntity,
|
|
87
|
-
serviceEntityPath
|
|
87
|
+
serviceEntityPath,
|
|
88
|
+
valueDataType
|
|
88
89
|
],
|
|
89
90
|
SortOrder : [{
|
|
90
91
|
Property : createdAt,
|
package/lib/change-log.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
const cds = require("@sap/cds")
|
|
2
2
|
const getTemplate = require("@sap/cds/libx/_runtime/common/utils/template") // REVISIT: bad usage of internal stuff
|
|
3
|
-
const templateProcessor = require("./template-processor")
|
|
3
|
+
const {templateProcessor, retrieveFirstKey} = require("./template-processor")
|
|
4
4
|
const LOG = cds.log("change-log")
|
|
5
5
|
|
|
6
6
|
const {
|
|
@@ -150,9 +150,12 @@ const _formatAssociationContext = async function (changes, reqData) {
|
|
|
150
150
|
if (!semkeys.length) continue
|
|
151
151
|
|
|
152
152
|
const ID = a.keys[0].ref[0] || 'ID'
|
|
153
|
-
const [ from, to ] = await cds.db.run ([
|
|
154
|
-
SELECT.
|
|
155
|
-
SELECT.
|
|
153
|
+
const [ [from], [to] ] = await cds.db.run (cds.env.requires['change-tracking'].considerLocalizedValues ? [
|
|
154
|
+
SELECT.localized.from(a.target).where({ [ID]: change.valueChangedFrom }).limit(1),
|
|
155
|
+
SELECT.localized.from(a.target).where({ [ID]: change.valueChangedTo }).limit(1)
|
|
156
|
+
] : [
|
|
157
|
+
SELECT.from(a.target).where({ [ID]: change.valueChangedFrom }).limit(1),
|
|
158
|
+
SELECT.from(a.target).where({ [ID]: change.valueChangedTo }).limit(1)
|
|
156
159
|
])
|
|
157
160
|
|
|
158
161
|
const fromObjId = await getObjectId(reqData, a.target, semkeys, { curObjFromDbQuery: from || undefined }) // Note: ... || undefined is important for subsequent object destructuring with defaults
|
|
@@ -170,7 +173,8 @@ const _getChildChangeObjId = async function (
|
|
|
170
173
|
change,
|
|
171
174
|
childNodeChange,
|
|
172
175
|
curNodePathVal,
|
|
173
|
-
reqData
|
|
176
|
+
reqData,
|
|
177
|
+
target
|
|
174
178
|
) {
|
|
175
179
|
const composition = cds.model.definitions[change.serviceEntity].elements[change.attribute]
|
|
176
180
|
const objIdElements = composition ? composition["@changelog"] : null
|
|
@@ -180,11 +184,12 @@ const _getChildChangeObjId = async function (
|
|
|
180
184
|
reqData,
|
|
181
185
|
curNodePathVal,
|
|
182
186
|
childNodeChange._path,
|
|
187
|
+
target,
|
|
183
188
|
objIdElementNames
|
|
184
189
|
)
|
|
185
190
|
}
|
|
186
191
|
|
|
187
|
-
const _formatCompositionContext = async function (changes, reqData) {
|
|
192
|
+
const _formatCompositionContext = async function (changes, reqData, target) {
|
|
188
193
|
const childNodeChanges = []
|
|
189
194
|
|
|
190
195
|
for (const change of changes) {
|
|
@@ -201,7 +206,8 @@ const _formatCompositionContext = async function (changes, reqData) {
|
|
|
201
206
|
change,
|
|
202
207
|
childNodeChange,
|
|
203
208
|
curNodePathVal,
|
|
204
|
-
reqData
|
|
209
|
+
reqData,
|
|
210
|
+
target
|
|
205
211
|
)
|
|
206
212
|
_formatCompositionValue(curChange, objId, childNodeChange, childNodeChanges)
|
|
207
213
|
}
|
|
@@ -258,17 +264,18 @@ const _getObjectIdByPath = async function (
|
|
|
258
264
|
reqData,
|
|
259
265
|
nodePathVal,
|
|
260
266
|
serviceEntityPath,
|
|
267
|
+
target,
|
|
261
268
|
/**optional*/ objIdElementNames
|
|
262
269
|
) {
|
|
263
270
|
const curObjFromReqData = getCurObjFromReqData(reqData, nodePathVal, serviceEntityPath)
|
|
264
271
|
const entityName = getNameFromPathVal(nodePathVal)
|
|
265
272
|
const entityUUID = getUUIDFromPathVal(nodePathVal)
|
|
266
|
-
const obj = await getCurObjFromDbQuery(entityName, entityUUID)
|
|
273
|
+
const obj = await getCurObjFromDbQuery(entityName, {[retrieveFirstKey(target)]: entityUUID})
|
|
267
274
|
const curObj = { curObjFromReqData, curObjFromDbQuery: obj }
|
|
268
275
|
return getObjectId(reqData, entityName, objIdElementNames, curObj)
|
|
269
276
|
}
|
|
270
277
|
|
|
271
|
-
const _formatObjectID = async function (changes, reqData) {
|
|
278
|
+
const _formatObjectID = async function (changes, reqData, target) {
|
|
272
279
|
const objectIdCache = new Map()
|
|
273
280
|
for (const change of changes) {
|
|
274
281
|
const path = splitPath(change.serviceEntityPath)
|
|
@@ -280,7 +287,8 @@ const _formatObjectID = async function (changes, reqData) {
|
|
|
280
287
|
curNodeObjId = await _getObjectIdByPath(
|
|
281
288
|
reqData,
|
|
282
289
|
curNodePathVal,
|
|
283
|
-
change.serviceEntityPath
|
|
290
|
+
change.serviceEntityPath,
|
|
291
|
+
target
|
|
284
292
|
)
|
|
285
293
|
objectIdCache.set(curNodePathVal, curNodeObjId)
|
|
286
294
|
}
|
|
@@ -290,7 +298,8 @@ const _formatObjectID = async function (changes, reqData) {
|
|
|
290
298
|
parentNodeObjId = await _getObjectIdByPath(
|
|
291
299
|
reqData,
|
|
292
300
|
parentNodePathVal,
|
|
293
|
-
change.serviceEntityPath
|
|
301
|
+
change.serviceEntityPath,
|
|
302
|
+
target
|
|
294
303
|
)
|
|
295
304
|
objectIdCache.set(parentNodePathVal, parentNodeObjId)
|
|
296
305
|
}
|
|
@@ -312,9 +321,9 @@ const _isCompositionContextPath = function (aPath, hasComp) {
|
|
|
312
321
|
}
|
|
313
322
|
|
|
314
323
|
const _formatChangeLog = async function (changes, req) {
|
|
315
|
-
await _formatObjectID(changes, req.data)
|
|
324
|
+
await _formatObjectID(changes, req.data, req.target)
|
|
316
325
|
await _formatAssociationContext(changes, req.data)
|
|
317
|
-
await _formatCompositionContext(changes, req.data)
|
|
326
|
+
await _formatCompositionContext(changes, req.data, req.target)
|
|
318
327
|
}
|
|
319
328
|
|
|
320
329
|
const _afterReadChangeView = function (data, req) {
|
|
@@ -323,13 +332,12 @@ const _afterReadChangeView = function (data, req) {
|
|
|
323
332
|
localizeLogFields(data, req.locale)
|
|
324
333
|
}
|
|
325
334
|
|
|
326
|
-
|
|
327
335
|
function _trackedChanges4 (srv, target, diff) {
|
|
328
336
|
const template = getTemplate("change-logging", srv, target, { pick: e => e['@changelog'] })
|
|
329
337
|
if (!template.elements.size) return
|
|
330
338
|
|
|
331
339
|
const changes = []
|
|
332
|
-
diff._path = `${target.name}(${diff
|
|
340
|
+
diff._path = `${target.name}(${diff[retrieveFirstKey(target)]})`
|
|
333
341
|
|
|
334
342
|
templateProcessor({
|
|
335
343
|
template, row: diff, processFn: ({ row, key, element }) => {
|
|
@@ -413,7 +421,7 @@ const _prepareChangeLogForComposition = async function (entity, entityKey, chang
|
|
|
413
421
|
.join('/')
|
|
414
422
|
|
|
415
423
|
for (const change of changes) {
|
|
416
|
-
change.parentEntityID = await _getObjectIdByPath(req.data, parentEntityPathVal, parentServiceEntityPath)
|
|
424
|
+
change.parentEntityID = await _getObjectIdByPath(req.data, parentEntityPathVal, parentServiceEntityPath, entity)
|
|
417
425
|
change.parentKey = parentKey
|
|
418
426
|
change.serviceEntityPath = serviceEntityPath
|
|
419
427
|
}
|
|
@@ -517,7 +525,7 @@ async function track_changes (req) {
|
|
|
517
525
|
async function trackChangesForDiff(diff, req, that){
|
|
518
526
|
let target = req.target
|
|
519
527
|
let compContext = null;
|
|
520
|
-
let entityKey = diff.
|
|
528
|
+
let entityKey = diff[retrieveFirstKey(req.target)]
|
|
521
529
|
const params = convertSubjectToParams(req.subject);
|
|
522
530
|
if (req.subject.ref.length === 1 && params.length === 1 && !target[isRoot]) {
|
|
523
531
|
compContext = await generatePathAndParams(req, entityKey);
|
package/lib/entity-helper.js
CHANGED
|
@@ -29,10 +29,10 @@ const getObjIdElementNamesInArray = function (elements) {
|
|
|
29
29
|
else return []
|
|
30
30
|
}
|
|
31
31
|
|
|
32
|
-
const getCurObjFromDbQuery = async function (entityName,
|
|
33
|
-
if (!
|
|
32
|
+
const getCurObjFromDbQuery = async function (entityName, whereXpr) {
|
|
33
|
+
if (!Object.keys(whereXpr)) return {}
|
|
34
34
|
// REVISIT: This always reads all elements -> should read required ones only!
|
|
35
|
-
const obj = await SELECT.one.from(entityName).where(
|
|
35
|
+
const obj = await SELECT.one.from(entityName).where(whereXpr)
|
|
36
36
|
return obj || {}
|
|
37
37
|
}
|
|
38
38
|
|
|
@@ -99,10 +99,10 @@ async function getObjectId (reqData, entityName, fields, curObj) {
|
|
|
99
99
|
// When multiple layers of child nodes are deleted at the same time, the deep layer of child nodes will lose the information of the upper nodes, so data needs to be extracted from the db.
|
|
100
100
|
const entityKeys = reqData ? Object.keys(reqData).filter(item => !Object.keys(assoc._target.keys).some(ele => item === ele)) : [];
|
|
101
101
|
if (!_db_data || JSON.stringify(_db_data) === '{}' || entityKeys.length === 0) {
|
|
102
|
-
_db_data = await getCurObjFromDbQuery(assoc._target, IDval
|
|
102
|
+
_db_data = IDval ? await getCurObjFromDbQuery(assoc._target, {[ID]: IDval}) : {};
|
|
103
103
|
}
|
|
104
104
|
} else {
|
|
105
|
-
_db_data = await getCurObjFromDbQuery(assoc._target, IDval
|
|
105
|
+
_db_data = IDval ? await getCurObjFromDbQuery(assoc._target, {[ID]: IDval}) : {};
|
|
106
106
|
}
|
|
107
107
|
} catch (e) {
|
|
108
108
|
LOG.error("Failed to generate object Id for an association entity.", e)
|