Просмотр исходного кода

feature: 系统设置-> google邮箱,拒绝原因

ljc 5 месяцев назад
Родитель
Сommit
5e9a597296

+ 2 - 2
src/routers/index.ts

@@ -14,7 +14,7 @@ interface extendRoute {
 //
 import uCardRoute from './modules/uCard'
 import userRoute from '@/routers/modules/user'
-import systemRouter from '@/routers/modules/system'
+import systemRoute from '@/routers/modules/system'
 
 /**
  * path ==> 路由路径
@@ -75,7 +75,7 @@ export const constantRoutes: Array<RouteRecordRaw & extendRoute> = [
       OnBreadCrumb: false,
       requiresAuth: true,
     },
-    children: [uCardRoute, userRoute, systemRouter],
+    children: [systemRoute, uCardRoute, userRoute],
   },
 ]
 

+ 25 - 19
src/routers/modules/system.ts

@@ -1,22 +1,28 @@
-const systemRouter = [
-  {
-    meta: {
-      OnBreadCrumb: true,
+const systemRoute = {
+  meta: {
+    OnBreadCrumb: true,
+  },
+  path: 'system',
+  name: 'R-System',
+  component: () => import(/* webpackChunkName: "page" */ '@/views/page/Page.vue'),
+  children: [
+    {
+      meta: {
+        OnBreadCrumb: true,
+      },
+      path: 'google/email',
+      name: 'R-GoogleGroup',
+      component: () => import('@/views/system/GoogleEmail/index.vue'),
     },
-    path: 'system',
-    name: 'R-System',
-    component: () => import(/* webpackChunkName: "page" */ '@/views/page/Page.vue'),
-    children: [
-      {
-        meta: {
-          OnBreadCrumb: true,
-        },
-        path: 'google/email',
-        name: 'R-GoogleGroup',
-        component: () => import('@/views/system/GoogleEmail/index.vue'),
+    {
+      meta: {
+        OnBreadCrumb: true,
       },
-    ],
-  },
-]
+      path: 'refusal',
+      name: 'R-Refusal',
+      component: () => import('@/views/system/Refusal/index.vue'),
+    },
+  ],
+}
 
-export default systemRouter
+export default systemRoute

+ 9 - 1
src/routers/modules/uCard.ts

@@ -119,7 +119,15 @@ const uCardRoute = {
       component: () =>
         import(/* webpackChunkName: "GlobalCurrency" */ '@/views/card/GlobalCurrency/index.vue'),
     },
-
+    {
+      meta: {
+        OnBreadCrumb: true,
+      },
+      path: 'global/order',
+      name: 'R-GlobalOrder',
+      component: () =>
+        import(/* webpackChunkName: "GlobalOrder" */ '@/views/card/CardGlobalOrder/index.vue'),
+    },
     //   {
     //     meta: {
     //       OnBreadCrumb: true,

+ 22 - 0
src/service/system.ts

@@ -24,5 +24,27 @@ class CustomerService extends Service {
   async countryGet(params = {}) {
     return await this.post('/country/get', params)
   }
+  /* 拒绝理由 */
+  //拒绝理由添加
+  async reasonsRefusalAdd(params = {}) {
+    return await this.post('/reasons/refusal/add', params)
+  }
+  //拒绝理由修改
+  async reasonsRefusalUpdate(params = {}) {
+    return await this.post('/reasons/refusal/update', params)
+  }
+
+  //删除拒绝理由
+  async reasonsRefusalDelete(params = {}) {
+    return await this.post('/reasons/refusal/delete', params)
+  }
+  //单个查看拒绝理由
+  async reasonsRefusalSingle(params = {}) {
+    return await this.post('/reasons/refusal/search/single', params)
+  }
+  //拒绝理由列表
+  async reasonsRefusalSearchList(params = {}) {
+    return await this.post('/reasons/refusal/search/list', params)
+  }
 }
 export default new CustomerService()

+ 4 - 0
src/service/user.ts

@@ -131,6 +131,10 @@ class UserService extends Service {
   async userListUpdate(params = {}) {
     return await this.post('/user/update', params)
   }
+  //添加按钮
+  async authorityActionAdd(params = {}) {
+    return await this.post('/authority/action/add', params)
+  }
 }
 
 export default new UserService()

+ 33 - 35
src/views/system/GoogleEmail/index.vue

@@ -14,9 +14,9 @@
             <el-form-item style="margin-right: 10px">
               <el-input
                 v-model="search.groupEmail"
+                style="width: 330px !important"
                 :placeholder="t('Placeholder.Input')"
                 clearable
-                style="margin-top: 5px"
               >
                 <template #prepend>
                   <span class="crm-cursor crm-border-radius-no">
@@ -28,10 +28,10 @@
             <el-form-item>
               <el-input
                 v-model="search.groupName"
+                style="width: 300px !important"
                 :placeholder="t('Placeholder.Input')"
                 clearable
                 class="crm-border-radius-no"
-                style="margin-top: 5px"
               >
                 <template #prepend>
                   <span class="crm-cursor crm-border-radius-no">
@@ -195,7 +195,38 @@
   const display = computed(() => {
     return JSON.parse(Session.Get('display', true))
   })
+  // 自定义邮箱验证规则
+  const validateEmails = (rule, value, callback) => {
+    if (!value) {
+      callback(new Error(t('Placeholder.Input')))
+      return
+    }
+
+    // 检查是否包含中文逗号
+    if (value.includes(',')) {
+      callback(new Error('请使用英文逗号分隔多个邮箱地址'))
+      return
+    }
+
+    // 分割邮箱地址,只支持英文逗号,去除空格
+    const emails = value
+      .split(',')
+      .map((email) => email.trim())
+      .filter((email) => email)
+
+    // 邮箱格式正则表达式
+    const emailRegex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/
+
+    // 验证每个邮箱格式
+    for (const email of emails) {
+      if (!emailRegex.test(email)) {
+        callback(new Error(t('vaildate.email.format')))
+        return
+      }
+    }
 
+    callback()
+  }
   // 验证规则
   const rules = reactive({
     groupEmail: [
@@ -386,39 +417,6 @@
       submitLoading.value = false
     }
   }
-
-  // 自定义邮箱验证规则
-  const validateEmails = (rule, value, callback) => {
-    if (!value) {
-      callback(new Error(t('Placeholder.Input')))
-      return
-    }
-
-    // 检查是否包含中文逗号
-    if (value.includes(',')) {
-      callback(new Error('请使用英文逗号分隔多个邮箱地址'))
-      return
-    }
-
-    // 分割邮箱地址,只支持英文逗号,去除空格
-    const emails = value
-      .split(',')
-      .map((email) => email.trim())
-      .filter((email) => email)
-
-    // 邮箱格式正则表达式
-    const emailRegex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/
-
-    // 验证每个邮箱格式
-    for (const email of emails) {
-      if (!emailRegex.test(email)) {
-        callback(new Error(t('vaildate.email.format')))
-        return
-      }
-    }
-
-    callback()
-  }
 </script>
 <style lang="scss" scoped>
   #google {

+ 201 - 0
src/views/system/Refusal/components/Add.vue

@@ -0,0 +1,201 @@
+<template>
+  <div id="TradingDetailedInfoAdd" class="InfoBox" :class="{ active: dialogInfoTradingAdd }">
+    <div class="header">
+      <div>
+        <span v-if="editor" class="title">{{ $t('Label.RefusalEditor') }}</span>
+        <span v-else class="title">{{ $t('Label.AddRefusal') }}</span>
+      </div>
+      <span class="close crm-cursor" @click="close">
+        <el-icon><Close /></el-icon>
+      </span>
+    </div>
+    <el-form ref="formRef" :rules="rules" :model="form" label-width="150PX">
+      <el-form-item prop="content" :label="$t('Label.CN') + ':'">
+        <el-input v-model="form.content" :placeholder="$t('Placeholder.Input')"></el-input>
+      </el-form-item>
+      <el-form-item prop="enContent" :label="$t('Label.EN') + ':'">
+        <el-input v-model="form.enContent" :placeholder="$t('Placeholder.Input')"></el-input>
+      </el-form-item>
+      <el-form-item prop="subIndex" :label="$t('Label.SubIndex') + ':'">
+        <el-input v-model.trim="form.subIndex" :placeholder="$t('Placeholder.Input')"></el-input>
+      </el-form-item>
+    </el-form>
+    <span class="btn crm-cursor" @click="confirm"
+      ><span>{{ $t('Btn.Confirm') }}</span></span
+    >
+  </div>
+</template>
+
+<script setup lang="ts">
+  import { ref, reactive, computed, watch, onMounted, inject } from 'vue'
+  import { useI18n } from 'vue-i18n'
+  import { ElMessage, FormInstance, FormRules } from 'element-plus'
+  import ServiceSystem from '@/service/system'
+  import Config from '@/config/index'
+  import { Close } from '@element-plus/icons-vue'
+
+  const { Code } = Config
+  const { t } = useI18n()
+  const Session = inject('session')
+  const pigeon = inject('pigeon')
+
+  interface Props {
+    dialogInfoTradingAdd: boolean
+    editor?: string
+    myInfo?: any
+    formList?: any
+  }
+
+  const props = withDefaults(defineProps<Props>(), {
+    dialogInfoTradingAdd: false,
+    editor: '',
+    myInfo: null,
+    formList: null,
+  })
+
+  const emit = defineEmits<{
+    (e: 'update:dialogInfoTradingAdd', value: boolean): void
+    (e: 'confirmToReload'): void
+    (e: 'close'): void
+  }>()
+
+  // Refs
+  const formRef = ref<FormInstance>()
+
+  // Reactive data
+  const form = reactive({})
+  const refusalType = ref(null)
+  const rules = ref<FormRules>({
+    subIndex: [
+      {
+        required: true,
+        message: t('Placeholder.Input'),
+        trigger: 'blur',
+      },
+    ],
+  })
+
+  // Methods
+
+  // 提交
+  const confirm = () => {
+    if (!formRef.value) return
+
+    formRef.value.validate((valid) => {
+      if (valid) {
+        toConfirm()
+      } else {
+        return false
+      }
+    })
+  }
+
+  const toConfirm = () => {
+    if (props.editor) {
+      reasonsUpdate()
+    } else {
+      reasonsAdd()
+    }
+  }
+
+  // 原因添加
+  const reasonsAdd = async () => {
+    try {
+      // 验证表单
+      if (!formRef.value) return
+      const valid = await formRef.value.validate()
+      if (!valid) return
+
+      // 准备数据
+      const formData = {
+        type: refusalType.value,
+        ...form,
+        subIndex: Number(form.subIndex) || 0,
+      }
+
+      // 调用接口
+      const res = await ServiceSystem.reasonsRefusalAdd(formData)
+
+      if (res.code === Code.StatusOK) {
+        emit('confirmToReload', true)
+        formRef.value.resetFields()
+        ElMessage.success(t('Msg.Success'))
+      } else {
+        ElMessage.error(res.msg || t('Msg.Fail'))
+      }
+    } catch (error) {
+      console.error('添加失败:', error)
+      ElMessage.error(t('Msg.SystemError'))
+    }
+  }
+
+  // 原因更新
+  const reasonsUpdate = async () => {
+    try {
+      // 验证表单
+      if (!formRef.value) return
+      const valid = await formRef.value.validate()
+      if (!valid) return
+
+      // 准备数据
+      const formData = {
+        ...form,
+        subIndex: Number(form.subIndex) || 0,
+      }
+
+      // 调用接口
+      const res = await ServiceSystem.reasonsRefusalUpdate(formData)
+
+      if (res.code === Code.StatusOK) {
+        emit('confirmToReload', true)
+        emit('closeAdd', false)
+        formRef.value.resetFields()
+        ElMessage.success(t('Msg.Success'))
+      } else {
+        ElMessage.error(res.msg || t('Msg.Fail'))
+      }
+    } catch (error) {
+      console.error('更新失败:', error)
+      ElMessage.error(t('Msg.SystemError'))
+    }
+  }
+
+  const close = () => {
+    emit('update:dialogInfoTradingAdd', false)
+    emit('close')
+  }
+
+  const selectChange = () => {
+    // 选择变更处理
+  }
+
+  // Lifecycle
+  onMounted(() => {})
+
+  // Watch
+  watch(
+    () => props.formList,
+    (newVal) => {
+      if (newVal) {
+        Object.assign(form, newVal)
+      }
+    },
+    { immediate: true }
+  )
+  // Watch
+  watch(
+    () => props.dialogInfoTradingAdd,
+    (newVal) => {
+      if (!newVal && formRef.value) {
+        formRef.value?.resetFields()
+        Object.assign(form, {})
+      }
+      if (newVal) {
+        refusalType.value = props.myInfo.type
+      }
+    },
+    { immediate: true }
+  )
+</script>
+
+<style scoped lang="scss"></style>

+ 371 - 0
src/views/system/Refusal/index.vue

@@ -0,0 +1,371 @@
+<template>
+  <div
+    id="system_Refusal"
+    v-loading="pictLoading"
+    class="view"
+    :element-loading-background="'rgba(43, 48, 67, 0.65)'"
+    :element-loading-spinner="'el-icon-loading'"
+  >
+    <div class="crm_search">
+      <el-form ref="formRef" label-position="" :model="search" label-width="">
+        <el-row>
+          <el-col :span="24" :md="24" :lg="24">
+            <el-form-item>
+              <el-select
+                v-model="search.type"
+                class="crm-border-radius-no"
+                :placeholder="t('Placeholder.Choose')"
+              >
+                <el-option
+                  v-for="option in typeOptions"
+                  :key="option.value"
+                  :label="option.label"
+                  :value="option.value"
+                ></el-option>
+              </el-select>
+            </el-form-item>
+            <el-form-item>
+              <el-button
+                class="crm-border-radius-no crm-border-left-no"
+                :icon="Search"
+                @click="toSearch"
+              ></el-button>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-form-item>
+          <div v-if="display['R-Refusal-Add']?.show" class="search_action_btn">
+            <span class="crm-cursor" @click="addRefusal">
+              <el-icon><Plus /></el-icon>
+              <span>{{ t('Btn.Add') }}</span>
+            </span>
+          </div>
+        </el-form-item>
+      </el-form>
+    </div>
+    <el-table :data="mock_tableData" stripe style="width: 100%">
+      <el-table-column prop="" align="left" :label="t('Label.SubIndex')">
+        <template #default="{ row }">
+          {{ row.subIndex || '--' }}
+        </template>
+      </el-table-column>
+      <el-table-column prop="" align="left" :label="t('Label.CN')">
+        <template #default="{ row }">
+          {{ row.content || '--' }}
+        </template>
+      </el-table-column>
+      <el-table-column prop="" align="left" :label="t('Label.EN')">
+        <template #default="{ row }">
+          {{ row.enContent || '--' }}
+        </template>
+      </el-table-column>
+      <el-table-column prop="" align="center" :label="t('Label.Action')">
+        <template #default="{ row }">
+          <el-dropdown trigger="click" @command="handleCommand">
+            <span class="el-dropdown-link crm-cursor">
+              <i style="font-weight: bold; font-size: 20px" class="iconfont iconcaidan"></i>
+            </span>
+            <template #dropdown>
+              <el-dropdown-menu>
+                <el-dropdown-item
+                  v-if="display['R-Refusal-Update']?.show"
+                  :command="{ type: 'editor', row: row }"
+                >
+                  <el-icon><Operation /></el-icon>
+                  <span>{{ t('Btn.Editor') }}</span>
+                </el-dropdown-item>
+                <el-dropdown-item
+                  v-if="search.type != '-1' && display['R-Refusal-Delete']?.show"
+                  :command="{ type: 'delete', id: row.id }"
+                >
+                  <el-icon><Delete /></el-icon>
+                  <span>{{ t('Btn.Delete') }}</span>
+                </el-dropdown-item>
+              </el-dropdown-menu>
+            </template>
+          </el-dropdown>
+        </template>
+      </el-table-column>
+    </el-table>
+    <div v-if="pagerInfo.rowTotal" class="crm_pagination">
+      <div class="crm_page_total">
+        <span>{{ t('Page.total.item1') }}</span>
+        <span>{{ pagerInfo.rowTotal }}</span>
+        <span>{{ t('Page.total.item2') }}</span>
+      </div>
+      <el-pagination
+        v-model:current-page="pagerInfo.current"
+        class="page"
+        background
+        layout="sizes, prev, pager, next"
+        :page-sizes="[10, 20, 50, 100]"
+        :page-size="pagerInfo.row"
+        :total="pagerInfo.rowTotal"
+        @current-change="handleCurrentChange"
+        @size-change="handleSizeChange"
+      >
+      </el-pagination>
+    </div>
+
+    <!-- 组别新增/修改弹出 -->
+    <Add
+      :dialog-info-trading-add="dialogInfoTradingAdd"
+      :editor="editor"
+      :my-info="myInfo"
+      :form-list="formList"
+      @confirm-to-reload="confirmToReload"
+      @close-add="closeAdd"
+    ></Add>
+    <div v-if="dialogInfoTradingAdd" class="crm_verified_info_mask" @click="closeDiaAdd"></div>
+  </div>
+</template>
+
+<script setup>
+  import { ref, reactive, computed, onMounted, watch, inject } from 'vue'
+  import { useI18n } from 'vue-i18n'
+  import { ElMessage, ElMessageBox } from 'element-plus'
+  import Service from '@/service/system'
+  import Config from '@/config/index'
+  import { Delete, Operation, Plus, Search } from '@element-plus/icons-vue'
+  import Add from './components/Add.vue'
+
+  const { t } = useI18n()
+  const { Code } = Config
+  const Session = inject('session')
+
+  // 响应式数据
+  const pictLoading = ref(false)
+  const formRef = ref(null)
+  const dialogInfoTradingAdd = ref(false)
+  const editor = ref('')
+  const myInfo = ref({})
+  const formList = ref({})
+
+  const search = reactive({
+    type: 1,
+  })
+
+  const mock_tableData = ref([])
+
+  const pagerInfo = reactive({
+    row: 10,
+    current: 1,
+    pageTotal: 0,
+    rowTotal: 0,
+  })
+
+  // 计算属性
+  const display = computed(() => {
+    return JSON.parse(Session.Get('display', true))
+  })
+
+  // 类型选项
+  const typeOptions = computed(() => [
+    { label: t('R-VerifiedUser'), value: 1 },
+    { label: t('R-PendingAccount'), value: 2 },
+    { label: t('R-LeverAdjust'), value: 3 },
+    { label: t('R-PasswordReset'), value: 4 },
+    { label: t('R-BelongingAdjust'), value: 5 },
+    { label: t('R-ActivitiesApply'), value: 6 },
+    { label: t('R-CommissionAdjust'), value: 7 },
+    { label: t('R-HangUndo'), value: 8 },
+    { label: t('R-AgentApply'), value: 9 },
+    { label: t('R-Financial'), value: 10 },
+    { label: t('R-Real'), value: 11 },
+    { label: t('R-PammManagerValid'), value: 12 },
+    { label: t('Documentary.R-SignalSourceApply'), value: 13 },
+    { label: t('Documentary.R-RecruitmentReview'), value: 14 },
+    { label: t('R-Card'), value: 15 },
+    { label: t('R-System'), value: -1 },
+  ])
+
+  // 生命周期
+  onMounted(() => {
+    searchFunc()
+  })
+
+  // 监听搜索类型变化
+  watch(
+    () => search.type,
+    () => {
+      searchFunc()
+    }
+  )
+
+  // 方法
+  // 点击操作的回调
+  const handleCommand = (command) => {
+    if (command.type == 'editor') {
+      editor.value = 1
+      refusalSingle(command.row.id)
+    } else if (command.type == 'delete') {
+      deleteReal(command.id)
+    }
+  }
+
+  // 新增
+  const closeDiaAdd = () => {
+    dialogInfoTradingAdd.value = false
+    editor.value = ''
+  }
+
+  const closeAdd = (val) => {
+    dialogInfoTradingAdd.value = val
+  }
+
+  const addRefusal = () => {
+    editor.value = ''
+    myInfo.value.type = search.type
+    dialogInfoTradingAdd.value = true
+  }
+
+  const confirmToReload = () => {
+    closeDiaAdd()
+    searchFunc()
+  }
+
+  // 删除
+  const deleteReal = async (id) => {
+    try {
+      await ElMessageBox.confirm(t('Msg.Delete'), t('Msg.SystemPrompt'), {
+        confirmButtonText: t('Btn.Confirm'),
+        cancelButtonText: t('Btn.Cancel'),
+        type: 'warning',
+      })
+
+      const res = await Service.reasonsRefusalDelete({ ids: [id] })
+      if (res.code == Code.StatusOK) {
+        ElMessage.success(t('Msg.DeleteSuccess'))
+        searchFunc()
+      } else {
+        ElMessage.error(res.msg)
+      }
+    } catch (error) {
+      if (error !== 'cancel') {
+        ElMessage.error(t('Msg.SystemError'))
+      }
+    }
+  }
+
+  // 原因single
+  const refusalSingle = async (id) => {
+    const res = await Service.reasonsRefusalSingle({
+      id: id,
+    })
+    if (res.code == Code.StatusOK) {
+      formList.value = res.data
+      dialogInfoTradingAdd.value = true
+      ElMessage.success(t('Msg.SearchSuccess'))
+    } else {
+      ElMessage.error(res.msg)
+    }
+  }
+
+  // 获取列表数据
+  const searchFunc = async () => {
+    pictLoading.value = true
+    if (!display.value['R-Refusal-Search']?.show) {
+      ElMessage.warning(t('Msg.NotDisplay'))
+      pictLoading.value = false
+      return
+    }
+    const res = await Service.reasonsRefusalSearchList({
+      ...search,
+      page: {
+        current: pagerInfo.current,
+        row: pagerInfo.row,
+      },
+    })
+    if (res.code == Code.StatusOK) {
+      mock_tableData.value = res.data
+      if (res.page != null) {
+        pagerInfo.rowTotal = res.page.rowTotal
+        pagerInfo.pageTotal = res.page.pageTotal
+      } else {
+        pagerInfo.rowTotal = 0
+      }
+      ElMessage.success(t('Msg.SearchSuccess'))
+    } else {
+      ElMessage.error(res.msg)
+    }
+    pictLoading.value = false
+  }
+
+  // 搜索
+  const toSearch = () => {
+    pagerInfo.current = 1
+    searchFunc()
+  }
+
+  // 分页返回数据
+  const handleSizeChange = (val) => {
+    pagerInfo.row = val
+    searchFunc()
+  }
+
+  const handleCurrentChange = (val) => {
+    pagerInfo.current = val
+    searchFunc()
+  }
+</script>
+<style scoped lang="scss">
+  #system_Refusal {
+    .crm_search {
+      .search_action_btn {
+        .delete {
+          background-color: #a1a1a1;
+        }
+        .delete.active {
+          background-color: #368fec;
+        }
+      }
+      .chooseLang {
+        margin-top: 2px;
+        margin-right: 10px;
+        > span {
+          border: 1px solid #dcdfe6;
+          padding: 0 8px;
+          min-width: 100px;
+          display: inline-block;
+          height: 32px;
+          line-height: 32px;
+          box-sizing: border-box;
+          text-align: center;
+        }
+        span.active {
+          background-color: #368fec;
+          border-color: #368fec;
+          color: #ffffff;
+        }
+      }
+    }
+    .el-table .state {
+      display: inline-block;
+      min-width: 80px;
+      max-width: 150px;
+      box-sizing: border-box;
+      line-height: 1.5;
+      border-radius: 2px;
+      padding: 2px 10px;
+      color: #ffffff;
+    }
+    .crm_verified_info_mask_trading {
+      position: fixed;
+      left: 0;
+      top: 0;
+      width: 100%;
+      height: 100%;
+      background-color: rgba(43, 48, 67, 0.65);
+      z-index: 88;
+    }
+  }
+</style>
+<style lang="scss">
+  #system_Refusal {
+    .dialog_header_w {
+      .crm_search_down {
+        width: 400px;
+      }
+    }
+  }
+</style>

