作者 庄敏学

fixed

@@ -103,3 +103,29 @@ @@ -103,3 +103,29 @@
103 2022/11/10 15:58:15.435 [D] [hook.go:130] performance CREATE TABLE IF NOT EXISTS "positions" ("id" bigserial, "company_id" bigint, "name" text, "parent_id" bigint, "path" text, "level" bigint, "remarks" text, "created_at" timestamptz, "updated_at" timestamptz, "deleted_at" timestamptz, PRIMARY KEY ("id")) null 103 2022/11/10 15:58:15.435 [D] [hook.go:130] performance CREATE TABLE IF NOT EXISTS "positions" ("id" bigserial, "company_id" bigint, "name" text, "parent_id" bigint, "path" text, "level" bigint, "remarks" text, "created_at" timestamptz, "updated_at" timestamptz, "deleted_at" timestamptz, PRIMARY KEY ("id")) null
104 2022/11/10 15:58:15.450 [I] [???:0] performance http server Running on http://:8082 104 2022/11/10 15:58:15.450 [I] [???:0] performance http server Running on http://:8082
105 2022/11/10 15:58:16.194 [E] [asm_amd64.s:1594] performance kafka: client has run out of available brokers to talk to (Is your cluster reachable?) [] 105 2022/11/10 15:58:16.194 [E] [asm_amd64.s:1594] performance kafka: client has run out of available brokers to talk to (Is your cluster reachable?) []
  106 +2022/11/10 16:16:09.220 [D] [hook.go:130] performance CREATE TABLE IF NOT EXISTS "company" ("id" bigserial, "logo" text, "name" text, "charge_user_ids" jsonb, "status" bigint, "update_at" timestamptz, "create_at" timestamptz, "delete_at" timestamptz, PRIMARY KEY ("id")) null
  107 +2022/11/10 16:16:09.247 [D] [hook.go:130] performance CREATE TABLE IF NOT EXISTS "department" ("id" bigserial, "company_id" bigint, "level" bigint, "name" text, "parent_id" bigint, "charge_user_ids" jsonb, "path" text, "create_at" timestamptz, "update_at" timestamptz, "delete_at" timestamptz, PRIMARY KEY ("id")) null
  108 +2022/11/10 16:16:09.274 [D] [hook.go:130] performance CREATE TABLE IF NOT EXISTS "user" ("id" bigserial, "account" text, "avatar_url" text, "company_id" bigint, "admin_type" bigint, "name" text, "email" text, "status" bigint, "department_id" jsonb, "position_id" jsonb, "update_at" timestamptz, "create_at" timestamptz, "delete_at" timestamptz, PRIMARY KEY ("id")) null
  109 +2022/11/10 16:16:09.302 [D] [hook.go:130] performance CREATE TABLE IF NOT EXISTS "received_message" ("message_id" bigserial, "message_type" text, "message_body" text, "occurred_on" timestamptz, "create_at" timestamptz, PRIMARY KEY ("message_id")) null
  110 +2022/11/10 16:16:09.330 [D] [hook.go:130] performance CREATE TABLE IF NOT EXISTS "role" ("id" bigserial, "name" text, "type" bigint, "description" text, "company_id" bigint, "created_at" timestamptz, "updated_at" timestamptz, "deleted_at" timestamptz, PRIMARY KEY ("id")) null
  111 +2022/11/10 16:16:09.359 [D] [hook.go:130] performance COMMENT ON TABLE public."role" IS '角色'; null
  112 +2022/11/10 16:16:09.386 [D] [hook.go:130] performance COMMENT ON COLUMN public."role".id IS 'ID'; null
  113 +2022/11/10 16:16:09.415 [D] [hook.go:130] performance COMMENT ON COLUMN public."role".name IS '角色名称'; null
  114 +2022/11/10 16:16:09.442 [D] [hook.go:130] performance COMMENT ON COLUMN public."role".type IS '角色类型(0角色可删、1系统预置角色不可删)'; null
  115 +2022/11/10 16:16:09.470 [D] [hook.go:130] performance COMMENT ON COLUMN public."role".description IS '角色描述'; null
  116 +2022/11/10 16:16:09.497 [D] [hook.go:130] performance COMMENT ON COLUMN public."role".company_id IS '公司ID'; null
  117 +2022/11/10 16:16:09.524 [D] [hook.go:130] performance COMMENT ON COLUMN public."role".created_at IS '创建时间'; null
  118 +2022/11/10 16:16:09.553 [D] [hook.go:130] performance COMMENT ON COLUMN public."role".updated_at IS '更新时间'; null
  119 +2022/11/10 16:16:09.580 [D] [hook.go:130] performance COMMENT ON COLUMN public."role".deleted_at IS '删除时间'; null
  120 +2022/11/10 16:16:09.606 [D] [hook.go:130] performance CREATE TABLE IF NOT EXISTS "role_user" ("id" bigserial, "role_id" bigint, "user_id" bigint, "company_id" bigint, "created_at" timestamptz, "updated_at" timestamptz, "deleted_at" timestamptz, PRIMARY KEY ("id")) null
  121 +2022/11/10 16:16:09.633 [D] [hook.go:130] performance COMMENT ON TABLE public."role_user" IS '角色用户关系'; null
  122 +2022/11/10 16:16:09.660 [D] [hook.go:130] performance COMMENT ON COLUMN public."role_user".id IS 'ID'; null
  123 +2022/11/10 16:16:09.687 [D] [hook.go:130] performance COMMENT ON COLUMN public."role_user".role_id IS '角色ID'; null
  124 +2022/11/10 16:16:09.714 [D] [hook.go:130] performance COMMENT ON COLUMN public."role_user".user_id IS '用户ID'; null
  125 +2022/11/10 16:16:09.750 [D] [hook.go:130] performance COMMENT ON COLUMN public."role_user".company_id IS '公司ID'; null
  126 +2022/11/10 16:16:09.776 [D] [hook.go:130] performance COMMENT ON COLUMN public."role_user".created_at IS '创建时间'; null
  127 +2022/11/10 16:16:09.803 [D] [hook.go:130] performance COMMENT ON COLUMN public."role_user".updated_at IS '更新时间'; null
  128 +2022/11/10 16:16:09.831 [D] [hook.go:130] performance COMMENT ON COLUMN public."role_user".deleted_at IS '删除时间'; null
  129 +2022/11/10 16:16:09.857 [D] [hook.go:130] performance CREATE TABLE IF NOT EXISTS "positions" ("id" bigserial, "company_id" bigint, "name" text, "parent_id" bigint, "path" text, "level" bigint, "remarks" text, "created_at" timestamptz, "updated_at" timestamptz, "deleted_at" timestamptz, PRIMARY KEY ("id")) null
  130 +2022/11/10 16:16:09.873 [I] [???:0] performance http server Running on http://:8082
  131 +2022/11/10 16:16:10.621 [E] [asm_amd64.s:1594] performance kafka: client has run out of available brokers to talk to (Is your cluster reachable?) []
