Browse Source

无改-1

1
mo 3 years ago
parent
commit
f029f2f529
2 changed files with 15 additions and 7 deletions
  1. 8 3
      src/views/teamBuild/forecastName.vue
  2. 7 4
      src/views/teamBuild/initiationList.vue

+ 8 - 3
src/views/teamBuild/forecastName.vue

@@ -50,6 +50,7 @@
         @reset="onReSet"
         @submit="search"
         :model="searchForm"
+        save-key='/forecastName'
         ref="searchForm"
       >
         <el-form-item prop="name">
@@ -77,7 +78,7 @@
             placeholder="老师推荐声部"
           >
             <el-option
-              v-for="item in selects.subjects"
+              v-for="item in subjectList"
               :value="item.id"
               :label="item.name"
               :key="item.id"
@@ -187,7 +188,7 @@
                   : null
               }}
               {{
-                !scope.row.teacherRecommandSubjectId &&
+                scope.row.teacherRecommandSubjectId==-1 &&
                 !scope.row.teacherRecommandSubjectName
                   ? "无"
                   : null
@@ -297,6 +298,7 @@
           </el-table-column>
         </el-table>
         <pagination
+          save-key='/forecastName'
           sync
           :total.sync="pageInfo.total"
           :page.sync="pageInfo.page"
@@ -473,11 +475,14 @@ export default {
       },
       preLookVisible: false,
       sysMsg:'',
+      subjectList:[]
     };
   },
 async mounted() {
-    this.$store.dispatch("setSubjects");
+   await this.$store.dispatch("setSubjects");
          // 获取短信推送模板
+         this.subjectList = [...this.selects.subjects]
+this.subjectList.push({id:-1,name:'无'})
       const rus = await getSysMessageConfig({
         type: "STUDENT_SMS_IM_MUSIC_GROUP_PARENT_MEETING_NOTICE",
       });

+ 7 - 4
src/views/teamBuild/initiationList.vue

@@ -79,7 +79,7 @@
             placeholder="老师推荐声部"
           >
             <el-option
-              v-for="item in selects.subjects"
+              v-for="item in subjectList"
               :value="item.id"
               :label="item.name"
               :key="item.id"
@@ -140,7 +140,7 @@
             <template slot-scope="scope">
               <div>
                 {{
-                  scope.row.teacherRecommandSubjectId
+                  scope.row.teacherRecommandSubjectId==-1
                     ? scope.row.subjectName
                     : "无"
                 }}
@@ -351,10 +351,13 @@ export default {
       gradeList: [],
       preLookVisible: false,
       sysMsg: "",
+      subjectList:[]
     };
   },
-  mounted() {
-    this.$store.dispatch("setSubjects");
+ async mounted() {
+  await  this.$store.dispatch("setSubjects");
+this.subjectList = [...this.selects.subjects]
+this.subjectList.push({id:-1,name:'无'})
     this.init();
   },
   methods: {