diff --git a/app/cc_member.go b/app/cc_member.go index 44d28fe3..5c43466c 100644 --- a/app/cc_member.go +++ b/app/cc_member.go @@ -228,9 +228,19 @@ func (app *App) ListOfflineQueueForAgent(ctx context.Context, domainId int64, se return list, search.EndOfList(), nil } -func (app *App) ReportingAttempt(attemptId int64, status, description string, nextOffering *int64, expireAt *int64, vars map[string]string, - stickyDisplay bool, agentId int32, excludeDes bool, waitBetweenRetries *int32, onlyComm bool) model.AppError { - +func (app *App) ReportingAttempt( + attemptId int64, + status, description string, + nextOffering *int64, + expireAt *int64, + vars map[string]string, + stickyDisplay bool, + agentId int32, + excludeDes bool, + waitBetweenRetries *int32, + onlyComm bool, + draft bool, +) model.AppError { res := &cc.AttemptResultRequest{ AttemptId: attemptId, Status: status, @@ -243,6 +253,7 @@ func (app *App) ReportingAttempt(attemptId int64, status, description string, ne AgentId: agentId, ExcludeCurrentCommunication: excludeDes, OnlyCurrentCommunication: onlyComm, + Draft: draft, } if expireAt != nil { @@ -257,9 +268,7 @@ func (app *App) ReportingAttempt(attemptId int64, status, description string, ne res.WaitBetweenRetries = *waitBetweenRetries } - err := app.cc.Member().AttemptResult(res) - - if err != nil { + if err := app.cc.Member().AttemptResult(res); err != nil { return model.NewBadRequestError("app.cc_member.reporting.app_err", err.Error()) } diff --git a/controller/member.go b/controller/member.go index de63ef0a..1ceba66b 100644 --- a/controller/member.go +++ b/controller/member.go @@ -33,15 +33,39 @@ func (c *Controller) ListOfflineQueueForAgent(ctx context.Context, session *auth return c.app.ListOfflineQueueForAgent(ctx, session.DomainId, search) } -func (c *Controller) ReportingAttempt(session *auth_manager.Session, attemptId int64, status, description string, nextOffering *int64, - expireAt *int64, vars map[string]string, stickyDisplay bool, agentId int32, exclDes bool, waitBetweenRetries *int32, onlyComm bool) model.AppError { +func (c *Controller) ReportingAttempt( + session *auth_manager.Session, + attemptId int64, + status, description string, + nextOffering *int64, + expireAt *int64, + vars map[string]string, + stickyDisplay bool, + agentId int32, + exclDes bool, + waitBetweenRetries *int32, + onlyComm bool, + draft bool, +) model.AppError { permission := session.GetPermission(model.PERMISSION_SCOPE_CC_QUEUE) if !permission.CanRead() { return c.app.MakePermissionError(session, permission, auth_manager.PERMISSION_ACCESS_READ) } - return c.app.ReportingAttempt(attemptId, status, description, nextOffering, expireAt, vars, stickyDisplay, agentId, exclDes, - waitBetweenRetries, onlyComm) + return c.app.ReportingAttempt( + attemptId, + status, + description, + nextOffering, + expireAt, + vars, + stickyDisplay, + agentId, + exclDes, + waitBetweenRetries, + onlyComm, + draft, + ) } func (c *Controller) RenewalAttempt(session *auth_manager.Session, attemptId int64, renewal uint32) model.AppError { diff --git a/gen/cc/cc_member.pb.go b/gen/cc/cc_member.pb.go index 608d847d..c7291b27 100644 --- a/gen/cc/cc_member.pb.go +++ b/gen/cc/cc_member.pb.go @@ -2636,6 +2636,7 @@ type AttemptResultRequest struct { AddCommunications []*MemberCommunicationCreateRequest `protobuf:"bytes,12,rep,name=add_communications,json=addCommunications,proto3" json:"add_communications,omitempty"` WaitBetweenRetries int32 `protobuf:"varint,13,opt,name=wait_between_retries,json=waitBetweenRetries,proto3" json:"wait_between_retries,omitempty"` OnlyCurrentCommunication bool `protobuf:"varint,14,opt,name=only_current_communication,json=onlyCurrentCommunication,proto3" json:"only_current_communication,omitempty"` + Draft bool `protobuf:"varint,15,opt,name=draft,proto3" json:"draft,omitempty"` } func (x *AttemptResultRequest) Reset() { @@ -2768,6 +2769,13 @@ func (x *AttemptResultRequest) GetOnlyCurrentCommunication() bool { return false } +func (x *AttemptResultRequest) GetDraft() bool { + if x != nil { + return x.Draft + } + return false +} + type AttemptResultResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -4386,7 +4394,7 @@ var file_cc_member_proto_rawDesc = []byte{ 0x64, 0x69, 0x73, 0x70, 0x6c, 0x61, 0x79, 0x12, 0x17, 0x0a, 0x07, 0x73, 0x74, 0x6f, 0x70, 0x5f, 0x61, 0x74, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x73, 0x74, 0x6f, 0x70, 0x41, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x74, 0x6d, 0x66, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, - 0x64, 0x74, 0x6d, 0x66, 0x22, 0xc1, 0x05, 0x0a, 0x14, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, + 0x64, 0x74, 0x6d, 0x66, 0x22, 0xd7, 0x05, 0x0a, 0x14, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x61, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, @@ -4426,110 +4434,111 @@ var file_cc_member_proto_rawDesc = []byte{ 0x6f, 0x6e, 0x6c, 0x79, 0x5f, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x5f, 0x63, 0x6f, 0x6d, 0x6d, 0x75, 0x6e, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08, 0x52, 0x18, 0x6f, 0x6e, 0x6c, 0x79, 0x43, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x43, 0x6f, 0x6d, - 0x6d, 0x75, 0x6e, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x1a, 0x3c, 0x0a, 0x0e, 0x56, 0x61, - 0x72, 0x69, 0x61, 0x62, 0x6c, 0x65, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, - 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, - 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, - 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x2f, 0x0a, 0x15, 0x41, 0x74, 0x74, 0x65, - 0x6d, 0x70, 0x74, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x32, 0x92, 0x0b, 0x0a, 0x0d, 0x4d, 0x65, - 0x6d, 0x62, 0x65, 0x72, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x46, 0x0a, 0x0d, 0x41, - 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x18, 0x2e, 0x63, + 0x6d, 0x75, 0x6e, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x14, 0x0a, 0x05, 0x64, 0x72, + 0x61, 0x66, 0x74, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, 0x64, 0x72, 0x61, 0x66, 0x74, + 0x1a, 0x3c, 0x0a, 0x0e, 0x56, 0x61, 0x72, 0x69, 0x61, 0x62, 0x6c, 0x65, 0x73, 0x45, 0x6e, 0x74, + 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x2f, + 0x0a, 0x15, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, + 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x32, + 0x92, 0x0b, 0x0a, 0x0d, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x12, 0x46, 0x0a, 0x0d, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, 0x73, 0x75, + 0x6c, 0x74, 0x12, 0x18, 0x2e, 0x63, 0x63, 0x2e, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, + 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x63, 0x63, 0x2e, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x63, 0x63, 0x2e, 0x41, 0x74, 0x74, 0x65, - 0x6d, 0x70, 0x74, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x00, 0x12, 0x5b, 0x0a, 0x14, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, - 0x6e, 0x65, 0x77, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x1f, 0x2e, 0x63, 0x63, - 0x2e, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, 0x6e, 0x65, 0x77, 0x61, 0x6c, 0x52, - 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x63, - 0x63, 0x2e, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, 0x6e, 0x65, 0x77, 0x61, 0x6c, - 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, - 0x12, 0x41, 0x0a, 0x0f, 0x43, 0x61, 0x6c, 0x6c, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x51, 0x75, - 0x65, 0x75, 0x65, 0x12, 0x1a, 0x2e, 0x63, 0x63, 0x2e, 0x43, 0x61, 0x6c, 0x6c, 0x4a, 0x6f, 0x69, - 0x6e, 0x54, 0x6f, 0x51, 0x75, 0x65, 0x75, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x0e, 0x2e, 0x63, 0x63, 0x2e, 0x51, 0x75, 0x65, 0x75, 0x65, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x22, - 0x00, 0x30, 0x01, 0x12, 0x41, 0x0a, 0x0f, 0x43, 0x68, 0x61, 0x74, 0x4a, 0x6f, 0x69, 0x6e, 0x54, - 0x6f, 0x51, 0x75, 0x65, 0x75, 0x65, 0x12, 0x1a, 0x2e, 0x63, 0x63, 0x2e, 0x43, 0x68, 0x61, 0x74, - 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x51, 0x75, 0x65, 0x75, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x0e, 0x2e, 0x63, 0x63, 0x2e, 0x51, 0x75, 0x65, 0x75, 0x65, 0x45, 0x76, 0x65, - 0x6e, 0x74, 0x22, 0x00, 0x30, 0x01, 0x12, 0x41, 0x0a, 0x0f, 0x43, 0x61, 0x6c, 0x6c, 0x4a, 0x6f, - 0x69, 0x6e, 0x54, 0x6f, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x12, 0x1a, 0x2e, 0x63, 0x63, 0x2e, 0x43, - 0x61, 0x6c, 0x6c, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x52, 0x65, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x5b, 0x0a, 0x14, 0x41, 0x74, 0x74, + 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, 0x6e, 0x65, 0x77, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x75, 0x6c, + 0x74, 0x12, 0x1f, 0x2e, 0x63, 0x63, 0x2e, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, + 0x6e, 0x65, 0x77, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x63, 0x63, 0x2e, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, + 0x65, 0x6e, 0x65, 0x77, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x41, 0x0a, 0x0f, 0x43, 0x61, 0x6c, 0x6c, 0x4a, 0x6f, + 0x69, 0x6e, 0x54, 0x6f, 0x51, 0x75, 0x65, 0x75, 0x65, 0x12, 0x1a, 0x2e, 0x63, 0x63, 0x2e, 0x43, + 0x61, 0x6c, 0x6c, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x51, 0x75, 0x65, 0x75, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x0e, 0x2e, 0x63, 0x63, 0x2e, 0x51, 0x75, 0x65, 0x75, 0x65, - 0x45, 0x76, 0x65, 0x6e, 0x74, 0x22, 0x00, 0x30, 0x01, 0x12, 0x43, 0x0a, 0x0c, 0x4f, 0x75, 0x74, - 0x62, 0x6f, 0x75, 0x6e, 0x64, 0x43, 0x61, 0x6c, 0x6c, 0x12, 0x17, 0x2e, 0x63, 0x63, 0x2e, 0x4f, - 0x75, 0x74, 0x62, 0x6f, 0x75, 0x6e, 0x64, 0x43, 0x61, 0x6c, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x63, 0x63, 0x2e, 0x4f, 0x75, 0x74, 0x62, 0x6f, 0x75, 0x6e, 0x64, - 0x43, 0x61, 0x6c, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x41, - 0x0a, 0x0f, 0x54, 0x61, 0x73, 0x6b, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x41, 0x67, 0x65, 0x6e, - 0x74, 0x12, 0x1a, 0x2e, 0x63, 0x63, 0x2e, 0x54, 0x61, 0x73, 0x6b, 0x4a, 0x6f, 0x69, 0x6e, 0x54, - 0x6f, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x0e, 0x2e, - 0x63, 0x63, 0x2e, 0x51, 0x75, 0x65, 0x75, 0x65, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x22, 0x00, 0x30, - 0x01, 0x12, 0x46, 0x0a, 0x0d, 0x49, 0x4d, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x51, 0x75, 0x65, - 0x75, 0x65, 0x12, 0x18, 0x2e, 0x63, 0x63, 0x2e, 0x49, 0x4d, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, - 0x51, 0x75, 0x65, 0x75, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x63, - 0x63, 0x2e, 0x49, 0x4d, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x51, 0x75, 0x65, 0x75, 0x65, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x46, 0x0a, 0x0d, 0x43, 0x61, 0x6e, - 0x63, 0x65, 0x6c, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x12, 0x18, 0x2e, 0x63, 0x63, 0x2e, - 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x63, 0x63, 0x2e, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, - 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x00, 0x12, 0x5e, 0x0a, 0x15, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x41, 0x67, 0x65, 0x6e, 0x74, - 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x12, 0x20, 0x2e, 0x63, 0x63, 0x2e, - 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x44, 0x69, 0x73, 0x74, 0x72, - 0x69, 0x62, 0x75, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x21, 0x2e, 0x63, - 0x63, 0x2e, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x44, 0x69, 0x73, - 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x00, 0x12, 0x4f, 0x0a, 0x10, 0x45, 0x6d, 0x61, 0x69, 0x6c, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, - 0x51, 0x75, 0x65, 0x75, 0x65, 0x12, 0x1b, 0x2e, 0x63, 0x63, 0x2e, 0x45, 0x6d, 0x61, 0x69, 0x6c, + 0x45, 0x76, 0x65, 0x6e, 0x74, 0x22, 0x00, 0x30, 0x01, 0x12, 0x41, 0x0a, 0x0f, 0x43, 0x68, 0x61, + 0x74, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x51, 0x75, 0x65, 0x75, 0x65, 0x12, 0x1a, 0x2e, 0x63, + 0x63, 0x2e, 0x43, 0x68, 0x61, 0x74, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x51, 0x75, 0x65, 0x75, + 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x0e, 0x2e, 0x63, 0x63, 0x2e, 0x51, 0x75, + 0x65, 0x75, 0x65, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x22, 0x00, 0x30, 0x01, 0x12, 0x41, 0x0a, 0x0f, + 0x43, 0x61, 0x6c, 0x6c, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x12, + 0x1a, 0x2e, 0x63, 0x63, 0x2e, 0x43, 0x61, 0x6c, 0x6c, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x41, + 0x67, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x0e, 0x2e, 0x63, 0x63, + 0x2e, 0x51, 0x75, 0x65, 0x75, 0x65, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x22, 0x00, 0x30, 0x01, 0x12, + 0x43, 0x0a, 0x0c, 0x4f, 0x75, 0x74, 0x62, 0x6f, 0x75, 0x6e, 0x64, 0x43, 0x61, 0x6c, 0x6c, 0x12, + 0x17, 0x2e, 0x63, 0x63, 0x2e, 0x4f, 0x75, 0x74, 0x62, 0x6f, 0x75, 0x6e, 0x64, 0x43, 0x61, 0x6c, + 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x63, 0x63, 0x2e, 0x4f, 0x75, + 0x74, 0x62, 0x6f, 0x75, 0x6e, 0x64, 0x43, 0x61, 0x6c, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x00, 0x12, 0x41, 0x0a, 0x0f, 0x54, 0x61, 0x73, 0x6b, 0x4a, 0x6f, 0x69, 0x6e, + 0x54, 0x6f, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x12, 0x1a, 0x2e, 0x63, 0x63, 0x2e, 0x54, 0x61, 0x73, + 0x6b, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x0e, 0x2e, 0x63, 0x63, 0x2e, 0x51, 0x75, 0x65, 0x75, 0x65, 0x45, 0x76, + 0x65, 0x6e, 0x74, 0x22, 0x00, 0x30, 0x01, 0x12, 0x46, 0x0a, 0x0d, 0x49, 0x4d, 0x4a, 0x6f, 0x69, + 0x6e, 0x54, 0x6f, 0x51, 0x75, 0x65, 0x75, 0x65, 0x12, 0x18, 0x2e, 0x63, 0x63, 0x2e, 0x49, 0x4d, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x51, 0x75, 0x65, 0x75, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x63, 0x63, 0x2e, 0x45, 0x6d, 0x61, 0x69, 0x6c, 0x4a, 0x6f, 0x69, - 0x6e, 0x54, 0x6f, 0x51, 0x75, 0x65, 0x75, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x22, 0x00, 0x12, 0x58, 0x0a, 0x13, 0x44, 0x69, 0x72, 0x65, 0x63, 0x74, 0x41, 0x67, 0x65, 0x6e, - 0x74, 0x54, 0x6f, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x1e, 0x2e, 0x63, 0x63, 0x2e, 0x44, - 0x69, 0x72, 0x65, 0x63, 0x74, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x54, 0x6f, 0x4d, 0x65, 0x6d, 0x62, - 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x63, 0x63, 0x2e, 0x44, - 0x69, 0x72, 0x65, 0x63, 0x74, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x54, 0x6f, 0x4d, 0x65, 0x6d, 0x62, - 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x5b, 0x0a, 0x14, + 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x63, 0x63, 0x2e, 0x49, 0x4d, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, + 0x51, 0x75, 0x65, 0x75, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, + 0x46, 0x0a, 0x0d, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, + 0x12, 0x18, 0x2e, 0x63, 0x63, 0x2e, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x41, 0x74, 0x74, 0x65, + 0x6d, 0x70, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x63, 0x63, 0x2e, + 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x5e, 0x0a, 0x15, 0x43, 0x61, 0x6e, 0x63, 0x65, + 0x6c, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, + 0x12, 0x20, 0x2e, 0x63, 0x63, 0x2e, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x41, 0x67, 0x65, 0x6e, + 0x74, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x21, 0x2e, 0x63, 0x63, 0x2e, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x41, 0x67, + 0x65, 0x6e, 0x74, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4f, 0x0a, 0x10, 0x45, 0x6d, 0x61, 0x69, 0x6c, + 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x51, 0x75, 0x65, 0x75, 0x65, 0x12, 0x1b, 0x2e, 0x63, 0x63, + 0x2e, 0x45, 0x6d, 0x61, 0x69, 0x6c, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x51, 0x75, 0x65, 0x75, + 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x63, 0x63, 0x2e, 0x45, 0x6d, + 0x61, 0x69, 0x6c, 0x4a, 0x6f, 0x69, 0x6e, 0x54, 0x6f, 0x51, 0x75, 0x65, 0x75, 0x65, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x58, 0x0a, 0x13, 0x44, 0x69, 0x72, 0x65, + 0x63, 0x74, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x54, 0x6f, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x12, + 0x1e, 0x2e, 0x63, 0x63, 0x2e, 0x44, 0x69, 0x72, 0x65, 0x63, 0x74, 0x41, 0x67, 0x65, 0x6e, 0x74, + 0x54, 0x6f, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x1f, 0x2e, 0x63, 0x63, 0x2e, 0x44, 0x69, 0x72, 0x65, 0x63, 0x74, 0x41, 0x67, 0x65, 0x6e, 0x74, + 0x54, 0x6f, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x00, 0x12, 0x5b, 0x0a, 0x14, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x69, 0x6e, 0x67, + 0x46, 0x6f, 0x72, 0x6d, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1f, 0x2e, 0x63, 0x63, 0x2e, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x69, 0x6e, 0x67, 0x46, 0x6f, 0x72, 0x6d, 0x41, 0x63, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1f, 0x2e, 0x63, 0x63, 0x2e, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, - 0x73, 0x69, 0x6e, 0x67, 0x46, 0x6f, 0x72, 0x6d, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x63, 0x63, 0x2e, 0x50, 0x72, 0x6f, 0x63, 0x65, - 0x73, 0x73, 0x69, 0x6e, 0x67, 0x46, 0x6f, 0x72, 0x6d, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x6a, 0x0a, 0x19, 0x50, 0x72, 0x6f, - 0x63, 0x65, 0x73, 0x73, 0x69, 0x6e, 0x67, 0x43, 0x6f, 0x6d, 0x70, 0x6f, 0x6e, 0x65, 0x6e, 0x74, - 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x24, 0x2e, 0x63, 0x63, 0x2e, 0x50, 0x72, 0x6f, 0x63, - 0x65, 0x73, 0x73, 0x69, 0x6e, 0x67, 0x43, 0x6f, 0x6d, 0x70, 0x6f, 0x6e, 0x65, 0x6e, 0x74, 0x41, - 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x25, 0x2e, 0x63, + 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x63, 0x63, + 0x2e, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x69, 0x6e, 0x67, 0x46, 0x6f, 0x72, 0x6d, 0x41, + 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, + 0x6a, 0x0a, 0x19, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x69, 0x6e, 0x67, 0x43, 0x6f, 0x6d, + 0x70, 0x6f, 0x6e, 0x65, 0x6e, 0x74, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x24, 0x2e, 0x63, 0x63, 0x2e, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x69, 0x6e, 0x67, 0x43, 0x6f, 0x6d, 0x70, - 0x6f, 0x6e, 0x65, 0x6e, 0x74, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x55, 0x0a, 0x12, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, - 0x69, 0x6e, 0x67, 0x46, 0x6f, 0x72, 0x6d, 0x53, 0x61, 0x76, 0x65, 0x12, 0x1d, 0x2e, 0x63, 0x63, - 0x2e, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x69, 0x6e, 0x67, 0x46, 0x6f, 0x72, 0x6d, 0x53, - 0x61, 0x76, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x63, 0x63, 0x2e, - 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x69, 0x6e, 0x67, 0x46, 0x6f, 0x72, 0x6d, 0x53, 0x61, - 0x76, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x37, 0x0a, 0x08, - 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x12, 0x13, 0x2e, 0x63, 0x63, 0x2e, 0x54, 0x72, - 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x14, 0x2e, - 0x63, 0x63, 0x2e, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4f, 0x0a, 0x10, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x63, 0x65, - 0x70, 0x74, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x12, 0x1b, 0x2e, 0x63, 0x63, 0x2e, 0x49, - 0x6e, 0x74, 0x65, 0x72, 0x63, 0x65, 0x70, 0x74, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x63, 0x63, 0x2e, 0x49, 0x6e, 0x74, 0x65, - 0x72, 0x63, 0x65, 0x70, 0x74, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x46, 0x0a, 0x0d, 0x52, 0x65, 0x73, 0x75, 0x6d, 0x65, - 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x12, 0x18, 0x2e, 0x63, 0x63, 0x2e, 0x52, 0x65, 0x73, - 0x75, 0x6d, 0x65, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x19, 0x2e, 0x63, 0x63, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6d, 0x65, 0x41, 0x74, 0x74, - 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x5d, - 0x0a, 0x06, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x63, 0x42, 0x0d, 0x43, 0x63, 0x4d, 0x65, 0x6d, 0x62, - 0x65, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x1c, 0x67, 0x69, 0x74, 0x68, 0x75, - 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x77, 0x65, 0x62, 0x69, 0x74, 0x65, 0x6c, 0x2f, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x73, 0x2f, 0x63, 0x63, 0xa2, 0x02, 0x03, 0x43, 0x58, 0x58, 0xaa, 0x02, 0x02, - 0x43, 0x63, 0xca, 0x02, 0x02, 0x43, 0x63, 0xe2, 0x02, 0x0e, 0x43, 0x63, 0x5c, 0x47, 0x50, 0x42, - 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x02, 0x43, 0x63, 0x62, 0x06, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x6f, 0x6e, 0x65, 0x6e, 0x74, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x25, 0x2e, 0x63, 0x63, 0x2e, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x69, + 0x6e, 0x67, 0x43, 0x6f, 0x6d, 0x70, 0x6f, 0x6e, 0x65, 0x6e, 0x74, 0x41, 0x63, 0x74, 0x69, 0x6f, + 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x55, 0x0a, 0x12, 0x50, + 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x69, 0x6e, 0x67, 0x46, 0x6f, 0x72, 0x6d, 0x53, 0x61, 0x76, + 0x65, 0x12, 0x1d, 0x2e, 0x63, 0x63, 0x2e, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x69, 0x6e, + 0x67, 0x46, 0x6f, 0x72, 0x6d, 0x53, 0x61, 0x76, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x1e, 0x2e, 0x63, 0x63, 0x2e, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x69, 0x6e, 0x67, + 0x46, 0x6f, 0x72, 0x6d, 0x53, 0x61, 0x76, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x00, 0x12, 0x37, 0x0a, 0x08, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x12, 0x13, + 0x2e, 0x63, 0x63, 0x2e, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x14, 0x2e, 0x63, 0x63, 0x2e, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x66, 0x65, + 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4f, 0x0a, 0x10, 0x49, + 0x6e, 0x74, 0x65, 0x72, 0x63, 0x65, 0x70, 0x74, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x12, + 0x1b, 0x2e, 0x63, 0x63, 0x2e, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x63, 0x65, 0x70, 0x74, 0x41, 0x74, + 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x63, + 0x63, 0x2e, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x63, 0x65, 0x70, 0x74, 0x41, 0x74, 0x74, 0x65, 0x6d, + 0x70, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x46, 0x0a, 0x0d, + 0x52, 0x65, 0x73, 0x75, 0x6d, 0x65, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x12, 0x18, 0x2e, + 0x63, 0x63, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6d, 0x65, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x63, 0x63, 0x2e, 0x52, 0x65, 0x73, + 0x75, 0x6d, 0x65, 0x41, 0x74, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x00, 0x42, 0x5d, 0x0a, 0x06, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x63, 0x42, 0x0d, + 0x43, 0x63, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, + 0x1c, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x77, 0x65, 0x62, 0x69, + 0x74, 0x65, 0x6c, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x73, 0x2f, 0x63, 0x63, 0xa2, 0x02, 0x03, + 0x43, 0x58, 0x58, 0xaa, 0x02, 0x02, 0x43, 0x63, 0xca, 0x02, 0x02, 0x43, 0x63, 0xe2, 0x02, 0x0e, + 0x43, 0x63, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, + 0x02, 0x43, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/grpc_api/cc_member.go b/grpc_api/cc_member.go index 59c55666..46e41855 100644 --- a/grpc_api/cc_member.go +++ b/grpc_api/cc_member.go @@ -1247,8 +1247,22 @@ func (api *member) AttemptResult(ctx context.Context, in *engine.AttemptResultRe waitBetweenRetries = &in.WaitBetweenRetries } - err = api.ctrl.ReportingAttempt(session, in.AttemptId, in.Status, in.Description, nextOffering, expire, in.Variables, - in.Display, in.AgentId, in.ExcludeCurrentCommunication, waitBetweenRetries, in.OnlyCurrentCommunication) + err = api.ctrl.ReportingAttempt( + session, + in.AttemptId, + in.Status, + in.Description, + nextOffering, + expire, + in.Variables, + in.Display, + in.AgentId, + in.ExcludeCurrentCommunication, + waitBetweenRetries, + in.OnlyCurrentCommunication, + false, + ) + if err != nil { return nil, err } @@ -1280,8 +1294,21 @@ func (api *member) AttemptCallback(ctx context.Context, in *engine.AttemptCallba waitBetweenRetries = &in.WaitBetweenRetries } - err = api.ctrl.ReportingAttempt(session, in.AttemptId, in.Status, in.Description, nextOffering, expire, in.Variables, - in.Display, in.AgentId, in.ExcludeCurrentCommunication, waitBetweenRetries, in.OnlyCurrentCommunication) + err = api.ctrl.ReportingAttempt( + session, + in.AttemptId, + in.Status, + in.Description, + nextOffering, + expire, + in.Variables, + in.Display, + in.AgentId, + in.ExcludeCurrentCommunication, + waitBetweenRetries, + in.OnlyCurrentCommunication, + false, + ) if err != nil { return nil, err } diff --git a/wsapi/member.go b/wsapi/member.go index 83f1394a..4c390954 100644 --- a/wsapi/member.go +++ b/wsapi/member.go @@ -143,7 +143,7 @@ func (api *API) processingSaveFormAttempt(ctx context.Context, conn *app.WebConn return res, nil } -func (api *API) reporting(ctx context.Context, conn *app.WebConn, req *model.WebSocketRequest) (map[string]interface{}, model.AppError) { +func (api *API) reporting(ctx context.Context, conn *app.WebConn, req *model.WebSocketRequest) (map[string]any, model.AppError) { var attemptId, agentId float64 var ok bool var nextDistributeAt *int64 @@ -184,14 +184,29 @@ func (api *API) reporting(ctx context.Context, conn *app.WebConn, req *model.Web agentId, _ = req.Data["agent_id"].(float64) - err := api.ctrl.ReportingAttempt(conn.GetSession(), int64(attemptId), status, description, nextDistributeAt, expire, - nil, display, int32(agentId), exclDes, waitBetweenRetries, onlyComm) + draft, _ := req.Get("draft").(bool) + + err := api.ctrl.ReportingAttempt( + conn.GetSession(), + int64(attemptId), + status, + description, + nextDistributeAt, + expire, + nil, + display, + int32(agentId), + exclDes, + waitBetweenRetries, + onlyComm, + draft, + ) + if err != nil { return nil, err } - res := make(map[string]interface{}) - return res, nil + return make(map[string]any), nil } func (api *API) memberDirect(ctx context.Context, conn *app.WebConn, req *model.WebSocketRequest) (map[string]interface{}, model.AppError) {