chore: import clean Agent Desk snapshot (2/7)

This commit is contained in:
2026-10-16 11:57:21 +00:00
parent 79176541c7
commit 89c5231c4c
461 changed files with 60092 additions and 0 deletions

View File

@@ -0,0 +1,36 @@
package enums
const CustomerSourceTypeWebChat = ExternalSourceGuest
func GetCustomerSourceTypeLabel(sourceType ExternalSource) string {
return GetExternalSourceLabel(ExternalSource(sourceType))
}
// 联系方式类型
type ContactType string
const (
ContactTypeMobile ContactType = "mobile"
ContactTypeEmail ContactType = "email"
ContactTypeOther ContactType = "other"
)
var contactTypeLabelMap = map[ContactType]string{
ContactTypeMobile: "手机号",
ContactTypeEmail: "邮箱",
ContactTypeOther: "其他",
}
func GetContactTypeLabel(contactType ContactType) string {
return contactTypeLabelMap[contactType]
}
// IsValidContactType 判断字符串是否为合法联系方式类型。
func IsValidContactType(v string) bool {
switch ContactType(v) {
case ContactTypeMobile, ContactTypeEmail, ContactTypeOther:
return true
default:
return false
}
}