Commit 9444bc4b by mushishixian

调试

parent 45f76ff4
Showing with 0 additions and 6 deletions
package controller
import (
"fmt"
"github.com/gin-gonic/gin"
"github.com/gomodule/redigo/redis"
"github.com/ichunt2019/logger"
......@@ -117,13 +116,11 @@ func GetDataPur(c *gin.Context) {
if user.Name == "" && user.Email != "" {
userInfoData[user.UserId] = user.Email
} else {
fmt.Println(user.UserId)
userInfoData[user.UserId] = user.Name
}
}
temp2 := make(map[int]string)
for _, code := range intracode {
//fmt.Println(userInfoData[code.AdminId])
if _, exist := userInfoData[code.AdminId]; exist {
temp2[code.CodeId] = userInfoData[code.AdminId]
} else {
......@@ -135,8 +132,6 @@ func GetDataPur(c *gin.Context) {
defer redisCon.Close()
for _, supplier := range supplierData {
if value, exist := temp2[supplier.ChannelUid]; exist {
fmt.Println(value)
fmt.Println(temp2[supplier.ChannelUid])
res, err := redis.Bool(redisCon.Do("HSET", "search_supplier_canaltopurchase_test", supplier.SupplierCode, value))
if err != nil || !res {
c.String(200, "失败")
......@@ -152,6 +147,5 @@ func GetDataPur(c *gin.Context) {
func GetData(keyword, supplierName string) (res interface{}) {
quoteService := service.QuoteService{}
res, _ = quoteService.GetData(keyword, supplierName)
fmt.Println(res)
return
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment