独联体 - 新增CIS房主钻石奖励 / CIS公会成员钻石奖励 / CIS公会钻石奖励

This commit is contained in:
2025-09-23 15:03:42 +08:00
parent aff85e8e41
commit fa556a357c
4 changed files with 682 additions and 0 deletions

View File

@@ -271,4 +271,64 @@ export const exportRoomHourDiamondList = query => {
params: query,
responseType: 'blob'
});
};
// CIS公会钻石 - 列表
export const getSovietList = query => {
return request({
url: '/admin/soviet/list',
method: 'get',
params: query
});
};
// CIS公会钻石 - 导出
export const exportSovietList = query => {
return request({
url: '/admin/soviet/export',
method: 'post',
params: query,
responseType: 'blob'
});
};
// CIS公会成员钻石 - 列表
export const getSovietMemberList = query => {
return request({
url: '/admin/soviet/memberList',
method: 'get',
params: query
});
};
// CIS公会成员钻石 - 导出
export const exportSovietMemberList = query => {
return request({
url: '/admin/soviet/memberExport',
method: 'post',
params: query,
responseType: 'blob'
});
};
// CIS房主钻石 - 列表
export const getSovietRoomList = query => {
return request({
url: '/admin/soviet/roomList',
method: 'get',
params: query
});
};
// CIS房主钻石 - 导出
export const exportSovietRoomList = query => {
return request({
url: '/admin/soviet/roomExport',
method: 'post',
params: query,
responseType: 'blob'
});
};
// CIS房主钻石 - CIS房主钻石-周期
export const getRoomCycleDateList = query => {
return request({
url: '/admin/soviet/roomCycleDateList',
method: 'get',
params: query
});
};

View File

@@ -0,0 +1,208 @@
<template>
<div class="box">
<div class="inquire">
<span>公会ID:</span>
<el-input v-model="formData.guildId" placeholder="" class="input" />
</div>
<div class="inquire">
<span>公会长ID:</span>
<el-input v-model="formData.erbanNo" placeholder="" class="input" />
</div>
<div class="inquire">
<span>国家</span>
<el-select v-model="formData.regionId" placeholder="请选择">
<el-option
v-for="item in adminCountryArr"
:key="item.id"
:label="item.name"
:value="item.id"
>
</el-option>
</el-select>
</div>
<div class="inquire">
<div class="block">
<span class="demonstration">日期</span>
<el-date-picker
v-model="dataTime"
type="daterange"
range-separator=""
start-placeholder="开始日期"
end-placeholder="结束日期"
>
</el-date-picker>
</div>
</div>
<el-button style="" type="primary" @click="getData()">查询</el-button>
<el-button style="" type="primary" @click="confirmExportExcel()"
>导出</el-button
>
<!-- 表格数据 -->
<el-table
v-loading="tableData.loading"
:data="tableData.data"
ref="multipleTable"
@selection-change="handleSelectionChange"
border
style="width: 100%; margin-top: 25px"
>
<el-table-column prop="statDate" align="center" label="日期" />
<el-table-column prop="guildId" align="center" label="公会ID" />
<el-table-column prop="erbanNo" align="center" label="公会长ID" />
<el-table-column prop="nick" align="center" label="公会长昵称" />
<el-table-column prop="guildRegionName" align="center" label="公会国家" />
<el-table-column prop="diamondNum" align="center" label="公会长基础收益" />
<el-table-column prop="extraDiamondNum" align="center" label="公会长额外收益" />
</el-table>
<!-- 分页 -->
<el-pagination
style="margin-top: 10px"
class="paginationClass"
:current-page="formData.pageNo"
:page-size="formData.pageSize"
:page-sizes="[10, 20, 50, 100, 200]"
layout="sizes, prev, pager, next"
:total="tableData.total"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
/>
</div>
</template>
<script>
export default {
name: "cisGuildDiamondReward",
};
</script>
<script setup>
import { ref, onMounted, reactive, computed } from "vue";
import { ElMessage, ElMessageBox } from "element-plus";
import { formatDate } from "@/utils/relDate";
import { dateFormat } from "@/utils/system-helper";
import { getSovietList, exportSovietList} from "@/api/relAgency/relAgency.js";
import { getlistByPartitionId } from "@/api/BD/IdentitySettings.js";
const formData = reactive({
pageNo: 1,
pageSize: 10,
guildId: "",
erbanNo: "",
regionId: 0,
startDate:'',
endDate:'',
});
const tableData = reactive({
data: [],
total: 0,
loading: false,
});
const dataTime = ref([]);
const adminCountryArr = ref([]);
// 查询
const getData = () => {
tableData.loading = true;
if (dataTime.value && dataTime.value.length > 0) {
formData.startDate = dateFormat(dataTime.value[0], "yyyy-MM-dd");
formData.endDate = dateFormat(dataTime.value[1], "yyyy-MM-dd");
} else {
formData.startDate = dataTime.value;
formData.endDate = dataTime.value;
}
getSovietList(formData).then((res) => {
if (res.code == 200) {
tableData.data = res.data.rows;
tableData.loading = false;
tableData.total = res.data.total;
} else {
tableData.loading = false;
ElMessage.error(res.message);
}
});
};
// 导出
const confirmExportExcel = async () => {
try {
const res = await exportSovietList(formData)
if (res) {
ElMessage({
message: '导出成功',
type: 'success',
});
let time = formatDate(new Date());
let alink = document.createElement("a");
alink.download = `CIS公会钻石奖励${time}.xls`;
alink.style.display = "none";
const blob = new Blob([res]);
alink.href = URL.createObjectURL(blob);
document.body.appendChild(alink);
alink.click();
URL.revokeObjectURL(alink.href);
}
} catch (error) {
ElMessage({
message: error.message,
type: 'error',
});
}
}
const handleSizeChange = (val) => {
formData.pageSize = val;
getData();
};
const handleCurrentChange = (val) => {
formData.pageNo = val;
getData();
};
onMounted(() => {
getlistByPartitionId({ partitionId: 32, containAll: true }).then((res) => {
if (res.code == 200) {
adminCountryArr.value = res.data;
}
});
});
</script>
<style lang="less" scoped>
.box {
padding-top: 20px;
background: #ecf0f5;
.inquire {
display: inline-block;
margin-right: 20px;
span {
margin-right: 10px;
}
.input {
width: 180px;
margin-right: 10px;
}
}
.dialogTableVisibleBut {
display: block;
margin: 30px 0 0 830px;
}
.paginationClass {
margin: 15px 0 5px 0px;
}
}
.selectBox {
display: flex;
height: 35px;
line-height: 35px;
margin-bottom: 20px;
}
.selectBoxImg {
height: 150px;
}
.avatar {
width: 178px;
height: 178px;
display: block;
}
</style>

