diff --git a/src/app/student/examination-details/examination-details.component.html b/src/app/student/examination-details/examination-details.component.html index aa1ab18..274315c 100644 --- a/src/app/student/examination-details/examination-details.component.html +++ b/src/app/student/examination-details/examination-details.component.html @@ -7,7 +7,9 @@
单位名称
总分
单位名称
总分
-
+
+ +
diff --git a/src/app/student/examination-details/examination-details.component.ts b/src/app/student/examination-details/examination-details.component.ts index 5effe16..af843a9 100644 --- a/src/app/student/examination-details/examination-details.component.ts +++ b/src/app/student/examination-details/examination-details.component.ts @@ -13,16 +13,27 @@ export class ExaminationDetailsComponent implements OnInit { constructor(public http:HttpClient,public dialog: MatDialog,public snackBar: MatSnackBar,public route:ActivatedRoute) { } - ngOnInit(): void { - this.getTestInfo() + async ngOnInit(): Promise { + await this.getTestInfo() + console.log(2) } + paperData:any//试卷信息 //获取考卷 - getTestInfo () { + async getTestInfo () { let id = this.route.snapshot.queryParams.paperId - this.http.get(`/api/Papers/${id}`).subscribe((data:any)=>{ - console.log(data) + await new Promise((resolve, reject) => { + this.http.get(`/api/Papers/${id}`).subscribe((data:any)=>{ + console.log(data) + this.paperData = data + resolve(1) + }) }) + } + //获得单位预案设定 + getUnitPlans(){ + + } }