From c09faee5746a790a6948ac185097f2e2c10b9591 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=82=B9=E5=AE=97=E6=A5=A0?= Date: Thu, 12 Oct 2023 17:14:58 +0800 Subject: [PATCH] 1 --- platformapi/mtwmapi/comment.go | 7 +++++++ platformapi/mtwmapi/comment_test.go | 2 +- platformapi/mtwmapi/mtwmapi_test.go | 4 ++-- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/platformapi/mtwmapi/comment.go b/platformapi/mtwmapi/comment.go index 14b877ea..08edf344 100644 --- a/platformapi/mtwmapi/comment.go +++ b/platformapi/mtwmapi/comment.go @@ -1,6 +1,7 @@ package mtwmapi import ( + "git.rosy.net.cn/jx-callback/globals" "math" "strings" @@ -61,6 +62,12 @@ func (a *API) CommentQuery(poiCode string, startDateStr, endDateStr string, offs params["pageoffset"] = offset params["pagesize"] = limit result, err := a.AccessAPI("comment/query", true, params) + if poiCode == "18805464" { + globals.SugarLogger.Debugf("param :==== %s", utils.Format4Output(params, false)) + globals.SugarLogger.Debugf("result :==== %s", utils.Format4Output(result, false)) + globals.SugarLogger.Debugf("err :==== %v", err) + globals.SugarLogger.Debugf("token :==== %s", a.token) + } if err != nil { return nil, err } diff --git a/platformapi/mtwmapi/comment_test.go b/platformapi/mtwmapi/comment_test.go index 993d71c1..e2bc1ddd 100644 --- a/platformapi/mtwmapi/comment_test.go +++ b/platformapi/mtwmapi/comment_test.go @@ -8,7 +8,7 @@ import ( ) func TestCommentQuery(t *testing.T) { - result, err := api.CommentQuery("18026738", "20230711", "20230717", 0, 0, CommentReplyStatusNotReplied) + result, err := api.CommentQuery("18805464", "20231009", "20231011", 0, 0, CommentReplyStatusNotReplied) if err != nil { t.Fatal(err) } diff --git a/platformapi/mtwmapi/mtwmapi_test.go b/platformapi/mtwmapi/mtwmapi_test.go index 235cfc76..c0821dfd 100644 --- a/platformapi/mtwmapi/mtwmapi_test.go +++ b/platformapi/mtwmapi/mtwmapi_test.go @@ -23,10 +23,10 @@ func init() { //api = New("589", "a81eb3df418d83d6a1a4b7c572156d2f", "", "") // ζžœε›­ - api = New("4123", "df2c88338b85f830cebce2a9eab56628", "", "") + //api = New("4123", "df2c88338b85f830cebce2a9eab56628", "", "") //商袅 - //api = New("5873", "41c479790a76f86326f89e8048964739", "", "token_nngsVP37s-HXY86xe85H7Q") //token_n4TwqCntWWuvQwAawzxC0w + api = New("5873", "41c479790a76f86326f89e8048964739", "", "token_rfAD6OxSVxkTeCO1XmNCZg") //token_n4TwqCntWWuvQwAawzxC0w //api = New("5873", "41c479790a76f86326f89e8048964739", "", "token_r36FEse6_ywebQI65FNNWA") //token_n4TwqCntWWuvQwAawzxC0w cookieStr := ` acctId=57396785; token=0bWbK5VbK50E2BmIhIH2zHB-am_y7mB37yXHm6RLZWx4*; wmPoiId=-1;