Explorar o código

refactor(system): 优化代码结构和注释

- 在 apiUsers 和 tournaments 组件中添加了 HTML 注释
- 优化了代码格式和缩进
- 删除了 apiUsers 组件中的一些冗余注释
fugui001 hai 5 meses
pai
achega
2a9e59868c

+ 9 - 7
src/views/system/business/apiUsers/index.vue

@@ -1,3 +1,4 @@
+<!--
 <template>
   <div class="p-2">
     <transition :enter-active-class="proxy?.animate.searchAnimate.enter" :leave-active-class="proxy?.animate.searchAnimate.leave">
@@ -36,7 +37,7 @@
     </transition>
 
     <el-card shadow="never">
-      <!--      <template #header>
+      &lt;!&ndash;      <template #header>
         <el-row :gutter="10" class="mb8">
           &lt;!&ndash;          <el-col :span="1.5">
             <el-button type="primary" plain icon="Plus" @click="handleAdd" v-hasPermi="['business:user:add']">新增</el-button>
@@ -56,10 +57,10 @@
           </el-col>&ndash;&gt;
           <right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
         </el-row>
-      </template>-->
+      </template>&ndash;&gt;
 
       <el-table v-loading="loading" border :data="userList" @selection-change="handleSelectionChange">
-        <!--        <el-table-column type="selection" width="55" align="center" />-->
+        &lt;!&ndash;        <el-table-column type="selection" width="55" align="center" />&ndash;&gt;
         <el-table-column label="用户id" align="center" prop="id" v-if="true" />
         <el-table-column label="登录名称" align="center" prop="loginName" />
         <el-table-column label="用户姓名" align="center" prop="realName" />
@@ -87,7 +88,7 @@
               <el-button link type="primary" icon="View" @click="handleUpdate(scope.row)" v-hasPermi="['business:user:edit']"></el-button>
             </el-tooltip>
 
-            <!-- 禁用/启用 按钮 -->
+            &lt;!&ndash; 禁用/启用 按钮 &ndash;&gt;
             <el-tooltip :content="scope.row.status === 1 ? '禁用' : '启用'" placement="top">
               <el-button
                 link
@@ -112,7 +113,7 @@
       <pagination v-show="total > 0" :total="total" v-model:page="queryParams.pageNum" v-model:limit="queryParams.pageSize" @pagination="getList" />
     </el-card>
 
-    <!-- 查看用户详情对话框 -->
+    &lt;!&ndash; 查看用户详情对话框 &ndash;&gt;
     <el-dialog :title="dialog.title" v-model="dialog.visible" width="500px" append-to-body>
       <el-form ref="userFormRef" :model="form" :rules="rules" label-width="80px">
         <el-form-item label="用户ID" prop="id">
@@ -149,13 +150,13 @@
       </el-form>
       <template #footer>
         <div class="dialog-footer">
-          <!--          <el-button :loading="buttonLoading" type="primary" @click="submitForm">确 定</el-button>-->
+          &lt;!&ndash;          <el-button :loading="buttonLoading" type="primary" @click="submitForm">确 定</el-button>&ndash;&gt;
           <el-button @click="cancel">取 消</el-button>
         </div>
       </template>
     </el-dialog>
 
-    <!-- 编辑用户对话框 -->
+    &lt;!&ndash; 编辑用户对话框 &ndash;&gt;
     <el-dialog :title="editDialog.title" v-model="editDialog.visible" width="500px" append-to-body>
       <el-form ref="editUserFormRef" :model="editForm" :rules="rules2" label-width="80px">
         <el-form-item label="用户ID" prop="id" v-show="false">
@@ -439,3 +440,4 @@ onMounted(() => {
   getList();
 });
 </script>
+-->

+ 1 - 1
src/views/system/business/tournaments/index.vue

@@ -449,7 +449,7 @@ import {
 import { selectItemsSelList } from '@/api/system/business/items';
 import { selectBlindLevelsById } from '@/api/system/business/levels';
 import { selectBlingStructuresInfo } from '@/api/system/business/structures';
-import { listClaims, deleteClaim ,auditSendReward } from '@/api/system/business/claims';
+import { listClaims, deleteClaim, auditSendReward } from '@/api/system/business/claims';
 import { TournamentsVO, TournamentsQuery, TournamentsForm, TournamentsBindStructuresVO } from '@/api/system/business/tournaments/types';
 import { ref } from 'vue';
 import LevelsIndex from '@/views/system/business/levels/index.vue';