@adempiere/grpc-api
Advanced tools
Comparing version 1.0.4 to 1.0.5
89
index.js
@@ -290,2 +290,3 @@ /************************************************************************************* | ||
// Dictionary | ||
// Get Window | ||
@@ -297,2 +298,88 @@ getWindow({ | ||
}, callback) { | ||
this.getDictionaryService().getWindow(this.getDictionaryRequest(token, id, uuid), callback) | ||
} | ||
// Get Process | ||
getProcess({ | ||
token, | ||
id, | ||
uuid | ||
}, callback) { | ||
this.getDictionaryService().getProcess(this.getDictionaryRequest(token, id, uuid), callback) | ||
} | ||
// Get Browser | ||
getBrowser({ | ||
token, | ||
id, | ||
uuid | ||
}, callback) { | ||
this.getDictionaryService().getBrowser(this.getDictionaryRequest(token, id, uuid), callback) | ||
} | ||
// Get Form | ||
getForm({ | ||
token, | ||
id, | ||
uuid | ||
}, callback) { | ||
this.getDictionaryService().getForm(this.getDictionaryRequest(token, id, uuid), callback) | ||
} | ||
// Get Form | ||
getValidationRule({ | ||
token, | ||
id, | ||
uuid | ||
}, callback) { | ||
this.getDictionaryService().getValidationRule(this.getDictionaryRequest(token, id, uuid), callback) | ||
} | ||
// Get Field | ||
getField({ | ||
token, | ||
uuid, | ||
columnUuid, | ||
elementUuid, | ||
tableName, | ||
columnName, | ||
elementNolumnName | ||
}, callback) { | ||
const { FieldRequest, ApplicationRequest } = require('./src/grpc/proto/dictionary_pb.js') | ||
const request = new FieldRequest() | ||
const applicationRequest = new ApplicationRequest() | ||
request.setFieldUuid(uuid) | ||
request.setColumnUuid(columnUuid) | ||
request.setElementUuid(elementUuid) | ||
request.setFieldUuid(tableName) | ||
request.setColumnName(columnName) | ||
request.setElementColumnName(elementNolumnName) | ||
applicationRequest.setSessionUuid(token) | ||
applicationRequest.setLanguage(this.language) | ||
request.setApplicationRequest(applicationRequest) | ||
this.getDictionaryService().getField(request, callback) | ||
} | ||
// Get Reference | ||
getReference({ | ||
token, | ||
uuid, | ||
columnName | ||
}, callback) { | ||
const { ReferenceRequest, ApplicationRequest } = require('./src/grpc/proto/dictionary_pb.js') | ||
const request = new ReferenceRequest() | ||
const applicationRequest = new ApplicationRequest() | ||
request.setReferenceUuid(uuid) | ||
request.setColumnName(columnName) | ||
applicationRequest.setSessionUuid(token) | ||
applicationRequest.setLanguage(this.language) | ||
request.setApplicationRequest(applicationRequest) | ||
this.getDictionaryService().getReference(request, callback) | ||
} | ||
// Get Process | ||
getDictionaryRequest( | ||
token, | ||
id, | ||
uuid) { | ||
const { EntityRequest, ApplicationRequest } = require('./src/grpc/proto/dictionary_pb.js') | ||
@@ -306,5 +393,5 @@ const request = new EntityRequest() | ||
request.setApplicationRequest(applicationRequest) | ||
this.getDictionaryService().getWindow(request, callback) | ||
return request | ||
} | ||
} | ||
module.exports = Api; |
{ | ||
"name": "@adempiere/grpc-api", | ||
"version": "1.0.4", | ||
"version": "1.0.5", | ||
"description": "ADempiere Web Store write in Javascript for a node service", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -109,3 +109,3 @@ # ADempiere Web Store backend API for gRPC | ||
yarn global add grpc-tools | ||
grpc_tools_node_protoc --js_out=import_style=commonjs,binary:src/grpc --grpc_out=src/grpc --plugin=protoc-gen-grpc=`which grpc_tools_node_protoc_plugin` proto/access.proto proto/client.proto proto/base_data_type.proto proto/core_functionality.proto | ||
grpc_tools_node_protoc --js_out=import_style=commonjs,binary:src/grpc --grpc_out=src/grpc --plugin=protoc-gen-grpc=`which grpc_tools_node_protoc_plugin` proto/access.proto proto/client.proto proto/base_data_type.proto proto/core_functionality.proto proto/dictionary.proto | ||
``` | ||
@@ -112,0 +112,0 @@ |
@@ -132,13 +132,2 @@ // GENERATED CODE -- DO NOT EDIT! | ||
function serialize_dictionary_ValidationRuleRequest(arg) { | ||
if (!(arg instanceof proto_dictionary_pb.ValidationRuleRequest)) { | ||
throw new Error('Expected argument of type dictionary.ValidationRuleRequest'); | ||
} | ||
return Buffer.from(arg.serializeBinary()); | ||
} | ||
function deserialize_dictionary_ValidationRuleRequest(buffer_arg) { | ||
return proto_dictionary_pb.ValidationRuleRequest.deserializeBinary(new Uint8Array(buffer_arg)); | ||
} | ||
function serialize_dictionary_Window(arg) { | ||
@@ -211,6 +200,6 @@ if (!(arg instanceof proto_dictionary_pb.Window)) { | ||
responseStream: false, | ||
requestType: proto_dictionary_pb.ValidationRuleRequest, | ||
requestType: proto_dictionary_pb.EntityRequest, | ||
responseType: proto_dictionary_pb.ValidationRule, | ||
requestSerialize: serialize_dictionary_ValidationRuleRequest, | ||
requestDeserialize: deserialize_dictionary_ValidationRuleRequest, | ||
requestSerialize: serialize_dictionary_EntityRequest, | ||
requestDeserialize: deserialize_dictionary_EntityRequest, | ||
responseSerialize: serialize_dictionary_ValidationRule, | ||
@@ -217,0 +206,0 @@ responseDeserialize: deserialize_dictionary_ValidationRule, |
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
1674968
49480