Kaynağa Gözat

wip:认领管理 提交api、及调整认领

fuwencai 2 yıl önce
ebeveyn
işleme
64c4fd7389

+ 8 - 1
README.md

@@ -1 +1,8 @@
-# 领域化产品
+# 领域化产品
+
+
+
+
+
+## 注意事项 
+- github.com/zeromicro/go-zero  与旧版本(github.com/tal-tech/go-zero)不兼容  需使用新版goctl生成代码。

+ 19 - 2
api/medical/internal/logic/distributor/claimdistributorlogic.go

@@ -1,6 +1,7 @@
 package distributor
 package distributor
 
 
 import (
 import (
+	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/rpc/medical/medical"
 	"context"
 	"context"
 
 
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/api/medical/internal/svc"
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/api/medical/internal/svc"
@@ -23,8 +24,24 @@ func NewClaimDistributorLogic(ctx context.Context, svcCtx *svc.ServiceContext) *
 	}
 	}
 }
 }
 
 
+// ClaimDistributor 我认领的经销商列表
 func (l *ClaimDistributorLogic) ClaimDistributor(req *types.ClaimDistributorReq) (resp *types.CommonRes, err error) {
 func (l *ClaimDistributorLogic) ClaimDistributor(req *types.ClaimDistributorReq) (resp *types.CommonRes, err error) {
-	// todo: add your logic here and delete this line
+	if req.PageSize == 0 {
+		req.PageSize = 10
+	}
+	if req.Page < 0 {
+		req.Page = 0
+	}
+	rs, _ := l.svcCtx.Medical.ClaimedDistributorList(l.ctx, &medical.ClaimedReq{
+		UserId:   int64(req.UserId),
+		Page:     int64(req.Page),
+		PageSize: int64(req.PageSize),
+	})
+
+	return &types.CommonRes{
+		Error_msg:  rs.ErrorMsg,
+		Error_code: int(rs.ErrorCode),
+		Data:       rs.Data,
+	}, nil
 
 
-	return
 }
 }

+ 19 - 2
api/medical/internal/logic/institution/claiminstitutionlogic.go

@@ -1,6 +1,7 @@
 package institution
 package institution
 
 
 import (
 import (
+	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/rpc/medical/medical"
 	"context"
 	"context"
 
 
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/api/medical/internal/svc"
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/api/medical/internal/svc"
@@ -23,8 +24,24 @@ func NewClaimInstitutionLogic(ctx context.Context, svcCtx *svc.ServiceContext) *
 	}
 	}
 }
 }
 
 
+// ClaimInstitution 我认领的医疗机构列表
 func (l *ClaimInstitutionLogic) ClaimInstitution(req *types.ClaimInstitutionReq) (resp *types.CommonRes, err error) {
 func (l *ClaimInstitutionLogic) ClaimInstitution(req *types.ClaimInstitutionReq) (resp *types.CommonRes, err error) {
-	// todo: add your logic here and delete this line
+	if req.PageSize == 0 {
+		req.PageSize = 10
+	}
+	if req.Page < 0 {
+		req.Page = 0
+	}
+	rs, _ := l.svcCtx.Medical.ClaimedInstitutionList(l.ctx, &medical.ClaimedReq{
+		UserId:   int64(req.UserId),
+		Page:     int64(req.Page),
+		PageSize: int64(req.PageSize),
+	})
+
+	return &types.CommonRes{
+		Error_msg:  rs.ErrorMsg,
+		Error_code: int(rs.ErrorCode),
+		Data:       rs.Data,
+	}, nil
 
 
-	return
 }
 }

+ 13 - 2
api/medical/internal/logic/public/claimlogic.go

@@ -1,6 +1,7 @@
 package public
 package public
 
 
 import (
 import (
+	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/rpc/medical/medical"
 	"context"
 	"context"
 
 
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/api/medical/internal/svc"
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/api/medical/internal/svc"
@@ -23,8 +24,18 @@ func NewClaimLogic(ctx context.Context, svcCtx *svc.ServiceContext) *ClaimLogic
 	}
 	}
 }
 }
 
 
+// Claim 认领
 func (l *ClaimLogic) Claim(req *types.ClaimReq) (resp *types.CommonRes, err error) {
 func (l *ClaimLogic) Claim(req *types.ClaimReq) (resp *types.CommonRes, err error) {
-	// todo: add your logic here and delete this line
 
 
-	return
+	rs, _ := l.svcCtx.Medical.Claim(l.ctx, &medical.ClaimReq{
+		UserId: int64(req.UserId),
+		EntId:  req.EntId,
+		Type:   int64(req.Type),
+		AppId:  req.AppId,
+	})
+
+	return &types.CommonRes{
+		Error_msg:  rs.ErrorMsg,
+		Error_code: int(rs.ErrorCode),
+	}, nil
 }
 }

+ 14 - 2
api/medical/internal/logic/public/isclaimedlogic.go

@@ -1,6 +1,7 @@
 package public
 package public
 
 
 import (
 import (
+	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/rpc/medical/medical"
 	"context"
 	"context"
 
 
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/api/medical/internal/svc"
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/api/medical/internal/svc"
@@ -23,8 +24,19 @@ func NewIsClaimedLogic(ctx context.Context, svcCtx *svc.ServiceContext) *IsClaim
 	}
 	}
 }
 }
 
 
+// IsClaimed 是否认领
 func (l *IsClaimedLogic) IsClaimed(req *types.IsClaimedReq) (resp *types.CommonRes, err error) {
 func (l *IsClaimedLogic) IsClaimed(req *types.IsClaimedReq) (resp *types.CommonRes, err error) {
-	// todo: add your logic here and delete this line
 
 
-	return
+	rs, _ := l.svcCtx.Medical.IsClaimed(l.ctx, &medical.IsClaimedReq{
+		UserId: int64(req.UserId),
+		EntId:  req.CompanyId,
+		Type:   int64(req.Type),
+	})
+
+	return &types.CommonRes{
+		Error_msg:  rs.ErrorMsg,
+		Error_code: int(rs.ErrorCode),
+		Data:       rs.Data,
+	}, nil
+
 }
 }

+ 10 - 2
api/medical/internal/logic/public/unclaimedlogic.go

@@ -1,6 +1,7 @@
 package public
 package public
 
 
 import (
 import (
+	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/rpc/medical/medical"
 	"context"
 	"context"
 
 
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/api/medical/internal/svc"
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/api/medical/internal/svc"
@@ -23,8 +24,15 @@ func NewUnclaimedLogic(ctx context.Context, svcCtx *svc.ServiceContext) *Unclaim
 	}
 	}
 }
 }
 
 
+// Unclaimed 取消认领
 func (l *UnclaimedLogic) Unclaimed(req *types.UnclaimedReq) (resp *types.CommonRes, err error) {
 func (l *UnclaimedLogic) Unclaimed(req *types.UnclaimedReq) (resp *types.CommonRes, err error) {
-	// todo: add your logic here and delete this line
+	rs, _ := l.svcCtx.Medical.UnClaimed(l.ctx, &medical.UnclaimedReq{
+		UserId: int64(req.UserId),
+		Id:     int64(req.Id),
+	})
 
 
-	return
+	return &types.CommonRes{
+		Error_msg:  rs.ErrorMsg,
+		Error_code: int(rs.ErrorCode),
+	}, nil
 }
 }

+ 16 - 12
api/medical/internal/types/types.go

