对政策匹配进行优化
This commit is contained in:
@@ -4,6 +4,7 @@ import (
|
||||
. "code.hoteas.com/golang/hotime"
|
||||
. "code.hoteas.com/golang/hotime/common"
|
||||
"errors"
|
||||
"strings"
|
||||
"time"
|
||||
"unicode/utf8"
|
||||
)
|
||||
@@ -46,6 +47,29 @@ func getCode() string {
|
||||
return res
|
||||
}
|
||||
|
||||
func strToArray(str string) Slice {
|
||||
s := Slice{}
|
||||
|
||||
olds := strings.Split(str, ",")
|
||||
for _, v := range olds {
|
||||
if v != "" {
|
||||
s = append(s, v)
|
||||
}
|
||||
}
|
||||
return s
|
||||
}
|
||||
|
||||
func arrayToStr(ars Slice) string {
|
||||
s := ","
|
||||
if ars == nil {
|
||||
return s
|
||||
}
|
||||
for k, _ := range ars {
|
||||
s = s + ars.GetString(k) + ","
|
||||
}
|
||||
return s
|
||||
}
|
||||
|
||||
//认证公共方案
|
||||
func auth(that *Context, phone, companyName, userName string) error {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user