|
@@ -66,6 +66,7 @@ const open = async (id?: number) => {
|
|
|
if (id) {
|
|
|
formLoading.value = true
|
|
|
try {
|
|
|
+ getSupervisor(id)
|
|
|
const data = await studentSelectionProjectApi.getStudentSelectExternalSupervisorsList(id)
|
|
|
formData.value.studentList = data;
|
|
|
} finally {
|
|
@@ -94,9 +95,9 @@ const submitForm = async () => {
|
|
|
|
|
|
// 获取所有导师
|
|
|
const supervisors = ref<{ id: number; nickname: string }[]>([])
|
|
|
-const getSupervisor = async () => {
|
|
|
+const getSupervisor = async (id) => {
|
|
|
try {
|
|
|
- const result = await studentSelectionProjectApi.getProjectInnerSupervisors()
|
|
|
+ const result = await studentSelectionProjectApi.getProjectInnerSupervisors(id)
|
|
|
supervisors.value = result
|
|
|
} catch (error) {
|
|
|
console.error('未获取到导师', error)
|
|
@@ -104,7 +105,4 @@ const getSupervisor = async () => {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-onMounted(() => {
|
|
|
- getSupervisor()
|
|
|
-})
|
|
|
</script>
|