瀏覽代碼

人脉公关渠道新增接口

Jianghan 9 月之前
父節點
當前提交
75574cb59f

+ 29 - 0
api/internal/handler/prcollectlisthandler.go

@@ -0,0 +1,29 @@
+package handler
+
+import (
+	"net/http"
+
+	"bp.jydev.jianyu360.cn/CRM/networkManage/api/internal/logic"
+	"bp.jydev.jianyu360.cn/CRM/networkManage/api/internal/svc"
+	"bp.jydev.jianyu360.cn/CRM/networkManage/api/internal/types"
+	"github.com/zeromicro/go-zero/rest/httpx"
+)
+
+// 公关渠道-标讯收藏项目找人脉
+func PrCollectListHandler(svcCtx *svc.ServiceContext) http.HandlerFunc {
+	return func(w http.ResponseWriter, r *http.Request) {
+		var req types.PrCollectListReq
+		if err := httpx.Parse(r, &req); err != nil {
+			httpx.ErrorCtx(r.Context(), w, err)
+			return
+		}
+
+		l := logic.NewPrCollectListLogic(r.Context(), svcCtx)
+		resp, err := l.PrCollectList(&req)
+		if err != nil {
+			httpx.ErrorCtx(r.Context(), w, err)
+		} else {
+			httpx.OkJsonCtx(r.Context(), w, resp)
+		}
+	}
+}

+ 29 - 0
api/internal/handler/prmonitorlisthandler.go

@@ -0,0 +1,29 @@
+package handler
+
+import (
+	"net/http"
+
+	"bp.jydev.jianyu360.cn/CRM/networkManage/api/internal/logic"
+	"bp.jydev.jianyu360.cn/CRM/networkManage/api/internal/svc"
+	"bp.jydev.jianyu360.cn/CRM/networkManage/api/internal/types"
+	"github.com/zeromicro/go-zero/rest/httpx"
+)
+
+// 公关渠道-业主监控项目找人脉
+func PrMonitorListHandler(svcCtx *svc.ServiceContext) http.HandlerFunc {
+	return func(w http.ResponseWriter, r *http.Request) {
+		var req types.PrMonitorListReq
+		if err := httpx.Parse(r, &req); err != nil {
+			httpx.ErrorCtx(r.Context(), w, err)
+			return
+		}
+
+		l := logic.NewPrMonitorListLogic(r.Context(), svcCtx)
+		resp, err := l.PrMonitorList(&req)
+		if err != nil {
+			httpx.ErrorCtx(r.Context(), w, err)
+		} else {
+			httpx.OkJsonCtx(r.Context(), w, resp)
+		}
+	}
+}

+ 48 - 24
api/internal/handler/routes.go

