| | |
| | | }; |
| | | // 发起ws请求 |
| | | sendWebsocket( |
| | | "ws://localhost:8089/chat?userId=1", |
| | | "ws://192.168.2.8:8089/chat?userId=1", |
| | | obj, |
| | | this.wsMessage, |
| | | this.wsError |
| | |
| | | dataJson = JSON.parse(dataJson); |
| | | dataJson = JSON.parse(dataJson); |
| | | console.log(dataJson, "数据"); |
| | | // 首次接收数据 |
| | | if (!this.Answerline[0]) { |
| | | this.Answerline.push({ |
| | | value: dataJson.kcb, |
| | | isEat: 1, |
| | | }); |
| | | } |
| | | this.Answerline.push({ |
| | | value: dataJson.nowQuestion.questionText, |
| | | isEat: 1, |
| | | }); |
| | | // 优先加入通用库匹配文本 |
| | | if (dataJson.nowQuestion.submoduleText) { |
| | | this.Answerline.push({ |
| | | value: dataJson.nowQuestion.submoduleText, |
| | | isEat: 1, |
| | | }); |
| | | } |
| | | // 是否结束 |
| | | if (!dataJson.jsy) { |
| | | this.Answerline.push({ |
| | | value: dataJson.nowQuestion.questionText, |
| | | isEat: 1, |
| | | }); |
| | | } else { |
| | | this.Answerline.push({ |
| | | value: dataJson.jsy, |
| | | isEat: 1, |
| | | }); |
| | | } |
| | | this.questionList = dataJson.questionList; |
| | | this.questionList = this.questionList.map((item) => { |
| | | item.ivrLibaScriptTargetoptionList.forEach((row) => { |
| | |
| | | console.log(obj, "入参"); |
| | | // 发起ws请求 |
| | | sendWebsocket( |
| | | "ws://localhost:8089/chat?userId=1", |
| | | "ws://192.168.2.8:8089/chat?userId=1", |
| | | obj, |
| | | this.wsMessage, |
| | | this.wsError |