1、年度积分问题修改 11.23

main
zhc077 1 year ago
parent 004424b230
commit 78fbce0ccb
  1. 4
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/abilityEvaluation/service/impl/PersonalAbilityEvaluationCollectServiceImpl.java
  2. 4
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/abilityEvaluation/service/impl/PersonalAbilityEvaluationServiceImpl.java
  3. 272
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/annualCompPoint/entity/AnnualCompPoint.java
  4. 81
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/annualScore/entity/PersonalCompTotalScore.java
  5. 22
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/annualScore/service/impl/PersonalCompScoreServiceImpl.java
  6. 2
      jeecgboot-vue3-master/src/views/annualCompPoint/committee/AnnualCompPoint.data.ts
  7. 59
      jeecgboot-vue3-master/src/views/annualScore/persoanlCompScore/PersonalCompScore.data.ts
  8. 88
      jeecgboot-vue3-master/src/views/annualScore/personalCompTotalScore/PersonalCompTotalScore.data.ts

@ -73,7 +73,7 @@ public class PersonalAbilityEvaluationCollectServiceImpl extends ServiceImpl<Per
// TeamManagement management = iTeamManagementService.getOne(new LambdaQueryWrapper<TeamManagement>()
// .eq(TeamManagement::getEnrollCode, enrollCode));
SysUser sysUser = iSysUserService.getOne(new LambdaQueryWrapper<SysUser>().eq(SysUser::getWorkNo, workNo));
SysDepart sysDepart = iSysDepartService.getById(sysUser.getOrgCode());
// SysDepart sysDepart = iSysDepartService.getDepartByOrgCode(sysUser.getOrgCode());
//每个学生同一类型能力指标分组查询
List<PersonalAbilityEvaluation> evaluationList4User = iPersonalAbilityEvaluationService.list(new LambdaQueryWrapper<PersonalAbilityEvaluation>()
@ -82,7 +82,7 @@ public class PersonalAbilityEvaluationCollectServiceImpl extends ServiceImpl<Per
Optional.ofNullable(evaluationList4User).orElse(new LinkedList<>()).stream().forEach(en -> {
PersonalAbilityEvaluationCollect person = new PersonalAbilityEvaluationCollect();
person.setAnnualCompP(projectId);
person.setDepetId(sysDepart.getId());
person.setDepetId(sysUser.getDepartIds());
person.setWorkOn(workNo);
person.setName(sysUser.getRealname());
double sum = evaluationList4User.stream().mapToDouble(e -> e.getValue()).sum();

@ -123,7 +123,7 @@ public class PersonalAbilityEvaluationServiceImpl extends ServiceImpl<PersonalAb
TeamManagement management = iTeamManagementService.getOne(new LambdaQueryWrapper<TeamManagement>()
.eq(TeamManagement::getEnrollCode, e.getEnrollCode()));
SysUser sysUser = iSysUserService.getById(management.getUserId());
SysDepart sysDepart = iSysDepartService.getById(sysUser.getOrgCode());
// SysDepart sysDepart = iSysDepartService.getDepartByOrgCode(sysUser.getOrgCode());
//遍历每一类能力指标
compskillList.forEach(compskill -> {
@ -133,7 +133,7 @@ public class PersonalAbilityEvaluationServiceImpl extends ServiceImpl<PersonalAb
person.setAnnualCompP(projectId);
person.setWorkOn(sysUser.getWorkNo());
person.setName(sysUser.getRealname());
person.setDepetId(sysDepart.getId());
person.setDepetId(sysUser.getDepartIds());
Basicsskill basicsskill = iBasicsskillService.getById(compskill.getCapacityid());
person.setCapacityId(compskill.getCapacityid());

@ -1,199 +1,269 @@
package org.jeecg.modules.demo.annualCompPoint.entity;
import java.io.Serializable;
import java.io.UnsupportedEncodingException;
import java.util.Date;
import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.TableLogic;
import lombok.Data;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.jeecg.common.aspect.annotation.Dict;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecg.common.aspect.annotation.Dict;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
/**
* @Description: 年度比赛项目管理
* @Author: jeecg-boot
* @Date: 2023-08-18
* @Date: 2023-08-18
* @Version: V1.0
*/
@Data
@TableName("annual_comp_point")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="annual_comp_point对象", description="年度比赛项目管理")
@ApiModel(value = "annual_comp_point对象", description = "年度比赛项目管理")
public class AnnualCompPoint implements Serializable {
private static final long serialVersionUID = 1L;
/**主键*/
@TableId(type = IdType.ASSIGN_ID)
/**
* 主键
*/
@TableId(type = IdType.ASSIGN_ID)
@ApiModelProperty(value = "主键")
private String id;
/**创建人*/
/**
* 创建人
*/
@ApiModelProperty(value = "创建人")
private String createBy;
/**创建日期*/
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
/**
* 创建日期
*/
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "创建日期")
private Date createTime;
/**更新人*/
/**
* 更新人
*/
@ApiModelProperty(value = "更新人")
private String updateBy;
/**更新日期*/
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
/**
* 更新日期
*/
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "更新日期")
private Date updateTime;
/**所属部门*/
/**
* 所属部门
*/
@ApiModelProperty(value = "所属部门")
private String sysOrgCode;
/**年度比赛id*/
@Excel(name = "年度比赛id", width = 15)
@Dict(dictTable = "annual_comp",dicCode = "id",dicText = "name")
/**
* 年度比赛id
*/
@Excel(name = "年度比赛id", width = 15)
@Dict(dictTable = "annual_comp", dicCode = "id", dicText = "name")
@ApiModelProperty(value = "年度比赛id")
private String annualCompId;
/**项目名称*/
@Excel(name = "项目名称", width = 15)
/**
* 项目名称
*/
@Excel(name = "项目名称", width = 15)
@ApiModelProperty(value = "项目名称")
private String objName;
/**简介*/
@Excel(name = "简介", width = 15)
/**
* 简介
*/
@Excel(name = "简介", width = 15)
@ApiModelProperty(value = "简介")
private String introduce;
/**项目层次*/
@Excel(name = "项目层次", width = 15)
@Dict(dictTable = "obj_level",dicCode = "id",dicText = "level_name")
/**
* 项目层次
*/
@Excel(name = "项目层次", width = 15)
@Dict(dictTable = "obj_level", dicCode = "id", dicText = "level_name")
@ApiModelProperty(value = "项目层次")
private String objLevel;
/**参与形式*/
@Excel(name = "参与形式", width = 15)
/**
* 参与形式
*/
@Excel(name = "参与形式", width = 15)
@ApiModelProperty(value = "参与形式")
private String entryForm;
/**队伍人数*/
@Excel(name = "队伍人数", width = 15)
/**
* 队伍人数
*/
@Excel(name = "队伍人数", width = 15)
@ApiModelProperty(value = "队伍人数")
private Integer teamNumber;
/**指导老师人数*/
@Excel(name = "指导老师人数", width = 15)
/**
* 指导老师人数
*/
@Excel(name = "指导老师人数", width = 15)
@ApiModelProperty(value = "指导老师人数")
private Integer teacherNumber;
/**是否需要领队*/
@Excel(name = "是否需要领队", width = 15)
/**
* 是否需要领队
*/
@Excel(name = "是否需要领队", width = 15)
@ApiModelProperty(value = "是否需要领队")
private String requireLeader;
/**是否需要队伍名称*/
@Excel(name = "是否需要队伍名称", width = 15)
/**
* 是否需要队伍名称
*/
@Excel(name = "是否需要队伍名称", width = 15)
@ApiModelProperty(value = "是否需要队伍名称")
private String requireTeamName;
/**是否报名*/
@Excel(name = "是否报名", width = 15)
/**
* 是否报名
*/
@Excel(name = "是否报名", width = 15)
@ApiModelProperty(value = "是否报名")
private String requireApply;
/**是否选题*/
@Excel(name = "是否选题", width = 15)
/**
* 是否选题
*/
@Excel(name = "是否选题", width = 15)
@ApiModelProperty(value = "是否选题")
private String requireTopic;
/**是否上传作品*/
@Excel(name = "是否上传作品", width = 15)
/**
* 是否上传作品
*/
@Excel(name = "是否上传作品", width = 15)
@ApiModelProperty(value = "是否上传作品")
private String requireUploadWorks;
/**上传作品限制数量*/
/**
* 上传作品限制数量
*/
@Excel(name = "是否上传作品", width = 15)
@ApiModelProperty(value = "上传作品限制数量")
private Integer workCount;
/**上传作品类型*/
@Excel(name = "上传作品类型", width = 15)
/**
* 上传作品类型
*/
@Excel(name = "上传作品类型", width = 15)
@ApiModelProperty(value = "上传作品类型")
private String uploadWorksType;
/**是否评分*/
@Excel(name = "是否评分", width = 15)
/**
* 是否评分
*/
@Excel(name = "是否评分", width = 15)
@ApiModelProperty(value = "是否评分")
private String requireScore;
/**开始时间*/
@Excel(name = "开始时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
/**
* 开始时间
*/
@Excel(name = "开始时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "开始时间")
private Date starttime;
/**结束时间*/
@Excel(name = "结束时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
/**
* 结束时间
*/
@Excel(name = "结束时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "结束时间")
private Date endtime;
/**年度比赛状态*/
@Excel(name = "年度比赛状态", width = 15)
/**
* 年度比赛状态
*/
@Excel(name = "年度比赛状态", width = 15)
@ApiModelProperty(value = "年度比赛状态")
private String annualCompState;
/**开关*/
@Excel(name = "开关", width = 15)
/**
* 开关
*/
@Excel(name = "开关", width = 15)
@ApiModelProperty(value = "开关")
private String annualCompSwitch;
/**驳回信息*/
@Excel(name = "驳回信息", width = 15)
/**
* 驳回信息
*/
@Excel(name = "驳回信息", width = 15)
@ApiModelProperty(value = "驳回信息")
private String backinfo;
/**报名开始时间*/
@Excel(name = "报名开始时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
/**
* 报名开始时间
*/
@Excel(name = "报名开始时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "报名开始时间")
private Date applyStartTime;
/**报名结束时间*/
@Excel(name = "报名结束时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
/**
* 报名结束时间
*/
@Excel(name = "报名结束时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "报名结束时间")
private Date applyEndTime;
/**选题开始时间*/
@Excel(name = "选题开始时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
/**
* 选题开始时间
*/
@Excel(name = "选题开始时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "选题开始时间")
private Date topicStartTime;
/**选题结束时间*/
@Excel(name = "选题结束时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
/**
* 选题结束时间
*/
@Excel(name = "选题结束时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "选题结束时间")
private Date topicEndTime;
/**上传作品开始时间*/
@Excel(name = "上传作品开始时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
/**
* 上传作品开始时间
*/
@Excel(name = "上传作品开始时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "上传作品开始时间")
private Date uploadStartTime;
/**上传作品结束时间*/
@Excel(name = "上传作品结束时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
/**
* 上传作品结束时间
*/
@Excel(name = "上传作品结束时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "上传作品结束时间")
private Date uploadEndTime;
/**评分开始时间*/
@Excel(name = "评分开始时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
/**
* 评分开始时间
*/
@Excel(name = "评分开始时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "评分开始时间")
private Date scoreStartTime;
/**评分结束时间*/
@Excel(name = "评分结束时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
/**
* 评分结束时间
*/
@Excel(name = "评分结束时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "评分结束时间")
private Date scoreEndTime;
/**是否成绩汇总*/
/**
* 是否成绩汇总
*/
@Excel(name = "是否成绩汇总", width = 15)
@ApiModelProperty(value = "是否成绩汇总")
private Integer isCjhz;
/**是否评奖*/
/**
* 是否评奖
*/
@Excel(name = "是否评奖", width = 15)
@ApiModelProperty(value = "是否评奖")
private Integer isPj;

@ -1,75 +1,94 @@
package org.jeecg.modules.demo.annualScore.entity;
import java.io.Serializable;
import java.io.UnsupportedEncodingException;
import java.util.Date;
import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.TableLogic;
import lombok.Data;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.jeecg.common.aspect.annotation.Dict;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecg.common.aspect.annotation.Dict;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
/**
* @Description: 个人总积分
* @Author: jeecg-boot
* @Date: 2023-11-01
* @Date: 2023-11-01
* @Version: V1.0
*/
@Data
@TableName("personal_comp_total_score")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="personal_comp_total_score对象", description="个人总积分")
@ApiModel(value = "personal_comp_total_score对象", description = "个人总积分")
public class PersonalCompTotalScore implements Serializable {
private static final long serialVersionUID = 1L;
/**主键*/
@TableId(type = IdType.ASSIGN_ID)
/**
* 主键
*/
@TableId(type = IdType.ASSIGN_ID)
@ApiModelProperty(value = "主键")
private String id;
/**创建人*/
/**
* 创建人
*/
@ApiModelProperty(value = "创建人")
private String createBy;
/**创建日期*/
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
/**
* 创建日期
*/
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "创建日期")
private Date createTime;
/**更新人*/
/**
* 更新人
*/
@ApiModelProperty(value = "更新人")
private String updateBy;
/**更新日期*/
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
/**
* 更新日期
*/
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "更新日期")
private Date updateTime;
/**院系*/
@Excel(name = "院系", width = 15)
/**
* 院系
*/
@Excel(name = "院系", width = 15)
@ApiModelProperty(value = "院系")
@Dict(dictTable = "sys_depart",dicCode = "id",dicText = "depart_name")
private String depet;
/**学号*/
@Excel(name = "学号", width = 15)
/**
* 学号
*/
@Excel(name = "学号", width = 15)
@ApiModelProperty(value = "学号")
private String workOn;
/**姓名*/
@Excel(name = "姓名", width = 15)
/**
* 姓名
*/
@Excel(name = "姓名", width = 15)
@ApiModelProperty(value = "姓名")
private String name;
/**总积分*/
@Excel(name = "总积分", width = 15)
/**
* 总积分
*/
@Excel(name = "总积分", width = 15)
@ApiModelProperty(value = "总积分")
private Double score;
/**描述*/
@Excel(name = "描述", width = 15)
/**
* 描述
*/
@Excel(name = "描述", width = 15)
@ApiModelProperty(value = "描述")
private String remark;
}

@ -2,6 +2,7 @@ package org.jeecg.modules.demo.annualScore.service.impl;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils;
import org.jeecg.common.util.ComputeUtils;
import org.jeecg.modules.demo.annualCompPoint.entity.AnnualCompPoint;
@ -42,6 +43,7 @@ import java.util.concurrent.atomic.AtomicReference;
* @Version: V1.0
*/
@Service
@Slf4j
public class PersonalCompScoreServiceImpl extends ServiceImpl<PersonalCompScoreMapper, PersonalCompScore> implements IPersonalCompScoreService {
@Autowired
@ -98,22 +100,25 @@ public class PersonalCompScoreServiceImpl extends ServiceImpl<PersonalCompScoreM
List<PersonalCompScore> saveList = new LinkedList<>();
if (!ObjectUtils.isEmpty(annualCompPoint)) {
//年度比赛项目 奖项设置
AnnualCompAward annualCompAward = iAnnualCompAwardService.getOne(new LambdaQueryWrapper<AnnualCompAward>()
.eq(AnnualCompAward::getAnnucompid, annualCompPoint.getId()));
if (ObjectUtils.isEmpty(annualCompAward)) return;
//1、根据年度比赛项目id,查询获取管理(award_persion)列表,即参赛人员及获取奖项顺序号
List<AwardPersion> awardPersionList = iAwardPersionService.list(new LambdaQueryWrapper<AwardPersion>()
.eq(AwardPersion::getAnnualCompP, annualCompPoint.getId()));
//2、遍历获奖理理(award_persion)列表,根据奖项id查询比赛奖项设置表(annual_comp_award)
//2、遍历获奖理(award_persion)列表,根据奖项id查询比赛奖项设置表(annual_comp_award)
Optional.ofNullable(awardPersionList).orElse(new LinkedList<>()).forEach(en -> {
//2.1、比赛奖项设置 根据awardsort奖项顺序,获取对应的奖项权重值
//奖项顺序与奖项权重值映射关系: wardsort(1:first_weight,2:second_weight,3:third_weight,4:fourth_weight,5:fifth_weight
AnnualCompAward annualCompAward = iAnnualCompAwardService.getById(en.getId());
if (ObjectUtils.isEmpty(annualCompAward)) return;
//奖项权重值 百分比
String weightVal;
switch (en.getAwardsort()) {
case 1:
weightVal = annualCompAward.getFifthWeight();
weightVal = annualCompAward.getFirstWeight();
break;
case 2:
weightVal = annualCompAward.getSecondWeight();
@ -140,6 +145,7 @@ public class PersonalCompScoreServiceImpl extends ServiceImpl<PersonalCompScoreM
if (ObjectUtils.isEmpty(managementList)) return;
//3、计算积分 项目分值*项目奖项权重值/100
log.info("***************年度比赛项目-{},项目分值:{},奖项权重值:{}", annualCompPoint.getObjName(), compweight_val, weightVal);
double baseScore = ComputeUtils.mul(compweight_val, ComputeUtils.div2(new Double(weightVal), ONE_HUNDRED));
AtomicReference<Double> score = new AtomicReference<>((double) 0);
if (StringUtils.equals("Y", entryForm)) { //团队赛
@ -159,8 +165,8 @@ public class PersonalCompScoreServiceImpl extends ServiceImpl<PersonalCompScoreM
SysUser sysUser = iSysUserService.getById(e.getUserId());
bean.setWorkOn(sysUser.getWorkNo());
bean.setName(sysUser.getRealname());
SysDepart sysDepart = iSysDepartService.getById(sysUser.getOrgCode());
bean.setDepet(sysDepart.getId());
// SysDepart sysDepart = iSysDepartService.getDepartByOrgCode(sysUser.getOrgCode());
bean.setDepet(sysUser.getDepartIds());
bean.setScore(score.get());
saveList.add(bean);
});
@ -174,8 +180,8 @@ public class PersonalCompScoreServiceImpl extends ServiceImpl<PersonalCompScoreM
SysUser sysUser = iSysUserService.getById(teamManagement.getUserId());
bean.setWorkOn(sysUser.getWorkNo());
bean.setName(sysUser.getRealname());
SysDepart sysDepart = iSysDepartService.getById(sysUser.getOrgCode());
bean.setDepet(sysDepart.getId());
// SysDepart sysDepart = iSysDepartService.getDepartByOrgCode(sysUser.getOrgCode());
bean.setDepet(sysUser.getDepartIds());
bean.setScore(score.get());
saveList.add(bean);
}

@ -69,6 +69,8 @@ export const columns: BasicColumn[] = [
return '已评分';
case "9":
return '已评奖';
case "10":
return '个人积分已汇总';
default:
return annualCompState.value;
}

@ -1,11 +1,6 @@
import {BasicColumn, FormSchema} from '/@/components/Table';
//列表数据
export const columns: BasicColumn[] = [
{
title: '所属院系',
align: "center",
dataIndex: 'depet_dictText'
},
{
title: '年度',
align: "center",
@ -22,15 +17,20 @@ export const columns: BasicColumn[] = [
dataIndex: 'annualCompP_dictText'
},
{
title: '学号',
title: '所属院系',
align: "center",
dataIndex: 'workOn'
dataIndex: 'depet_dictText'
},
{
title: '姓名',
align: "center",
dataIndex: 'name'
},
{
title: '学号',
align: "center",
dataIndex: 'workOn'
},
{
title: '个人积分',
align: "center",
@ -44,6 +44,24 @@ export const columns: BasicColumn[] = [
];
//查询数据
export const searchFormSchema: FormSchema[] = [
{
label: "年度",
field: 'annualId',
component: 'JDictSelectTag',
componentProps: {
dictCode: "annual,annual_name,id"
},
colProps: {span: 6},
},
{
label: "年度比赛项目",
field: 'annualCompP',
component: 'JDictSelectTag',
componentProps: {
dictCode: "annual_comp_point,obj_name,id"
},
colProps: {span: 6},
},
{
label: "院系",
field: 'depet',
@ -56,10 +74,11 @@ export const searchFormSchema: FormSchema[] = [
{
label: "学号",
field: 'workOn',
component: 'JDictSelectTag',
componentProps: {
dictCode: "sys_user,work_no,work_no"
},
// component: 'JDictSelectTag',
// componentProps: {
// dictCode: "sys_user,work_no,work_no"
// },
component: 'Input',
colProps: {span: 6},
},
{
@ -68,15 +87,6 @@ export const searchFormSchema: FormSchema[] = [
component: 'Input',
colProps: {span: 6},
},
{
label: "年度",
field: 'annualId',
component: 'JDictSelectTag',
componentProps: {
dictCode: "annual,annual_name,id"
},
colProps: {span: 6},
},
// {
// label: "年度比赛",
// field: 'annualCompId',
@ -86,15 +96,6 @@ export const searchFormSchema: FormSchema[] = [
// },
// colProps: {span: 6},
// },
{
label: "年度比赛项目",
field: 'annualCompP',
component: 'JDictSelectTag',
componentProps: {
dictCode: "annual_comp_point,obj_name,id"
},
colProps: {span: 6},
},
];
//表单数据
export const formSchema: FormSchema[] = [

@ -1,34 +1,31 @@
import {BasicColumn} from '/@/components/Table';
import {FormSchema} from '/@/components/Table';
import { rules} from '/@/utils/helper/validator';
import { render } from '/@/utils/common/renderUtils';
import {BasicColumn, FormSchema} from '/@/components/Table';
//列表数据
export const columns: BasicColumn[] = [
{
{
title: '院系',
align:"center",
dataIndex: 'depet'
},
{
title: '学号',
align:"center",
dataIndex: 'workOn'
},
{
align: "center",
dataIndex: 'depet_dictText'
},
{
title: '姓名',
align:"center",
align: "center",
dataIndex: 'name'
},
{
},
{
title: '学号',
align: "center",
dataIndex: 'workOn'
},
{
title: '总积分',
align:"center",
align: "center",
dataIndex: 'score'
},
// {
// title: '描述',
// align:"center",
// dataIndex: 'remark'
// },
},
// {
// title: '描述',
// align:"center",
// dataIndex: 'remark'
// },
];
//查询数据
export const searchFormSchema: FormSchema[] = [
@ -36,19 +33,19 @@ export const searchFormSchema: FormSchema[] = [
label: "院系",
field: 'depet',
component: 'JDictSelectTag',
componentProps:{
dictCode:"sys_depart,depart_name,id"
componentProps: {
dictCode: "sys_depart,depart_name,id"
},
colProps: {span: 6},
},
{
label: "学号",
field: 'workOn',
// component: 'Input',
component: 'JDictSelectTag',
componentProps:{
dictCode:"sys_user,work_no,work_no"
},
component: 'Input',
// component: 'JDictSelectTag',
// componentProps:{
// dictCode:"sys_user,work_no,work_no"
// },
colProps: {span: 6},
},
{
@ -64,41 +61,40 @@ export const formSchema: FormSchema[] = [
label: '学号',
field: 'workOn',
component: 'Input',
dynamicDisabled:true
dynamicDisabled: true
},
{
label: '姓名',
field: 'name',
component: 'Input',
dynamicDisabled:true
dynamicDisabled: true
},
{
label: '总积分',
field: 'score',
component: 'InputNumber',
dynamicDisabled:true
dynamicDisabled: true
},
{
label: '描述',
field: 'remark',
component: 'Input',
},
// TODO 主键隐藏字段,目前写死为ID
{
label: '',
field: 'id',
component: 'Input',
show: false
},
// TODO 主键隐藏字段,目前写死为ID
{
label: '',
field: 'id',
component: 'Input',
show: false
},
];
/**
* formSchema
* @param param
*/
export function getBpmFormSchema(_formData): FormSchema[]{
* formSchema
* @param param
*/
export function getBpmFormSchema(_formData): FormSchema[] {
// 默认和原始表单保持一致 如果流程中配置了权限数据,这里需要单独处理formSchema
return formSchema;
}

Loading…
Cancel
Save