Compare commits

...

2 Commits

Author SHA1 Message Date
YuanJian d312d5e941 feat:1,tapdbug修改 2025-10-10 11:43:45 +08:00
YuanJian 4299efdfc1 feat:1,tapdbug修改 2025-10-10 10:10:53 +08:00
18 changed files with 372 additions and 105 deletions

View File

@ -5,4 +5,4 @@ VITE_APP_TITLE = 代理管理系统
VITE_APP_ENV = 'development'
# 代理管理系统/开发环境
VITE_APP_BASE_API = '/ff-api'
VITE_APP_BASE_API = '/dev-api'

BIN
dist.rar 100644

Binary file not shown.

View File

@ -0,0 +1,114 @@
<template>
<el-form-item :label="label" v-if="hasPermission" :prop="prop">
<el-select
v-model="innerValue"
filterable
clearable
reserve-keyword
:placeholder="placeholder"
:remote-method="loadOptions"
:loading="loadingSelect"
style="width: 240px"
>
<!-- 正常列表 -->
<el-option
v-for="item in agentListSelect"
:key="item.tenantKey"
:label="item.tenantKey"
:value="item.tenantKey"
/>
<!-- 加载更多按钮 -->
<el-option
v-if="hasMore && agentListSelect.length > 0"
disabled
value=""
>
<div
style="color:#409EFF;cursor:pointer;width:100%;"
@click.stop="loadMore"
>
{{ loadingMore ? "加载中..." : "加载更多" }}
</div>
</el-option>
</el-select>
</el-form-item>
</template>
<script setup>
import { ref, watch, onMounted, computed } from "vue"
import { superTenantList } from "@/api/super/tenant"
import auth from "@/plugins/auth"
const props = defineProps({
modelValue: String, // v-model
label: {
type: String,
default: "商户账号"
},
prop: {
type: String,
default: "tenantKey"
},
placeholder: {
type: String,
default: "请输入商户账号搜索"
}
})
const emit = defineEmits(["update:modelValue"])
//
const hasPermission = computed(() => auth.hasPermi("super:tenant:list"))
//
const innerValue = ref(props.modelValue)
watch(() => props.modelValue, v => (innerValue.value = v))
watch(innerValue, v => emit("update:modelValue", v))
// &
const agentListSelect = ref([])
const loadingSelect = ref(false)
const loadingMore = ref(false)
const hasMore = ref(true)
const queryParamSelect = ref({
pageNum: 1,
pageSize: 10,
tenantKey: ""
})
//
const loadOptions = async (query) => {
queryParamSelect.value.pageNum = 1
queryParamSelect.value.tenantKey = query
loadingSelect.value = true
try {
const res = await superTenantList(queryParamSelect.value)
agentListSelect.value = res.rows || []
hasMore.value = agentListSelect.value.length < (res.total || 0)
} finally {
loadingSelect.value = false
}
}
//
const loadMore = async () => {
if (!hasMore.value) return
queryParamSelect.value.pageNum++
loadingMore.value = true
try {
const res = await superTenantList(queryParamSelect.value)
agentListSelect.value = [...agentListSelect.value, ...(res.rows || [])]
hasMore.value = agentListSelect.value.length < (res.total || 0)
} finally {
loadingMore.value = false
}
}
//
onMounted(() => {
if (hasPermission.value) {
loadOptions("")
}
})
</script>

View File

