增加品牌

This commit is contained in:
qiyunfanbo126.com 2024-10-22 15:44:22 +08:00
parent 2050e9b710
commit 6c7aeded6c
1 changed files with 3 additions and 3 deletions

View File

@ -355,11 +355,11 @@ func GenerateOrderNumber() string {
// 生成随机数部分4位随机数
mrand.Seed(time.Now().UnixNano())
randomPart := fmt.Sprintf("%04d", mrand.Intn(10000))
randomPart := fmt.Sprintf("%06d", mrand.Intn(100000))
// 添加固定前缀
prefix := "SN"
//prefix := "SN"
prefix := ""
// 最终的订单号由前缀、日期和随机数部分组成
orderNumber := fmt.Sprintf("%s%s%s", prefix, datePart, randomPart)