Browse Source

客成修改线索名称移交客成

renjiaojiao 6 ngày trước cách đây
mục cha
commit
86ff6bf375

+ 8 - 3
rpc/biService.proto

@@ -297,9 +297,13 @@ message ClueTransferReq {
   int64 mainClueId = 5; //原所在企业/个人主账号
 }
 
-message UpdateClueName {
-  int64 clueId = 1;
-//  string
+message UpdateCompanyNameReq {
+  int64 mainClueId = 1;
+  string NewCompanyName = 2;
+  int64 NewEntId = 3;
+  int64 cusId = 4;
+  string OldCompanyName = 5;
+  int64 OldEntId = 6;
 }
 
 service BiService {
@@ -330,4 +334,5 @@ service BiService {
   rpc getClueInfoList(ClueInfoReq) returns(BiReply);
   rpc MaterialSave(MaterialSaveReq) returns(MaterialSaveResp);//物料分发保存
   rpc clueTransfer(ClueTransferReq) returns(BiResp);
+  rpc updateCompanyName(UpdateCompanyNameReq) returns(BiResp);
 }

+ 7 - 1
rpc/biservice/biservice.go

@@ -55,7 +55,7 @@ type (
 	SqlManageReq           = pb.SqlManageReq
 	TransferClueReq        = pb.TransferClueReq
 	UpFileReq              = pb.UpFileReq
-	UpdateClueName         = pb.UpdateClueName
+	UpdateCompanyNameReq   = pb.UpdateCompanyNameReq
 
 	BiService interface {
 		MyDataAsset(ctx context.Context, in *MyDataAssetReq, opts ...grpc.CallOption) (*MyDataAssetResp, error)
@@ -85,6 +85,7 @@ type (
 		GetClueInfoList(ctx context.Context, in *ClueInfoReq, opts ...grpc.CallOption) (*BiReply, error)
 		MaterialSave(ctx context.Context, in *MaterialSaveReq, opts ...grpc.CallOption) (*MaterialSaveResp, error)
 		ClueTransfer(ctx context.Context, in *ClueTransferReq, opts ...grpc.CallOption) (*BiResp, error)
+		UpdateCompanyName(ctx context.Context, in *UpdateCompanyNameReq, opts ...grpc.CallOption) (*BiResp, error)
 	}
 
 	defaultBiService struct {
@@ -232,3 +233,8 @@ func (m *defaultBiService) ClueTransfer(ctx context.Context, in *ClueTransferReq
 	client := pb.NewBiServiceClient(m.cli.Conn())
 	return client.ClueTransfer(ctx, in, opts...)
 }
+
+func (m *defaultBiService) UpdateCompanyName(ctx context.Context, in *UpdateCompanyNameReq, opts ...grpc.CallOption) (*BiResp, error) {
+	client := pb.NewBiServiceClient(m.cli.Conn())
+	return client.UpdateCompanyName(ctx, in, opts...)
+}

+ 5 - 0
rpc/internal/server/biserviceserver.go

@@ -156,3 +156,8 @@ func (s *BiServiceServer) ClueTransfer(ctx context.Context, in *pb.ClueTransferR
 	l := logic.NewClueTransferLogic(ctx, s.svcCtx)
 	return l.ClueTransfer(in)
 }
+
+func (s *BiServiceServer) UpdateCompanyName(ctx context.Context, in *pb.UpdateCompanyNameReq) (*pb.BiResp, error) {
+	l := logic.NewUpdateCompanyNameLogic(ctx, s.svcCtx)
+	return l.UpdateCompanyName(in)
+}

+ 178 - 122
rpc/pb/biService.pb.go

@@ -3074,16 +3074,21 @@ func (x *ClueTransferReq) GetMainClueId() int64 {
 	return 0
 }
 
-type UpdateClueName struct {
+type UpdateCompanyNameReq struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
 	unknownFields protoimpl.UnknownFields
 
-	ClueId int64 `protobuf:"varint,1,opt,name=clueId,proto3" json:"clueId,omitempty"` //  string
+	MainClueId     int64  `protobuf:"varint,1,opt,name=mainClueId,proto3" json:"mainClueId,omitempty"`
+	NewCompanyName string `protobuf:"bytes,2,opt,name=NewCompanyName,proto3" json:"NewCompanyName,omitempty"`
+	NewEntId       int64  `protobuf:"varint,3,opt,name=NewEntId,proto3" json:"NewEntId,omitempty"`
+	CusId          int64  `protobuf:"varint,4,opt,name=cusId,proto3" json:"cusId,omitempty"`
+	OldCompanyName string `protobuf:"bytes,5,opt,name=OldCompanyName,proto3" json:"OldCompanyName,omitempty"`
+	OldEntId       int64  `protobuf:"varint,6,opt,name=OldEntId,proto3" json:"OldEntId,omitempty"`
 }
 
-func (x *UpdateClueName) Reset() {
-	*x = UpdateClueName{}
+func (x *UpdateCompanyNameReq) Reset() {
+	*x = UpdateCompanyNameReq{}
 	if protoimpl.UnsafeEnabled {
 		mi := &file_biService_proto_msgTypes[42]
 		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
@@ -3091,13 +3096,13 @@ func (x *UpdateClueName) Reset() {
 	}
 }
 
-func (x *UpdateClueName) String() string {
+func (x *UpdateCompanyNameReq) String() string {
 	return protoimpl.X.MessageStringOf(x)
 }
 
-func (*UpdateClueName) ProtoMessage() {}
+func (*UpdateCompanyNameReq) ProtoMessage() {}
 
-func (x *UpdateClueName) ProtoReflect() protoreflect.Message {
+func (x *UpdateCompanyNameReq) ProtoReflect() protoreflect.Message {
 	mi := &file_biService_proto_msgTypes[42]
 	if protoimpl.UnsafeEnabled && x != nil {
 		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
@@ -3109,14 +3114,49 @@ func (x *UpdateClueName) ProtoReflect() protoreflect.Message {
 	return mi.MessageOf(x)
 }
 
-// Deprecated: Use UpdateClueName.ProtoReflect.Descriptor instead.
-func (*UpdateClueName) Descriptor() ([]byte, []int) {
+// Deprecated: Use UpdateCompanyNameReq.ProtoReflect.Descriptor instead.
+func (*UpdateCompanyNameReq) Descriptor() ([]byte, []int) {
 	return file_biService_proto_rawDescGZIP(), []int{42}
 }
 
-func (x *UpdateClueName) GetClueId() int64 {
+func (x *UpdateCompanyNameReq) GetMainClueId() int64 {
 	if x != nil {
-		return x.ClueId
+		return x.MainClueId
+	}
+	return 0
+}
+
+func (x *UpdateCompanyNameReq) GetNewCompanyName() string {
+	if x != nil {
+		return x.NewCompanyName
+	}
+	return ""
+}
+
+func (x *UpdateCompanyNameReq) GetNewEntId() int64 {
+	if x != nil {
+		return x.NewEntId
+	}
+	return 0
+}
+
+func (x *UpdateCompanyNameReq) GetCusId() int64 {
+	if x != nil {
+		return x.CusId
+	}
+	return 0
+}
+
+func (x *UpdateCompanyNameReq) GetOldCompanyName() string {
+	if x != nil {
+		return x.OldCompanyName
+	}
+	return ""
+}
+
+func (x *UpdateCompanyNameReq) GetOldEntId() int64 {
+	if x != nil {
+		return x.OldEntId
 	}
 	return 0
 }
@@ -3494,86 +3534,100 @@ var file_biService_proto_rawDesc = []byte{
 	0x70, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x6b, 0x63, 0x54, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01,
 	0x28, 0x03, 0x52, 0x06, 0x6b, 0x63, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x6d, 0x61,
 	0x69, 0x6e, 0x43, 0x6c, 0x75, 0x65, 0x49, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a,
-	0x6d, 0x61, 0x69, 0x6e, 0x43, 0x6c, 0x75, 0x65, 0x49, 0x64, 0x22, 0x28, 0x0a, 0x0e, 0x55, 0x70,
-	0x64, 0x61, 0x74, 0x65, 0x43, 0x6c, 0x75, 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x16, 0x0a, 0x06,
-	0x63, 0x6c, 0x75, 0x65, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x63, 0x6c,
-	0x75, 0x65, 0x49, 0x64, 0x32, 0xb4, 0x09, 0x0a, 0x09, 0x42, 0x69, 0x53, 0x65, 0x72, 0x76, 0x69,
-	0x63, 0x65, 0x12, 0x30, 0x0a, 0x0b, 0x6d, 0x79, 0x44, 0x61, 0x74, 0x61, 0x41, 0x73, 0x73, 0x65,
-	0x74, 0x12, 0x0f, 0x2e, 0x4d, 0x79, 0x44, 0x61, 0x74, 0x61, 0x41, 0x73, 0x73, 0x65, 0x74, 0x52,
-	0x65, 0x71, 0x1a, 0x10, 0x2e, 0x4d, 0x79, 0x44, 0x61, 0x74, 0x61, 0x41, 0x73, 0x73, 0x65, 0x74,
-	0x52, 0x65, 0x73, 0x70, 0x12, 0x2d, 0x0a, 0x0a, 0x61, 0x64, 0x64, 0x50, 0x72, 0x6f, 0x6a, 0x65,
-	0x63, 0x74, 0x12, 0x0e, 0x2e, 0x41, 0x64, 0x64, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52,
-	0x65, 0x71, 0x1a, 0x0f, 0x2e, 0x41, 0x64, 0x64, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52,
-	0x65, 0x73, 0x70, 0x12, 0x2b, 0x0a, 0x09, 0x67, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x49, 0x64,
-	0x12, 0x0e, 0x2e, 0x41, 0x64, 0x64, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71,
-	0x1a, 0x0e, 0x2e, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x49, 0x64, 0x52, 0x65, 0x73, 0x70,
-	0x12, 0x29, 0x0a, 0x08, 0x64, 0x72, 0x61, 0x77, 0x43, 0x6c, 0x75, 0x65, 0x12, 0x0c, 0x2e, 0x44,
-	0x72, 0x61, 0x77, 0x43, 0x6c, 0x75, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x0f, 0x2e, 0x41, 0x64, 0x64,
-	0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x19, 0x0a, 0x04, 0x43,
-	0x61, 0x6c, 0x6c, 0x12, 0x08, 0x2e, 0x43, 0x61, 0x6c, 0x6c, 0x52, 0x65, 0x71, 0x1a, 0x07, 0x2e,
-	0x42, 0x69, 0x52, 0x65, 0x73, 0x70, 0x12, 0x35, 0x0a, 0x0e, 0x64, 0x69, 0x73, 0x74, 0x72, 0x69,
-	0x62, 0x75, 0x74, 0x65, 0x43, 0x6c, 0x75, 0x65, 0x12, 0x12, 0x2e, 0x44, 0x69, 0x73, 0x74, 0x72,
-	0x69, 0x62, 0x75, 0x74, 0x65, 0x43, 0x6c, 0x75, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x0f, 0x2e, 0x41,
-	0x64, 0x64, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x2d, 0x0a,
-	0x0a, 0x63, 0x6c, 0x75, 0x65, 0x49, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x12, 0x0e, 0x2e, 0x43, 0x6c,
-	0x75, 0x65, 0x49, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x71, 0x1a, 0x0f, 0x2e, 0x43, 0x6c,
-	0x75, 0x65, 0x49, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x27, 0x0a, 0x07,
-	0x63, 0x6c, 0x75, 0x65, 0x41, 0x64, 0x64, 0x12, 0x0b, 0x2e, 0x43, 0x6c, 0x75, 0x65, 0x41, 0x64,
-	0x64, 0x52, 0x65, 0x71, 0x1a, 0x0f, 0x2e, 0x41, 0x64, 0x64, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63,
-	0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x2f, 0x0a, 0x0c, 0x63, 0x6c, 0x75, 0x65, 0x49, 0x6d, 0x70,
-	0x6f, 0x72, 0x74, 0x54, 0x74, 0x12, 0x0e, 0x2e, 0x43, 0x6c, 0x75, 0x65, 0x49, 0x6d, 0x70, 0x6f,
-	0x72, 0x74, 0x52, 0x65, 0x71, 0x1a, 0x0f, 0x2e, 0x43, 0x6c, 0x75, 0x65, 0x49, 0x6d, 0x70, 0x6f,
-	0x72, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x27, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x6f, 0x46, 0x6f,
-	0x6c, 0x6c, 0x6f, 0x77, 0x12, 0x08, 0x2e, 0x43, 0x61, 0x6c, 0x6c, 0x52, 0x65, 0x71, 0x1a, 0x0f,
-	0x2e, 0x43, 0x6c, 0x75, 0x65, 0x49, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12,
-	0x24, 0x0a, 0x09, 0x73, 0x71, 0x6c, 0x4d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x12, 0x0d, 0x2e, 0x53,
-	0x71, 0x6c, 0x4d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69,
-	0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x1e, 0x0a, 0x06, 0x6d, 0x79, 0x49, 0x6e, 0x66, 0x6f, 0x12,
-	0x0a, 0x2e, 0x4d, 0x79, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69,
-	0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x25, 0x0a, 0x0d, 0x61, 0x6c, 0x6c, 0x49, 0x6e, 0x66, 0x6f,
-	0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x12, 0x0a, 0x2e, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x52,
-	0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x28, 0x0a, 0x10,
-	0x61, 0x6c, 0x6c, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74,
-	0x12, 0x0a, 0x2e, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42,
-	0x69, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x24, 0x0a, 0x0b, 0x69, 0x6e, 0x66, 0x6f, 0x4f, 0x70,
-	0x65, 0x72, 0x61, 0x74, 0x65, 0x12, 0x0b, 0x2e, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x65, 0x52,
-	0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x2b, 0x0a, 0x0e,
-	0x67, 0x65, 0x74, 0x43, 0x6f, 0x6d, 0x70, 0x61, 0x6e, 0x79, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0b,
-	0x2e, 0x43, 0x6f, 0x6d, 0x70, 0x61, 0x6e, 0x79, 0x52, 0x65, 0x71, 0x1a, 0x0c, 0x2e, 0x43, 0x6f,
-	0x6d, 0x70, 0x61, 0x6e, 0x79, 0x52, 0x65, 0x73, 0x70, 0x12, 0x45, 0x0a, 0x12, 0x64, 0x69, 0x73,
-	0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x43, 0x6c, 0x75, 0x65, 0x53, 0x68, 0x6f, 0x77, 0x12,
-	0x16, 0x2e, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x43, 0x6c, 0x75, 0x65,
-	0x53, 0x68, 0x6f, 0x77, 0x52, 0x65, 0x71, 0x1a, 0x17, 0x2e, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69,
-	0x62, 0x75, 0x74, 0x65, 0x43, 0x6c, 0x75, 0x65, 0x53, 0x68, 0x6f, 0x77, 0x52, 0x65, 0x73, 0x70,
-	0x12, 0x24, 0x0a, 0x08, 0x73, 0x65, 0x6e, 0x64, 0x4d, 0x61, 0x69, 0x6c, 0x12, 0x0e, 0x2e, 0x45,
-	0x78, 0x70, 0x6f, 0x72, 0x74, 0x42, 0x79, 0x44, 0x62, 0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42,
-	0x69, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x1e, 0x0a, 0x06, 0x75, 0x70, 0x46, 0x69, 0x6c, 0x65,
-	0x12, 0x0a, 0x2e, 0x55, 0x70, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42,
-	0x69, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x28, 0x0a, 0x0e, 0x73, 0x65, 0x6e, 0x64, 0x43, 0x6f,
-	0x6d, 0x6d, 0x6f, 0x6e, 0x4d, 0x61, 0x69, 0x6c, 0x12, 0x0c, 0x2e, 0x53, 0x65, 0x6e, 0x64, 0x4d,
-	0x61, 0x69, 0x6c, 0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x70, 0x6c, 0x79,
-	0x12, 0x30, 0x0a, 0x0d, 0x61, 0x64, 0x64, 0x41, 0x63, 0x63, 0x65, 0x70, 0x74, 0x61, 0x6e, 0x63,
-	0x65, 0x12, 0x0e, 0x2e, 0x41, 0x63, 0x63, 0x65, 0x70, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65,
-	0x71, 0x1a, 0x0f, 0x2e, 0x41, 0x63, 0x63, 0x65, 0x70, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65,
-	0x73, 0x70, 0x12, 0x2d, 0x0a, 0x11, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x6c, 0x75, 0x65,
-	0x42, 0x79, 0x50, 0x68, 0x6f, 0x6e, 0x65, 0x12, 0x0e, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65,
-	0x43, 0x75, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x70, 0x6c,
-	0x79, 0x12, 0x31, 0x0a, 0x13, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x43, 0x6c, 0x75,
-	0x65, 0x42, 0x79, 0x50, 0x68, 0x6f, 0x6e, 0x65, 0x12, 0x10, 0x2e, 0x54, 0x72, 0x61, 0x6e, 0x73,
-	0x66, 0x65, 0x72, 0x43, 0x6c, 0x75, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69, 0x52,
-	0x65, 0x70, 0x6c, 0x79, 0x12, 0x2a, 0x0a, 0x0c, 0x66, 0x69, 0x6e, 0x64, 0x43, 0x6c, 0x75, 0x65,
-	0x49, 0x6e, 0x66, 0x6f, 0x12, 0x10, 0x2e, 0x46, 0x69, 0x6e, 0x64, 0x43, 0x6c, 0x75, 0x65, 0x49,
-	0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x70, 0x6c, 0x79,
-	0x12, 0x29, 0x0a, 0x0f, 0x67, 0x65, 0x74, 0x43, 0x6c, 0x75, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x4c,
-	0x69, 0x73, 0x74, 0x12, 0x0c, 0x2e, 0x43, 0x6c, 0x75, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65,
-	0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x33, 0x0a, 0x0c, 0x4d,
-	0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x53, 0x61, 0x76, 0x65, 0x12, 0x10, 0x2e, 0x4d, 0x61,
-	0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x53, 0x61, 0x76, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x11, 0x2e,
-	0x4d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x53, 0x61, 0x76, 0x65, 0x52, 0x65, 0x73, 0x70,
-	0x12, 0x29, 0x0a, 0x0c, 0x63, 0x6c, 0x75, 0x65, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72,
-	0x12, 0x10, 0x2e, 0x43, 0x6c, 0x75, 0x65, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x52,
-	0x65, 0x71, 0x1a, 0x07, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x73, 0x70, 0x42, 0x06, 0x5a, 0x04, 0x2e,
-	0x2f, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
+	0x6d, 0x61, 0x69, 0x6e, 0x43, 0x6c, 0x75, 0x65, 0x49, 0x64, 0x22, 0xd4, 0x01, 0x0a, 0x14, 0x55,
+	0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6d, 0x70, 0x61, 0x6e, 0x79, 0x4e, 0x61, 0x6d, 0x65,
+	0x52, 0x65, 0x71, 0x12, 0x1e, 0x0a, 0x0a, 0x6d, 0x61, 0x69, 0x6e, 0x43, 0x6c, 0x75, 0x65, 0x49,
+	0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x6d, 0x61, 0x69, 0x6e, 0x43, 0x6c, 0x75,
+	0x65, 0x49, 0x64, 0x12, 0x26, 0x0a, 0x0e, 0x4e, 0x65, 0x77, 0x43, 0x6f, 0x6d, 0x70, 0x61, 0x6e,
+	0x79, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4e, 0x65, 0x77,
+	0x43, 0x6f, 0x6d, 0x70, 0x61, 0x6e, 0x79, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x4e,
+	0x65, 0x77, 0x45, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x4e,
+	0x65, 0x77, 0x45, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x75, 0x73, 0x49, 0x64,
+	0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x63, 0x75, 0x73, 0x49, 0x64, 0x12, 0x26, 0x0a,
+	0x0e, 0x4f, 0x6c, 0x64, 0x43, 0x6f, 0x6d, 0x70, 0x61, 0x6e, 0x79, 0x4e, 0x61, 0x6d, 0x65, 0x18,
+	0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x4f, 0x6c, 0x64, 0x43, 0x6f, 0x6d, 0x70, 0x61, 0x6e,
+	0x79, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x4f, 0x6c, 0x64, 0x45, 0x6e, 0x74, 0x49,
+	0x64, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x4f, 0x6c, 0x64, 0x45, 0x6e, 0x74, 0x49,
+	0x64, 0x32, 0xe9, 0x09, 0x0a, 0x09, 0x42, 0x69, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12,
+	0x30, 0x0a, 0x0b, 0x6d, 0x79, 0x44, 0x61, 0x74, 0x61, 0x41, 0x73, 0x73, 0x65, 0x74, 0x12, 0x0f,
+	0x2e, 0x4d, 0x79, 0x44, 0x61, 0x74, 0x61, 0x41, 0x73, 0x73, 0x65, 0x74, 0x52, 0x65, 0x71, 0x1a,
+	0x10, 0x2e, 0x4d, 0x79, 0x44, 0x61, 0x74, 0x61, 0x41, 0x73, 0x73, 0x65, 0x74, 0x52, 0x65, 0x73,
+	0x70, 0x12, 0x2d, 0x0a, 0x0a, 0x61, 0x64, 0x64, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x12,
+	0x0e, 0x2e, 0x41, 0x64, 0x64, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x1a,
+	0x0f, 0x2e, 0x41, 0x64, 0x64, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70,
+	0x12, 0x2b, 0x0a, 0x09, 0x67, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x49, 0x64, 0x12, 0x0e, 0x2e,
+	0x41, 0x64, 0x64, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x1a, 0x0e, 0x2e,
+	0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x49, 0x64, 0x52, 0x65, 0x73, 0x70, 0x12, 0x29, 0x0a,
+	0x08, 0x64, 0x72, 0x61, 0x77, 0x43, 0x6c, 0x75, 0x65, 0x12, 0x0c, 0x2e, 0x44, 0x72, 0x61, 0x77,
+	0x43, 0x6c, 0x75, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x0f, 0x2e, 0x41, 0x64, 0x64, 0x50, 0x72, 0x6f,
+	0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x19, 0x0a, 0x04, 0x43, 0x61, 0x6c, 0x6c,
+	0x12, 0x08, 0x2e, 0x43, 0x61, 0x6c, 0x6c, 0x52, 0x65, 0x71, 0x1a, 0x07, 0x2e, 0x42, 0x69, 0x52,
+	0x65, 0x73, 0x70, 0x12, 0x35, 0x0a, 0x0e, 0x64, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74,
+	0x65, 0x43, 0x6c, 0x75, 0x65, 0x12, 0x12, 0x2e, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75,
+	0x74, 0x65, 0x43, 0x6c, 0x75, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x0f, 0x2e, 0x41, 0x64, 0x64, 0x50,
+	0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x2d, 0x0a, 0x0a, 0x63, 0x6c,
+	0x75, 0x65, 0x49, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x12, 0x0e, 0x2e, 0x43, 0x6c, 0x75, 0x65, 0x49,
+	0x6d, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x71, 0x1a, 0x0f, 0x2e, 0x43, 0x6c, 0x75, 0x65, 0x49,
+	0x6d, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x27, 0x0a, 0x07, 0x63, 0x6c, 0x75,
+	0x65, 0x41, 0x64, 0x64, 0x12, 0x0b, 0x2e, 0x43, 0x6c, 0x75, 0x65, 0x41, 0x64, 0x64, 0x52, 0x65,
+	0x71, 0x1a, 0x0f, 0x2e, 0x41, 0x64, 0x64, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65,
+	0x73, 0x70, 0x12, 0x2f, 0x0a, 0x0c, 0x63, 0x6c, 0x75, 0x65, 0x49, 0x6d, 0x70, 0x6f, 0x72, 0x74,
+	0x54, 0x74, 0x12, 0x0e, 0x2e, 0x43, 0x6c, 0x75, 0x65, 0x49, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x52,
+	0x65, 0x71, 0x1a, 0x0f, 0x2e, 0x43, 0x6c, 0x75, 0x65, 0x49, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x52,
+	0x65, 0x73, 0x70, 0x12, 0x27, 0x0a, 0x0a, 0x61, 0x75, 0x74, 0x6f, 0x46, 0x6f, 0x6c, 0x6c, 0x6f,
+	0x77, 0x12, 0x08, 0x2e, 0x43, 0x61, 0x6c, 0x6c, 0x52, 0x65, 0x71, 0x1a, 0x0f, 0x2e, 0x43, 0x6c,
+	0x75, 0x65, 0x49, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x24, 0x0a, 0x09,
+	0x73, 0x71, 0x6c, 0x4d, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x12, 0x0d, 0x2e, 0x53, 0x71, 0x6c, 0x4d,
+	0x61, 0x6e, 0x61, 0x67, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x70,
+	0x6c, 0x79, 0x12, 0x1e, 0x0a, 0x06, 0x6d, 0x79, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x0a, 0x2e, 0x4d,
+	0x79, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x70,
+	0x6c, 0x79, 0x12, 0x25, 0x0a, 0x0d, 0x61, 0x6c, 0x6c, 0x49, 0x6e, 0x66, 0x6f, 0x45, 0x78, 0x70,
+	0x6f, 0x72, 0x74, 0x12, 0x0a, 0x2e, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x71, 0x1a,
+	0x08, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x28, 0x0a, 0x10, 0x61, 0x6c, 0x6c,
+	0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x12, 0x0a, 0x2e,
+	0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69, 0x52, 0x65,
+	0x70, 0x6c, 0x79, 0x12, 0x24, 0x0a, 0x0b, 0x69, 0x6e, 0x66, 0x6f, 0x4f, 0x70, 0x65, 0x72, 0x61,
+	0x74, 0x65, 0x12, 0x0b, 0x2e, 0x4f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x1a,
+	0x08, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x2b, 0x0a, 0x0e, 0x67, 0x65, 0x74,
+	0x43, 0x6f, 0x6d, 0x70, 0x61, 0x6e, 0x79, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0b, 0x2e, 0x43, 0x6f,
+	0x6d, 0x70, 0x61, 0x6e, 0x79, 0x52, 0x65, 0x71, 0x1a, 0x0c, 0x2e, 0x43, 0x6f, 0x6d, 0x70, 0x61,
+	0x6e, 0x79, 0x52, 0x65, 0x73, 0x70, 0x12, 0x45, 0x0a, 0x12, 0x64, 0x69, 0x73, 0x74, 0x72, 0x69,
+	0x62, 0x75, 0x74, 0x65, 0x43, 0x6c, 0x75, 0x65, 0x53, 0x68, 0x6f, 0x77, 0x12, 0x16, 0x2e, 0x44,
+	0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x43, 0x6c, 0x75, 0x65, 0x53, 0x68, 0x6f,
+	0x77, 0x52, 0x65, 0x71, 0x1a, 0x17, 0x2e, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74,
+	0x65, 0x43, 0x6c, 0x75, 0x65, 0x53, 0x68, 0x6f, 0x77, 0x52, 0x65, 0x73, 0x70, 0x12, 0x24, 0x0a,
+	0x08, 0x73, 0x65, 0x6e, 0x64, 0x4d, 0x61, 0x69, 0x6c, 0x12, 0x0e, 0x2e, 0x45, 0x78, 0x70, 0x6f,
+	0x72, 0x74, 0x42, 0x79, 0x44, 0x62, 0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69, 0x52, 0x65,
+	0x70, 0x6c, 0x79, 0x12, 0x1e, 0x0a, 0x06, 0x75, 0x70, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x0a, 0x2e,
+	0x55, 0x70, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69, 0x52, 0x65,
+	0x70, 0x6c, 0x79, 0x12, 0x28, 0x0a, 0x0e, 0x73, 0x65, 0x6e, 0x64, 0x43, 0x6f, 0x6d, 0x6d, 0x6f,
+	0x6e, 0x4d, 0x61, 0x69, 0x6c, 0x12, 0x0c, 0x2e, 0x53, 0x65, 0x6e, 0x64, 0x4d, 0x61, 0x69, 0x6c,
+	0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x30, 0x0a,
+	0x0d, 0x61, 0x64, 0x64, 0x41, 0x63, 0x63, 0x65, 0x70, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x12, 0x0e,
+	0x2e, 0x41, 0x63, 0x63, 0x65, 0x70, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x0f,
+	0x2e, 0x41, 0x63, 0x63, 0x65, 0x70, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, 0x73, 0x70, 0x12,
+	0x2d, 0x0a, 0x11, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x6c, 0x75, 0x65, 0x42, 0x79, 0x50,
+	0x68, 0x6f, 0x6e, 0x65, 0x12, 0x0e, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x75, 0x6c,
+	0x65, 0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x31,
+	0x0a, 0x13, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x43, 0x6c, 0x75, 0x65, 0x42, 0x79,
+	0x50, 0x68, 0x6f, 0x6e, 0x65, 0x12, 0x10, 0x2e, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72,
+	0x43, 0x6c, 0x75, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x70, 0x6c,
+	0x79, 0x12, 0x2a, 0x0a, 0x0c, 0x66, 0x69, 0x6e, 0x64, 0x43, 0x6c, 0x75, 0x65, 0x49, 0x6e, 0x66,
+	0x6f, 0x12, 0x10, 0x2e, 0x46, 0x69, 0x6e, 0x64, 0x43, 0x6c, 0x75, 0x65, 0x49, 0x6e, 0x66, 0x6f,
+	0x52, 0x65, 0x71, 0x1a, 0x08, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x29, 0x0a,
+	0x0f, 0x67, 0x65, 0x74, 0x43, 0x6c, 0x75, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x4c, 0x69, 0x73, 0x74,
+	0x12, 0x0c, 0x2e, 0x43, 0x6c, 0x75, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x1a, 0x08,
+	0x2e, 0x42, 0x69, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x12, 0x33, 0x0a, 0x0c, 0x4d, 0x61, 0x74, 0x65,
+	0x72, 0x69, 0x61, 0x6c, 0x53, 0x61, 0x76, 0x65, 0x12, 0x10, 0x2e, 0x4d, 0x61, 0x74, 0x65, 0x72,
+	0x69, 0x61, 0x6c, 0x53, 0x61, 0x76, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x11, 0x2e, 0x4d, 0x61, 0x74,
+	0x65, 0x72, 0x69, 0x61, 0x6c, 0x53, 0x61, 0x76, 0x65, 0x52, 0x65, 0x73, 0x70, 0x12, 0x29, 0x0a,
+	0x0c, 0x63, 0x6c, 0x75, 0x65, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x12, 0x10, 0x2e,
+	0x43, 0x6c, 0x75, 0x65, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x52, 0x65, 0x71, 0x1a,
+	0x07, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x73, 0x70, 0x12, 0x33, 0x0a, 0x11, 0x75, 0x70, 0x64, 0x61,
+	0x74, 0x65, 0x43, 0x6f, 0x6d, 0x70, 0x61, 0x6e, 0x79, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x15, 0x2e,
+	0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6d, 0x70, 0x61, 0x6e, 0x79, 0x4e, 0x61, 0x6d,
+	0x65, 0x52, 0x65, 0x71, 0x1a, 0x07, 0x2e, 0x42, 0x69, 0x52, 0x65, 0x73, 0x70, 0x42, 0x06, 0x5a,
+	0x04, 0x2e, 0x2f, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
 }
 
 var (
@@ -3632,7 +3686,7 @@ var file_biService_proto_goTypes = []interface{}{
 	(*MaterialSaveReq)(nil),        // 39: MaterialSaveReq
 	(*MaterialSaveResp)(nil),       // 40: MaterialSaveResp
 	(*ClueTransferReq)(nil),        // 41: ClueTransferReq
-	(*UpdateClueName)(nil),         // 42: UpdateClueName
+	(*UpdateCompanyNameReq)(nil),   // 42: UpdateCompanyNameReq
 }
 var file_biService_proto_depIdxs = []int32{
 	2,  // 0: MyDataAssetResp.data:type_name -> MyDataAsset
@@ -3671,35 +3725,37 @@ var file_biService_proto_depIdxs = []int32{
 	38, // 33: BiService.getClueInfoList:input_type -> ClueInfoReq
 	39, // 34: BiService.MaterialSave:input_type -> MaterialSaveReq
 	41, // 35: BiService.clueTransfer:input_type -> ClueTransferReq
-	1,  // 36: BiService.myDataAsset:output_type -> MyDataAssetResp
-	4,  // 37: BiService.addProject:output_type -> AddProjectResp
-	6,  // 38: BiService.getInfoId:output_type -> GetInfoIdResp
-	4,  // 39: BiService.drawClue:output_type -> AddProjectResp
-	9,  // 40: BiService.Call:output_type -> BiResp
-	4,  // 41: BiService.distributeClue:output_type -> AddProjectResp
-	14, // 42: BiService.clueImport:output_type -> ClueImportResp
-	4,  // 43: BiService.clueAdd:output_type -> AddProjectResp
-	14, // 44: BiService.clueImportTt:output_type -> ClueImportResp
-	14, // 45: BiService.autoFollow:output_type -> ClueImportResp
-	10, // 46: BiService.sqlManage:output_type -> BiReply
-	10, // 47: BiService.myInfo:output_type -> BiReply
-	10, // 48: BiService.allInfoExport:output_type -> BiReply
-	10, // 49: BiService.allProjectExport:output_type -> BiReply
-	10, // 50: BiService.infoOperate:output_type -> BiReply
-	23, // 51: BiService.getCompanyType:output_type -> CompanyResp
-	27, // 52: BiService.distributeClueShow:output_type -> DistributeClueShowResp
-	10, // 53: BiService.sendMail:output_type -> BiReply
-	10, // 54: BiService.upFile:output_type -> BiReply
-	10, // 55: BiService.sendCommonMail:output_type -> BiReply
-	32, // 56: BiService.addAcceptance:output_type -> AcceptanceResp
-	10, // 57: BiService.createClueByPhone:output_type -> BiReply
-	10, // 58: BiService.transferClueByPhone:output_type -> BiReply
-	10, // 59: BiService.findClueInfo:output_type -> BiReply
-	10, // 60: BiService.getClueInfoList:output_type -> BiReply
-	40, // 61: BiService.MaterialSave:output_type -> MaterialSaveResp
-	9,  // 62: BiService.clueTransfer:output_type -> BiResp
-	36, // [36:63] is the sub-list for method output_type
-	9,  // [9:36] is the sub-list for method input_type
+	42, // 36: BiService.updateCompanyName:input_type -> UpdateCompanyNameReq
+	1,  // 37: BiService.myDataAsset:output_type -> MyDataAssetResp
+	4,  // 38: BiService.addProject:output_type -> AddProjectResp
+	6,  // 39: BiService.getInfoId:output_type -> GetInfoIdResp
+	4,  // 40: BiService.drawClue:output_type -> AddProjectResp
+	9,  // 41: BiService.Call:output_type -> BiResp
+	4,  // 42: BiService.distributeClue:output_type -> AddProjectResp
+	14, // 43: BiService.clueImport:output_type -> ClueImportResp
+	4,  // 44: BiService.clueAdd:output_type -> AddProjectResp
+	14, // 45: BiService.clueImportTt:output_type -> ClueImportResp
+	14, // 46: BiService.autoFollow:output_type -> ClueImportResp
+	10, // 47: BiService.sqlManage:output_type -> BiReply
+	10, // 48: BiService.myInfo:output_type -> BiReply
+	10, // 49: BiService.allInfoExport:output_type -> BiReply
+	10, // 50: BiService.allProjectExport:output_type -> BiReply
+	10, // 51: BiService.infoOperate:output_type -> BiReply
+	23, // 52: BiService.getCompanyType:output_type -> CompanyResp
+	27, // 53: BiService.distributeClueShow:output_type -> DistributeClueShowResp
+	10, // 54: BiService.sendMail:output_type -> BiReply
+	10, // 55: BiService.upFile:output_type -> BiReply
+	10, // 56: BiService.sendCommonMail:output_type -> BiReply
+	32, // 57: BiService.addAcceptance:output_type -> AcceptanceResp
+	10, // 58: BiService.createClueByPhone:output_type -> BiReply
+	10, // 59: BiService.transferClueByPhone:output_type -> BiReply
+	10, // 60: BiService.findClueInfo:output_type -> BiReply
+	10, // 61: BiService.getClueInfoList:output_type -> BiReply
+	40, // 62: BiService.MaterialSave:output_type -> MaterialSaveResp
+	9,  // 63: BiService.clueTransfer:output_type -> BiResp
+	9,  // 64: BiService.updateCompanyName:output_type -> BiResp
+	37, // [37:65] is the sub-list for method output_type
+	9,  // [9:37] 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
@@ -4216,7 +4272,7 @@ func file_biService_proto_init() {
 			}
 		}
 		file_biService_proto_msgTypes[42].Exporter = func(v interface{}, i int) interface{} {
-			switch v := v.(*UpdateClueName); i {
+			switch v := v.(*UpdateCompanyNameReq); i {
 			case 0:
 				return &v.state
 			case 1:

+ 36 - 0
rpc/pb/biService_grpc.pb.go

@@ -49,6 +49,7 @@ type BiServiceClient interface {
 	GetClueInfoList(ctx context.Context, in *ClueInfoReq, opts ...grpc.CallOption) (*BiReply, error)
 	MaterialSave(ctx context.Context, in *MaterialSaveReq, opts ...grpc.CallOption) (*MaterialSaveResp, error)
 	ClueTransfer(ctx context.Context, in *ClueTransferReq, opts ...grpc.CallOption) (*BiResp, error)
+	UpdateCompanyName(ctx context.Context, in *UpdateCompanyNameReq, opts ...grpc.CallOption) (*BiResp, error)
 }
 
 type biServiceClient struct {
@@ -302,6 +303,15 @@ func (c *biServiceClient) ClueTransfer(ctx context.Context, in *ClueTransferReq,
 	return out, nil
 }
 
+func (c *biServiceClient) UpdateCompanyName(ctx context.Context, in *UpdateCompanyNameReq, opts ...grpc.CallOption) (*BiResp, error) {
+	out := new(BiResp)
+	err := c.cc.Invoke(ctx, "/BiService/updateCompanyName", in, out, opts...)
+	if err != nil {
+		return nil, err
+	}
+	return out, nil
+}
+
 // BiServiceServer is the server API for BiService service.
 // All implementations must embed UnimplementedBiServiceServer
 // for forward compatibility
@@ -333,6 +343,7 @@ type BiServiceServer interface {
 	GetClueInfoList(context.Context, *ClueInfoReq) (*BiReply, error)
 	MaterialSave(context.Context, *MaterialSaveReq) (*MaterialSaveResp, error)
 	ClueTransfer(context.Context, *ClueTransferReq) (*BiResp, error)
+	UpdateCompanyName(context.Context, *UpdateCompanyNameReq) (*BiResp, error)
 	mustEmbedUnimplementedBiServiceServer()
 }
 
@@ -421,6 +432,9 @@ func (UnimplementedBiServiceServer) MaterialSave(context.Context, *MaterialSaveR
 func (UnimplementedBiServiceServer) ClueTransfer(context.Context, *ClueTransferReq) (*BiResp, error) {
 	return nil, status.Errorf(codes.Unimplemented, "method ClueTransfer not implemented")
 }
+func (UnimplementedBiServiceServer) UpdateCompanyName(context.Context, *UpdateCompanyNameReq) (*BiResp, error) {
+	return nil, status.Errorf(codes.Unimplemented, "method UpdateCompanyName not implemented")
+}
 func (UnimplementedBiServiceServer) mustEmbedUnimplementedBiServiceServer() {}
 
 // UnsafeBiServiceServer may be embedded to opt out of forward compatibility for this service.
@@ -920,6 +934,24 @@ func _BiService_ClueTransfer_Handler(srv interface{}, ctx context.Context, dec f
 	return interceptor(ctx, in, info, handler)
 }
 
+func _BiService_UpdateCompanyName_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
+	in := new(UpdateCompanyNameReq)
+	if err := dec(in); err != nil {
+		return nil, err
+	}
+	if interceptor == nil {
+		return srv.(BiServiceServer).UpdateCompanyName(ctx, in)
+	}
+	info := &grpc.UnaryServerInfo{
+		Server:     srv,
+		FullMethod: "/BiService/updateCompanyName",
+	}
+	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
+		return srv.(BiServiceServer).UpdateCompanyName(ctx, req.(*UpdateCompanyNameReq))
+	}
+	return interceptor(ctx, in, info, handler)
+}
+
 // BiService_ServiceDesc is the grpc.ServiceDesc for BiService service.
 // It's only intended for direct use with grpc.RegisterService,
 // and not to be introspected or modified (even as a copy)
@@ -1035,6 +1067,10 @@ var BiService_ServiceDesc = grpc.ServiceDesc{
 			MethodName: "clueTransfer",
 			Handler:    _BiService_ClueTransfer_Handler,
 		},
+		{
+			MethodName: "updateCompanyName",
+			Handler:    _BiService_UpdateCompanyName_Handler,
+		},
 	},
 	Streams:  []grpc.StreamDesc{},
 	Metadata: "biService.proto",

+ 76 - 1
service/updateClueName.go

@@ -1,5 +1,80 @@
 package service
 
-func UpdateClueName() {
+import (
+	"app.yhyue.com/moapp/jybase/common"
+	"bp.jydev.jianyu360.cn/BaseService/biService/entity"
+	"bp.jydev.jianyu360.cn/BaseService/biService/rpc/pb"
+	"errors"
+	"time"
+)
 
+func UpdateClueName(in *pb.UpdateCompanyNameReq) error {
+	newIsGroup, _ := CompanyType(in.NewCompanyName)
+	oldIsGroup, _ := CompanyType(in.OldCompanyName)
+
+	mainData := entity.JyBiTidb.FindOne("dwd_f_csm_customer_info", map[string]interface{}{"clue_id": in.MainClueId, "is_transfer": 0, "primary_id": 1}, "", "")
+	if mainData == nil || len(*mainData) == 0 {
+		return errors.New("主账号没有移交客成")
+	}
+	mainCusId := common.Int64All((*mainData)["id"])
+	//把主账号、子账号和企业组织架构免费账号修改线索名称
+	//更新主账号线索、客成信息
+	entity.JyBiTidb.Update("dwd_f_crm_clue_info", map[string]interface{}{"id": in.MainClueId}, map[string]interface{}{"cluename": in.NewCompanyName})
+	entity.JyBiTidb.Update("dwd_f_csm_customer_info", map[string]interface{}{"clue_id": in.MainClueId}, map[string]interface{}{"company_name": in.NewCompanyName, "ent_id": in.NewEntId})
+	//子账号和企业组织架构免费账号修改线索名称
+	subAndFreeData := entity.JyBiTidb.SelectBySql("SELECT * FROM dwd_f_csm_customer_info WHERE primary_id = ? AND is_transfer = 0 AND (account_type=2 OR account_type=3)", mainCusId)
+	if subAndFreeData != nil && len(*subAndFreeData) > 0 {
+		nowTime := time.Now().Format("2006-01-02 15:04:05")
+		for _, val := range *subAndFreeData {
+			//更新线索、客成信息
+			kcPositionId := common.Int64All(val["position_id"])
+			subClueId := common.Int64All(val["clue_id"]) //子账号或者企业组织架构免费账号线索id
+			entity.JyBiTidb.UpdateOrDeleteBySql("UPDATE dwd_f_crm_clue_info SET cluename = ? WHERE id = ?", subClueId)
+			entity.JyBiTidb.UpdateOrDeleteBySql("UPDATE dwd_f_csm_customer_info SET company_name = ?,ent_id=? WHERE clue_id = ?")
+			//插入变更记录
+			entity.JyBiTidb.Insert("dwd_f_crm_clue_change_record", map[string]interface{}{
+				"clue_id":      subClueId,
+				"change_field": "cluename",
+				"change_type":  "基本信息变更",
+				"old_value":    common.If(in.OldCompanyName != "", in.OldCompanyName, "/"),
+				"new_value":    common.If(in.NewCompanyName != "", in.NewCompanyName, "/"),
+				"createtime":   nowTime,
+				"BCPCID":       common.GetRandom(32),
+				"position_id":  kcPositionId,
+				"operator_id":  -1})
+		}
+	}
+
+	//客成系统有其它主账号是原公司,则将该主账号下的非集团公司免费账号关联至其他主账号下
+	if !oldIsGroup {
+		//查非集团免费账号
+		freeData := entity.JyBiTidb.SelectBySql("SELECT * FROM dwd_f_csm_customer_info WHERE primary_id = ? AND account_type = 4 AND is_transfer = 0", mainCusId)
+		if freeData != nil && len(*freeData) > 0 {
+			oldOtherCus := entity.JyBiTidb.FindOne("dwd_f_csm_customer_info", map[string]interface{}{"company_name": in.OldCompanyName, "is_transfer": 0, "primary_id": 1}, "", "")
+			if oldOtherCus != nil && len(*oldOtherCus) > 0 {
+				//把非集团免费账号移交另外的主账号下
+
+			} else {
+				//把非集团免费账号移交电销
+				/*data := entity.JyBiTidb.SelectBySql("SELECT * FROM dwd_f_csm_customer_info WHERE primary_id = ? AND is_transfer = 0", mainCusId)
+				if data != nil && len(*data) > 0 {
+					for _, val := range *data {
+						//移交电销
+					}
+				}*/
+			}
+		}
+	}
+
+	if !oldIsGroup && !newIsGroup {
+		//把线索名称是新企业名称的线索移交客成
+	}
+
+	if oldIsGroup && !newIsGroup {
+		//关联线索处理
+		//(4)该线索的客户成功经理,由空调整为其关联客户的客户成功经理,并新增1条“客户成功经理变更”的线索动态;
+		//(5)“线索归属”标记为“客户成功部”。
+	}
+
+	return nil
 }