Migrate guuid.

This commit is contained in:
lishuang
2020-07-11 15:36:21 +08:00
parent 24e8dc4e9f
commit 02e0f10016
18 changed files with 378 additions and 50 deletions

View File

@ -4,9 +4,8 @@ import (
"github.com/eyebluecn/tank/code/core"
"github.com/eyebluecn/tank/code/tool/builder"
"github.com/eyebluecn/tank/code/tool/result"
"github.com/eyebluecn/tank/code/tool/uuid"
"github.com/jinzhu/gorm"
"github.com/nu7hatch/gouuid"
"time"
)

View File

@ -3,8 +3,8 @@ package rest
import (
"github.com/eyebluecn/tank/code/core"
"github.com/eyebluecn/tank/code/tool/builder"
"github.com/eyebluecn/tank/code/tool/uuid"
"github.com/jinzhu/gorm"
"github.com/nu7hatch/gouuid"
"time"
)

View File

@ -3,7 +3,7 @@ package rest
import (
"github.com/eyebluecn/tank/code/core"
"github.com/eyebluecn/tank/code/tool/result"
"github.com/nu7hatch/gouuid"
"github.com/eyebluecn/tank/code/tool/uuid"
"time"
)

View File

@ -6,7 +6,7 @@ import (
"github.com/eyebluecn/tank/code/tool/result"
"github.com/jinzhu/gorm"
"github.com/nu7hatch/gouuid"
"github.com/eyebluecn/tank/code/tool/uuid"
"time"
)

View File

@ -6,8 +6,8 @@ import (
"github.com/eyebluecn/tank/code/tool/builder"
"github.com/eyebluecn/tank/code/tool/result"
"github.com/eyebluecn/tank/code/tool/util"
"github.com/eyebluecn/tank/code/tool/uuid"
"github.com/jinzhu/gorm"
"github.com/nu7hatch/gouuid"
"os"
"path/filepath"
"time"

View File

@ -7,8 +7,8 @@ import (
"github.com/eyebluecn/tank/code/tool/i18n"
"github.com/eyebluecn/tank/code/tool/result"
"github.com/eyebluecn/tank/code/tool/util"
"github.com/eyebluecn/tank/code/tool/uuid"
"github.com/jinzhu/gorm"
"github.com/nu7hatch/gouuid"
"net/http"
"regexp"
"strconv"

View File

@ -5,8 +5,8 @@ import (
"github.com/eyebluecn/tank/code/tool/builder"
"github.com/eyebluecn/tank/code/tool/result"
"github.com/eyebluecn/tank/code/tool/util"
"github.com/eyebluecn/tank/code/tool/uuid"
"github.com/jinzhu/gorm"
"github.com/nu7hatch/gouuid"
"os"
"time"
)

View File

@ -3,7 +3,7 @@ package rest
import (
"github.com/eyebluecn/tank/code/core"
"github.com/eyebluecn/tank/code/tool/result"
"github.com/nu7hatch/gouuid"
"github.com/eyebluecn/tank/code/tool/uuid"
"time"
)

View File

@ -3,7 +3,7 @@ package rest
import (
"github.com/eyebluecn/tank/code/core"
"github.com/eyebluecn/tank/code/tool/result"
"github.com/nu7hatch/gouuid"
"github.com/eyebluecn/tank/code/tool/uuid"
"time"
)

View File

@ -6,7 +6,7 @@ import (
"github.com/eyebluecn/tank/code/tool/result"
"github.com/jinzhu/gorm"
"github.com/nu7hatch/gouuid"
"github.com/eyebluecn/tank/code/tool/uuid"
"time"
)

View File

@ -3,7 +3,7 @@ package rest
import (
"github.com/eyebluecn/tank/code/core"
"github.com/eyebluecn/tank/code/tool/result"
"github.com/nu7hatch/gouuid"
"github.com/eyebluecn/tank/code/tool/uuid"
"time"
)

View File

@ -4,7 +4,7 @@ import (
"github.com/eyebluecn/tank/code/core"
"github.com/eyebluecn/tank/code/tool/builder"
"github.com/eyebluecn/tank/code/tool/result"
"github.com/nu7hatch/gouuid"
"github.com/eyebluecn/tank/code/tool/uuid"
"time"
)

View File

@ -5,7 +5,7 @@ import (
"github.com/eyebluecn/tank/code/tool/cache"
"github.com/eyebluecn/tank/code/tool/result"
"github.com/eyebluecn/tank/code/tool/util"
gouuid "github.com/nu7hatch/gouuid"
"github.com/eyebluecn/tank/code/tool/uuid"
"net/http"
"os"
"time"
@ -169,7 +169,7 @@ func (this *UserService) PreHandle(writer http.ResponseWriter, request *http.Req
} else {
this.logger.Info("load a temp session by username and password.")
timeUUID, _ := gouuid.NewV4()
timeUUID, _ := uuid.NewV4()
uuidStr := string(timeUUID.String())
request.Form[core.COOKIE_AUTH_KEY] = []string{uuidStr}