Browse Source

fiex:新增章导入节,修改学时审核等参数替换及修复细节漏洞

Tang 3 years ago
parent
commit
cd11c6f0aa

+ 3 - 1
src/assets/styles/index.scss

@@ -19,7 +19,9 @@ body {
 label {
   font-weight: 700;
 }
-
+.myMessageClass{
+  z-index: 3000!important;
+}
 html {
   height: 100%;
   box-sizing: border-box;

+ 33 - 0
src/components/searchBoxNew.vue

@@ -26,6 +26,19 @@
         >
       </div>
     </div>
+    <div class="inputListBox" v-if="hoursType">
+      <div class="fon_s">审核状态:</div>
+      <div>
+        <el-button
+          :type="formData.periodStatus === item.value ? 'primary' : ''"
+          :size="size"
+          v-for="(item, index) in lists6"
+          :key="index"
+          @click="topHoursSearchsh(item.value)"
+          >{{ item.label }}</el-button
+        >
+      </div>
+    </div>
     <!-- <div class="inputListBox" v-if="classType">
       <div>
         <el-button
@@ -439,6 +452,7 @@ export default {
     "topType",
     "formData",
     "shType",
+    "hoursType",
     "redIcon",
     "advanced",
     "advancedName",
@@ -486,6 +500,16 @@ export default {
           value: 3,
         },
       ],
+      lists6: [
+        {
+          label: "待审核",
+          value: 2,
+        },
+        {
+          label: "审核中",
+          value: 3,
+        }
+      ],
       // classLists: [
       //   {
       //     label: "全部",
@@ -740,6 +764,15 @@ export default {
       this.formData.status = types;
       this.$emit("search", 3);
     },
+    /**
+     *
+     * @param {int} status
+     * @remark 顶部定制按钮-根据学时审核状态点击快速搜索
+     */
+    topHoursSearchsh(types) {
+      this.formData.periodStatus = types;
+      this.$emit("search", 2);
+    },
     /**
      * @remark 搜索
      */

+ 3 - 3
src/components/tableList.vue

@@ -914,11 +914,11 @@
             {{
               scope.row[item.prop] === -1
                 ? "不可审核"
-                : scope.row[item.prop] === 0
+                : scope.row[item.prop] === 2
                 ? "待审核"
-                : scope.row[item.prop] === 1
+                : scope.row[item.prop] === 0
                 ? "未通过"
-                : scope.row[item.prop] === 2
+                : scope.row[item.prop] === 1
                 ? "通过"
                 : scope.row[item.prop] === 3
                 ? "审核中"

+ 1 - 1
src/views/Marketing/goods/courseInquiryList/index.vue

@@ -17,7 +17,7 @@
     >
       <template slot="btn" slot-scope="props">
         <el-button type="text" @click="msgInfo(props.scope.row)"
-          >详情</el-button
+          >课程内容详情</el-button
         >
       </template>
     </table-list>

+ 36 - 14
src/views/education/classManageMent/classHours/index.vue

@@ -20,7 +20,7 @@
         ><el-button
           :type="activeBtn === 3 ? 'primary' : ''"
           :size="size"
-          @click="changeBTN(3)"
+          @click="changeBTN(4)"
           >全部</el-button
         ><el-button
           :type="activeBtn === 2 ? 'primary' : ''"
@@ -39,25 +39,30 @@
                 : ''
             "
             style="font-weight: bold"
-          ></i>
-          <!-- <i
+          ></i></el-button
+        ><el-button
+          :type="activeBtn === 0 ? 'primary' : ''"
+          :size="size"
+          @click="changeBTN(0)"
+          >不通过</el-button
+        ><el-button
+          :type="activeBtn === 2 ? 'primary' : ''"
+          :size="size"
+          @click="changeBTN(3)"
+          >审核中
+          <i
             class="el-icon-warning-outline"
             :style="
-              reviewListNums >= 3
+              underReiviewNums >= 200
                 ? 'color:red;'
-                : reviewListNums < 3 && reviewListNums > 1
+                : underReiviewNums < 200 && underReiviewNums > 99
                 ? 'color:green'
-                : reviewListNums <= 1
+                : underReiviewNums < 100
                 ? 'color:block;'
                 : ''
             "
             style="font-weight: bold"
-          ></i> --> </el-button
-        ><el-button
-          :type="activeBtn === 0 ? 'primary' : ''"
-          :size="size"
-          @click="changeBTN(0)"
-          >不通过</el-button
+          ></i></el-button
         ><el-button
           :type="activeBtn === 1 ? 'primary' : ''"
           :size="size"
@@ -159,6 +164,7 @@ export default {
   data() {
     return {
       reviewListNums: 0,
+      underReiviewNums: 0,
       statusShow: "", //1无官方接口按钮 2只有官方推送 3都有
       size: "medium",
       active: 2,
@@ -295,7 +301,7 @@ export default {
         },
         {
           label: "学时审批状态",
-          prop: "allStatus",
+          prop: "periodStatus",
           hidden: true,
           scope: "statusPeriod",
           width: "130px",
@@ -322,11 +328,13 @@ export default {
     await this.getStatus();
     this.search();
     this.getInitList();
+    this.getInitUnderList();
   },
   activated() {
     this.getStatus();
     this.search();
     this.getInitList();
+    this.getInitUnderList();
   },
   methods: {
     uploadXS() {
@@ -498,7 +506,7 @@ export default {
         };
       }
       if (int === 6) {
-        if (this.activeBtn == 3) {
+        if (this.activeBtn == 4) {
           this.formData = {
             gradeId: this.$route.query.id,
             status: "0,1",
@@ -549,6 +557,20 @@ export default {
           this.reviewListNums = res.rows.length;
         });
     },
+    /**
+     * 审核中数量
+     */
+    getInitUnderList() {
+      this.$api
+        .inquireGradegradelistUserPeriod({
+          periodStatus: 3,
+          gradeId: this.$route.query.id,
+          status: "0,1",
+        })
+        .then((res) => {
+          this.underReiviewNums = res.rows.length;
+        });
+    },
     handleSizeChange(v) {
       this.formData.pageSize = v;
       this.formData.pageNum = 1;

+ 26 - 26
src/views/education/classManageMent/classHoursReview/studyTimes.vue

@@ -89,24 +89,24 @@
         </div>
         <div class="shbtns">
           学时审批状态:{{
-            userData.allStatus === 1
+            userData.periodStatus === 0
               ? "未通过"
-              : userData.allStatus === 0
+              : userData.periodStatus === 2
               ? "待审核"
-              : userData.allStatus === -1
+              : userData.periodStatus === -1
               ? "不可审核"
-              : userData.allStatus === 2
+              : userData.periodStatus === 1
               ? "通过审核"
-              : userData.allStatus === 3
+              : userData.periodStatus === 3
               ? "审核中"
               : "未知状态,请联系管理员"
           }}
         </div>
       </div>
       <div class="s_sd">
-        <span v-if="userData.allStatus !== 3">
+        <span v-if="userData.periodStatus !== 3">
           <el-checkbox
-            v-if="userData.allStatus === 0"
+            v-if="userData.periodStatus === 2"
             :disabled="!getAllList.length"
             :indeterminate="isIndeterminate"
             v-model="checkAll"
@@ -116,13 +116,13 @@
           <el-button
             style="margin-left: 10px"
             size="mini"
-            v-if="userData.allStatus === 0"
+            v-if="userData.periodStatus === 2"
             @click="getChangeStatus(1)"
             >勾选通过</el-button
           >
           <el-button
             size="mini"
-            v-if="userData.allStatus === 0"
+            v-if="userData.periodStatus === 2"
             @click="getChangeStatus(2)"
             >勾选作弊</el-button
           >
@@ -234,9 +234,9 @@
                 <div
                   class="styFlex"
                   v-if="
-                    (userData.allStatus === 0 ||
-                      userData.allStatus === 1 ||
-                      userData.allStatus === 3) &&
+                    (userData.periodStatus === 0 ||
+                      userData.periodStatus === 2 ||
+                      userData.periodStatus === 3) &&
                     scope.row.periodStatus === 1
                   "
                 >
@@ -245,7 +245,7 @@
                       class="checkboxList"
                       :label="scope.row.periodStatusId"
                       :disabled="
-                        userData.allStatus === 3
+                        userData.periodStatus === 3
                           ? false
                           : scope.row.status !== 2
                           ? true
@@ -358,9 +358,9 @@
                       <div
                         class="styFlex"
                         v-if="
-                          (userData.allStatus === 0 ||
-                            userData.allStatus === 1 ||
-                            userData.allStatus === 3) &&
+                          (userData.periodStatus === 0 ||
+                            userData.periodStatus === 2 ||
+                            userData.periodStatus === 3) &&
                           scope2.row.periodStatus === 1
                         "
                       >
@@ -369,7 +369,7 @@
                             class="checkboxList"
                             :label="scope2.row.periodStatusId"
                             :disabled="
-                              userData.allStatus === 3
+                              userData.periodStatus === 3
                                 ? false
                                 : scope2.row.status !== 2
                                 ? true
@@ -477,9 +477,9 @@
                             <div
                               class="styFlex"
                               v-if="
-                                (userData.allStatus === 0 ||
-                                  userData.allStatus === 1 ||
-                                  userData.allStatus === 3) &&
+                                (userData.periodStatus === 0 ||
+                                  userData.periodStatus === 2 ||
+                                  userData.periodStatus === 3) &&
                                 scope3.row.periodStatus === 1
                               "
                             >
@@ -488,7 +488,7 @@
                                   class="checkboxList"
                                   :label="scope3.row.periodStatusId"
                                   :disabled="
-                                    userData.allStatus === 3
+                                    userData.periodStatus === 3
                                       ? false
                                       : scope3.row.status !== 2
                                       ? true
@@ -1161,8 +1161,8 @@ export default {
     },
   },
   watch: {
-    "userData.allStatus"(val, oldVal) {
-      if (val == 3 && oldVal == 0) {
+    "userData.periodStatus"(val, oldVal) {
+      if (val == 3 && oldVal == 2) {
         this.search();
       }
     },
@@ -1743,7 +1743,7 @@ export default {
           tab1.forEach((item) => {
             item.classPeriods.forEach((items) => {
               items.classPeriodSectionList.forEach((itemsxs) => {
-                if (self.userData.allStatus === 3) {
+                if (self.userData.periodStatus === 3) {
                   getAllList1.push(itemsxs.periodStatusId);
                   allArrays.push(itemsxs);
                 } else {
@@ -1760,7 +1760,7 @@ export default {
           let getAllList2 = [];
           tab2.forEach((item) => {
             item.classPeriodSectionList.forEach((items) => {
-              if (self.userData.allStatus === 3) {
+              if (self.userData.periodStatus === 3) {
                 getAllList2.push(items.periodStatusId);
                 allArrays.push(items);
               } else {
@@ -1775,7 +1775,7 @@ export default {
            */
           let getAllList3 = [];
           tab3.forEach((item) => {
-            if (self.userData.allStatus === 3) {
+            if (self.userData.periodStatus === 3) {
               getAllList3.push(item.periodStatusId);
               allArrays.push(item);
             } else {

+ 63 - 19
src/views/education/classManageMent/learningHoursRecordList/index.vue

@@ -178,6 +178,33 @@ export default {
             },
           ],
         },
+        {
+          prop: "periodStatus",
+          placeholder: "学时审核状态",
+          scope: "select",
+          options: [
+            {
+              label: "不可审核",
+              value: -1,
+            },
+            {
+              label: "待审核",
+              value: 2,
+            },
+            {
+              label: "审核不通过",
+              value: 0,
+            },
+            {
+              label: "审核通过",
+              value: 1,
+            },
+            {
+              label: "审核中",
+              value: 3,
+            },
+          ],
+        },
         {
           prop: "learnStatus",
           placeholder: "请选择学时官方推送状态",
@@ -222,11 +249,6 @@ export default {
       },
       // 表单
       tableSet: [
-        {
-          label: "学员编码",
-          prop: "studentCode",
-          hidden: true,
-        },
         {
           label: "学员姓名",
           prop: "realName",
@@ -237,11 +259,6 @@ export default {
           prop: "idCard",
           hidden: true,
         },
-        {
-          label: "手机号码",
-          prop: "telPhone",
-          hidden: true,
-        },
         {
           label: "一寸头像照",
           prop: "oneInchPhotos",
@@ -250,7 +267,7 @@ export default {
           width: "120px",
         },
         {
-          label: "身份证正面照",
+          label: "最近头像照",
           prop: "idCardImg1",
           hidden: true,
           scope: "img",
@@ -266,14 +283,6 @@ export default {
           prop: "classHours",
           hidden: true,
         },
-        {
-          label: "学习服务期",
-          prop1: "studyStartTime",
-          prop2: "studyEndTime",
-          scope: "TimeLists",
-          Diszing: false,
-          hidden: true,
-        },
         {
           label: "所在班级",
           prop: "className",
@@ -287,6 +296,13 @@ export default {
           Diszing: false,
           hidden: true,
         },
+        {
+          label: "学习时间",
+          prop1: "studyStartTime",
+          prop2: "studyEndTime",
+          scope: "TimeLists",
+          hidden: true,
+        },
         {
           label: "学习状态",
           prop: "periodStatus",
@@ -311,6 +327,34 @@ export default {
             },
           ],
         },
+        {
+          label: "学时审核状态",
+          prop: "periodStatus",
+          hidden: true,
+          scope: "isOptions",
+          options: [
+            {
+              label: "不可审核",
+              value: -1,
+            },
+            {
+              label: "待审核",
+              value: 2,
+            },
+            {
+              label: "审核不通过",
+              value: 0,
+            },
+            {
+              label: "审核通过",
+              value: 1,
+            },
+            {
+              label: "审核中",
+              value: 3,
+            },
+          ],
+        },
         {
           label: "学时官方推送状态",
           prop: "learnStatus",

+ 26 - 26
src/views/education/classManageMent/learningHoursRecordList/studyTimesRecord.vue

@@ -111,24 +111,24 @@
         </div>
         <div class="shbtns">
           学时审批状态:{{
-            userData.allStatus === 1
+            userData.periodStatus === 0
               ? "未通过"
-              : userData.allStatus === 0
+              : userData.periodStatus === 2
               ? "待审核"
-              : userData.allStatus === -1
+              : userData.periodStatus === -1
               ? "不可审核"
-              : userData.allStatus === 2
+              : userData.periodStatus === 1
               ? "通过审核"
-              : userData.allStatus === 3
+              : userData.periodStatus === 3
               ? "审核中"
               : "未知状态,请联系管理员"
           }}
         </div>
       </div>
       <div class="s_sd">
-        <span v-if="userData.allStatus !== 3">
+        <span v-if="userData.periodStatus !== 3">
           <el-checkbox
-            v-if="userData.allStatus === 0"
+            v-if="userData.periodStatus === 2"
             :disabled="!getAllList.length"
             :indeterminate="isIndeterminate"
             v-model="checkAll"
@@ -138,13 +138,13 @@
           <el-button
             style="margin-left: 10px"
             size="mini"
-            v-if="userData.allStatus === 0"
+            v-if="userData.periodStatus === 2"
             @click="getChangeStatus(1)"
             >勾选通过</el-button
           >
           <el-button
             size="mini"
-            v-if="userData.allStatus === 0"
+            v-if="userData.periodStatus === 2"
             @click="getChangeStatus(2)"
             >勾选作弊</el-button
           >
@@ -256,9 +256,9 @@
                 <div
                   class="styFlex"
                   v-if="
-                    (userData.allStatus === 0 ||
-                      userData.allStatus === 1 ||
-                      userData.allStatus === 3) &&
+                    (userData.periodStatus === 2 ||
+                      userData.periodStatus === 0 ||
+                      userData.periodStatus === 3) &&
                     scope.row.periodStatus === 1
                   "
                 >
@@ -267,7 +267,7 @@
                       class="checkboxList"
                       :label="scope.row.periodStatusId"
                       :disabled="
-                        userData.allStatus === 3
+                        userData.periodStatus === 3
                           ? false
                           : scope.row.status !== 2
                           ? true
@@ -380,9 +380,9 @@
                       <div
                         class="styFlex"
                         v-if="
-                          (userData.allStatus === 0 ||
-                            userData.allStatus === 1 ||
-                            userData.allStatus === 3) &&
+                          (userData.periodStatus === 0 ||
+                            userData.periodStatus === 2 ||
+                            userData.periodStatus === 3) &&
                           scope2.row.periodStatus === 1
                         "
                       >
@@ -391,7 +391,7 @@
                             class="checkboxList"
                             :label="scope2.row.periodStatusId"
                             :disabled="
-                              userData.allStatus === 3
+                              userData.periodStatus === 3
                                 ? false
                                 : scope2.row.status !== 2
                                 ? true
@@ -499,9 +499,9 @@
                             <div
                               class="styFlex"
                               v-if="
-                                (userData.allStatus === 0 ||
-                                  userData.allStatus === 1 ||
-                                  userData.allStatus === 3) &&
+                                (userData.periodStatus === 0 ||
+                                  userData.periodStatus === 2 ||
+                                  userData.periodStatus === 3) &&
                                 scope3.row.periodStatus === 1
                               "
                             >
@@ -510,7 +510,7 @@
                                   class="checkboxList"
                                   :label="scope3.row.periodStatusId"
                                   :disabled="
-                                    userData.allStatus === 3
+                                    userData.periodStatus === 3
                                       ? false
                                       : scope3.row.status !== 2
                                       ? true
@@ -1193,8 +1193,8 @@ export default {
     },
   },
   watch: {
-    "userData.allStatus"(val, oldVal) {
-      if (val == 3 && oldVal == 0) {
+    "userData.periodStatus"(val, oldVal) {
+      if (val == 3 && oldVal == 2) {
         this.search();
       }
     },
@@ -1776,7 +1776,7 @@ export default {
           tab1.forEach((item) => {
             item.classPeriods.forEach((items) => {
               items.classPeriodSectionList.forEach((itemsxs) => {
-                if (self.userData.allStatus === 3) {
+                if (self.userData.periodStatus === 3) {
                   getAllList1.push(itemsxs.periodStatusId);
                   allArrays.push(itemsxs);
                 } else {
@@ -1793,7 +1793,7 @@ export default {
           let getAllList2 = [];
           tab2.forEach((item) => {
             item.classPeriodSectionList.forEach((items) => {
-              if (self.userData.allStatus === 3) {
+              if (self.userData.periodStatus === 3) {
                 getAllList2.push(items.periodStatusId);
                 allArrays.push(items);
               } else {
@@ -1808,7 +1808,7 @@ export default {
            */
           let getAllList3 = [];
           tab3.forEach((item) => {
-            if (self.userData.allStatus === 3) {
+            if (self.userData.periodStatus === 3) {
               getAllList3.push(item.periodStatusId);
               allArrays.push(item);
             } else {

+ 4 - 5
src/views/education/classManageMent/listOfhoursToBeReviewed/index.vue

@@ -6,6 +6,7 @@
       :formList="formList"
       @search="search"
       @init="init"
+      :hoursType="hoursType"
     />
     <table-list
       :tableSets="tableSet"
@@ -38,6 +39,7 @@ export default {
   components: { searchBoxNew, tableList, pagination },
   data() {
     return {
+      hoursType: true,
       loading: false, //当前表单加载是否加载动画
       navText: {
         title: "学时待审核列表",
@@ -215,7 +217,7 @@ export default {
         },
         {
           label: "学时审批状态",
-          prop: "allStatus",
+          prop: "periodStatus",
           hidden: true,
           scope: "statusPeriod",
         },
@@ -270,15 +272,12 @@ export default {
       if (int === 2) {
         this.formData = {
           profileStatus: "",
-          periodStatus: 2,
+          periodStatus: this.formData.periodStatus,
           status: 1,
           pageSize: 10,
           pageNum: 1,
         };
       }
-      if (int === 3) {
-        this.formData.pageNum = 1;
-      }
       var data = JSON.parse(JSON.stringify(this.formData));
       if (this.formData.classStartTime) {
         data.classStartTime = data.classStartTime / 1000;

+ 283 - 97
src/views/resource/videoManagement/chapter/add/index.vue

@@ -1,13 +1,13 @@
 <template>
   <div id="chapterEdit">
-    <div class="boxWidth">
-      <el-form
-        label-position="right"
-        label-width="120px"
-        :model="listData"
-        :rules="rules"
-        ref="listData"
-      >
+    <el-form
+      label-position="right"
+      label-width="120px"
+      :model="listData"
+      :rules="rules"
+      ref="listData"
+    >
+      <div class="boxWidth">
         <el-form-item label="适用业务层级">
           <el-select
             v-model="eduType"
@@ -201,100 +201,104 @@
             <el-radio :label="0">否</el-radio>
           </el-radio-group>
         </el-form-item>
-        <el-form-item label="管理节">
-          <div class="dis_plays">
-            <div>
-              <el-button size="small" @click="openBoxs">添加节</el-button>
-            </div>
-            <div style="color: #f56c6c">
-              <span style="margin-right: 10px"
-                >节总数:{{ tableData.length }}</span
-              >
-              <!-- <span>总时长:{{ minTimeAll }}分钟</span> -->
-            </div>
+      </div>
+      <el-form-item label="管理节">
+        <div class="dis_plays">
+          <div>
+            <el-button size="small" @click="openBoxs">调用已有数据</el-button>
+            <el-button size="small" type="success" @click="dialogDR = true"
+              >Excel批量新增</el-button
+            >
           </div>
-          <el-table
-            :data="tableData"
-            border
-            :header-cell-style="{
-              'background-color': '#eee',
-              padding: '8px',
-              color: '#333',
-            }"
-            :default-sort="{ prop: 'sort', order: 'ascending' }"
-          >
-            <el-table-column
-              v-for="(item, index) in tableSet"
-              :width="item.width"
-              :key="index"
-              :label="item.label"
-              align="center"
-              :show-overflow-tooltip="true"
-              header-align="center"
-              :sortable="item.prop === 'sort'"
-              sort-by="sort"
-              :prop="item.prop"
+          <div style="color: #f56c6c">
+            <span style="margin-right: 10px"
+              >节总数:{{ tableData.length }}</span
             >
-              <template slot-scope="scope">
-                <span v-if="item.scope === 'types'">{{
+            <!-- <span>总时长:{{ minTimeAll }}分钟</span> -->
+          </div>
+        </div>
+        <el-table
+          :data="tableData"
+          border
+          :header-cell-style="{
+            'background-color': '#eee',
+            padding: '8px',
+            color: '#333',
+          }"
+          :default-sort="{ prop: 'sort', order: 'ascending' }"
+        >
+          <el-table-column
+            v-for="(item, index) in tableSet"
+            :width="item.width"
+            :key="index"
+            :label="item.label"
+            align="center"
+            :show-overflow-tooltip="true"
+            header-align="center"
+            :sortable="item.prop === 'sort'"
+            sort-by="sort"
+            :prop="item.prop"
+          >
+            <template slot-scope="scope">
+              <span v-if="item.scope === 'types'">{{
+                scope.row[item.prop] === 1
+                  ? "录播"
+                  : scope.row[item.prop] === 2
+                  ? "直播"
+                  : scope.row[item.prop] === 3
+                  ? "回放"
+                  : "未知"
+              }}</span>
+              <span v-else-if="item.scope === 'Status'">
+                {{
                   scope.row[item.prop] === 1
-                    ? "录播"
-                    : scope.row[item.prop] === 2
-                    ? "直播"
-                    : scope.row[item.prop] === 3
-                    ? "回放"
+                    ? "发布"
+                    : scope.row[item.prop] === 0
+                    ? "未发布"
                     : "未知"
-                }}</span>
-                <span v-else-if="item.scope === 'Status'">
-                  {{
-                    scope.row[item.prop] === 1
-                      ? "发布"
-                      : scope.row[item.prop] === 0
-                      ? "未发布"
-                      : "未知"
-                  }}
-                </span>
-                <div v-else-if="item.scope === 'inputs'">
-                  <el-input-number
-                    style="width: 50px"
-                    size="small"
-                    :controls="false"
-                    v-model="scope.row[item.prop]"
-                    controls-position="right"
-                    :min="0"
-                  ></el-input-number>
-                </div>
-                <span v-else>{{ scope.row[item.prop] }}</span></template
-              >
-            </el-table-column>
-            <el-table-column
-              label="操作"
-              align="center"
-              fixed="right"
-              width="100px"
+                }}
+              </span>
+              <div v-else-if="item.scope === 'inputs'">
+                <el-input-number
+                  style="width: 50px"
+                  size="small"
+                  :controls="false"
+                  v-model="scope.row[item.prop]"
+                  controls-position="right"
+                  :min="0"
+                ></el-input-number>
+              </div>
+              <span v-else>{{ scope.row[item.prop] }}</span></template
             >
-              <template slot-scope="scope">
-                <el-button type="text" @click="delList(scope.row)"
-                  >删除</el-button
-                >
-              </template>
-            </el-table-column>
-          </el-table>
-        </el-form-item>
-        <el-form-item>
-          <el-button @click="backPage">取消</el-button>
-          <el-button
-            :loading="disabledBtn"
-            type="primary"
-            @click="submit('listData')"
-            >确定</el-button
+          </el-table-column>
+          <el-table-column
+            label="操作"
+            align="center"
+            fixed="right"
+            width="100px"
           >
-        </el-form-item>
-      </el-form>
-    </div>
+            <template slot-scope="scope">
+              <el-button type="text" @click="delList(scope.row)"
+                >删除</el-button
+              >
+            </template>
+          </el-table-column>
+        </el-table>
+      </el-form-item>
+      <el-form-item>
+        <el-button @click="backPage">取消</el-button>
+        <el-button
+          :loading="disabledBtn"
+          type="primary"
+          @click="submit('listData')"
+          >确定</el-button
+        >
+      </el-form-item>
+    </el-form>
+
     <el-dialog
       :visible.sync="dialogVisible"
-      width="800px"
+      width="1000px"
       :show-close="false"
       :close-on-click-modal="false"
     >
@@ -388,10 +392,94 @@
         >
       </span>
     </el-dialog>
+    <el-dialog
+      :visible.sync="dialogDR"
+      width="660px"
+      :show-close="false"
+      :close-on-click-modal="false"
+    >
+      <div slot="title" class="hearders">
+        <div class="leftTitle">导入</div>
+        <div class="rightBoxs">
+          <img
+            src="@/assets/images/Close@2x.png"
+            alt=""
+            @click="dialogDR = false"
+          />
+        </div>
+      </div>
+      <div>
+        <div class="swq">
+          <img
+            style="width: 182px; height: 168px"
+            src="@/assets/images/dr.png"
+            alt=""
+          />
+        </div>
+        <div style="padding-left: 100px">
+          <p>第一步:下载导入模板</p>
+          <p style="padding-left: 50px">
+            <i class="el-icon-upload"></i
+            ><span class="dowmStys" @click="getDowm">下载模板</span>
+          </p>
+          <p>第二步:(批量新增):点击“上传Excel”完成导入</p>
+          <label
+            for="mobles"
+            class="el-button el-button--primary"
+            style="margin-left: 50px; padding: 10px 20px"
+            >上传Excel</label
+          ><input
+            style="display: none"
+            type="file"
+            id="mobles"
+            ref="input1"
+            @change="importMobleadd"
+          />
+        </div>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogDR = false">取消</el-button>
+        <!-- <el-button type="primary" @click="submitChecksDR">确定</el-button> -->
+      </span>
+    </el-dialog>
+    <el-dialog
+      append-to-body
+      :visible.sync="dialogERROR"
+      width="660px"
+      :show-close="false"
+      :close-on-click-modal="false"
+    >
+      <div slot="title" class="hearders">
+        <div class="leftTitle">提示</div>
+        <div class="rightBoxs">
+          <img
+            src="@/assets/images/Close@2x.png"
+            alt=""
+            @click="dialogERROR = false"
+          />
+        </div>
+      </div>
+      <div>
+        <h4 style="margin-top: 0px; font-weight: bold; text-align: center">
+          导入失败原因
+        </h4>
+        <el-input
+          readonly
+          type="textarea"
+          :autosize="{ minRows: 6, maxRows: 24 }"
+          v-model="errorData"
+        >
+        </el-input>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogERROR = false">确定</el-button>
+      </span>
+    </el-dialog>
   </div>
 </template>
 
 <script>
+import * as baseUrls from "@/utils/request.js";
 import searchBoxNew from "@/components/searchBoxNew";
 import pagination from "@/components/pagination";
 export default {
@@ -399,6 +487,9 @@ export default {
   name: "ChapterAdd",
   data() {
     return {
+      dialogDR: false,
+      errorData: "", //导入错误原因
+      dialogERROR: false,
       disabledBtn: false,
       isIndeterminate: false,
       checkAll: false,
@@ -518,9 +609,90 @@ export default {
   mounted() {
     this.localData = this.$methodsTools.getBusinessList();
     this.getDict();
-    // this.search();
   },
   methods: {
+    getDowm() {
+      let url =
+        baseUrls.BASE_IMG_URL + "/oss/images/file/20220304/1646382321115.xlsx";
+      let link = document.createElement("a");
+      let fileName = "导入模板" + ".xlsx";
+      document.body.appendChild(link);
+      link.href = url;
+      link.dowmload = fileName;
+      link.click();
+      link.remove();
+    },
+    importMobleadd(e) {
+      var self = this;
+      var file = e.target.files[0];
+      let formData = new FormData();
+      formData.append("file", file);
+      this.$api
+        .drCourseSectionimportData(formData)
+        .then(async (res) => {
+          if (res.code === 200) {
+            if (!res.data.errorLog) {
+              await this.awaitGetFestivalList(res.data.importNo, 1)
+                .then((result) => {
+                  self.dialogDR = false;
+                })
+                .catch(() => {
+                  e.target.value = "";
+                });
+            } else {
+              await this.awaitGetFestivalList(res.data.importNo, 2)
+                .then((result) => {
+                  let ary = res.data.errorLog.split("\r\n");
+                  ary = ary
+                    .filter((item) => {
+                      return item.length > 0;
+                    })
+                    .reverse();
+                  self.$message({
+                    message: `${ary.length}条数据导入失败,请查看失败原因`,
+                    customClass: "myMessageClass",
+                  });
+                  ary = ary.join("\r\n");
+                  self.errorData = ary;
+                  self.dialogERROR = true;
+                })
+                .catch(() => {
+                  e.target.value = "";
+                });
+            }
+          }
+        })
+        .finally(() => {
+          e.target.value = "";
+        });
+    },
+    awaitGetFestivalList(ids, type) {
+      return new Promise((resolve, reject) => {
+        this.$api
+          .inquireCourseSection({ importNo: ids })
+          .then((res) => {
+            if (type === 2 && res.rows.length) {
+              this.$message({
+                type: "success",
+                message: `成功导入${res.rows.length}条数据,`,
+                customClass: "myMessageClass",
+              });
+            }
+            if (res.rows.length) {
+              this.activeLists = res.rows;
+              if (type === 1) {
+                this.submitForm();
+              } else {
+                this.submitForm(1);
+              }
+            }
+            resolve();
+          })
+          .catch(() => {
+            reject();
+          });
+      });
+    },
     unTime(val) {
       let a = `${val.businessId}-${val.subjectId}`;
       if (this.sujectApis.includes(a)) {
@@ -899,7 +1071,7 @@ export default {
     getRowKeys(row) {
       return row.sectionId;
     },
-    submitForm() {
+    submitForm(int) {
       if (this.activeLists.length === 0) {
         this.dialogVisible = false;
         return;
@@ -921,7 +1093,13 @@ export default {
       }
       this.tableData = this.tableData.concat(this.activeLists);
       this.dialogVisible = false;
-      this.$message.success("添加成功");
+      if (!int) {
+        this.$message({
+          type: "success",
+          message: `添加成功`,
+          customClass: "myMessageClass",
+        });
+      }
       this.activeLists = [];
     },
     delList(item) {
@@ -937,6 +1115,14 @@ export default {
 </script>
 
 <style lang="less" scoped>
+.swq {
+  text-align: center;
+  border-bottom: 1px solid #eee;
+}
+.dowmStys {
+  color: blue;
+  cursor: pointer;
+}
 .boxWidth {
   width: 800px;
 }

+ 406 - 99
src/views/resource/videoManagement/chapter/edit/index.vue

@@ -1,13 +1,13 @@
 <template>
   <div id="chapterEdit">
-    <div class="boxWidth">
-      <el-form
-        label-position="right"
-        label-width="120px"
-        :model="listData"
-        :rules="rules"
-        ref="listData"
-      >
+    <el-form
+      label-position="right"
+      label-width="120px"
+      :model="listData"
+      :rules="rules"
+      ref="listData"
+    >
+      <div class="boxWidth">
         <el-form-item label="适用业务层级">
           <el-select
             v-model="eduType"
@@ -173,101 +173,104 @@
             <el-radio :label="0">否</el-radio>
           </el-radio-group>
         </el-form-item>
-        <el-form-item label="管理节">
-          <div class="dis_plays">
-            <div>
-              <el-button size="small" @click="openBoxs">添加节</el-button>
-            </div>
-            <div style="color: #f56c6c">
-              <span style="margin-right: 10px"
-                >节总数:{{ tableData.length }}</span
-              >
-              <!-- <span>总时长:{{ minTimeAll }}分钟</span> -->
-            </div>
+      </div>
+      <el-form-item label="管理节">
+        <div class="dis_plays">
+          <div>
+            <el-button size="small" @click="openBoxs">调用已有数据</el-button>
+            <el-button size="small" type="success" @click="dialogDR = true"
+              >Excel批量新增</el-button
+            >
           </div>
-          <el-table
-            :data="tableData"
-            border
-            :header-cell-style="{
-              'background-color': '#eee',
-              padding: '8px',
-              color: '#333',
-            }"
-            :default-sort="{ prop: 'sort', order: 'ascending' }"
-          >
-            <el-table-column
-              v-for="(item, index) in tableSet"
-              :width="item.width"
-              :key="index"
-              :label="item.label"
-              align="center"
-              :show-overflow-tooltip="true"
-              header-align="center"
-              :sortable="item.prop === 'sort'"
-              sort-by="sort"
-              :prop="item.prop"
+          <div style="color: #f56c6c">
+            <span style="margin-right: 10px"
+              >节总数:{{ tableData.length }}</span
             >
-              <template slot-scope="scope">
-                <span v-if="item.scope === 'types'">{{
+            <!-- <span>总时长:{{ minTimeAll }}分钟</span> -->
+          </div>
+        </div>
+        <el-table
+          :data="tableData"
+          border
+          :header-cell-style="{
+            'background-color': '#eee',
+            padding: '8px',
+            color: '#333',
+          }"
+          :default-sort="{ prop: 'sort', order: 'ascending' }"
+        >
+          <el-table-column
+            v-for="(item, index) in tableSet"
+            :width="item.width"
+            :key="index"
+            :label="item.label"
+            align="center"
+            :show-overflow-tooltip="true"
+            header-align="center"
+            :sortable="item.prop === 'sort'"
+            sort-by="sort"
+            :prop="item.prop"
+          >
+            <template slot-scope="scope">
+              <span v-if="item.scope === 'types'">{{
+                scope.row[item.prop] === 1
+                  ? "录播"
+                  : scope.row[item.prop] === 2
+                  ? "直播"
+                  : scope.row[item.prop] === 3
+                  ? "回放"
+                  : "未知"
+              }}</span>
+              <span v-else-if="item.scope === 'Status'">
+                {{
                   scope.row[item.prop] === 1
-                    ? "录播"
-                    : scope.row[item.prop] === 2
-                    ? "直播"
-                    : scope.row[item.prop] === 3
-                    ? "回放"
+                    ? "发布"
+                    : scope.row[item.prop] === 0
+                    ? "未发布"
                     : "未知"
-                }}</span>
-                <span v-else-if="item.scope === 'Status'">
-                  {{
-                    scope.row[item.prop] === 1
-                      ? "发布"
-                      : scope.row[item.prop] === 0
-                      ? "未发布"
-                      : "未知"
-                  }}
-                </span>
-                <div v-else-if="item.scope === 'inputs'">
-                  <el-input-number
-                    style="width: 50px"
-                    size="small"
-                    :controls="false"
-                    v-model="scope.row[item.prop]"
-                    controls-position="right"
-                    :min="0"
-                  ></el-input-number>
-                </div>
-                <span v-else>{{ scope.row[item.prop] }}</span></template
-              >
-            </el-table-column>
-            <el-table-column
-              label="操作"
-              align="center"
-              fixed="right"
-              width="100px"
+                }}
+              </span>
+              <div v-else-if="item.scope === 'inputs'">
+                <el-input-number
+                  style="width: 50px"
+                  size="small"
+                  :controls="false"
+                  v-model="scope.row[item.prop]"
+                  controls-position="right"
+                  :min="0"
+                ></el-input-number>
+              </div>
+              <span v-else>{{ scope.row[item.prop] }}</span></template
             >
-              <template slot-scope="scope">
-                <el-button type="text" @click="delList(scope.row)"
-                  >删除</el-button
-                >
-              </template>
-            </el-table-column>
-          </el-table>
-        </el-form-item>
-        <el-form-item>
-          <el-button @click="backPage">取消</el-button>
-          <el-button
-            :loading="disabledBtn"
-            type="primary"
-            @click="submit('listData')"
-            :disabled="!noStudent"
-            >确定</el-button
+          </el-table-column>
+          <el-table-column
+            label="操作"
+            align="center"
+            fixed="right"
+            width="100px"
           >
-        </el-form-item>
-      </el-form>
-    </div>
+            <template slot-scope="scope">
+              <el-button type="text" @click="delList(scope.row)"
+                >删除</el-button
+              >
+            </template>
+          </el-table-column>
+        </el-table>
+      </el-form-item>
+      <el-form-item>
+        <el-button @click="backPage">取消</el-button>
+        <el-button
+          :loading="disabledBtn"
+          type="primary"
+          @click="submit('listData')"
+          :disabled="!noStudent"
+          >确定</el-button
+        >
+      </el-form-item>
+    </el-form>
     <el-dialog
       :visible.sync="dialogVisible"
-      width="800px"
+      width="1000px"
       :show-close="false"
       :close-on-click-modal="false"
     >
@@ -361,10 +364,94 @@
         >
       </span>
     </el-dialog>
+    <el-dialog
+      :visible.sync="dialogDR"
+      width="660px"
+      :show-close="false"
+      :close-on-click-modal="false"
+    >
+      <div slot="title" class="hearders">
+        <div class="leftTitle">导入</div>
+        <div class="rightBoxs">
+          <img
+            src="@/assets/images/Close@2x.png"
+            alt=""
+            @click="dialogDR = false"
+          />
+        </div>
+      </div>
+      <div>
+        <div class="swq">
+          <img
+            style="width: 182px; height: 168px"
+            src="@/assets/images/dr.png"
+            alt=""
+          />
+        </div>
+        <div style="padding-left: 100px">
+          <p>第一步:下载导入模板</p>
+          <p style="padding-left: 50px">
+            <i class="el-icon-upload"></i
+            ><span class="dowmStys" @click="getDowm">下载模板</span>
+          </p>
+          <p>第二步:(批量新增):点击“上传Excel”完成导入</p>
+          <label
+            for="mobles"
+            class="el-button el-button--primary"
+            style="margin-left: 50px; padding: 10px 20px"
+            >上传Excel</label
+          ><input
+            style="display: none"
+            type="file"
+            id="mobles"
+            ref="input1"
+            @change="importMobleadd"
+          />
+        </div>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogDR = false">取消</el-button>
+        <!-- <el-button type="primary" @click="submitChecksDR">确定</el-button> -->
+      </span>
+    </el-dialog>
+    <el-dialog
+      append-to-body
+      :visible.sync="dialogERROR"
+      width="660px"
+      :show-close="false"
+      :close-on-click-modal="false"
+    >
+      <div slot="title" class="hearders">
+        <div class="leftTitle">提示</div>
+        <div class="rightBoxs">
+          <img
+            src="@/assets/images/Close@2x.png"
+            alt=""
+            @click="dialogERROR = false"
+          />
+        </div>
+      </div>
+      <div>
+        <h4 style="margin-top: 0px; font-weight: bold; text-align: center">
+          导入失败原因
+        </h4>
+        <el-input
+          readonly
+          type="textarea"
+          :autosize="{ minRows: 6, maxRows: 24 }"
+          v-model="errorData"
+        >
+        </el-input>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogERROR = false">确定</el-button>
+      </span>
+    </el-dialog>
   </div>
 </template>
 
 <script>
+import * as baseUrls from "@/utils/request.js";
 import searchBoxNew from "@/components/searchBoxNew";
 import pagination from "@/components/pagination";
 export default {
@@ -372,6 +459,9 @@ export default {
   name: "ChapterEdit",
   data() {
     return {
+      dialogDR: false,
+      errorData: "", //导入错误原因
+      dialogERROR: false,
       disabledBtn: false,
       isIndeterminate: false,
       checkAll: false,
@@ -501,6 +591,105 @@ export default {
     this.search();
   },
   methods: {
+    /**
+     * 下载Excel模板
+     */
+    getDowm() {
+      let url =
+        baseUrls.BASE_IMG_URL + "/oss/images/file/20220304/1646382321115.xlsx";
+      let link = document.createElement("a");
+      let fileName = "导入模板" + ".xlsx";
+      document.body.appendChild(link);
+      link.href = url;
+      link.dowmload = fileName;
+      link.click();
+      link.remove();
+    },
+    /**
+     *
+     * @param {Object} e
+     * @remards 导入逻辑
+     */
+    importMobleadd(e) {
+      var self = this;
+      var file = e.target.files[0];
+      let formData = new FormData();
+      formData.append("file", file);
+      this.$api
+        .drCourseSectionimportData(formData)
+        .then(async (res) => {
+          if (res.code === 200) {
+            if (!res.data.errorLog) {
+              await this.awaitGetFestivalList(res.data.importNo, 1)
+                .then((result) => {
+                  self.dialogDR = false;
+                })
+                .catch(() => {
+                  e.target.value = "";
+                });
+            } else {
+              await this.awaitGetFestivalList(res.data.importNo, 2)
+                .then((result) => {
+                  let ary = res.data.errorLog.split("\r\n");
+                  ary = ary
+                    .filter((item) => {
+                      return item.length > 0;
+                    })
+                    .reverse();
+                  self.$message({
+                    message: `${ary.length}条数据导入失败,请查看失败原因`,
+                    customClass: "myMessageClass",
+                  });
+                  ary = ary.join("\r\n");
+                  self.errorData = ary;
+                  self.dialogERROR = true;
+                })
+                .catch(() => {
+                  e.target.value = "";
+                });
+            }
+          }
+        })
+        .finally(() => {
+          e.target.value = "";
+        });
+    },
+    /**
+     *
+     * @param {Strings} ids 查询编码
+     * @param {Number} type 1为成功2为失败
+     * @remards 失败时也需查询是否有成功的数据导入数据库,如存在 则加列队列同时提示
+     */
+    awaitGetFestivalList(ids, type) {
+      return new Promise((resolve, reject) => {
+        this.$api
+          .inquireCourseSection({ importNo: ids })
+          .then((res) => {
+            if (type === 2 && res.rows.length) {
+              this.$message({
+                type: "success",
+                message: `成功导入${res.rows.length}条数据,`,
+                customClass: "myMessageClass",
+              });
+            }
+            if (res.rows.length) {
+              this.activeLists = res.rows;
+              if (type === 1) {
+                this.submitForm();
+              } else {
+                this.submitForm(1);
+              }
+            }
+            resolve();
+          })
+          .catch(() => {
+            reject();
+          });
+      });
+    },
+    /**
+     * 科目复选框发生变化时触发
+     */
     handleCheckedCitiesChange() {
       let nid = this.newSujectOption.map((item) => {
         return item.newId;
@@ -509,6 +698,11 @@ export default {
       this.isIndeterminate =
         this.sujectArray.length > 0 && this.sujectArray.length < nid.length;
     },
+    /**
+     *
+     * @param {Arrays} arr
+     * @remards 数据去重
+     */
     setFunc(arr) {
       var arrays = [];
       for (let i = 0; i < arr.length; i++) {
@@ -518,6 +712,11 @@ export default {
       }
       return arrays;
     },
+    /**
+     *
+     * @param {Arrays} val 复选框内容
+     * @remards 科目复选框全选按钮触发
+     */
     handleCheckAllChange(val) {
       if (val) {
         let nid = this.newSujectOption.map((item) => {
@@ -540,11 +739,17 @@ export default {
         this.isIndeterminate = false;
       }
     },
+    /**
+     * 点击科目按钮 判断是否选中了业务层级
+     */
     getMessage() {
       if (!this.courType) {
         this.$message.warning("请先选择业务层级");
       }
     },
+    /**
+     * 调用已有数据触发
+     */
     openBoxs() {
       var self = this;
       this.$api.inquireCourseSection(this.formData).then((res) => {
@@ -561,15 +766,21 @@ export default {
         });
       });
     },
+    /**
+     * 初始化获取该章管理节数据
+     */
     getInfosList() {
       this.$api
         .inquireCoursechaptersectionlist(this.$route.query.id)
         .then((result) => {
-          // this.numberAll = result.total;
-          // this.minTimeAll = result.timeTotal;
           this.tableData = result.data;
         });
     },
+    /**
+     *
+     * @param {Number} int
+     * @remards 搜索节列表
+     */
     getInfos(int) {
       this.loading = true;
       if (int === 1) {
@@ -592,9 +803,15 @@ export default {
           this.loading = false;
         });
     },
+    /**
+     * 重置节搜索
+     */
     init() {
       this.getInfos(2);
     },
+    /**
+     * 初始调用数据
+     */
     search() {
       this.$api
         .obtainCoursechapter(this.$route.query.id)
@@ -616,9 +833,15 @@ export default {
           this.$modal.closeLoading();
         });
     },
+    /**
+     * 删除封面
+     */
     clearImgs() {
       this.listData.coverUrl = "";
     },
+    /**
+     * 转换业务层级-科目选中以及展示逻辑
+     */
     changeTypes() {
       var self = this;
       var arrays = [];
@@ -648,9 +871,15 @@ export default {
       });
       this.newSujectApis = arrays;
     },
+    /**
+     * 业务层级展开or关闭
+     */
     changeType() {
       this.changeHeight = !this.changeHeight;
     },
+    /**
+     * 科目框确定按钮触发
+     */
     submitSujectArray() {
       var self = this;
       this.sujectApis = this.sujectApis.filter((item, index) => {
@@ -661,6 +890,9 @@ export default {
       }
       this.$refs.popovers.doClose();
     },
+    /**
+     * 科目框显示触发函数
+     */
     showHandle() {
       var array = [];
       for (let i = 0; i < this.sujectApis.length; i++) {
@@ -681,7 +913,13 @@ export default {
       });
       this.handleCheckedCitiesChange();
     },
+    /**
+     * 科目框隐藏触发函数
+     */
     hideHandle() {},
+    /**
+     * 初始获取基本select参数
+     */
     getDict() {
       return new Promise((resolve, reject) => {
         this.$api.inquireCourseEducationType({ status: 1 }).then((res) => {
@@ -707,6 +945,9 @@ export default {
         });
       });
     },
+    /**
+     * 改变教育类型触发函数
+     */
     changeEduType() {
       if (!(this.courType === undefined || this.courType === "")) {
         this.courType = "";
@@ -719,6 +960,9 @@ export default {
       });
       this.newCourTypeOptions = arrays;
     },
+    /**
+     * 改变业务层级触发函数
+     */
     changecourseType() {
       this.newCourTypeOptions.map((item, index) => {
         if (item.id === this.courType) {
@@ -741,6 +985,11 @@ export default {
       this.newCourTypeOptions = arrays;
       this.$refs.popovers.doClose();
     },
+    /**
+     *
+     * @param {Strings} formName 表单名称
+     * @remards 表单验证
+     */
     submit(formName) {
       this.$refs[formName].validate((valid) => {
         if (valid) {
@@ -771,6 +1020,9 @@ export default {
         }
       });
     },
+    /**
+     * 提交表单数据
+     */
     async rulesTableSumbit() {
       this.disabledBtn = true;
       var sectionIdList = [];
@@ -808,6 +1060,9 @@ export default {
           this.disabledBtn = false;
         });
     },
+    /**
+     * 关闭该页面
+     */
     backPage() {
       this.$store.dispatch("tagsView/delView", this.$route).then((res) => {
         this.$router.push({
@@ -815,9 +1070,17 @@ export default {
         });
       });
     },
+    /**
+     *
+     * @param {Number} index 业务层级-科目的索引
+     * @remards 删除该科目
+     */
     closeType(index) {
       this.sujectApis.splice(index, 1);
     },
+    /**
+     * 上传封面
+     */
     getImgFile() {
       var self = this;
       var file = self.$refs.file.files[0];
@@ -844,18 +1107,38 @@ export default {
         self.listData.coverUrl = res;
       });
     },
+    /**
+     * @param {Number} v 页量
+     * @remards
+     * 节列表页量触发
+     */
     handleSizeChange(v) {
       this.formData.pageSize = v;
       this.formData.pageNum = 1;
       this.getInfos();
     },
+    /**
+     *
+     * @param {Number} v 页码
+     * @remards 节列表页码触发
+     */
     handleCurrentChange(v) {
       this.formData.pageNum = v;
       this.getInfos();
     },
+    /**
+     *
+     * @param {Arrays} value 节选中列表
+     * @remards 节全选触发
+     */
     selectAll(value) {
       this.activeLists = value;
     },
+    /**
+     *
+     * @param {Arrays} value 节选中列表
+     * @remards 节单个选中触发
+     */
     select(value) {
       this.activeLists = value;
     },
@@ -869,7 +1152,12 @@ export default {
     getRowKeys(row) {
       return row.sectionId;
     },
-    submitForm() {
+    /**
+     *
+     * @param {Number} int 导入失败标识
+     * @remards 合并且排列节列表数据
+     */
+    submitForm(int) {
       if (this.activeLists.length === 0) {
         this.dialogVisible = false;
         return;
@@ -891,9 +1179,20 @@ export default {
       }
       this.tableData = this.tableData.concat(this.activeLists);
       this.dialogVisible = false;
-      this.$message.success("添加成功");
+      if (!int) {
+        this.$message({
+          type: "success",
+          message: `添加成功`,
+          customClass: "myMessageClass",
+        });
+      }
       this.activeLists = [];
     },
+    /**
+     *
+     * @param {Object} item 当前点击的节数据
+     * @remards 删除节触发
+     */
     delList(item) {
       this.tableData.map((items, indexs) => {
         if (items.sectionId === item.sectionId) {
@@ -907,6 +1206,14 @@ export default {
 </script>
 
 <style lang="less" scoped>
+.swq {
+  text-align: center;
+  border-bottom: 1px solid #eee;
+}
+.dowmStys {
+  color: blue;
+  cursor: pointer;
+}
 .boxWidth {
   width: 800px;
 }