@sap/cds-dk 7.0.0 → 7.0.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.
Files changed (81) hide show
  1. package/bin/add.js +34 -38
  2. package/bin/build.js +4 -0
  3. package/bin/cds.js +13 -8
  4. package/bin/compile/index.js +3 -3
  5. package/bin/env.js +4 -1
  6. package/bin/help.js +2 -3
  7. package/lib/bind/bindingManager.js +1 -1
  8. package/lib/bind/bindingResolver.js +1 -1
  9. package/lib/bind/bindingUtil.js +1 -1
  10. package/lib/build/buildTaskEngine.js +1 -1
  11. package/lib/build/provider/buildTaskHandlerFeatureToggles.js +2 -1
  12. package/lib/build/provider/buildTaskHandlerInternal.js +1 -1
  13. package/lib/build/provider/java/index.js +2 -2
  14. package/lib/build/provider/mtx-sidecar/index.js +3 -4
  15. package/lib/build/provider/nodejs/index.js +6 -5
  16. package/lib/build/util.js +8 -0
  17. package/lib/cds.js +2 -2
  18. package/lib/import/asyncapi/parserContext.js +2 -2
  19. package/lib/index.js +6 -0
  20. package/lib/init/constants.js +4 -4
  21. package/lib/init/index.js +37 -38
  22. package/lib/init/template/_merging/registry-mta.js +2 -2
  23. package/lib/init/template/approuter/index.js +12 -8
  24. package/lib/init/template/auditlog/index.js +7 -7
  25. package/lib/init/template/cf-manifest/index.js +5 -5
  26. package/lib/init/template/connectivity/index.js +7 -7
  27. package/lib/init/template/data/index.js +1 -1
  28. package/lib/init/template/destination/index.js +6 -6
  29. package/lib/init/template/enterprise-messaging/index.js +10 -10
  30. package/lib/init/template/enterprise-messaging-shared/index.js +8 -8
  31. package/lib/init/template/extensibility/index.js +6 -6
  32. package/lib/init/template/file-based-messaging/index.js +4 -4
  33. package/lib/init/template/hana/index.js +11 -11
  34. package/lib/init/template/helm/index.js +5 -5
  35. package/lib/init/template/html5-repo/index.js +2 -2
  36. package/lib/init/template/java/index.js +20 -37
  37. package/lib/init/template/kibana/files/mta.yaml.hbs +29 -0
  38. package/lib/init/template/kibana/index.js +55 -0
  39. package/lib/init/template/multitenancy/files/package.json.hbs +0 -3
  40. package/lib/init/template/multitenancy/files/package.sidecar.json.hbs +1 -1
  41. package/lib/init/template/multitenancy/index.js +18 -12
  42. package/lib/init/template/nodejs/files/package.json.hbs +1 -1
  43. package/lib/init/template/nodejs/index.js +12 -19
  44. package/lib/init/template/pipeline/index.js +1 -1
  45. package/lib/init/template/redis-messaging/index.js +7 -7
  46. package/lib/init/template/sample/files/app/_i18n/i18n.properties +3 -32
  47. package/lib/init/template/sample/files/app/_i18n/i18n_de.properties +2 -2
  48. package/lib/init/template/sample/files/app/admin-books/fiori-service.cds +6 -7
  49. package/lib/init/template/sample/files/app/admin-books/webapp/Component.js +3 -3
  50. package/lib/init/template/sample/files/app/admin-books/webapp/i18n/i18n.properties +3 -11
  51. package/lib/init/template/sample/files/app/admin-books/webapp/manifest.json +117 -113
  52. package/lib/init/template/sample/files/app/appconfig/fioriSandboxConfig.json +38 -0
  53. package/lib/init/template/sample/files/app/browse/fiori-service.cds +56 -0
  54. package/lib/init/template/sample/files/app/browse/webapp/Component.js +7 -0
  55. package/lib/init/template/sample/files/app/browse/webapp/i18n/i18n.properties +4 -0
  56. package/lib/init/template/sample/files/app/browse/webapp/manifest.json +139 -0
  57. package/lib/init/template/sample/files/app/common.cds +78 -81
  58. package/lib/init/template/sample/files/app/services.cds +1 -0
  59. package/lib/init/template/samples/index.js +3 -3
  60. package/lib/init/template/sqlite/files/package.json.hbs +1 -21
  61. package/lib/init/template/sqlite/index.js +4 -4
  62. package/lib/init/template/templateBase.js +1 -1
  63. package/lib/init/template/{sample-tiny → tiny-sample}/files/nodejs/db/data-model.cds +1 -1
  64. package/lib/init/template/{sample-tiny → tiny-sample}/files/nodejs/srv/cat-service.cds.hbs +1 -1
  65. package/lib/init/template/{sample-tiny → tiny-sample}/index.js +2 -2
  66. package/lib/init/template/toggles/index.js +3 -3
  67. package/lib/init/template/typer/index.js +6 -5
  68. package/lib/init/template/xsuaa/index.js +9 -9
  69. package/lib/init/util/md5.js +2 -2
  70. package/lib/init/util/merge.js +9 -9
  71. package/lib/init/util/mvn.js +1 -1
  72. package/lib/init/util/projectReader.js +4 -4
  73. package/lib/util/fs.js +10 -10
  74. package/lib/util/term.js +2 -0
  75. package/npm-shrinkwrap.json +281 -334
  76. package/package.json +1 -1
  77. package/lib/init/template/kibana-logging/files/cds.package.json +0 -7
  78. package/lib/init/template/kibana-logging/files/mta.yaml.hbs +0 -14
  79. package/lib/init/template/kibana-logging/index.js +0 -45
  80. /package/lib/init/template/{kibana-logging → kibana}/files/package.json.hbs +0 -0
  81. /package/lib/init/template/{sample-tiny → tiny-sample}/files/nodejs/db/data/my.bookshop-Books.csv +0 -0
