作者 tangxvhui
@@ -396,12 +396,15 @@ func (rs *EvaluationProjectService) List(in *command.QueryProjectCommand) (inter @@ -396,12 +396,15 @@ func (rs *EvaluationProjectService) List(in *command.QueryProjectCommand) (inter
396 pmpUserIds = append(pmpUserIds, userId) 396 pmpUserIds = append(pmpUserIds, userId)
397 } 397 }
398 398
399 - // 当前时间超过截至时间显示【已结束】 399 + // 如果是已启用状态时,当前时间超过截至时间显示【已结束】
  400 + if project.State == domain.ProjectStateEnable {
400 if now > project.EndTime.Unix() { 401 if now > project.EndTime.Unix() {
401 project.State = domain.ProjectStateDisable 402 project.State = domain.ProjectStateDisable
402 } 403 }
403 } 404 }
404 405
  406 + }
  407 +
405 if len(pmpUserIds) > 0 { 408 if len(pmpUserIds) > 0 {
406 userRepository := factory.CreateUserRepository(map[string]interface{}{"transactionContext": transactionContext}) 409 userRepository := factory.CreateUserRepository(map[string]interface{}{"transactionContext": transactionContext})
407 _, users, _ := userRepository.Find(map[string]interface{}{"ids": pmpUserIds, "limit": len(pmpUserIds)}) 410 _, users, _ := userRepository.Find(map[string]interface{}{"ids": pmpUserIds, "limit": len(pmpUserIds)})
@@ -27,6 +27,7 @@ const ( @@ -27,6 +27,7 @@ const (
27 type EntryItem struct { 27 type EntryItem struct {
28 Title string `json:"title" comment:"填写标题"` 28 Title string `json:"title" comment:"填写标题"`
29 HintText string `json:"hintText" comment:"文本内容提示"` 29 HintText string `json:"hintText" comment:"文本内容提示"`
  30 + Definition string `json:"definition" comment:"定义"`
30 } 31 }
31 32
32 // NodeContent 评估内容 33 // NodeContent 评估内容
@@ -107,7 +107,8 @@ func (controller *ImportController) parseTemplateNodeContent(data []*domain.Perf @@ -107,7 +107,8 @@ func (controller *ImportController) parseTemplateNodeContent(data []*domain.Perf
107 target := module.Target[i3] 107 target := module.Target[i3]
108 nc.EntryItems = append(nc.EntryItems, &domain.EntryItem{ 108 nc.EntryItems = append(nc.EntryItems, &domain.EntryItem{
109 Title: target.Task, // 输入型标题 109 Title: target.Task, // 输入型标题
110 - HintText: target.Definition, // 输入项提示文本 110 + HintText: "", // 输入项提示文本
  111 + Definition: target.Definition, //定义
111 }) 112 })
112 } 113 }
113 // 没有任何输入项时,默认1个 114 // 没有任何输入项时,默认1个