Merge remote-tracking branch 'origin/main'

main
王家东 3 months ago
commit 7b16c6aee9
  1. 8
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/homepage/controller/UserHomePageController.java
  2. 4
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/homepage/service/UserHomePageService.java
  3. 65
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/homepage/service/UserHomePageServiceImpl.java
  4. 11
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/teamseq/controller/TeamSeqController.java
  5. 17
      jeecg-boot-master/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/teamseq/service/impl/TeamSeqServiceImpl.java
  6. 3
      jeecgboot-vue3-master/src/api/common/api.ts
  7. 62
      jeecgboot-vue3-master/src/views/comprehensiveEvaluation/comprehensiveReport.vue
  8. 63
      jeecgboot-vue3-master/src/views/comprehensiveEvaluation/department.vue

@ -48,15 +48,15 @@ public class UserHomePageController {
@AutoLog(value = "学校管理员-分析报告") @AutoLog(value = "学校管理员-分析报告")
@ApiOperation(value = "河南机电-学校综合报告", notes = "河南机电-学校综合报告") @ApiOperation(value = "河南机电-学校综合报告", notes = "河南机电-学校综合报告")
@GetMapping(value = "/report4School") @GetMapping(value = "/report4School")
public Result report4School(boolean recreateFlag) { public Result report4School(String annualid, boolean recreateFlag) {
Object result = homePageService.report4School(recreateFlag); Object result = homePageService.report4School(annualid,recreateFlag);
return Result.ok(result); return Result.ok(result);
} }
@AutoLog(value = "部门管理员-分析报告") @AutoLog(value = "部门管理员-分析报告")
@ApiOperation(value = "河南机电-部门综合报告", notes = "河南机电-部门综合报告") @ApiOperation(value = "河南机电-部门综合报告", notes = "河南机电-部门综合报告")
@GetMapping(value = "/report4Depart") @GetMapping(value = "/report4Depart")
public Result report4Depart(String orgCode,boolean recreateFlag) { public Result report4Depart(String annualid,String orgCode, boolean recreateFlag) {
return Result.ok(homePageService.report4Depart(orgCode, recreateFlag)); return Result.ok(homePageService.report4Depart(annualid,orgCode, recreateFlag));
} }
} }

@ -8,7 +8,7 @@ public interface UserHomePageService {
Map<String, Object> homePage4School(); Map<String, Object> homePage4School();
Object report4School(boolean recreateFlag); Object report4School(String year,boolean recreateFlag);
Object report4Depart(String orgCode, boolean recreateFlag); Object report4Depart(String year,String orgCode, boolean recreateFlag);
} }