@@ -43,16 +43,16 @@ type PortraitReq struct {
 }
 }
 
 
 type ClaimInstitutionReq struct {
 type ClaimInstitutionReq struct {
-	UserId      string `header:"newUserId"`           // 用户id
+	UserId      int    `header:"newUserId"`           // 用户id
 	CompanyName string `json:"company_name,optional"` // 要搜索的医疗机构
 	CompanyName string `json:"company_name,optional"` // 要搜索的医疗机构
 	Page        int    `json:"page,optional"`         // 页码
 	Page        int    `json:"page,optional"`         // 页码
 	PageSize    int    `json:"page_size,optional"`    // 每页条数
 	PageSize    int    `json:"page_size,optional"`    // 每页条数
 }
 }
 
 
 type ClaimDistributorReq struct {
 type ClaimDistributorReq struct {
-	UserId   string `header:"newUserId"`        // 用户id
-	Page     int    `json:"page,optional"`      // 页码
-	PageSize int    `json:"page_size,optional"` // 每页条数
+	UserId   int `header:"newUserId"`        // 用户id
+	Page     int `json:"page,optional"`      // 页码
+	PageSize int `json:"page_size,optional"` // 每页条数
 }
 }
 
 
 type DistributorProductsReq struct {
 type DistributorProductsReq struct {
@@ -62,20 +62,24 @@ type DistributorProductsReq struct {
 }
 }
 
 
 type ClaimReq struct {
 type ClaimReq struct {
-	Type    int    `json:"type"`        // 1 医疗机构 2 经销商
-	EntId   string `json:"entid"`       // 企业标识
-	EntName string `json:"ent_name"`    // 企业名称
-	Address string `json:"address"`     // 所在地
-	UserId  string `header:"newUserId"` // 用户id
+	Type          int    `json:"type"`           // 1 医疗机构 2 经销商
+	EntId         string `json:"entid"`          // 企业标识
+	EntName       string `json:"ent_name"`       // 企业名称
+	Address       string `json:"address"`        // 所在地
+	EstablishDate string `json:"establish_date"` // 成立日期
+	RegistCapital string `json:"regist_capital"` // 注册资本
+	Phone         string `header:"phone"`        // 联系方式
+	UserId        int    `header:"newUserId"`    // 用户id
+	AppId         string `header:"appId"`        // appid
 }
 }
 
 
 type UnclaimedReq struct {
 type UnclaimedReq struct {
-	UserId string `header:"newUserId"` // 用户id
-	Id     int    `json:"id"`
+	UserId int `header:"newUserId"` // 用户id
+	Id     int `json:"id"`
 }
 }
 
 
 type IsClaimedReq struct {
 type IsClaimedReq struct {
-	UserId    string `header:"newUserId"` // 用户id
+	UserId    int    `header:"newUserId"` // 用户id
 	CompanyId string `json:"company_id"`  // 机构id
 	CompanyId string `json:"company_id"`  // 机构id
 	Type      int    `json:"type"`        // 1 医疗机构 2 经销商
 	Type      int    `json:"type"`        // 1 医疗机构 2 经销商
 }
 }

+ 17 - 14
api/medical/medical.api

@@ -41,7 +41,7 @@ type PortraitReq {
 }
 }
 // 我认领的医疗机构请求
 // 我认领的医疗机构请求
 type ClaimInstitutionReq {
 type ClaimInstitutionReq {
-	UserId      string `header:"newUserId"`           // 用户id
+	UserId      int    `header:"newUserId"`           // 用户id
 	CompanyName string `json:"company_name,optional"` // 要搜索的医疗机构
 	CompanyName string `json:"company_name,optional"` // 要搜索的医疗机构
 	Page        int    `json:"page,optional"`         // 页码
 	Page        int    `json:"page,optional"`         // 页码
 	PageSize    int    `json:"page_size,optional"`    // 每页条数
 	PageSize    int    `json:"page_size,optional"`    // 每页条数
@@ -49,9 +49,9 @@ type ClaimInstitutionReq {
 
 
 // 我认领的经销商请求
 // 我认领的经销商请求
 type ClaimDistributorReq {
 type ClaimDistributorReq {
-	UserId   string `header:"newUserId"`        // 用户id
-	Page     int    `json:"page,optional"`      // 页码
-	PageSize int    `json:"page_size,optional"` // 每页条数
+	UserId   int `header:"newUserId"`        // 用户id
+	Page     int `json:"page,optional"`      // 页码
+	PageSize int `json:"page_size,optional"` // 每页条数
 }
 }
 
 
 // 获取经销商医械信息请求
 // 获取经销商医械信息请求
@@ -62,23 +62,26 @@ type DistributorProductsReq {
 }
 }
 // 认领
 // 认领
 type ClaimReq {
 type ClaimReq {
-	Type    int    `json:"type"`        // 1 医疗机构 2 经销商
-	EntId   string `json:"entid"`       // 企业标识
-	EntName string `json:"ent_name"`    // 企业名称
-	Address string `json:"address"`     // 所在地
-	UserId  string `header:"newUserId"` // 用户id
-
+	Type          int    `json:"type"`           // 1 医疗机构 2 经销商
+	EntId         string `json:"entid"`          // 企业标识
+	EntName       string `json:"ent_name"`       // 企业名称
+	Address       string `json:"address"`        // 所在地
+	EstablishDate string `json:"establish_date"` // 成立日期
+	RegistCapital string `json:"regist_capital"` // 注册资本
+	Phone         string `header:"phone"`        // 联系方式
+	UserId        int    `header:"newUserId"`    // 用户id
+	AppId         string `header:"appId"`        // appid
 }
 }
 
 
 // 取消认领
 // 取消认领
 type UnclaimedReq {
 type UnclaimedReq {
-	UserId string `header:"newUserId"` // 用户id
-	Id     int    `json:"id"`
+	UserId int `header:"newUserId"` // 用户id
+	Id     int `json:"id"`
 }
 }
 
 
 // 是否是认领过的
 // 是否是认领过的
 type IsClaimedReq {
 type IsClaimedReq {
-	UserId    string `header:"newUserId"` // 用户id
+	UserId    int    `header:"newUserId"` // 用户id
 	CompanyId string `json:"company_id"`  // 机构id
 	CompanyId string `json:"company_id"`  // 机构id
 	Type      int    `json:"type"`        // 1 医疗机构 2 经销商
 	Type      int    `json:"type"`        // 1 医疗机构 2 经销商
 }
 }
@@ -91,7 +94,7 @@ service medical-api {
 	@handler searchInstitution
 	@handler searchInstitution
 	post /search/institution (SearchInstitutionReq) returns (CommonRes); 	    // 搜索医疗机构
 	post /search/institution (SearchInstitutionReq) returns (CommonRes); 	    // 搜索医疗机构
 	@handler getFilterItem
 	@handler getFilterItem
-	post /getFilterItem () returns (CommonRes); 	                            // 获取医疗机构筛选条件
+	post /getFilterItem  returns (CommonRes); 	                            // 获取医疗机构筛选条件
 	@handler portraitInstitution
 	@handler portraitInstitution
 	post /portrait/institution (PortraitReq) returns (CommonRes); 	// 医疗机构画像-医院信息 不确定是否需要
 	post /portrait/institution (PortraitReq) returns (CommonRes); 	// 医疗机构画像-医院信息 不确定是否需要
 	@handler claimInstitution
 	@handler claimInstitution

+ 2 - 1
entity/code.go

@@ -5,7 +5,8 @@ const (
 	CODE_MEDICAL_INSTITUTION_LEVEL = "code_level"
 	CODE_MEDICAL_INSTITUTION_LEVEL = "code_level"
 	CODE_MEDICAL_INSTITUTION_TYPE  = "code_type"
 	CODE_MEDICAL_INSTITUTION_TYPE  = "code_type"
 	DOMAIN_CAPITAL_RETENTION       = "domain_capital_retention"
 	DOMAIN_CAPITAL_RETENTION       = "domain_capital_retention"
-	TableDomainEntClaim            = "domain_ent_claim"
+	TableDomainEntClaim            = "domain_ent_claim" // 认领表
+	TableCompanyBasInfo            = "company_baseinfo" // 企业信息表
 )
 )
 
 
 //返回状态
 //返回状态

+ 6 - 4
entity/db.go

@@ -20,11 +20,13 @@ type EsStruct struct {
 }
 }
 
 
 var (
 var (
-	Mysql     *mysql.Mysql
-	BaseMysql *mysql.Mysql
+	Mysql            *mysql.Mysql
+	BaseMysql        *mysql.Mysql
+	GlobalCommonData *mysql.Mysql
 )
 )
 
 
 type Conn struct {
 type Conn struct {
-	Mysql     *mysql.Mysql
-	BaseMysql *mysql.Mysql
+	Mysql            *mysql.Mysql
+	BaseMysql        *mysql.Mysql
+	GlobalCommonData *mysql.Mysql
 }
 }

+ 1 - 1
go.mod

@@ -5,7 +5,7 @@ go 1.16
 require (
 require (
 	app.yhyue.com/moapp/jybase v0.0.0-20220802080941-07f401baab8b
 	app.yhyue.com/moapp/jybase v0.0.0-20220802080941-07f401baab8b
 	github.com/go-sql-driver/mysql v1.6.0
 	github.com/go-sql-driver/mysql v1.6.0
-	github.com/golang/protobuf v1.5.2
+	github.com/mitchellh/mapstructure v1.1.2
 	github.com/zeromicro/go-zero v1.4.0
 	github.com/zeromicro/go-zero v1.4.0
 	google.golang.org/grpc v1.48.0
 	google.golang.org/grpc v1.48.0
 	google.golang.org/protobuf v1.28.1
 	google.golang.org/protobuf v1.28.1

+ 1 - 0
go.sum

@@ -326,6 +326,7 @@ github.com/mattn/go-sqlite3 v1.9.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOq
 github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0=
 github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0=
 github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 h1:I0XW9+e1XWDxdcEniV4rQAIOPUGDq67JSCiRCgGCZLI=
 github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 h1:I0XW9+e1XWDxdcEniV4rQAIOPUGDq67JSCiRCgGCZLI=
 github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4=
 github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4=
+github.com/mitchellh/mapstructure v1.1.2 h1:fmNYVwqnSfB9mZU6OS2O6GsXM+wcskZDuKQzvN1EDeE=
 github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
 github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
 github.com/mkevac/debugcharts v0.0.0-20191222103121-ae1c48aa8615/go.mod h1:Ad7oeElCZqA1Ufj0U9/liOF4BtVepxRcTvr2ey7zTvM=
 github.com/mkevac/debugcharts v0.0.0-20191222103121-ae1c48aa8615/go.mod h1:Ad7oeElCZqA1Ufj0U9/liOF4BtVepxRcTvr2ey7zTvM=
 github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c=
 github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c=

+ 7 - 0
rpc/medical/etc/medical.yaml

@@ -23,3 +23,10 @@ Es:
   size: 5
   size: 5
   index: smart_new
   index: smart_new
   type: smart
   type: smart
+GlobalCommonData:
+  dbName: global_common_data
+  address: 192.168.3.14:4000
+  userName: root
+  passWord: =PDT49#80Z!RVv52_z
+  maxOpenConns: 5
+  maxIdleConns: 5

+ 14 - 1
rpc/medical/init/init.go

@@ -47,6 +47,19 @@ func init() {
 		}
 		}
 		entity.BaseMysql.Init()
 		entity.BaseMysql.Init()
 	}
 	}
