Merge branch 'master' of https://github.com/pragmatismo-io/BotServer
# Resolved: # deploy/default.gbui/public/index.html
This commit is contained in:
commit
d8080f9696
4 changed files with 6 additions and 5 deletions
|
@ -141,7 +141,7 @@ export class GBMinService {
|
||||||
|
|
||||||
let options = {
|
let options = {
|
||||||
url:
|
url:
|
||||||
"https://westus.api.cognitive.microsoft.com/sts/v1.0/issueToken",
|
"https://api.cognitive.microsoft.com/sts/v1.0/issueToken",
|
||||||
method: "POST",
|
method: "POST",
|
||||||
headers: {
|
headers: {
|
||||||
"Ocp-Apim-Subscription-Key": instance.speechKey
|
"Ocp-Apim-Subscription-Key": instance.speechKey
|
||||||
|
@ -191,9 +191,9 @@ export class GBMinService {
|
||||||
GBKBPackage, GBCustomerSatisfactionPackage, GBWhatsappPackage].forEach(sysPackage => {
|
GBKBPackage, GBCustomerSatisfactionPackage, GBWhatsappPackage].forEach(sysPackage => {
|
||||||
logger.trace(`Loading sys package: ${sysPackage.name}...`);
|
logger.trace(`Loading sys package: ${sysPackage.name}...`);
|
||||||
let p = Object.create(sysPackage.prototype) as IGBPackage;
|
let p = Object.create(sysPackage.prototype) as IGBPackage;
|
||||||
p.loadBot(min);
|
//e.sysPackages.push(p);
|
||||||
e.sysPackages.push(p);
|
|
||||||
if (sysPackage.name === "GBWhatsappPackage") {
|
if (sysPackage.name === "GBWhatsappPackage") {
|
||||||
|
p.loadBot(min);
|
||||||
let url = "/instances/:botId/whatsapp";
|
let url = "/instances/:botId/whatsapp";
|
||||||
server.post(url, (req, res) => {
|
server.post(url, (req, res) => {
|
||||||
p["channel"].received(req, res);
|
p["channel"].received(req, res);
|
||||||
|
|
|
@ -52,7 +52,7 @@
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body style="background-color: lightgrey;">
|
<body style="background-color: lightgrey;">
|
||||||
<div id="root" class="loader"></div>
|
<div id="root"></div>
|
||||||
</body>
|
</body>
|
||||||
|
|
||||||
</html>
|
</html>
|
|
@ -204,7 +204,7 @@ export class WhatsappDirectLine extends GBService {
|
||||||
|
|
||||||
// Ignore own messages.
|
// Ignore own messages.
|
||||||
// TODO: this.botId instead of "general-bot-9672a8d3"
|
// TODO: this.botId instead of "general-bot-9672a8d3"
|
||||||
activities = activities.filter((m) => { return m.from.id === "general-bot-9672a8d3" && m.type === "message" });
|
activities = activities.filter((m) => { return (m.from.id === "GeneralBot-Netshoes" || m.from.id.includes("4vqtLx3cFJgBAELkRib2K8")) && m.type === "message" });
|
||||||
|
|
||||||
if (activities.length) {
|
if (activities.length) {
|
||||||
|
|
||||||
|
|
|
@ -5,6 +5,7 @@
|
||||||
"declaration": false,
|
"declaration": false,
|
||||||
"emitDecoratorMetadata": true,
|
"emitDecoratorMetadata": true,
|
||||||
"experimentalDecorators": true,
|
"experimentalDecorators": true,
|
||||||
|
"keyofStringsOnly": true,
|
||||||
"mapRoot": "./dist/",
|
"mapRoot": "./dist/",
|
||||||
"module": "commonjs",
|
"module": "commonjs",
|
||||||
"moduleResolution": "node",
|
"moduleResolution": "node",
|
||||||
|
|
Loading…
Add table
Reference in a new issue