From f66a3edbf08da194d576af01b38881090b78e50f Mon Sep 17 00:00:00 2001
From: xiangpei <xiangpei@timesnew.cn>
Date: 星期三, 26 六月 2024 13:49:41 +0800
Subject: [PATCH] 班级学员新增bug
---
vue.config.js | 3 +--
src/views/class-management/ClassStaff.vue | 9 ++++-----
2 files changed, 5 insertions(+), 7 deletions(-)
diff --git a/src/views/class-management/ClassStaff.vue b/src/views/class-management/ClassStaff.vue
index 2e20b1b..047e4fa 100644
--- a/src/views/class-management/ClassStaff.vue
+++ b/src/views/class-management/ClassStaff.vue
@@ -61,7 +61,6 @@
<template slot-scope="scope">
<el-button @click="handlerEditStudent(scope.row)" type="warning">缂栬緫</el-button>
<el-button @click="remove(scope.row.id)" type="danger">鍒犻櫎</el-button>
- <el-button type="primary">鍒嗛厤瑙掕壊</el-button>
</template>
</el-table-column>
</el-table>
@@ -84,8 +83,8 @@
</el-form-item>
<el-form-item label="鎬у埆" prop="sex">
<el-select v-model="studentForm.sex">
- <el-option label="鐢�" value="N"></el-option>
- <el-option label="濂�" value="V"></el-option>
+ <el-option label="鐢�" :value="1"></el-option>
+ <el-option label="濂�" :value="2"></el-option>
</el-select>
</el-form-item>
<el-form-item label="鐢佃瘽" prop="phone">
@@ -142,7 +141,7 @@
return {
studentForm: {
realName: '',
- sex: '',
+ sex: 1,
phone: '',
age: null,
account: '',
@@ -206,7 +205,7 @@
submitStudentForm () {
this.$refs['studentForm'].validate((valid) => {
if (valid) {
- this.studentForm.classes = this.classes.id
+ this.studentForm.classesId = this.classes.id
if (this.studentForm.id) {
edit(this.studentForm).then(res => {
this.addOpen = false
diff --git a/vue.config.js b/vue.config.js
index cc6f74c..2e3c632 100644
--- a/vue.config.js
+++ b/vue.config.js
@@ -19,8 +19,7 @@
hotOnly: false,
proxy: {
'/api': {
- // target: 'http://localhost:8000',
- target: 'http://192.168.3.64:8000',
+ target: 'http://localhost:8000',
changeOrigin: true
}
}
--
Gitblit v1.8.0