@@ -13,64 +13,88 @@ func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
 	server.AddRoutes(
 		[]rest.Route{
 			{
+				// 情报详情
 				Method:  http.MethodPost,
-				Path:    "/networkManage/owner/list",
-				Handler: ownerListHandler(serverCtx),
+				Path:    "/networkManage/infomation/detail",
+				Handler: infoDetailHandler(serverCtx),
 			},
 			{
+				// 人脉库-添加/修改人脉
 				Method:  http.MethodPost,
-				Path:    "/networkManage/network/project/list",
-				Handler: projectListHandler(serverCtx),
+				Path:    "/networkManage/network/addOrUpdate",
+				Handler: addOrUpdateHandler(serverCtx),
 			},
 			{
+				// 人脉库-全部人脉项目
 				Method:  http.MethodPost,
-				Path:    "/networkManage/pr/pname/ass",
-				Handler: PrPnameAssHandler(serverCtx),
+				Path:    "/networkManage/network/allProject",
+				Handler: allProjectHandler(serverCtx),
 			},
 			{
+				// 人脉库-业主名称联想
 				Method:  http.MethodPost,
-				Path:    "/networkManage/pr/project/analyse",
-				Handler: CoopHistoryListHandler(serverCtx),
+				Path:    "/networkManage/network/associate",
+				Handler: associateHandler(serverCtx),
 			},
 			{
+				// 人脉库-列表
 				Method:  http.MethodPost,
-				Path:    "/networkManage/network/addOrUpdate",
-				Handler: addOrUpdateHandler(serverCtx),
+				Path:    "/networkManage/network/networkList",
+				Handler: networkListHandler(serverCtx),
 			},
 			{
+				// 人脉可达商机列表
 				Method:  http.MethodPost,
-				Path:    "/networkManage/network/associate",
-				Handler: associateHandler(serverCtx),
+				Path:    "/networkManage/network/project/list",
+				Handler: projectListHandler(serverCtx),
 			},
 			{
+				// 可介绍业主合作次数
 				Method:  http.MethodPost,
-				Path:    "/networkManage/network/allProject",
-				Handler: allProjectHandler(serverCtx),
+				Path:    "/networkManage/owner/cooperate",
+				Handler: ownerCooperateHandler(serverCtx),
 			},
 			{
+				// 人脉可达潜客业主列表
 				Method:  http.MethodPost,
-				Path:    "/networkManage/network/networkList",
-				Handler: networkListHandler(serverCtx),
+				Path:    "/networkManage/owner/list",
+				Handler: ownerListHandler(serverCtx),
 			},
 			{
+				// 可介绍业主路径
 				Method:  http.MethodPost,
-				Path:    "/networkManage/infomation/detail",
-				Handler: infoDetailHandler(serverCtx),
+				Path:    "/networkManage/owner/route",
+				Handler: ownerRouteHandler(serverCtx),
 			},
 			{
+				// 公关渠道-标讯收藏项目找人脉
 				Method:  http.MethodPost,
-				Path:    "/networkManage/pr/project/history",
-				Handler: projectHistoryHandler(serverCtx),
+				Path:    "/networkManage/pr/collect/list",
+				Handler: PrCollectListHandler(serverCtx),
 			},
 			{
+				// 公关渠道-业主监控项目找人脉
 				Method:  http.MethodPost,
-				Path:    "/networkManage/owner/route",
-				Handler: ownerRouteHandler(serverCtx),
+				Path:    "/networkManage/pr/monitor/list",
+				Handler: PrMonitorListHandler(serverCtx),
 			},
 			{
+				// 项目公关渠道分析-项目名称联想
 				Method:  http.MethodPost,
-				Path:    "/networkManage/owner/cooperate",
-				Handler: ownerCooperateHandler(serverCtx),
+				Path:    "/networkManage/pr/pname/ass",
+				Handler: PrPnameAssHandler(serverCtx),
+			},
+			{
+				// 项目公关渠道分析-与业主合作历史
+				Method:  http.MethodPost,
+				Path:    "/networkManage/pr/project/analyse",
+				Handler: CoopHistoryListHandler(serverCtx),
+			},
+			{
+				// 人脉项目分析-业主合作历史
+				Method:  http.MethodPost,
+				Path:    "/networkManage/pr/project/history",
+				Handler: projectHistoryHandler(serverCtx),
 			},
 		},
 	)

+ 38 - 0
api/internal/logic/prcollectlistlogic.go

@@ -0,0 +1,38 @@
+package logic
+
+import (
+	"bp.jydev.jianyu360.cn/CRM/networkManage/api/internal/service"
+	"context"
+	"fmt"
+
+	"bp.jydev.jianyu360.cn/CRM/networkManage/api/internal/svc"
+	"bp.jydev.jianyu360.cn/CRM/networkManage/api/internal/types"
+
+	"github.com/zeromicro/go-zero/core/logx"
+)
+
+type PrCollectListLogic struct {
+	logx.Logger
+	ctx    context.Context
+	svcCtx *svc.ServiceContext
+}
+
+// 公关渠道-标讯收藏项目找人脉
+func NewPrCollectListLogic(ctx context.Context, svcCtx *svc.ServiceContext) *PrCollectListLogic {
+	return &PrCollectListLogic{
+		Logger: logx.WithContext(ctx),
+		ctx:    ctx,
+		svcCtx: svcCtx,
+	}
+}
+
+func (l *PrCollectListLogic) PrCollectList(req *types.PrCollectListReq) (resp *types.Reply, err error) {
+	logx.Info(fmt.Sprintf("%+v", req))
+	resp = &types.Reply{}
+	list, count := service.GetCollectList(req)
+	resp.Data = map[string]interface{}{
+		"list":  list,
+		"total": count,
+	}
+	return
+}

+ 38 - 0
api/internal/logic/prmonitorlistlogic.go

