refactor(basic.gblib): Renaming WA.
This commit is contained in:
parent
1914d377ab
commit
cf36adfab7
3 changed files with 6 additions and 6 deletions
|
@ -42,7 +42,7 @@ import { Sequelize } from 'sequelize-typescript';
|
|||
import { createServerRouter } from 'typescript-rest-rpc/lib/server.js';
|
||||
import { DialogKeywords } from './services/DialogKeywords.js';
|
||||
import { SystemKeywords } from './services/SystemKeywords.js';
|
||||
import { WebAutomationKeywords } from './services/WebAutomationKeywords.js';
|
||||
import { WebAutomationServices } from './services/WebAutomationServices.js';
|
||||
import { ImageProcessing } from './services/ImageProcessing.js';
|
||||
import { DebuggerService } from './services/DebuggerService.js';
|
||||
import * as koaBody from 'koa-body';
|
||||
|
@ -81,7 +81,7 @@ export class GBBasicPackage implements IGBPackage {
|
|||
}
|
||||
public async loadBot (min: GBMinInstance): Promise<void> {
|
||||
const dk = new DialogKeywords(min, null, null);
|
||||
const wa = new WebAutomationKeywords(min, null, dk);
|
||||
const wa = new WebAutomationServices(min, null, dk);
|
||||
const sys = new SystemKeywords(min, null, dk, wa);
|
||||
const dbg = new DebuggerService(min, null, dk);
|
||||
const img = new ImageProcessing(min, null, dk);
|
||||
|
|
|
@ -57,7 +57,7 @@ import sgMail from '@sendgrid/mail';
|
|||
import mammoth from 'mammoth';
|
||||
import qrcode from 'qrcode';
|
||||
import { json } from 'body-parser';
|
||||
import { WebAutomationKeywords } from './WebAutomationKeywords.js';
|
||||
import { WebAutomationServices } from './WebAutomationServices.js';
|
||||
|
||||
/**
|
||||
* Default check interval for user replay
|
||||
|
@ -833,7 +833,7 @@ export class DialogKeywords {
|
|||
|
||||
if (kind === 'file') {
|
||||
GBLog.info(`BASIC (${min.botId}): Upload done for ${answer.filename}.`);
|
||||
const handle = WebAutomationKeywords.cyrb53(this.min.botId + answer.filename);
|
||||
const handle = WebAutomationServices.cyrb53(this.min.botId + answer.filename);
|
||||
GBServer.globals.files[handle] = answer;
|
||||
result = handle;
|
||||
} else if (kind === 'boolean') {
|
||||
|
|
|
@ -49,7 +49,7 @@ import { pid } from 'process';
|
|||
/**
|
||||
* Web Automation services of conversation to be called by BASIC.
|
||||
*/
|
||||
export class WebAutomationKeywords {
|
||||
export class WebAutomationServices {
|
||||
/**
|
||||
* Reference to minimal bot instance.
|
||||
*/
|
||||
|
@ -131,7 +131,7 @@ export class WebAutomationKeywords {
|
|||
}
|
||||
await page.goto(url);
|
||||
|
||||
const handle = WebAutomationKeywords.cyrb53(this.min.botId + url);
|
||||
const handle = WebAutomationServices.cyrb53(this.min.botId + url);
|
||||
|
||||
this.pageMap[handle] = page;
|
||||
|
Loading…
Add table
Reference in a new issue