From e5badfb077beb67f0b7186414cdebd7a1a6dce5b Mon Sep 17 00:00:00 2001 From: timerzz Date: Mon, 2 Sep 2024 21:42:48 +0800 Subject: [PATCH] feat LoadBiddingType --- bid.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/bid.go b/bid.go index d7ed034..9c10b14 100644 --- a/bid.go +++ b/bid.go @@ -1,5 +1,7 @@ package dw_sdk +import "strconv" + type BiddingType int8 const ( @@ -7,3 +9,8 @@ const ( BiddingType_Consign BiddingType = 5 //闪电直发 BiddingType_Fast_PreSale BiddingType = 8 //急速预售 ) + +func LoadBiddingType(s string) BiddingType { + i, _ := strconv.Atoi(s) + return BiddingType(i) +}