|
@@ -1,10 +1,10 @@
|
|
|
package service
|
|
|
|
|
|
import (
|
|
|
- "app.yhyue.com/moapp/jybase/common"
|
|
|
"app.yhyue.com/moapp/jybase/redis"
|
|
|
MC "bp.jydev.jianyu360.cn/BaseService/biCenter/api/common"
|
|
|
"encoding/base64"
|
|
|
+ "github.com/gogf/gf/v2/util/gconv"
|
|
|
"github.com/tjfoc/gmsm/sm4"
|
|
|
)
|
|
|
|
|
@@ -14,20 +14,21 @@ type InfoService struct {
|
|
|
func (l *InfoService) Myinfo(sid string) map[string]interface{} {
|
|
|
infoMap := map[string]interface{}{}
|
|
|
info_i := redis.Get("session", sid)
|
|
|
+
|
|
|
if info_i != nil {
|
|
|
info_m, _ := info_i.(map[string]interface{})
|
|
|
infoMap = map[string]interface{}{
|
|
|
- "nickName": RsaEncrypt([]byte(common.InterfaceToStr(info_m["s_nickname"]))),
|
|
|
- "entRole": RsaEncrypt([]byte(common.InterfaceToStr(info_m["entRole"]))),
|
|
|
- "entNicheDis": RsaEncrypt([]byte(common.InterfaceToStr(info_m["entNicheDis"]))),
|
|
|
- "positionId": RsaEncrypt([]byte(common.InterfaceToStr(info_m["positionId"]))),
|
|
|
- "accountId": RsaEncrypt([]byte(common.InterfaceToStr(info_m["accountId"]))),
|
|
|
- "entAccountId": RsaEncrypt([]byte(common.InterfaceToStr(info_m["entAccountId"]))),
|
|
|
- "entId": RsaEncrypt([]byte(common.InterfaceToStr(info_m["entId"]))),
|
|
|
- "entName": RsaEncrypt([]byte(common.InterfaceToStr(info_m["entName"]))),
|
|
|
- "entUserName": RsaEncrypt([]byte(common.InterfaceToStr(info_m["entUserName"]))),
|
|
|
- "entUserId": RsaEncrypt([]byte(common.InterfaceToStr(info_m["entUserId"]))),
|
|
|
- "userId": RsaEncrypt([]byte(common.InterfaceToStr(info_m["base_user_id"]))),
|
|
|
+ "nickName": RsaEncrypt([]byte(gconv.String(info_m["s_nickname"]))),
|
|
|
+ "entRole": RsaEncrypt([]byte(gconv.String(info_m["entRole"]))),
|
|
|
+ "entNicheDis": RsaEncrypt([]byte(gconv.String(info_m["entNicheDis"]))),
|
|
|
+ "positionId": RsaEncrypt([]byte(gconv.String(info_m["positionId"]))),
|
|
|
+ "accountId": RsaEncrypt([]byte(gconv.String(info_m["accountId"]))),
|
|
|
+ "entAccountId": RsaEncrypt([]byte(gconv.String(info_m["entAccountId"]))),
|
|
|
+ "entId": RsaEncrypt([]byte(gconv.String(info_m["entId"]))),
|
|
|
+ "entName": RsaEncrypt([]byte(gconv.String(info_m["entName"]))),
|
|
|
+ "entUserName": RsaEncrypt([]byte(gconv.String(info_m["entUserName"]))),
|
|
|
+ "entUserId": RsaEncrypt([]byte(gconv.String(info_m["entUserId"]))),
|
|
|
+ "userId": RsaEncrypt([]byte(gconv.String(info_m["base_user_id"]))),
|
|
|
}
|
|
|
}
|
|
|
return infoMap
|