Browse Source

Merge remote-tracking branch 'origin/master'

WH01243 9 months ago
parent
commit
c339c9ff8f
3 changed files with 12 additions and 2 deletions
  1. 10 2
      api/internal/service/CoopHistoryService.go
  2. 1 0
      api/internal/types/types.go
  3. 1 0
      api/networkmanage.api

+ 10 - 2
api/internal/service/CoopHistoryService.go

@@ -76,8 +76,16 @@ type Cooperate struct {
 
 func GetPrList(req *types.CoopHistoryReq) (result []*ResultData, size_1, size_2, size_3, size_4 int64) {
 	pTmp := ProjectTmp{}
-	pid := encrypt.CommonDecodeArticle("content", req.Pid)
-	err := T.ClickhouseConn.QueryRow(context.TODO(), sql_2_0, pid).ScanStruct(&pTmp)
+	id := ""
+	if req.Pid != "" {
+		id = req.Pid
+	} else if req.Bid != "" {
+		id = encrypt.CommonDecodeArticle("content", req.Bid)[0]
+	}
+	if id == "" {
+		return
+	}
+	err := T.ClickhouseConn.QueryRow(context.TODO(), sql_2_0, id).ScanStruct(&pTmp)
 	if err != nil {
 		return nil, 0, 0, 0, 0
 	}

+ 1 - 0
api/internal/types/types.go

@@ -46,6 +46,7 @@ type CoopHistoryReq struct {
 	EntUserId    string `header:"entUserId,optional"`
 	DeptId       string `header:"deptId,optional"` //部门id
 	Pid          string `json:"projectId"`
+	Bid          string `json:"infoId"`
 	ChannelType  string `json:"channelType"`
 }
 

+ 1 - 0
api/networkmanage.api

@@ -59,6 +59,7 @@ type (
 		EntUserId    string `header:"entUserId,optional"`
 		DeptId       string `header:"deptId,optional"` //部门id
 		Pid          string `json:"projectId"`
+		Bid          string `json:"infoId"`
 		ChannelType  string `json:"channelType"`
 	}
 	AddOrUpdateReq {