+ 35 - 3
src/views/user/userRole/components/RoleAdd/index.vue

@@ -463,8 +463,9 @@
       const valid = await dialogCheckFormRef?.value.validate()
       console.log(valid)
       console.log(dialogCheck_form)
+      const { typeIndex } = dialogCheck_form
       if (valid) {
-        if (dialogCheck_form.typeIndex == 1 || dialogCheck_form.typeIndex == 2) {
+        if (typeIndex == 1 || typeIndex == 2) {
           dialogCheck_form.subIndex = Number(dialogCheck_form.subIndex)
           dialogCheck_form.code = dialogCheck_form.name
 
@@ -472,6 +473,16 @@
             ...dialogCheck_form,
           })
 
+          if (res.code == Code.StatusOK) {
+            ElMessage.success(res.msg)
+          } else {
+            ElMessage.error(res.msg)
+          }
+        } else if (typeIndex == 3) {
+          dialogCheck_form.code = dialogCheck_form.name
+          let res = await ServiceUser.authorityActionAdd({
+            ...dialogCheck_form,
+          })
           if (res.code == Code.StatusOK) {
             ElMessage.success(res.msg)
           } else {
@@ -568,7 +579,8 @@
     try {
       const valid = await dialogCheckFormRef.value.validate()
       if (valid) {
-        if (dialogCheck_form.typeIndex == 1 || dialogCheck_form.typeIndex == 2) {
+        const { typeIndex } = dialogCheck_form
+        if (typeIndex == 1 || typeIndex == 2) {
           dialogCheck_form.subIndex = Number(dialogCheck_form.subIndex)
           dialogCheck_form.code = dialogCheck_form.name
 
@@ -576,6 +588,16 @@
             ...dialogCheck_form,
           })
 
+          if (res.code == Code.StatusOK) {
+            ElMessage.success(res.msg)
+          } else {
+            ElMessage.error(res.msg)
+          }
+        } else if (typeIndex == 3) {
+          dialogCheck_form.code = dialogCheck_form.name
+          let res = await ServiceUser.authorityActionUpdate({
+            ...dialogCheck_form,
+          })
           if (res.code == Code.StatusOK) {
             ElMessage.success(res.msg)
           } else {
@@ -594,11 +616,21 @@
     try {
       const valid = await dialogCheckFormRef.value.validate()
       if (valid) {
-        if (dialogCheck_form.typeIndex == 1 || dialogCheck_form.typeIndex == 2) {
+        const { typeIndex } = dialogCheck_form
+        if (typeIndex == 1 || typeIndex == 2) {
           const res = await ServiceUser.authorityNodeDelete({
             ...dialogCheck_form,
           })
 
+          if (res.code == Code.StatusOK) {
+            ElMessage.success(res.msg)
+          } else {
+            ElMessage.error(res.msg)
+          }
+        } else if (typeIndex == 3) {
+          let res = await ServiceUser.authorityActionDelete({
+            ...dialogCheck_form,
+          })
           if (res.code == Code.StatusOK) {
             ElMessage.success(res.msg)
           } else {