-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Description
When I use start, assign and invoke interface , it shows the user how do this action is undefined or null.
var client = new BPMNClient(process.env.HOST, process.env.PORT, process.env.API_KEY);
var response = await client.engine.start(processId, data, null, 'starter')
response = await client.engine.assign({ id: instance.id, "items.status": "wait" }, {}, 'starter', { assignee: 'starter' })
response = await client.engine.invoke({ id: instance.id, "items.status": "wait" }, {}, 'starter')
response = await clent.engine.assign({ id: instance.id, "items.status": "wait" }, {}, 'leader')
The request looks like succeed, but in the web it shows
12/3/2024 14:30:31 | Task Start a aproval process -Task_1 started.
12/3/2024 14:30:31 | Task Start a aproval process -Task_1 Assigned by undefined to:[object Object]
12/3/2024 14:30:31 | Task Start a aproval process ended by null
12/3/2024 14:30:31 | Task Level 1 approve -Task_2 started.
12/3/2024 14:30:31 | Task Level 1 approve -Task_2 Assigned by undefined to:[object Object]
For example, the code of the assign interface is:
async assign(query, data, userId = null, assignment): Promise<IInstanceData> {
const ret = await this.client.put('engine/assign', { query, data, userId, assignment });
if (ret['errors']) {
console.log(ret['errors']);
throw new Error(ret['errors']);
}
const instance = ret['instance'] as IInstanceData;
return instance;
}
In the request body of client,the user information is userId, it is not usable for server. In server it's userName.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels