Selaa lähdekoodia

fiex:优化代码

Tang 3 vuotta sitten
vanhempi
commit
2f6664ffd4

+ 2 - 3
src/views/Marketing/order/orderList/add/order/index.vue

@@ -114,8 +114,8 @@
     >
       <el-table-column label="序号" type="index" width="80" align="center">
       </el-table-column>
-      <template v-for="(item, index) in tableSetTSB">
         <el-table-column
+         v-for="(item, index) in tableSetTSB"
           :width="item.width"
           :key="index"
           :label="item.label"
@@ -214,8 +214,7 @@
             </div>
             <span v-else>{{ scope.row[item.prop] }}</span></template
           >
-        </el-table-column></template
-      >
+        </el-table-column>
       <el-table-column label="操作" align="center" fixed="right" width="100px">
         <template slot-scope="scope">
           <el-button type="text" @click="del(scope.row, scope.$index)"

Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 519 - 538
src/views/education/classManageMent/classHoursReview/studyTimes.vue


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 519 - 545
src/views/education/classManageMent/learningHoursRecordList/studyTimesRecord.vue


+ 90 - 93
src/views/education/studentManageMent/studentXQ/BankQuestionPassRecord.vue

@@ -24,15 +24,15 @@
               color: '#333',
             }"
           >
-            <template v-for="(item, index) in tableSetChild">
-              <el-table-column
-                :width="item.width"
-                :key="index"
-                :label="item.label"
-                align="center"
-              >
-                <template slot-scope="scope">
-                  <!-- <span v-if="item.scope === 'types'">
+            <el-table-column
+              v-for="(item, index) in tableSetChild"
+              :width="item.width"
+              :key="index"
+              :label="item.label"
+              align="center"
+            >
+              <template slot-scope="scope">
+                <!-- <span v-if="item.scope === 'types'">
                     {{
                       scope.row[item.prop] === 1
                         ? "开课"
@@ -51,19 +51,18 @@
                     }}</span>
                   </span> -->
 
-                  <span v-if="item.scope === 'types'">
-                    {{
-                      scope.row[item.prop] === 1
-                        ? "练习题"
-                        : scope.row[item.prop] === 2
-                        ? "模拟题"
-                        : ""
-                    }}
-                  </span>
-                  <span v-else> {{ scope.row[item.prop] }} </span>
-                </template>
-              </el-table-column>
-            </template>
+                <span v-if="item.scope === 'types'">
+                  {{
+                    scope.row[item.prop] === 1
+                      ? "练习题"
+                      : scope.row[item.prop] === 2
+                      ? "模拟题"
+                      : ""
+                  }}
+                </span>
+                <span v-else> {{ scope.row[item.prop] }} </span>
+              </template>
+            </el-table-column>
             <el-table-column label="操作" align="center" width="100px">
               <template slot-scope="scope">
                 <el-button
@@ -76,39 +75,38 @@
           </el-table>
         </template>
       </el-table-column>
-      <template v-for="(item, index) in tableSet">
-        <el-table-column
-          :width="item.width"
-          :key="index"
-          :label="item.label"
-          align="center"
-        >
-          <template slot-scope="scope">
-            <span v-if="item.scope === 'yewu'">
-              {{ scope.row[item.prop1] }}-{{ scope.row[item.prop2] }}-{{
-                scope.row[item.prop3]
-              }}
-            </span>
-            <span v-else-if="item.scope === 'time'">
-              {{ $methodsTools.onlyForma(scope.row[item.prop]) }}
-            </span>
-            <span v-else-if="item.scope === 'moreTime'">
-              {{ $methodsTools.onlyForma(scope.row[item.prop1]) }} -
-              {{ $methodsTools.onlyForma(scope.row[item.prop2]) }}
-            </span>
-            <span v-else-if="item.scope === 'computes'">
-              {{
-                ((scope.row[item.prop1] / scope.row[item.prop2]) * 100).toFixed(
-                  2
-                )
-              }}%
-            </span>
-            <span v-else>
-              {{ scope.row[item.prop] }}{{ item.ch ? item.ch : "" }}
-            </span>
-          </template>
-        </el-table-column>
-      </template>
+      <el-table-column
+        v-for="(item, index) in tableSet"
+        :width="item.width"
+        :key="index"
+        :label="item.label"
+        align="center"
+      >
+        <template slot-scope="scope">
+          <span v-if="item.scope === 'yewu'">
+            {{ scope.row[item.prop1] }}-{{ scope.row[item.prop2] }}-{{
+              scope.row[item.prop3]
+            }}
+          </span>
+          <span v-else-if="item.scope === 'time'">
+            {{ $methodsTools.onlyForma(scope.row[item.prop]) }}
+          </span>
+          <span v-else-if="item.scope === 'moreTime'">
+            {{ $methodsTools.onlyForma(scope.row[item.prop1]) }} -
+            {{ $methodsTools.onlyForma(scope.row[item.prop2]) }}
+          </span>
+          <span v-else-if="item.scope === 'computes'">
+            {{
+              ((scope.row[item.prop1] / scope.row[item.prop2]) * 100).toFixed(
+                2
+              )
+            }}%
+          </span>
+          <span v-else>
+            {{ scope.row[item.prop] }}{{ item.ch ? item.ch : "" }}
+          </span>
+        </template>
+      </el-table-column>
     </el-table>
     <el-dialog
       :visible.sync="dialogVisible"
@@ -136,44 +134,43 @@
         >
           <el-table-column label="序号" align="center" type="index" width="70">
           </el-table-column>
-          <template v-for="(item, index) in studyListRemard">
-            <el-table-column
-              :width="item.width"
-              :key="index"
-              :label="item.label"
-              align="center"
-            >
-              <template slot-scope="scope">
-                <span v-if="item.scope === 'studyTime'">
-                  {{ $methodsTools.onlyForma(scope.row[item.prop1])
-                  }}{{
-                    scope.row[item.prop1] && scope.row[item.prop2] ? "至" : ""
-                  }}
-                  {{ $methodsTools.onlyForma(scope.row[item.prop2]) }}
-                </span>
-                <span v-else-if="item.scope === 'status'">
-                  {{
-                    scope.row[item.prop] === 1
-                      ? "完成"
-                      : scope.row[item.prop] === 0
-                      ? "未学习"
-                      : scope.row[item.prop] === 2
-                      ? "学习中"
-                      : "未知"
-                  }}
-                </span>
-                <span v-else-if="item.scope === 'computerTimes'">
-                  {{
-                    $methodsTools.humandate(
-                      scope.row[item.prop1],
-                      scope.row[item.prop2]
-                    )
-                  }}
-                </span>
-                <span v-else> {{ scope.row[item.prop] }} </span>
-              </template>
-            </el-table-column>
-          </template>
+          <el-table-column
+            v-for="(item, index) in studyListRemard"
+            :width="item.width"
+            :key="index"
+            :label="item.label"
+            align="center"
+          >
+            <template slot-scope="scope">
+              <span v-if="item.scope === 'studyTime'">
+                {{ $methodsTools.onlyForma(scope.row[item.prop1])
+                }}{{
+                  scope.row[item.prop1] && scope.row[item.prop2] ? "至" : ""
+                }}
+                {{ $methodsTools.onlyForma(scope.row[item.prop2]) }}
+              </span>
+              <span v-else-if="item.scope === 'status'">
+                {{
+                  scope.row[item.prop] === 1
+                    ? "完成"
+                    : scope.row[item.prop] === 0
+                    ? "未学习"
+                    : scope.row[item.prop] === 2
+                    ? "学习中"
+                    : "未知"
+                }}
+              </span>
+              <span v-else-if="item.scope === 'computerTimes'">
+                {{
+                  $methodsTools.humandate(
+                    scope.row[item.prop1],
+                    scope.row[item.prop2]
+                  )
+                }}
+              </span>
+              <span v-else> {{ scope.row[item.prop] }} </span>
+            </template>
+          </el-table-column>
         </el-table>
       </div>
       <span slot="footer" class="dialog-footer">

+ 42 - 43
src/views/resource/bankManagement/chapterVolumeManagement/add/index.vue

@@ -120,51 +120,50 @@
             }"
             :default-sort="{ prop: 'sort', order: 'ascending' }"
           >
-            <template v-for="(item, index) in tableSet">
-              <el-table-column
-                :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'">{{
+            <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></template
-            >
+                  }}
+                </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"

+ 47 - 47
src/views/resource/bankManagement/chapterVolumeManagement/edit/index.vue

@@ -131,51 +131,50 @@
             }"
             :default-sort="{ prop: 'sort', order: 'ascending' }"
           >
-            <template v-for="(item, index) in tableSet">
-              <el-table-column
-                :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'">{{
+            <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></template
-            >
+                  }}
+                </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"
@@ -302,7 +301,7 @@ import searchBoxNew from "@/components/searchBoxNew";
 import pagination from "@/components/pagination";
 import tableList from "@/components/tableList";
 export default {
-  name:"ChapterVolumeManagementEdit",
+  name: "ChapterVolumeManagementEdit",
   components: { searchBoxNew, tableList, pagination },
   data() {
     return {
@@ -457,9 +456,10 @@ export default {
           this.sujectApis =
             res.rows[0].businessId + "-" + res.rows[0].subjectId;
           this.getInfosList();
-        }).finally(()=>{
-        this.$modal.closeLoading();
-      })
+        })
+        .finally(() => {
+          this.$modal.closeLoading();
+        });
     },
     changeTypes() {
       var self = this;

+ 42 - 43
src/views/resource/bankManagement/volumeManagement/add/index.vue

@@ -120,51 +120,50 @@
             }"
             :default-sort="{ prop: 'sort', order: 'ascending' }"
           >