@@ -0,0 +1,38 @@
+package logic
+
+import (
+	"bp.jydev.jianyu360.cn/CRM/networkManage/api/internal/service"
+	"context"
+	"fmt"
+
+	"bp.jydev.jianyu360.cn/CRM/networkManage/api/internal/svc"
+	"bp.jydev.jianyu360.cn/CRM/networkManage/api/internal/types"
+
+	"github.com/zeromicro/go-zero/core/logx"
+)
+
+type PrMonitorListLogic struct {
+	logx.Logger
+	ctx    context.Context
+	svcCtx *svc.ServiceContext
+}
+
+// 公关渠道-业主监控项目找人脉
+func NewPrMonitorListLogic(ctx context.Context, svcCtx *svc.ServiceContext) *PrMonitorListLogic {
+	return &PrMonitorListLogic{
+		Logger: logx.WithContext(ctx),
+		ctx:    ctx,
+		svcCtx: svcCtx,
+	}
+}
+
+func (l *PrMonitorListLogic) PrMonitorList(req *types.PrMonitorListReq) (resp *types.Reply, err error) {
+	logx.Info(fmt.Sprintf("%+v", req))
+	resp = &types.Reply{}
+	list, count := service.GetMonitorList(req)
+	resp.Data = map[string]interface{}{
+		"list":  list,
+		"total": count,
+	}
+	return
+}

+ 93 - 0
api/internal/service/prListService.go

@@ -0,0 +1,93 @@
+package service
+
+import (
+	"app.yhyue.com/moapp/jybase/common"
+	elastic "app.yhyue.com/moapp/jybase/es"
+	"app.yhyue.com/moapp/jybase/mongodb"
+	T "bp.jydev.jianyu360.cn/CRM/networkManage/api/common"
+	"bp.jydev.jianyu360.cn/CRM/networkManage/api/internal/types"
+	"fmt"
+	"strings"
+)
+
+var (
+	esQ1      = `{"query": {"bool": {"must": [{"terms": {"buyer": ["%s"]}},{"terms": {"toptype": ["采购意向","预告","招标"]}}], "should": [%s], "minimum_should_match": 1}}, "_source": ["%s"], "sort": {"comeintime": {"order": "desc"}}, "from": %d, "size": %d}`
+	esQ2      = `{"query": {"bool": {"must": [{"terms": {"buyer": ["%s"]}},{"terms": {"toptype": ["采购意向","预告","招标"]}}]}}, "_source": ["%s"], "sort": {"comeintime": {"order": "desc"}}, "from": %d, "size": %d}`
+	shouldMul = `{"multi_match": {"query": "%s","type": "phrase", "fields": ["s_topscopeclass"]}}`
+	fields    = []string{"_id", "title", "publishtime", "dataweight", "toptype", "subtype", "type", "area", "city", "s_topscopeclass", "s_subscopeclass", "bidamount", "budget", "buyerclass", "buyer", "winner", "bidopentime", "buyertel", "buyerperson", "agency", "agencytel", "agencyperson", "s_winner", "winnertel", "winnerperson", "signendtime", "bidendtime", "projectinfo", "entidlist"}
+)
+
+func GetMonitorList(req *types.PrMonitorListReq) (resultList *[]map[string]interface{}, total int64) {
+
+	bList, b := T.Mgo.Find("follow_customer", map[string]string{"userId": req.MgoUserId}, `{_id: 1}`, nil, false, -1, -1)
+	if b && len(*bList) > 0 {
+		var bName []string
+		for _, v := range *bList {
+			if name := common.ObjToString(v["name"]); name != "" {
+				bName = append(bName, name)
+			}
+		}
+		pageStart := (req.PageNum - 1) * req.PageSize
+		esQuery1 := ""
+		scopeClass := FindBusiness(req.EntId)
+		if scopeClass != "" {
+			var should []string
+			for _, v := range strings.Split(scopeClass, ",") {
+				should = append(should, fmt.Sprintf(shouldMul, v))
+			}
+			esQuery1 = fmt.Sprintf(esQ1, strings.ReplaceAll(strings.Join(bName, ","), ",", `","`), should, strings.ReplaceAll(strings.Join(fields, ","), ",", `","`), pageStart, req.PageSize)
+		} else {
+			esQuery1 = fmt.Sprintf(esQ2, strings.ReplaceAll(strings.Join(bName, ","), ",", `","`), strings.ReplaceAll(strings.Join(fields, ","), ",", `","`), pageStart, req.PageSize)
+		}
+		total, resultList = elastic.GetWithCount("bidding", "bidding", "", esQuery1)
+		return
+	} else {
+		return nil, 0
+	}
+}
+
+func GetCollectList(req *types.PrCollectListReq) (resultList []map[string]interface{}, total int64) {
+	scopeClass := FindBusiness(req.EntId)
+	info := T.JianyuMysql.Find("bdcollection", map[string]interface{}{"userid": req.UserId}, "", `{id: 1}`, -1, -1)
+	var ids []interface{}
+	for _, m := range *info {
+		if bid := common.ObjToString(m["bid"]); bid != "" {
+			ids = append(ids, mongodb.StringTOBsonId(bid))
+		}
+	}
+	if len(ids) == 0 {
+		return make([]map[string]interface{}, 0), 0
+	}
+	if len(ids) > 100 {
+		ids = ids[:100]
+	}
+	fs := make(map[string]interface{})
+	for _, f := range fields {
+		fs[f] = 1
+	}
+	binfo, b := T.MgoBidding.Find("bidding", map[string]interface{}{"$in": ids}, `{_id: 1}`, fs, false, -1, -1)
+	if b && len(*binfo) > 0 {
+		for _, m := range *binfo {
+			if tp := common.ObjToString(m["toptype"]); tp == "采购意向" || tp == "预告" || tp == "招标" {
+				for _, s := range strings.Split(scopeClass, ",") {
+					if top := common.ObjToString("s_topscopeclass"); strings.Contains(top, s) {
+						resultList = append(resultList, m)
+						break
+					}
+				}
+			}
+		}
+	}
+	total = int64(len(resultList))
+	start := (req.PageNum - 1) * req.PageSize
+	end := start + req.PageSize
+
+	// 处理边界情况
+	if start >= len(resultList) {
+		return make([]map[string]interface{}, 0), total
+	}
+	if end > len(resultList) {
+		end = len(resultList)
+	}
+	return resultList[start:end], total
+}