@@ -1,129 +1,133 @@
1
1
  {
2
- "_version": "1.8.0",
2
+ "_version": "1.49.0",
3
3
  "sap.app": {
4
- "id": "books",
5
- "type": "application",
6
- "title": "Manage Books",
7
- "description": "Sample Application",
8
- "i18n": "i18n/i18n.properties",
9
- "dataSources": {
10
- "AdminService": {
11
- "uri": "/admin/",
12
- "type": "OData",
13
- "settings": {
14
- "odataVersion": "4.0"
15
- }
16
- }
17
- },
18
- "-sourceTemplate": {
19
- "id": "ui5template.basicSAPUI5ApplicationProject",
20
- "-id": "ui5template.smartTemplate",
21
- "-version": "1.40.12"
4
+ "applicationVersion": {
5
+ "version": "1.0.0"
6
+ },
7
+ "id": "books",
8
+ "type": "application",
9
+ "title": "{{appTitle}}",
10
+ "description": "{{appDescription}}",
11
+ "i18n": "i18n/i18n.properties",
12
+ "dataSources": {
13
+ "AdminService": {
14
+ "uri": "/admin/",
15
+ "type": "OData",
16
+ "settings": {
17
+ "odataVersion": "4.0"
18
+ }
22
19
  }
20
+ }
21
+ },
22
+ "sap.ui": {
23
+ "technology": "UI5",
24
+ "fullWidth": false,
25
+ "deviceTypes": {
26
+ "desktop": true,
27
+ "tablet": true,
28
+ "phone": true
29
+ }
23
30
  },
24
31
  "sap.ui5": {
25
- "dependencies": {
26
- "libs": {
27
- "sap.fe.templates": {}
28
- }
32
+ "dependencies": {
33
+ "minUI5Version": "1.115.1",
34
+ "libs": {
35
+ "sap.fe.templates": {}
36
+ }
37
+ },
38
+ "models": {
39
+ "i18n": {
40
+ "type": "sap.ui.model.resource.ResourceModel",
41
+ "uri": "i18n/i18n.properties"
29
42
  },
30
- "models": {
31
- "i18n": {
32
- "type": "sap.ui.model.resource.ResourceModel",
33
- "uri": "i18n/i18n.properties"
34
- },
35
- "": {
36
- "dataSource": "AdminService",
37
- "settings": {
38
- "synchronizationMode": "None",
39
- "operationMode": "Server",
40
- "autoExpandSelect" : true,
41
- "earlyRequests": true,
42
- "groupProperties": {
43
- "default": {
44
- "submit": "Auto"
45
- }
43
+ "": {
44
+ "dataSource": "AdminService",
45
+ "settings": {
46
+ "synchronizationMode": "None",
47
+ "operationMode": "Server",
48
+ "autoExpandSelect": true,
49
+ "earlyRequests": true,
50
+ "groupProperties": {
51
+ "default": {
52
+ "submit": "Auto"
53
+ }
54
+ }
55
+ }
56
+ }
57
+ },
58
+ "routing": {
59
+ "routes": [
60
+ {
61
+ "pattern": ":?query:",
62
+ "name": "BooksList",
63
+ "target": "BooksList"
64
+ },
65
+ {
66
+ "pattern": "Books({key}):?query:",
67
+ "name": "BooksDetails",
68
+ "target": "BooksDetails"
69
+ },
70
+ {
71
+ "pattern": "Books({key}/author({key2}):?query:",
72
+ "name": "AuthorsDetails",
73
+ "target": "AuthorsDetails"
74
+ }
75
+ ],
76
+ "targets": {
77
+ "BooksList": {
78
+ "type": "Component",
79
+ "id": "BooksList",
80
+ "name": "sap.fe.templates.ListReport",
81
+ "options": {
82
+ "settings": {
83
+ "entitySet": "Books",
84
+ "initialLoad": true,
85
+ "navigation": {
86
+ "Books": {
87
+ "detail": {
88
+ "route": "BooksDetails"
46
89
  }
90
+ }
47
91
  }
92
+ }
48
93
  }
49
- },
50
- "routing": {
51
- "routes": [
52
- {
53
- "pattern": ":?query:",
54
- "name": "BooksList",
55
- "target": "BooksList"
56
- },
57
- {
58
- "pattern": "Books({key}):?query:",
59
- "name": "BooksDetails",
60
- "target": "BooksDetails"
61
- },
62
- {
63
- "pattern": "Books({key}/author({key2}):?query:",
64
- "name": "AuthorsDetails",
65
- "target": "AuthorsDetails"
66
- }
67
- ],
68
- "targets": {
69
- "BooksList": {
70
- "type": "Component",
71
- "id": "BooksList",
72
- "name": "sap.fe.templates.ListReport",
73
- "options": {
74
- "settings" : {
75
- "entitySet" : "Books",
76
- "initialLoad": true,
77
- "navigation" : {
78
- "Books" : {
79
- "detail" : {
80
- "route" : "BooksDetails"
81
- }
82
- }
83
- }
84
- }
85
- }
86
- },
87
- "BooksDetails": {
88
- "type": "Component",
89
- "id": "BooksDetailsList",
90
- "name": "sap.fe.templates.ObjectPage",
91
- "options": {
92
- "settings" : {
93
- "entitySet" : "Books",
94
- "navigation" : {
95
- "Authors" : {
96
- "detail" : {
97
- "route" : "AuthorsDetails"
98
- }
99
- }
100
- }
101
- }
102
- }
103
- },
104
- "AuthorsDetails": {
105
- "type": "Component",
106
- "id": "AuthorsDetailsList",
107
- "name": "sap.fe.templates.ObjectPage",
108
- "options": {
109
- "settings" : {
110
- "entitySet" : "Authors"
111
- }
94
+ },
95
+ "BooksDetails": {
96
+ "type": "Component",
97
+ "id": "BooksDetailsList",
98
+ "name": "sap.fe.templates.ObjectPage",
99
+ "options": {
100
+ "settings": {
101
+ "entitySet": "Books",
102
+ "navigation": {
103
+ "Authors": {
104
+ "detail": {
105
+ "route": "AuthorsDetails"
112
106
  }
107
+ }
113
108
  }
109
+ }
114
110
  }
115
- },
116
- "contentDensities": {
117
- "compact": true,
118
- "cozy": true
111
+ },
112
+ "AuthorsDetails": {
113
+ "type": "Component",
114
+ "id": "AuthorsDetailsList",
115
+ "name": "sap.fe.templates.ObjectPage",
116
+ "options": {
117
+ "settings": {
118
+ "entitySet": "Authors"
119
+ }
120
+ }
121
+ }
119
122
  }
120
- },
121
- "sap.ui": {
122
- "technology": "UI5",
123
- "fullWidth": false
123
+ },
124
+ "contentDensities": {
125
+ "compact": true,
126
+ "cozy": true
127
+ }
124
128
  },
125
129
  "sap.fiori": {
126
- "registrationIds": [],
127
- "archeType": "transactional"
130
+ "registrationIds": [],
131
+ "archeType": "transactional"
128
132
  }
129
- }
133
+ }
@@ -5,6 +5,23 @@
5
5
  "config": {
6
6
  "catalogs": [],
7
7
  "groups": [
8
+ {
9
+ "id": "Bookshop",
10
+ "title": "Bookshop",
11
+ "isPreset": true,
12
+ "isVisible": true,
13
+ "isGroupLocked": false,
14
+ "tiles": [
15
+ {
16
+ "id": "BrowseBooks",
17
+ "tileType": "sap.ushell.ui.tile.StaticTile",
18
+ "properties": {
19
+ "title": "Browse Books",
20
+ "targetURL": "#Books-display"
21
+ }
22
+ }
23
+ ]
24
+ },
8
25
  {
9
26
  "id": "Administration",
10
27
  "title": "Administration",
@@ -35,6 +52,27 @@
35
52
  "adapter": {
36
53
  "config": {
37
54
  "inbounds": {
55
+ "BrowseBooks": {
56
+ "semanticObject": "Books",
57
+ "action": "display",
58
+ "title": "Browse Books",
59
+ "signature": {
60
+ "parameters": {
61
+ "Books.ID": {
62
+ "renameTo": "ID"
63
+ },
64
+ "Authors.books.ID": {
65
+ "renameTo": "ID"
66
+ }
67
+ },
68
+ "additionalParameters": "ignored"
69
+ },
70
+ "resolutionResult": {
71
+ "applicationType": "SAPUI5",
72
+ "additionalInformation": "SAPUI5.Component=bookshop",
73
+ "url": "browse/webapp"
74
+ }
75
+ },
38
76
  "ManageBooks": {
39
77
  "semanticObject": "Books",
40
78
  "action": "manage",
@@ -0,0 +1,56 @@
1
+ using { CatalogService } from '../../srv/cat-service.cds';
2
+
3
+ ////////////////////////////////////////////////////////////////////////////
4
+ //
5
+ // Books Object Page
6
+ //
7
+ annotate CatalogService.Books with @(UI : {
8
+ HeaderInfo: {
9
+ TypeName : 'Book',
10
+ TypeNamePlural: 'Books',
11
+ Description : {Value : author}
12
+ },
13
+ HeaderFacets: [{
14
+ $Type : 'UI.ReferenceFacet',
15
+ Label : '{i18n>Description}',
16
+ Target: '@UI.FieldGroup#Descr'
17
+ }, ],
18
+ Facets: [{
19
+ $Type : 'UI.ReferenceFacet',
20
+ Label : '{i18n>Details}',
21
+ Target: '@UI.FieldGroup#Price'
22
+ }, ],
23
+ FieldGroup #Descr: {Data : [{Value : descr}, ]},
24
+ FieldGroup #Price: {Data : [
25
+ {Value: price},
26
+ {
27
+ Value: currency.symbol,
28
+ Label: '{i18n>Currency}'
29
+ },
30
+ ]},
31
+ });
32
+
33
+ ////////////////////////////////////////////////////////////////////////////
34
+ //
35
+ // Books List Page
36
+ //
37
+ annotate CatalogService.Books with @(UI : {
38
+ SelectionFields: [
39
+ ID,
40
+ price,
41
+ currency_code
42
+ ],
43
+ LineItem: [
44
+ {
45
+ Value: ID,
46
+ Label: '{i18n>Title}'
47
+ },
48
+ {
49
+ Value: author,
50
+ Label: '{i18n>Author}'
51
+ },
52
+ {Value: genre.name},
53
+ {Value: price},
54
+ {Value: currency.symbol},
55
+ ]
56
+ });
@@ -0,0 +1,7 @@
1
+ sap.ui.define(["sap/fe/core/AppComponent"], function(AppComponent) {
2
+ "use strict";
3
+ return AppComponent.extend("bookshop.Component", {
4
+ metadata: { manifest: "json" }
5
+ });
6
+ });
7
+ /* eslint no-undef:0 */
@@ -0,0 +1,4 @@
1
+ appTitle=Browse Books
2
+ appSubTitle=Find all your favorite books
3
+ appDescription=This application lets you find the next books you want to read.
4
+ appInfo=This is an app info field
@@ -0,0 +1,139 @@
1
+ {
2
+ "_version": "1.49.0",
3
+ "sap.app": {
4
+ "id": "bookshop",
5
+ "applicationVersion": {
6
+ "version": "1.0.0"
7
+ },
8
+ "type": "application",
9
+ "title": "{{appTitle}}",
10
+ "description": "{{appDescription}}",
11
+ "i18n": "i18n/i18n.properties",
12
+ "dataSources": {
13
+ "CatalogService": {
14
+ "uri": "/browse/",
15
+ "type": "OData",
16
+ "settings": {
17
+ "odataVersion": "4.0"
18
+ }
19
+ }
20
+ },
21
+ "crossNavigation": {
22
+ "inbounds": {
23
+ "intent1": {
24
+ "signature": {
25
+ "parameters": {
26
+ "Books.ID": {
27
+ "renameTo": "ID"
28
+ },
29
+ "Authors.books.ID": {
30
+ "renameTo": "ID"
31
+ }
32
+ },
33
+ "additionalParameters": "ignored"
34
+ },
35
+ "semanticObject": "Books",
36
+ "action": "display",
37
+ "title": "{{appTitle}}",
38
+ "info": "{{appInfo}}",
39
+ "subTitle": "{{appSubTitle}}",
40
+ "icon": "sap-icon://course-book",
41
+ "indicatorDataSource": {
42
+ "dataSource": "CatalogService",
43
+ "path": "Books/$count",
44
+ "refresh": 1800
45
+ }
46
+ }
47
+ }
48
+ }
49
+ },
50
+ "sap.ui": {
51
+ "technology": "UI5",
52
+ "fullWidth": false,
53
+ "deviceTypes": {
54
+ "desktop": true,
55
+ "tablet": true,
56
+ "phone": true
57
+ }
58
+ },
59
+ "sap.ui5": {
60
+ "dependencies": {
61
+ "minUI5Version": "1.115.1",
62
+ "libs": {
63
+ "sap.fe.templates": {}
64
+ }
65
+ },
66
+ "models": {
67
+ "i18n": {
68
+ "type": "sap.ui.model.resource.ResourceModel",
69
+ "uri": "i18n/i18n.properties"
70
+ },
71
+ "": {
72
+ "dataSource": "CatalogService",
73
+ "settings": {
74
+ "synchronizationMode": "None",
75
+ "operationMode": "Server",
76
+ "autoExpandSelect": true,
77
+ "earlyRequests": true,
78
+ "groupProperties": {
79
+ "default": {
80
+ "submit": "Auto"
81
+ }
82
+ }
83
+ }
84
+ }
85
+ },
86
+ "routing": {
87
+ "routes": [
88
+ {
89
+ "pattern": ":?query:",
90
+ "name": "BooksList",
91
+ "target": "BooksList"
92
+ },
93
+ {
94
+ "pattern": "Books({key}):?query:",
95
+ "name": "BooksDetails",
96
+ "target": "BooksDetails"
97
+ }
98
+ ],
99
+ "targets": {
100
+ "BooksList": {
101
+ "type": "Component",
102
+ "id": "BooksList",
103
+ "name": "sap.fe.templates.ListReport",
104
+ "options": {
105
+ "settings": {
106
+ "entitySet": "Books",
107
+ "initialLoad": true,
108
+ "navigation": {
109
+ "Books": {
110
+ "detail": {
111
+ "route": "BooksDetails"
112
+ }
113
+ }
114
+ }
115
+ }
116
+ }
117
+ },
118
+ "BooksDetails": {
119
+ "type": "Component",
120
+ "id": "BooksDetailsList",
121
+ "name": "sap.fe.templates.ObjectPage",
122
+ "options": {
123
+ "settings": {
124
+ "entitySet": "Books"
125
+ }
126
+ }
127
+ }
128
+ }
129
+ },
130
+ "contentDensities": {
131
+ "compact": true,
132
+ "cozy": true
133
+ }
134
+ },
135
+ "sap.fiori": {
136
+ "registrationIds": [],
137
+ "archeType": "transactional"
138
+ }
139
+ }