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