|
@@ -28,12 +28,12 @@
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-form>
|
|
</el-form>
|
|
</el-row>
|
|
</el-row>
|
|
- <el-row>
|
|
|
|
|
|
+ <!-- <el-row>
|
|
<div class="mb8" style="width: 100%">
|
|
<div class="mb8" style="width: 100%">
|
|
<right-toolbar v-model:showSearch="showSearch" class="ml10" style="float: right; margin-right: 20px"
|
|
<right-toolbar v-model:showSearch="showSearch" class="ml10" style="float: right; margin-right: 20px"
|
|
@queryTable="getDataList"></right-toolbar>
|
|
@queryTable="getDataList"></right-toolbar>
|
|
</div>
|
|
</div>
|
|
- </el-row>
|
|
|
|
|
|
+ </el-row> -->
|
|
|
|
|
|
<el-tabs v-model="activeName" class="demo-tabs" @tab-click="handleClick">
|
|
<el-tabs v-model="activeName" class="demo-tabs" @tab-click="handleClick">
|
|
<el-tab-pane label="使用中" name="tab1"></el-tab-pane>
|
|
<el-tab-pane label="使用中" name="tab1"></el-tab-pane>
|
|
@@ -69,17 +69,27 @@
|
|
</el-table-column>
|
|
</el-table-column>
|
|
<el-table-column label="营销投放" prop="isMarketing" width="120">
|
|
<el-table-column label="营销投放" prop="isMarketing" width="120">
|
|
<template #default="{ row }">
|
|
<template #default="{ row }">
|
|
- <el-switch v-model="row.isMarketing" inline-prompt active-text="开启" inactive-text="关闭" :active-value="1"
|
|
|
|
|
|
+ <el-switch v-model="row.isMarketing" inline-prompt :active-value="1"
|
|
:inactive-value="0" @change="handleChange(row)" />
|
|
:inactive-value="0" @change="handleChange(row)" />
|
|
|
|
+ <!-- active-text="开启" inactive-text="关闭" -->
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
<el-table-column label="域名限制" prop="isHttp" width="120">
|
|
<el-table-column label="域名限制" prop="isHttp" width="120">
|
|
<template #default="{ row }">
|
|
<template #default="{ row }">
|
|
- <el-switch v-model="row.isHttp" inline-prompt active-text="开启" inactive-text="关闭" :active-value="1"
|
|
|
|
|
|
+ <el-switch v-model="row.isHttp" inline-prompt :active-value="1"
|
|
:inactive-value="0" @change="handleChange(row)" />
|
|
:inactive-value="0" @change="handleChange(row)" />
|
|
|
|
+ <!-- active-text="开启" inactive-text="关闭" -->
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
- <el-table-column label="域名集合" prop="domains" width="240" show-overflow-tooltip>
|
|
|
|
|
|
+ <el-table-column prop="domains" width="240" show-overflow-tooltip>
|
|
|
|
+ <template #header>
|
|
|
|
+ <span style="display: inline-block; align-items: center;">
|
|
|
|
+ 域名集合
|
|
|
|
+ <el-tooltip effect="light" content="鼠标悬浮查看域名分组详情" placement="top">
|
|
|
|
+ <el-icon><Warning /></el-icon>
|
|
|
|
+ </el-tooltip>
|
|
|
|
+ </span>
|
|
|
|
+ </template>
|
|
<template #default="{ row }">
|
|
<template #default="{ row }">
|
|
<div style="
|
|
<div style="
|
|
padding: 0 20px;
|
|
padding: 0 20px;
|
|
@@ -102,8 +112,8 @@
|
|
<el-table-column prop="ips" width="300">
|
|
<el-table-column prop="ips" width="300">
|
|
<template #header>
|
|
<template #header>
|
|
<span style="display: inline-block; align-items: center;">
|
|
<span style="display: inline-block; align-items: center;">
|
|
- IP限制
|
|
|
|
- <el-tooltip effect="light" content="鼠标悬浮查看分组ip详情" placement="top">
|
|
|
|
|
|
+ IP集合
|
|
|
|
+ <el-tooltip effect="light" content="鼠标悬浮查看ip分组详情" placement="top">
|
|
<el-icon><Warning /></el-icon>
|
|
<el-icon><Warning /></el-icon>
|
|
</el-tooltip>
|
|
</el-tooltip>
|
|
</span>
|
|
</span>
|
|
@@ -169,7 +179,7 @@
|
|
:type="activeName == 'tab1' ? 'danger' : 'success'"
|
|
:type="activeName == 'tab1' ? 'danger' : 'success'"
|
|
style="margin-left: 0;"
|
|
style="margin-left: 0;"
|
|
:icon="activeName == 'tab1' ? 'delete' : 'refresh'"
|
|
:icon="activeName == 'tab1' ? 'delete' : 'refresh'"
|
|
- @click="query()" text
|
|
|
|
|
|
+ @click="handleDelete(scope.row)" text
|
|
v-auth="'sys_menu_edit'">
|
|
v-auth="'sys_menu_edit'">
|
|
{{ activeName == 'tab1' ? '拉黑' : '还原' }}
|
|
{{ activeName == 'tab1' ? '拉黑' : '还原' }}
|
|
</el-button>
|
|
</el-button>
|
|
@@ -194,7 +204,7 @@ import { ref } from 'vue'
|
|
const MenuDialog = defineAsyncComponent(() => import('./components/form.vue'));
|
|
const MenuDialog = defineAsyncComponent(() => import('./components/form.vue'));
|
|
const StatisticalDialog = defineAsyncComponent(() => import('./components/statistical.vue'));
|
|
const StatisticalDialog = defineAsyncComponent(() => import('./components/statistical.vue'));
|
|
|
|
|
|
-import type { TabsPaneContext } from 'element-plus'
|
|
|
|
|
|
+import { ElMessage, ElNotification, messageConfig, type TabsPaneContext } from 'element-plus'
|
|
|
|
|
|
const activeName = ref('tab1')
|
|
const activeName = ref('tab1')
|
|
|
|
|
|
@@ -235,21 +245,13 @@ getAppTypes();
|
|
|
|
|
|
const triggerRules = [
|
|
const triggerRules = [
|
|
{
|
|
{
|
|
- label: '仅一次 - URL',
|
|
|
|
|
|
+ label: '仅一次',
|
|
value: 1,
|
|
value: 1,
|
|
},
|
|
},
|
|
{
|
|
{
|
|
- label: '多次 - URL',
|
|
|
|
|
|
+ label: '多次',
|
|
value: 2,
|
|
value: 2,
|
|
},
|
|
},
|
|
- {
|
|
|
|
- label: '仅一次 - 视频',
|
|
|
|
- value: 3,
|
|
|
|
- },
|
|
|
|
- {
|
|
|
|
- label: '多次 - 视频',
|
|
|
|
- value: 4,
|
|
|
|
- },
|
|
|
|
]
|
|
]
|
|
|
|
|
|
const { getDataList, currentChangeHandle, sizeChangeHandle, tableStyle } = useTable(state);
|
|
const { getDataList, currentChangeHandle, sizeChangeHandle, tableStyle } = useTable(state);
|
|
@@ -302,6 +304,28 @@ const onOpenStatistical = (row: any) => {
|
|
statisticalDialogRef.value.openDialog(row);
|
|
statisticalDialogRef.value.openDialog(row);
|
|
};
|
|
};
|
|
|
|
|
|
|
|
+// 删除操作
|
|
|
|
+const handleDelete = async (row: any) => {
|
|
|
|
+ try {
|
|
|
|
+ if(activeName.value == 'tab1'){
|
|
|
|
+ await useMessageBox().confirm('是否确认拉黑该应用');
|
|
|
|
+ }else{
|
|
|
|
+ ElMessage.success('还原成功!');
|
|
|
|
+ }
|
|
|
|
+ } catch {
|
|
|
|
+ return;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ // try {
|
|
|
|
+ // await delObj(ids);
|
|
|
|
+ // getDataList();
|
|
|
|
+ // useMessage().success(t('common.delSuccessText'));
|
|
|
|
+ // } catch (err: any) {
|
|
|
|
+ // useMessage().error(err.msg);
|
|
|
|
+ // }
|
|
|
|
+ query();
|
|
|
|
+};
|
|
|
|
+
|
|
</script>
|
|
</script>
|
|
<style scoped lang="scss">
|
|
<style scoped lang="scss">
|
|
:deep(.el-link__inner) {
|
|
:deep(.el-link__inner) {
|