Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MaskPhoneNumber ¶
MaskPhoneNumber - 手机号掩码为 132****1111 的格式
func RandStringBytes ¶
RandStringBytes - 生成指定长度的随机字符串 https://stackoverflow.com/questions/22892120/how-to-generate-a-random-string-of-a-fixed-length-in-go https://colobu.com/2018/09/02/generate-random-string-in-Go/
func RandStringBytesMaskImprSrcUnsafe ¶
RandStringBytesMaskImprSrcUnsafe - 比 RandStringBytes 快 6.3 倍,并且只使用了六分之一的内存和一半的内存分配 https://www.flysnow.org/2019/09/30/how-to-generate-a-random-string-of-a-fixed-length-in-go.html
func UUIDNumber ¶
func UUIDNumber() (str string)
通过 UUID v4 的方案生成微信商户订单号 商户订单号,需保持唯一性,只能是字母或者数字,不能包含有其他字符,长度为32位。
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.