浏览代码

0106 11:12

跨团调整增加验证
mo 5 年之前
父节点
当前提交
1975ee2f55
共有 3 个文件被更改,包括 35 次插入13 次删除
  1. 24 11
      src/views/setSilder/addSilder.vue
  2. 9 0
      src/views/teamBuild/components/teamResetSound.vue
  3. 2 2
      vue.config.js

+ 24 - 11
src/views/setSilder/addSilder.vue

@@ -1,33 +1,42 @@
 <template>
   <div class="slider-container">
-    <el-button @click='onOperation("create")' style="position: fixed; z-index: 100;">添加按钮</el-button>
+    <el-button @click='onOperation("create")'
+               style="position: fixed; z-index: 100;">添加按钮</el-button>
 
     <el-table :data="tableList"
               style="width: 100%;margin-bottom: 20px;"
               row-key="id"
               border
               :tree-props="{children: 'children', hasChildren: 'hasChildren'}">
-      <el-table-column width="400px" prop="name"
+      <el-table-column width="400px"
+                       prop="name"
                        label="菜单名称">
       </el-table-column>
-      <el-table-column prop="id" width="100px"
+      <el-table-column prop="id"
+                       width="100px"
                        label="元素ID">
       </el-table-column>
-      <el-table-column label="菜单类型" width="100px">
+      <el-table-column label="菜单类型"
+                       width="100px">
         <template slot-scope="scope">
           {{ scope.row.type == 1 ? '按钮' : '菜单' }}
         </template>
       </el-table-column>
-      <el-table-column prop="sort" width="100px"
+      <el-table-column prop="sort"
+                       width="100px"
                        label="排序">
       </el-table-column>
       <el-table-column prop="path"
                        label="文件路径">
       </el-table-column>
+      <el-table-column prop="parentPermission"
+                       label="高亮地址">
+      </el-table-column>
       <el-table-column prop="permission"
                        label="权限标识">
       </el-table-column>
-      <el-table-column prop="hid" width="100px"
+      <el-table-column prop="hid"
+                       width="100px"
                        label="是否隐藏">
         <template slot-scope="scope">
           {{ scope.row.hid == 1 ? '隐藏' : '不隐藏' }}
@@ -43,7 +52,7 @@
       </el-table-column>
     </el-table>
     <el-dialog title="侧边栏管理"
-                :close-on-click-modal="false"
+               :close-on-click-modal="false"
                :visible.sync="branchStatus"
                default-expand-all
                @close="onFormClose('ruleForm')"
@@ -78,15 +87,19 @@
         <el-form-item label="是否隐藏"
                       :label-width="formLabelWidth">
           <el-select v-model="form.hid">
-            <el-option label="否" :value="0"></el-option>
-            <el-option label="是" :value="1"></el-option>
+            <el-option label="否"
+                       :value="0"></el-option>
+            <el-option label="是"
+                       :value="1"></el-option>
           </el-select>
         </el-form-item>
         <el-form-item label="菜单类型"
                       :label-width="formLabelWidth">
           <el-select v-model.number="form.type">
-            <el-option label="菜单" :value="0"></el-option>
-            <el-option label="按钮" :value="1"></el-option>
+            <el-option label="菜单"
+                       :value="0"></el-option>
+            <el-option label="按钮"
+                       :value="1"></el-option>
           </el-select>
         </el-form-item>
         <el-form-item label="排序"

+ 9 - 0
src/views/teamBuild/components/teamResetSound.vue

@@ -497,6 +497,10 @@ export default {
       // 添加商品以及教辅
       // 添加声部
       obj.musicGroupSubjectPlans = [];
+      if (this.activeSoundList.length <= 0) {
+        this.$message.error('乐团至少有一个声部')
+        return
+      }
       for (let i in this.activeSoundList) {
         let item = {};
         // expectedStudentNum
@@ -512,6 +516,11 @@ export default {
         // expectedStudentNum
         item.subjectId = this.activeSoundList[i].id;
         item.registerIdList = []
+
+        if (this.activeSoundList[i].studentList.length <= 0) {
+          this.$message.error(`${this.activeSoundList[i].sound}声部至少有一个学生`)
+          return
+        }
         for (let j in this.activeSoundList[i].studentList) {
           item.registerIdList.push(this.activeSoundList[i].studentList[j].id)
         }

+ 2 - 2
vue.config.js

@@ -19,9 +19,9 @@ const name = defaultSettings.title || '管乐迷后台管理系统' // page titl
 // let target = 'https://online.dayaedu.com' //线上
 // let target = 'http://testadm.dayaedu.com/' //test环境
 // let target = 'http://192.168.3.27:8000' // 箭河
-// let target = 'http://192.168.3.28:8000' //邹璇
+let target = 'http://192.168.3.28:8000' //邹璇
 // let target = 'http://192.168.3.8:18000' //勇哥
-let target = 'http://admin.dayaedu.com/' // 测试服
+// let target = 'http://admin.dayaedu.com/' // 测试服
 // let target = 'http://192.168.3.48:8080' // 乔
 // All configuration item explanations can be find in https://cli.vuejs.org/config/
 module.exports = {