@ -2,6 +2,7 @@ package org.jeecg.modules.demo.homepage.service;
import cn.hutool.core.util.ObjectUtil; import cn.hutool.core.util.ObjectUtil;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import org.apache.commons.lang3.StringUtils;
import org.jeecg.common.exception.JeecgBootException; import org.jeecg.common.exception.JeecgBootException;
import org.jeecg.common.util.ComputeUtils; import org.jeecg.common.util.ComputeUtils;
import org.jeecg.common.util.DateUtils; import org.jeecg.common.util.DateUtils;
@ -362,24 +363,34 @@ public class UserHomePageServiceImpl implements UserHomePageService {
} }
@Override @Override
public Object report4School(boolean recreateFlag) { public Object report4School(String annualId, boolean recreateFlag) {
final String REPORT4SCHOOL = "report4School";
String currentYear;
if (StringUtils.isNotBlank(annualId)) {
Annual annual = iAnnualService.getById(annualId);
currentYear = annual.getAnnualName();
} else {
currentYear = DateUtils.getCurrentYear() + "";
}
final String REPORT4SCHOOL = "report4School-" + currentYear;
Map<String, Object> resultMap = new LinkedHashMap<>(); Map<String, Object> resultMap = new LinkedHashMap<>();
boolean hasKey = redisUtil.hasKey(REPORT4SCHOOL);
if (hasKey && !recreateFlag) {
return redisUtil.get(REPORT4SCHOOL);
}
if (recreateFlag) { if (recreateFlag) {
int currentYear = DateUtils.getCurrentYear(); //年度
//当前年度
Annual annual = iAnnualService.getOne(new LambdaQueryWrapper<Annual>().eq(Annual::getAnnualName, currentYear + "")); Annual annual = iAnnualService.getOne(new LambdaQueryWrapper<Annual>().eq(Annual::getAnnualName, currentYear + ""));
if (ObjectUtils.isEmpty(annual)) return resultMap;
List<AnnualComp> annualCompList = iAnnualCompService.list(new LambdaQueryWrapper<AnnualComp>() List<AnnualComp> annualCompList = iAnnualCompService.list(new LambdaQueryWrapper<AnnualComp>()
.eq(AnnualComp::getAnnualid, annual.getId())); .eq(AnnualComp::getAnnualid, annual.getId()));
Set<String> compIds = Optional.ofNullable(annualCompList).orElse(new LinkedList<>()).stream().map(obj -> obj.getId()).collect(Collectors.toSet()); Set<String> compIds = Optional.ofNullable(annualCompList).orElse(new LinkedList<>()).stream().map(obj -> obj.getId()).collect(Collectors.toSet());
List<AnnualCompPoint> annualCompPointList = iAnnualCompPointService.list(new LambdaQueryWrapper<AnnualCompPoint>().in(!ObjectUtils.isEmpty(compIds), AnnualCompPoint::getAnnualCompId, compIds)); List<AnnualCompPoint> annualCompPointList = iAnnualCompPointService.list(new LambdaQueryWrapper<AnnualCompPoint>().in(!ObjectUtils.isEmpty(compIds), AnnualCompPoint::getAnnualCompId, compIds));
if(ObjectUtil.isEmpty(annualCompPointList)) return resultMap;
//当前年,所有项目id //当前年,所有项目id
Set<String> annualCompPointIds = Optional.ofNullable(annualCompPointList).orElse(new ArrayList<>()).stream().map(annualCompPoint -> annualCompPoint.getId()).collect(Collectors.toSet()); Set<String> annualCompPointIds = Optional.ofNullable(annualCompPointList).orElse(new ArrayList<>()).stream().map(annualCompPoint -> annualCompPoint.getId()).collect(Collectors.toSet());
if(ObjectUtil.isEmpty(annualCompPointIds)) return resultMap;
//未评奖的项目为进行中 //未评奖的项目为进行中
List<AnnualCompPoint> pj0PointList = Optional.ofNullable(annualCompPointList).orElse(new LinkedList<>()).stream().filter(bo -> "0".equals(bo.getIsPj())).collect(Collectors.toList()); List<AnnualCompPoint> pj0PointList = Optional.ofNullable(annualCompPointList).orElse(new LinkedList<>()).stream().filter(bo -> "0".equals(bo.getIsPj())).collect(Collectors.toList());
Map<String, Object> countMap = this.convertProjectLevel(annualCompPointList); Map<String, Object> countMap = this.convertProjectLevel(annualCompPointList);
@ -587,15 +598,15 @@ public class UserHomePageServiceImpl implements UserHomePageService {
scoreList4Point.stream().sorted(Comparator.comparing(HomePageCompVo::getTotalScore)).collect(Collectors.toList()); scoreList4Point.stream().sorted(Comparator.comparing(HomePageCompVo::getTotalScore)).collect(Collectors.toList());
resultMap.put("比赛学生积分况分析", scoreList4Point); resultMap.put("比赛学生积分况分析", scoreList4Point);
redisUtil.set(REPORT4SCHOOL, resultMap); redisUtil.set(REPORT4SCHOOL, resultMap);
return resultMap; }/* else {
} else {
boolean hasKey = redisUtil.hasKey(REPORT4SCHOOL); boolean hasKey = redisUtil.hasKey(REPORT4SCHOOL);
if (hasKey) { if (hasKey) {
return redisUtil.get(REPORT4SCHOOL); return redisUtil.get(REPORT4SCHOOL);
} else { } else {
return this.report4School(true); return this.report4School(annualId, true);
}
} }
}*/
return resultMap;
} }
private List<AnnualCompPoint> convertPoint4Depart(SysDepart depart) { private List<AnnualCompPoint> convertPoint4Depart(SysDepart depart) {
@ -613,11 +624,22 @@ public class UserHomePageServiceImpl implements UserHomePageService {
} }
@Override @Override
public Object report4Depart(String orgCode, boolean recreateFlag) { public Object report4Depart(String annualId, String orgCode, boolean recreateFlag) {
Assert.notNull(orgCode, "部门编号不能为空"); Assert.notNull(orgCode, "部门编号不能为空");
final String REPORT4DEPART = "report4Depart";
Map<String, Object> resultMap = new LinkedHashMap<>(); Map<String, Object> resultMap = new LinkedHashMap<>();
String currentYear;
if (StringUtils.isNotBlank(annualId)) {
Annual annual = iAnnualService.getById(annualId);
currentYear = annual.getAnnualName();
} else {
currentYear = DateUtils.getCurrentYear() + "";
}
final String REPORT4DEPART = "report4Depart-" + currentYear;
boolean hasKey = redisUtil.hasKey(REPORT4DEPART);
if (hasKey && !recreateFlag) {
return redisUtil.get(REPORT4DEPART);
}
if (recreateFlag) { if (recreateFlag) {
SysDepart sysDepart = iSysDepartService.getOne(new LambdaQueryWrapper<SysDepart>().eq(SysDepart::getOrgCode, orgCode)); SysDepart sysDepart = iSysDepartService.getOne(new LambdaQueryWrapper<SysDepart>().eq(SysDepart::getOrgCode, orgCode));
if (ObjectUtil.isNull(sysDepart)) { if (ObjectUtil.isNull(sysDepart)) {
@ -625,9 +647,10 @@ public class UserHomePageServiceImpl implements UserHomePageService {
} }
String departId = sysDepart.getParentId(); String departId = sysDepart.getParentId();
int currentYear = DateUtils.getCurrentYear();
//当前年度 //当前年度
Annual annual = iAnnualService.getOne(new LambdaQueryWrapper<Annual>().eq(Annual::getAnnualName, currentYear + "")); Annual annual = iAnnualService.getOne(new LambdaQueryWrapper<Annual>().eq(Annual::getAnnualName, currentYear + ""));
if (ObjectUtils.isEmpty(annual)) return resultMap;
List<Comp> compList = iCompService.list(new LambdaQueryWrapper<Comp>().eq(Comp::getCompOrgan, departId)); List<Comp> compList = iCompService.list(new LambdaQueryWrapper<Comp>().eq(Comp::getCompOrgan, departId));
Set<String> compIds = Optional.ofNullable(compList).orElse(new LinkedList<>()).stream().map(obj -> obj.getId()).collect(Collectors.toSet()); Set<String> compIds = Optional.ofNullable(compList).orElse(new LinkedList<>()).stream().map(obj -> obj.getId()).collect(Collectors.toSet());
@ -636,10 +659,13 @@ public class UserHomePageServiceImpl implements UserHomePageService {
.in(!ObjectUtils.isEmpty(compIds), AnnualComp::getCompid, compIds)); .in(!ObjectUtils.isEmpty(compIds), AnnualComp::getCompid, compIds));
Set<String> annualCompIds = Optional.ofNullable(annualCompList).orElse(new LinkedList<>()).stream().map(obj -> obj.getId()).collect(Collectors.toSet()); Set<String> annualCompIds = Optional.ofNullable(annualCompList).orElse(new LinkedList<>()).stream().map(obj -> obj.getId()).collect(Collectors.toSet());
if(ObjectUtil.isEmpty(annualCompIds)) return resultMap;
List<AnnualCompPoint> annualCompPointList = iAnnualCompPointService.list(new LambdaQueryWrapper<AnnualCompPoint>().in(AnnualCompPoint::getAnnualCompId, annualCompIds)); List<AnnualCompPoint> annualCompPointList = iAnnualCompPointService.list(new LambdaQueryWrapper<AnnualCompPoint>().in(AnnualCompPoint::getAnnualCompId, annualCompIds));
if(ObjectUtil.isEmpty(annualCompPointList)) return resultMap;
//该部门,当前年,所有项目id //该部门,当前年,所有项目id
Set<String> annualCompPointIds = Optional.ofNullable(annualCompPointList).orElse(new ArrayList<>()).stream().map(annualCompPoint -> annualCompPoint.getId()).collect(Collectors.toSet()); Set<String> annualCompPointIds = Optional.ofNullable(annualCompPointList).orElse(new ArrayList<>()).stream().map(annualCompPoint -> annualCompPoint.getId()).collect(Collectors.toSet());
if(ObjectUtil.isEmpty(annualCompPointIds)) return resultMap;
//未评奖的项目为进行中 //未评奖的项目为进行中
List<AnnualCompPoint> pj0PointList = Optional.ofNullable(annualCompPointList).orElse(new LinkedList<>()).stream().filter(bo -> "0".equals(bo.getIsPj())).collect(Collectors.toList()); List<AnnualCompPoint> pj0PointList = Optional.ofNullable(annualCompPointList).orElse(new LinkedList<>()).stream().filter(bo -> "0".equals(bo.getIsPj())).collect(Collectors.toList());
Map<String, Object> countMap = this.convertProjectLevel(annualCompPointList); Map<String, Object> countMap = this.convertProjectLevel(annualCompPointList);
@ -807,15 +833,8 @@ public class UserHomePageServiceImpl implements UserHomePageService {
} }
canSaiList.add(departMap); canSaiList.add(departMap);
redisUtil.set(REPORT4DEPART, resultMap); redisUtil.set(REPORT4DEPART, resultMap);
return resultMap;
} else {
boolean hasKey = redisUtil.hasKey(REPORT4DEPART);
if (hasKey) {
return redisUtil.get(REPORT4DEPART);
} else {
return this.report4Depart(orgCode, true);
}
} }
return resultMap;
} }
Map<String, Object> convertProjectLevel(List<AnnualCompPoint> annualCompPointList) { Map<String, Object> convertProjectLevel(List<AnnualCompPoint> annualCompPointList) {

@ -1,5 +1,6 @@
package org.jeecg.modules.demo.teamseq.controller; package org.jeecg.modules.demo.teamseq.controller;
import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.core.metadata.IPage;
@ -20,10 +21,7 @@ import org.springframework.web.servlet.ModelAndView;
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import java.util.Arrays; import java.util.*;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
/** /**
* @Description: 团队赛队员积分计算配置 * @Description: 团队赛队员积分计算配置
@ -64,8 +62,11 @@ public class TeamSeqController extends JeecgController<TeamSeq, ITeamSeqService>
@ApiOperation(value = "团队赛队员积分计算配置-分页列表查询", notes = "团队赛队员积分计算配置-分页列表查询") @ApiOperation(value = "团队赛队员积分计算配置-分页列表查询", notes = "团队赛队员积分计算配置-分页列表查询")
@GetMapping(value = "/listByPointId") @GetMapping(value = "/listByPointId")
public Result<Object> queryPageList(String pointId) { public Result<Object> queryPageList(String pointId) {
List<TeamSeq> list = teamSeqService.list(new LambdaQueryWrapper<TeamSeq>().eq(TeamSeq::getPointId, pointId));
Map<String, Object> map = new LinkedHashMap<>(); Map<String, Object> map = new LinkedHashMap<>();
List<TeamSeq> list =new LinkedList<>();
if (StrUtil.isNotEmpty(pointId)) {
list = teamSeqService.list(new LambdaQueryWrapper<TeamSeq>().eq(TeamSeq::getPointId, pointId));
}
map.put("records", list); map.put("records", list);
return Result.OK(map); return Result.OK(map);
} }

@ -1,12 +1,13 @@
package org.jeecg.modules.demo.teamseq.service.impl; package org.jeecg.modules.demo.teamseq.service.impl;
import cn.hutool.core.util.ObjectUtil;
import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.jeecg.common.exception.JeecgBootException;
import org.jeecg.modules.demo.teamseq.entity.TeamSeq; import org.jeecg.modules.demo.teamseq.entity.TeamSeq;
import org.jeecg.modules.demo.teamseq.mapper.TeamSeqMapper; import org.jeecg.modules.demo.teamseq.mapper.TeamSeqMapper;
import org.jeecg.modules.demo.teamseq.service.ITeamSeqService; import org.jeecg.modules.demo.teamseq.service.ITeamSeqService;
import org.jeecg.modules.demo.teamseq.vo.TeamSeqVo;
import org.springframework.beans.BeanUtils;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import java.util.List; import java.util.List;
@ -22,13 +23,15 @@ public class TeamSeqServiceImpl extends ServiceImpl<TeamSeqMapper, TeamSeq> impl
@Override @Override
public void saveOrUpdate4TeamSeq(List<TeamSeq> list) { public void saveOrUpdate4TeamSeq(List<TeamSeq> list) {
if (ObjectUtil.isEmpty(list)) {
throw new JeecgBootException("配置对象不能为空!");
}
String pointId = list.get(0).getPointId(); String pointId = list.get(0).getPointId();
if (StrUtil.isEmpty(pointId)) {
throw new JeecgBootException("比赛项目不能为空!");
}
this.remove(new LambdaQueryWrapper<TeamSeq>().eq(TeamSeq::getPointId, pointId)); this.remove(new LambdaQueryWrapper<TeamSeq>().eq(TeamSeq::getPointId, pointId));
// TeamSeqVo vo = new TeamSeqVo();
// BeanUtils.copyProperties(point, vo);
// vo.setPointId(point.getId());
// TeamSeq teamSeq = new TeamSeq();
// BeanUtils.copyProperties(vo, teamSeq);
this.saveBatch(list); this.saveBatch(list);
} }
} }

@ -206,7 +206,8 @@ export const getComprehensiveReport = (params = {}) => {
// http://localhost:18083/jeecg-boot/user/login/homepage/report4Depart // http://localhost:18083/jeecg-boot/user/login/homepage/report4Depart
export const getdepartmentReport = (params: any = {}) => { export const getdepartmentReport = (params: any = {}) => {
return defHttp.get({ return defHttp.get({
url: '/user/login/homepage/report4School', url: '/user/login/homepage/report4Depart',
params params
}) })
} }
// 11111111

@ -1,6 +1,12 @@
<template> <template>
<div style="padding: 30px 18.6vw 0; width: 100%; margin: auto">
年度<j-dict-select-tag placeholder="请选择年度" v-model:value="annualid" dictCode="annual,annual_name,id" />
</div>
<div class="container" v-if="isLoading"> <div class="container" v-if="isLoading">
<div class="title">河南机电学院比赛综合报告<div style="margin-left: 10px;cursor: pointer;"><SvgIcon name="log" @click="log"/></div></div> <div class="title"
>河南机电学院比赛综合报告<div style="margin-left: 10px; cursor: pointer"><SvgIcon name="log" @click="log" /></div
></div>
<div class="rebuild"><div @click="Rebuild">重新生成报告</div></div> <div class="rebuild"><div @click="Rebuild">重新生成报告</div></div>
<p class="description" <p class="description"
>我是比赛综述:全面落实立德树人根本任务依据CDI0工程教育理念培养德劳全面发展掌握软件工程专业所需的数学与自然科学基础知识专业基础理论知识;在企业级软件开发和工业智能软件开发方向能承担软件分析设计开发项目管理等任务具备解决复杂工程问题的能力;具有终身学习和创新创业意识国际交流能力团队合作精神等良好案养能适应产业与社会变革的国际化应用型人才<br />本专业毕业生经过五年左右的实际工作能够达到以下目标:</p >我是比赛综述:全面落实立德树人根本任务依据CDI0工程教育理念培养德劳全面发展掌握软件工程专业所需的数学与自然科学基础知识专业基础理论知识;在企业级软件开发和工业智能软件开发方向能承担软件分析设计开发项目管理等任务具备解决复杂工程问题的能力;具有终身学习和创新创业意识国际交流能力团队合作精神等良好案养能适应产业与社会变革的国际化应用型人才<br />本专业毕业生经过五年左右的实际工作能够达到以下目标:</p
@ -141,7 +147,6 @@
</div> </div>
<div class="loading" v-else> <div class="loading" v-else>
<a-spin /> <a-spin />
</div> </div>
</template> </template>
@ -154,34 +159,34 @@
import cardList5 from './components/cardList5.vue'; import cardList5 from './components/cardList5.vue';
// import cardList6 from './components/cardList6.vue'; // import cardList6 from './components/cardList6.vue';
import { SvgIcon } from '/@/components/Icon'; import { SvgIcon } from '/@/components/Icon';
import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue';
import randerChart from './components/randerChart.vue'; import randerChart from './components/randerChart.vue';
import cakeChart from './components/cakeChart.vue'; import cakeChart from './components/cakeChart.vue';
import ringChart from './components/ringChart.vue'; import ringChart from './components/ringChart.vue';
import pillarChart from './components/pillarChart.vue'; import pillarChart from './components/pillarChart.vue';
import { ref, onMounted, nextTick } from 'vue'; import { ref, onMounted, nextTick,watch } from 'vue';
import { jsPDF } from 'jspdf'; import { jsPDF } from 'jspdf';
import { getComprehensiveReport } from '/@/api/common/api'; import { getComprehensiveReport } from '/@/api/common/api';
const data = ref<any>({}) const data = ref<any>({});
const isLoading = ref<any>(false) const isLoading = ref<any>(false);
const data12 = ref<any>([]) const data12 = ref<any>([]);
const getComprehensiveReportEvent = async () => { const getComprehensiveReportEvent = async () => {
const res = await getComprehensiveReport() const res = await getComprehensiveReport();
data.value = res data.value = res;
console.log(res); console.log(res);
data12.value = JSON.stringify(res.学生能力平均值) data12.value = JSON.stringify(res.学生能力平均值);
isLoading.value = true isLoading.value = true;
};
} getComprehensiveReportEvent();
getComprehensiveReportEvent()
const Rebuild = async () => { const Rebuild = async () => {
isLoading.value = false isLoading.value = false;
const res = await getComprehensiveReport({recreateFlag:true}) const res = await getComprehensiveReport({ recreateFlag: true ,annualid:annualid.value});
data.value = res data.value = res;
console.log(res); console.log(res);
data12.value = JSON.stringify(res.学生能力平均值) data12.value = JSON.stringify(res.学生能力平均值);
isLoading.value = true isLoading.value = true;
} };
const activeKey = ref('1'); const activeKey = ref('1');
var indicator = [ var indicator = [
{ {
@ -291,6 +296,24 @@
} }
}); });
}; };
const selectYeay = async () => {
isLoading.value = false;
const res = await getComprehensiveReport({ annualid: annualid.value });
console.log(res);
data.value = res;
data12.value = JSON.stringify(res.学生能力平均值);
isLoading.value = true;
};
const annualid = ref('');
watch(
() => annualid.value,
() => {
console.log(annualid);
selectYeay();
}
);
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
@ -485,6 +508,5 @@
line-height: 50px; line-height: 50px;
font-size: 14px; font-size: 14px;
padding: 0 20px; padding: 0 20px;
} }
</style> </style>

@ -1,4 +1,7 @@
<template> <template>
<div style="padding: 30px 18.6vw 0; width: 100%; margin: auto">
年度<j-dict-select-tag placeholder="请选择年度" v-model:value="annualid" dictCode="annual,annual_name,id" />
</div>
<div class="container" v-if="isLoading"> <div class="container" v-if="isLoading">
<div class="title">河南机电学院比赛部门报告</div> <div class="title">河南机电学院比赛部门报告</div>
<div class="rebuild"><div @click="Rebuild">重新生成报告</div></div> <div class="rebuild"><div @click="Rebuild">重新生成报告</div></div>
@ -115,7 +118,6 @@
<div class="left border-000"> <div class="left border-000">
<!-- <div class="border-title">年度维度分析</div> --> <!-- <div class="border-title">年度维度分析</div> -->
<ringChart :data="data.比赛获奖占比" /> <ringChart :data="data.比赛获奖占比" />
</div> </div>
</div> </div>
<div class="footer-edit border-000"> <div class="footer-edit border-000">
@ -130,7 +132,6 @@
<div class="right border-000"> <div class="right border-000">
<cardList7 :data="data.部门参赛情况列表" /> <cardList7 :data="data.部门参赛情况列表" />
</div> </div>
</div> </div>
<!-- <div class="footer border-000"> <!-- <div class="footer border-000">
<cardList6 :data="data.部门获奖情况列表"/> <cardList6 :data="data.部门获奖情况列表"/>
@ -138,7 +139,6 @@
</div> </div>
<div class="loading" v-else> <div class="loading" v-else>
<a-spin /> <a-spin />
</div> </div>
</template> </template>
@ -155,34 +155,42 @@
import ringChart from './components/ringChart.vue'; import ringChart from './components/ringChart.vue';
import pillarChart from './components/pillarChart.vue'; import pillarChart from './components/pillarChart.vue';
import { getdepartmentReport } from '/@/api/common/api'; import { getdepartmentReport } from '/@/api/common/api';
import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue';
import { ref } from 'vue'; import { ref, watch } from 'vue';
import {useUserStore} from '/@/store/modules/user' import { useUserStore } from '/@/store/modules/user';
const userStore = useUserStore() const userStore = useUserStore();
const activeKey = ref('1'); const activeKey = ref('1');
const data = ref<any>({}) const data = ref<any>({});
const isLoading = ref<any>(false) const isLoading = ref<any>(false);
const data12 = ref<any>([]) const data12 = ref<any>([]);
const getdepartmentReportEvent = async () => { const getdepartmentReportEvent = async () => {
const res = await getdepartmentReport({orgCode:userStore.userInfo.id const res = await getdepartmentReport({ orgCode: userStore.userInfo.orgCode });
})
console.log(res); console.log(res);
data.value = res data.value = res;
data12.value = JSON.stringify(res.学生能力平均值) data12.value = JSON.stringify(res.学生能力平均值);
isLoading.value = true isLoading.value = true;
} };
getdepartmentReportEvent() getdepartmentReportEvent();
const Rebuild = async () => { const Rebuild = async () => {
isLoading.value = false isLoading.value = false;
const res = await getdepartmentReport({recreateFlag:true,orgCode:userStore.userInfo.id const res = await getdepartmentReport({ recreateFlag: true, orgCode: userStore.userInfo.orgCode, annualid: annualid.value });
})
console.log(res); console.log(res);
data.value = res data.value = res;
data12.value = JSON.stringify(res.学生能力平均值) data12.value = JSON.stringify(res.学生能力平均值);
isLoading.value = true isLoading.value = true;
} };
const selectYeay = async () => {
isLoading.value = false;
const res = await getdepartmentReport({ orgCode: userStore.userInfo.orgCode, annualid: annualid.value });
console.log(res);
data.value = res;
data12.value = JSON.stringify(res.学生能力平均值);
isLoading.value = true;
};
var indicator = [ var indicator = [
{ {
text: '前言探索', text: '前言探索',
@ -233,6 +241,15 @@
max: 5000, max: 5000,
}, },
]; ];
const annualid = ref('');
watch(
() => annualid.value,
() => {
console.log(annualid);
selectYeay();
}
);
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>

Loading…
Cancel
Save