+	commonConfig := C.GlobalCommonData
+	if nn.Address != "" {
+		log.Println("--初始化 mysql--")
+		entity.GlobalCommonData = &mysql.Mysql{
+			Address:      commonConfig.Address,
+			UserName:     commonConfig.UserName,
+			PassWord:     commonConfig.PassWord,
+			DBName:       commonConfig.DbName,
+			MaxOpenConns: commonConfig.MaxOpenConns,
+			MaxIdleConns: commonConfig.MaxIdleConns,
+		}
+		entity.GlobalCommonData.Init()
+	}
 
 
 	fmt.Println()
 	fmt.Println()
 	//初始化 elasticsearch
 	//初始化 elasticsearch
@@ -55,7 +68,7 @@ func init() {
 	//	log.Println("--初始化 elasticsearch--")
 	//	log.Println("--初始化 elasticsearch--")
 	//	log.Println(es.Addr, es.Size)
 	//	log.Println(es.Addr, es.Size)
 	//	elastic.InitElasticSize(es.Addr, es.Size)
 	//	elastic.InitElasticSize(es.Addr, es.Size)
-	//
+	//	elastic.Count()
 	//	//初始化日志信息
 	//	//初始化日志信息
 	//	conf.MustLoad(*logFile, &logc)
 	//	conf.MustLoad(*logFile, &logc)
 	//	if len(logc.Level) > 0 {
 	//	if len(logc.Level) > 0 {

+ 4 - 3
rpc/medical/internal/config/config.go

@@ -7,7 +7,8 @@ import (
 
 
 type Config struct {
 type Config struct {
 	zrpc.RpcServerConf
 	zrpc.RpcServerConf
-	MysqlMain     entity.MysqlMainStruct
-	BaseMysqlMain entity.MysqlMainStruct
-	//Es            entity.EsStruct
+	MysqlMain        entity.MysqlMainStruct
+	BaseMysqlMain    entity.MysqlMainStruct
+	GlobalCommonData entity.MysqlMainStruct
+	Es               entity.EsStruct
 }
 }

+ 20 - 8
rpc/medical/internal/logic/claimlogic.go

@@ -3,11 +3,10 @@ package logic
 import (
 import (
 	"app.yhyue.com/moapp/jybase/date"
 	"app.yhyue.com/moapp/jybase/date"
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/entity"
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/entity"
-	"context"
-
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/rpc/medical/internal/svc"
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/rpc/medical/internal/svc"
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/rpc/medical/medical"
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/rpc/medical/medical"
-
+	"context"
+	"github.com/mitchellh/mapstructure"
 	"github.com/zeromicro/go-zero/core/logx"
 	"github.com/zeromicro/go-zero/core/logx"
 )
 )
 
 
@@ -27,18 +26,31 @@ func NewClaimLogic(ctx context.Context, svcCtx *svc.ServiceContext) *ClaimLogic
 
 
 // Claim 认领(经销商/医疗机构)
 // Claim 认领(经销商/医疗机构)
 func (l *ClaimLogic) Claim(in *medical.ClaimReq) (*medical.CommonResp, error) {
 func (l *ClaimLogic) Claim(in *medical.ClaimReq) (*medical.CommonResp, error) {
+	tmp := struct {
+		CompanyName    string `mapstructure:"company_name,omitempty"`
+		EstablishDate  string `mapstructure:"establish_date,omitempty"`
+		CompanyAddress string `mapstructure:"company_address,omitempty"`
+		CompanyPhone   string `mapstructure:"company_phone,omitempty"`
+		Capital        string `mapstructure:"capital,omitempty"`
+	}{}
+	// 查询基本信息
+	baseInfo := l.svcCtx.EntClaimSrv.GetInstitution(in.EntId)
+	err := mapstructure.Decode(*baseInfo, &tmp)
+	if err != nil {
+		return nil, err
+	}
 
 
 	rs := l.svcCtx.EntClaimSrv.Claim(&entity.EntClaim{
 	rs := l.svcCtx.EntClaimSrv.Claim(&entity.EntClaim{
 		AppId:           in.AppId,
 		AppId:           in.AppId,
 		UserId:          int(in.UserId),
 		UserId:          int(in.UserId),
 		EntId:           in.EntId,
 		EntId:           in.EntId,
-		EntName:         in.EntName,
+		EntName:         tmp.CompanyName,
 		Status:          entity.StatusClaimed,
 		Status:          entity.StatusClaimed,
 		Type:            int(in.Type),
 		Type:            int(in.Type),
-		Address:         in.Address,
-		EstablishDate:   in.EstablishDate,
-		RegisterCapital: in.RegisterCapital,
-		Phone:           in.Phone,
+		Address:         tmp.CompanyAddress,
+		EstablishDate:   tmp.EstablishDate,
+		RegisterCapital: tmp.Capital,
+		Phone:           tmp.CompanyPhone,
 		CreateTime:      date.NowFormat(date.Date_Full_Layout),
 		CreateTime:      date.NowFormat(date.Date_Full_Layout),
 	})
 	})
 	if !rs {
 	if !rs {

+ 3 - 1
rpc/medical/internal/logic/isclaimedlogic.go

@@ -30,6 +30,8 @@ func (l *IsClaimedLogic) IsClaimed(in *medical.IsClaimedReq) (*medical.IsClaimed
 	return &medical.IsClaimedResp{
 	return &medical.IsClaimedResp{
 		ErrorCode: entity.SUCCESSCODE,
 		ErrorCode: entity.SUCCESSCODE,
 		ErrorMsg:  "",
 		ErrorMsg:  "",
-		Status:    rs,
+		Data: &medical.IsClaimedResp_StatusRes{
+			Status: rs,
+		},
 	}, nil
 	}, nil
 }
 }

+ 1 - 3
rpc/medical/internal/svc/servicecontext.go

@@ -4,7 +4,6 @@ import (
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/entity"
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/entity"
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/rpc/medical/internal/config"
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/rpc/medical/internal/config"
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/service"
 	"bp.jydev.jianyu360.cn/ApplicationCenter/medicalField/service"
-	"fmt"
 )
 )
 
 
 type ServiceContext struct {
 type ServiceContext struct {
@@ -13,9 +12,8 @@ type ServiceContext struct {
 }
 }
 
 
 func NewServiceContext(c config.Config) *ServiceContext {
 func NewServiceContext(c config.Config) *ServiceContext {
-	fmt.Println(entity.BaseMysql, entity.BaseMysql == nil)
 	return &ServiceContext{
 	return &ServiceContext{
 		Config:      c,
 		Config:      c,
-		EntClaimSrv: service.NewEntClaimSrv(&entity.Conn{Mysql: entity.Mysql, BaseMysql: entity.BaseMysql}), // 手动添加 认领相关
+		EntClaimSrv: service.NewEntClaimSrv(&entity.Conn{Mysql: entity.Mysql, BaseMysql: entity.BaseMysql, GlobalCommonData: entity.GlobalCommonData}), // 手动添加 认领相关
 	}
 	}
 }
 }

+ 7 - 8
rpc/medical/medical.proto

@@ -134,13 +134,8 @@ message PortraitResp{
 message ClaimReq{
 message ClaimReq{
   int64 UserId = 1 ;// 用户id
   int64 UserId = 1 ;// 用户id
   string EntId = 2 ;// 公司id
   string EntId = 2 ;// 公司id
-  string EntName = 3 ;// 公司名称
-  int64 Type = 4 ;// 类型;1:医疗机构 2:经销商'
-  string Address = 5 ;// 企业地址
-  string EstablishDate = 6 ;// 成立日期
-  string RegisterCapital = 7 ;// 注册资本
-  string Phone = 8 ;// 联系方式
-  string AppId = 9 ;//appid
+  int64 Type = 3 ;// 类型;1:医疗机构 2:经销商'
+  string AppId = 4 ;//appid
 }
 }
 
 
 // 取消认领
 // 取消认领
@@ -159,7 +154,11 @@ message IsClaimedReq{
 message IsClaimedResp{
 message IsClaimedResp{
   int64  ErrorCode = 1;  // 响应代码
   int64  ErrorCode = 1;  // 响应代码
   string ErrorMsg = 2;   // 响应信息
   string ErrorMsg = 2;   // 响应信息
-  bool   Status =3;// 是否认领
+  message StatusRes{
+    bool Status = 1;
+  }
+  StatusRes Data =3;
+
 }
 }
 // 我认领的
 // 我认领的
 message ClaimedReq{
 message ClaimedReq{

+ 241 - 225
rpc/medical/medical/medical.pb.go

@@ -1374,15 +1374,10 @@ type ClaimReq struct {
 	sizeCache     protoimpl.SizeCache
 	sizeCache     protoimpl.SizeCache
 	unknownFields protoimpl.UnknownFields
 	unknownFields protoimpl.UnknownFields
 
 
-	UserId          int64  `protobuf:"varint,1,opt,name=UserId,proto3" json:"UserId,omitempty"`                  // 用户id
-	EntId           string `protobuf:"bytes,2,opt,name=EntId,proto3" json:"EntId,omitempty"`                     // 公司id
-	EntName         string `protobuf:"bytes,3,opt,name=EntName,proto3" json:"EntName,omitempty"`                 // 公司名称
-	Type            int64  `protobuf:"varint,4,opt,name=Type,proto3" json:"Type,omitempty"`                      // 类型;1:医疗机构 2:经销商'
-	Address         string `protobuf:"bytes,5,opt,name=Address,proto3" json:"Address,omitempty"`                 // 企业地址
-	EstablishDate   string `protobuf:"bytes,6,opt,name=EstablishDate,proto3" json:"EstablishDate,omitempty"`     // 成立日期
-	RegisterCapital string `protobuf:"bytes,7,opt,name=RegisterCapital,proto3" json:"RegisterCapital,omitempty"` // 注册资本
-	Phone           string `protobuf:"bytes,8,opt,name=Phone,proto3" json:"Phone,omitempty"`                     // 联系方式
-	AppId           string `protobuf:"bytes,9,opt,name=AppId,proto3" json:"AppId,omitempty"`                     //appid
+	UserId int64  `protobuf:"varint,1,opt,name=UserId,proto3" json:"UserId,omitempty"` // 用户id
+	EntId  string `protobuf:"bytes,2,opt,name=EntId,proto3" json:"EntId,omitempty"`    // 公司id
+	Type   int64  `protobuf:"varint,3,opt,name=Type,proto3" json:"Type,omitempty"`     // 类型;1:医疗机构 2:经销商'
+	AppId  string `protobuf:"bytes,4,opt,name=AppId,proto3" json:"AppId,omitempty"`    //appid
 }
 }
 
 
 func (x *ClaimReq) Reset() {
 func (x *ClaimReq) Reset() {
@@ -1431,13 +1426,6 @@ func (x *ClaimReq) GetEntId() string {
 	return ""
 	return ""
 }
 }
 
 
-func (x *ClaimReq) GetEntName() string {
-	if x != nil {
-		return x.EntName
-	}
-	return ""
-}
-
 func (x *ClaimReq) GetType() int64 {
 func (x *ClaimReq) GetType() int64 {
 	if x != nil {
 	if x != nil {
 		return x.Type
 		return x.Type
@@ -1445,34 +1433,6 @@ func (x *ClaimReq) GetType() int64 {
 	return 0
 	return 0
 }
 }
 
 
-func (x *ClaimReq) GetAddress() string {
-	if x != nil {
-		return x.Address
-	}
-	return ""
-}
-
-func (x *ClaimReq) GetEstablishDate() string {
-	if x != nil {
-		return x.EstablishDate
-	}
-	return ""
-}
-
-func (x *ClaimReq) GetRegisterCapital() string {
-	if x != nil {
-		return x.RegisterCapital
-	}
-	return ""
-}
-
-func (x *ClaimReq) GetPhone() string {
-	if x != nil {
-		return x.Phone
-	}
-	return ""
-}
-
 func (x *ClaimReq) GetAppId() string {
 func (x *ClaimReq) GetAppId() string {
 	if x != nil {
 	if x != nil {
 		return x.AppId
 		return x.AppId
@@ -1621,9 +1581,9 @@ type IsClaimedResp struct {
 	sizeCache     protoimpl.SizeCache
 	sizeCache     protoimpl.SizeCache
 	unknownFields protoimpl.UnknownFields
 	unknownFields protoimpl.UnknownFields
 
 
-	ErrorCode int64  `protobuf:"varint,1,opt,name=ErrorCode,proto3" json:"ErrorCode,omitempty"` // 响应代码
-	ErrorMsg  string `protobuf:"bytes,2,opt,name=ErrorMsg,proto3" json:"ErrorMsg,omitempty"`    // 响应信息
-	Status    bool   `protobuf:"varint,3,opt,name=Status,proto3" json:"Status,omitempty"`       // 是否认领
+	ErrorCode int64                    `protobuf:"varint,1,opt,name=ErrorCode,proto3" json:"ErrorCode,omitempty"` // 响应代码
+	ErrorMsg  string                   `protobuf:"bytes,2,opt,name=ErrorMsg,proto3" json:"ErrorMsg,omitempty"`    // 响应信息
+	Data      *IsClaimedResp_StatusRes `protobuf:"bytes,3,opt,name=Data,proto3" json:"Data,omitempty"`
 }
 }
 
 
 func (x *IsClaimedResp) Reset() {
 func (x *IsClaimedResp) Reset() {
@@ -1672,11 +1632,11 @@ func (x *IsClaimedResp) GetErrorMsg() string {
 	return ""
 	return ""
 }
 }
 
 
-func (x *IsClaimedResp) GetStatus() bool {
+func (x *IsClaimedResp) GetData() *IsClaimedResp_StatusRes {
 	if x != nil {
 	if x != nil {
-		return x.Status
+		return x.Data
 	}
 	}
-	return false
+	return nil
 }
 }
 
 
 // 我认领的
 // 我认领的
@@ -2006,6 +1966,53 @@ func (x *EntClaimListResp) GetData() *EntClaimListStruct {
 	return nil
 	return nil
 }
 }
 
 
+type IsClaimedResp_StatusRes struct {
+	state         protoimpl.MessageState
+	sizeCache     protoimpl.SizeCache
+	unknownFields protoimpl.UnknownFields
+
+	Status bool `protobuf:"varint,1,opt,name=Status,proto3" json:"Status,omitempty"`
+}
+
+func (x *IsClaimedResp_StatusRes) Reset() {
+	*x = IsClaimedResp_StatusRes{}
+	if protoimpl.UnsafeEnabled {
+		mi := &file_medical_proto_msgTypes[26]
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		ms.StoreMessageInfo(mi)
+	}
+}
+
+func (x *IsClaimedResp_StatusRes) String() string {
+	return protoimpl.X.MessageStringOf(x)
+}
+
+func (*IsClaimedResp_StatusRes) ProtoMessage() {}
+
+func (x *IsClaimedResp_StatusRes) ProtoReflect() protoreflect.Message {
+	mi := &file_medical_proto_msgTypes[26]
+	if protoimpl.UnsafeEnabled && x != nil {
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		if ms.LoadMessageInfo() == nil {
+			ms.StoreMessageInfo(mi)
+		}
+		return ms
+	}
+	return mi.MessageOf(x)
+}
+
+// Deprecated: Use IsClaimedResp_StatusRes.ProtoReflect.Descriptor instead.
+func (*IsClaimedResp_StatusRes) Descriptor() ([]byte, []int) {
+	return file_medical_proto_rawDescGZIP(), []int{21, 0}
+}
+
+func (x *IsClaimedResp_StatusRes) GetStatus() bool {
+	if x != nil {
+		return x.Status
+	}
+	return false
+}
+
 var File_medical_proto protoreflect.FileDescriptor
 var File_medical_proto protoreflect.FileDescriptor
 
 
 var file_medical_proto_rawDesc = []byte{
 var file_medical_proto_rawDesc = []byte{
@@ -2174,126 +2181,121 @@ var file_medical_proto_rawDesc = []byte{
 	0x4e, 0x61, 0x6d, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6d, 0x70,
 	0x4e, 0x61, 0x6d, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6d, 0x70,
 	0x61, 0x6e, 0x79, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x25, 0x0a, 0x0e, 0x65, 0x73, 0x74, 0x61, 0x62,
 	0x61, 0x6e, 0x79, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x25, 0x0a, 0x0e, 0x65, 0x73, 0x74, 0x61, 0x62,
 	0x6c, 0x69, 0x73, 0x68, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52,
 	0x6c, 0x69, 0x73, 0x68, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52,
-	0x0d, 0x65, 0x73, 0x74, 0x61, 0x62, 0x6c, 0x69, 0x73, 0x68, 0x44, 0x61, 0x74, 0x65, 0x22, 0xfc,
-	0x01, 0x0a, 0x08, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x52, 0x65, 0x71, 0x12, 0x16, 0x0a, 0x06, 0x55,
-	0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x55, 0x73, 0x65,
-	0x72, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x45, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01,
-	0x28, 0x09, 0x52, 0x05, 0x45, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x45, 0x6e, 0x74,
-	0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x45, 0x6e, 0x74, 0x4e,
-	0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28,
-	0x03, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x41, 0x64, 0x64, 0x72, 0x65,
-	0x73, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73,
-	0x73, 0x12, 0x24, 0x0a, 0x0d, 0x45, 0x73, 0x74, 0x61, 0x62, 0x6c, 0x69, 0x73, 0x68, 0x44, 0x61,
-	0x74, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x45, 0x73, 0x74, 0x61, 0x62, 0x6c,
-	0x69, 0x73, 0x68, 0x44, 0x61, 0x74, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x52, 0x65, 0x67, 0x69, 0x73,
-	0x74, 0x65, 0x72, 0x43, 0x61, 0x70, 0x69, 0x74, 0x61, 0x6c, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09,
-	0x52, 0x0f, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x43, 0x61, 0x70, 0x69, 0x74, 0x61,
-	0x6c, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x68, 0x6f, 0x6e, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09,
-	0x52, 0x05, 0x50, 0x68, 0x6f, 0x6e, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x41, 0x70, 0x70, 0x49, 0x64,
-	0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x41, 0x70, 0x70, 0x49, 0x64, 0x22, 0x4c, 0x0a,
-	0x0c, 0x55, 0x6e, 0x63, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x52, 0x65, 0x71, 0x12, 0x16, 0x0a,
+	0x0d, 0x65, 0x73, 0x74, 0x61, 0x62, 0x6c, 0x69, 0x73, 0x68, 0x44, 0x61, 0x74, 0x65, 0x22, 0x62,
+	0x0a, 0x08, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x52, 0x65, 0x71, 0x12, 0x16, 0x0a, 0x06, 0x55, 0x73,
+	0x65, 0x72, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x55, 0x73, 0x65, 0x72,
+	0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x45, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28,
+	0x09, 0x52, 0x05, 0x45, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65,
+	0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x14, 0x0a, 0x05,
+	0x41, 0x70, 0x70, 0x49, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x41, 0x70, 0x70,
+	0x49, 0x64, 0x22, 0x4c, 0x0a, 0x0c, 0x55, 0x6e, 0x63, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x52,
+	0x65, 0x71, 0x12, 0x16, 0x0a, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01,
+	0x28, 0x03, 0x52, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x64,
+	0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x41, 0x70,
+	0x70, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x41, 0x70, 0x70, 0x49, 0x64,
+	0x22, 0x66, 0x0a, 0x0c, 0x49, 0x73, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x52, 0x65, 0x71,
+	0x12, 0x16, 0x0a, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03,
+	0x52, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x45, 0x6e, 0x74, 0x49,
+	0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x45, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x14,
+	0x0a, 0x05, 0x41, 0x70, 0x70, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x41,
+	0x70, 0x70, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01,
+	0x28, 0x03, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x22, 0xa4, 0x01, 0x0a, 0x0d, 0x49, 0x73, 0x43,
+	0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x45, 0x72,
+	0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x45,
+	0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x45, 0x72, 0x72, 0x6f,
+	0x72, 0x4d, 0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x45, 0x72, 0x72, 0x6f,
+	0x72, 0x4d, 0x73, 0x67, 0x12, 0x34, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01,
+	0x28, 0x0b, 0x32, 0x20, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x49, 0x73, 0x43,
+	0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x52, 0x65, 0x73, 0x70, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75,
+	0x73, 0x52, 0x65, 0x73, 0x52, 0x04, 0x44, 0x61, 0x74, 0x61, 0x1a, 0x23, 0x0a, 0x09, 0x53, 0x74,
+	0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x53, 0x74, 0x61, 0x74, 0x75,
+	0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x22,
+	0x6a, 0x0a, 0x0a, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x52, 0x65, 0x71, 0x12, 0x16, 0x0a,
 	0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x55,
 	0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x55,
-	0x73, 0x65, 0x72, 0x49, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28,
-	0x03, 0x52, 0x02, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x41, 0x70, 0x70, 0x49, 0x64, 0x18, 0x03,
-	0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x41, 0x70, 0x70, 0x49, 0x64, 0x22, 0x66, 0x0a, 0x0c, 0x49,
-	0x73, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x52, 0x65, 0x71, 0x12, 0x16, 0x0a, 0x06, 0x55,
-	0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x55, 0x73, 0x65,
-	0x72, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x45, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01,
-	0x28, 0x09, 0x52, 0x05, 0x45, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x41, 0x70, 0x70,
-	0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x41, 0x70, 0x70, 0x49, 0x64, 0x12,
-	0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x54,
-	0x79, 0x70, 0x65, 0x22, 0x61, 0x0a, 0x0d, 0x49, 0x73, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64,
-	0x52, 0x65, 0x73, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64,
-	0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f,
-	0x64, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x4d, 0x73, 0x67, 0x18, 0x02,
-	0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x4d, 0x73, 0x67, 0x12, 0x16,
-	0x0a, 0x06, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06,
-	0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x22, 0x6a, 0x0a, 0x0a, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x65,
-	0x64, 0x52, 0x65, 0x71, 0x12, 0x16, 0x0a, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x01,
-	0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05,
-	0x41, 0x70, 0x70, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x41, 0x70, 0x70,
-	0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03,
-	0x52, 0x04, 0x50, 0x61, 0x67, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x67, 0x65, 0x53, 0x69,
-	0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x50, 0x61, 0x67, 0x65, 0x53, 0x69,
-	0x7a, 0x65, 0x22, 0xcc, 0x02, 0x0a, 0x08, 0x45, 0x6e, 0x74, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x12,
-	0x0e, 0x0a, 0x02, 0x49, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x64, 0x12,
-	0x16, 0x0a, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52,
-	0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x45, 0x6e, 0x74, 0x49, 0x64,
-	0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x45, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x18, 0x0a,
-	0x07, 0x45, 0x6e, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07,
-	0x45, 0x6e, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18,
-	0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x41,
-	0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x41, 0x64,
-	0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x24, 0x0a, 0x0d, 0x45, 0x73, 0x74, 0x61, 0x62, 0x6c, 0x69,
-	0x73, 0x68, 0x44, 0x61, 0x74, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x45, 0x73,
-	0x74, 0x61, 0x62, 0x6c, 0x69, 0x73, 0x68, 0x44, 0x61, 0x74, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x52,
-	0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x43, 0x61, 0x70, 0x69, 0x74, 0x61, 0x6c, 0x18, 0x07,
-	0x20, 0x01, 0x28, 0x09, 0x52, 0x0f, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x43, 0x61,
-	0x70, 0x69, 0x74, 0x61, 0x6c, 0x12, 0x14, 0x0a, 0x05, 0x50, 0x68, 0x6f, 0x6e, 0x65, 0x18, 0x08,
-	0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x50, 0x68, 0x6f, 0x6e, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x41,
-	0x70, 0x70, 0x49, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x41, 0x70, 0x70, 0x49,
-	0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x18,
-	0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d,
-	0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x18,
-	0x0c, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d,
-	0x65, 0x22, 0x51, 0x0a, 0x12, 0x45, 0x6e, 0x74, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x4c, 0x69, 0x73,
-	0x74, 0x53, 0x74, 0x72, 0x75, 0x63, 0x74, 0x12, 0x25, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18,
-	0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e,
-	0x45, 0x6e, 0x74, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x14,
-	0x0a, 0x05, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x54,
-	0x6f, 0x74, 0x61, 0x6c, 0x22, 0x7d, 0x0a, 0x10, 0x45, 0x6e, 0x74, 0x43, 0x6c, 0x61, 0x69, 0x6d,
-	0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1c, 0x0a, 0x09, 0x45, 0x72, 0x72, 0x6f,
-	0x72, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x45, 0x72, 0x72,
-	0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x4d,
-	0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x4d,
-	0x73, 0x67, 0x12, 0x2f, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b,
-	0x32, 0x1b, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x45, 0x6e, 0x74, 0x43, 0x6c,
-	0x61, 0x69, 0x6d, 0x4c, 0x69, 0x73, 0x74, 0x53, 0x74, 0x72, 0x75, 0x63, 0x74, 0x52, 0x04, 0x44,
-	0x61, 0x74, 0x61, 0x32, 0xb4, 0x05, 0x0a, 0x07, 0x4d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x12,
-	0x42, 0x0a, 0x0b, 0x49, 0x6e, 0x73, 0x74, 0x69, 0x74, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1d,
-	0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x49,
-	0x6e, 0x73, 0x74, 0x69, 0x74, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x1a, 0x14, 0x2e,
-	0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x43, 0x6f, 0x6d, 0x70, 0x61, 0x6e, 0x79, 0x52,
-	0x65, 0x73, 0x70, 0x12, 0x37, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x74, 0x65, 0x72,
-	0x49, 0x74, 0x65, 0x6d, 0x12, 0x0d, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x5a,
-	0x65, 0x72, 0x6f, 0x1a, 0x17, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x46, 0x69,
-	0x6c, 0x74, 0x65, 0x72, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x73, 0x70, 0x12, 0x42, 0x0a, 0x0b,
-	0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x6f, 0x72, 0x12, 0x1d, 0x2e, 0x6d, 0x65,
-	0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x44, 0x69, 0x73, 0x74,
-	0x72, 0x69, 0x62, 0x75, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, 0x1a, 0x14, 0x2e, 0x6d, 0x65, 0x64,
-	0x69, 0x63, 0x61, 0x6c, 0x2e, 0x43, 0x6f, 0x6d, 0x70, 0x61, 0x6e, 0x79, 0x52, 0x65, 0x73, 0x70,
-	0x12, 0x3a, 0x0a, 0x10, 0x75, 0x73, 0x65, 0x72, 0x41, 0x75, 0x74, 0x68, 0x49, 0x6e, 0x66, 0x6f,
-	0x53, 0x61, 0x76, 0x65, 0x12, 0x11, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x55,
-	0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x1a, 0x13, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61,
-	0x6c, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x12, 0x39, 0x0a, 0x0c,
-	0x75, 0x73, 0x65, 0x72, 0x41, 0x75, 0x74, 0x68, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x12, 0x2e, 0x6d,
-	0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x52, 0x65, 0x71,
-	0x1a, 0x15, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x49,
-	0x6e, 0x66, 0x6f, 0x52, 0x65, 0x73, 0x70, 0x12, 0x37, 0x0a, 0x08, 0x50, 0x6f, 0x72, 0x74, 0x72,
-	0x61, 0x69, 0x74, 0x12, 0x14, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x50, 0x6f,
-	0x72, 0x74, 0x72, 0x61, 0x69, 0x74, 0x52, 0x65, 0x71, 0x1a, 0x15, 0x2e, 0x6d, 0x65, 0x64, 0x69,
-	0x63, 0x61, 0x6c, 0x2e, 0x50, 0x6f, 0x72, 0x74, 0x72, 0x61, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70,
-	0x12, 0x2f, 0x0a, 0x05, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x12, 0x11, 0x2e, 0x6d, 0x65, 0x64, 0x69,
-	0x63, 0x61, 0x6c, 0x2e, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x52, 0x65, 0x71, 0x1a, 0x13, 0x2e, 0x6d,
-	0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x52, 0x65, 0x73,
-	0x70, 0x12, 0x37, 0x0a, 0x09, 0x55, 0x6e, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x12, 0x15,
-	0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x55, 0x6e, 0x63, 0x6c, 0x61, 0x69, 0x6d,
-	0x65, 0x64, 0x52, 0x65, 0x71, 0x1a, 0x13, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e,
-	0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x12, 0x3a, 0x0a, 0x09, 0x49, 0x73,
+	0x73, 0x65, 0x72, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x41, 0x70, 0x70, 0x49, 0x64, 0x18, 0x02,
+	0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x41, 0x70, 0x70, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x50,
+	0x61, 0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x50, 0x61, 0x67, 0x65, 0x12,
+	0x1a, 0x0a, 0x08, 0x50, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28,
+	0x03, 0x52, 0x08, 0x50, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x22, 0xcc, 0x02, 0x0a, 0x08,
+	0x45, 0x6e, 0x74, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x64, 0x18, 0x0a,
+	0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x55, 0x73, 0x65, 0x72,
+	0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64,
+	0x12, 0x14, 0x0a, 0x05, 0x45, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52,
+	0x05, 0x45, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x45, 0x6e, 0x74, 0x4e, 0x61, 0x6d,
+	0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x45, 0x6e, 0x74, 0x4e, 0x61, 0x6d, 0x65,
+	0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04,
+	0x54, 0x79, 0x70, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18,
+	0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x24,
+	0x0a, 0x0d, 0x45, 0x73, 0x74, 0x61, 0x62, 0x6c, 0x69, 0x73, 0x68, 0x44, 0x61, 0x74, 0x65, 0x18,
+	0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x45, 0x73, 0x74, 0x61, 0x62, 0x6c, 0x69, 0x73, 0x68,
+	0x44, 0x61, 0x74, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72,
+	0x43, 0x61, 0x70, 0x69, 0x74, 0x61, 0x6c, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0f, 0x52,
+	0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x43, 0x61, 0x70, 0x69, 0x74, 0x61, 0x6c, 0x12, 0x14,
+	0x0a, 0x05, 0x50, 0x68, 0x6f, 0x6e, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x50,
+	0x68, 0x6f, 0x6e, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x41, 0x70, 0x70, 0x49, 0x64, 0x18, 0x09, 0x20,
+	0x01, 0x28, 0x09, 0x52, 0x05, 0x41, 0x70, 0x70, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x72,
+	0x65, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a,
+	0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x55, 0x70,
+	0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a,
+	0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x22, 0x51, 0x0a, 0x12, 0x45, 0x6e,
+	0x74, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x4c, 0x69, 0x73, 0x74, 0x53, 0x74, 0x72, 0x75, 0x63, 0x74,
+	0x12, 0x25, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x11,
+	0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x45, 0x6e, 0x74, 0x43, 0x6c, 0x61, 0x69,
+	0x6d, 0x52, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x6f, 0x74, 0x61, 0x6c,
+	0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x22, 0x7d, 0x0a,
+	0x10, 0x45, 0x6e, 0x74, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73,
+	0x70, 0x12, 0x1c, 0x0a, 0x09, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01,
+	0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12,
+	0x1a, 0x0a, 0x08, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x4d, 0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28,
+	0x09, 0x52, 0x08, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x4d, 0x73, 0x67, 0x12, 0x2f, 0x0a, 0x04, 0x44,
+	0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x6d, 0x65, 0x64, 0x69,
+	0x63, 0x61, 0x6c, 0x2e, 0x45, 0x6e, 0x74, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x4c, 0x69, 0x73, 0x74,
+	0x53, 0x74, 0x72, 0x75, 0x63, 0x74, 0x52, 0x04, 0x44, 0x61, 0x74, 0x61, 0x32, 0xb4, 0x05, 0x0a,
+	0x07, 0x4d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x12, 0x42, 0x0a, 0x0b, 0x49, 0x6e, 0x73, 0x74,
+	0x69, 0x74, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1d, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61,
+	0x6c, 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x49, 0x6e, 0x73, 0x74, 0x69, 0x74, 0x75, 0x74,
+	0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x1a, 0x14, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c,
+	0x2e, 0x43, 0x6f, 0x6d, 0x70, 0x61, 0x6e, 0x79, 0x52, 0x65, 0x73, 0x70, 0x12, 0x37, 0x0a, 0x0d,
+	0x47, 0x65, 0x74, 0x46, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x0d, 0x2e,
+	0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x5a, 0x65, 0x72, 0x6f, 0x1a, 0x17, 0x2e, 0x6d,
+	0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x46, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x49, 0x74, 0x65,
+	0x6d, 0x52, 0x65, 0x73, 0x70, 0x12, 0x42, 0x0a, 0x0b, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62,
+	0x75, 0x74, 0x6f, 0x72, 0x12, 0x1d, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x53,
+	0x65, 0x61, 0x72, 0x63, 0x68, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x6f, 0x72,
+	0x52, 0x65, 0x71, 0x1a, 0x14, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x43, 0x6f,
+	0x6d, 0x70, 0x61, 0x6e, 0x79, 0x52, 0x65, 0x73, 0x70, 0x12, 0x3a, 0x0a, 0x10, 0x75, 0x73, 0x65,
+	0x72, 0x41, 0x75, 0x74, 0x68, 0x49, 0x6e, 0x66, 0x6f, 0x53, 0x61, 0x76, 0x65, 0x12, 0x11, 0x2e,
+	0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f,
+	0x1a, 0x13, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x6f,
+	0x6e, 0x52, 0x65, 0x73, 0x70, 0x12, 0x39, 0x0a, 0x0c, 0x75, 0x73, 0x65, 0x72, 0x41, 0x75, 0x74,
+	0x68, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x12, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e,
+	0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x1a, 0x15, 0x2e, 0x6d, 0x65, 0x64, 0x69,
+	0x63, 0x61, 0x6c, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x73, 0x70,
+	0x12, 0x37, 0x0a, 0x08, 0x50, 0x6f, 0x72, 0x74, 0x72, 0x61, 0x69, 0x74, 0x12, 0x14, 0x2e, 0x6d,
+	0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x50, 0x6f, 0x72, 0x74, 0x72, 0x61, 0x69, 0x74, 0x52,
+	0x65, 0x71, 0x1a, 0x15, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x50, 0x6f, 0x72,
+	0x74, 0x72, 0x61, 0x69, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x2f, 0x0a, 0x05, 0x43, 0x6c, 0x61,
+	0x69, 0x6d, 0x12, 0x11, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x43, 0x6c, 0x61,
+	0x69, 0x6d, 0x52, 0x65, 0x71, 0x1a, 0x13, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e,
+	0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x12, 0x37, 0x0a, 0x09, 0x55, 0x6e,
 	0x43, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x12, 0x15, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61,
 	0x43, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x12, 0x15, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61,
-	0x6c, 0x2e, 0x49, 0x73, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x52, 0x65, 0x71, 0x1a, 0x16,
-	0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x49, 0x73, 0x43, 0x6c, 0x61, 0x69, 0x6d,
-	0x65, 0x64, 0x52, 0x65, 0x73, 0x70, 0x12, 0x48, 0x0a, 0x16, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x65,
-	0x64, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x6f, 0x72, 0x4c, 0x69, 0x73, 0x74,
-	0x12, 0x13, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x43, 0x6c, 0x61, 0x69, 0x6d,
-	0x65, 0x64, 0x52, 0x65, 0x71, 0x1a, 0x19, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e,
-	0x45, 0x6e, 0x74, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70,
-	0x12, 0x48, 0x0a, 0x16, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x49, 0x6e, 0x73, 0x74, 0x69,
-	0x74, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x13, 0x2e, 0x6d, 0x65, 0x64,
-	0x69, 0x63, 0x61, 0x6c, 0x2e, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x52, 0x65, 0x71, 0x1a,
-	0x19, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x45, 0x6e, 0x74, 0x43, 0x6c, 0x61,
-	0x69, 0x6d, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x42, 0x0b, 0x5a, 0x09, 0x2e, 0x2f,
-	0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
+	0x6c, 0x2e, 0x55, 0x6e, 0x63, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x52, 0x65, 0x71, 0x1a, 0x13,
+	0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x52,
+	0x65, 0x73, 0x70, 0x12, 0x3a, 0x0a, 0x09, 0x49, 0x73, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64,
+	0x12, 0x15, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x49, 0x73, 0x43, 0x6c, 0x61,
+	0x69, 0x6d, 0x65, 0x64, 0x52, 0x65, 0x71, 0x1a, 0x16, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61,
+	0x6c, 0x2e, 0x49, 0x73, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x52, 0x65, 0x73, 0x70, 0x12,
+	0x48, 0x0a, 0x16, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69,
+	0x62, 0x75, 0x74, 0x6f, 0x72, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x13, 0x2e, 0x6d, 0x65, 0x64, 0x69,
+	0x63, 0x61, 0x6c, 0x2e, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x65, 0x64, 0x52, 0x65, 0x71, 0x1a, 0x19,
+	0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x45, 0x6e, 0x74, 0x43, 0x6c, 0x61, 0x69,
+	0x6d, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x48, 0x0a, 0x16, 0x43, 0x6c, 0x61,
+	0x69, 0x6d, 0x65, 0x64, 0x49, 0x6e, 0x73, 0x74, 0x69, 0x74, 0x75, 0x74, 0x69, 0x6f, 0x6e, 0x4c,
+	0x69, 0x73, 0x74, 0x12, 0x13, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c, 0x2e, 0x43, 0x6c,
+	0x61, 0x69, 0x6d, 0x65, 0x64, 0x52, 0x65, 0x71, 0x1a, 0x19, 0x2e, 0x6d, 0x65, 0x64, 0x69, 0x63,
+	0x61, 0x6c, 0x2e, 0x45, 0x6e, 0x74, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x4c, 0x69, 0x73, 0x74, 0x52,
+	0x65, 0x73, 0x70, 0x42, 0x0b, 0x5a, 0x09, 0x2e, 0x2f, 0x6d, 0x65, 0x64, 0x69, 0x63, 0x61, 0x6c,
+	0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
 }
 }
 
 
 var (
 var (
@@ -2308,34 +2310,35 @@ func file_medical_proto_rawDescGZIP() []byte {
 	return file_medical_proto_rawDescData
 	return file_medical_proto_rawDescData
 }
 }
 
 
-var file_medical_proto_msgTypes = make([]protoimpl.MessageInfo, 26)
+var file_medical_proto_msgTypes = make([]protoimpl.MessageInfo, 27)
 var file_medical_proto_goTypes = []interface{}{
 var file_medical_proto_goTypes = []interface{}{
-	(*Request)(nil),              // 0: medical.Request
-	(*Response)(nil),             // 1: medical.Response
-	(*CommonResp)(nil),           // 2: medical.CommonResp
-	(*CommonReq)(nil),            // 3: medical.CommonReq
-	(*Zero)(nil),                 // 4: medical.Zero
-	(*SearchInstitutionReq)(nil), // 5: medical.SearchInstitutionReq
-	(*SearchDistributorReq)(nil), // 6: medical.SearchDistributorReq
-	(*CompanyData)(nil),          // 7: medical.CompanyData
-	(*CompanyDataList)(nil),      // 8: medical.CompanyDataList
-	(*CompanyResp)(nil),          // 9: medical.CompanyResp
-	(*LevelCode)(nil),            // 10: medical.LevelCode
-	(*MiTypeCode)(nil),           // 11: medical.MiTypeCode
-	(*FilterItem)(nil),           // 12: medical.FilterItem
-	(*FilterItemResp)(nil),       // 13: medical.FilterItemResp
-	(*UserInfo)(nil),             // 14: medical.UserInfo
-	(*UserInfoResp)(nil),         // 15: medical.UserInfoResp
-	(*PortraitReq)(nil),          // 16: medical.PortraitReq
-	(*PortraitResp)(nil),         // 17: medical.PortraitResp
-	(*ClaimReq)(nil),             // 18: medical.ClaimReq
-	(*UnclaimedReq)(nil),         // 19: medical.UnclaimedReq
-	(*IsClaimedReq)(nil),         // 20: medical.IsClaimedReq
-	(*IsClaimedResp)(nil),        // 21: medical.IsClaimedResp
-	(*ClaimedReq)(nil),           // 22: medical.ClaimedReq
-	(*EntClaim)(nil),             // 23: medical.EntClaim
-	(*EntClaimListStruct)(nil),   // 24: medical.EntClaimListStruct
-	(*EntClaimListResp)(nil),     // 25: medical.EntClaimListResp
+	(*Request)(nil),                 // 0: medical.Request
+	(*Response)(nil),                // 1: medical.Response
+	(*CommonResp)(nil),              // 2: medical.CommonResp
+	(*CommonReq)(nil),               // 3: medical.CommonReq
+	(*Zero)(nil),                    // 4: medical.Zero
+	(*SearchInstitutionReq)(nil),    // 5: medical.SearchInstitutionReq
+	(*SearchDistributorReq)(nil),    // 6: medical.SearchDistributorReq
+	(*CompanyData)(nil),             // 7: medical.CompanyData
+	(*CompanyDataList)(nil),         // 8: medical.CompanyDataList
+	(*CompanyResp)(nil),             // 9: medical.CompanyResp
+	(*LevelCode)(nil),               // 10: medical.LevelCode
+	(*MiTypeCode)(nil),              // 11: medical.MiTypeCode
+	(*FilterItem)(nil),              // 12: medical.FilterItem
+	(*FilterItemResp)(nil),          // 13: medical.FilterItemResp
+	(*UserInfo)(nil),                // 14: medical.UserInfo
+	(*UserInfoResp)(nil),            // 15: medical.UserInfoResp
+	(*PortraitReq)(nil),             // 16: medical.PortraitReq
+	(*PortraitResp)(nil),            // 17: medical.PortraitResp
+	(*ClaimReq)(nil),                // 18: medical.ClaimReq
+	(*UnclaimedReq)(nil),            // 19: medical.UnclaimedReq
+	(*IsClaimedReq)(nil),            // 20: medical.IsClaimedReq
+	(*IsClaimedResp)(nil),           // 21: medical.IsClaimedResp
+	(*ClaimedReq)(nil),              // 22: medical.ClaimedReq
+	(*EntClaim)(nil),                // 23: medical.EntClaim
+	(*EntClaimListStruct)(nil),      // 24: medical.EntClaimListStruct
+	(*EntClaimListResp)(nil),        // 25: medical.EntClaimListResp
+	(*IsClaimedResp_StatusRes)(nil), // 26: medical.IsClaimedResp.StatusRes
 }
 }
 var file_medical_proto_depIdxs = []int32{
 var file_medical_proto_depIdxs = []int32{
 	7,  // 0: medical.CompanyDataList.list:type_name -> medical.CompanyData
 	7,  // 0: medical.CompanyDataList.list:type_name -> medical.CompanyData
@@ -2344,35 +2347,36 @@ var file_medical_proto_depIdxs = []int32{
 	11, // 3: medical.FilterItem.mi_type_code:type_name -> medical.MiTypeCode
 	11, // 3: medical.FilterItem.mi_type_code:type_name -> medical.MiTypeCode
 	12, // 4: medical.FilterItemResp.data:type_name -> medical.FilterItem
 	12, // 4: medical.FilterItemResp.data:type_name -> medical.FilterItem
 	14, // 5: medical.UserInfoResp.data:type_name -> medical.UserInfo
 	14, // 5: medical.UserInfoResp.data:type_name -> medical.UserInfo
-	23, // 6: medical.EntClaimListStruct.List:type_name -> medical.EntClaim
-	24, // 7: medical.EntClaimListResp.Data:type_name -> medical.EntClaimListStruct
-	5,  // 8: medical.Medical.Institution:input_type -> medical.SearchInstitutionReq
-	4,  // 9: medical.Medical.GetFilterItem:input_type -> medical.Zero
-	6,  // 10: medical.Medical.Distributor:input_type -> medical.SearchDistributorReq
-	14, // 11: medical.Medical.userAuthInfoSave:input_type -> medical.UserInfo
-	3,  // 12: medical.Medical.userAuthInfo:input_type -> medical.CommonReq
-	16, // 13: medical.Medical.Portrait:input_type -> medical.PortraitReq
-	18, // 14: medical.Medical.Claim:input_type -> medical.ClaimReq
-	19, // 15: medical.Medical.UnClaimed:input_type -> medical.UnclaimedReq
-	20, // 16: medical.Medical.IsClaimed:input_type -> medical.IsClaimedReq
-	22, // 17: medical.Medical.ClaimedDistributorList:input_type -> medical.ClaimedReq
-	22, // 18: medical.Medical.ClaimedInstitutionList:input_type -> medical.ClaimedReq
-	9,  // 19: medical.Medical.Institution:output_type -> medical.CompanyResp
-	13, // 20: medical.Medical.GetFilterItem:output_type -> medical.FilterItemResp
-	9,  // 21: medical.Medical.Distributor:output_type -> medical.CompanyResp
-	2,  // 22: medical.Medical.userAuthInfoSave:output_type -> medical.CommonResp
-	15, // 23: medical.Medical.userAuthInfo:output_type -> medical.UserInfoResp
-	17, // 24: medical.Medical.Portrait:output_type -> medical.PortraitResp
-	2,  // 25: medical.Medical.Claim:output_type -> medical.CommonResp
-	2,  // 26: medical.Medical.UnClaimed:output_type -> medical.CommonResp
-	21, // 27: medical.Medical.IsClaimed:output_type -> medical.IsClaimedResp
-	25, // 28: medical.Medical.ClaimedDistributorList:output_type -> medical.EntClaimListResp
-	25, // 29: medical.Medical.ClaimedInstitutionList:output_type -> medical.EntClaimListResp
-	19, // [19:30] is the sub-list for method output_type
-	8,  // [8:19] is the sub-list for method input_type
-	8,  // [8:8] is the sub-list for extension type_name
-	8,  // [8:8] is the sub-list for extension extendee
-	0,  // [0:8] is the sub-list for field type_name
+	26, // 6: medical.IsClaimedResp.Data:type_name -> medical.IsClaimedResp.StatusRes
+	23, // 7: medical.EntClaimListStruct.List:type_name -> medical.EntClaim
+	24, // 8: medical.EntClaimListResp.Data:type_name -> medical.EntClaimListStruct
+	5,  // 9: medical.Medical.Institution:input_type -> medical.SearchInstitutionReq
+	4,  // 10: medical.Medical.GetFilterItem:input_type -> medical.Zero
+	6,  // 11: medical.Medical.Distributor:input_type -> medical.SearchDistributorReq
+	14, // 12: medical.Medical.userAuthInfoSave:input_type -> medical.UserInfo
+	3,  // 13: medical.Medical.userAuthInfo:input_type -> medical.CommonReq
+	16, // 14: medical.Medical.Portrait:input_type -> medical.PortraitReq
+	18, // 15: medical.Medical.Claim:input_type -> medical.ClaimReq
+	19, // 16: medical.Medical.UnClaimed:input_type -> medical.UnclaimedReq
+	20, // 17: medical.Medical.IsClaimed:input_type -> medical.IsClaimedReq
+	22, // 18: medical.Medical.ClaimedDistributorList:input_type -> medical.ClaimedReq
+	22, // 19: medical.Medical.ClaimedInstitutionList:input_type -> medical.ClaimedReq
+	9,  // 20: medical.Medical.Institution:output_type -> medical.CompanyResp
+	13, // 21: medical.Medical.GetFilterItem:output_type -> medical.FilterItemResp
+	9,  // 22: medical.Medical.Distributor:output_type -> medical.CompanyResp
+	2,  // 23: medical.Medical.userAuthInfoSave:output_type -> medical.CommonResp
+	15, // 24: medical.Medical.userAuthInfo:output_type -> medical.UserInfoResp
+	17, // 25: medical.Medical.Portrait:output_type -> medical.PortraitResp
+	2,  // 26: medical.Medical.Claim:output_type -> medical.CommonResp
+	2,  // 27: medical.Medical.UnClaimed:output_type -> medical.CommonResp
+	21, // 28: medical.Medical.IsClaimed:output_type -> medical.IsClaimedResp
+	25, // 29: medical.Medical.ClaimedDistributorList:output_type -> medical.EntClaimListResp
+	25, // 30: medical.Medical.ClaimedInstitutionList:output_type -> medical.EntClaimListResp
+	20, // [20:31] is the sub-list for method output_type
+	9,  // [9:20] is the sub-list for method input_type
+	9,  // [9:9] is the sub-list for extension type_name
+	9,  // [9:9] is the sub-list for extension extendee
+	0,  // [0:9] is the sub-list for field type_name
 }
 }
 
 
 func init() { file_medical_proto_init() }
 func init() { file_medical_proto_init() }
@@ -2693,6 +2697,18 @@ func file_medical_proto_init() {
 				return nil
 				return nil
 			}
 			}
 		}
 		}
+		file_medical_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} {
+			switch v := v.(*IsClaimedResp_StatusRes); i {
+			case 0:
+				return &v.state
+			case 1:
+				return &v.sizeCache
+			case 2:
+				return &v.unknownFields
+			default:
+				return nil
+			}
+		}
 	}
 	}
 	type x struct{}
 	type x struct{}
 	out := protoimpl.TypeBuilder{
 	out := protoimpl.TypeBuilder{
@@ -2700,7 +2716,7 @@ func file_medical_proto_init() {
 			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
 			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
 			RawDescriptor: file_medical_proto_rawDesc,
 			RawDescriptor: file_medical_proto_rawDesc,
 			NumEnums:      0,
 			NumEnums:      0,
-			NumMessages:   26,
+			NumMessages:   27,
 			NumExtensions: 0,
 			NumExtensions: 0,
 			NumServices:   1,
 			NumServices:   1,
 		},
 		},

+ 9 - 0
service/claim.go

@@ -97,3 +97,12 @@ func (e *EntClaimService) InstitutionList(userId int, appId string, page int, pa
 	}
 	}
 	return e.BaseMysql.Find(entity.TableDomainEntClaim, query, field, order, (page-1)*pageSize, pageSize), int(total)
 	return e.BaseMysql.Find(entity.TableDomainEntClaim, query, field, order, (page-1)*pageSize, pageSize), int(total)
 }
 }
+
+// GetInstitution 获取机构信息
+func (e EntClaimService) GetInstitution(id string) *map[string]interface{} {
+	query := map[string]interface{}{
+		"company_id": id,
+	}
+	field := "company_name,establish_date,company_address,capital,company_phone"
+	return e.GlobalCommonData.FindOne(entity.TableCompanyBasInfo, query, field, "")
+}

+ 23 - 0
service/claim_test.go

@@ -147,3 +147,26 @@ func TestEntClaimService_Unclaimed(t *testing.T) {
 		})
 		})
 	}
 	}
 }
 }
+
+// 获取企业基本信息
+func TestEntClaimService_GetInstitution(t *testing.T) {
+	type args struct {
+		id string
+	}
+	tests := []struct {
+		name string
+		args args
+		want *map[string]interface{}
+	}{
+		{
+			"获取企业基本信息", args{id: ""}, nil,
+		},
+	}
+	for _, tt := range tests {
+		t.Run(tt.name, func(t *testing.T) {
+			got := EntClaimSrv.GetInstitution(tt.args.id)
+			t.Log(got)
+
+		})
+	}
+}

+ 2 - 7
test/rpc_test.http

@@ -24,13 +24,8 @@ GRPC {{host}}:8080/medical.Medical/Claim
 {
 {
   "AppId": "10000",
   "AppId": "10000",
   "UserId": 1,
   "UserId": 1,
-  "EntId": "2022",
-  "EntName": "剑鱼",
-  "Type": 1,
-  "Address": "郑州",
-  "EstablishDate": "2022-08-22 14:28:00",
-  "Phone": "18238182402",
-  "RegisterCapital": "高新区"
+  "EntId": "30d041422855fda867a356b3994a67ea",
+  "Type": 1
 }
 }
 ### 取消认领
 ### 取消认领
 GRPC {{host}}:8080/medical.Medical/UnClaimed
 GRPC {{host}}:8080/medical.Medical/UnClaimed