@adempiere/grpc-api
Advanced tools
Comparing version 4.6.3 to 4.6.4
{ | ||
"name": "@adempiere/grpc-api", | ||
"version": "4.6.3", | ||
"version": "4.6.4", | ||
"description": "ADempiere Web write in Javascript for a node service", | ||
@@ -5,0 +5,0 @@ "author": "Yamel Senih", |
@@ -233,3 +233,7 @@ /************************************************************************************* | ||
resourceId, | ||
charset | ||
charset, | ||
// process values | ||
isProcess, | ||
processId, | ||
parametersList | ||
}, callback) { | ||
@@ -247,2 +251,33 @@ const { SaveRecordsRequest } = this.stubFile; | ||
// set process values | ||
if (isProcess) { | ||
request.setIsProcess(isProcess); | ||
request.setProcessId( | ||
getValidInteger(processId) | ||
); | ||
// set process parameters list | ||
if (!isEmptyValue(parametersList)) { | ||
const { getTypeOfValue } = require('@adempiere/grpc-api/src/utils/valueUtils.js'); | ||
const { getKeyValueToGRPC } = require('@adempiere/grpc-api/src/utils/baseDataTypeToGRPC.js'); | ||
if (getTypeOfValue(parametersList) === 'String') { | ||
parametersList = JSON.parse(parametersList); | ||
} | ||
parametersList.forEach(parameter => { | ||
let parsedParameter = parameter; | ||
if (getTypeOfValue(parameter) === 'String') { | ||
parsedParameter = JSON.parse(parameter); | ||
} | ||
// parameter format = { columName, value, valueType } | ||
const convertedParameter = getKeyValueToGRPC({ | ||
columnName: parsedParameter.key, | ||
value: parsedParameter.value, | ||
valueType: parsedParameter.valueType | ||
}); | ||
request.addParameters(convertedParameter); | ||
}); | ||
} | ||
} | ||
const metadata = getMetadata({ | ||
@@ -249,0 +284,0 @@ token |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
6762122
191690