View File

@@ -0,0 +1,218 @@
<template>
<div class="box">
<div class="inquire">
<span>用户ID:</span>
<el-input v-model="formData.erbanNo" placeholder="" class="input" />
</div>
<div class="inquire">
<span>国家</span>
<el-select v-model="formData.regionId" placeholder="请选择">
<el-option
v-for="item in adminCountryArr"
:key="item.id"
:label="item.name"
:value="item.id"
>
</el-option>
</el-select>
</div>
<div class="inquire">
<div class="block">
<span class="demonstration">日期</span>
<el-date-picker
v-model="dataTime"
type="daterange"
range-separator=""
start-placeholder="开始日期"
end-placeholder="结束日期"
>
</el-date-picker>
</div>
</div>
<div class="inquire">
<span class="demonstration">状态</span>
<el-select v-model="formData.enable" placeholder="请选择">
<el-option label="全部" :value="-1"></el-option>
<el-option label="无效" :value="0"></el-option>
<el-option label="有效" :value="1"></el-option>
</el-select>
</div>
<el-button style="" type="primary" @click="getData()">查询</el-button>
<el-button style="" type="primary" @click="confirmExportExcel()"
>导出</el-button
>
<!-- 表格数据 -->
<el-table
v-loading="tableData.loading"
:data="tableData.data"
ref="multipleTable"
@selection-change="handleSelectionChange"
border
style="width: 100%; margin-top: 25px"
>
<el-table-column prop="statDate" align="center" label="日期" />
<el-table-column prop="guildId" align="center" label="公会ID" />
<el-table-column prop="erbanNo" align="center" label="用户ID" />
<el-table-column prop="nick" align="center" label="用户昵称" />
<el-table-column prop="enbale" align="center" label="主播状态" >
<template v-slot="scope">
{{scope.row.enbale ==0 ? '无效' : '有效'}}
</template>
</el-table-column>
<el-table-column prop="regionName" align="center" label="用户国家" />
<el-table-column prop="diamondNum" align="center" label="基础收益" />
<el-table-column prop="extraDiamondNum" align="center" label="额外收益" />
<el-table-column prop="guildExtraDiamondNum" align="center" label="公会长额哇收益" />
</el-table>
<!-- 分页 -->
<el-pagination
style="margin-top: 10px"
class="paginationClass"
:current-page="formData.pageNo"
:page-size="formData.pageSize"
:page-sizes="[10, 20, 50, 100, 200]"
layout="sizes, prev, pager, next"
:total="tableData.total"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
/>
</div>
</template>
<script>
export default {
name: "cisGuildMemberDiamond",
};
</script>
<script setup>
import { ref, onMounted, reactive, computed } from "vue";
import { ElMessage, ElMessageBox } from "element-plus";
import { formatDate } from "@/utils/relDate";
import { dateFormat } from "@/utils/system-helper";
import { getSovietMemberList, exportSovietMemberList} from "@/api/relAgency/relAgency.js";
import { getlistByPartitionId } from "@/api/BD/IdentitySettings.js";
const formData = reactive({
pageNo: 1,
pageSize: 10,
erbanNo: "",
regionId: 0,
startDate:'',
endDate:'',
enable:-1
});
const tableData = reactive({
data: [],
total: 0,
loading: false,
});
const dataTime = ref([]);
const adminCountryArr = ref([]);
// 查询
const getData = () => {
tableData.loading = true;
if (dataTime.value && dataTime.value.length > 0) {
formData.startDate = dateFormat(dataTime.value[0], "yyyy-MM-dd");
formData.endDate = dateFormat(dataTime.value[1], "yyyy-MM-dd");
} else {
formData.startDate = dataTime.value;
formData.endDate = dataTime.value;
}
getSovietMemberList(formData).then((res) => {
if (res.code == 200) {
tableData.data = res.data.rows;
tableData.loading = false;
tableData.total = res.data.total;
} else {
tableData.loading = false;
ElMessage.error(res.message);
}
});
};
// 导出
const confirmExportExcel = async () => {
try {
const res = await exportSovietMemberList(formData)
if (res) {
ElMessage({
message: '导出成功',
type: 'success',
});
let time = formatDate(new Date());
let alink = document.createElement("a");
alink.download = `CIS公会成员钻石奖励${time}.xls`;
alink.style.display = "none";
const blob = new Blob([res]);
alink.href = URL.createObjectURL(blob);
document.body.appendChild(alink);
alink.click();
URL.revokeObjectURL(alink.href);
}
} catch (error) {
ElMessage({
message: error.message,
type: 'error',
});
}
}
const handleSizeChange = (val) => {
formData.pageSize = val;
getData();
};
const handleCurrentChange = (val) => {
formData.pageNo = val;
getData();
};
onMounted(() => {
getlistByPartitionId({ partitionId: 32, containAll: true }).then((res) => {
if (res.code == 200) {
adminCountryArr.value = res.data;
}
});
});
</script>
<style lang="less" scoped>
.box {
padding-top: 20px;
background: #ecf0f5;
.inquire {
display: inline-block;
margin-right: 20px;
span {
margin-right: 10px;
}
.input {
width: 180px;
margin-right: 10px;
}
}
.dialogTableVisibleBut {
display: block;
margin: 30px 0 0 830px;
}
.paginationClass {
margin: 15px 0 5px 0px;
}
}
.selectBox {
display: flex;
height: 35px;
line-height: 35px;
margin-bottom: 20px;
}
.selectBoxImg {
height: 150px;
}
.avatar {
width: 178px;
height: 178px;
display: block;
}
</style>