不能预览此文件类型
@@ -11,8 +11,8 @@ type User struct { @@ -11,8 +11,8 @@ type User struct {
11 Name string // 用户姓名 11 Name string // 用户姓名
12 Email string // 邮箱 12 Email string // 邮箱
13 Status int // 用户状态(1正常 2禁用) 13 Status int // 用户状态(1正常 2禁用)
14 - DepartmentId []int64 // 用户归属的部门  
15 - PositionId []int64 //用户职位 14 + DepartmentId []int // 用户归属的部门
  15 + PositionId []int //用户职位
16 UpdateAt time.Time // 更新时间 16 UpdateAt time.Time // 更新时间
17 DeleteAt *time.Time 17 DeleteAt *time.Time
18 CreateAt time.Time 18 CreateAt time.Time
@@ -12,8 +12,8 @@ type User struct { @@ -12,8 +12,8 @@ type User struct {
12 Name string // 用户姓名 12 Name string // 用户姓名
13 Email string // 邮箱 13 Email string // 邮箱
14 Status int // 用户状态(1正常 2禁用) 14 Status int // 用户状态(1正常 2禁用)
15 - DepartmentId []int64 // 用户归属的部门  
16 - PositionId []int64 // 用户职位 15 + DepartmentId []int // 用户归属的部门
  16 + PositionId []int // 用户职位
17 UpdateAt time.Time // 更新时间 17 UpdateAt time.Time // 更新时间
18 CreateAt time.Time // 创建时间 18 CreateAt time.Time // 创建时间
19 DeleteAt *time.Time `bun:",soft_delete"` // 删除时间 19 DeleteAt *time.Time `bun:",soft_delete"` // 删除时间