로그추가

wo_translateinfo
jiyoungcheon 2 weeks ago
parent e0ca56b93b
commit 4845e9ee5f

@ -151,7 +151,7 @@ func TTSFunc2(w http.ResponseWriter, r *http.Request) {
fmt.Fprintln(w, "TTS func 2", r) fmt.Fprintln(w, "TTS func 2", r)
} }
//post // post
func TTSFunc3(w http.ResponseWriter, r *http.Request) { func TTSFunc3(w http.ResponseWriter, r *http.Request) {
fmt.Fprintln(w, "TTS func 3", r) fmt.Fprintln(w, "TTS func 3", r)
body := make([]byte, r.ContentLength) body := make([]byte, r.ContentLength)
@ -163,13 +163,13 @@ func TTSFunc3(w http.ResponseWriter, r *http.Request) {
fmt.Println(string(body)) fmt.Println(string(body))
} }
//post // post
func TTSFunc4(w http.ResponseWriter, r *http.Request) { func TTSFunc4(w http.ResponseWriter, r *http.Request) {
fmt.Fprintln(w, "TTS func 4", r) fmt.Fprintln(w, "TTS func 4", r)
} }
///////////////////////////////////////////// // ///////////////////////////////////////////
//BOT // BOT
func (s *ScenarioSession) BOTPFunc(w http.ResponseWriter, r *http.Request) { func (s *ScenarioSession) BOTPFunc(w http.ResponseWriter, r *http.Request) {
// get scenario config // get scenario config
l := icslog.GetIcsLog() l := icslog.GetIcsLog()
@ -258,6 +258,7 @@ func (s *ScenarioSession) BOTPFunc(w http.ResponseWriter, r *http.Request) {
response.Data.RecodingFile = "" response.Data.RecodingFile = ""
response.Data.SttMaxTime = 10 response.Data.SttMaxTime = 10
} else if request.Method != "INIT" && request.TalkText == "" { } else if request.Method != "INIT" && request.TalkText == "" {
l.Println(icslog.LOG_LEVEL_INFO, -1, "여기는 INIT 아닐 때")
if request.TalkText == "" { if request.TalkText == "" {
request.TalkText = "잘못된 값 입력 " request.TalkText = "잘못된 값 입력 "
} }
@ -383,6 +384,7 @@ func (s *ScenarioSession) BOTPFunc(w http.ResponseWriter, r *http.Request) {
s.session[token] = ResStatus{Count: 1, Status: scnarioConf[dnis][0].Action, NotUnderstand: 0, PreEventNum: 1} s.session[token] = ResStatus{Count: 1, Status: scnarioConf[dnis][0].Action, NotUnderstand: 0, PreEventNum: 1}
// s.m.Unlock() // s.m.Unlock()
case "STT", "DTMF", "BOTH", "MEMO", "NONE": case "STT", "DTMF", "BOTH", "MEMO", "NONE":
l.Println(icslog.LOG_LEVEL_INFO, -1, "여기는 언제 타는거지지")
response.ResultCode = 200 response.ResultCode = 200
response.Token = request.Token response.Token = request.Token
if dnis == "9013" || dnis == "9014" { if dnis == "9013" || dnis == "9014" {

Loading…
Cancel
Save