@ -333,6 +333,7 @@ function submitForm() {
tenantType: form.value.tenantType,
timeZone: form.value.timeZone,
scoreRatio: form.value.scoreRatio,
googleCode: form.value.googleCode,
}
createAgent(dataObj).then(response => {
loadingButton.value = false;

View File

@ -3,15 +3,7 @@
<table-search-card :leftSpan="24" :model="queryParams" @getList="getList" @handleQuery="handleQuery" @resetQuery="resetQuery">
<template #left>
<table-search-date ref="searchDateRef" v-model:dateRange="dateRange" @dateChange="handleQuery" v-model:operateTimeType="operateTimeType"></table-search-date>
<el-form-item :label="t('商户账号')" prop="tenantKey">
<el-input
v-model="queryParams.tenantKey"
:placeholder="t('请输入商户账号')"
clearable
style="width: 200px"
@keyup.enter="handleQuery"
/>
</el-form-item>
<TenantSelect ref="tenantSelectRef" v-model="queryParams.tenantKey" :placeholder="t('请选择商户账号')" style="width: 300px" />
<el-form-item :label="t('玩家帐号')" prop="ourAccount">
<el-input
v-model="queryParams.ourAccount"
@ -121,6 +113,7 @@
import { getLocalStorage } from "@/utils/auth";
import CustomSelect from '@/components/CustomSelect';
import TableSearchDate from '@/components/TableSearchDate'
import TenantSelect from '@/components/TenantSelect';
import Crontab from '@/components/Crontab'
import { parseTime } from '@/utils/ruoyi'; //
import { onMounted } from "vue";

View File

@ -3,7 +3,7 @@
<table-search-card :model="queryParams" @getList="getList" @handleQuery="handleQuery" @resetQuery="resetQuery">
<template #left>
<table-search-date ref="searchDateRef" @dateChange="handleQuery" v-model:dateRange="dateRange" v-model:operateTimeType="operateTimeType"></table-search-date>
<select-input-form ref="selectInputFormRef" :queryParamsList="queryParamsList" :queryParams="queryParams"></select-input-form>
<select-input-form ref="selectInputFormRef" :queryParamsList="queryParamsList" v-if="showLodings" :queryParams="queryParams"></select-input-form>
<el-form-item :label="t('佣金类型')" prop="commissionType">
<el-select v-if="commissionTypeOption.length > 0" v-model="queryParams.commissionType" clearable style="width:220px;" :placeholder="t('请选择')">
<el-option
@ -140,8 +140,13 @@ function handleQuery() {
getList();
}
const searchDateRef = ref(null);
const showLodings = ref(true);
/** 重置按钮操作 */
function resetQuery() {
showLodings.value = false;
nextTick(() => {
showLodings.value = true;
})
dateRange.value = [];
operateTimeType.value = "day";
searchDateRef.value.timeTypeChange(operateTimeType.value)

View File

@ -3,7 +3,41 @@
<table-search-card :model="queryParams" @getList="getList" @handleQuery="handleQuery" @resetQuery="resetQuery">
<template #left>
<table-search-date ref="searchDateRef" v-model:dateRange="dateRange" @dateChange="handleQuery" v-model:operateTimeType="operateTimeType"></table-search-date>
<select-input-form ref="selectInputFormRef" :queryParamsList="queryParamsList" :queryParams="queryParams"></select-input-form>
<!-- <select-input-form ref="selectInputFormRef" :queryParamsList="queryParamsList" :queryParams="queryParams"></select-input-form> -->
<el-form-item :label="t('商户账号')" v-hasPermi="['super:tenant:list']" prop="tenantKey">
<el-select
v-model="queryParams.tenantKey"
filterable
clearable
reserve-keyword
placeholder="请输入商户账号搜索"
:remote-method="loadOptions"
:loading="loadingSelect"
style="width: 240px"
>
<!-- 正常列表 -->
<el-option
v-for="item in agentListSelect"
:key="item.tenantKey"
:label="item.tenantKey"
:value="item.tenantKey"
/>
<!-- 加载更多按钮 -->
<el-option
v-if="hasMore && agentListSelect.length > 0"
disabled
value=""
>
<div
style="color:#409EFF;cursor:pointer;width:100%;"
@click.stop="loadMore"
>
{{ loadingMore ? "加载中..." : "加载更多" }}
</div>
</el-option>
</el-select>
</el-form-item>
<el-form-item prop="gameQuotaFlowId">
<el-input v-model="queryParams.gameQuotaFlowId" style="width: 240px" :placeholder="t('流水ID')" />
</el-form-item>
@ -116,6 +150,8 @@
import DictText from '@/components/DictText'
import SelectInputForm from '@/components/SelectInputForm';
import Crontab from '@/components/Crontab'
import auth from '@/plugins/auth';
import { superTenantList } from "@/api/super/tenant";
import { parseTime } from '@/utils/ruoyi'; //
const router = useRouter();
const { proxy } = getCurrentInstance();
@ -139,6 +175,49 @@
}])
const { queryParams, form, rules } = toRefs(data);
const dateRange = ref([]),operateTimeType = ref("day");
const agentListSelect = ref([])
const loadingSelect = ref(false)
const loadingMore = ref(false)
const hasMore = ref(true)
const queryParamSelect = ref({
pageNum: 1,
pageSize: 10,
tenantKey: ""
})
//
const loadOptions = async (query) => {
queryParamSelect.value.pageNum = 1
queryParamSelect.value.tenantKey = query
loadingSelect.value = true
try {
const res = await superTenantList(queryParamSelect.value)
agentListSelect.value = res.rows || []
hasMore.value = agentListSelect.value.length < (res.total || 0)
} finally {
loadingSelect.value = false
}
}
//
const loadMore = async () => {
if (!hasMore.value) return
queryParamSelect.value.pageNum++
loadingMore.value = true
try {
const res = await superTenantList(queryParamSelect.value)
agentListSelect.value = [...agentListSelect.value, ...(res.rows || [])]
hasMore.value = agentListSelect.value.length < (res.total || 0)
} finally {
loadingMore.value = false
}
}
/** 查询列表 */
function getList() {
loading.value = true;
@ -174,6 +253,9 @@
onMounted(() => {
getList();
getSuperCommonOperationTypes();
if (auth.hasPermi('super:tenant:list') == true){
loadOptions('');
}
});
</script>

View File

@ -123,7 +123,10 @@ const data = reactive({
],
content:[
{ required: true, message: "请输入内容", trigger: "change" },
]
],
replyContent:[
{ required: true, message: "请输入回复内容", trigger: "change" },
],
}
});
@ -217,8 +220,9 @@ function submitForm1() {
form.value.replyContent = '';
getList();
}).catch(() => {
loadingButton.value = false;
});
}
});
}

