@sap/cds 8.1.0 → 8.2.0
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 +60 -0
- package/app/index.css +3 -0
- package/app/index.js +50 -4
- package/bin/serve.js +1 -1
- package/lib/compile/cdsc.js +2 -2
- package/lib/compile/etc/_localized.js +1 -1
- package/lib/compile/for/lean_drafts.js +1 -0
- package/lib/compile/to/sql.js +2 -2
- package/lib/env/cds-requires.js +6 -0
- package/lib/env/defaults.js +14 -3
- package/lib/env/plugins.js +6 -22
- package/lib/index.js +3 -2
- package/lib/linked/classes.js +0 -14
- package/lib/linked/types.js +12 -0
- package/lib/linked/validate.js +3 -2
- package/lib/log/cds-log.js +3 -3
- package/lib/log/format/aspects/als.js +23 -29
- package/lib/log/format/aspects/cls.js +9 -0
- package/lib/log/format/json.js +42 -6
- package/lib/ql/Whereable.js +5 -1
- package/lib/req/context.js +1 -0
- package/lib/req/locale.js +1 -1
- package/lib/srv/cds-connect.js +33 -32
- package/lib/srv/cds-serve.js +2 -1
- package/lib/srv/srv-tx.js +1 -0
- package/lib/utils/cds-utils.js +4 -2
- package/libx/_runtime/cds-services/adapter/odata-v4/utils/metaInfo.js +1 -5
- package/libx/_runtime/cds-services/adapter/odata-v4/utils/result.js +2 -31
- package/libx/_runtime/common/generic/auth/utils.js +2 -0
- package/libx/_runtime/common/generic/input.js +2 -11
- package/libx/_runtime/common/generic/put.js +1 -10
- package/libx/_runtime/common/utils/binary.js +1 -7
- package/libx/_runtime/common/utils/cqn2cqn4sql.js +10 -1
- package/libx/_runtime/common/utils/resolveView.js +2 -2
- package/libx/_runtime/common/utils/search2cqn4sql.js +1 -1
- package/libx/_runtime/common/utils/streamProp.js +12 -1
- package/libx/_runtime/common/utils/template.js +26 -16
- package/libx/_runtime/common/utils/templateProcessor.js +8 -7
- package/libx/_runtime/common/utils/ucsn.js +2 -5
- package/libx/_runtime/db/expand/expandCQNToJoin.js +43 -2
- package/libx/_runtime/db/generic/input.js +1 -5
- package/libx/_runtime/fiori/lean-draft.js +287 -96
- package/libx/_runtime/messaging/event-broker.js +105 -40
- package/libx/_runtime/remote/Service.js +3 -1
- package/libx/_runtime/remote/utils/client.js +12 -4
- package/libx/_runtime/ucl/Service.js +16 -6
- package/libx/odata/middleware/batch.js +2 -2
- package/libx/odata/middleware/create.js +5 -0
- package/libx/odata/middleware/delete.js +5 -0
- package/libx/odata/middleware/error.js +1 -0
- package/libx/odata/middleware/operation.js +6 -0
- package/libx/odata/middleware/read.js +16 -11
- package/libx/odata/middleware/stream.js +4 -5
- package/libx/odata/middleware/update.js +9 -4
- package/libx/odata/parse/afterburner.js +3 -2
- package/libx/odata/parse/multipartToJson.js +1 -1
- package/libx/odata/utils/index.js +3 -3
- package/libx/odata/utils/postProcess.js +3 -25
- package/libx/rest/middleware/error.js +1 -0
- package/libx/rest/middleware/parse.js +1 -6
- package/package.json +2 -2
|
@@ -6,7 +6,6 @@ const { getKeysAndParamsFromPath } = require('../../common/utils')
|
|
|
6
6
|
const { base64ToBuffer } = require('../../_runtime/common/utils/binary')
|
|
7
7
|
const { convertStructured } = require('../../_runtime/common/utils/ucsn')
|
|
8
8
|
const getTemplate = require('../../_runtime/common/utils/template')
|
|
9
|
-
const templateProcessor = require('../../_runtime/common/utils/templateProcessor')
|
|
10
9
|
|
|
11
10
|
const { checkStaticElementByKey } = require('../../_runtime/cds-services/util/assert')
|
|
12
11
|
|
|
@@ -151,11 +150,7 @@ module.exports = adapter => {
|
|
|
151
150
|
cleanupStruct: cds.env.features.rest_struct_data
|
|
152
151
|
})
|
|
153
152
|
const template = getTemplate(_cache(req), service, definition, { pick: _picker })
|
|
154
|
-
|
|
155
|
-
for (const row of Array.isArray(payload) ? payload : [payload]) {
|
|
156
|
-
templateProcessor({ processFn: _processorFn(errs), row, template })
|
|
157
|
-
}
|
|
158
|
-
}
|
|
153
|
+
template.process(payload, _processorFn(errs))
|
|
159
154
|
if (errs.length) {
|
|
160
155
|
if (errs.length === 1) throw errs[0]
|
|
161
156
|
throw Object.assign(new Error('MULTIPLE_ERRORS'), { statusCode: 400, details: errs })
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sap/cds",
|
|
3
|
-
"version": "8.
|
|
3
|
+
"version": "8.2.0",
|
|
4
4
|
"description": "SAP Cloud Application Programming Model - CDS for Node.js",
|
|
5
5
|
"homepage": "https://cap.cloud.sap/",
|
|
6
6
|
"keywords": [
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
"node": ">=18"
|
|
36
36
|
},
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@sap/cds-compiler": ">=5",
|
|
38
|
+
"@sap/cds-compiler": ">=5.1",
|
|
39
39
|
"@sap/cds-fiori": "^1",
|
|
40
40
|
"@sap/cds-foss": "^5.0.0"
|
|
41
41
|
},
|