Skip to content

Commit

Permalink
MOD:fmt 引用
Browse files Browse the repository at this point in the history
  • Loading branch information
timidsmile committed Aug 29, 2018
1 parent 557976f commit 817a4bd
Show file tree
Hide file tree
Showing 20 changed files with 37 additions and 22 deletions.
2 changes: 1 addition & 1 deletion .idea/watcherTasks.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions action/common/uploadAvartarImage.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,12 @@ package common

import (
"fmt"
"net/http"
"strconv"

"github.com/gin-gonic/gin"
"github.com/timidsmile/pspace/components"
"github.com/timidsmile/pspace/consts"
"net/http"
"strconv"
)

func UploadAvartarImageAction(c *gin.Context) {
Expand Down
3 changes: 2 additions & 1 deletion action/common/uploadFile.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@ package common

import (
"fmt"
"net/http"

"github.com/gin-gonic/gin"
"github.com/timidsmile/pspace/components"
"net/http"
)

func UploadFileAction(c *gin.Context) {
Expand Down
3 changes: 2 additions & 1 deletion action/passport/getUserInfo.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,11 @@ package passport

import (
"fmt"
"net/http"

"github.com/gin-gonic/gin"
"github.com/timidsmile/pspace/components"
"github.com/timidsmile/pspace/service"
"net/http"
)

func GetUserInfoAction(c *gin.Context) {
Expand Down
5 changes: 3 additions & 2 deletions action/passport/setting.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,12 @@ package passport

import (
"fmt"
"net/http"

"github.com/gin-gonic/gin"
"github.com/timidsmile/pspace/components"
"github.com/timidsmile/pspace/model"
"github.com/timidsmile/pspace/service"
"net/http"
)

func SettingAction(c *gin.Context) {
Expand All @@ -23,7 +24,7 @@ func SettingAction(c *gin.Context) {
NickName string `form:"nickName"`
AvatarUrl string `form:"avatarUrl"`
}{
// Mobile: "123456", // 赋默认值情形
// Mobile: "123456", // 赋默认值情形
}

fmt.Println(params.NickName)
Expand Down
3 changes: 2 additions & 1 deletion action/session/CheckLogin.go
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
package session

import (
"net/http"

"github.com/gin-gonic/gin"
"github.com/timidsmile/pspace/components"
"github.com/timidsmile/pspace/service"
"net/http"
)

func CheckLoginAction(c *gin.Context) {
Expand Down
5 changes: 3 additions & 2 deletions action/session/Login.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,12 @@ package session

import (
"fmt"
"net/http"
"time"

"github.com/gin-gonic/gin"
"github.com/timidsmile/pspace/components"
"github.com/timidsmile/pspace/service"
"net/http"
"time"
)

func LoginAction(c *gin.Context) {
Expand Down
5 changes: 3 additions & 2 deletions action/session/Register.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,14 @@ package session

import (
"fmt"
"net/http"
"time"

"github.com/gin-gonic/gin"
"github.com/timidsmile/pspace/components"
"github.com/timidsmile/pspace/consts"
"github.com/timidsmile/pspace/model"
"github.com/timidsmile/pspace/service"
"net/http"
"time"
)

func RegisterAction(c *gin.Context) {
Expand Down
3 changes: 2 additions & 1 deletion action/test/Goodbye.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@ package test

import (
"fmt"
"github.com/gin-gonic/gin"
"net/http"

"github.com/gin-gonic/gin"
)

func GoodbyeAction(c *gin.Context) {
Expand Down
3 changes: 2 additions & 1 deletion action/test/Testdb.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,12 @@ package test

import (
"fmt"
"net/http"

"github.com/gin-gonic/gin"
_ "github.com/go-sql-driver/mysql" // mysql 驱动
"github.com/timidsmile/pspace/components"
"github.com/timidsmile/pspace/model"
"net/http"
)

func TestdbAction(c *gin.Context) {
Expand Down
3 changes: 2 additions & 1 deletion action/test/Welcome.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@ package test

import (
"fmt"
"github.com/gin-gonic/gin"
"net/http"

"github.com/gin-gonic/gin"
)

func WelcomeAction(c *gin.Context) {
Expand Down
1 change: 1 addition & 0 deletions components/db.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package components

import (
"fmt"

_ "github.com/go-sql-driver/mysql"
"github.com/jinzhu/gorm"
"github.com/timidsmile/pspace/setting"
Expand Down
1 change: 1 addition & 0 deletions components/redis.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package components

import (
"fmt"

"github.com/gomodule/redigo/redis"
"github.com/timidsmile/pspace/setting"
)
Expand Down
3 changes: 2 additions & 1 deletion components/session.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@ import (
"crypto/md5"
"encoding/hex"
"fmt"
"github.com/timidsmile/pspace/consts"
"strconv"
"strings"

"github.com/timidsmile/pspace/consts"
)

const TTL_SESSION = 86400
Expand Down
3 changes: 2 additions & 1 deletion middleware/CheckLogin.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@ package middleware

import (
"fmt"
"net/http"

"github.com/gin-gonic/gin"
"github.com/timidsmile/pspace/components"
"net/http"
)

func CheckLogin(c *gin.Context) {
Expand Down
1 change: 1 addition & 0 deletions router/router.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package router

import (
"fmt"

"github.com/gin-gonic/gin"
"github.com/robvdl/pongo2gin"
"github.com/timidsmile/pspace/action/common"
Expand Down
3 changes: 2 additions & 1 deletion service/userBasicService.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@ package service

import (
"errors"
"sync"

"github.com/timidsmile/pspace/components"
"github.com/timidsmile/pspace/model"
"sync"
)

type UserBasicService struct {
Expand Down
3 changes: 2 additions & 1 deletion setting/setting.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@ package setting

import (
"fmt"
"github.com/BurntSushi/toml"
"path/filepath"
"sync"

"github.com/BurntSushi/toml"
)

var (
Expand Down
2 changes: 0 additions & 2 deletions vendor/github.com/gin-gonic/gin/json/jsoniter.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion vendor/github.com/go-sql-driver/mysql/utils.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 817a4bd

Please sign in to comment.