View File

@ -3,15 +3,7 @@
<table-search-card :model="queryParams" @getList="getList" @handleQuery="handleQuery" @resetQuery="resetQuery">
<template #left>
<table-search-date ref="searchDateRef" v-model:dateRange="dateRange" @dateChange="handleQuery" v-model:operateTimeType="operateTimeType"></table-search-date>
<el-form-item :label="t('商户账号')" prop="tenantKey">
<el-input
v-model="queryParams.tenantKey"
:placeholder="t('请输入商户账号')"
clearable
style="width: 200px"
@keyup.enter="handleQuery"
/>
</el-form-item>
<TenantSelect ref="tenantSelectRef" v-model="queryParams.tenantKey" :placeholder="t('请选择商户账号')" style="width: 300px" />
<el-form-item :label="t('状态')" prop="status">
<CustomSelect v-model="queryParams.status" :options="tenantStatusArr" placeholder="请选择状态" style="width: 200px" />
</el-form-item>
@ -219,6 +211,7 @@
import CustomSelect from '@/components/CustomSelect'
import TableSearchDate from '@/components/TableSearchDate'
import Crontab from '@/components/Crontab'
import TenantSelect from '@/components/TenantSelect';
import { parseTime } from '@/utils/ruoyi'; //
import { nextTick, onMounted } from "vue";
const router = useRouter();

View File

@ -3,15 +3,7 @@
<table-search-card :model="queryParams" @getList="getList" @handleQuery="handleQuery" @resetQuery="resetQuery">
<template #left>
<table-search-date ref="searchDateRef" v-model:dateRange="dateRange" @dateChange="handleQuery" v-model:operateTimeType="operateTimeType"></table-search-date>
<el-form-item :label="t('商户账号')" prop="tenantKey">
<el-input
v-model="queryParams.tenantKey"
:placeholder="t('请输入商户账号')"
clearable
style="width: 200px"
@keyup.enter="handleQuery"
/>
</el-form-item>
<TenantSelect ref="tenantSelectRef" v-model="queryParams.tenantKey" :placeholder="t('请选择商户账号')" style="width: 300px" />
<el-form-item :label="t('玩家账号')" prop="memberAccount">
<el-input
v-model="queryParams.memberAccount"
@ -170,7 +162,8 @@
import {superQueryBalance} from "@/api/super/platform";
import TableSearchDate from '@/components/TableSearchDate'
import { getLocalStorage } from "@/utils/auth";
import CustomSelect from '@/components/CustomSelect'
import CustomSelect from '@/components/CustomSelect';
import TenantSelect from '@/components/TenantSelect';
import Crontab from '@/components/Crontab'
import { parseTime } from '@/utils/ruoyi'; //
import { nextTick } from "vue";

View File

