fix(basic.gblib): update ChatServices.ts #420

Closed
eltociear wants to merge 2540 commits from patch-1 into main
Showing only changes of commit 9b59146034 - Show all commits

View file

@ -526,6 +526,11 @@ export class DialogKeywords {
*
*/
public async sendEmail({ pid, to, subject, body }) {
if (!body) {
body = "";
};
// tslint:disable-next-line:no-console
GBLog.info(`[E-mail]: to:${to},subject: ${subject},body: ${body}.`);
@ -1247,9 +1252,9 @@ export class DialogKeywords {
public async messageBot({ pid, text }) {
const { min, user } = await DialogKeywords.getProcessInfo(pid);
GBLogEx.info(min,`MESSAGE BOT: ${text}.`);
GBLogEx.info(min, `MESSAGE BOT: ${text}.`);
const { conversation, client} = min['apiConversations'][pid];
const { conversation, client } = min['apiConversations'][pid];
await client.apis.Conversations.Conversations_PostActivity({
conversationId: conversation.conversationId,
@ -1377,10 +1382,10 @@ export class DialogKeywords {
);
GBLog.verbose(`Translated text(playMarkdown): ${text}.`);
if (step){
if (step) {
await min.conversationalService.sendText(min, step, text);
}
else{
else {
await min.conversationalService['sendOnConversation'](min, user, text);
}
}