胡轶钦 6 년 전
부모
커밋
5871d50959

+ 22
- 0
models/constant.go 파일 보기

@@ -14,3 +14,25 @@ const (
14 14
 	// 已使用
15 15
 	STATUS_USED
16 16
 )
17
+
18
+// 回复类型
19
+const (
20
+	// 关键词
21
+	AUTOREPLY_KEYWORDS = "keyword"
22
+	// 关注
23
+	AUTOREPLY_SUBSCRIBE = "subscribe"
24
+)
25
+
26
+// 授权状态
27
+const (
28
+	AUTH_STATUS_YES = "yes"
29
+	AUTH_STATUS_NO  = "no"
30
+)
31
+
32
+// 用户类型
33
+const (
34
+	// 超级管理员
35
+	USER_TYPE_ADMIN = "admin"
36
+	// 操作员
37
+	USER_TYPE_OPERATOR = "operator"
38
+)

+ 1
- 0
models/model/sys_org.go 파일 보기

@@ -9,6 +9,7 @@ type SysOrg struct {
9 9
 	OrgName    string    `xorm:"VARCHAR(32)"`
10 10
 	WechatId   string    `xorm:"VARCHAR(64)"`
11 11
 	WechatName string    `xorm:"VARCHAR(32)"`
12
+	AuthStatus string    `xorm:"VARCHAR(32)"`
12 13
 	Status     int       `xorm:"SMALLINT(6)"`
13 14
 	CreateDate time.Time `xorm:"DATETIME"`
14 15
 }

+ 1
- 0
models/model/ta_auto_reply.go 파일 보기

@@ -16,4 +16,5 @@ type TaAutoReply struct {
16 16
 	CreateDate       time.Time `xorm:"DATETIME"`
17 17
 	Status           int       `xorm:"SMALLINT(6)"`
18 18
 	OrgId            string    `xorm:"VARCHAR(64)"`
19
+	KeyWords         string    `xorm:"TEXT"`
19 20
 }

+ 1
- 1
models/model/ta_auto_reply_keywords.go 파일 보기

@@ -4,5 +4,5 @@ type TaAutoReplyKeywords struct {
4 4
 	KeywordsId  string `xorm:"not null pk VARCHAR(64)"`
5 5
 	AutoReplyId string `xorm:"VARCHAR(64)"`
6 6
 	Keywords    string `xorm:"VARCHAR(32)"`
7
-	Status      string `xorm:"CHAR(10)"`
7
+	Status      int    `xorm:"SMALLINT(6)"`
8 8
 }

+ 1
- 0
models/model/ta_wechat_content.go 파일 보기

@@ -17,4 +17,5 @@ type TaWechatContent struct {
17 17
 	UpdateTime       time.Time `xorm:"DATETIME"`
18 18
 	OrgId            string    `xorm:"VARCHAR(64)"`
19 19
 	CreateDate       time.Time `xorm:"DATETIME"`
20
+	Status           int       `xorm:"SMALLINT(6)"`
20 21
 }

+ 1
- 0
models/model/ta_wechat_img.go 파일 보기

@@ -11,4 +11,5 @@ type TaWechatImg struct {
11 11
 	Url        string    `xorm:"TEXT"`
12 12
 	OrgId      string    `xorm:"VARCHAR(64)"`
13 13
 	CreateDate time.Time `xorm:"DATETIME"`
14
+	Status     int       `xorm:"SMALLINT(6)"`
14 15
 }

+ 0
- 1
service/user/user.go 파일 보기

@@ -6,7 +6,6 @@ import (
6 6
 	"wechat-conf/models/model"
7 7
 	"wechat-conf/models/user"
8 8
 	"wechat-conf/utils"
9
-	"wechat/helper"
10 9
 
11 10
 	"github.com/yl10/kit/encrypt"
12 11
 )