Files
servicebase/pkg/common/messages/error_message.go
2025-11-18 17:48:20 +08:00

27 lines
605 B
Go
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package messages
// 错误消息(补偿)
type Error struct {
MessageId string
Code string // 错误代码
Content string // 错误内容(json)
Tag ErrorTag // 消息标签auto=自动处理 manual=手动处理 auto_to_manual=自动转手动
}
type ErrorTag string
const (
Auto ErrorTag = "AUTO"
Manual ErrorTag = "MANUAL"
AutoToManual ErrorTag = "AUTO_TO_MANUAL"
)
type ErrorState string
const (
ErrorCreate ErrorState = "CREATED"
ErrorSuccess ErrorState = "SUCCESS"
ErrorFailed ErrorState = "FAILED"
ErrorReSuccess ErrorState = "RE_SUCCESS"
)