-            <template v-for="(item, index) in tableSet">
-              <el-table-column
-                :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'">{{
+            <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></template
-            >
+                  }}
+                </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"

+ 47 - 47
src/views/resource/bankManagement/volumeManagement/edit/index.vue

@@ -131,51 +131,50 @@
             }"
             :default-sort="{ prop: 'sort', order: 'ascending' }"
           >
-            <template v-for="(item, index) in tableSet">
-              <el-table-column
-                :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'">{{
+            <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></template
-            >
+                  }}
+                </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"
@@ -302,7 +301,7 @@ import searchBoxNew from "@/components/searchBoxNew";
 import pagination from "@/components/pagination";
 import tableList from "@/components/tableList";
 export default {
-  name:"VolumeManagementEdit",
+  name: "VolumeManagementEdit",
   components: { searchBoxNew, tableList, pagination },
   data() {
     return {
@@ -435,9 +434,10 @@ export default {
           this.sujectApis =
             res.rows[0].businessId + "-" + res.rows[0].subjectId;
           this.getInfosList();
-        }).finally(()=>{
-        this.$modal.closeLoading();
-      })
+        })
+        .finally(() => {
+          this.$modal.closeLoading();
+        });
     },
     changeTypes() {
       var self = this;

+ 42 - 43
src/views/resource/videoManagement/chapter/add/index.vue

@@ -166,51 +166,50 @@
             }"
             :default-sort="{ prop: 'sort', order: 'ascending' }"
           >
-            <template v-for="(item, index) in tableSet">
-              <el-table-column
-                :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'">{{
+            <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></template
-            >
+                  }}
+                </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"

+ 42 - 43
src/views/resource/videoManagement/chapter/edit/index.vue

@@ -165,51 +165,50 @@
             }"
             :default-sort="{ prop: 'sort', order: 'ascending' }"
           >
-            <template v-for="(item, index) in tableSet">
-              <el-table-column
-                :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'">{{
+            <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></template
-            >
+                  }}
+                </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"

+ 24 - 25
src/views/resource/videoManagement/courseManagement/chapterContent/index.vue

@@ -134,32 +134,31 @@
           :reserve-selection="true"
         >
         </el-table-column>
-        <template v-for="(item, index) in tableSet">
-          <el-table-column
-            :width="item.width"
-            :key="index"
-            :label="item.label"
-            align="center"
-            :show-overflow-tooltip="true"
-            header-align="center"
-          >
-            <template slot-scope="scope">
-              <span v-if="item.scope === 'Status'">
-                {{
-                  scope.row[item.prop] === 1
-                    ? "发布"
-                    : scope.row[item.prop] === 0
-                    ? "未发布"
-                    : "未知"
-                }}
-              </span>
-              <span v-else-if="item.scope === 'teshu'">
-                {{ radio === 1 ? scope.row[item.prop] : scope.row[item.prop1] }}
-              </span>
-              <span v-else>{{ scope.row[item.prop] }}</span></template
-            >
-          </el-table-column></template
+        <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"
         >
+          <template slot-scope="scope">
+            <span v-if="item.scope === 'Status'">
+              {{
+                scope.row[item.prop] === 1
+                  ? "发布"
+                  : scope.row[item.prop] === 0
+                  ? "未发布"
+                  : "未知"
+              }}
+            </span>
+            <span v-else-if="item.scope === 'teshu'">
+              {{ radio === 1 ? scope.row[item.prop] : scope.row[item.prop1] }}
+            </span>
+            <span v-else>{{ scope.row[item.prop] }}</span></template
+          >
+        </el-table-column>
       </el-table>
       <pagination
         :total="total5"

+ 2 - 3
src/views/resource/videoManagement/moduleManagement/add/index.vue

@@ -165,8 +165,8 @@
             }"
             :default-sort="{ prop: 'sort', order: 'ascending' }"
           >
-            <template v-for="(item, index) in tableSet">
               <el-table-column
+               v-for="(item, index) in tableSet"
                 :width="item.width"
                 :key="index"
                 :label="item.label"
@@ -208,8 +208,7 @@
                   </div>
                   <span v-else>{{ scope.row[item.prop] }}</span></template
                 >
-              </el-table-column></template
-            >
+              </el-table-column>
             <el-table-column
               label="操作"
               align="center"

+ 42 - 43
src/views/resource/videoManagement/moduleManagement/edit/index.vue

@@ -166,51 +166,50 @@
             }"
             :default-sort="{ prop: 'sort', order: 'ascending' }"
           >
-            <template v-for="(item, index) in tableSet">
-              <el-table-column
-                :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'">{{
+            <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></template
-            >
+                  }}
+                </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"

Kaikkia tiedostoja ei voida näyttää, sillä liian monta tiedostoa muuttui tässä diffissä