@ -2,15 +2,40 @@
<div class="app-container">
<table-search-card :model="queryParams" @getList="getList" @handleQuery="handleQuery" @resetQuery="resetQuery">
<template #left>
<el-form-item :label="t('商户账号')" prop="tenantKey">
<el-input
<el-form-item :label="t('商户账号')" v-hasPermi="['super:tenant:list']" prop="tenantKey">
<el-select
v-model="queryParams.tenantKey"
:placeholder="t('请输入商户账号')"
filterable
clearable
style="width: 200px"
@keyup.enter="handleQuery"
/>
</el-form-item>
reserve-keyword
placeholder="请输入商户账号搜索"
:remote-method="loadOptions"
:loading="loadingSelect"
style="width: 240px"
>
<!-- 正常列表 -->
<el-option
v-for="item in agentListSelect"
:key="item.tenantKey"
:label="item.tenantKey"
:value="item.tenantKey"
/>
<!-- 加载更多按钮 -->
<el-option
v-if="hasMore && agentListSelect.length > 0"
disabled
value=""
>
<div
style="color:#409EFF;cursor:pointer;width:100%;"
@click.stop="loadMore"
>
{{ loadingMore ? "加载中..." : "加载更多" }}
</div>
</el-option>
</el-select>
</el-form-item>
<el-form-item :label="t('状态')" prop="tenantStatus">
<CustomSelect v-model="queryParams.tenantStatus" :options="tenantStatusArr" placeholder="请选择状态" style="width: 200px" />
</el-form-item>
@ -235,7 +260,8 @@
import CustomSelect from '@/components/CustomSelect'
import CopyIcon from '@/components/CopyIcon'
import NumberInput from '@/components/NumberInput';
import Crontab from '@/components/Crontab'
import Crontab from '@/components/Crontab';
import auth from '@/plugins/auth';
import { Search } from '@element-plus/icons-vue'
import { parseTime } from '@/utils/ruoyi'; //
import { get } from "@vueuse/core";
@ -294,8 +320,51 @@ currencySelectArr.value = res.map(item => {
pwd: "",
});
const openReset = ref(false);
const agentListSelect = ref([])
const loadingSelect = ref(false)
const loadingMore = ref(false)
const hasMore = ref(true)
const queryParamSelect = ref({
pageNum: 1,
pageSize: 10,
tenantKey: ""
})
//
const loadOptions = async (query) => {
queryParamSelect.value.pageNum = 1
queryParamSelect.value.tenantKey = query
loadingSelect.value = true
try {
const res = await superTenantList(queryParamSelect.value)
agentListSelect.value = res.rows || []
hasMore.value = agentListSelect.value.length < (res.total || 0)
} finally {
loadingSelect.value = false
}
}
//
const loadMore = async () => {
if (!hasMore.value) return
queryParamSelect.value.pageNum++
loadingMore.value = true
try {
const res = await superTenantList(queryParamSelect.value)
agentListSelect.value = [...agentListSelect.value, ...(res.rows || [])]
hasMore.value = agentListSelect.value.length < (res.total || 0)
} finally {
loadingMore.value = false
}
}
/** 查询列表 */
function getList() {
console.log('getList')
loading.value = true;
let query={
pageNum: 1,
@ -718,15 +787,15 @@ const searchPlatformCode = ref('');
const searchCurrencyCode = ref('');
//
const searchSystemPlatforms = (platformCode) => {
const keyword = platformCode?.trim();
const keyword = platformCode?.trim().toLowerCase(); //
if (!keyword) {
form.value.tenantSystemPlatforms = PlatformRatioAll.value;
return;
}
// platformCode
// platformCode
const matchedCodes = PlatformRatioAll.value
.filter(item => item.platformCode?.includes(keyword))
.filter(item => item.platformCode?.toLowerCase().includes(keyword))
.map(item => item.platformCode);
// platformCode
@ -771,8 +840,13 @@ function submitForm() {
}
});
}
getList();
onMounted(() => {
console.log('onMounted');
getList();
if (auth.hasPermi('super:tenant:list') == true){
loadOptions('');
}
})
</script>
<style scoped lang="scss">

View File