+ 97 - 80
api/internal/types/types.go

@@ -1,69 +1,6 @@
 // Code generated by goctl. DO NOT EDIT.
 package types
 
-type Reply struct {
-	Error_code int64       `json:"error_code"`
-	Error_msg  string      `json:"error_msg"`
-	Data       interface{} `json:"data"`
-}
-
-type OwnerListReq struct {
-	PartyA           string `json:"partyA,optional"`           //甲方
-	Supplier         string `json:"supplier,optional"`         //供应商
-	Heterotophy      string `json:"heterotophy,optional"`      //同甲异业
-	Intermediary     string `json:"intermediary,optional"`     //中间人
-	Agency           string `json:"agency,optional"`           //代理机构
-	SearchEntName    string `json:"searchEntName,optional"`    //搜索企业名称
-	SourceType       string `json:"sourceType,optional"`       //搜索类型 1 只看转介绍成功率高2只看已监控的
-	ProcessingStatus string `json:"processingStatus,optional"` //处理状态1未处理2已忽略3已建客户
-	Area             string `json:"area,optional"`             //项目地区
-	PositionId       int64  `header:"positionId,optional"`
-	PageSize         int64  `json:"pageSize,optional"`
-	PageIndex        int64  `json:"pageIndex,optional"`
-	ProjectType      string `json:"projectType,optional"`
-	EntAccountId     int64  `header:"entAccountId"`
-}
-
-type ProjectListReq struct {
-	UserId       string `header:"userId,optional"`
-	PositionId   int64  `header:"positionId,optional"`
-	EntId        string `header:"entId,optional"`
-	EntUserId    string `header:"entUserId,optional"`
-	DeptId       string `header:"deptId,optional"`     //部门id
-	PartyA       string `json:"partyA,optional"`       //甲方
-	Supplier     string `json:"supplier,optional"`     //供应商
-	Heterotophy  string `json:"heterotophy,optional"`  //同甲异业
-	Intermediary string `json:"intermediary,optional"` //中间人
-	Agency       string `json:"agency,optional"`       //代理机构
-	PageNum      int    `json:"pageNum"`
-	PageSize     int    `json:"pageSize"`
-	BusinessType string `json:"businessType"`
-	SaleStatus   string `json:"saleStatus"`
-	ProjectName  string `json:"projectName,optional"`
-	StartTime    int64  `json:"startTime,optional"`
-	EntTime      int64  `json:"entTime,optional"`
-	Area         string `json:"area,optional"`
-	City         string `json:"city,optional"`
-	District     string `json:"district,optional"`
-	PropertyForm string `json:"propertyForm,optional"`
-	SubClass     string `json:"subClass,optional"`
-	Amount       string `json:"amount,optional"`
-}
-
-type PnameAssReq struct {
-	ProjectName string `json:"projectName"`
-}
-
-type CoopHistoryReq struct {
-	EntAccountId int64  `header:"entAccountId,optional"` //企业账户id
-	PositionId   int64  `header:"positionId,optional"`
-	EntId        string `header:"entId,optional"`
-	EntUserId    string `header:"entUserId,optional"`
-	DeptId       string `header:"deptId,optional"` //部门id
-	Pid          string `json:"projectId"`
-	ChannelType  string `json:"channelType"`
-}
-
 type AddOrUpdateReq struct {
 	PositionId              int64  `header:"positionId"`
 	EntUserId               int64  `header:"entUserId,optional"`
@@ -83,6 +20,14 @@ type AddOrUpdateReq struct {
 	Type                    string `json:"type"`
 }
 
+type AllprojectReq struct {
+	EntAccountId int64  `header:"entAccountId"`
+	PositionId   int64  `header:"positionId"`
+	Name         string `json:"name,optional"`
+	Type         string `json:"type,optional"`
+	Id           string `json:"id,optional"`
+}
+
 type AssociateReq struct {
 	EntAccountId int64  `header:"entAccountId"`
 	EntName      string `header:"entName"`
@@ -90,12 +35,27 @@ type AssociateReq struct {
 	Type         string `json:"type"`
 }
 
-type AllprojectReq struct {
-	EntAccountId int64  `header:"entAccountId"`
-	PositionId   int64  `header:"positionId"`
-	Name         string `json:"name,optional"`
-	Type         string `json:"type,optional"`
-	Id           string `json:"id,optional"`
+type CoopHistoryReq struct {
+	EntAccountId int64  `header:"entAccountId,optional"` //企业账户id
+	PositionId   int64  `header:"positionId,optional"`
+	EntId        string `header:"entId,optional"`
+	EntUserId    string `header:"entUserId,optional"`
+	DeptId       string `header:"deptId,optional"` //部门id
+	Pid          string `json:"projectId"`
+	ChannelType  string `json:"channelType"`
+}
+
+type CooperateOwnerListReq struct {
+	BuyerId       string `json:"buyerId,optional"`
+	BuyerName     string `json:"buyerName,optional"`
+	WinnerId      string `json:"winnerId,optional"`
+	WinnerName    string `json:"winnerName,optional"`
+	CooperateType string `json:"cooperateType,optional"`
+	PositionId    int64  `header:"positionId,optional"`
+}
+
+type InfoDetailReq struct {
+	InfoId string `json:"infoId"`
 }
 
 type NetWorkListReq struct {
@@ -117,8 +77,42 @@ type NetWorkListReq struct {
 	Monitorcount_end   int64  `json:"monitorcount_end,optional"`
 }
 
-type InfoDetailReq struct {
-	InfoId string `json:"infoId"`
+type OwnerListReq struct {
+	PartyA           string `json:"partyA,optional"`           //甲方
+	Supplier         string `json:"supplier,optional"`         //供应商
+	Heterotophy      string `json:"heterotophy,optional"`      //同甲异业
+	Intermediary     string `json:"intermediary,optional"`     //中间人
+	Agency           string `json:"agency,optional"`           //代理机构
+	SearchEntName    string `json:"searchEntName,optional"`    //搜索企业名称
+	SourceType       string `json:"sourceType,optional"`       //搜索类型 1 只看转介绍成功率高2只看已监控的
+	ProcessingStatus string `json:"processingStatus,optional"` //处理状态1未处理2已忽略3已建客户
+	Area             string `json:"area,optional"`             //项目地区
+	PositionId       int64  `header:"positionId,optional"`
+	PageSize         int64  `json:"pageSize,optional"`
+	PageIndex        int64  `json:"pageIndex,optional"`
+	ProjectType      string `json:"projectType,optional"`
+	EntAccountId     int64  `header:"entAccountId"`
+}
+
+type PnameAssReq struct {
+	ProjectName string `json:"projectName"`
+}
+
+type PrCollectListReq struct {
+	UserId     string `header:userId,optional`
+	MgoUserId  string `header:mgoUserId,optional`
+	PositionId int64  `header:"positionId,optional"`
+	EntId      int64  `header:"entId,optional"`
+	PageSize   int    `json:"pageSize"`
+	PageNum    int    `json:"pageNum"`
+}
+
+type PrMonitorListReq struct {
+	MgoUserId  string `header:mgoUserId,optional`
+	PositionId int64  `header:"positionId,optional"`
+	EntId      int64  `header:"entId,optional"`
+	PageSize   int    `json:"pageSize"`
+	PageNum    int    `json:"pageNum"`
 }
 
 type PrjectHistoryReq struct {
@@ -127,17 +121,40 @@ type PrjectHistoryReq struct {
 	WinnerId string `json:"winnerId"`
 }
 
+type ProjectListReq struct {
+	UserId       string `header:"userId,optional"`
+	PositionId   int64  `header:"positionId,optional"`
+	EntId        string `header:"entId,optional"`
+	EntUserId    string `header:"entUserId,optional"`
+	DeptId       string `header:"deptId,optional"`     //部门id
+	PartyA       string `json:"partyA,optional"`       //甲方
+	Supplier     string `json:"supplier,optional"`     //供应商
+	Heterotophy  string `json:"heterotophy,optional"`  //同甲异业
+	Intermediary string `json:"intermediary,optional"` //中间人
+	Agency       string `json:"agency,optional"`       //代理机构
+	PageNum      int    `json:"pageNum"`
+	PageSize     int    `json:"pageSize"`
+	BusinessType string `json:"businessType"`
+	SaleStatus   string `json:"saleStatus"`
+	ProjectName  string `json:"projectName,optional"`
+	StartTime    int64  `json:"startTime,optional"`
+	EntTime      int64  `json:"entTime,optional"`
+	Area         string `json:"area,optional"`
+	City         string `json:"city,optional"`
+	District     string `json:"district,optional"`
+	PropertyForm string `json:"propertyForm,optional"`
+	SubClass     string `json:"subClass,optional"`
+	Amount       string `json:"amount,optional"`
+}
+
+type Reply struct {
+	Error_code int64       `json:"error_code"`
+	Error_msg  string      `json:"error_msg"`
+	Data       interface{} `json:"data"`
+}
+
 type RouteOwnerListReq struct {
 	BuyerId    string `json:"buyerId,optional"`
 	BuyerName  string `json:"buyerName,optional"`
 	PositionId int64  `header:"positionId,optional"`
 }
-
-type CooperateOwnerListReq struct {
-	BuyerId       string `json:"buyerId,optional"`
-	BuyerName     string `json:"buyerName,optional"`
-	WinnerId      string `json:"winnerId,optional"`
-	WinnerName    string `json:"winnerName,optional"`
-	CooperateType string `json:"cooperateType,optional"`
-	PositionId    int64  `header:"positionId,optional"`
-}

+ 49 - 25
api/networkmanage.api

@@ -7,15 +7,15 @@ type (
 		Data       interface{} `json:"data"`
 	}
 	OwnerListReq {
-		PartyA           string `json:"partyA,optional"`           //甲方
-		Supplier         string `json:"supplier,optional"`         //供应商
-		Heterotophy      string `json:"heterotophy,optional"`      //同甲异业
-		Intermediary     string `json:"intermediary,optional"`     //中间人
-		Agency           string `json:"agency,optional"`           //代理机构
-		SearchEntName    string `json:"searchEntName,optional"`    //搜索企业名称
-		SourceType       string `json:"sourceType,optional"`       //搜索类型 1 只看转介绍成功率高2只看已监控的
+		PartyA           string `json:"partyA,optional"` //甲方
+		Supplier         string `json:"supplier,optional"` //供应商
+		Heterotophy      string `json:"heterotophy,optional"` //同甲异业
+		Intermediary     string `json:"intermediary,optional"` //中间人
+		Agency           string `json:"agency,optional"` //代理机构
+		SearchEntName    string `json:"searchEntName,optional"` //搜索企业名称
+		SourceType       string `json:"sourceType,optional"` //搜索类型 1 只看转介绍成功率高2只看已监控的
 		ProcessingStatus string `json:"processingStatus,optional"` //处理状态1未处理2已忽略3已建客户
-		Area             string `json:"area,optional"`             //项目地区
+		Area             string `json:"area,optional"` //项目地区
 		PositionId       int64  `header:"positionId,optional"`
 		PageSize         int64  `json:"pageSize,optional"`
 		PageIndex        int64  `json:"pageIndex,optional"`
@@ -27,12 +27,12 @@ type (
 		PositionId   int64  `header:"positionId,optional"`
 		EntId        string `header:"entId,optional"`
 		EntUserId    string `header:"entUserId,optional"`
-		DeptId       string `header:"deptId,optional"`     //部门id
-		PartyA       string `json:"partyA,optional"`       //甲方
-		Supplier     string `json:"supplier,optional"`     //供应商
-		Heterotophy  string `json:"heterotophy,optional"`  //同甲异业
+		DeptId       string `header:"deptId,optional"` //部门id
+		PartyA       string `json:"partyA,optional"` //甲方
+		Supplier     string `json:"supplier,optional"` //供应商
+		Heterotophy  string `json:"heterotophy,optional"` //同甲异业
 		Intermediary string `json:"intermediary,optional"` //中间人
-		Agency       string `json:"agency,optional"`       //代理机构
+		Agency       string `json:"agency,optional"` //代理机构
 		PageNum      int    `json:"pageNum"`
 		PageSize     int    `json:"pageSize"`
 		BusinessType string `json:"businessType"`
@@ -129,54 +129,78 @@ type (
 		CooperateType string `json:"cooperateType,optional"`
 		PositionId    int64  `header:"positionId,optional"`
 	}
+	PrMonitorListReq {
+		MgoUserId  string `header:mgoUserId,optional`
+		PositionId int64  `header:"positionId,optional"`
+		EntId      int64  `header:"entId,optional"`
+		PageSize   int    `json:"pageSize"`
+		PageNum    int    `json:"pageNum"`
+	}
+	PrCollectListReq {
+		UserId     string `header:userId,optional`
+		MgoUserId  string `header:mgoUserId,optional`
+		PositionId int64  `header:"positionId,optional"`
+		EntId      int64  `header:"entId,optional"`
+		PageSize   int    `json:"pageSize"`
+		PageNum    int    `json:"pageNum"`
+	}
 )
 
 service networkManage {
 	@doc "人脉可达潜客业主列表"
 	@handler ownerList
 	post /networkManage/owner/list (OwnerListReq) returns (Reply)
-	
+
 	@doc "人脉可达商机列表"
 	@handler projectList
 	post /networkManage/network/project/list (ProjectListReq) returns (Reply)
-	
+
 	@doc "项目公关渠道分析-项目名称联想"
 	@handler PrPnameAss
 	post /networkManage/pr/pname/ass (PnameAssReq) returns (Reply)
-	
+
 	@doc "项目公关渠道分析-与业主合作历史"
 	@handler CoopHistoryList
 	post /networkManage/pr/project/analyse (CoopHistoryReq) returns (Reply)
-	
+
 	@doc "人脉库-添加/修改人脉"
 	@handler addOrUpdate
 	post /networkManage/network/addOrUpdate (AddOrUpdateReq) returns (Reply)
-	
+
 	@doc "人脉库-业主名称联想"
 	@handler associate
 	post /networkManage/network/associate (AssociateReq) returns (Reply)
-	
+
 	@doc "人脉库-全部人脉项目"
 	@handler allProject
 	post /networkManage/network/allProject (AllprojectReq) returns (Reply)
-	
+
 	@doc "人脉库-列表"
 	@handler networkList
 	post /networkManage/network/networkList (NetWorkListReq) returns (Reply)
-	
+
 	@doc "情报详情"
 	@handler infoDetail
 	post /networkManage/infomation/detail (InfoDetailReq) returns (Reply)
-	
+
 	@doc "人脉项目分析-业主合作历史"
 	@handler projectHistory
 	post /networkManage/pr/project/history (PrjectHistoryReq) returns (Reply)
-	
+
 	@doc "可介绍业主路径"
 	@handler ownerRoute
 	post /networkManage/owner/route (RouteOwnerListReq) returns (Reply)
-	
+
 	@doc "可介绍业主合作次数"
 	@handler ownerCooperate
 	post /networkManage/owner/cooperate (CooperateOwnerListReq) returns (Reply)
-}
+
+	@doc "公关渠道-业主监控项目找人脉"
+	@handler PrMonitorList
+	post /networkManage/pr/monitor/list (PrMonitorListReq) returns (Reply)
+
+	@doc "公关渠道-标讯收藏项目找人脉"
+	@handler PrCollectList
+	post /networkManage/pr/collect/list (PrCollectListReq) returns (Reply)
+}
+