Update Member
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
package utils
|
||||
|
||||
import (
|
||||
"enaklo-pos-be/internal/common/mycontext"
|
||||
"fmt"
|
||||
"time"
|
||||
)
|
||||
|
||||
func GenerateMemberID(ctx mycontext.Context, branchID, sequence int64) string {
|
||||
now := time.Now()
|
||||
yearMonth := now.Format("200601")
|
||||
|
||||
return fmt.Sprintf("%s%04d%04d", yearMonth, branchID, sequence)
|
||||
}
|
||||
Reference in New Issue
Block a user