@ -109,30 +109,30 @@
</table-search-card>
<el-table v-loading="loading" :data="agentList" class="c-table-main" stripe border>
<!-- <el-table-column type="selection" width="55" align="center" /> -->
<el-table-column :label="t('商户账号')" align="center" prop="tenantKey" :show-overflow-tooltip="true" min-width="175px">
<el-table-column :label="t('商户账号')" align="center" prop="tenantKey" fixed="left" :show-overflow-tooltip="true" min-width="175px">
<template #default="{row}">
{{ row.tenantKey }}
<CopyIcon :colors="'#409EFF'" :text="String(row.tenantKey)"></CopyIcon>
</template>
</el-table-column>
<!-- <el-table-column :label="t('前缀')" width="100" align="center" prop="tenantSn" /> -->
<el-table-column :label="t('玩家账号')" align="center" prop="memberAccount" min-width="180px" >
<el-table-column :label="t('玩家账号')" align="center" fixed="left" prop="memberAccount" min-width="180px" >
<template #default="{row}">
{{ row.memberAccount? row.memberAccount : '--' }}
</template>
</el-table-column>
<el-table-column :label="t('游戏账号')" align="center" prop="gameAccount" min-width="180px" >
<el-table-column :label="t('游戏账号')" align="center" fixed="left" prop="gameAccount" min-width="180px" >
<template #default="{row}">
{{ row.gameAccount? row.gameAccount : '--' }}
</template>
</el-table-column>
<el-table-column :label="t('币种')" width="100" align="center" prop="currencyCode" />
<el-table-column :label="t('游戏平台')" align="center" prop="platformName" min-width="130">
<el-table-column :label="t('币种')" width="100" align="center" fixed="left" prop="currencyCode" />
<el-table-column :label="t('游戏平台')" align="center" fixed="left" prop="platformName" min-width="130">
<template #default="{row}">
{{ row.platformName? row.platformName : '--' }}
</template>
</el-table-column>
<el-table-column align="center" prop="exchangeMoney" min-width="110px">
<el-table-column align="center" fixed="left" prop="exchangeMoney" min-width="110px">
<template #header>
{{ t('转账金额') }}
<IconTips>{{ t('会员带入带出的游戏的金币') }}
@ -507,15 +507,10 @@ const handleAudit = (row) => {
});
});
};
const agentListSelect = ref([])
const agentListSelect = ref([])
const loadingSelect = ref(false)
const loadingMore = ref(false)
const hasMore = ref(true)
const queryParamSelect = ref({
pageNum: 1,
pageSize: 10,

View File

@ -145,7 +145,7 @@
<el-scrollbar max-height="600px">
<el-form ref="openReviseRef" :model="rowOpenRevise" :rules="ruleForm" label-width="160px">
<el-form-item :label="t('游戏平台')" prop="platformCode">
<CustomSelect v-model="rowOpenRevise.platformCode" :options="sys_job_status" placeholder="请选择游戏平台" style="width: 400px" />
<CustomSelect v-model="rowOpenRevise.platformCode" filterable :options="sys_job_status" placeholder="请选择游戏平台" style="width: 400px" />
</el-form-item>
<el-form-item :label="t('游戏名称')" style="width: 100%;" prop="gameName">
<el-input v-model="rowOpenRevise.gameName" style="width: 400px;" :placeholder="t('请输入游戏名称')"> </el-input>

View File

@ -232,18 +232,22 @@ function toggleExpandAll() {
refreshTable.value = false;
isExpandAll.value = !isExpandAll.value;
nextTick(() => {
refreshTable.value = true;
refreshTable.value = true;
});
}
/** 修改按钮操作 */
function handleUpdate(row) {
reset();
listDeptExcludeChild(row.deptId).then(response => {
listDept().then(response => {
deptOptions.value = proxy.handleTree(response.data, "deptId");
});
// listDeptExcludeChild(row.deptId).then(response => {
// deptOptions.value = proxy.handleTree(response.data, "deptId");
// });
getDept(row.deptId).then(response => {
form.value = response.data;
form.value.parentId = response.data.parentId == 0 ?response.data.deptId: response.data.parentId;
open.value = true;
title.value = "修改部门";
setTimeout(() => {

View File

@ -4,10 +4,10 @@
<div style="width: 600px;text-align: center;border: 1px solid #ccc;border-radius: 5px; margin: 0 auto;padding: 15px;">
<el-form ref="openReviseRef" :model="rowOpenRevise" :rules="ruleForm" label-width="120px">
<el-form-item label="platformCode" style="width: 100%;" prop="platformCode">
<CustomSelect v-if="showLoding2" v-model="rowOpenRevise.platformCode" :options="sys_job_status" placeholder="请选择游戏平台" style="width: 100%" />
<CustomSelect v-if="showLoding2" v-model="rowOpenRevise.platformCode" filterable :options="sys_job_status" placeholder="请选择游戏平台" style="width: 100%" />
</el-form-item>
<el-form-item label="currencyCode" style="width: 100%;" prop="currencyCode">
<CustomSelect v-model="rowOpenRevise.currencyCode" :options="currencyCodesOptions" placeholder="请选择币种" style="width: 100%;" />
<CustomSelect v-model="rowOpenRevise.currencyCode" filterable :options="currencyCodesOptions" placeholder="请选择币种" style="width: 100%;" />
</el-form-item>
<el-form-item label="fetchType" style="width: 100%;" prop="fetchType">
<el-input v-model="rowOpenRevise.fetchType" style="width: 100%;" :placeholder="t('请输入fetchType')"> </el-input>

View File

@ -2,8 +2,7 @@
<table-search-card :model="queryParams" @getList="getList" @handleQuery="handleQuery" @resetQuery="resetQuery">
<template #left>
<select-input-form ref="selectInputFormRef" :queryParamsList="queryParamsList" :queryParams="queryParams"
@handleQuery="handleQuery">
<select-input-form ref="selectInputFormRef" :queryParamsList="queryParamsList" :queryParams="queryParams">
</select-input-form>
</template>
<template #right>
@ -432,7 +431,7 @@ function resetQuery() {
/** 删除按钮操作 */
function handleDelete(row) {
const roleIds = row.roleId || ids.value;
proxy.$modal.confirm('是否确认删除角色编号为"' + roleIds + '"的数据项?').then(function () {
proxy.$modal.confirm('是否确认删除角色名称为"' + row.roleName + '"的数据项?').then(function () {
return delRole(roleIds);
}).then(() => {
getList();
@ -653,6 +652,7 @@ const handleDetail = (row) => {
const roleId = row.roleId || ids.value;
const roleMenu = getRoleMenuTreeselect(roleId);
getRole(roleId).then(response => {
countTree.value = row.menuCount;
form.value = response.data;
form.value.roleSort = Number(form.value.roleSort);
open.value = true;
@ -677,8 +677,10 @@ const handleManage = (row) => {
reset();
const roleId = row.roleId || ids.value;
const roleMenu = getRoleMenuTreeselect(roleId);
accountLinking.value = [];
getunallocatedUserList(roleId);
getRole(roleId).then(response => {
countTree.value = row.menuCount;
form.value = response.data;
sysUsersArr.value = response.data.sysUsers;
form.value.roleSort = Number(form.value.roleSort);
@ -721,6 +723,7 @@ function handleUpdate(row) {
const roleId = row.roleId || ids.value;
const roleMenu = getRoleMenuTreeselect(roleId);
getRole(roleId).then(response => {
countTree.value = row.menuCount;
form.value = response.data;
form.value.roleSort = Number(form.value.roleSort);
open.value = true;

View File

@ -46,24 +46,23 @@
end-placeholder="结束日期"
></el-date-picker>
</el-form-item>
<select-input-form ref="selectInputFormRef" :queryParamsList="queryParamsList" :queryParams="queryParams"
@handleQuery="handleQuery">
<select-input-form ref="selectInputFormRef" v-if="showLodings" :queryParamsList="queryParamsList" :queryParams="queryParams">
</select-input-form>
<el-form-item label-width="0px" prop="status">
<el-select
v-model="queryParams.status"
placeholder="账户状态"
clearable
style="width: 240px"
>
<el-option
v-for="dict in statusOptions"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
</el-select>
</el-form-item>
<el-select
v-model="queryParams.status"
placeholder="账户状态"
clearable
style="width: 240px"
>
<el-option
v-for="dict in statusOptions"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
</el-select>
</el-form-item>
<!-- <el-form-item label-width="0px" prop="status">
<el-select
v-model="queryParams.status"
@ -136,9 +135,9 @@
<template #default="scope">
<el-button link type="primary" @click="handleDetails(scope.row)" v-hasPermi="['system:user:edit']"></el-button>
<el-button link type="primary" @click="handleUpdate(scope.row)" v-hasPermi="['system:user:edit']"></el-button>
<el-button link type="primary" v-if="scope.row.status != 1" @click="handleFreeze(scope.row)" v-hasPermi="['system:user:edit']"></el-button>
<el-button link type="primary" :disabled="userName == scope.row.userName" v-if="scope.row.status != 1" @click="handleFreeze(scope.row)" v-hasPermi="['system:user:edit']"></el-button>
<el-button link type="primary" v-if="scope.row.status == 1" @click="handleUnfreeze(scope.row)" v-hasPermi="['system:user:edit']"></el-button>
<el-button link type="primary" @click="handleDelete(scope.row)" v-hasPermi="['system:user:remove']"></el-button>
<el-button link type="primary" :disabled="userName == scope.row.userName" @click="handleDelete(scope.row)" v-hasPermi="['system:user:remove']"></el-button>
</template>
</el-table-column>
</el-table>
@ -292,10 +291,12 @@ import SelectInputForm from '@/components/SelectInputForm';
import { h } from "vue";
import { ElMessageBox } from "element-plus";
import MyCustomForm from "./components/MyCustomForm.vue";
import { getLocalStorage } from "@/utils/auth";
const router = useRouter();
const { proxy } = getCurrentInstance();
const userName = getLocalStorage('userInfo')?.userName;
const { sys_normal_disable, sys_user_sex } = proxy.useDict("sys_normal_disable", "sys_user_sex");
const statusOptions = ref([
{
@ -653,13 +654,17 @@ function handleQuery() {
queryParams.value.pageNum = 1;
getList();
};
const showLodings = ref(true);
/** 重置按钮操作 */
function resetQuery() {
dateRange.value = [];
proxy.resetForm("queryRef");
queryParams.value.deptId = undefined;
proxy.$refs.deptTreeRef.setCurrentKey(null);
// proxy.$refs.deptTreeRef.setCurrentKey(null);
showLodings.value = false;
nextTick(() => {
showLodings.value = true;
})
handleQuery();
};
//
@ -676,9 +681,9 @@ const handleGoogle = () => {
};
/** 删除按钮操作 */
function handleDelete(row) {
const userIds = row.userId || ids.value;
const userName = row.userName || ids.value;
modifyDate.value = row;
proxy.$modal.confirm('是否确认删除用户编号为"' + userIds + '"的数据项?').then(() => {
proxy.$modal.confirm('是否确认删除用户账户为"' + userName + '"的数据项?').then(() => {
modifyType.value = 'handleDelete';
dialogVisible.value = true;
}).catch(() => {});
@ -856,6 +861,7 @@ function handleUpdate(row) {
roleOptions.value = response.roles;
form.value.postIds = response.postIds;
form.value.roleIds = response.roleIds;
form.value.deptId = response.data.dept.deptName == null ? '无' :response.data.deptId;
open.value = true;
modifyStatus.value = 'edit';
title.value = "修改账户";

View File

@ -24,25 +24,25 @@ export default defineConfig(({ mode, command }) => {
port: 80,
host: true,
open: true,
// proxy: {
// '/dev-api': {
// target: 'http://192.168.50.234:9080',
// // target: 'http://192.168.50.11:9080',
// // target: 'http://192.168.50.178:8080',
// // target: 'http://192.168.50.99:8080',
// changeOrigin: true,
// rewrite: (p) => p.replace(/^\/dev-api/, '')
// }
// },
proxy: {
'/ff-api': {
target: 'https://apiadmin.tt-gaming.com', // 线上接口地址
changeOrigin: true, // 是否允许跨域
pathRewrite: {
'^/ff-api': '' // 如果你需要去掉前缀,例如将 /api/xxx 替换为 /xxx
}
'/dev-api': {
target: 'http://192.168.50.234:9080',
// target: 'http://192.168.50.11:9080',
// target: 'http://192.168.50.178:8080',
// target: 'http://192.168.50.99:8080',
changeOrigin: true,
rewrite: (p) => p.replace(/^\/dev-api/, '')
}
}
},
// proxy: {
// '/ff-api': {
// target: 'https://apiadmin.tt-gaming.com', // 线上接口地址
// changeOrigin: true, // 是否允许跨域
// pathRewrite: {
// '^/ff-api': '' // 如果你需要去掉前缀,例如将 /api/xxx 替换为 /xxx
// }
// }
// }
},
css: {
postcss: {