xiangpei
2024-06-26 f66a3edbf08da194d576af01b38881090b78e50f
班级学员新增bug
2个文件已修改
12 ■■■■■ 已修改文件
src/views/class-management/ClassStaff.vue 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
vue.config.js 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
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
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
      }
    }