|
@@ -35,7 +35,7 @@
|
|
|
<span style="margin: 0" v-else>{{ lang.KekeleboPlatform }}</span>
|
|
|
</div>
|
|
|
<div v-if="steps == 2">
|
|
|
- <div style="margin-left: 10px">{{ this.codeRes.school }}</div>
|
|
|
+ <div style="margin-left: 10px">{{ codeRes.school }} - {{ codeClassName }}</div>
|
|
|
</div>
|
|
|
<div
|
|
|
v-if="steps == 2"
|
|
@@ -348,6 +348,8 @@ export default {
|
|
|
SuffixShow: false,
|
|
|
// 组织号查询区域结果
|
|
|
SuffixData: "",
|
|
|
+ // 获取随机码班级名称
|
|
|
+ codeClassName:'',
|
|
|
orginfo: [],
|
|
|
codeRes: "",
|
|
|
CodeOptions: [],
|
|
@@ -1049,10 +1051,11 @@ export default {
|
|
|
|
|
|
this.$ajax
|
|
|
.post(API_CONFIG.baseUrl, params)
|
|
|
- .then((res) => {
|
|
|
+ .then(async (res) => {
|
|
|
if (res.data.length && res.data[0].length) {
|
|
|
this.codeRes = res.data[0][0];
|
|
|
this.courseId = res.data[0][0].courseId;
|
|
|
+ await this.getClassName(res.data[0][0].classid)
|
|
|
this.getClass(res.data[0][0].classid);
|
|
|
} else {
|
|
|
this.$message.error(this.lang.codenotexist);
|
|
@@ -1062,6 +1065,27 @@ export default {
|
|
|
console.error(err);
|
|
|
});
|
|
|
},
|
|
|
+ async getClassName(val){
|
|
|
+ let params = [
|
|
|
+ {
|
|
|
+ functionName: API_CONFIG.ajax_selectliyuanCodename.functionName, // 调用存储过程的名称
|
|
|
+ cid: val,
|
|
|
+ },
|
|
|
+ ];
|
|
|
+ return new Promise((resolve, reject) => {
|
|
|
+ this.$ajax
|
|
|
+ .post(API_CONFIG.baseUrl, params)
|
|
|
+ .then((res) => {
|
|
|
+ this.codeClassName = res.data[0][0].name
|
|
|
+ resolve(1)
|
|
|
+ })
|
|
|
+ .catch((err) => {
|
|
|
+ reject(err)
|
|
|
+ console.error(err);
|
|
|
+ });
|
|
|
+ })
|
|
|
+
|
|
|
+ },
|
|
|
// 根据随机码获取学生
|
|
|
getClass(classId) {
|
|
|
let params = [
|