constants.go 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. package utils
  2. //常量定义
  3. const (
  4. FormatTime = "15:04:05" //时间格式
  5. FormatDate = "2006-01-02" //日期格式
  6. FormatDateCN = "2006年01月02日" //日期格式(中文)
  7. FormatDateUnSpace = "20060102" //日期格式
  8. FormatDateTime = "2006-01-02 15:04:05" //完整时间格式
  9. HlbFormatDateTime = "2006-01-02_15:04:05.999" //完整时间格式
  10. FormatDateTimeUnSpace = "20060102150405" //完整时间格式
  11. PageSize15 = 15 //列表页每页数据量
  12. PageSize5 = 5
  13. PageSize10 = 10
  14. PageSize20 = 20
  15. PageSize30 = 30
  16. )
  17. //手机号,电子邮箱正则
  18. const (
  19. RegularMobile = "^((13[0-9])|(14[5|7])|(15([0-3]|[5-9]))|(18[0-9])|(17[0-9])|(16[0-9])|(19[0-9]))\\d{8}$" //手机号码
  20. RegularEmail = `\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*` //匹配电子邮箱
  21. )
  22. const (
  23. APPNAME = "弘则人力资源管理系统"
  24. EmailSendToUsers = "317699326@qq.com;984198890@qq.com;hsun@hzinsights.com;xyxie@hzinsights.com"
  25. )
  26. // 招聘流程状态:0待一面结果、1待二面结果、2待三面结果;3已淘汰,4已通过
  27. const (
  28. RcrtProcessStatusWaitFirstResult = 0
  29. RcrtProcessStatusWaitSecondResult = 1
  30. RcrtProcessStatusWaitThirdResult = 2
  31. RcrtProcessStatusOut = 3
  32. RcrtProcessStatusWPass = 4
  33. )
  34. const DefaultPwd = "9cbf8a4dcb8e30682b927f352d6559a0" //初始密码:123456a
  35. // redis 缓存
  36. const (
  37. HRSYSTEM_LOGIN_TOKEN = "hrSystem:login:token:"
  38. HRSYSTEM_LOGIN_TOKEN_NO_TRUST = "hrSystem:login:no_trust:" //管理后台登录(不可信登录态)
  39. HRSYSTEM_LOGIN_ADMINID_IP = "hrSystem:login:admin_id:"
  40. )