Merge branch 'main' of http://47.112.118.149:10082/xgxt_sd/zhxg_pc
This commit is contained in:
@@ -25,6 +25,15 @@ export function listLeftJoin(query){
|
||||
});
|
||||
}
|
||||
|
||||
//根据学号查询学生的体测成绩
|
||||
export function selectTestStu(query){
|
||||
return request({
|
||||
url:"/system/score/selectTestStu",
|
||||
method:"get",
|
||||
params:query
|
||||
});
|
||||
}
|
||||
|
||||
// 查询体能测试列表
|
||||
export function listSportTest(query) {
|
||||
return request({
|
||||
|
||||
@@ -276,8 +276,7 @@ import { getTokenKeySessionStorage as getToken } from "@/utils/auth";
|
||||
|
||||
import GlApply from "@/views/comprehensive/knzzGlApply/cpnt/GlApply.vue";
|
||||
import GlLook from "@/views/comprehensive/knzzGlApply/cpnt/GlLook.vue";
|
||||
|
||||
import {listOwnSportScore} from "@/api/comprehensive/biyeapply";
|
||||
import {selectTestStu} from "@/api/stuCQS/info-fill/sportTest";
|
||||
import { getDicts } from "@/api/system/dict/data";
|
||||
import { listDisciplinaryApplication } from "@/api/routine/disciplinaryApplication";
|
||||
import { getOwnStuScoreMajorRank } from "@/api/comprehensive/biyeapply";
|
||||
@@ -461,7 +460,7 @@ export default {
|
||||
async checkAllConditions() {
|
||||
try {
|
||||
const [sportResult, disciplinaryResult, scoreResult] = await Promise.all([
|
||||
this.fetchSportScoreData(),
|
||||
this.fetchTestScoreData(),
|
||||
this.fetchcfwjc(),
|
||||
this.fetchcjpm()
|
||||
]);
|
||||
@@ -471,16 +470,16 @@ export default {
|
||||
this.applyV = false;
|
||||
}
|
||||
},
|
||||
async fetchSportScoreData() {
|
||||
const res = await listOwnSportScore().catch(() => {
|
||||
async fetchTestScoreData() {
|
||||
const res = await selectTestStu().catch(() => {
|
||||
this.$message.info("体能测试数据获取失败");
|
||||
return { code: 500, data: [] };
|
||||
return { code: 500, rows: [] };
|
||||
});
|
||||
if (res.code === 200 && res.data && res.data.length > 1) {
|
||||
const sportScore = res.data[res.data.length - 1].sportScore;
|
||||
if (sportScore >= 60) {
|
||||
if (res.code === 200 && res.rows && res.rows.length > 0) {
|
||||
const testScore = res.rows[res.rows.length - 1].testScore;
|
||||
if (testScore >= 60) {
|
||||
return true;
|
||||
} else if (sportScore === 0) {
|
||||
} else if (testScore === 0) {
|
||||
this.$message.info("当前学年没有您的体能成绩");
|
||||
return false;
|
||||
} else {
|
||||
@@ -528,7 +527,7 @@ export default {
|
||||
return { code: 500 };
|
||||
});
|
||||
loading.close();
|
||||
if (res.code === 200) {
|
||||
if (res.code === 200 && res.data && res.data.majorRank != null && res.data.majorCount != null) {
|
||||
let data = res.data;
|
||||
let stuRank = Math.round(Math.round(data.majorRank / data.majorCount * 10000) / 100);
|
||||
if (stuRank <= 30) {
|
||||
@@ -538,6 +537,7 @@ export default {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
this.$message.info("无法获取您的专业排名数据");
|
||||
return false;
|
||||
},
|
||||
/* async fetchSportScoreData() {
|
||||
|
||||
Reference in New Issue
Block a user