View File

@@ -0,0 +1,196 @@
<template>
<div class="box">
<div class="inquire">
<span>房间ID:</span>
<el-input v-model="formData.erbanNo" placeholder="" class="input" />
</div>
<div class="inquire">
<span>国家</span>
<el-select v-model="formData.regionId" placeholder="请选择">
<el-option
v-for="item in adminCountryArr"
:key="item.id"
:label="item.name"
:value="item.id"
>
</el-option>
</el-select>
</div>
<div class="inquire">
<span>周期</span>
<el-select v-model="formData.cycleDate" placeholder="请选择" clearable>
<el-option
v-for="item in dateCycleArr"
:key="item.cycleDate"
:label="item.intervalFormatter"
:value="item.cycleDate"
>
</el-option>
</el-select>
</div>
<el-button style="" type="primary" @click="getData()">查询</el-button>
<el-button style="" type="primary" @click="confirmExportExcel()"
>导出</el-button
>
<!-- 表格数据 -->
<el-table
v-loading="tableData.loading"
:data="tableData.data"
ref="multipleTable"
@selection-change="handleSelectionChange"
border
style="width: 100%; margin-top: 25px"
>
<el-table-column prop="statDate" align="center" label="日期" />
<el-table-column prop="erbanNo" align="center" label="房间ID" />
<el-table-column prop="nick" align="center" label="房主昵称" />
<el-table-column prop="regionName" align="center" label="国家" />
<el-table-column prop="diamondNum" align="center" label="房间钻石收益" />
<el-table-column prop="extraDiamondNum" align="center" label="房主额外收益" />
</el-table>
<!-- 分页 -->
<el-pagination
style="margin-top: 10px"
class="paginationClass"
:current-page="formData.pageNo"
:page-size="formData.pageSize"
:page-sizes="[10, 20, 50, 100, 200]"
layout="sizes, prev, pager, next"
:total="tableData.total"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
/>
</div>
</template>
<script>
export default {
name: "cisHomeOwnerDiamond",
};
</script>
<script setup>
import { ref, onMounted, reactive, computed } from "vue";
import { ElMessage, ElMessageBox } from "element-plus";
import { formatDate } from "@/utils/relDate";
import { dateFormat } from "@/utils/system-helper";
import { getSovietRoomList, exportSovietRoomList ,getRoomCycleDateList} from "@/api/relAgency/relAgency.js";
import { getlistByPartitionId } from "@/api/BD/IdentitySettings.js";
const formData = reactive({
pageNo: 1,
pageSize: 10,
erbanNo: "",
regionId: 0,
cycleDate:'',
});
const tableData = reactive({
data: [],
total: 0,
loading: false,
});
const dateCycleArr = ref([]);
const adminCountryArr = ref([]);
// 查询
const getData = () => {
tableData.loading = true;
getSovietRoomList(formData).then((res) => {
if (res.code == 200) {
tableData.data = res.data.rows;
tableData.loading = false;
tableData.total = res.data.total;
} else {
tableData.loading = false;
ElMessage.error(res.message);
}
});
};
// 导出
const confirmExportExcel = async () => {
try {
const res = await exportSovietRoomList(formData)
if (res) {
ElMessage({
message: '导出成功',
type: 'success',
});
let time = formatDate(new Date());
let alink = document.createElement("a");
alink.download = `CIS房主钻石奖励${time}.xls`;
alink.style.display = "none";
const blob = new Blob([res]);
alink.href = URL.createObjectURL(blob);
document.body.appendChild(alink);
alink.click();
URL.revokeObjectURL(alink.href);
}
} catch (error) {
ElMessage({
message: error.message,
type: 'error',
});
}
}
const handleSizeChange = (val) => {
formData.pageSize = val;
getData();
};
const handleCurrentChange = (val) => {
formData.pageNo = val;
getData();
};
onMounted(() => {
getlistByPartitionId({ partitionId: 32, containAll: true }).then((res) => {
if (res.code == 200) {
adminCountryArr.value = res.data;
}
});
getRoomCycleDateList().then((res) => {
dateCycleArr.value = res;
});
});
</script>
<style lang="less" scoped>
.box {
padding-top: 20px;
background: #ecf0f5;
.inquire {
display: inline-block;
margin-right: 20px;
span {
margin-right: 10px;
}
.input {
width: 180px;
margin-right: 10px;
}
}
.dialogTableVisibleBut {
display: block;
margin: 30px 0 0 830px;
}
.paginationClass {
margin: 15px 0 5px 0px;
}
}
.selectBox {
display: flex;
height: 35px;
line-height: 35px;
margin-bottom: 20px;
}
.selectBoxImg {
height: 150px;
}
.avatar {
width: 178px;
height: 178px;
display: block;
}
</style>