作者 Your Name

暂存

@@ -25,7 +25,7 @@ type StaffAssessTask struct { @@ -25,7 +25,7 @@ type StaffAssessTask struct {
25 CycleName string `json:"cycleName"` //对应周期的名称 25 CycleName string `json:"cycleName"` //对应周期的名称
26 BeginTime time.Time `json:"beginTime"` //绩效考核开始时间 26 BeginTime time.Time `json:"beginTime"` //绩效考核开始时间
27 EndTime time.Time `json:"endTime"` //绩效考核截止时间 27 EndTime time.Time `json:"endTime"` //绩效考核截止时间
28 - StepList []AssessTaskStep `json:"steps"` //考评的流程 28 + StepList []AssessTaskStep `json:"stepList"` //考评的流程
29 ExecutorId []int `json:"executorId"` //参与此次考评的人 29 ExecutorId []int `json:"executorId"` //参与此次考评的人
30 CreatedAt time.Time `json:"createdAt"` //数据创建时间 30 CreatedAt time.Time `json:"createdAt"` //数据创建时间
31 UpdatedAt time.Time `json:"updatedAt"` //数据更新时间 31 UpdatedAt time.Time `json:"updatedAt"` //数据更新时间
@@ -12,7 +12,7 @@ type RuleController struct { @@ -12,7 +12,7 @@ type RuleController struct {
12 beego.BaseController 12 beego.BaseController
13 } 13 }
14 14
15 -func (controller *RoleController) CreateRule() { 15 +func (controller *RuleController) CreateRule() {
16 ruService := service.NewEvaluationRuleService() 16 ruService := service.NewEvaluationRuleService()
17 in := &command.CreateRuleCommand{} 17 in := &command.CreateRuleCommand{}
18 if err := controller.Unmarshal(in); err != nil { 18 if err := controller.Unmarshal(in); err != nil {
@@ -38,6 +38,8 @@ func (c *StaffAssessController) AssessTaskMeDesc() { @@ -38,6 +38,8 @@ func (c *StaffAssessController) AssessTaskMeDesc() {
38 return 38 return
39 } 39 }
40 //TODO 获取当前用户信息 40 //TODO 获取当前用户信息
  41 + paramReq.CompanyId = 1
  42 + paramReq.UserId = 1
41 data, err := srv.AssessTaskDesc(paramReq) 43 data, err := srv.AssessTaskDesc(paramReq)
42 c.Response(data, err) 44 c.Response(data, err)
43 } 45 }
@@ -10,7 +10,7 @@ import ( @@ -10,7 +10,7 @@ import (
10 func init() { 10 func init() {
11 ns := web.NewNamespace("/v1/evaluation-template", 11 ns := web.NewNamespace("/v1/evaluation-template",
12 web.NSBefore(filters.AllowCors(), middlewares.CheckToken()), 12 web.NSBefore(filters.AllowCors(), middlewares.CheckToken()),
13 - web.NSRouter("/", &controllers.TemplateController{}, "Post:CreateTemplate"), 13 + // web.NSRouter("/", &controllers.TemplateController{}, "Post:CreateTemplate"),
14 web.NSRouter("/", &controllers.TemplateController{}, "Put:UpdateTemplate"), 14 web.NSRouter("/", &controllers.TemplateController{}, "Put:UpdateTemplate"),
15 web.NSRouter("/", &controllers.TemplateController{}, "Delete:RemoveTemplate"), 15 web.NSRouter("/", &controllers.TemplateController{}, "Delete:RemoveTemplate"),
16 web.NSRouter("/:Id", &controllers.TemplateController{}, "Get:GetTemplate"), 16 web.NSRouter("/:Id", &controllers.TemplateController{}, "Get:GetTemplate"),
@@ -3,16 +3,15 @@ package routers @@ -3,16 +3,15 @@ package routers
3 import ( 3 import (
4 "github.com/beego/beego/v2/server/web" 4 "github.com/beego/beego/v2/server/web"
5 "github.com/linmadan/egglib-go/web/beego/filters" 5 "github.com/linmadan/egglib-go/web/beego/filters"
6 - "gitlab.fjmaimaimai.com/allied-creation/performance/pkg/port/beego/controllers"  
7 "gitlab.fjmaimaimai.com/allied-creation/performance/pkg/port/beego/middlewares" 6 "gitlab.fjmaimaimai.com/allied-creation/performance/pkg/port/beego/middlewares"
8 ) 7 )
9 8
10 func init() { 9 func init() {
11 ns := web.NewNamespace("/v1/role-user", 10 ns := web.NewNamespace("/v1/role-user",
12 web.NSBefore(filters.AllowCors(), middlewares.CheckToken()), 11 web.NSBefore(filters.AllowCors(), middlewares.CheckToken()),
13 - web.NSRouter("/", &controllers.RoleUserController{}, "Post:CreateRole"),  
14 - web.NSRouter("/", &controllers.RoleUserController{}, "Delete:RemoveRole"),  
15 - web.NSRouter("/all", &controllers.RoleUserController{}, "Post:ListRoleUser"), 12 + // web.NSRouter("/", &controllers.RoleUserController{}, "Post:CreateRole"),
  13 + // web.NSRouter("/", &controllers.RoleUserController{}, "Delete:RemoveRole"),
  14 + // web.NSRouter("/all", &controllers.RoleUserController{}, "Post:ListRoleUser"),
16 ) 15 )
17 web.AddNamespace(ns) 16 web.AddNamespace(ns)
18 } 17 }
@@ -2,21 +2,19 @@ package routers @@ -2,21 +2,19 @@ package routers
2 2
3 import ( 3 import (
4 "github.com/beego/beego/v2/server/web" 4 "github.com/beego/beego/v2/server/web"
5 - "github.com/linmadan/egglib-go/web/beego/filters"  
6 "gitlab.fjmaimaimai.com/allied-creation/performance/pkg/port/beego/controllers" 5 "gitlab.fjmaimaimai.com/allied-creation/performance/pkg/port/beego/controllers"
7 - "gitlab.fjmaimaimai.com/allied-creation/performance/pkg/port/beego/middlewares"  
8 ) 6 )
9 7
10 func init() { 8 func init() {
11 assessTaskNS := web.NewNamespace("/v1/staff-assess-task", 9 assessTaskNS := web.NewNamespace("/v1/staff-assess-task",
12 - web.NSBefore(filters.AllowCors(), middlewares.CheckToken()), 10 + // web.NSBefore(filters.AllowCors(), middlewares.CheckToken()),
13 web.NSCtrlPost("/search/me", (*controllers.StaffAssessController).SearchAssessTaskMe), //获取我参与过的评估项目列表 11 web.NSCtrlPost("/search/me", (*controllers.StaffAssessController).SearchAssessTaskMe), //获取我参与过的评估项目列表
14 web.NSCtrlPost("/desc/me", (*controllers.StaffAssessController).AssessTaskMeDesc), //获取我的项目评估进度描述 12 web.NSCtrlPost("/desc/me", (*controllers.StaffAssessController).AssessTaskMeDesc), //获取我的项目评估进度描述
15 web.NSCtrlPost("/", (*controllers.StaffAssessController).CreateStaffAssessTask), //创建员工的评估任务 13 web.NSCtrlPost("/", (*controllers.StaffAssessController).CreateStaffAssessTask), //创建员工的评估任务
16 ) 14 )
17 // /v1/staff-assess/self/me/list 15 // /v1/staff-assess/self/me/list
18 assessNS := web.NewNamespace("/v1/staff-assess", 16 assessNS := web.NewNamespace("/v1/staff-assess",
19 - web.NSBefore(filters.AllowCors(), middlewares.CheckToken()), 17 + // web.NSBefore(filters.AllowCors(), middlewares.CheckToken()),
20 web.NSCtrlPost("/self/me/list", (*controllers.StaffAssessController).AssessSelfMeList), //获取我的自评反馈列表 18 web.NSCtrlPost("/self/me/list", (*controllers.StaffAssessController).AssessSelfMeList), //获取我的自评反馈列表
21 // web.NSCtrlPost("/self/me/info", (*controllers.StaffAssessController).AssessSelfMeList), 19 // web.NSCtrlPost("/self/me/info", (*controllers.StaffAssessController).AssessSelfMeList),
22 ) 20 )