作者 Your Name

更新

... ... @@ -12,8 +12,12 @@ type AssessInfoResp struct {
BeginTime string `json:"beginTime"` //开始时间 2006-01-02 15:04:05
EndTime string `json:"endTime"` //结束时间 2006-01-02 15:04:05
Status string `json:"status"` //完成状态
TargetUserId int `json:"targetUser"` //
TargetUserName string `json:"targetUserName"` //
TargetUserId int `json:"targetUser"` //目标用户
TargetUserName string `json:"targetUserName"` //目标用户名称
CompanyId int `json:"companyId,string"` //
CompanyName string `json:"companyName"` //公司名称
SupperUser string `json:"superUser"` //目标用户的上级
DutyTime string `json:"dutyTime"` //入职时间 //
AssessContent []*domain.StaffAssessContent `json:"assessContent"` //评估内容
}
... ...
... ... @@ -78,8 +78,8 @@ func (c *StaffAssessController) CreateStaffAssessTask() {
c.Response(data, err)
}
// 获取员工自评详情
func (c *StaffAssessController) GetAssessSelfInfo() {
// 获取当前登录员工自评详情
func (c *StaffAssessController) GetAssessSelfMeInfo() {
srv := service.NewStaffAssessServeice()
paramReq := &query.AssessSelfInfoQuery{}
err := c.BindJSON(paramReq)
... ... @@ -166,7 +166,6 @@ func (c *StaffAssessController) ListInviteUserAssess() {
}
// 获取上级评估成员列表
// 获取我要执行360评估,用户列表和评估填写的值
func (c *StaffAssessController) ListSupperAssess() {
srv := service.NewStaffAssessServeice()
paramReq := &query.ListSupperAssessQuery{}
... ... @@ -182,3 +181,33 @@ func (c *StaffAssessController) ListSupperAssess() {
data, err := srv.ListSupperAssess(paramReq)
c.Response(data, err)
}
// 获取员工自评详情
func (c *StaffAssessController) GetAssessSelfInfo() {
srv := service.NewStaffAssessServeice()
paramReq := &query.AssessSelfInfoQuery{}
err := c.BindJSON(paramReq)
if err != nil {
e := application.ThrowError(application.ARG_ERROR, "json 解析错误"+err.Error())
c.Response(nil, e)
return
}
paramReq.CompanyId = 1
data, err := srv.GetAssessSelfInfo(paramReq)
c.Response(data, err)
}
// 获取评估内容详情
func (c *StaffAssessController) GetAssessInfo() {
srv := service.NewStaffAssessServeice()
paramReq := &query.AssessInfoQuery{}
err := c.BindJSON(paramReq)
if err != nil {
e := application.ThrowError(application.ARG_ERROR, "json 解析错误"+err.Error())
c.Response(nil, e)
return
}
paramReq.CompanyId = 1
data, err := srv.GetAssessInfo(paramReq)
c.Response(data, err)
}
... ...
... ... @@ -16,10 +16,12 @@ func init() {
assessNS := web.NewNamespace("/v1/staff-assess",
// web.NSBefore(filters.AllowCors(), middlewares.CheckToken()),
web.NSCtrlPost("/self/me/list", (*controllers.StaffAssessController).AssessSelfMeList), //获取我的自评反馈列表
web.NSCtrlPost("/self/me/info", (*controllers.StaffAssessController).GetAssessSelfInfo), //获取我的自评反馈详情
web.NSCtrlPost("/self/me/info", (*controllers.StaffAssessController).GetAssessSelfMeInfo), //获取我的自评反馈详情
web.NSCtrlPost("/me/invite-user", (*controllers.StaffAssessController).GetAssessInviteUser), //获取邀请的员工
web.NSCtrlPost("/me/save-invite-user", (*controllers.StaffAssessController).SaveAssessInviteUser), //保存邀请的员工
web.NSCtrlPost("/me/save-invite-user", (*controllers.StaffAssessController).SaveAssessInviteUser), //保存邀请的员工
web.NSCtrlPost("/me/invite-user/select", (*controllers.StaffAssessController).SelectAssessInviteUser), //选择我邀请的员工
web.NSCtrlPost("/self/info", (*controllers.StaffAssessController).GetAssessSelfInfo), //获取我的自评反馈详情
web.NSCtrlPost("/info", (*controllers.StaffAssessController).GetAssessInfo), //获取我的自评反馈详情
)
web.AddNamespace(assessTaskNS)
web.AddNamespace(assessNS)
... ...