|
@@ -1,10 +1,9 @@
|
|
|
package filter
|
|
|
|
|
|
import (
|
|
|
- "app.yhyue.com/moapp/jypkg/common/src/qfw/util/jy"
|
|
|
- "log"
|
|
|
- "net/http"
|
|
|
- "strings"
|
|
|
+ "app.yhyue.com/moapp/jypkg/common/src/qfw/util/jy"
|
|
|
+ "net/http"
|
|
|
+ "strings"
|
|
|
)
|
|
|
|
|
|
// CookieInfo 信息
|
|
@@ -15,14 +14,12 @@ type CookieInfo struct {
|
|
|
|
|
|
// Do 继承过滤器方法
|
|
|
func (ci *CookieInfo) Do() {
|
|
|
- log.Println(ci.R.Referer(), "----------------------", ci.R.RequestURI)
|
|
|
if crr := ci.R.Referer(); crr != "" {
|
|
|
if strings.Contains(crr, "cooperate") {
|
|
|
match := strings.Split(crr, "cooperate/")
|
|
|
if len(match) > 1 {
|
|
|
jy.SetCookieValue(ci.W, jy.ChannelCookieName, match[1], 172800) //两天
|
|
|
}
|
|
|
- log.Println("---------------pc-------------", match)
|
|
|
}
|
|
|
}
|
|
|
}
|