合并main分支
This commit is contained in:
commit
d150e95f19
1240
api/cast/cast.pb.go
1240
api/cast/cast.pb.go
File diff suppressed because it is too large
Load Diff
@ -3236,6 +3236,8 @@ func (m *UpdateStatusReq) validate(all bool) error {
|
|||||||
|
|
||||||
// no validation rules for ConfirmFailType
|
// no validation rules for ConfirmFailType
|
||||||
|
|
||||||
|
// no validation rules for ApprovalTime
|
||||||
|
|
||||||
if len(errors) > 0 {
|
if len(errors) > 0 {
|
||||||
return UpdateStatusReqMultiError(errors)
|
return UpdateStatusReqMultiError(errors)
|
||||||
}
|
}
|
||||||
@ -16493,6 +16495,14 @@ func (m *MediaMetricsDailyItem) validate(all bool) error {
|
|||||||
|
|
||||||
// no validation rules for ImageCount
|
// no validation rules for ImageCount
|
||||||
|
|
||||||
|
// no validation rules for ProfileKey
|
||||||
|
|
||||||
|
// no validation rules for IsSuccess
|
||||||
|
|
||||||
|
// no validation rules for FailReason
|
||||||
|
|
||||||
|
// no validation rules for FailType
|
||||||
|
|
||||||
if len(errors) > 0 {
|
if len(errors) > 0 {
|
||||||
return MediaMetricsDailyItemMultiError(errors)
|
return MediaMetricsDailyItemMultiError(errors)
|
||||||
}
|
}
|
||||||
@ -16865,6 +16875,16 @@ func (m *WorkMetricsDailyItem) validate(all bool) error {
|
|||||||
|
|
||||||
// no validation rules for SharesCount
|
// no validation rules for SharesCount
|
||||||
|
|
||||||
|
// no validation rules for PublishMediaID
|
||||||
|
|
||||||
|
// no validation rules for ProfileKey
|
||||||
|
|
||||||
|
// no validation rules for IsSuccess
|
||||||
|
|
||||||
|
// no validation rules for FailReason
|
||||||
|
|
||||||
|
// no validation rules for FailType
|
||||||
|
|
||||||
if len(errors) > 0 {
|
if len(errors) > 0 {
|
||||||
return WorkMetricsDailyItemMultiError(errors)
|
return WorkMetricsDailyItemMultiError(errors)
|
||||||
}
|
}
|
||||||
@ -17933,6 +17953,792 @@ var _ interface {
|
|||||||
ErrorName() string
|
ErrorName() string
|
||||||
} = ListWorkPlatformInfoRespValidationError{}
|
} = ListWorkPlatformInfoRespValidationError{}
|
||||||
|
|
||||||
|
// Validate checks the field values on ListMediaMetricsDailyReq with the rules
|
||||||
|
// defined in the proto definition for this message. If any rules are
|
||||||
|
// violated, the first error encountered is returned, or nil if there are no violations.
|
||||||
|
func (m *ListMediaMetricsDailyReq) Validate() error {
|
||||||
|
return m.validate(false)
|
||||||
|
}
|
||||||
|
|
||||||
|
// ValidateAll checks the field values on ListMediaMetricsDailyReq with the
|
||||||
|
// rules defined in the proto definition for this message. If any rules are
|
||||||
|
// violated, the result is a list of violation errors wrapped in
|
||||||
|
// ListMediaMetricsDailyReqMultiError, or nil if none found.
|
||||||
|
func (m *ListMediaMetricsDailyReq) ValidateAll() error {
|
||||||
|
return m.validate(true)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *ListMediaMetricsDailyReq) validate(all bool) error {
|
||||||
|
if m == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
var errors []error
|
||||||
|
|
||||||
|
// no validation rules for IsSuccess
|
||||||
|
|
||||||
|
// no validation rules for FailType
|
||||||
|
|
||||||
|
// no validation rules for Page
|
||||||
|
|
||||||
|
// no validation rules for PageSize
|
||||||
|
|
||||||
|
// no validation rules for Date
|
||||||
|
|
||||||
|
if len(errors) > 0 {
|
||||||
|
return ListMediaMetricsDailyReqMultiError(errors)
|
||||||
|
}
|
||||||
|
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
// ListMediaMetricsDailyReqMultiError is an error wrapping multiple validation
|
||||||
|
// errors returned by ListMediaMetricsDailyReq.ValidateAll() if the designated
|
||||||
|
// constraints aren't met.
|
||||||
|
type ListMediaMetricsDailyReqMultiError []error
|
||||||
|
|
||||||
|
// Error returns a concatenation of all the error messages it wraps.
|
||||||
|
func (m ListMediaMetricsDailyReqMultiError) Error() string {
|
||||||
|
msgs := make([]string, 0, len(m))
|
||||||
|
for _, err := range m {
|
||||||
|
msgs = append(msgs, err.Error())
|
||||||
|
}
|
||||||
|
return strings.Join(msgs, "; ")
|
||||||
|
}
|
||||||
|
|
||||||
|
// AllErrors returns a list of validation violation errors.
|
||||||
|
func (m ListMediaMetricsDailyReqMultiError) AllErrors() []error { return m }
|
||||||
|
|
||||||
|
// ListMediaMetricsDailyReqValidationError is the validation error returned by
|
||||||
|
// ListMediaMetricsDailyReq.Validate if the designated constraints aren't met.
|
||||||
|
type ListMediaMetricsDailyReqValidationError struct {
|
||||||
|
field string
|
||||||
|
reason string
|
||||||
|
cause error
|
||||||
|
key bool
|
||||||
|
}
|
||||||
|
|
||||||
|
// Field function returns field value.
|
||||||
|
func (e ListMediaMetricsDailyReqValidationError) Field() string { return e.field }
|
||||||
|
|
||||||
|
// Reason function returns reason value.
|
||||||
|
func (e ListMediaMetricsDailyReqValidationError) Reason() string { return e.reason }
|
||||||
|
|
||||||
|
// Cause function returns cause value.
|
||||||
|
func (e ListMediaMetricsDailyReqValidationError) Cause() error { return e.cause }
|
||||||
|
|
||||||
|
// Key function returns key value.
|
||||||
|
func (e ListMediaMetricsDailyReqValidationError) Key() bool { return e.key }
|
||||||
|
|
||||||
|
// ErrorName returns error name.
|
||||||
|
func (e ListMediaMetricsDailyReqValidationError) ErrorName() string {
|
||||||
|
return "ListMediaMetricsDailyReqValidationError"
|
||||||
|
}
|
||||||
|
|
||||||
|
// Error satisfies the builtin error interface
|
||||||
|
func (e ListMediaMetricsDailyReqValidationError) Error() string {
|
||||||
|
cause := ""
|
||||||
|
if e.cause != nil {
|
||||||
|
cause = fmt.Sprintf(" | caused by: %v", e.cause)
|
||||||
|
}
|
||||||
|
|
||||||
|
key := ""
|
||||||
|
if e.key {
|
||||||
|
key = "key for "
|
||||||
|
}
|
||||||
|
|
||||||
|
return fmt.Sprintf(
|
||||||
|
"invalid %sListMediaMetricsDailyReq.%s: %s%s",
|
||||||
|
key,
|
||||||
|
e.field,
|
||||||
|
e.reason,
|
||||||
|
cause)
|
||||||
|
}
|
||||||
|
|
||||||
|
var _ error = ListMediaMetricsDailyReqValidationError{}
|
||||||
|
|
||||||
|
var _ interface {
|
||||||
|
Field() string
|
||||||
|
Reason() string
|
||||||
|
Key() bool
|
||||||
|
Cause() error
|
||||||
|
ErrorName() string
|
||||||
|
} = ListMediaMetricsDailyReqValidationError{}
|
||||||
|
|
||||||
|
// Validate checks the field values on MediaMetricsDailyInfo with the rules
|
||||||
|
// defined in the proto definition for this message. If any rules are
|
||||||
|
// violated, the first error encountered is returned, or nil if there are no violations.
|
||||||
|
func (m *MediaMetricsDailyInfo) Validate() error {
|
||||||
|
return m.validate(false)
|
||||||
|
}
|
||||||
|
|
||||||
|
// ValidateAll checks the field values on MediaMetricsDailyInfo with the rules
|
||||||
|
// defined in the proto definition for this message. If any rules are
|
||||||
|
// violated, the result is a list of violation errors wrapped in
|
||||||
|
// MediaMetricsDailyInfoMultiError, or nil if none found.
|
||||||
|
func (m *MediaMetricsDailyInfo) ValidateAll() error {
|
||||||
|
return m.validate(true)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *MediaMetricsDailyInfo) validate(all bool) error {
|
||||||
|
if m == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
var errors []error
|
||||||
|
|
||||||
|
// no validation rules for Uuid
|
||||||
|
|
||||||
|
// no validation rules for ArtistUuid
|
||||||
|
|
||||||
|
// no validation rules for MediaAccUserID
|
||||||
|
|
||||||
|
// no validation rules for MediaName
|
||||||
|
|
||||||
|
// no validation rules for ArtistName
|
||||||
|
|
||||||
|
// no validation rules for ArtistPhone
|
||||||
|
|
||||||
|
// no validation rules for PlatformID
|
||||||
|
|
||||||
|
// no validation rules for Date
|
||||||
|
|
||||||
|
// no validation rules for FansCount
|
||||||
|
|
||||||
|
// no validation rules for ViewsCount
|
||||||
|
|
||||||
|
// no validation rules for LikesCount
|
||||||
|
|
||||||
|
// no validation rules for CommentsCount
|
||||||
|
|
||||||
|
// no validation rules for SharesCount
|
||||||
|
|
||||||
|
// no validation rules for VideoCount
|
||||||
|
|
||||||
|
// no validation rules for ImageCount
|
||||||
|
|
||||||
|
// no validation rules for ProfileKey
|
||||||
|
|
||||||
|
// no validation rules for IsSuccess
|
||||||
|
|
||||||
|
// no validation rules for FailReason
|
||||||
|
|
||||||
|
// no validation rules for FailType
|
||||||
|
|
||||||
|
// no validation rules for CreatedAt
|
||||||
|
|
||||||
|
// no validation rules for UpdatedAt
|
||||||
|
|
||||||
|
if len(errors) > 0 {
|
||||||
|
return MediaMetricsDailyInfoMultiError(errors)
|
||||||
|
}
|
||||||
|
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
// MediaMetricsDailyInfoMultiError is an error wrapping multiple validation
|
||||||
|
// errors returned by MediaMetricsDailyInfo.ValidateAll() if the designated
|
||||||
|
// constraints aren't met.
|
||||||
|
type MediaMetricsDailyInfoMultiError []error
|
||||||
|
|
||||||
|
// Error returns a concatenation of all the error messages it wraps.
|
||||||
|
func (m MediaMetricsDailyInfoMultiError) Error() string {
|
||||||
|
msgs := make([]string, 0, len(m))
|
||||||
|
for _, err := range m {
|
||||||
|
msgs = append(msgs, err.Error())
|
||||||
|
}
|
||||||
|
return strings.Join(msgs, "; ")
|
||||||
|
}
|
||||||
|
|
||||||
|
// AllErrors returns a list of validation violation errors.
|
||||||
|
func (m MediaMetricsDailyInfoMultiError) AllErrors() []error { return m }
|
||||||
|
|
||||||
|
// MediaMetricsDailyInfoValidationError is the validation error returned by
|
||||||
|
// MediaMetricsDailyInfo.Validate if the designated constraints aren't met.
|
||||||
|
type MediaMetricsDailyInfoValidationError struct {
|
||||||
|
field string
|
||||||
|
reason string
|
||||||
|
cause error
|
||||||
|
key bool
|
||||||
|
}
|
||||||
|
|
||||||
|
// Field function returns field value.
|
||||||
|
func (e MediaMetricsDailyInfoValidationError) Field() string { return e.field }
|
||||||
|
|
||||||
|
// Reason function returns reason value.
|
||||||
|
func (e MediaMetricsDailyInfoValidationError) Reason() string { return e.reason }
|
||||||
|
|
||||||
|
// Cause function returns cause value.
|
||||||
|
func (e MediaMetricsDailyInfoValidationError) Cause() error { return e.cause }
|
||||||
|
|
||||||
|
// Key function returns key value.
|
||||||
|
func (e MediaMetricsDailyInfoValidationError) Key() bool { return e.key }
|
||||||
|
|
||||||
|
// ErrorName returns error name.
|
||||||
|
func (e MediaMetricsDailyInfoValidationError) ErrorName() string {
|
||||||
|
return "MediaMetricsDailyInfoValidationError"
|
||||||
|
}
|
||||||
|
|
||||||
|
// Error satisfies the builtin error interface
|
||||||
|
func (e MediaMetricsDailyInfoValidationError) Error() string {
|
||||||
|
cause := ""
|
||||||
|
if e.cause != nil {
|
||||||
|
cause = fmt.Sprintf(" | caused by: %v", e.cause)
|
||||||
|
}
|
||||||
|
|
||||||
|
key := ""
|
||||||
|
if e.key {
|
||||||
|
key = "key for "
|
||||||
|
}
|
||||||
|
|
||||||
|
return fmt.Sprintf(
|
||||||
|
"invalid %sMediaMetricsDailyInfo.%s: %s%s",
|
||||||
|
key,
|
||||||
|
e.field,
|
||||||
|
e.reason,
|
||||||
|
cause)
|
||||||
|
}
|
||||||
|
|
||||||
|
var _ error = MediaMetricsDailyInfoValidationError{}
|
||||||
|
|
||||||
|
var _ interface {
|
||||||
|
Field() string
|
||||||
|
Reason() string
|
||||||
|
Key() bool
|
||||||
|
Cause() error
|
||||||
|
ErrorName() string
|
||||||
|
} = MediaMetricsDailyInfoValidationError{}
|
||||||
|
|
||||||
|
// Validate checks the field values on ListMediaMetricsDailyResp with the rules
|
||||||
|
// defined in the proto definition for this message. If any rules are
|
||||||
|
// violated, the first error encountered is returned, or nil if there are no violations.
|
||||||
|
func (m *ListMediaMetricsDailyResp) Validate() error {
|
||||||
|
return m.validate(false)
|
||||||
|
}
|
||||||
|
|
||||||
|
// ValidateAll checks the field values on ListMediaMetricsDailyResp with the
|
||||||
|
// rules defined in the proto definition for this message. If any rules are
|
||||||
|
// violated, the result is a list of violation errors wrapped in
|
||||||
|
// ListMediaMetricsDailyRespMultiError, or nil if none found.
|
||||||
|
func (m *ListMediaMetricsDailyResp) ValidateAll() error {
|
||||||
|
return m.validate(true)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *ListMediaMetricsDailyResp) validate(all bool) error {
|
||||||
|
if m == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
var errors []error
|
||||||
|
|
||||||
|
for idx, item := range m.GetData() {
|
||||||
|
_, _ = idx, item
|
||||||
|
|
||||||
|
if all {
|
||||||
|
switch v := interface{}(item).(type) {
|
||||||
|
case interface{ ValidateAll() error }:
|
||||||
|
if err := v.ValidateAll(); err != nil {
|
||||||
|
errors = append(errors, ListMediaMetricsDailyRespValidationError{
|
||||||
|
field: fmt.Sprintf("Data[%v]", idx),
|
||||||
|
reason: "embedded message failed validation",
|
||||||
|
cause: err,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
case interface{ Validate() error }:
|
||||||
|
if err := v.Validate(); err != nil {
|
||||||
|
errors = append(errors, ListMediaMetricsDailyRespValidationError{
|
||||||
|
field: fmt.Sprintf("Data[%v]", idx),
|
||||||
|
reason: "embedded message failed validation",
|
||||||
|
cause: err,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else if v, ok := interface{}(item).(interface{ Validate() error }); ok {
|
||||||
|
if err := v.Validate(); err != nil {
|
||||||
|
return ListMediaMetricsDailyRespValidationError{
|
||||||
|
field: fmt.Sprintf("Data[%v]", idx),
|
||||||
|
reason: "embedded message failed validation",
|
||||||
|
cause: err,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
// no validation rules for Count
|
||||||
|
|
||||||
|
if len(errors) > 0 {
|
||||||
|
return ListMediaMetricsDailyRespMultiError(errors)
|
||||||
|
}
|
||||||
|
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
// ListMediaMetricsDailyRespMultiError is an error wrapping multiple validation
|
||||||
|
// errors returned by ListMediaMetricsDailyResp.ValidateAll() if the
|
||||||
|
// designated constraints aren't met.
|
||||||
|
type ListMediaMetricsDailyRespMultiError []error
|
||||||
|
|
||||||
|
// Error returns a concatenation of all the error messages it wraps.
|
||||||
|
func (m ListMediaMetricsDailyRespMultiError) Error() string {
|
||||||
|
msgs := make([]string, 0, len(m))
|
||||||
|
for _, err := range m {
|
||||||
|
msgs = append(msgs, err.Error())
|
||||||
|
}
|
||||||
|
return strings.Join(msgs, "; ")
|
||||||
|
}
|
||||||
|
|
||||||
|
// AllErrors returns a list of validation violation errors.
|
||||||
|
func (m ListMediaMetricsDailyRespMultiError) AllErrors() []error { return m }
|
||||||
|
|
||||||
|
// ListMediaMetricsDailyRespValidationError is the validation error returned by
|
||||||
|
// ListMediaMetricsDailyResp.Validate if the designated constraints aren't met.
|
||||||
|
type ListMediaMetricsDailyRespValidationError struct {
|
||||||
|
field string
|
||||||
|
reason string
|
||||||
|
cause error
|
||||||
|
key bool
|
||||||
|
}
|
||||||
|
|
||||||
|
// Field function returns field value.
|
||||||
|
func (e ListMediaMetricsDailyRespValidationError) Field() string { return e.field }
|
||||||
|
|
||||||
|
// Reason function returns reason value.
|
||||||
|
func (e ListMediaMetricsDailyRespValidationError) Reason() string { return e.reason }
|
||||||
|
|
||||||
|
// Cause function returns cause value.
|
||||||
|
func (e ListMediaMetricsDailyRespValidationError) Cause() error { return e.cause }
|
||||||
|
|
||||||
|
// Key function returns key value.
|
||||||
|
func (e ListMediaMetricsDailyRespValidationError) Key() bool { return e.key }
|
||||||
|
|
||||||
|
// ErrorName returns error name.
|
||||||
|
func (e ListMediaMetricsDailyRespValidationError) ErrorName() string {
|
||||||
|
return "ListMediaMetricsDailyRespValidationError"
|
||||||
|
}
|
||||||
|
|
||||||
|
// Error satisfies the builtin error interface
|
||||||
|
func (e ListMediaMetricsDailyRespValidationError) Error() string {
|
||||||
|
cause := ""
|
||||||
|
if e.cause != nil {
|
||||||
|
cause = fmt.Sprintf(" | caused by: %v", e.cause)
|
||||||
|
}
|
||||||
|
|
||||||
|
key := ""
|
||||||
|
if e.key {
|
||||||
|
key = "key for "
|
||||||
|
}
|
||||||
|
|
||||||
|
return fmt.Sprintf(
|
||||||
|
"invalid %sListMediaMetricsDailyResp.%s: %s%s",
|
||||||
|
key,
|
||||||
|
e.field,
|
||||||
|
e.reason,
|
||||||
|
cause)
|
||||||
|
}
|
||||||
|
|
||||||
|
var _ error = ListMediaMetricsDailyRespValidationError{}
|
||||||
|
|
||||||
|
var _ interface {
|
||||||
|
Field() string
|
||||||
|
Reason() string
|
||||||
|
Key() bool
|
||||||
|
Cause() error
|
||||||
|
ErrorName() string
|
||||||
|
} = ListMediaMetricsDailyRespValidationError{}
|
||||||
|
|
||||||
|
// Validate checks the field values on ListWorkMetricsDailyReq with the rules
|
||||||
|
// defined in the proto definition for this message. If any rules are
|
||||||
|
// violated, the first error encountered is returned, or nil if there are no violations.
|
||||||
|
func (m *ListWorkMetricsDailyReq) Validate() error {
|
||||||
|
return m.validate(false)
|
||||||
|
}
|
||||||
|
|
||||||
|
// ValidateAll checks the field values on ListWorkMetricsDailyReq with the
|
||||||
|
// rules defined in the proto definition for this message. If any rules are
|
||||||
|
// violated, the result is a list of violation errors wrapped in
|
||||||
|
// ListWorkMetricsDailyReqMultiError, or nil if none found.
|
||||||
|
func (m *ListWorkMetricsDailyReq) ValidateAll() error {
|
||||||
|
return m.validate(true)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *ListWorkMetricsDailyReq) validate(all bool) error {
|
||||||
|
if m == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
var errors []error
|
||||||
|
|
||||||
|
// no validation rules for IsSuccess
|
||||||
|
|
||||||
|
// no validation rules for FailType
|
||||||
|
|
||||||
|
// no validation rules for Page
|
||||||
|
|
||||||
|
// no validation rules for PageSize
|
||||||
|
|
||||||
|
// no validation rules for Date
|
||||||
|
|
||||||
|
if len(errors) > 0 {
|
||||||
|
return ListWorkMetricsDailyReqMultiError(errors)
|
||||||
|
}
|
||||||
|
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
// ListWorkMetricsDailyReqMultiError is an error wrapping multiple validation
|
||||||
|
// errors returned by ListWorkMetricsDailyReq.ValidateAll() if the designated
|
||||||
|
// constraints aren't met.
|
||||||
|
type ListWorkMetricsDailyReqMultiError []error
|
||||||
|
|
||||||
|
// Error returns a concatenation of all the error messages it wraps.
|
||||||
|
func (m ListWorkMetricsDailyReqMultiError) Error() string {
|
||||||
|
msgs := make([]string, 0, len(m))
|
||||||
|
for _, err := range m {
|
||||||
|
msgs = append(msgs, err.Error())
|
||||||
|
}
|
||||||
|
return strings.Join(msgs, "; ")
|
||||||
|
}
|
||||||
|
|
||||||
|
// AllErrors returns a list of validation violation errors.
|
||||||
|
func (m ListWorkMetricsDailyReqMultiError) AllErrors() []error { return m }
|
||||||
|
|
||||||
|
// ListWorkMetricsDailyReqValidationError is the validation error returned by
|
||||||
|
// ListWorkMetricsDailyReq.Validate if the designated constraints aren't met.
|
||||||
|
type ListWorkMetricsDailyReqValidationError struct {
|
||||||
|
field string
|
||||||
|
reason string
|
||||||
|
cause error
|
||||||
|
key bool
|
||||||
|
}
|
||||||
|
|
||||||
|
// Field function returns field value.
|
||||||
|
func (e ListWorkMetricsDailyReqValidationError) Field() string { return e.field }
|
||||||
|
|
||||||
|
// Reason function returns reason value.
|
||||||
|
func (e ListWorkMetricsDailyReqValidationError) Reason() string { return e.reason }
|
||||||
|
|
||||||
|
// Cause function returns cause value.
|
||||||
|
func (e ListWorkMetricsDailyReqValidationError) Cause() error { return e.cause }
|
||||||
|
|
||||||
|
// Key function returns key value.
|
||||||
|
func (e ListWorkMetricsDailyReqValidationError) Key() bool { return e.key }
|
||||||
|
|
||||||
|
// ErrorName returns error name.
|
||||||
|
func (e ListWorkMetricsDailyReqValidationError) ErrorName() string {
|
||||||
|
return "ListWorkMetricsDailyReqValidationError"
|
||||||
|
}
|
||||||
|
|
||||||
|
// Error satisfies the builtin error interface
|
||||||
|
func (e ListWorkMetricsDailyReqValidationError) Error() string {
|
||||||
|
cause := ""
|
||||||
|
if e.cause != nil {
|
||||||
|
cause = fmt.Sprintf(" | caused by: %v", e.cause)
|
||||||
|
}
|
||||||
|
|
||||||
|
key := ""
|
||||||
|
if e.key {
|
||||||
|
key = "key for "
|
||||||
|
}
|
||||||
|
|
||||||
|
return fmt.Sprintf(
|
||||||
|
"invalid %sListWorkMetricsDailyReq.%s: %s%s",
|
||||||
|
key,
|
||||||
|
e.field,
|
||||||
|
e.reason,
|
||||||
|
cause)
|
||||||
|
}
|
||||||
|
|
||||||
|
var _ error = ListWorkMetricsDailyReqValidationError{}
|
||||||
|
|
||||||
|
var _ interface {
|
||||||
|
Field() string
|
||||||
|
Reason() string
|
||||||
|
Key() bool
|
||||||
|
Cause() error
|
||||||
|
ErrorName() string
|
||||||
|
} = ListWorkMetricsDailyReqValidationError{}
|
||||||
|
|
||||||
|
// Validate checks the field values on WorkMetricsDailyInfo with the rules
|
||||||
|
// defined in the proto definition for this message. If any rules are
|
||||||
|
// violated, the first error encountered is returned, or nil if there are no violations.
|
||||||
|
func (m *WorkMetricsDailyInfo) Validate() error {
|
||||||
|
return m.validate(false)
|
||||||
|
}
|
||||||
|
|
||||||
|
// ValidateAll checks the field values on WorkMetricsDailyInfo with the rules
|
||||||
|
// defined in the proto definition for this message. If any rules are
|
||||||
|
// violated, the result is a list of violation errors wrapped in
|
||||||
|
// WorkMetricsDailyInfoMultiError, or nil if none found.
|
||||||
|
func (m *WorkMetricsDailyInfo) ValidateAll() error {
|
||||||
|
return m.validate(true)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *WorkMetricsDailyInfo) validate(all bool) error {
|
||||||
|
if m == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
var errors []error
|
||||||
|
|
||||||
|
// no validation rules for Uuid
|
||||||
|
|
||||||
|
// no validation rules for WorkUuid
|
||||||
|
|
||||||
|
// no validation rules for ArtistUuid
|
||||||
|
|
||||||
|
// no validation rules for MediaAccUserID
|
||||||
|
|
||||||
|
// no validation rules for MediaName
|
||||||
|
|
||||||
|
// no validation rules for ArtistName
|
||||||
|
|
||||||
|
// no validation rules for ArtistPhone
|
||||||
|
|
||||||
|
// no validation rules for PlatformID
|
||||||
|
|
||||||
|
// no validation rules for Date
|
||||||
|
|
||||||
|
// no validation rules for ViewsCount
|
||||||
|
|
||||||
|
// no validation rules for LikesCount
|
||||||
|
|
||||||
|
// no validation rules for CommentsCount
|
||||||
|
|
||||||
|
// no validation rules for SharesCount
|
||||||
|
|
||||||
|
// no validation rules for PublishMediaID
|
||||||
|
|
||||||
|
// no validation rules for ProfileKey
|
||||||
|
|
||||||
|
// no validation rules for IsSuccess
|
||||||
|
|
||||||
|
// no validation rules for FailReason
|
||||||
|
|
||||||
|
// no validation rules for FailType
|
||||||
|
|
||||||
|
// no validation rules for CreatedAt
|
||||||
|
|
||||||
|
// no validation rules for UpdatedAt
|
||||||
|
|
||||||
|
if len(errors) > 0 {
|
||||||
|
return WorkMetricsDailyInfoMultiError(errors)
|
||||||
|
}
|
||||||
|
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
// WorkMetricsDailyInfoMultiError is an error wrapping multiple validation
|
||||||
|
// errors returned by WorkMetricsDailyInfo.ValidateAll() if the designated
|
||||||
|
// constraints aren't met.
|
||||||
|
type WorkMetricsDailyInfoMultiError []error
|
||||||
|
|
||||||
|
// Error returns a concatenation of all the error messages it wraps.
|
||||||
|
func (m WorkMetricsDailyInfoMultiError) Error() string {
|
||||||
|
msgs := make([]string, 0, len(m))
|
||||||
|
for _, err := range m {
|
||||||
|
msgs = append(msgs, err.Error())
|
||||||
|
}
|
||||||
|
return strings.Join(msgs, "; ")
|
||||||
|
}
|
||||||
|
|
||||||
|
// AllErrors returns a list of validation violation errors.
|
||||||
|
func (m WorkMetricsDailyInfoMultiError) AllErrors() []error { return m }
|
||||||
|
|
||||||
|
// WorkMetricsDailyInfoValidationError is the validation error returned by
|
||||||
|
// WorkMetricsDailyInfo.Validate if the designated constraints aren't met.
|
||||||
|
type WorkMetricsDailyInfoValidationError struct {
|
||||||
|
field string
|
||||||
|
reason string
|
||||||
|
cause error
|
||||||
|
key bool
|
||||||
|
}
|
||||||
|
|
||||||
|
// Field function returns field value.
|
||||||
|
func (e WorkMetricsDailyInfoValidationError) Field() string { return e.field }
|
||||||
|
|
||||||
|
// Reason function returns reason value.
|
||||||
|
func (e WorkMetricsDailyInfoValidationError) Reason() string { return e.reason }
|
||||||
|
|
||||||
|
// Cause function returns cause value.
|
||||||
|
func (e WorkMetricsDailyInfoValidationError) Cause() error { return e.cause }
|
||||||
|
|
||||||
|
// Key function returns key value.
|
||||||
|
func (e WorkMetricsDailyInfoValidationError) Key() bool { return e.key }
|
||||||
|
|
||||||
|
// ErrorName returns error name.
|
||||||
|
func (e WorkMetricsDailyInfoValidationError) ErrorName() string {
|
||||||
|
return "WorkMetricsDailyInfoValidationError"
|
||||||
|
}
|
||||||
|
|
||||||
|
// Error satisfies the builtin error interface
|
||||||
|
func (e WorkMetricsDailyInfoValidationError) Error() string {
|
||||||
|
cause := ""
|
||||||
|
if e.cause != nil {
|
||||||
|
cause = fmt.Sprintf(" | caused by: %v", e.cause)
|
||||||
|
}
|
||||||
|
|
||||||
|
key := ""
|
||||||
|
if e.key {
|
||||||
|
key = "key for "
|
||||||
|
}
|
||||||
|
|
||||||
|
return fmt.Sprintf(
|
||||||
|
"invalid %sWorkMetricsDailyInfo.%s: %s%s",
|
||||||
|
key,
|
||||||
|
e.field,
|
||||||
|
e.reason,
|
||||||
|
cause)
|
||||||
|
}
|
||||||
|
|
||||||
|
var _ error = WorkMetricsDailyInfoValidationError{}
|
||||||
|
|
||||||
|
var _ interface {
|
||||||
|
Field() string
|
||||||
|
Reason() string
|
||||||
|
Key() bool
|
||||||
|
Cause() error
|
||||||
|
ErrorName() string
|
||||||
|
} = WorkMetricsDailyInfoValidationError{}
|
||||||
|
|
||||||
|
// Validate checks the field values on ListWorkMetricsDailyResp with the rules
|
||||||
|
// defined in the proto definition for this message. If any rules are
|
||||||
|
// violated, the first error encountered is returned, or nil if there are no violations.
|
||||||
|
func (m *ListWorkMetricsDailyResp) Validate() error {
|
||||||
|
return m.validate(false)
|
||||||
|
}
|
||||||
|
|
||||||
|
// ValidateAll checks the field values on ListWorkMetricsDailyResp with the
|
||||||
|
// rules defined in the proto definition for this message. If any rules are
|
||||||
|
// violated, the result is a list of violation errors wrapped in
|
||||||
|
// ListWorkMetricsDailyRespMultiError, or nil if none found.
|
||||||
|
func (m *ListWorkMetricsDailyResp) ValidateAll() error {
|
||||||
|
return m.validate(true)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *ListWorkMetricsDailyResp) validate(all bool) error {
|
||||||
|
if m == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
var errors []error
|
||||||
|
|
||||||
|
for idx, item := range m.GetData() {
|
||||||
|
_, _ = idx, item
|
||||||
|
|
||||||
|
if all {
|
||||||
|
switch v := interface{}(item).(type) {
|
||||||
|
case interface{ ValidateAll() error }:
|
||||||
|
if err := v.ValidateAll(); err != nil {
|
||||||
|
errors = append(errors, ListWorkMetricsDailyRespValidationError{
|
||||||
|
field: fmt.Sprintf("Data[%v]", idx),
|
||||||
|
reason: "embedded message failed validation",
|
||||||
|
cause: err,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
case interface{ Validate() error }:
|
||||||
|
if err := v.Validate(); err != nil {
|
||||||
|
errors = append(errors, ListWorkMetricsDailyRespValidationError{
|
||||||
|
field: fmt.Sprintf("Data[%v]", idx),
|
||||||
|
reason: "embedded message failed validation",
|
||||||
|
cause: err,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else if v, ok := interface{}(item).(interface{ Validate() error }); ok {
|
||||||
|
if err := v.Validate(); err != nil {
|
||||||
|
return ListWorkMetricsDailyRespValidationError{
|
||||||
|
field: fmt.Sprintf("Data[%v]", idx),
|
||||||
|
reason: "embedded message failed validation",
|
||||||
|
cause: err,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
// no validation rules for Count
|
||||||
|
|
||||||
|
if len(errors) > 0 {
|
||||||
|
return ListWorkMetricsDailyRespMultiError(errors)
|
||||||
|
}
|
||||||
|
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
||||||
|
// ListWorkMetricsDailyRespMultiError is an error wrapping multiple validation
|
||||||
|
// errors returned by ListWorkMetricsDailyResp.ValidateAll() if the designated
|
||||||
|
// constraints aren't met.
|
||||||
|
type ListWorkMetricsDailyRespMultiError []error
|
||||||
|
|
||||||
|
// Error returns a concatenation of all the error messages it wraps.
|
||||||
|
func (m ListWorkMetricsDailyRespMultiError) Error() string {
|
||||||
|
msgs := make([]string, 0, len(m))
|
||||||
|
for _, err := range m {
|
||||||
|
msgs = append(msgs, err.Error())
|
||||||
|
}
|
||||||
|
return strings.Join(msgs, "; ")
|
||||||
|
}
|
||||||
|
|
||||||
|
// AllErrors returns a list of validation violation errors.
|
||||||
|
func (m ListWorkMetricsDailyRespMultiError) AllErrors() []error { return m }
|
||||||
|
|
||||||
|
// ListWorkMetricsDailyRespValidationError is the validation error returned by
|
||||||
|
// ListWorkMetricsDailyResp.Validate if the designated constraints aren't met.
|
||||||
|
type ListWorkMetricsDailyRespValidationError struct {
|
||||||
|
field string
|
||||||
|
reason string
|
||||||
|
cause error
|
||||||
|
key bool
|
||||||
|
}
|
||||||
|
|
||||||
|
// Field function returns field value.
|
||||||
|
func (e ListWorkMetricsDailyRespValidationError) Field() string { return e.field }
|
||||||
|
|
||||||
|
// Reason function returns reason value.
|
||||||
|
func (e ListWorkMetricsDailyRespValidationError) Reason() string { return e.reason }
|
||||||
|
|
||||||
|
// Cause function returns cause value.
|
||||||
|
func (e ListWorkMetricsDailyRespValidationError) Cause() error { return e.cause }
|
||||||
|
|
||||||
|
// Key function returns key value.
|
||||||
|
func (e ListWorkMetricsDailyRespValidationError) Key() bool { return e.key }
|
||||||
|
|
||||||
|
// ErrorName returns error name.
|
||||||
|
func (e ListWorkMetricsDailyRespValidationError) ErrorName() string {
|
||||||
|
return "ListWorkMetricsDailyRespValidationError"
|
||||||
|
}
|
||||||
|
|
||||||
|
// Error satisfies the builtin error interface
|
||||||
|
func (e ListWorkMetricsDailyRespValidationError) Error() string {
|
||||||
|
cause := ""
|
||||||
|
if e.cause != nil {
|
||||||
|
cause = fmt.Sprintf(" | caused by: %v", e.cause)
|
||||||
|
}
|
||||||
|
|
||||||
|
key := ""
|
||||||
|
if e.key {
|
||||||
|
key = "key for "
|
||||||
|
}
|
||||||
|
|
||||||
|
return fmt.Sprintf(
|
||||||
|
"invalid %sListWorkMetricsDailyResp.%s: %s%s",
|
||||||
|
key,
|
||||||
|
e.field,
|
||||||
|
e.reason,
|
||||||
|
cause)
|
||||||
|
}
|
||||||
|
|
||||||
|
var _ error = ListWorkMetricsDailyRespValidationError{}
|
||||||
|
|
||||||
|
var _ interface {
|
||||||
|
Field() string
|
||||||
|
Reason() string
|
||||||
|
Key() bool
|
||||||
|
Cause() error
|
||||||
|
ErrorName() string
|
||||||
|
} = ListWorkMetricsDailyRespValidationError{}
|
||||||
|
|
||||||
// Validate checks the field values on WorkListResp_Info with the rules defined
|
// Validate checks the field values on WorkListResp_Info with the rules defined
|
||||||
// in the proto definition for this message. If any rules are violated, the
|
// in the proto definition for this message. If any rules are violated, the
|
||||||
// first error encountered is returned, or nil if there are no violations.
|
// first error encountered is returned, or nil if there are no violations.
|
||||||
|
|||||||
@ -97,6 +97,9 @@ type CastClient interface {
|
|||||||
// 日级指标批量更新接口
|
// 日级指标批量更新接口
|
||||||
UpsertMediaMetricsDailyBatch(ctx context.Context, in *UpsertMediaMetricsDailyBatchReq, opts ...grpc_go.CallOption) (*UpsertMediaMetricsDailyBatchResp, common.ErrorWithAttachment)
|
UpsertMediaMetricsDailyBatch(ctx context.Context, in *UpsertMediaMetricsDailyBatchReq, opts ...grpc_go.CallOption) (*UpsertMediaMetricsDailyBatchResp, common.ErrorWithAttachment)
|
||||||
UpsertWorkMetricsDailyBatch(ctx context.Context, in *UpsertWorkMetricsDailyBatchReq, opts ...grpc_go.CallOption) (*UpsertWorkMetricsDailyBatchResp, common.ErrorWithAttachment)
|
UpsertWorkMetricsDailyBatch(ctx context.Context, in *UpsertWorkMetricsDailyBatchReq, opts ...grpc_go.CallOption) (*UpsertWorkMetricsDailyBatchResp, common.ErrorWithAttachment)
|
||||||
|
// 日级指标查询接口
|
||||||
|
ListMediaMetricsDaily(ctx context.Context, in *ListMediaMetricsDailyReq, opts ...grpc_go.CallOption) (*ListMediaMetricsDailyResp, common.ErrorWithAttachment)
|
||||||
|
ListWorkMetricsDaily(ctx context.Context, in *ListWorkMetricsDailyReq, opts ...grpc_go.CallOption) (*ListWorkMetricsDailyResp, common.ErrorWithAttachment)
|
||||||
// 艺人AyrShare信息相关接口
|
// 艺人AyrShare信息相关接口
|
||||||
GetArtistAyrShareInfo(ctx context.Context, in *GetArtistAyrShareInfoReq, opts ...grpc_go.CallOption) (*GetArtistAyrShareInfoResp, common.ErrorWithAttachment)
|
GetArtistAyrShareInfo(ctx context.Context, in *GetArtistAyrShareInfoReq, opts ...grpc_go.CallOption) (*GetArtistAyrShareInfoResp, common.ErrorWithAttachment)
|
||||||
// 作品平台信息相关接口
|
// 作品平台信息相关接口
|
||||||
@ -168,6 +171,8 @@ type CastClientImpl struct {
|
|||||||
TobeConfirmedList func(ctx context.Context, in *TobeConfirmedListReq) (*TobeConfirmedListResp, error)
|
TobeConfirmedList func(ctx context.Context, in *TobeConfirmedListReq) (*TobeConfirmedListResp, error)
|
||||||
UpsertMediaMetricsDailyBatch func(ctx context.Context, in *UpsertMediaMetricsDailyBatchReq) (*UpsertMediaMetricsDailyBatchResp, error)
|
UpsertMediaMetricsDailyBatch func(ctx context.Context, in *UpsertMediaMetricsDailyBatchReq) (*UpsertMediaMetricsDailyBatchResp, error)
|
||||||
UpsertWorkMetricsDailyBatch func(ctx context.Context, in *UpsertWorkMetricsDailyBatchReq) (*UpsertWorkMetricsDailyBatchResp, error)
|
UpsertWorkMetricsDailyBatch func(ctx context.Context, in *UpsertWorkMetricsDailyBatchReq) (*UpsertWorkMetricsDailyBatchResp, error)
|
||||||
|
ListMediaMetricsDaily func(ctx context.Context, in *ListMediaMetricsDailyReq) (*ListMediaMetricsDailyResp, error)
|
||||||
|
ListWorkMetricsDaily func(ctx context.Context, in *ListWorkMetricsDailyReq) (*ListWorkMetricsDailyResp, error)
|
||||||
GetArtistAyrShareInfo func(ctx context.Context, in *GetArtistAyrShareInfoReq) (*GetArtistAyrShareInfoResp, error)
|
GetArtistAyrShareInfo func(ctx context.Context, in *GetArtistAyrShareInfoReq) (*GetArtistAyrShareInfoResp, error)
|
||||||
ListWorkPlatformInfo func(ctx context.Context, in *ListWorkPlatformInfoReq) (*ListWorkPlatformInfoResp, error)
|
ListWorkPlatformInfo func(ctx context.Context, in *ListWorkPlatformInfoReq) (*ListWorkPlatformInfoResp, error)
|
||||||
}
|
}
|
||||||
@ -544,6 +549,18 @@ func (c *castClient) UpsertWorkMetricsDailyBatch(ctx context.Context, in *Upsert
|
|||||||
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/UpsertWorkMetricsDailyBatch", in, out)
|
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/UpsertWorkMetricsDailyBatch", in, out)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (c *castClient) ListMediaMetricsDaily(ctx context.Context, in *ListMediaMetricsDailyReq, opts ...grpc_go.CallOption) (*ListMediaMetricsDailyResp, common.ErrorWithAttachment) {
|
||||||
|
out := new(ListMediaMetricsDailyResp)
|
||||||
|
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
|
||||||
|
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/ListMediaMetricsDaily", in, out)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (c *castClient) ListWorkMetricsDaily(ctx context.Context, in *ListWorkMetricsDailyReq, opts ...grpc_go.CallOption) (*ListWorkMetricsDailyResp, common.ErrorWithAttachment) {
|
||||||
|
out := new(ListWorkMetricsDailyResp)
|
||||||
|
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
|
||||||
|
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/ListWorkMetricsDaily", in, out)
|
||||||
|
}
|
||||||
|
|
||||||
func (c *castClient) GetArtistAyrShareInfo(ctx context.Context, in *GetArtistAyrShareInfoReq, opts ...grpc_go.CallOption) (*GetArtistAyrShareInfoResp, common.ErrorWithAttachment) {
|
func (c *castClient) GetArtistAyrShareInfo(ctx context.Context, in *GetArtistAyrShareInfoReq, opts ...grpc_go.CallOption) (*GetArtistAyrShareInfoResp, common.ErrorWithAttachment) {
|
||||||
out := new(GetArtistAyrShareInfoResp)
|
out := new(GetArtistAyrShareInfoResp)
|
||||||
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
|
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
|
||||||
@ -628,6 +645,9 @@ type CastServer interface {
|
|||||||
// 日级指标批量更新接口
|
// 日级指标批量更新接口
|
||||||
UpsertMediaMetricsDailyBatch(context.Context, *UpsertMediaMetricsDailyBatchReq) (*UpsertMediaMetricsDailyBatchResp, error)
|
UpsertMediaMetricsDailyBatch(context.Context, *UpsertMediaMetricsDailyBatchReq) (*UpsertMediaMetricsDailyBatchResp, error)
|
||||||
UpsertWorkMetricsDailyBatch(context.Context, *UpsertWorkMetricsDailyBatchReq) (*UpsertWorkMetricsDailyBatchResp, error)
|
UpsertWorkMetricsDailyBatch(context.Context, *UpsertWorkMetricsDailyBatchReq) (*UpsertWorkMetricsDailyBatchResp, error)
|
||||||
|
// 日级指标查询接口
|
||||||
|
ListMediaMetricsDaily(context.Context, *ListMediaMetricsDailyReq) (*ListMediaMetricsDailyResp, error)
|
||||||
|
ListWorkMetricsDaily(context.Context, *ListWorkMetricsDailyReq) (*ListWorkMetricsDailyResp, error)
|
||||||
// 艺人AyrShare信息相关接口
|
// 艺人AyrShare信息相关接口
|
||||||
GetArtistAyrShareInfo(context.Context, *GetArtistAyrShareInfoReq) (*GetArtistAyrShareInfoResp, error)
|
GetArtistAyrShareInfo(context.Context, *GetArtistAyrShareInfoReq) (*GetArtistAyrShareInfoResp, error)
|
||||||
// 作品平台信息相关接口
|
// 作品平台信息相关接口
|
||||||
@ -820,6 +840,12 @@ func (UnimplementedCastServer) UpsertMediaMetricsDailyBatch(context.Context, *Up
|
|||||||
func (UnimplementedCastServer) UpsertWorkMetricsDailyBatch(context.Context, *UpsertWorkMetricsDailyBatchReq) (*UpsertWorkMetricsDailyBatchResp, error) {
|
func (UnimplementedCastServer) UpsertWorkMetricsDailyBatch(context.Context, *UpsertWorkMetricsDailyBatchReq) (*UpsertWorkMetricsDailyBatchResp, error) {
|
||||||
return nil, status.Errorf(codes.Unimplemented, "method UpsertWorkMetricsDailyBatch not implemented")
|
return nil, status.Errorf(codes.Unimplemented, "method UpsertWorkMetricsDailyBatch not implemented")
|
||||||
}
|
}
|
||||||
|
func (UnimplementedCastServer) ListMediaMetricsDaily(context.Context, *ListMediaMetricsDailyReq) (*ListMediaMetricsDailyResp, error) {
|
||||||
|
return nil, status.Errorf(codes.Unimplemented, "method ListMediaMetricsDaily not implemented")
|
||||||
|
}
|
||||||
|
func (UnimplementedCastServer) ListWorkMetricsDaily(context.Context, *ListWorkMetricsDailyReq) (*ListWorkMetricsDailyResp, error) {
|
||||||
|
return nil, status.Errorf(codes.Unimplemented, "method ListWorkMetricsDaily not implemented")
|
||||||
|
}
|
||||||
func (UnimplementedCastServer) GetArtistAyrShareInfo(context.Context, *GetArtistAyrShareInfoReq) (*GetArtistAyrShareInfoResp, error) {
|
func (UnimplementedCastServer) GetArtistAyrShareInfo(context.Context, *GetArtistAyrShareInfoReq) (*GetArtistAyrShareInfoResp, error) {
|
||||||
return nil, status.Errorf(codes.Unimplemented, "method GetArtistAyrShareInfo not implemented")
|
return nil, status.Errorf(codes.Unimplemented, "method GetArtistAyrShareInfo not implemented")
|
||||||
}
|
}
|
||||||
@ -2594,6 +2620,64 @@ func _Cast_UpsertWorkMetricsDailyBatch_Handler(srv interface{}, ctx context.Cont
|
|||||||
return interceptor(ctx, in, info, handler)
|
return interceptor(ctx, in, info, handler)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func _Cast_ListMediaMetricsDaily_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
|
||||||
|
in := new(ListMediaMetricsDailyReq)
|
||||||
|
if err := dec(in); err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
base := srv.(dubbo3.Dubbo3GrpcService)
|
||||||
|
args := []interface{}{}
|
||||||
|
args = append(args, in)
|
||||||
|
md, _ := metadata.FromIncomingContext(ctx)
|
||||||
|
invAttachment := make(map[string]interface{}, len(md))
|
||||||
|
for k, v := range md {
|
||||||
|
invAttachment[k] = v
|
||||||
|
}
|
||||||
|
invo := invocation.NewRPCInvocation("ListMediaMetricsDaily", args, invAttachment)
|
||||||
|
if interceptor == nil {
|
||||||
|
result := base.XXX_GetProxyImpl().Invoke(ctx, invo)
|
||||||
|
return result, result.Error()
|
||||||
|
}
|
||||||
|
info := &grpc_go.UnaryServerInfo{
|
||||||
|
Server: srv,
|
||||||
|
FullMethod: ctx.Value("XXX_TRIPLE_GO_INTERFACE_NAME").(string),
|
||||||
|
}
|
||||||
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||||
|
result := base.XXX_GetProxyImpl().Invoke(ctx, invo)
|
||||||
|
return result, result.Error()
|
||||||
|
}
|
||||||
|
return interceptor(ctx, in, info, handler)
|
||||||
|
}
|
||||||
|
|
||||||
|
func _Cast_ListWorkMetricsDaily_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
|
||||||
|
in := new(ListWorkMetricsDailyReq)
|
||||||
|
if err := dec(in); err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
base := srv.(dubbo3.Dubbo3GrpcService)
|
||||||
|
args := []interface{}{}
|
||||||
|
args = append(args, in)
|
||||||
|
md, _ := metadata.FromIncomingContext(ctx)
|
||||||
|
invAttachment := make(map[string]interface{}, len(md))
|
||||||
|
for k, v := range md {
|
||||||
|
invAttachment[k] = v
|
||||||
|
}
|
||||||
|
invo := invocation.NewRPCInvocation("ListWorkMetricsDaily", args, invAttachment)
|
||||||
|
if interceptor == nil {
|
||||||
|
result := base.XXX_GetProxyImpl().Invoke(ctx, invo)
|
||||||
|
return result, result.Error()
|
||||||
|
}
|
||||||
|
info := &grpc_go.UnaryServerInfo{
|
||||||
|
Server: srv,
|
||||||
|
FullMethod: ctx.Value("XXX_TRIPLE_GO_INTERFACE_NAME").(string),
|
||||||
|
}
|
||||||
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||||
|
result := base.XXX_GetProxyImpl().Invoke(ctx, invo)
|
||||||
|
return result, result.Error()
|
||||||
|
}
|
||||||
|
return interceptor(ctx, in, info, handler)
|
||||||
|
}
|
||||||
|
|
||||||
func _Cast_GetArtistAyrShareInfo_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
|
func _Cast_GetArtistAyrShareInfo_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
|
||||||
in := new(GetArtistAyrShareInfoReq)
|
in := new(GetArtistAyrShareInfoReq)
|
||||||
if err := dec(in); err != nil {
|
if err := dec(in); err != nil {
|
||||||
@ -2899,6 +2983,14 @@ var Cast_ServiceDesc = grpc_go.ServiceDesc{
|
|||||||
MethodName: "UpsertWorkMetricsDailyBatch",
|
MethodName: "UpsertWorkMetricsDailyBatch",
|
||||||
Handler: _Cast_UpsertWorkMetricsDailyBatch_Handler,
|
Handler: _Cast_UpsertWorkMetricsDailyBatch_Handler,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
MethodName: "ListMediaMetricsDaily",
|
||||||
|
Handler: _Cast_ListMediaMetricsDaily_Handler,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
MethodName: "ListWorkMetricsDaily",
|
||||||
|
Handler: _Cast_ListWorkMetricsDaily_Handler,
|
||||||
|
},
|
||||||
{
|
{
|
||||||
MethodName: "GetArtistAyrShareInfo",
|
MethodName: "GetArtistAyrShareInfo",
|
||||||
Handler: _Cast_GetArtistAyrShareInfo_Handler,
|
Handler: _Cast_GetArtistAyrShareInfo_Handler,
|
||||||
|
|||||||
@ -18,8 +18,9 @@ type Data struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type Item struct {
|
type Item struct {
|
||||||
ID int `json:"ID"`
|
ID int `json:"ID"`
|
||||||
Domain string `json:"Domain"`
|
Domain string `json:"Domain"`
|
||||||
Status int `json:"Status"`
|
Status int `json:"Status"`
|
||||||
Reply string `json:"Reply"`
|
Reply string `json:"Reply"`
|
||||||
|
UpdatedAt string `json:"UpdatedAt"`
|
||||||
}
|
}
|
||||||
|
|||||||
@ -599,12 +599,12 @@ func PostAS(workUuids []string) (errs []error) {
|
|||||||
postIDs := postResp.Posts[0].PostIds
|
postIDs := postResp.Posts[0].PostIds
|
||||||
postData, _ := json.Marshal(postResp)
|
postData, _ := json.Marshal(postResp)
|
||||||
for _, postInfo := range postIDs {
|
for _, postInfo := range postIDs {
|
||||||
var platformID uint32
|
var pid uint32
|
||||||
switch postInfo.Platform {
|
switch postInfo.Platform {
|
||||||
case "tiktok":
|
case "tiktok":
|
||||||
platformID = 1
|
pid = 1
|
||||||
case "instagram":
|
case "instagram":
|
||||||
platformID = 3
|
pid = 3
|
||||||
}
|
}
|
||||||
publishStatus := cast.PublishStatusENUM_PublishMediaStatus_NO
|
publishStatus := cast.PublishStatusENUM_PublishMediaStatus_NO
|
||||||
if postInfo.Status == "success" {
|
if postInfo.Status == "success" {
|
||||||
@ -620,7 +620,7 @@ func PostAS(workUuids []string) (errs []error) {
|
|||||||
infoReq.PlatformInfoData = append(infoReq.PlatformInfoData, &cast.PlatformInfo{
|
infoReq.PlatformInfoData = append(infoReq.PlatformInfoData, &cast.PlatformInfo{
|
||||||
WorkUuid: workDetail.WorkUuid,
|
WorkUuid: workDetail.WorkUuid,
|
||||||
MediaAccountUuid: "", //FIXME
|
MediaAccountUuid: "", //FIXME
|
||||||
PlatformID: platformID,
|
PlatformID: pid,
|
||||||
PublishType: 2,
|
PublishType: 2,
|
||||||
PublishResp: string(postBytes),
|
PublishResp: string(postBytes),
|
||||||
PublishMediaId: postResp.Posts[0].Id,
|
PublishMediaId: postResp.Posts[0].Id,
|
||||||
@ -719,11 +719,13 @@ func RefreshWorkApprovalStatus(ctx *gin.Context, approvalIDWorkUuidMap map[int]s
|
|||||||
WorkUuid: approvalIDWorkUuidMap[approvalId],
|
WorkUuid: approvalIDWorkUuidMap[approvalId],
|
||||||
ApprovalID: fmt.Sprint(approvalId),
|
ApprovalID: fmt.Sprint(approvalId),
|
||||||
ApprovalReply: "",
|
ApprovalReply: "",
|
||||||
|
ApprovalTime: v.UpdatedAt,
|
||||||
})
|
})
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
var workAction cast.WorkActionENUM
|
var workAction cast.WorkActionENUM
|
||||||
if v.Status == 2 {
|
uTimes, _ := stime.DatetimeToTimes(v.UpdatedAt, "2006-01-02 15:04:05")
|
||||||
|
if v.Status == 2 && int64(uTimes) <= time.Now().Unix() {
|
||||||
workAction = cast.WorkActionENUM_APPROVAL_PASS
|
workAction = cast.WorkActionENUM_APPROVAL_PASS
|
||||||
} else if v.Status == 3 {
|
} else if v.Status == 3 {
|
||||||
workAction = cast.WorkActionENUM_APPROVAL_REJECT
|
workAction = cast.WorkActionENUM_APPROVAL_REJECT
|
||||||
@ -735,6 +737,7 @@ func RefreshWorkApprovalStatus(ctx *gin.Context, approvalIDWorkUuidMap map[int]s
|
|||||||
WorkUuid: approvalIDWorkUuidMap[approvalId],
|
WorkUuid: approvalIDWorkUuidMap[approvalId],
|
||||||
ApprovalID: fmt.Sprint(approvalId),
|
ApprovalID: fmt.Sprint(approvalId),
|
||||||
ApprovalReply: v.Reply,
|
ApprovalReply: v.Reply,
|
||||||
|
ApprovalTime: v.UpdatedAt,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user