Compare commits
46 Commits
starRating
...
quit
Author | SHA1 | Date | |
---|---|---|---|
![]() |
96846bcf2d | ||
![]() |
af9c29421c | ||
![]() |
2547caeac8 | ||
![]() |
e8836d1223 | ||
![]() |
3dfff36aaa | ||
![]() |
64af9bc602 | ||
![]() |
1a5f2f676c | ||
![]() |
179f0718e6 | ||
![]() |
f3c1518fdf | ||
![]() |
662637a6e9 | ||
![]() |
af2a393a65 | ||
![]() |
519f07f4cf | ||
![]() |
44db1b535c | ||
![]() |
186504f0fb | ||
![]() |
45c3f1fd92 | ||
![]() |
3bc87809e1 | ||
![]() |
5323ad7241 | ||
![]() |
8fe6b24b0f | ||
![]() |
99d2c67087 | ||
![]() |
e31f755216 | ||
![]() |
a73f806d92 | ||
![]() |
fa1138dc03 | ||
![]() |
6191f1a3f5 | ||
![]() |
50919fd508 | ||
![]() |
8dc17b87ad | ||
![]() |
d420979350 | ||
![]() |
63c7f5ed80 | ||
![]() |
eba1d654d3 | ||
![]() |
09dc6f3645 | ||
![]() |
5338943b9b | ||
![]() |
1b47d48d0a | ||
![]() |
3659f582d5 | ||
![]() |
ed17e47390 | ||
![]() |
84e86deb73 | ||
![]() |
0751f06ec4 | ||
![]() |
4bc596e3d8 | ||
![]() |
1683225a72 | ||
![]() |
c904646f4a | ||
![]() |
98d5f20be7 | ||
![]() |
924971a290 | ||
![]() |
f5b721a6f8 | ||
![]() |
47c819433b | ||
![]() |
3e9a2bfb60 | ||
![]() |
ce2a63c864 | ||
![]() |
0e5857873c | ||
![]() |
26d422ecda |
@@ -34,3 +34,11 @@ export default {
|
||||
computed: {},
|
||||
};
|
||||
</script>
|
||||
<style>
|
||||
.modal-open{
|
||||
overflow-y: scroll;
|
||||
}
|
||||
body{
|
||||
padding-right:0 !important;
|
||||
}
|
||||
</style>
|
||||
|
13
src/api/dailyCoinStatistics/dailyCoinStatistics.js
Normal file
13
src/api/dailyCoinStatistics/dailyCoinStatistics.js
Normal file
@@ -0,0 +1,13 @@
|
||||
import request from '@/utils/request';
|
||||
import qs from 'qs';
|
||||
import { genQueryParam } from '@/utils/maintainer';
|
||||
|
||||
// ==================================每日数据====================================
|
||||
// 列表
|
||||
export const diamondStatList = query => {
|
||||
return request({
|
||||
url: '/admin/diamondStat/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
37
src/api/gameWhitelist/gameWhitelist.js
Normal file
37
src/api/gameWhitelist/gameWhitelist.js
Normal file
@@ -0,0 +1,37 @@
|
||||
import request from '@/utils/request';
|
||||
import qs from 'qs';
|
||||
import { genQueryParam } from '@/utils/maintainer';
|
||||
|
||||
// ==================================灵小游戏====================================
|
||||
// 游戏列表
|
||||
export const gameList = query => {
|
||||
return request({
|
||||
url: '/admin/game/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
// 列表
|
||||
export const gameFeeRateList = query => {
|
||||
return request({
|
||||
url: '/admin/game/feeRateList',
|
||||
method: 'post',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
// 保存
|
||||
export const gameFeeRate = query => {
|
||||
return request({
|
||||
url: '/admin/game/feeRate',
|
||||
method: 'post',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
// 设置失效
|
||||
export const feeRateInvalid = query => {
|
||||
return request({
|
||||
url: '/admin/game/feeRate/invalid',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
@@ -279,3 +279,22 @@ export const guildApplyAudit = query => {
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
// 主播退公会申请 列表
|
||||
export const guildManageQuitList = query => {
|
||||
return request({
|
||||
url: '/admin/guild/manage/quitList',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
// 主播退公会申请审核
|
||||
export const guildManageOptQuit = query => {
|
||||
return request({
|
||||
url: '/admin/guild/manage/optQuit',
|
||||
method: 'post',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
|
@@ -7,3 +7,10 @@ export const getPartitionInfoList = query => {
|
||||
params: query
|
||||
});
|
||||
};
|
||||
export const listAll = query => {
|
||||
return request({
|
||||
url: '/partition/listAll',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
@@ -27,6 +27,28 @@ export const getDateCycleList = query => {
|
||||
params: query
|
||||
});
|
||||
};
|
||||
// 获取 周奖励周期列表
|
||||
export const familyMemberWeekLevelRewardListCycleDate = query => {
|
||||
return request({
|
||||
url: '/admin/familyMemberWeekLevelReward/listCycleDate',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
// 获取 周奖励查询列表
|
||||
export const familyMemberWeekLevelRewardPage = query => {
|
||||
return request({
|
||||
url: '/admin/familyMemberWeekLevelReward/page',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
|
||||
// 导出
|
||||
export const familyMemberWeekLevelRewardExport = query => {
|
||||
window.location.href = `/admin/familyMemberWeekLevelReward/export?${genQueryParam(query)}`;
|
||||
return;
|
||||
};
|
||||
|
||||
// 获取 公会钻石薪资流水统计 列表
|
||||
export const getAgencyDiamondFlow = query => {
|
||||
|
31
src/api/statistics/statistics.js
Normal file
31
src/api/statistics/statistics.js
Normal file
@@ -0,0 +1,31 @@
|
||||
import request from '@/utils/request';
|
||||
import qs from 'qs';
|
||||
import { genQueryParam } from '@/utils/maintainer';
|
||||
|
||||
// ==================================用户新增====================================
|
||||
// 列表
|
||||
export const dnuPage = query => {
|
||||
return request({
|
||||
url: '/admin/stats/dnu/page',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
// ==================================用户活跃====================================
|
||||
// 列表
|
||||
export const dauPage = query => {
|
||||
return request({
|
||||
url: '/admin/stats/dau/page',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
||||
// ==================================工会数据统计====================================
|
||||
// 列表
|
||||
export const guiildPage = query => {
|
||||
return request({
|
||||
url: '/admin/stats/guild/page',
|
||||
method: 'get',
|
||||
params: query
|
||||
});
|
||||
};
|
@@ -51,6 +51,7 @@
|
||||
{{langFormat(scope.row.lang)}}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="reason" align="center" label="原因" />
|
||||
<el-table-column align="center" label="操作" width="300">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
|
@@ -519,11 +519,6 @@ export default {
|
||||
$("#tipModal").modal('show');
|
||||
return;
|
||||
}
|
||||
if (isEmpty(androidUrl) || isEmpty(iosUrl)) {
|
||||
$("#tipMsg").text("图片不能为空");
|
||||
$("#tipModal").modal('show');
|
||||
return;
|
||||
}
|
||||
if ($("#addForm").validationEngine('validate')) {
|
||||
console.log('$("#addForm").serialize()', $("#addForm").serialize())
|
||||
$.ajax({
|
||||
|
300
src/views/dailyCoinStatistics/dailyCoinStatistics.vue
Normal file
300
src/views/dailyCoinStatistics/dailyCoinStatistics.vue
Normal file
@@ -0,0 +1,300 @@
|
||||
<template>
|
||||
<div class="outer">
|
||||
<!-- 查询 -->
|
||||
<div class="inquire">
|
||||
<div class="block">
|
||||
<span class="demonstration">开始时间</span>
|
||||
<el-date-picker
|
||||
v-model="inquire.time[0]"
|
||||
type="datetime"
|
||||
placeholder="开始时间"
|
||||
>
|
||||
</el-date-picker>
|
||||
</div>
|
||||
</div>
|
||||
<div class="inquire">
|
||||
<div class="block">
|
||||
<span class="demonstration">结束时间</span>
|
||||
<el-date-picker
|
||||
v-model="inquire.time[1]"
|
||||
type="datetime"
|
||||
placeholder="结束时间"
|
||||
>
|
||||
</el-date-picker>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 查询按钮 -->
|
||||
<el-button style="" type="primary" @click="getData()">查询</el-button>
|
||||
<!-- <el-button style="" type="primary" @click="exportDate()">导出</el-button> -->
|
||||
</div>
|
||||
|
||||
<!-- 表格 -->
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
:data="tableData"
|
||||
border
|
||||
style="width: 100%; margin-top: 25px"
|
||||
>
|
||||
<el-table-column prop="date" align="center" label="日期" />
|
||||
<el-table-column align="center" label="全平台真实消耗" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '全平台金币明细';
|
||||
edi(scope.row, 0);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.totalDiamond }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="阿拉伯区真实消耗" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '阿拉伯区金币明细';
|
||||
edi(scope.row, 2);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.arDiamond }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="英语区真实消耗" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '英语区金币明细';
|
||||
edi(scope.row, 1);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.enDiamond }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="华语区真实消耗" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '华语区金币明细';
|
||||
edi(scope.row, 4);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.zhDiamond }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="土耳其区真实消耗" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '土耳其区金币明细';
|
||||
edi(scope.row, 8);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.trDiamond }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="totalRemainDiamond"
|
||||
align="center"
|
||||
label="全平台库存"
|
||||
/>
|
||||
<el-table-column
|
||||
prop="arRemainDiamond"
|
||||
align="center"
|
||||
label="阿拉伯区库存"
|
||||
/>
|
||||
<el-table-column prop="enRemainDiamond" align="center" label="英语区库存" />
|
||||
<el-table-column prop="zhRemainDiamond" align="center" label="华语区库存" />
|
||||
<el-table-column
|
||||
prop="trRemainDiamond"
|
||||
align="center"
|
||||
label="土耳其区库存"
|
||||
/>
|
||||
</el-table>
|
||||
|
||||
<!-- 分页 -->
|
||||
<!-- <el-pagination
|
||||
style="margin-top: 10px"
|
||||
class="paginationClass"
|
||||
v-model:current-page="currentPage"
|
||||
v-model:page-size="pageSize"
|
||||
:page-sizes="[10, 20, 30, 40, 50, 100, 200, 300, 400, 500, 999999999]"
|
||||
layout="sizes, prev, pager, next"
|
||||
:total="total"
|
||||
@size-change="handleSizeChange"
|
||||
@current-change="handleCurrentChange"
|
||||
/> -->
|
||||
|
||||
<!-- 详情 -->
|
||||
<el-dialog v-model="detailsDialog" :title="detailsTitle" width="30%" center>
|
||||
<!-- 内表格 -->
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
:data="tableDataIn"
|
||||
border
|
||||
style="width: 100%; margin-top: 25px"
|
||||
>
|
||||
<el-table-column prop="domainDesc" align="center" label="类型" />
|
||||
<el-table-column prop="addDiamond" align="center" label="增加" />
|
||||
<el-table-column prop="subDiamond" align="center" label="消耗" />
|
||||
</el-table>
|
||||
<!-- 操作 -->
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button type="primary" class="primary" @click="detailsDialog = false"
|
||||
>关闭</el-button
|
||||
>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
import { diamondStatList } from "@/api/dailyCoinStatistics/dailyCoinStatistics";
|
||||
import { dateFormat } from "@/utils/system-helper";
|
||||
import { ElMessage } from "element-plus";
|
||||
export default {
|
||||
name: "dailyCoinStatistics",
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
// 查询条件
|
||||
inquire: {
|
||||
time: [],
|
||||
},
|
||||
// 表格
|
||||
tableData: [{ x: "x" }],
|
||||
// 分页
|
||||
total: 10, //总页数
|
||||
currentPage: 1, //页码
|
||||
pageSize: 10, //条数
|
||||
// 内表格
|
||||
detailsDialog: false,
|
||||
detailsTitle: "金币明细",
|
||||
tableDataIn: [],
|
||||
};
|
||||
},
|
||||
created() {
|
||||
// this.getData();
|
||||
},
|
||||
methods: {
|
||||
// 查询
|
||||
getData() {
|
||||
this.loading = true;
|
||||
let time = this.inquire.time;
|
||||
let startTime = null;
|
||||
let endTime = null;
|
||||
if (time.length > 0) {
|
||||
startTime = this.inquire.time[0]
|
||||
? dateFormat(this.inquire.time[0], "yyyy-MM-dd hh:mm:ss")
|
||||
: null;
|
||||
endTime = this.inquire.time[1]
|
||||
? dateFormat(this.inquire.time[1], "yyyy-MM-dd hh:mm:ss")
|
||||
: null;
|
||||
}
|
||||
diamondStatList({
|
||||
startDate: startTime,
|
||||
endDate: endTime,
|
||||
// pageNo: this.currentPage,
|
||||
// pageSize: this.pageSize,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
// this.total = res.data.total;
|
||||
this.tableData = res.data;
|
||||
this.loading = false;
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
// 详情
|
||||
edi(res, type) {
|
||||
var jsonArr =
|
||||
type == 0
|
||||
? res.totalDomainDetail
|
||||
: type == 1
|
||||
? res.enDomainDetail
|
||||
: type == 2
|
||||
? res.arDomainDetail
|
||||
: type == 4
|
||||
? res.zhDomainDetail
|
||||
: type == 8
|
||||
? res.trDomainDetail
|
||||
: `"[""]"`;
|
||||
console.log(jsonArr);
|
||||
|
||||
this.tableDataIn = JSON.parse(jsonArr);
|
||||
this.detailsDialog = true;
|
||||
},
|
||||
// 分页导航
|
||||
handleSizeChange() {
|
||||
this.getData();
|
||||
},
|
||||
handleCurrentChange() {
|
||||
this.getData();
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style lang="less" scoped>
|
||||
.outer {
|
||||
padding-top: 20px;
|
||||
background: #ecf0f5;
|
||||
border-top: 3px solid #d2d6de;
|
||||
.demonstration {
|
||||
margin-right: 20px;
|
||||
}
|
||||
.inquire {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
white-space: nowrap;
|
||||
float: left;
|
||||
margin-right: 20px;
|
||||
}
|
||||
.search {
|
||||
width: 100%;
|
||||
height: 41px;
|
||||
.searchLeft,
|
||||
.searchRight {
|
||||
width: 20%;
|
||||
float: left;
|
||||
span {
|
||||
margin-right: 10px;
|
||||
}
|
||||
.input {
|
||||
width: 75%;
|
||||
}
|
||||
}
|
||||
}
|
||||
.buttonBox {
|
||||
margin-top: 10px;
|
||||
}
|
||||
.authorityBox {
|
||||
.authoritySpan {
|
||||
margin-right: 20px;
|
||||
}
|
||||
.authorityInpput {
|
||||
width: 50%;
|
||||
}
|
||||
}
|
||||
.dialogTableVisibleBut {
|
||||
margin: -25px 0 20px 0px;
|
||||
}
|
||||
}
|
||||
</style>
|
335
src/views/data/guildStatisticsData.vue
Normal file
335
src/views/data/guildStatisticsData.vue
Normal file
@@ -0,0 +1,335 @@
|
||||
<template>
|
||||
<!-- 表格 -->
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
:data="tableData"
|
||||
border
|
||||
style="width: 100%; margin-top: 25px"
|
||||
>
|
||||
<el-table-column prop="date" align="center" label="日期" />
|
||||
<el-table-column
|
||||
prop="totalNewCount"
|
||||
align="center"
|
||||
label="全服公会总新增"
|
||||
/>
|
||||
|
||||
<el-table-column align="center" label="阿拉伯公会总新增" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '阿拉伯公会总新增' + scope.row.date;
|
||||
edi(scope.row.arNewCountDetail, false);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.arNewCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="英语区总新增" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '英语区总新增' + scope.row.date;
|
||||
edi(scope.row.enNewCountDetail, false);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.enNewCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="华语区总新增" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '华语区总新增' + scope.row.date;
|
||||
edi(scope.row.zhNewCountDetail, false);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.zhNewCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="土耳其区总新增" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '土耳其区总新增' + scope.row.date;
|
||||
edi(scope.row.trNewCountDetail, false);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.trNewCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column
|
||||
prop="totalActiveCount"
|
||||
align="center"
|
||||
label="全服公会活跃度"
|
||||
/>
|
||||
|
||||
<el-table-column align="center" label="阿拉伯公会活跃度" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '阿拉伯公会活跃度' + scope.row.date;
|
||||
edi(scope.row.arActiveCountDetail, true);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.arActiveCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="英语区活跃度" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '英语区活跃度' + scope.row.date;
|
||||
edi(scope.row.enActiveCountDetail, true);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.enActiveCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="华语区活跃度" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '华语区活跃度' + scope.row.date;
|
||||
edi(scope.row.zhActiveCountDetail, true);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.zhActiveCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="土耳其区活跃度" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '土耳其区活跃度' + scope.row.date;
|
||||
edi(scope.row.trActiveCountDetail, true);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.trActiveCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
<!-- 分页 -->
|
||||
<!-- <el-pagination
|
||||
style="margin-top: 10px"
|
||||
class="paginationClass"
|
||||
v-model:current-page="currentPage"
|
||||
v-model:page-size="pageSize"
|
||||
:page-sizes="[10, 20, 30, 40, 50, 100, 200, 300, 400, 500, 999999999]"
|
||||
layout="sizes, prev, pager, next"
|
||||
:total="total"
|
||||
@size-change="handleSizeChange"
|
||||
@current-change="handleCurrentChange"
|
||||
/> -->
|
||||
|
||||
<!-- 详情 -->
|
||||
<el-dialog v-model="detailsDialog" :title="detailsTitle" width="50%" center>
|
||||
<!-- 内表格 -->
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
:data="tableDataIn"
|
||||
border
|
||||
style="width: 100%; margin-top: 25px"
|
||||
>
|
||||
<el-table-column prop="date" align="center" label="日期" />
|
||||
<el-table-column prop="endDate" align="center" label="结束时间" />
|
||||
<el-table-column prop="guildId" align="center" label="公会ID" />
|
||||
<el-table-column prop="x" align="center" label="公会长ID" />
|
||||
<el-table-column
|
||||
prop="activeMemberCount"
|
||||
align="center"
|
||||
label="本周收礼主播数"
|
||||
/>
|
||||
<el-table-column
|
||||
prop="guildGoldFlow"
|
||||
align="center"
|
||||
label="本周公会钻石流水"
|
||||
/>
|
||||
<el-table-column
|
||||
prop="guildDiamondFlow"
|
||||
align="center"
|
||||
label="本周公会金币流水"
|
||||
/>
|
||||
<el-table-column
|
||||
prop="lastGuildGoldFlow"
|
||||
align="center"
|
||||
label="上周公会钻石流水"
|
||||
v-if="detailsIsShow"
|
||||
/>
|
||||
<el-table-column
|
||||
prop="guildGoldFlowWow"
|
||||
align="center"
|
||||
label="周环比"
|
||||
v-if="detailsIsShow"
|
||||
>
|
||||
<template v-slot="scope">
|
||||
{{
|
||||
scope.row.lastGuildGoldFlow === 0 ? '--'
|
||||
: formatPercentage(scope.row.guildGoldFlow / scope.row.lastGuildGoldFlow) + '%'
|
||||
}}
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!-- 操作 -->
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button type="primary" class="primary" @click="detailsDialog = false"
|
||||
>关闭</el-button
|
||||
>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
import { guiildPage } from "@/api/statistics/statistics";
|
||||
import { dateFormat } from "@/utils/system-helper";
|
||||
import { ElMessage } from "element-plus";
|
||||
export default {
|
||||
name: "guildStatisticsData",
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
// 查询条件
|
||||
inquire: {
|
||||
time: [],
|
||||
},
|
||||
// 表格
|
||||
tableData: [],
|
||||
// 分页
|
||||
total: 10, //总页数
|
||||
currentPage: 1, //页码
|
||||
pageSize: 10, //条数
|
||||
// 内表格
|
||||
detailsDialog: false,
|
||||
detailsTitle: "金币明细",
|
||||
tableDataIn: [],
|
||||
detailsIsShow: false,
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.getData();
|
||||
},
|
||||
methods: {
|
||||
// 查询
|
||||
getData() {
|
||||
this.loading = true;
|
||||
let time = this.inquire.time;
|
||||
let startTime = null;
|
||||
let endTime = null;
|
||||
if (time.length > 0) {
|
||||
startTime = this.inquire.time[0]
|
||||
? dateFormat(this.inquire.time[0], "yyyy-MM-dd hh:mm:ss")
|
||||
: null;
|
||||
endTime = this.inquire.time[1]
|
||||
? dateFormat(this.inquire.time[1], "yyyy-MM-dd hh:mm:ss")
|
||||
: null;
|
||||
}
|
||||
guiildPage({
|
||||
page: this.currentPage,
|
||||
pageSize: this.pageSize,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.total = res.data.total;
|
||||
this.tableData = res.data.rows;
|
||||
this.loading = false;
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
// 详情
|
||||
edi(res, type) {
|
||||
this.detailsIsShow = type;
|
||||
console.log(JSON.parse(res));
|
||||
|
||||
this.tableDataIn = JSON.parse(res);
|
||||
this.detailsDialog = true;
|
||||
},
|
||||
formatPercentage(value) {
|
||||
return parseFloat((value * 100).toFixed(2));
|
||||
},
|
||||
// 分页导航
|
||||
handleSizeChange() {
|
||||
this.getData();
|
||||
},
|
||||
handleCurrentChange() {
|
||||
this.getData();
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style lang="less" scoped>
|
||||
.outer {
|
||||
padding-top: 20px;
|
||||
background: #ecf0f5;
|
||||
border-top: 3px solid #d2d6de;
|
||||
.demonstration {
|
||||
margin-right: 20px;
|
||||
}
|
||||
.inquire {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
white-space: nowrap;
|
||||
float: left;
|
||||
margin-right: 20px;
|
||||
}
|
||||
.search {
|
||||
width: 100%;
|
||||
height: 41px;
|
||||
.searchLeft,
|
||||
.searchRight {
|
||||
width: 20%;
|
||||
float: left;
|
||||
span {
|
||||
margin-right: 10px;
|
||||
}
|
||||
.input {
|
||||
width: 75%;
|
||||
}
|
||||
}
|
||||
}
|
||||
.buttonBox {
|
||||
margin-top: 10px;
|
||||
}
|
||||
.authorityBox {
|
||||
.authoritySpan {
|
||||
margin-right: 20px;
|
||||
}
|
||||
.authorityInpput {
|
||||
width: 50%;
|
||||
}
|
||||
}
|
||||
.dialogTableVisibleBut {
|
||||
margin: -25px 0 20px 0px;
|
||||
}
|
||||
}
|
||||
</style>
|
236
src/views/data/newOverview.vue
Normal file
236
src/views/data/newOverview.vue
Normal file
@@ -0,0 +1,236 @@
|
||||
<template>
|
||||
<!-- 表格 -->
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
:data="tableData"
|
||||
border
|
||||
style="width: 100%; margin-top: 25px"
|
||||
>
|
||||
<el-table-column prop="date" align="center" label="日期" />
|
||||
<el-table-column prop="accountCount" align="center" label="新总注册" />
|
||||
<el-table-column prop="userCount" align="center" label="新完善资料" />
|
||||
<el-table-column prop="userRatio" align="center" label="完善率" />
|
||||
|
||||
<el-table-column align="center" label="阿拉伯区新注册(完善资料)" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '阿拉伯区注册明细' + scope.row.date;
|
||||
edi(scope.row.arCountDetail, 2);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.arCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="英语区新注册(完善资料)" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '英语区注册明细' + scope.row.date;
|
||||
edi(scope.row.enCountDetail, 1);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.enCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="华语区新注册(完善资料)" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '华语区注册明细' + scope.row.date;
|
||||
edi(scope.row.zhCountDetail, 4);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.zhCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="土耳其区新注册(完善资料)" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '土耳其区注册明细' + scope.row.date;
|
||||
edi(scope.row.trCountDetailt, 8);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.trCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
<!-- 分页 -->
|
||||
<el-pagination
|
||||
style="margin-top: 10px"
|
||||
class="paginationClass"
|
||||
v-model:current-page="currentPage"
|
||||
v-model:page-size="pageSize"
|
||||
:page-sizes="[10, 20, 30, 40, 50, 100, 200, 300, 400, 500, 999999999]"
|
||||
layout="sizes, prev, pager, next"
|
||||
:total="total"
|
||||
@size-change="handleSizeChange"
|
||||
@current-change="handleCurrentChange"
|
||||
/>
|
||||
|
||||
<!-- 详情 -->
|
||||
<el-dialog v-model="detailsDialog" :title="detailsTitle" width="30%" center>
|
||||
<!-- 内表格 -->
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
:data="tableDataIn"
|
||||
border
|
||||
style="width: 100%; margin-top: 25px"
|
||||
>
|
||||
<el-table-column prop="regionDesc" align="center" label="国家" />
|
||||
<el-table-column prop="count" align="center" label="新注册(完善资料)" />
|
||||
<el-table-column prop="ratio" align="center" label="占比">
|
||||
<template v-slot="scope">
|
||||
{{ formatPercentage(scope.row.ratio) }}%
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!-- 操作 -->
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button type="primary" class="primary" @click="detailsDialog = false"
|
||||
>关闭</el-button
|
||||
>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
import { dnuPage } from "@/api/statistics/statistics";
|
||||
import { dateFormat } from "@/utils/system-helper";
|
||||
import { ElMessage } from "element-plus";
|
||||
export default {
|
||||
name: "newOverview",
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
// 查询条件
|
||||
inquire: {
|
||||
time: [],
|
||||
},
|
||||
// 表格
|
||||
tableData: [],
|
||||
// 分页
|
||||
total: 10, //总页数
|
||||
currentPage: 1, //页码
|
||||
pageSize: 10, //条数
|
||||
// 内表格
|
||||
detailsDialog: false,
|
||||
detailsTitle: "金币明细",
|
||||
tableDataIn: [],
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.getData();
|
||||
},
|
||||
methods: {
|
||||
// 查询
|
||||
getData() {
|
||||
this.loading = true;
|
||||
dnuPage({
|
||||
page: this.currentPage,
|
||||
pageSize: this.pageSize,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.total = res.data.total;
|
||||
this.tableData = res.data.rows;
|
||||
this.loading = false;
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
// 详情
|
||||
edi(res, type) {
|
||||
var jsonArr =
|
||||
// type == 0
|
||||
// ? res.totalDiamondDetail
|
||||
// : type == 1
|
||||
// ? res.enDomainDetail
|
||||
// : type == 2
|
||||
// ? res.arDomainDetail
|
||||
// : type == 4
|
||||
// ? res.zhDomainDetail
|
||||
// : type == 8
|
||||
// ? res.trDomainDetail
|
||||
// : `"[""]"`;
|
||||
(this.tableDataIn = JSON.parse(res));
|
||||
this.detailsDialog = true;
|
||||
},
|
||||
formatPercentage(value) {
|
||||
return parseFloat((value * 100).toFixed(2));
|
||||
},
|
||||
// 分页导航
|
||||
handleSizeChange() {
|
||||
this.getData();
|
||||
},
|
||||
handleCurrentChange() {
|
||||
this.getData();
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style lang="less" scoped>
|
||||
.outer {
|
||||
padding-top: 20px;
|
||||
background: #ecf0f5;
|
||||
border-top: 3px solid #d2d6de;
|
||||
.demonstration {
|
||||
margin-right: 20px;
|
||||
}
|
||||
.inquire {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
white-space: nowrap;
|
||||
float: left;
|
||||
margin-right: 20px;
|
||||
}
|
||||
.search {
|
||||
width: 100%;
|
||||
height: 41px;
|
||||
.searchLeft,
|
||||
.searchRight {
|
||||
width: 20%;
|
||||
float: left;
|
||||
span {
|
||||
margin-right: 10px;
|
||||
}
|
||||
.input {
|
||||
width: 75%;
|
||||
}
|
||||
}
|
||||
}
|
||||
.buttonBox {
|
||||
margin-top: 10px;
|
||||
}
|
||||
.authorityBox {
|
||||
.authoritySpan {
|
||||
margin-right: 20px;
|
||||
}
|
||||
.authorityInpput {
|
||||
width: 50%;
|
||||
}
|
||||
}
|
||||
.dialogTableVisibleBut {
|
||||
margin: -25px 0 20px 0px;
|
||||
}
|
||||
}
|
||||
</style>
|
247
src/views/data/overviewActiveStatistics.vue
Normal file
247
src/views/data/overviewActiveStatistics.vue
Normal file
@@ -0,0 +1,247 @@
|
||||
<template>
|
||||
<!-- 表格 -->
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
:data="tableData"
|
||||
border
|
||||
style="width: 100%; margin-top: 25px"
|
||||
>
|
||||
<el-table-column prop="date" align="center" label="日期" />
|
||||
<el-table-column prop="totalCount" align="center" label="当天总活跃度">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '当天总活跃度' + scope.row.date;
|
||||
edi(scope.row.totalCountDetail, 2);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.totalCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column align="center" label="阿拉伯区总活跃度" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '阿拉伯区总活跃度' + scope.row.date;
|
||||
edi(scope.row.arCountDetail, 2);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.arCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="英语区总活跃度" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '英语区总活跃度' + scope.row.date;
|
||||
edi(scope.row.enCountDetail, 1);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.enCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="华语区总活跃度" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '华语区总活跃度' + scope.row.date;
|
||||
edi(scope.row.zhCountDetail, 4);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.zhCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="土耳其区总活跃度" width="">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="
|
||||
detailsTitle = '土耳其区总活跃度' + scope.row.date;
|
||||
edi(scope.row.trCountDetail, 8);
|
||||
"
|
||||
type="text"
|
||||
size="small"
|
||||
>
|
||||
{{ scope.row.trCount }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
<!-- 分页 -->
|
||||
<el-pagination
|
||||
style="margin-top: 10px"
|
||||
class="paginationClass"
|
||||
v-model:current-page="currentPage"
|
||||
v-model:page-size="pageSize"
|
||||
:page-sizes="[10, 20, 30, 40, 50, 100, 200, 300, 400, 500, 999999999]"
|
||||
layout="sizes, prev, pager, next"
|
||||
:total="total"
|
||||
@size-change="handleSizeChange"
|
||||
@current-change="handleCurrentChange"
|
||||
/>
|
||||
|
||||
<!-- 详情 -->
|
||||
<el-dialog v-model="detailsDialog" :title="detailsTitle" width="30%" center>
|
||||
<!-- 内表格 -->
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
:data="tableDataIn"
|
||||
border
|
||||
style="width: 100%; margin-top: 25px"
|
||||
>
|
||||
<el-table-column prop="regionDesc" align="center" label="国家" />
|
||||
<el-table-column prop="count" align="center" label="活跃度" />
|
||||
<el-table-column prop="ratio" align="center" label="占比">
|
||||
<template v-slot="scope">
|
||||
{{ formatPercentage(scope.row.ratio) }}%
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!-- 操作 -->
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button type="primary" class="primary" @click="detailsDialog = false"
|
||||
>关闭</el-button
|
||||
>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
import { dauPage } from "@/api/statistics/statistics";
|
||||
import { dateFormat } from "@/utils/system-helper";
|
||||
import { ElMessage } from "element-plus";
|
||||
export default {
|
||||
name: "overviewActiveStatistics",
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
// 查询条件
|
||||
inquire: {
|
||||
time: [],
|
||||
},
|
||||
// 表格
|
||||
tableData: [],
|
||||
// 分页
|
||||
total: 10, //总页数
|
||||
currentPage: 1, //页码
|
||||
pageSize: 10, //条数
|
||||
// 内表格
|
||||
detailsDialog: false,
|
||||
detailsTitle: "金币明细",
|
||||
tableDataIn: [],
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.getData();
|
||||
},
|
||||
methods: {
|
||||
// 查询
|
||||
getData() {
|
||||
this.loading = true;
|
||||
dauPage({
|
||||
page: this.currentPage,
|
||||
pageSize: this.pageSize,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.total = res.data.total;
|
||||
this.tableData = res.data.rows;
|
||||
this.loading = false;
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
// 详情
|
||||
edi(res, type) {
|
||||
var jsonArr =
|
||||
// type == 0
|
||||
// ? res.totalDiamondDetail
|
||||
// : type == 1
|
||||
// ? res.enDomainDetail
|
||||
// : type == 2
|
||||
// ? res.arDomainDetail
|
||||
// : type == 4
|
||||
// ? res.zhDomainDetail
|
||||
// : type == 8
|
||||
// ? res.trDomainDetail
|
||||
// : `"[""]"`;
|
||||
(this.tableDataIn = JSON.parse(res));
|
||||
this.detailsDialog = true;
|
||||
},
|
||||
formatPercentage(value) {
|
||||
return parseFloat((value * 100).toFixed(2));
|
||||
},
|
||||
// 分页导航
|
||||
handleSizeChange() {
|
||||
this.getData();
|
||||
},
|
||||
handleCurrentChange() {
|
||||
this.getData();
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style lang="less" scoped>
|
||||
.outer {
|
||||
padding-top: 20px;
|
||||
background: #ecf0f5;
|
||||
border-top: 3px solid #d2d6de;
|
||||
.demonstration {
|
||||
margin-right: 20px;
|
||||
}
|
||||
.inquire {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
white-space: nowrap;
|
||||
float: left;
|
||||
margin-right: 20px;
|
||||
}
|
||||
.search {
|
||||
width: 100%;
|
||||
height: 41px;
|
||||
.searchLeft,
|
||||
.searchRight {
|
||||
width: 20%;
|
||||
float: left;
|
||||
span {
|
||||
margin-right: 10px;
|
||||
}
|
||||
.input {
|
||||
width: 75%;
|
||||
}
|
||||
}
|
||||
}
|
||||
.buttonBox {
|
||||
margin-top: 10px;
|
||||
}
|
||||
.authorityBox {
|
||||
.authoritySpan {
|
||||
margin-right: 20px;
|
||||
}
|
||||
.authorityInpput {
|
||||
width: 50%;
|
||||
}
|
||||
}
|
||||
.dialogTableVisibleBut {
|
||||
margin: -25px 0 20px 0px;
|
||||
}
|
||||
}
|
||||
</style>
|
@@ -22,6 +22,9 @@
|
||||
<option value="2">Room ID</option>
|
||||
<option value="1">指定地址</option>
|
||||
<option value="3">跳转H5页面</option>
|
||||
<option value="4">CP活动</option>
|
||||
<option value="5">周星榜活动</option>
|
||||
<option value="6">定制礼物活动</option>
|
||||
</select>
|
||||
</div>
|
||||
<label for="status" class="col-sm-1 control-label">状态:</label>
|
||||
@@ -181,6 +184,9 @@
|
||||
<option value="2">Room ID</option>
|
||||
<option value="1">指定地址</option>
|
||||
<option value="3">跳转H5页面</option>
|
||||
<option value="4">CP活动</option>
|
||||
<option value="5">周星榜活动</option>
|
||||
<option value="6">定制礼物活动</option>
|
||||
</select>
|
||||
<div class="col-sm-6">
|
||||
<input
|
||||
@@ -446,6 +452,9 @@
|
||||
<option value="2">Room ID</option>
|
||||
<option value="1">指定地址</option>
|
||||
<option value="3">跳转H5页面</option>
|
||||
<option value="4">CP活动</option>
|
||||
<option value="5">周星榜活动</option>
|
||||
<option value="6">定制礼物活动</option>
|
||||
</select>
|
||||
<div class="col-sm-6">
|
||||
<input
|
||||
@@ -808,6 +817,12 @@ export default {
|
||||
|
||||
case 3:
|
||||
return "H5页面";
|
||||
case 4:
|
||||
return "CP活动";
|
||||
case 5:
|
||||
return "周星榜活动";
|
||||
case 6:
|
||||
return "定制礼物活动";
|
||||
}
|
||||
},
|
||||
},
|
||||
|
286
src/views/gameWhitelist/gameWhitelist.vue
Normal file
286
src/views/gameWhitelist/gameWhitelist.vue
Normal file
@@ -0,0 +1,286 @@
|
||||
<template>
|
||||
<div class="box">
|
||||
<!-- 查询 -->
|
||||
<div class="inquire">
|
||||
<span>ID</span>
|
||||
<el-input
|
||||
v-model="inquire.userId"
|
||||
placeholder=""
|
||||
class="input"
|
||||
></el-input>
|
||||
</div>
|
||||
<div class="inquire">
|
||||
<span>状态</span>
|
||||
<el-select v-model="inquire.validStatus" placeholder="请选择">
|
||||
<el-option
|
||||
v-for="item in inquire.options"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</div>
|
||||
|
||||
<!-- 新增按钮 -->
|
||||
<el-button class="primary" type="primary" @click="addDialog = true"
|
||||
>新增</el-button
|
||||
>
|
||||
<!-- 查询按钮 -->
|
||||
<el-button class="primary" type="primary" @click="getData()"
|
||||
>查询</el-button
|
||||
>
|
||||
<!-- 表格 -->
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
:data="tableData"
|
||||
border
|
||||
style="width: 100%; margin-top: 25px"
|
||||
>
|
||||
<el-table-column prop="erbanNo" align="center" label="用户ID" />
|
||||
<el-table-column prop="uid" align="center" label="UID" />
|
||||
<el-table-column prop="gameId" align="center" label="游戏ID" />
|
||||
<el-table-column prop="gameName" align="center" label="游戏名称" />
|
||||
<el-table-column prop="feeRate" align="center" label="water" />
|
||||
<el-table-column prop="adminName" align="center" label="操作人" />
|
||||
<el-table-column prop="createTime" align="center" label="添加时间" />
|
||||
<el-table-column align="center" label="操作" width="100">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
v-show="scope.row.validStatus == 1"
|
||||
@click="invalid(scope.row.id)"
|
||||
class="primary"
|
||||
type="primary"
|
||||
size="default"
|
||||
>失效</el-button
|
||||
>
|
||||
<div v-show="scope.row.validStatus == 0">无效</div>
|
||||
<div v-show="scope.row.validStatus == -1">全部</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="invalidTime" align="center" label="失效时间" />
|
||||
</el-table>
|
||||
|
||||
<!-- 分页 -->
|
||||
<el-pagination
|
||||
style="margin-top: 10px"
|
||||
class="paginationClass"
|
||||
v-model:current-page="currentPage"
|
||||
v-model:page-size="pageSize"
|
||||
:page-sizes="[10, 20, 30, 40, 50, 100, 200, 300, 400, 500, 999999999]"
|
||||
layout="sizes, prev, pager, next"
|
||||
:total="total"
|
||||
@size-change="handleSizeChange"
|
||||
@current-change="handleCurrentChange"
|
||||
/>
|
||||
</div>
|
||||
|
||||
<!-- 新增弹窗 -->
|
||||
<el-dialog v-model="addDialog" title="新增" width="30%" center>
|
||||
<el-form label-width="80px">
|
||||
<el-form-item label="用户id">
|
||||
<el-input
|
||||
style="width: 100%;"
|
||||
v-model="adduserID"
|
||||
placeholder="请输入"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="游戏id">
|
||||
<el-select v-model="gameID" placeholder="请选择" style="width: 100%;">
|
||||
<el-option
|
||||
v-for="item in gameIDArr"
|
||||
:key="item.gameId"
|
||||
:label="item.gameName"
|
||||
:value="item.gameId"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="Water">
|
||||
<el-input
|
||||
style="width: 100%;"
|
||||
v-model="water"
|
||||
placeholder="请输入"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
(例如water:0.2%,则填0.2即可,water2%,则填2)
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button @click="addDialog = false">取消</el-button>
|
||||
<el-button type="primary" @click="addClick()"> 保存 </el-button>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
import {
|
||||
gameList,
|
||||
gameFeeRateList,
|
||||
gameFeeRate,
|
||||
feeRateInvalid,
|
||||
} from "@/api/gameWhitelist/gameWhitelist";
|
||||
// @ts-ignore
|
||||
import { dateFormat } from "@/utils/system-helper";
|
||||
// @ts-ignore
|
||||
import { ElMessage } from "element-plus";
|
||||
export default {
|
||||
name: "gameWhitelist",
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
//查询所需条件对象
|
||||
inquire: {
|
||||
userId: "",
|
||||
validStatus: "-1",
|
||||
options: [
|
||||
{
|
||||
label: "无效",
|
||||
value: "0",
|
||||
},
|
||||
{
|
||||
label: "有效",
|
||||
value: "1",
|
||||
},
|
||||
{
|
||||
label: "全部",
|
||||
value: "-1",
|
||||
},
|
||||
],
|
||||
},
|
||||
//新增所需对象
|
||||
resource: {},
|
||||
// 表格
|
||||
tableData: [],
|
||||
// 分页
|
||||
total: 10, //总页数
|
||||
currentPage: 1, //页码
|
||||
pageSize: 10, //条数
|
||||
// 新增
|
||||
addDialog: false,
|
||||
adduserID: "",
|
||||
gameID: "",
|
||||
gameIDArr: [],
|
||||
water: "",
|
||||
};
|
||||
},
|
||||
created() {
|
||||
gameList().then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.gameIDArr = res.data;
|
||||
} else {
|
||||
this.butClick = false;
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
this.getData();
|
||||
},
|
||||
methods: {
|
||||
// 查询接口
|
||||
getData() {
|
||||
this.loading = true;
|
||||
gameFeeRateList({
|
||||
erbanNo: this.inquire.userId,
|
||||
validStatus: this.inquire.validStatus,
|
||||
pageNo: this.currentPage,
|
||||
pageSize: this.pageSize,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.total = res.data.total;
|
||||
this.tableData = res.data.rows;
|
||||
this.loading = false;
|
||||
} else {
|
||||
this.butClick = false;
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
// 确认新增按钮
|
||||
addClick() {
|
||||
gameFeeRate({
|
||||
erbanNo: this.adduserID,
|
||||
gameFeeRate: this.water,
|
||||
gameId: this.gameID,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.getData();
|
||||
this.addDialog = false;
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "新增成功",
|
||||
type: "success",
|
||||
});
|
||||
} else {
|
||||
this.butClick = false;
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
invalid(id) {
|
||||
feeRateInvalid({ id }).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.getData();
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "设置成功",
|
||||
type: "success",
|
||||
});
|
||||
} else {
|
||||
this.butClick = false;
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
// 分页导航
|
||||
handleSizeChange() {
|
||||
this.getData();
|
||||
},
|
||||
handleCurrentChange() {
|
||||
this.getData();
|
||||
},
|
||||
},
|
||||
};
|
||||
</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;
|
||||
}
|
||||
}
|
||||
</style>
|
@@ -532,11 +532,11 @@ export default {
|
||||
},
|
||||
// 弹窗分页导航
|
||||
handleSizeChange1(val) {
|
||||
this.$set(this.pageParams1, "pageSize", val);
|
||||
this.pageParams1.pageSize = val;
|
||||
this.getDetail();
|
||||
},
|
||||
handlePageChange1(val) {
|
||||
this.$set(this.pageParams1, "pageNo", val);
|
||||
this.pageParams1.pageNo = val;
|
||||
this.getDetail();
|
||||
},
|
||||
|
||||
|
950
src/views/guildOperationManagement/guildInfoCustomerService.vue
Normal file
950
src/views/guildOperationManagement/guildInfoCustomerService.vue
Normal file
@@ -0,0 +1,950 @@
|
||||
<template>
|
||||
<div class="box">
|
||||
<!-- 查询 -->
|
||||
<div class="inquire">
|
||||
<span>ID</span>
|
||||
<el-input
|
||||
v-model="inquire.userId"
|
||||
placeholder=""
|
||||
class="input"
|
||||
></el-input>
|
||||
</div>
|
||||
<div class="inquire">
|
||||
<div class="block">
|
||||
<span class="demonstration">分区</span>
|
||||
<el-select
|
||||
v-model="inquire.partitionId"
|
||||
style="width: 75%"
|
||||
placeholder="请选择"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in inquire.partitionArr"
|
||||
:key="item.id"
|
||||
:label="item.desc"
|
||||
:value="item.id"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="inquire">
|
||||
<span>推荐人</span>
|
||||
<el-input
|
||||
v-model="inquire.referrer"
|
||||
placeholder=""
|
||||
class="input"
|
||||
></el-input>
|
||||
</div> -->
|
||||
<!-- 时间选择器 -->
|
||||
<!-- <div class="inquire">
|
||||
<div class="block">
|
||||
<span class="demonstration">日期</span>
|
||||
<el-date-picker
|
||||
v-model="inquire.time"
|
||||
type="datetimerange"
|
||||
range-separator="至"
|
||||
start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"
|
||||
>
|
||||
</el-date-picker>
|
||||
</div>
|
||||
</div> -->
|
||||
<!-- 查询按钮 -->
|
||||
<el-button class="primary" type="primary" @click="getData()"
|
||||
>查询</el-button
|
||||
>
|
||||
<el-button class="primary" type="primary" @click="addDialog = true"
|
||||
>添加</el-button
|
||||
>
|
||||
<el-button class="primary" type="primary" @click="exportInfoFun()"
|
||||
>导出</el-button
|
||||
>
|
||||
|
||||
<!-- 表格 -->
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
:data="tableData"
|
||||
border
|
||||
style="width: 100%; margin-top: 25px"
|
||||
>
|
||||
<el-table-column prop="id" align="center" label="公会ID" />
|
||||
<!-- <el-table-column prop="referrer" align="center" label="推荐人" /> -->
|
||||
<el-table-column prop="ownerErbanNo" align="center" label="会长ID" />
|
||||
<el-table-column prop="ownerNick" align="center" label="会长昵称" />
|
||||
<el-table-column
|
||||
prop="ownerPartitionName"
|
||||
align="center"
|
||||
label="会长分区"
|
||||
/>
|
||||
<el-table-column prop="name" align="center" label="公会昵称" />
|
||||
<el-table-column align="center" prop="giftInfo" label="公会头像">
|
||||
<template v-slot="scope">
|
||||
<el-image
|
||||
style="width: 100px; height: 100px"
|
||||
:src="scope.row.avatar"
|
||||
:zoom-rate="1.1"
|
||||
:preview-src-list="[scope.row.avatar]"
|
||||
fit="scale-down"
|
||||
preview-teleported="true"
|
||||
hide-on-click-modal="true"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" prop="giftInfo" label="公会背景图">
|
||||
<template v-slot="scope">
|
||||
<el-image
|
||||
style="width: 100px; height: 100px"
|
||||
:src="scope.row.backgroundUrl"
|
||||
:zoom-rate="1.1"
|
||||
:preview-src-list="[scope.row.backgroundUrl]"
|
||||
fit="scale-down"
|
||||
preview-teleported="true"
|
||||
hide-on-click-modal="true"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="createTime" align="center" label="创建日期" />
|
||||
<!-- <el-table-column prop="memberNum" align="center" label="成员数量" /> -->
|
||||
<el-table-column align="center" label="成员数量/上限">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="memberDialogFun(scope.row)"
|
||||
type="text"
|
||||
size="default"
|
||||
>{{ scope.row.memberNum }}/{{ scope.row.memberNumLimit }}</el-button
|
||||
>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="adminName" align="center" label="操作人" />
|
||||
<el-table-column
|
||||
prop=""
|
||||
align="center"
|
||||
label="公会联系方式"
|
||||
/>
|
||||
<el-table-column align="center" prop="idCard" label="公会长身份证件">
|
||||
<template v-slot="scope">
|
||||
<el-image
|
||||
style="width: 100px; height: 100px"
|
||||
:src="scope.row.idCard"
|
||||
:zoom-rate="1.1"
|
||||
:preview-src-list="[scope.row.idCard]"
|
||||
fit="scale-down"
|
||||
preview-teleported="true"
|
||||
hide-on-click-modal="true"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="inviteErbanNo" align="center" label="邀请人ID" />
|
||||
<el-table-column prop="inviteCheck" align="center" label="邀请人证明">
|
||||
<template v-slot="scope">
|
||||
<el-image
|
||||
style="width: 100px; height: 100px"
|
||||
:src="scope.row.inviteCheck"
|
||||
:zoom-rate="1.1"
|
||||
:preview-src-list="[scope.row.inviteCheck]"
|
||||
fit="scale-down"
|
||||
preview-teleported="true"
|
||||
hide-on-click-modal="true"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- <el-table-column align="center" label="收款账户" width="300">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="payAccountDialogFun(scope.row)"
|
||||
type="text"
|
||||
size="medium "
|
||||
>
|
||||
payoneer:{{
|
||||
scope.row.payAccount.payoneer
|
||||
? scope.row.payAccount.payoneer
|
||||
: "未添加"
|
||||
}} </el-button
|
||||
><br />
|
||||
<el-button
|
||||
@click="payAccountDialogFun(scope.row)"
|
||||
type="text"
|
||||
size="medium "
|
||||
>
|
||||
USDT-ERC20:{{
|
||||
scope.row.payAccount.usdt ? scope.row.payAccount.usdt : "未添加"
|
||||
}} </el-button
|
||||
><br />
|
||||
<el-button
|
||||
@click="payAccountDialogFun(scope.row)"
|
||||
type="text"
|
||||
size="medium "
|
||||
>
|
||||
PayPal:{{
|
||||
scope.row.payAccount.payPal
|
||||
? scope.row.payAccount.payPal
|
||||
: "未添加"
|
||||
}} </el-button
|
||||
><br />
|
||||
</template>
|
||||
</el-table-column> -->
|
||||
<!-- <el-table-column prop="goldIncome" align="center" label="金币总收入" />
|
||||
<el-table-column prop="diamondRemain" align="center" label="钻石总收入" /> -->
|
||||
|
||||
<el-table-column align="center" label="操作" width="300">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="ediClick(scope)"
|
||||
class="primary"
|
||||
type="primary"
|
||||
size="default"
|
||||
:disabled="!scope.row.enable"
|
||||
>编辑</el-button
|
||||
>
|
||||
<el-button
|
||||
@click="
|
||||
delDialog = true;
|
||||
delDialogData = scope.row;
|
||||
"
|
||||
:class="scope.row.enable ? 'danger' : 'info'"
|
||||
:type="scope.row.enable ? 'danger' : 'info'"
|
||||
size="default"
|
||||
:disabled="!scope.row.enable"
|
||||
>{{ scope.row.enable ? "移除" : "已解散" }}</el-button
|
||||
>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!-- 新增弹窗 -->
|
||||
<el-dialog v-model="addDialog" title="新增" width="28%" center>
|
||||
<div style="margin-bottom: 25px">
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px; width: 100px"
|
||||
class="col-sm-2 control-label"
|
||||
>会长ID</span
|
||||
>
|
||||
<el-input
|
||||
v-model="resource.id"
|
||||
style="width: 75%"
|
||||
class="input"
|
||||
></el-input>
|
||||
</div>
|
||||
<!-- <div style="margin-bottom: 25px">
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px; width: 100px"
|
||||
class="col-sm-2 control-label"
|
||||
>推荐人</span
|
||||
>
|
||||
<el-input
|
||||
v-model="resource.referrer"
|
||||
style="width: 75%"
|
||||
class="input"
|
||||
></el-input>
|
||||
</div> -->
|
||||
<!-- <div style="margin-bottom: 25px">
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px; width: 100px"
|
||||
class="col-sm-2 control-label"
|
||||
>会长昵称</span
|
||||
>
|
||||
<el-input
|
||||
v-model="resource.nick"
|
||||
style="width: 75%"
|
||||
class="input"
|
||||
></el-input>
|
||||
</div> -->
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button @click="addDialog = false">取消</el-button>
|
||||
<el-button type="primary" @click="add()"> 确认 </el-button>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
<!-- 分页 -->
|
||||
<el-pagination
|
||||
style="margin-top: 10px"
|
||||
class="paginationClass"
|
||||
v-model:current-page="currentPage"
|
||||
v-model:page-size="pageSize"
|
||||
:page-sizes="[10, 20, 30, 40, 50, 100, 200, 300, 400, 500, 999999999]"
|
||||
layout="sizes, prev, pager, next"
|
||||
:total="total"
|
||||
@size-change="handleSizeChange"
|
||||
@current-change="handleCurrentChange"
|
||||
/>
|
||||
<!-- 编辑弹窗 -->
|
||||
<el-dialog v-model="editDialog" title="编辑" width="28%" center>
|
||||
<!-- 公会ID -->
|
||||
<div style="margin-bottom: 25px; margin-top: 10px">
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>公会ID</span
|
||||
>
|
||||
<el-input
|
||||
v-model="ediObj.id"
|
||||
style="width: 75%"
|
||||
class="input"
|
||||
disabled
|
||||
></el-input>
|
||||
</div>
|
||||
<!-- 会长ID -->
|
||||
<div style="margin-bottom: 25px; margin-top: 10px">
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>会长ID</span
|
||||
>
|
||||
<el-input
|
||||
v-model="ediObj.leaderId"
|
||||
style="width: 75%"
|
||||
class="input"
|
||||
disabled
|
||||
></el-input>
|
||||
</div>
|
||||
<!-- 会长昵称 -->
|
||||
<div style="margin-bottom: 25px; margin-top: 10px">
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>会长昵称</span
|
||||
>
|
||||
<el-input
|
||||
v-model="ediObj.leaderNick"
|
||||
style="width: 75%"
|
||||
class="input"
|
||||
disabled
|
||||
></el-input>
|
||||
</div>
|
||||
<!-- 公会昵称 -->
|
||||
<div style="margin-bottom: 25px; margin-top: 10px">
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>公会昵称</span
|
||||
>
|
||||
<el-input
|
||||
v-model="ediObj.guildNick"
|
||||
style="width: 75%"
|
||||
class="input"
|
||||
></el-input>
|
||||
</div>
|
||||
<!-- 公会头像 -->
|
||||
<div class="selectBox selectBoxImg">
|
||||
<span class="left" style="margin-right: 20px">公会头像</span>
|
||||
<!-- action="/admin/tencent/cos/upload/file" -->
|
||||
<el-upload
|
||||
class="avatar-uploader"
|
||||
action="/admin/tencent/cos/upload/file"
|
||||
:show-file-list="false"
|
||||
:on-success="handleAvatarSuccess2"
|
||||
:before-upload="beforeAvatarUpload"
|
||||
:on-error="handleAvatarError"
|
||||
>
|
||||
<img v-if="ediObj.imageUrl2" :src="ediObj.imageUrl2" class="avatar" />
|
||||
<el-icon v-else class="avatar-uploader-icon"><Plus /></el-icon>
|
||||
</el-upload>
|
||||
</div>
|
||||
<!-- 公会背景图 -->
|
||||
<div class="selectBox selectBoxImg">
|
||||
<span class="left" style="margin-right: 20px">公会背景图</span>
|
||||
<!-- action="/admin/tencent/cos/upload/file" -->
|
||||
<el-upload
|
||||
class="avatar-uploader"
|
||||
action="/admin/tencent/cos/upload/file"
|
||||
:show-file-list="false"
|
||||
:on-success="handleAvatarSuccess"
|
||||
:before-upload="beforeAvatarUpload"
|
||||
:on-error="handleAvatarError"
|
||||
>
|
||||
<img v-if="ediObj.imageUrl1" :src="ediObj.imageUrl1" class="avatar" />
|
||||
<el-icon v-else class="avatar-uploader-icon">
|
||||
<Plus />
|
||||
</el-icon>
|
||||
</el-upload>
|
||||
</div>
|
||||
<!-- 成员数量上限 -->
|
||||
<div style="margin-bottom: 25px; margin-top: 10px">
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>成员数量上限</span
|
||||
>
|
||||
<el-input
|
||||
v-model="ediObj.guildNumber"
|
||||
style="width: 75%"
|
||||
class="input"
|
||||
></el-input>
|
||||
</div>
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button @click="editDialog = false">取消</el-button>
|
||||
<el-button type="primary" @click="editDialogClick()">
|
||||
确认
|
||||
</el-button>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
<!-- 二次确认删除弹窗 -->
|
||||
<el-dialog v-model="delDialog" title="提示" width="30%" center>
|
||||
<span> 确定要解散该公会吗?</span>
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button @click="delDialog = false">取消</el-button>
|
||||
<el-button type="primary" @click="delClick()"> 确认 </el-button>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
<!-- 编辑收款账户弹窗 -->
|
||||
<el-dialog
|
||||
v-model="payAccountDialog"
|
||||
:title="payAccountTitle"
|
||||
width="28%"
|
||||
center
|
||||
>
|
||||
<!-- Payoneer -->
|
||||
<div style="margin-bottom: 25px; margin-top: 10px">
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>Payoneer</span
|
||||
>
|
||||
<el-input
|
||||
v-model="payAccount.payoneer"
|
||||
style="width: 75%"
|
||||
class="input"
|
||||
></el-input>
|
||||
</div>
|
||||
<!-- USDT-ERC20 -->
|
||||
<div style="margin-bottom: 25px; margin-top: 10px">
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>USDT-ERC20</span
|
||||
>
|
||||
<el-input
|
||||
v-model="payAccount.usdt"
|
||||
style="width: 75%"
|
||||
class="input"
|
||||
></el-input>
|
||||
</div>
|
||||
<!-- PayPal -->
|
||||
<div style="margin-bottom: 25px; margin-top: 10px">
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>PayPal</span
|
||||
>
|
||||
<el-input
|
||||
v-model="payAccount.payPal"
|
||||
style="width: 75%"
|
||||
class="input"
|
||||
></el-input>
|
||||
</div>
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button @click="payAccountDialog = false">取消</el-button>
|
||||
<el-button type="primary" @click="payAccountClick()">
|
||||
保存
|
||||
</el-button>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
<!-- 编辑成员弹窗 -->
|
||||
<el-dialog v-model="memberDialog" :title="memberTitle" width="36%" center>
|
||||
<!-- 新增用户 -->
|
||||
<div class="inquire">
|
||||
<span>平台ID</span>
|
||||
<el-input
|
||||
v-model="member.userID"
|
||||
placeholder="请输入新增平台id"
|
||||
class="input"
|
||||
></el-input>
|
||||
<el-button type="primary" @click="addMemberFun()"> 新增 </el-button>
|
||||
</div>
|
||||
<!-- 内嵌表格 -->
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
:data="member.tableData"
|
||||
border
|
||||
style="width: 100%; margin-top: 25px"
|
||||
>
|
||||
<el-table-column align="center" label="用户平台ID">
|
||||
<template v-slot="scope">
|
||||
{{ scope.row.erbanNo
|
||||
}}{{
|
||||
scope.row.roleType == 1
|
||||
? "(会长)"
|
||||
: scope.row.roleType == 2
|
||||
? "(管理员)"
|
||||
: ""
|
||||
}}
|
||||
{{ scope.row.enable == false ? "(已离开)" : "" }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="nick" align="center" label="用户昵称" />
|
||||
<el-table-column prop="createTime" align="center" label="加入时间" />
|
||||
<el-table-column prop="adminName" align="center" label="操作人" />
|
||||
<el-table-column align="center" label="操作" width="300">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
@click="setMemberFun(scope.row)"
|
||||
:class="scope.row.roleType == 2 ? 'danger' : 'primary'"
|
||||
:type="scope.row.roleType == 2 ? 'danger' : 'primary'"
|
||||
size="default"
|
||||
:disabled="scope.row.roleType == 1 ? true : false"
|
||||
>{{
|
||||
scope.row.roleType == 1
|
||||
? "会长"
|
||||
: scope.row.roleType == 2
|
||||
? "取消管理员"
|
||||
: "设为管理员"
|
||||
}}</el-button
|
||||
>
|
||||
<el-button
|
||||
@click="
|
||||
memberRemoveObj = scope.row;
|
||||
memberRemoveDialog = true;
|
||||
"
|
||||
class="danger"
|
||||
type="danger"
|
||||
size="default"
|
||||
:disabled="scope.row.roleType == 1 ? true : false"
|
||||
>删除</el-button
|
||||
>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button type="primary" @click="memberDialog = false">
|
||||
关闭
|
||||
</el-button>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
<!-- 二次确认删除弹窗 -->
|
||||
<el-dialog v-model="memberRemoveDialog" title="提示" width="30%" center>
|
||||
<span> 确定要删除该成员吗?</span>
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button @click="memberRemoveDialog = false">取消</el-button>
|
||||
<el-button type="primary" @click="delmemberRemoveClick()">
|
||||
确认
|
||||
</el-button>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import {
|
||||
pageFamily,
|
||||
exportInfo,
|
||||
create,
|
||||
update,
|
||||
dismiss,
|
||||
savePayAccount,
|
||||
manageListFamilyMember,
|
||||
addMember,
|
||||
setManager,
|
||||
removeMember,
|
||||
listPartitionInfo,
|
||||
} from "@/api/noblemanNew/noblemanNew";
|
||||
// @ts-ignore
|
||||
import { dateFormat } from "@/utils/system-helper";
|
||||
// @ts-ignore
|
||||
import { ElMessage } from "element-plus";
|
||||
export default {
|
||||
name: "GuildInfoNewCustomerService",
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
delDialog: false,
|
||||
delDialogData: null,
|
||||
//查询所需条件对象
|
||||
inquire: {
|
||||
userId: "",
|
||||
referrer: "",
|
||||
time: "",
|
||||
partitionId: "",
|
||||
partitionArr: [],
|
||||
},
|
||||
//新增所需对象
|
||||
resource: {
|
||||
id: "",
|
||||
nick: "",
|
||||
referrer: "",
|
||||
},
|
||||
// 表格
|
||||
tableData: [],
|
||||
// 新增弹窗
|
||||
addDialog: false,
|
||||
// 分页
|
||||
total: 10, //总页数
|
||||
currentPage: 1, //页码
|
||||
pageSize: 10, //条数
|
||||
// 编辑弹窗
|
||||
editDialog: false,
|
||||
ediObj: {
|
||||
leaderId: "",
|
||||
leaderNick: "",
|
||||
guildNick: "",
|
||||
guildNumber: "",
|
||||
id: "",
|
||||
imageUrl1: "",
|
||||
imageUrl2: "",
|
||||
},
|
||||
// 收款账户弹窗
|
||||
payAccountDialog: false,
|
||||
payAccountTitle: "(会长昵称【ID:0】)的收款账户",
|
||||
payAccountNew: {},
|
||||
payAccount: {
|
||||
payoneer: "",
|
||||
usdt: "",
|
||||
payPal: "",
|
||||
},
|
||||
// 新增成员弹窗
|
||||
memberDialog: false,
|
||||
memberTitle: "【公会名称】成员信息",
|
||||
memberNew: {},
|
||||
member: {
|
||||
userID: "",
|
||||
tableData: [],
|
||||
},
|
||||
// 删除成员弹窗
|
||||
memberRemoveDialog: false,
|
||||
memberRemoveObj: {},
|
||||
};
|
||||
},
|
||||
created() {
|
||||
listPartitionInfo().then((res) => {
|
||||
this.inquire.partitionArr = res.data;
|
||||
this.inquire.partitionId = this.inquire.partitionArr[0].id;
|
||||
this.getData();
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
// 查询接口
|
||||
getData() {
|
||||
this.loading = true;
|
||||
let time = this.inquire.time;
|
||||
let startTime = "";
|
||||
let endTime = "";
|
||||
if (time && time.length > 0) {
|
||||
startTime = dateFormat(this.inquire.time[0], "yyyy-MM-dd hh:mm:ss");
|
||||
endTime = dateFormat(this.inquire.time[1], "yyyy-MM-dd hh:mm:ss");
|
||||
}
|
||||
pageFamily({
|
||||
erbanNo: this.inquire.userId,
|
||||
referrer: this.inquire.referrer,
|
||||
familyName: this.inquire.nick,
|
||||
partitionId: this.inquire.partitionId,
|
||||
// startDate: startTime,
|
||||
// endDate: endTime,
|
||||
pageNum: this.currentPage,
|
||||
pageSize: this.pageSize,
|
||||
}).then((res) => {
|
||||
this.total = res.data.total;
|
||||
this.tableData = res.data.rows;
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
// 打开成员信息弹窗
|
||||
memberDialogFun(val) {
|
||||
var than = this;
|
||||
than.memberTitle = `【${val.name}】成员信息`;
|
||||
than.memberNew = val;
|
||||
manageListFamilyMember({
|
||||
guildId: val.id,
|
||||
}).then((res) => {
|
||||
this.member.tableData = res.data;
|
||||
than.memberDialog = true;
|
||||
});
|
||||
},
|
||||
// 二次确认删除成员
|
||||
delmemberRemoveClick() {
|
||||
removeMember({
|
||||
guildMemberId: this.memberRemoveObj.guildMemberId,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "删除成功",
|
||||
type: "success",
|
||||
});
|
||||
manageListFamilyMember({
|
||||
guildId: this.memberNew.id,
|
||||
}).then((res) => {
|
||||
this.member.tableData = res.data;
|
||||
});
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
this.memberRemoveDialog = false;
|
||||
});
|
||||
},
|
||||
// 设置管理员
|
||||
setMemberFun(val) {
|
||||
setManager({
|
||||
guildMemberId: val.guildMemberId,
|
||||
status: val.roleType == 3 ? true : val.roleType == 2 ? false : null,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "设置成功!",
|
||||
type: "success",
|
||||
});
|
||||
this.member.userID = "";
|
||||
manageListFamilyMember({
|
||||
guildId: this.memberNew.id,
|
||||
}).then((res) => {
|
||||
this.member.tableData = res.data;
|
||||
});
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
// 新增成员
|
||||
addMemberFun() {
|
||||
addMember({
|
||||
erbanNo: this.member.userID,
|
||||
guildId: this.memberNew.id,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "保存成功!",
|
||||
type: "success",
|
||||
});
|
||||
this.member.userID = "";
|
||||
manageListFamilyMember({
|
||||
guildId: this.memberNew.id,
|
||||
}).then((res) => {
|
||||
this.member.tableData = res.data;
|
||||
});
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "保存失败!",
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
// 打开收款账户弹窗
|
||||
payAccountDialogFun(val) {
|
||||
this.payAccountTitle = `(${val.ownerNick}【ID:${val.ownerErbanNo}】)的收款账户`;
|
||||
this.payAccount.payoneer = val.payAccount.payoneer;
|
||||
this.payAccount.usdt = val.payAccount.usdt;
|
||||
this.payAccount.payPal = val.payAccount.payPal;
|
||||
this.payAccountDialog = true;
|
||||
this.payAccountNew = val;
|
||||
},
|
||||
// 保存收款账户
|
||||
payAccountClick() {
|
||||
savePayAccount({
|
||||
id: this.payAccountNew.payAccount.familyId,
|
||||
payPal: this.payAccount.payPal,
|
||||
payoneer: this.payAccount.payoneer,
|
||||
usdt: this.payAccount.usdt,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "保存成功!",
|
||||
type: "success",
|
||||
});
|
||||
this.payAccountDialog = false;
|
||||
this.getData();
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "保存失败!",
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
// 导出
|
||||
exportInfoFun() {
|
||||
let time = this.inquire.time;
|
||||
let startTime = "";
|
||||
let endTime = "";
|
||||
if (time && time.length > 0) {
|
||||
startTime = dateFormat(this.inquire.time[0], "yyyy-MM-dd hh:mm:ss");
|
||||
endTime = dateFormat(this.inquire.time[1], "yyyy-MM-dd hh:mm:ss");
|
||||
}
|
||||
exportInfo({
|
||||
erbanNo: this.inquire.userId,
|
||||
referrer: this.inquire.referrer,
|
||||
familyName: this.inquire.nick,
|
||||
// startDate: startTime,
|
||||
// endDate: endTime,
|
||||
}).then((res) => {});
|
||||
},
|
||||
// 添加
|
||||
add() {
|
||||
this.addDialog = false;
|
||||
create({
|
||||
erbanNo: this.resource.id,
|
||||
referrer: this.resource.referrer,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "添加成功",
|
||||
type: "success",
|
||||
});
|
||||
this.getData();
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
// 编辑按钮
|
||||
ediClick(res) {
|
||||
var obj = res.row;
|
||||
this.ediObj.leaderId = obj.ownerErbanNo;
|
||||
this.ediObj.leaderNick = obj.ownerNick;
|
||||
this.ediObj.guildNick = obj.name;
|
||||
this.ediObj.guildNumber = obj.memberNumLimit;
|
||||
this.ediObj.id = obj.id;
|
||||
this.ediObj.imageUrl1 = obj.backgroundUrl;
|
||||
this.ediObj.imageUrl2 = obj.avatar;
|
||||
this.editDialog = true;
|
||||
},
|
||||
// 二次确认弹窗
|
||||
editDialogClick() {
|
||||
console.log(this.ediObj);
|
||||
update({
|
||||
id: this.ediObj.id,
|
||||
memberNumLimit: this.ediObj.guildNumber,
|
||||
backgroundUrl: this.ediObj.imageUrl1,
|
||||
avatar: this.ediObj.imageUrl2,
|
||||
name: this.ediObj.guildNick,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "success",
|
||||
});
|
||||
this.getData();
|
||||
this.editDialog = false;
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
this.delDialog = false;
|
||||
});
|
||||
},
|
||||
// 解散按钮
|
||||
delClick() {
|
||||
console.log(this.delDialogData.id);
|
||||
var guildId = this.delDialogData.id;
|
||||
dismiss({ guildId }).then((res) => {
|
||||
console.log();
|
||||
if (res.code == 200) {
|
||||
this.getData();
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "解散成功",
|
||||
type: "success",
|
||||
});
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
this.delDialog = false;
|
||||
});
|
||||
},
|
||||
beforeAvatarUpload() {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "上传中~",
|
||||
type: "warning",
|
||||
});
|
||||
},
|
||||
handleAvatarError() {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "上传失败!",
|
||||
type: "error",
|
||||
});
|
||||
},
|
||||
handleAvatarSuccess(res, file) {
|
||||
console.log(file);
|
||||
this.ediObj.imageUrl1 = file.response.data;
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "上传成功!",
|
||||
type: "success",
|
||||
});
|
||||
},
|
||||
handleAvatarSuccess2(res, file) {
|
||||
console.log(file);
|
||||
this.ediObj.imageUrl2 = file.response.data;
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "上传成功!",
|
||||
type: "success",
|
||||
});
|
||||
},
|
||||
// 分页导航
|
||||
handleSizeChange() {
|
||||
this.getData();
|
||||
},
|
||||
handleCurrentChange() {
|
||||
this.getData();
|
||||
},
|
||||
},
|
||||
};
|
||||
</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;
|
||||
}
|
||||
</style>
|
282
src/views/guildOperationManagement/weeklyRewards.vue
Normal file
282
src/views/guildOperationManagement/weeklyRewards.vue
Normal file
@@ -0,0 +1,282 @@
|
||||
<template>
|
||||
<div class="box">
|
||||
<!-- 查询 -->
|
||||
<div class="inquire">
|
||||
<div class="block">
|
||||
<span class="demonstration">分区</span>
|
||||
<el-select
|
||||
v-model="inquire.partitionId"
|
||||
style="width: 75%"
|
||||
placeholder="请选择"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in inquire.partitionArr"
|
||||
:key="item.id"
|
||||
:label="item.desc"
|
||||
:value="item.id"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="inquire">
|
||||
<span>周期</span>
|
||||
<el-select v-model="inquire.gameArrVal" placeholder="请选择">
|
||||
<el-option
|
||||
v-for="item in inquire.gamesArr"
|
||||
:key="item.gameId"
|
||||
:label="item.gameName"
|
||||
:value="item.gameId"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</div>
|
||||
<div class="inquire">
|
||||
<span>ID</span>
|
||||
<el-input
|
||||
v-model="inquire.userId"
|
||||
placeholder=""
|
||||
class="input"
|
||||
></el-input>
|
||||
</div>
|
||||
<!-- 查询按钮 -->
|
||||
<el-button
|
||||
class="primary"
|
||||
type="primary"
|
||||
@click="
|
||||
tableData = [];
|
||||
currentPage = 1;
|
||||
isFinished = false;
|
||||
getData();
|
||||
"
|
||||
>查询</el-button
|
||||
>
|
||||
<el-button
|
||||
class="primary"
|
||||
type="primary"
|
||||
@click="
|
||||
this.inquire.userId = '';
|
||||
this.getData();
|
||||
"
|
||||
>重置搜索</el-button
|
||||
>
|
||||
<el-button class="primary" type="primary" @click="confirmExport2Excel()"
|
||||
>导出</el-button
|
||||
>
|
||||
|
||||
<!-- 表格 -->
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
:data="tableData"
|
||||
ref="multipleTable"
|
||||
@selection-change="handleSelectionChange"
|
||||
border
|
||||
style="width: 100%; margin-top: 25px"
|
||||
>
|
||||
<el-table-column prop="cycleDate" align="center" label="周期" />
|
||||
<el-table-column prop="familyId" align="center" label="公会ID" />
|
||||
<el-table-column prop="familyName" align="center" label="公会昵称" />
|
||||
<el-table-column prop="familyOwnerId" align="center" label="公会长ID" />
|
||||
<el-table-column
|
||||
prop="familyOwnerNick"
|
||||
align="center"
|
||||
label="公会长昵称"
|
||||
/>
|
||||
<el-table-column prop="erbanNo" align="center" label="主播ID" />
|
||||
<el-table-column prop="nick" align="center" label="主播昵称" />
|
||||
<el-table-column prop="level" align="center" label="主播等级" />
|
||||
<el-table-column prop="processNum" align="center" label="钻石流水" />
|
||||
<el-table-column prop="rewardNum" align="center" label="已获得金币" />
|
||||
<el-table-column prop="receivedNum" align="center" label="已领取金币" />
|
||||
</el-table>
|
||||
|
||||
<!-- 分页 -->
|
||||
<el-pagination
|
||||
style="margin-top: 10px"
|
||||
class="paginationClass"
|
||||
v-model:current-page="currentPage"
|
||||
v-model:page-size="pageSize"
|
||||
:page-sizes="[1, 10, 20, 30, 40, 50, 100, 200, 300, 400, 500, 999999999]"
|
||||
layout="sizes, prev, pager, next"
|
||||
:total="total"
|
||||
@size-change="handleSizeChange"
|
||||
@current-change="handleCurrentChange"
|
||||
/>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import {
|
||||
familyMemberWeekLevelRewardPage,
|
||||
familyMemberWeekLevelRewardExport,
|
||||
familyMemberWeekLevelRewardListCycleDate,
|
||||
} from "@/api/relAgency/relAgency";
|
||||
import { listPartitionInfo } from "@/api/noblemanNew/noblemanNew";
|
||||
// @ts-ignore
|
||||
import { dateFormat } from "@/utils/system-helper";
|
||||
// @ts-ignore
|
||||
import { ElMessage, ElTable } from "element-plus";
|
||||
import { ref } from "vue";
|
||||
import { ElMessageBox } from "element-plus"; // 正确引入 ElM
|
||||
export default {
|
||||
name: "weeklyRewards",
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
//查询所需条件对象
|
||||
inquire: {
|
||||
userId: "",
|
||||
gamesArr: [],
|
||||
gameArrVal: 1,
|
||||
partitionId: 1,
|
||||
partitionArr: [
|
||||
{ id: 1, desc: "英语区" },
|
||||
{ id: 2, desc: "阿拉伯" },
|
||||
],
|
||||
},
|
||||
// 表格
|
||||
tableData: [],
|
||||
// 分页
|
||||
total: 0, //总页数
|
||||
currentPage: 1, //页码
|
||||
pageSize: 10, //条数
|
||||
};
|
||||
},
|
||||
created() {
|
||||
// const timestamps = this.getCurrentWeekTimestamps();
|
||||
// var obj = {};
|
||||
// timestamps.forEach((res, i) => {
|
||||
// this.inquire.gamesArr[i] = {
|
||||
// gameName: dateFormat(res, "yyyy-MM-dd"),
|
||||
// gameId: dateFormat(res, "yyyy-MM-dd"),
|
||||
// };
|
||||
// });
|
||||
// this.inquire.gameArrVal = this.inquire.gamesArr[0].gameId;
|
||||
familyMemberWeekLevelRewardListCycleDate().then((res) => {
|
||||
if (res.code == 200) {
|
||||
res.data.forEach((res, i) => {
|
||||
this.inquire.gamesArr[i] = {
|
||||
gameName: `${dateFormat(res.startDate, "yyyy-MM-dd")}~${dateFormat(
|
||||
res.endDate,
|
||||
"yyyy-MM-dd"
|
||||
)}`,
|
||||
gameId: res.dateCycle,
|
||||
};
|
||||
});
|
||||
this.inquire.gameArrVal = this.inquire.gamesArr[0].gameId;
|
||||
this.getData();
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
// listPartitionInfo().then((res) => {
|
||||
// this.inquire.partitionArr = res.data;
|
||||
// this.inquire.partitionId = this.inquire.partitionArr[0].id;
|
||||
// this.getData();
|
||||
// });
|
||||
},
|
||||
methods: {
|
||||
// 查询接口
|
||||
getData() {
|
||||
this.isLoading = true;
|
||||
this.loading = true;
|
||||
familyMemberWeekLevelRewardPage({
|
||||
cycleDate: this.inquire.gameArrVal,
|
||||
erbanNo: this.inquire.userId,
|
||||
pageNo: this.currentPage,
|
||||
pageSize: this.pageSize,
|
||||
partitionId: this.inquire.partitionId,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.total = res.data.total;
|
||||
this.tableData = res.data.rows;
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
this.loading = false;
|
||||
this.isLoading = false;
|
||||
});
|
||||
},
|
||||
getCurrentWeekTimestamps() {
|
||||
const today = new Date();
|
||||
const dayOfWeek = today.getDay(); // 0(周日)到6(周六)
|
||||
// 计算到周一的天数差:周日需-6天,其他天减(当前星期数 - 1)
|
||||
const diffToMonday = dayOfWeek === 0 ? -6 : 1 - dayOfWeek;
|
||||
const monday = new Date(today);
|
||||
monday.setDate(monday.getDate() + diffToMonday);
|
||||
monday.setHours(0, 0, 0, 0); // 设置为周一的0点
|
||||
|
||||
const weekTimestamps = [];
|
||||
for (let i = 0; i < 7; i++) {
|
||||
const date = new Date(monday);
|
||||
date.setDate(monday.getDate() + i);
|
||||
weekTimestamps.push(date.getTime());
|
||||
}
|
||||
return weekTimestamps; // 包含周一到周日每天0点的时间戳数组
|
||||
},
|
||||
// 导出
|
||||
confirmExport2Excel() {
|
||||
familyMemberWeekLevelRewardExport({
|
||||
cycleDate: this.inquire.gameArrVal,
|
||||
erbanNo: this.inquire.userId,
|
||||
partitionId: this.inquire.partitionId,
|
||||
}).then();
|
||||
},
|
||||
// 分页导航
|
||||
handleSizeChange() {
|
||||
this.getData();
|
||||
},
|
||||
handleCurrentChange() {
|
||||
this.getData();
|
||||
},
|
||||
},
|
||||
};
|
||||
</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;
|
||||
}
|
||||
.pagination {
|
||||
margin: 10px auto 10px;
|
||||
position: relative;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
}
|
||||
.pagination_in {
|
||||
text-align: center;
|
||||
}
|
||||
</style>
|
@@ -181,6 +181,7 @@ export default {
|
||||
methods: {
|
||||
// 查询接口
|
||||
getData() {
|
||||
this.butClick = false;
|
||||
console.log(dateFormat(this.inquire.time, "yyyy-MM-dd"));
|
||||
if (!this.inquire.time && this.inquire.userId == '') {
|
||||
ElMessage({
|
||||
|
@@ -1,6 +1,65 @@
|
||||
<template>
|
||||
<div class="box">
|
||||
<div class="condition">
|
||||
<div class="inquire">
|
||||
<span>用户上线列表</span>
|
||||
<!-- @input="handleInput" -->
|
||||
<el-input
|
||||
v-model="inquire.followErbanNoList"
|
||||
placeholder=""
|
||||
class="input"
|
||||
disabled
|
||||
></el-input>
|
||||
<el-button
|
||||
class="primary"
|
||||
type="primary"
|
||||
@click="
|
||||
editDialog = true;
|
||||
butClick = false;
|
||||
type = 11;
|
||||
editDialogTitle = '用户上线列表';
|
||||
value = inquire.followErbanNoList;
|
||||
"
|
||||
>
|
||||
编辑</el-button
|
||||
>
|
||||
</div>
|
||||
<div class="inquire">
|
||||
<span>用户W级列表</span>
|
||||
<!-- @input="handleInput" -->
|
||||
<!-- <el-input
|
||||
v-model="inquire.whiteErbanNoProductionRatioMap"
|
||||
placeholder=""
|
||||
class="input"
|
||||
disabled
|
||||
></el-input> -->
|
||||
<el-button class="primary" type="primary" @click="detailsClick">
|
||||
查看详情</el-button
|
||||
>
|
||||
</div>
|
||||
<div class="inquire">
|
||||
<span>用户B级列表</span>
|
||||
<!-- @input="handleInput" -->
|
||||
<el-input
|
||||
v-model="inquire.blackErbanNoList"
|
||||
placeholder=""
|
||||
class="input"
|
||||
disabled
|
||||
></el-input>
|
||||
<el-button
|
||||
class="primary"
|
||||
type="primary"
|
||||
@click="
|
||||
editDialog = true;
|
||||
butClick = false;
|
||||
type = 13;
|
||||
editDialogTitle = '用户B级列表';
|
||||
value = inquire.blackErbanNoList;
|
||||
"
|
||||
>
|
||||
编辑</el-button
|
||||
>
|
||||
</div>
|
||||
<!-- 分区 -->
|
||||
<div class="inquire">
|
||||
<span>分区</span>
|
||||
@@ -43,77 +102,6 @@
|
||||
>
|
||||
</div>
|
||||
|
||||
<div class="inquire">
|
||||
<span>对比值M</span>
|
||||
<el-input
|
||||
v-model="inquire.supplement.supplementRatio"
|
||||
placeholder=""
|
||||
class="input"
|
||||
disabled
|
||||
></el-input>
|
||||
<el-button
|
||||
class="primary"
|
||||
type="primary"
|
||||
@click="
|
||||
editDialog = true;
|
||||
butClick = false;
|
||||
type = 5;
|
||||
editDialogTitle = '对比值M';
|
||||
value = inquire.supplement.supplementRatio;
|
||||
"
|
||||
>
|
||||
编辑</el-button
|
||||
>
|
||||
</div>
|
||||
|
||||
<div class="inquire">
|
||||
<span>金币对比值A</span>
|
||||
<!-- @input="handleInput" -->
|
||||
<el-input
|
||||
v-model="inquire.supplement.conditionInput"
|
||||
placeholder=""
|
||||
class="input"
|
||||
disabled
|
||||
></el-input>
|
||||
<el-button
|
||||
class="primary"
|
||||
type="primary"
|
||||
@click="
|
||||
editDialog = true;
|
||||
butClick = false;
|
||||
type = 6;
|
||||
editDialogTitle = '金币对比值A';
|
||||
value = inquire.supplement.conditionInput;
|
||||
"
|
||||
>
|
||||
编辑</el-button
|
||||
>
|
||||
</div>
|
||||
|
||||
<div class="inquire">
|
||||
<span>奖励金币倍数</span>
|
||||
<!-- @input="handleInput" -->
|
||||
<el-input
|
||||
v-model="inquire.supplement.supplementMulti"
|
||||
placeholder=""
|
||||
class="input"
|
||||
disabled
|
||||
></el-input>
|
||||
<el-button
|
||||
class="primary"
|
||||
type="primary"
|
||||
@click="
|
||||
editDialog = true;
|
||||
butClick = false;
|
||||
type = 7;
|
||||
editDialogTitle = '奖励金币倍数';
|
||||
value = inquire.supplement.supplementMulti;
|
||||
"
|
||||
>
|
||||
编辑</el-button
|
||||
>
|
||||
</div>
|
||||
|
||||
<div class="inquire">
|
||||
<span>幸运24金币库存</span>
|
||||
<el-input
|
||||
@@ -250,29 +238,7 @@
|
||||
>
|
||||
</div> -->
|
||||
|
||||
<div class="inquire">
|
||||
<span>用户上线列表</span>
|
||||
<!-- @input="handleInput" -->
|
||||
<el-input
|
||||
v-model="inquire.followErbanNoList"
|
||||
placeholder=""
|
||||
class="input"
|
||||
disabled
|
||||
></el-input>
|
||||
<el-button
|
||||
class="primary"
|
||||
type="primary"
|
||||
@click="
|
||||
editDialog = true;
|
||||
butClick = false;
|
||||
type = 11;
|
||||
editDialogTitle = '用户上线列表';
|
||||
value = inquire.followErbanNoList;
|
||||
"
|
||||
>
|
||||
编辑</el-button
|
||||
>
|
||||
</div>
|
||||
|
||||
<div class="inquire">
|
||||
<span>赠送1000倍奖励</span>
|
||||
<el-button
|
||||
@@ -325,6 +291,53 @@
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
<!-- 详情弹窗 -->
|
||||
<el-dialog v-model="detailsDialog" title="用户W级列表" width="36%" center>
|
||||
<el-button class="primary" type="primary" @click="addDetail">
|
||||
新增</el-button
|
||||
>
|
||||
<el-table :data="detailsTable" style="width: 100%">
|
||||
<el-table-column label="用户ID">
|
||||
<template v-slot="scope">
|
||||
<el-input
|
||||
v-model="scope.row.userId"
|
||||
type="number"
|
||||
@blur="handleEdit(scope.$index, scope.row)"
|
||||
></el-input>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="值">
|
||||
<template v-slot="scope">
|
||||
<el-input
|
||||
v-model="scope.row.val"
|
||||
type="number"
|
||||
@blur="handleEdit(scope.$index, scope.row)"
|
||||
></el-input>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
class="danger"
|
||||
type="danger"
|
||||
@click="delDetail(scope.$index, scope.row)"
|
||||
>
|
||||
删除</el-button
|
||||
>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- 其他列 -->
|
||||
</el-table>
|
||||
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button @click="detailsDialog = false">取消</el-button>
|
||||
<el-button type="primary" :disabled="butClick" @click="sevaDetail()">
|
||||
保存
|
||||
</el-button>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
@@ -367,20 +380,19 @@ export default {
|
||||
giftId: "",
|
||||
platformCommission: "",
|
||||
userRevenueRatio: "",
|
||||
supplement: {
|
||||
conditionInput: "",
|
||||
conditionNum: "",
|
||||
supplementMulti: "",
|
||||
supplementNum: "",
|
||||
supplementRatio: "",
|
||||
},
|
||||
warnMulti: "",
|
||||
followErbanNoList: "",
|
||||
whiteErbanNoProductionRatioMap: "",
|
||||
blackErbanNoList: "",
|
||||
},
|
||||
editDialog: false,
|
||||
editDialogTitle: "",
|
||||
detailsDialog: false,
|
||||
value: "",
|
||||
type: null,
|
||||
// 详情
|
||||
detailsTable: [],
|
||||
whiteErbanNoProductionRatioMap: null,
|
||||
};
|
||||
},
|
||||
created() {
|
||||
@@ -394,10 +406,64 @@ export default {
|
||||
this.inquire.goldInventory = res.data.stock;
|
||||
this.inquire.platformCommission = res.data.platformRatio;
|
||||
this.inquire.userRevenueRatio = res.data.receiverRatio;
|
||||
this.inquire.supplement = res.data.supplement;
|
||||
this.inquire.warnMulti = res.data.warnMulti;
|
||||
this.inquire.followErbanNoList = res.data.followErbanNoList.join();
|
||||
// this.inquire.whiteErbanNoProductionRatioMap = res.data.whiteErbanNoProductionRatioMap.join();
|
||||
this.inquire.blackErbanNoList = res.data.blackErbanNoList.join();
|
||||
var newArr = [];
|
||||
var obj = res.data.whiteErbanNoProductionRatioMap;
|
||||
var arr = Object.keys(obj).map((key) => ({
|
||||
userId: key,
|
||||
val: obj[key],
|
||||
}));
|
||||
arr.forEach((res, i) => {
|
||||
newArr[i] = res;
|
||||
});
|
||||
this.detailsTable = newArr;
|
||||
});
|
||||
},
|
||||
// 查看详情按钮
|
||||
detailsClick() {
|
||||
this.getData();
|
||||
this.detailsDialog = true;
|
||||
this.type = 14;
|
||||
// this.value = inquire.whiteErbanNoProductionRatioMap;
|
||||
},
|
||||
// 详情新增按钮
|
||||
addDetail() {
|
||||
this.detailsTable.unshift([]);
|
||||
},
|
||||
// 详情删除按钮
|
||||
delDetail(index, val) {
|
||||
this.detailsTable.splice(index, 1);
|
||||
},
|
||||
// 详情确认保存按钮
|
||||
sevaDetail() {
|
||||
var map = {};
|
||||
var lock = true;
|
||||
this.detailsTable.forEach((res) => {
|
||||
if (res.userId == (undefined || "") || res.val == undefined || "") {
|
||||
lock = false;
|
||||
}
|
||||
map[res.userId] = res.val;
|
||||
});
|
||||
console.log(map);
|
||||
this.whiteErbanNoProductionRatioMap = map;
|
||||
if (lock) {
|
||||
this.editDialogClick();
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "用户ID和值不能为空",
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
},
|
||||
// 详情编辑监听
|
||||
handleEdit(index, row) {
|
||||
// 这里可以添加保存逻辑,例如调用API更新服务器数据等。
|
||||
console.log(index, "保存行数据", row);
|
||||
// 示例:更新本地数据或其他操作...
|
||||
},
|
||||
// 确认保存
|
||||
editDialogClick() {
|
||||
@@ -409,7 +475,7 @@ export default {
|
||||
if (res.code == 200) {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message:'赠送成功',
|
||||
message: "赠送成功",
|
||||
type: "success",
|
||||
});
|
||||
setTimeout(() => {
|
||||
@@ -435,19 +501,15 @@ export default {
|
||||
obj.platformRatio = this.value;
|
||||
} else if (this.type == 4) {
|
||||
obj.receiverRatio = this.value;
|
||||
}else if (this.type == 5) {
|
||||
obj.supplement = this.inquire.supplement;
|
||||
obj.supplement.supplementRatio = this.value;
|
||||
} else if (this.type == 6) {
|
||||
obj.supplement = this.inquire.supplement;
|
||||
obj.supplement.conditionInput = this.value;
|
||||
} else if (this.type == 7) {
|
||||
obj.supplement = this.inquire.supplement;
|
||||
obj.supplement.supplementMulti = this.value;
|
||||
} else if (this.type == 9) {
|
||||
obj.warnMulti = this.value;
|
||||
} else if (this.type == 11) {
|
||||
obj.followErbanNoList = this.value.split(",");
|
||||
} else if (this.type == 14) {
|
||||
obj.whiteErbanNoProductionRatioMap =
|
||||
this.whiteErbanNoProductionRatioMap;
|
||||
} else if (this.type == 13) {
|
||||
obj.blackErbanNoList = this.value.split(",");
|
||||
}
|
||||
updateSet(obj).then((res) => {
|
||||
if (res.code == 200) {
|
||||
@@ -457,6 +519,7 @@ export default {
|
||||
type: "success",
|
||||
});
|
||||
this.editDialog = false;
|
||||
// this.detailsDialog = false;
|
||||
this.getData();
|
||||
} else {
|
||||
ElMessage({
|
||||
|
182
src/views/nobleman/AnchorQuitApply.vue
Normal file
182
src/views/nobleman/AnchorQuitApply.vue
Normal file
@@ -0,0 +1,182 @@
|
||||
<template>
|
||||
<div class="box">
|
||||
<!-- 查询 -->
|
||||
<el-form ref="searchForm" :model="searchForm" :rules="searchRules" label-width="auto" inline="true">
|
||||
<el-form-item label="ID" prop="erbanNo">
|
||||
<el-input v-model="searchForm.erbanNo" placeholder="" class="input"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="状态" prop="status">
|
||||
<el-select v-model="searchForm.status" placeholder="请选择">
|
||||
<el-option label="全部" :value="-1"></el-option>
|
||||
<el-option label="未操作" :value="1"></el-option>
|
||||
<el-option label="已同意" :value="2"></el-option>
|
||||
<el-option label="已拒绝" :value="3"></el-option>
|
||||
<el-option label="已过期" :value="4"></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="时间" prop="time">
|
||||
<el-date-picker v-model="searchForm.time" type="datetimerange" range-separator="至" start-placeholder="开始日期"
|
||||
end-placeholder="结束日期">
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<!-- 查询按钮 -->
|
||||
<el-button class="primary" type="primary" @click="getData()">查询</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
|
||||
<!-- 表格 -->
|
||||
<el-table v-loading="loading" :data="tableData" border style="width: 100%; margin-top: 25px">
|
||||
<el-table-column prop="erbanNo" align="center" label="用户ID" />
|
||||
<el-table-column prop="uid" align="center" label="UID" />
|
||||
<el-table-column prop="guildId" align="center" label="公会ID" />
|
||||
<el-table-column prop="guildName" align="center" label="公会长昵称" />
|
||||
<el-table-column prop="createTime" align="center" label="申请时间" />
|
||||
<el-table-column align="center" label="操作">
|
||||
<template v-slot="scope">
|
||||
<p v-if="scope.row.status == 2" style="color: green;">已同意</p>
|
||||
<p v-if="scope.row.status == 3" style="color: red;">已拒绝</p>
|
||||
<p v-if="scope.row.status == 4" style="color: orange;">已过期</p>
|
||||
<el-button v-if="scope.row.status == 1" @click="optClick(scope.row, 2)" type="primary">同意</el-button><br>
|
||||
<el-button v-if="scope.row.status == 1" @click="optClick(scope.row, 3)" type="warning">拒绝</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="operator" align="center" label="操作人" />
|
||||
<el-table-column prop="updateTime" align="center" label="操作时间" />
|
||||
</el-table>
|
||||
<!-- 分页 -->
|
||||
<el-pagination style="margin-top: 10px" class="paginationClass" v-model:current-page="currentPage"
|
||||
v-model:page-size="pageSize" :page-sizes="[10, 20, 30, 40, 50, 100, 200, 300, 400, 500, 999999999]"
|
||||
layout="sizes, prev, pager, next" :total="total" @size-change="handleSizeChange"
|
||||
@current-change="handleCurrentChange" />
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { guildManageQuitList, guildManageOptQuit } from "@/api/nobleman/nobleman";
|
||||
// @ts-ignore
|
||||
import { dateFormat } from "@/utils/system-helper";
|
||||
// @ts-ignore
|
||||
import { ElMessageBox, ElMessage } from "element-plus"; // 正确引入 ElM
|
||||
export default {
|
||||
name: "AnchorQuitApply",
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
//查询所需条件对象
|
||||
searchForm: {
|
||||
erbanNo: "",
|
||||
status: "",
|
||||
time: "",
|
||||
},
|
||||
// 查询规则
|
||||
searchRules: {
|
||||
// erbanNo: [{ required: true, trigger: 'blur', message: 'ID不能为空' }]
|
||||
},
|
||||
// 表格
|
||||
tableData: [],
|
||||
// 分页
|
||||
total: 10, //总页数
|
||||
currentPage: 1, //页码
|
||||
pageSize: 10, //条数
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.getData();
|
||||
},
|
||||
methods: {
|
||||
// 查询接口
|
||||
getData() {
|
||||
this.loading = true;
|
||||
let time = this.searchForm.time;
|
||||
let startTime = "";
|
||||
let endTime = "";
|
||||
if (time && time.length > 0) {
|
||||
startTime = dateFormat(this.searchForm.time[0], "yyyy-MM-dd hh:mm:ss");
|
||||
endTime = dateFormat(this.searchForm.time[1], "yyyy-MM-dd hh:mm:ss");
|
||||
}
|
||||
guildManageQuitList({
|
||||
erbanNo: this.searchForm.erbanNo,
|
||||
status: this.searchForm.status,
|
||||
startDate: startTime,
|
||||
endDate: endTime,
|
||||
pageNum: this.currentPage,
|
||||
pageSize: this.pageSize,
|
||||
}).then((res) => {
|
||||
this.total = res.data.total;
|
||||
this.tableData = res.data.rows;
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
// 同意/拒绝
|
||||
optClick(row, val) {
|
||||
let params = {
|
||||
id: row.id,
|
||||
status: val,
|
||||
}
|
||||
|
||||
ElMessageBox.confirm(`确认${val == 2 ? '同意' : '拒绝'}吗?`, "提示", {
|
||||
type: "warning",
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
})
|
||||
.then(() => {
|
||||
guildManageOptQuit(params).then((res) => {
|
||||
console.log();
|
||||
if (res.code == 200) {
|
||||
this.getData();
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "操作成功!",
|
||||
type: "success",
|
||||
});
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
})
|
||||
.catch(() => { });
|
||||
|
||||
},
|
||||
// 分页导航
|
||||
handleSizeChange() {
|
||||
this.getData();
|
||||
},
|
||||
handleCurrentChange() {
|
||||
this.getData();
|
||||
},
|
||||
},
|
||||
};
|
||||
</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;
|
||||
}
|
||||
}
|
||||
</style>
|
@@ -3,13 +3,24 @@
|
||||
<!-- 时间选择器 -->
|
||||
<div class="inquire">
|
||||
<div class="block">
|
||||
<span class="demonstration">日期</span>
|
||||
<span class="demonstration">开始时间</span>
|
||||
<el-date-picker
|
||||
v-model="inquire.time"
|
||||
type="daterange"
|
||||
range-separator="至"
|
||||
start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"
|
||||
v-model="inquire.time[0]"
|
||||
type="date"
|
||||
placeholder="开始时间"
|
||||
format="YYYY-MM-DD 00:00:00"
|
||||
>
|
||||
</el-date-picker>
|
||||
</div>
|
||||
</div>
|
||||
<div class="inquire">
|
||||
<div class="block">
|
||||
<span class="demonstration">结束时间</span>
|
||||
<el-date-picker
|
||||
v-model="inquire.time[1]"
|
||||
type="date"
|
||||
placeholder="结束时间"
|
||||
format="YYYY-MM-DD 23:59:59"
|
||||
>
|
||||
</el-date-picker>
|
||||
</div>
|
||||
@@ -193,11 +204,24 @@ export default {
|
||||
getData() {
|
||||
this.loading = true;
|
||||
let time = this.inquire.time;
|
||||
let startTime = "";
|
||||
let endTime = "";
|
||||
if (time && time.length > 0) {
|
||||
startTime = dateFormat(this.inquire.time[0], "yyyy-MM-dd hh:mm:ss");
|
||||
endTime = dateFormat(this.inquire.time[1], "yyyy-MM-dd hh:mm:ss");
|
||||
let startTime = null;
|
||||
let endTime = null;
|
||||
if (time.length > 0) {
|
||||
startTime = this.inquire.time[0]
|
||||
? dateFormat(this.inquire.time[0], "yyyy-MM-dd 00:00:00")
|
||||
: null;
|
||||
endTime = this.inquire.time[1]
|
||||
? dateFormat(this.inquire.time[1], "yyyy-MM-dd 23:59:59")
|
||||
: null;
|
||||
}
|
||||
if (!startTime || !endTime) {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "请输入开始时间和结束时间",
|
||||
type: "error",
|
||||
});
|
||||
this.loading = false;
|
||||
return;
|
||||
}
|
||||
incomePageFamily({
|
||||
erbanNo: this.inquire.id,
|
||||
@@ -208,9 +232,18 @@ export default {
|
||||
pageNum: this.currentPage,
|
||||
pageSize: this.pageSize,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.total = res.data.total;
|
||||
this.tableData = res.data.rows;
|
||||
this.loading = false;
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
// 导出总外列表
|
||||
|
368
src/views/nobleman/newGuildApplicationCustomerService.vue
Normal file
368
src/views/nobleman/newGuildApplicationCustomerService.vue
Normal file
@@ -0,0 +1,368 @@
|
||||
<template>
|
||||
<div class="box">
|
||||
<!-- 查询 -->
|
||||
<div class="inquire">
|
||||
<span>分区</span>
|
||||
<el-select v-model="inquire.partitionId" placeholder="请选择">
|
||||
<el-option
|
||||
v-for="item in inquire.partitionArr"
|
||||
:key="item.id"
|
||||
:label="item.desc"
|
||||
:value="item.id"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</div>
|
||||
<div class="inquire">
|
||||
<span>平台ID</span>
|
||||
<el-input
|
||||
v-model="inquire.userId"
|
||||
placeholder=""
|
||||
class="input"
|
||||
></el-input>
|
||||
</div>
|
||||
<div class="inquire">
|
||||
<span>状态</span>
|
||||
<el-select v-model="inquire.status" placeholder="请选择">
|
||||
<el-option
|
||||
v-for="item in inquire.statusArr"
|
||||
:key="item.id"
|
||||
:label="item.desc"
|
||||
:value="item.id"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</div>
|
||||
<!-- 时间选择器 -->
|
||||
<div class="inquire">
|
||||
<div class="block">
|
||||
<span class="demonstration">日期</span>
|
||||
<el-date-picker
|
||||
v-model="inquire.time"
|
||||
type="datetimerange"
|
||||
range-separator="至"
|
||||
start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"
|
||||
>
|
||||
</el-date-picker>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 查询按钮 -->
|
||||
<el-button class="primary" type="primary" @click="getData()"
|
||||
>查询</el-button
|
||||
>
|
||||
<el-button class="primary" type="primary" @click="addDialog = true"
|
||||
>重置搜索</el-button
|
||||
>
|
||||
|
||||
<!-- 表格 -->
|
||||
<el-table
|
||||
v-loading="loading"
|
||||
:data="tableData"
|
||||
border
|
||||
style="width: 100%; margin-top: 25px"
|
||||
>
|
||||
<el-table-column prop="id" 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 align="center" prop="giftInfo" label="公会长头像">
|
||||
<template v-slot="scope">
|
||||
<el-image
|
||||
style="width: 100px; height: 100px"
|
||||
:src="scope.row.avatar"
|
||||
:zoom-rate="1.1"
|
||||
:preview-src-list="[scope.row.avatar]"
|
||||
fit="scale-down"
|
||||
preview-teleported="true"
|
||||
hide-on-click-modal="true"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="guildName" align="center" label="公会昵称" />
|
||||
<el-table-column align="center" prop="giftInfo" label="公会头像">
|
||||
<template v-slot="scope">
|
||||
<el-image
|
||||
style="width: 100px; height: 100px"
|
||||
:src="scope.row.guildAvatar"
|
||||
:zoom-rate="1.1"
|
||||
:preview-src-list="[scope.row.guildAvatar]"
|
||||
fit="scale-down"
|
||||
preview-teleported="true"
|
||||
hide-on-click-modal="true"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- guildContact -->
|
||||
<el-table-column
|
||||
prop=""
|
||||
align="center"
|
||||
label="公会联系方式"
|
||||
/>
|
||||
<el-table-column align="center" prop="idCard" label="公会长身份证件">
|
||||
<template v-slot="scope">
|
||||
<el-image
|
||||
style="width: 100px; height: 100px"
|
||||
:src="scope.row.idCard"
|
||||
:zoom-rate="1.1"
|
||||
:preview-src-list="[scope.row.idCard]"
|
||||
fit="scale-down"
|
||||
preview-teleported="true"
|
||||
hide-on-click-modal="true"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="inviteErbanNo" align="center" label="邀请人ID" />
|
||||
<el-table-column prop="inviteCheck" align="center" label="邀请人证明">
|
||||
<template v-slot="scope">
|
||||
<el-image
|
||||
style="width: 100px; height: 100px"
|
||||
:src="scope.row.inviteCheck"
|
||||
:zoom-rate="1.1"
|
||||
:preview-src-list="[scope.row.inviteCheck]"
|
||||
fit="scale-down"
|
||||
preview-teleported="true"
|
||||
hide-on-click-modal="true"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="applyTime" align="center" label="申请时间" />
|
||||
<el-table-column prop="auditStatus" align="center" label="状态">
|
||||
<template v-slot="scope">
|
||||
{{
|
||||
scope.row.auditStatus == 0
|
||||
? "未审核"
|
||||
: scope.row.auditStatus == 1
|
||||
? "已通过"
|
||||
: "拒绝"
|
||||
}}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="adminName" align="center" label="操作人" />
|
||||
<el-table-column align="center" label="操作">
|
||||
<template v-slot="scope">
|
||||
<el-button
|
||||
v-show="scope.row.auditStatus == 0"
|
||||
@click="agree(scope.row.id)"
|
||||
type="text"
|
||||
size="default"
|
||||
>同意</el-button
|
||||
>
|
||||
<el-button
|
||||
v-show="scope.row.auditStatus == 0"
|
||||
@click="refuse(scope.row.id)"
|
||||
type="text"
|
||||
size="default"
|
||||
>拒绝</el-button
|
||||
>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!-- 分页 -->
|
||||
<el-pagination
|
||||
style="margin-top: 10px"
|
||||
class="paginationClass"
|
||||
v-model:current-page="currentPage"
|
||||
v-model:page-size="pageSize"
|
||||
:page-sizes="[10, 20, 30, 40, 50, 100, 200, 300, 400, 500, 999999999]"
|
||||
layout="sizes, prev, pager, next"
|
||||
:total="total"
|
||||
@size-change="handleSizeChange"
|
||||
@current-change="handleCurrentChange"
|
||||
/>
|
||||
<!-- 二次确认删除弹窗 -->
|
||||
<el-dialog v-model="delDialog" title="提示" width="30%" center>
|
||||
<span> 确定要解散该公会吗?</span>
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button @click="delDialog = false">取消</el-button>
|
||||
<el-button type="primary" @click="delClick()"> 确认 </el-button>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import {
|
||||
listPartitionInfo,
|
||||
guildApplyList,
|
||||
guildApplyAudit,
|
||||
} from "@/api/nobleman/nobleman";
|
||||
// @ts-ignore
|
||||
import { dateFormat } from "@/utils/system-helper";
|
||||
// @ts-ignore
|
||||
import { ElMessage } from "element-plus";
|
||||
export default {
|
||||
name: "newGuildApplicationCustomerService",
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
//查询所需条件对象
|
||||
inquire: {
|
||||
partitionId: "",
|
||||
partitionArr: [],
|
||||
userId: "",
|
||||
status: -1,
|
||||
statusArr: [
|
||||
{ desc: "未审核", id: 0 },
|
||||
{ desc: "全部", id: -1 },
|
||||
{ desc: "通过", id: 1 },
|
||||
{ desc: "已拒绝", id: 2 },
|
||||
],
|
||||
time: "",
|
||||
},
|
||||
// 表格
|
||||
tableData: [],
|
||||
// 新增弹窗
|
||||
addDialog: false,
|
||||
// 分页
|
||||
total: 10, //总页数
|
||||
currentPage: 1, //页码
|
||||
pageSize: 10, //条数
|
||||
};
|
||||
},
|
||||
created() {
|
||||
listPartitionInfo().then((res) => {
|
||||
console.log(res.data);
|
||||
this.inquire.partitionArr = res.data;
|
||||
this.inquire.partitionId = this.inquire.partitionArr[0].id;
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
// 查询接口
|
||||
getData() {
|
||||
this.loading = true;
|
||||
let time = this.inquire.time;
|
||||
let startTime = "";
|
||||
let endTime = "";
|
||||
if (time && time.length > 0) {
|
||||
startTime = dateFormat(this.inquire.time[0], "yyyy-MM-dd hh:mm:ss");
|
||||
endTime = dateFormat(this.inquire.time[1], "yyyy-MM-dd hh:mm:ss");
|
||||
}
|
||||
guildApplyList({
|
||||
partitionId: this.inquire.partitionId,
|
||||
erbanNo: this.inquire.userId,
|
||||
auditStatus: this.inquire.status,
|
||||
startDate: startTime,
|
||||
endDate: endTime,
|
||||
pageNo: this.currentPage,
|
||||
pageSize: this.pageSize,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.total = res.data.total;
|
||||
this.tableData = res.data.rows;
|
||||
this.loading = false;
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
agree(id) {
|
||||
guildApplyAudit({
|
||||
auditStatus: 1,
|
||||
id,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.getData();
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
refuse(id) {
|
||||
guildApplyAudit({
|
||||
auditStatus: 2,
|
||||
id,
|
||||
}).then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.getData();
|
||||
} else {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: res.message,
|
||||
type: "error",
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
beforeAvatarUpload() {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "上传中~",
|
||||
type: "warning",
|
||||
});
|
||||
},
|
||||
handleAvatarError() {
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "上传失败!",
|
||||
type: "error",
|
||||
});
|
||||
},
|
||||
handleAvatarSuccess2(res, file) {
|
||||
this.ediObj.imageUrl2 = file.response.data;
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "上传成功!",
|
||||
type: "success",
|
||||
});
|
||||
},
|
||||
handleAvatarSuccess(res, file) {
|
||||
this.ediObj.imageUrl1 = file.response.data;
|
||||
ElMessage({
|
||||
showClose: true,
|
||||
message: "上传成功!",
|
||||
type: "success",
|
||||
});
|
||||
},
|
||||
// 分页导航
|
||||
handleSizeChange() {
|
||||
this.getData();
|
||||
},
|
||||
handleCurrentChange() {
|
||||
this.getData();
|
||||
},
|
||||
},
|
||||
};
|
||||
</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;
|
||||
}
|
||||
</style>
|
@@ -75,7 +75,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
<div id="mapObjHtml">
|
||||
<div id="mapObjHtml" style="display:none">
|
||||
<span
|
||||
style="
|
||||
margin-right: 10px;
|
||||
@@ -125,6 +125,33 @@ export default {
|
||||
$(function () {
|
||||
userRegion();
|
||||
$("#table").bootstrapTable("destroy");
|
||||
var picker1 = $("#startTime").datetimepicker({
|
||||
format: "yyyy-mm-dd hh:ii:00",
|
||||
todayBtn: true,
|
||||
autoclose: true,
|
||||
});
|
||||
var picker2 = $("#endTime").datetimepicker({
|
||||
format: "yyyy-mm-dd hh:ii:00",
|
||||
todayBtn: true,
|
||||
autoclose: true,
|
||||
});
|
||||
picker1.on("changeDate", function () {
|
||||
var date = $("#startTime").datetimepicker("getDate");
|
||||
picker2.datetimepicker("setStartDate", date);
|
||||
});
|
||||
picker2.on("changeDate", function () {
|
||||
var date = $("#endTime").datetimepicker("getDate");
|
||||
picker1.datetimepicker("setEndDate", date);
|
||||
});
|
||||
|
||||
//导出功能
|
||||
$("#btnExport").on("click", function () {
|
||||
$("#searchForm").submit();
|
||||
});
|
||||
|
||||
// 查询刷新
|
||||
$("#btnSearch").on("click", function () {
|
||||
|
||||
$("#table").bootstrapTable({
|
||||
columns: [
|
||||
{
|
||||
@@ -239,34 +266,8 @@ export default {
|
||||
console.log("load fail");
|
||||
},
|
||||
});
|
||||
|
||||
var picker1 = $("#startTime").datetimepicker({
|
||||
format: "yyyy-mm-dd hh:ii:00",
|
||||
todayBtn: true,
|
||||
autoclose: true,
|
||||
});
|
||||
var picker2 = $("#endTime").datetimepicker({
|
||||
format: "yyyy-mm-dd hh:ii:00",
|
||||
todayBtn: true,
|
||||
autoclose: true,
|
||||
});
|
||||
picker1.on("changeDate", function () {
|
||||
var date = $("#startTime").datetimepicker("getDate");
|
||||
picker2.datetimepicker("setStartDate", date);
|
||||
});
|
||||
picker2.on("changeDate", function () {
|
||||
var date = $("#endTime").datetimepicker("getDate");
|
||||
picker1.datetimepicker("setEndDate", date);
|
||||
});
|
||||
|
||||
//导出功能
|
||||
$("#btnExport").on("click", function () {
|
||||
$("#searchForm").submit();
|
||||
});
|
||||
|
||||
// 查询刷新
|
||||
$("#btnSearch").on("click", function () {
|
||||
TableHelper.doRefresh("#table");
|
||||
$('#mapObjHtml').show();
|
||||
});
|
||||
|
||||
//用户地区
|
||||
|
@@ -10,12 +10,33 @@
|
||||
<div id="table"></div>
|
||||
<div id="toolbar">
|
||||
<div class="col-sm-12">
|
||||
<label for="searchValue" class="col-sm-3 control-label">Peko ID:</label>
|
||||
<div class="col-sm-3"><input type="text" class="form-control" name="searchValue" id="searchValue">
|
||||
<label for="searchValue" class="col-sm-1 control-label">ID:</label>
|
||||
<div class="col-sm-2">
|
||||
<input
|
||||
type="text"
|
||||
class="form-control"
|
||||
name="searchValue"
|
||||
id="searchValue"
|
||||
/>
|
||||
</div>
|
||||
<label for="searchType" class="col-sm-3 control-label">地区:</label>
|
||||
<div class="col-sm-3">
|
||||
<select name="searchType" id="searchType" data-btn-class="btn-warning" class="form-control">
|
||||
<label for="partitionId" class="col-sm-1 control-label">分区:</label>
|
||||
<div class="col-sm-2">
|
||||
<select
|
||||
name="partitionId"
|
||||
id="partitionId"
|
||||
data-btn-class="btn-warning"
|
||||
class="form-control"
|
||||
>
|
||||
</select>
|
||||
</div>
|
||||
<label for="searchType" class="col-sm-1 control-label">地区:</label>
|
||||
<div class="col-sm-2">
|
||||
<select
|
||||
name="searchType"
|
||||
id="searchType"
|
||||
data-btn-class="btn-warning"
|
||||
class="form-control"
|
||||
>
|
||||
<option value="0" selected="selected">全部</option>
|
||||
</select>
|
||||
</div>
|
||||
@@ -33,12 +54,23 @@
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<div class="modal fade" id="editModal" tabindex="-1" role="dialog" aria-labelledby="modalLabel">
|
||||
<div
|
||||
class="modal fade"
|
||||
id="editModal"
|
||||
tabindex="-1"
|
||||
role="dialog"
|
||||
aria-labelledby="modalLabel"
|
||||
>
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
|
||||
aria-hidden="true">×</span>
|
||||
<button
|
||||
type="button"
|
||||
class="close"
|
||||
data-dismiss="modal"
|
||||
aria-label="Close"
|
||||
>
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
<h4 class="modal-title" id="modalLabel">代充信息</h4>
|
||||
</div>
|
||||
@@ -46,9 +78,26 @@
|
||||
<form class="form-horizontal">
|
||||
<input type="hidden" name="id" id="id" />
|
||||
<div class="form-group">
|
||||
<label for="erbanNo" class="col-sm-3 control-label">Peko ID:</label>
|
||||
<label for="erbanNo" class="col-sm-3 control-label"
|
||||
>Peko ID:</label
|
||||
>
|
||||
<div class="col-sm-9">
|
||||
<input type="text" class="form-control" id="erbanNo">
|
||||
<input type="text" class="form-control" id="erbanNo" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="starLevel" class="col-sm-3 control-label"
|
||||
>信誉值:</label
|
||||
>
|
||||
<div class="col-sm-9">
|
||||
<select name="starLevel" id="starLevel">
|
||||
<option value="">-- 请选择 --</option>
|
||||
<option value="1">1</option>
|
||||
<option value="2">2</option>
|
||||
<option value="3">3</option>
|
||||
<option value="4">4</option>
|
||||
<option value="5">5</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
@@ -57,14 +106,22 @@
|
||||
</form>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">
|
||||
取消
|
||||
</button>
|
||||
<button type="button" class="btn btn-primary" id="save">确认</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="modal fade" id="tipModal" tabindex="-1" role="dialog" aria-labelledby="modalLabel">
|
||||
<div
|
||||
class="modal fade"
|
||||
id="tipModal"
|
||||
tabindex="-1"
|
||||
role="dialog"
|
||||
aria-labelledby="modalLabel"
|
||||
>
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
@@ -77,8 +134,9 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import TableHelper from '@/utils/bootstrap-table-helper';
|
||||
import TableHelper from "@/utils/bootstrap-table-helper";
|
||||
|
||||
var partitionArray;
|
||||
var regionArray;
|
||||
export default {
|
||||
name: "RechargeUserView",
|
||||
@@ -89,7 +147,9 @@ export default {
|
||||
return;
|
||||
}
|
||||
var $input = $(obj);
|
||||
const typeArray = $("input:checkbox[name='type']:checked").serializeArray();
|
||||
const typeArray = $(
|
||||
"input:checkbox[name='type']:checked"
|
||||
).serializeArray();
|
||||
if (!typeArray) {
|
||||
return;
|
||||
}
|
||||
@@ -104,17 +164,17 @@ export default {
|
||||
break;
|
||||
}
|
||||
}
|
||||
var $seq = $('#seq' + type);
|
||||
var $seq = $("#seq" + type);
|
||||
if (isCheck) {
|
||||
$seq.removeAttr('readonly');
|
||||
$seq.removeAttr("readonly");
|
||||
} else {
|
||||
$seq.attr('readonly', 'true');
|
||||
$seq.attr("readonly", "true");
|
||||
}
|
||||
}
|
||||
}
|
||||
window.editSeqText = editSeqText;
|
||||
return {
|
||||
editSeqText
|
||||
editSeqText,
|
||||
};
|
||||
},
|
||||
created() {
|
||||
@@ -125,21 +185,40 @@ export default {
|
||||
methods: {
|
||||
initData() {
|
||||
$(function () {
|
||||
//分区
|
||||
partitionArray = listPartitionInfo();
|
||||
//地区
|
||||
regionArray = chargeRegion();
|
||||
$('#table').bootstrapTable('destroy');
|
||||
$('#table').bootstrapTable({
|
||||
|
||||
$("#table").bootstrapTable("destroy");
|
||||
$("#table").bootstrapTable({
|
||||
columns: [
|
||||
{ field: 'erbanNo', title: 'Peko ID', align: 'center', width: '5%' },
|
||||
{ field: 'nick', title: '昵称', align: 'center', width: '5%' },
|
||||
{ field: 'createTime', title: '首次加入代充时间', align: 'center', width: '5%' },
|
||||
{
|
||||
field: 'type',
|
||||
title: '地区',
|
||||
align: 'center',
|
||||
width: '5%',
|
||||
field: "erbanNo",
|
||||
title: "Peko ID",
|
||||
align: "center",
|
||||
width: "5%",
|
||||
},
|
||||
{ field: "nick", title: "昵称", align: "center", width: "5%" },
|
||||
{
|
||||
field: "starLevel",
|
||||
title: "信誉值",
|
||||
align: "center",
|
||||
width: "5%",
|
||||
},
|
||||
{
|
||||
field: "createTime",
|
||||
title: "首次加入代充时间",
|
||||
align: "center",
|
||||
width: "5%",
|
||||
},
|
||||
{
|
||||
field: "type",
|
||||
title: "地区",
|
||||
align: "center",
|
||||
width: "5%",
|
||||
formatter: function (val, row, index) {
|
||||
var value = '';
|
||||
var value = "";
|
||||
if (regionArray) {
|
||||
for (var i = 0, len = regionArray.length; i < len; i++) {
|
||||
var region = regionArray[i];
|
||||
@@ -148,46 +227,58 @@ export default {
|
||||
if ((val & type) != 0) {
|
||||
value += name;
|
||||
if (i != len - 1) {
|
||||
value += '<br>';
|
||||
value += "<br>";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return value;
|
||||
}
|
||||
},
|
||||
},
|
||||
{
|
||||
field: 'userRegions',
|
||||
title: '排序',
|
||||
align: 'center',
|
||||
width: '5%',
|
||||
field: "userRegions",
|
||||
title: "排序",
|
||||
align: "center",
|
||||
width: "5%",
|
||||
formatter: function (val, row, index) {
|
||||
var value = '';
|
||||
var value = "";
|
||||
if (row.userRegions) {
|
||||
for (var i = 0, len = row.userRegions.length; i < len; i++) {
|
||||
var userRegion = row.userRegions[i];
|
||||
var name = userRegion.name;
|
||||
var seq = userRegion.seq;
|
||||
value += name + ':' + seq;
|
||||
value += name + ":" + seq;
|
||||
if (i != len - 1) {
|
||||
value += '<br>';
|
||||
value += "<br>";
|
||||
}
|
||||
}
|
||||
}
|
||||
return value;
|
||||
}
|
||||
},
|
||||
{ field: 'outDiamondNum', title: '最近30天转出金币', align: 'center', width: '5%' },
|
||||
},
|
||||
{
|
||||
field: 'id',
|
||||
title: '操作',
|
||||
align: 'center',
|
||||
width: '5%',
|
||||
valign: 'middle',
|
||||
field: "outDiamondNum",
|
||||
title: "最近30天转出金币",
|
||||
align: "center",
|
||||
width: "5%",
|
||||
},
|
||||
{
|
||||
field: "id",
|
||||
title: "操作",
|
||||
align: "center",
|
||||
width: "5%",
|
||||
valign: "middle",
|
||||
formatter: function (val, row, index) {
|
||||
return '<button class="btn btn-sm btn-default opt-edit" data-index="' + index + '">编辑</button>' + '<button class="btn btn-sm btn-default opt-del" data-index="' + index + '">删除</button>';
|
||||
}
|
||||
}
|
||||
return (
|
||||
'<button class="btn btn-sm btn-default opt-edit" data-index="' +
|
||||
index +
|
||||
'">编辑</button>' +
|
||||
'<button class="btn btn-sm btn-default opt-del" data-index="' +
|
||||
index +
|
||||
'">删除</button>'
|
||||
);
|
||||
},
|
||||
},
|
||||
],
|
||||
cache: false,
|
||||
striped: true,
|
||||
@@ -200,25 +291,53 @@ export default {
|
||||
//设置为undefined可以获取pageNumber,pageSize,searchText,sortName,sortOrder
|
||||
//设置为limit可以获取limit, offset, search, sort, order
|
||||
queryParamsType: "undefined",
|
||||
queryParams: function queryParams(params) { //设置查询参数
|
||||
queryParams: function queryParams(params) {
|
||||
//设置查询参数
|
||||
var param = {
|
||||
page: params.pageNumber,
|
||||
pageSize: params.pageSize,
|
||||
erbanNo: $('#searchValue').val(),
|
||||
regionType: $('#searchType').val()
|
||||
erbanNo: $("#searchValue").val(),
|
||||
partitionId: $("#partitionId").val(),
|
||||
regionType: $("#searchType").val(),
|
||||
starLevel: $("#starLevel").val(),
|
||||
};
|
||||
return param;
|
||||
},
|
||||
toolbar: '#toolbar',
|
||||
url: '/admin/recharge/user/page',
|
||||
onLoadSuccess: function () { //加载成功时执行
|
||||
toolbar: "#toolbar",
|
||||
url: "/admin/recharge/user/page",
|
||||
onLoadSuccess: function () {
|
||||
//加载成功时执行
|
||||
console.log("load success");
|
||||
},
|
||||
onLoadError: function () { //加载失败时执行
|
||||
onLoadError: function () {
|
||||
//加载失败时执行
|
||||
console.log("load fail");
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
//分区
|
||||
function listPartitionInfo() {
|
||||
var array;
|
||||
$.ajax({
|
||||
type: "get",
|
||||
url: "/partition/listPartitionInfo",
|
||||
dataType: "json",
|
||||
async: false,
|
||||
success: function (json) {
|
||||
if (json.success == "true" || json.code == 200) {
|
||||
array = json.data;
|
||||
}
|
||||
},
|
||||
});
|
||||
var $select = $("#partitionId");
|
||||
for (let i = 0; i < array.length; i++) {
|
||||
var $option = $('<option value="' + array[i].id + '" />');
|
||||
$option.html(array[i].desc);
|
||||
$select.append($option);
|
||||
}
|
||||
return array;
|
||||
}
|
||||
|
||||
//地区
|
||||
function chargeRegion() {
|
||||
var array;
|
||||
@@ -228,31 +347,32 @@ export default {
|
||||
dataType: "json",
|
||||
async: false,
|
||||
success: function (json) {
|
||||
if (json.success == 'true' || json.code == 200) {
|
||||
if (json.success == "true" || json.code == 200) {
|
||||
array = json.data;
|
||||
}
|
||||
}
|
||||
},
|
||||
});
|
||||
var $select = $('#searchType');
|
||||
var $select = $("#searchType");
|
||||
for (let i = 0; i < array.length; i++) {
|
||||
var $option = $('<option value="' + array[i].type + '" />');
|
||||
$option.html(array[i].name);
|
||||
$option.html(array[i].desc);
|
||||
$select.append($option);
|
||||
}
|
||||
return array;
|
||||
}
|
||||
|
||||
//新增
|
||||
$('#btnAdd').on('click', function () {
|
||||
$("#id").val('');
|
||||
$("#erbanNo").val('');
|
||||
$("#btnAdd").on("click", function () {
|
||||
$("#id").val("");
|
||||
$("#erbanNo").val("");
|
||||
$("#starLevel").val("");
|
||||
showRegion();
|
||||
$("#editModal").modal('show');
|
||||
$("#editModal").modal("show");
|
||||
});
|
||||
|
||||
// 查询刷新
|
||||
$('#btnSearch').on('click', function () {
|
||||
TableHelper.doRefresh('#table');
|
||||
$("#btnSearch").on("click", function () {
|
||||
TableHelper.doRefresh("#table");
|
||||
});
|
||||
|
||||
//展示地区
|
||||
@@ -260,22 +380,31 @@ export default {
|
||||
if (!regionArray) {
|
||||
return;
|
||||
}
|
||||
var $form = $('#editModal .modal-body .form-horizontal');
|
||||
var $form = $("#editModal .modal-body .form-horizontal");
|
||||
for (let i = 0, len = regionArray.length; i < len; i++) {
|
||||
$('#region' + i).remove();
|
||||
$("#region" + i).remove();
|
||||
var region = regionArray[i];
|
||||
var name = region.name;
|
||||
var type = region.type;
|
||||
var $formGroup = $('<div/>');
|
||||
$formGroup.attr('id', 'region' + i);
|
||||
$formGroup.attr('class', 'form-group');
|
||||
var $label = $('<label/>');
|
||||
$label.attr('class', 'col-sm-3 control-label');
|
||||
$label.html('<input type="checkbox" name="type" value="' + type + '" onclick=\"editSeqText(this);\"/> ' + name);
|
||||
var $formGroup = $("<div/>");
|
||||
$formGroup.attr("id", "region" + i);
|
||||
$formGroup.attr("class", "form-group");
|
||||
var $label = $("<label/>");
|
||||
$label.attr("class", "col-sm-3 control-label");
|
||||
$label.html(
|
||||
'<input type="checkbox" name="type" value="' +
|
||||
type +
|
||||
'" onclick="editSeqText(this);"/> ' +
|
||||
name
|
||||
);
|
||||
$formGroup.append($label);
|
||||
var $div = $('<div/>');
|
||||
$div.attr('class', 'col-sm-9');
|
||||
$div.html('<input type="text" readonly class="form-control" id="seq' + type + '" value="0"/>');
|
||||
var $div = $("<div/>");
|
||||
$div.attr("class", "col-sm-9");
|
||||
$div.html(
|
||||
'<input type="text" readonly class="form-control" id="seq' +
|
||||
type +
|
||||
'" value="0"/>'
|
||||
);
|
||||
$formGroup.append($div);
|
||||
$form.append($formGroup);
|
||||
}
|
||||
@@ -283,13 +412,15 @@ export default {
|
||||
|
||||
//保存
|
||||
$("#save").click(function () {
|
||||
const msg = '确定要保存吗?';
|
||||
const msg = "确定要保存吗?";
|
||||
if (confirm(msg)) {
|
||||
var id = $('#id').val();
|
||||
const typeArray = $("input:checkbox[name='type']:checked").serializeArray();
|
||||
var id = $("#id").val();
|
||||
const typeArray = $(
|
||||
"input:checkbox[name='type']:checked"
|
||||
).serializeArray();
|
||||
if (!typeArray) {
|
||||
$("#tipMsg").text("代充地区不能为空");
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipModal").modal("show");
|
||||
return;
|
||||
}
|
||||
var userRegionArray = [];
|
||||
@@ -301,7 +432,7 @@ export default {
|
||||
for (let j = 0; j < typeArray.length; j++) {
|
||||
console.log(typeArray[j]);
|
||||
if (typeArray[j] && region.type == typeArray[j].value) {
|
||||
seq = $('#seq' + region.type).val();
|
||||
seq = $("#seq" + region.type).val();
|
||||
isCheck = true;
|
||||
break;
|
||||
}
|
||||
@@ -310,13 +441,14 @@ export default {
|
||||
type: region.type,
|
||||
name: region.name,
|
||||
isCheck: isCheck,
|
||||
seq: seq
|
||||
seq: seq,
|
||||
};
|
||||
userRegionArray.push(userRegion);
|
||||
}
|
||||
var data = {
|
||||
erbanNo: $('#erbanNo').val(),
|
||||
userRegions: JSON.stringify(userRegionArray)
|
||||
erbanNo: $("#erbanNo").val(),
|
||||
starLevel: $("#starLevel").val(),
|
||||
userRegions: JSON.stringify(userRegionArray),
|
||||
};
|
||||
if (id) {
|
||||
data.id = id;
|
||||
@@ -327,29 +459,32 @@ export default {
|
||||
data: data,
|
||||
dataType: "json",
|
||||
success: function (json) {
|
||||
if (json.success == 'true' || json.code == 200) {
|
||||
if (json.success == "true" || json.code == 200) {
|
||||
$("#tipMsg").text("保存成功");
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipModal").modal("show");
|
||||
TableHelper.doRefresh("#table");
|
||||
$("#editModal").modal('hide');
|
||||
$("#editModal").modal("hide");
|
||||
} else {
|
||||
$("#tipMsg").text("保存失败." + json.message);
|
||||
$("#tipModal").modal('show');
|
||||
$("#editModal").modal('hide');
|
||||
}
|
||||
$("#tipModal").modal("show");
|
||||
$("#editModal").modal("hide");
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
//编辑
|
||||
$('#table').on('click', '.opt-edit', function () {
|
||||
const currentData = $('#table').bootstrapTable('getData')[$(this).data('index')];
|
||||
$("#table").on("click", ".opt-edit", function () {
|
||||
const currentData =
|
||||
$("#table").bootstrapTable("getData")[$(this).data("index")];
|
||||
showRegion();
|
||||
var id = currentData.id;
|
||||
var erbanNo = currentData.erbanNo;
|
||||
var starLevel = currentData.starLevel;
|
||||
var userRegions = currentData.userRegions;
|
||||
$("#erbanNo").val(erbanNo);
|
||||
$("#starLevel").val(starLevel);
|
||||
$("#id").val(id);
|
||||
if (regionArray) {
|
||||
for (let i = 0; i < regionArray.length; i++) {
|
||||
@@ -365,48 +500,54 @@ export default {
|
||||
}
|
||||
}
|
||||
if (isCheck) {
|
||||
$('input:checkbox[value="' + region.type + '"]').prop('checked', true);
|
||||
$('#seq' + region.type).removeAttr('readonly');
|
||||
$('#seq' + region.type).val(seq);
|
||||
$('input:checkbox[value="' + region.type + '"]').prop(
|
||||
"checked",
|
||||
true
|
||||
);
|
||||
$("#seq" + region.type).removeAttr("readonly");
|
||||
$("#seq" + region.type).val(seq);
|
||||
} else {
|
||||
$("input:checkbox[value='" + region.type + "']").prop('checked', false);
|
||||
$('#seq' + region.type).attr('readonly', 'true');
|
||||
$('#seq' + region.type).val(0);
|
||||
$("input:checkbox[value='" + region.type + "']").prop(
|
||||
"checked",
|
||||
false
|
||||
);
|
||||
$("#seq" + region.type).attr("readonly", "true");
|
||||
$("#seq" + region.type).val(0);
|
||||
}
|
||||
}
|
||||
}
|
||||
$("#editModal").modal('show');
|
||||
$("#editModal").modal("show");
|
||||
});
|
||||
|
||||
//删除
|
||||
$('#table').on('click', '.opt-del', function () {
|
||||
const currentData = $('#table').bootstrapTable('getData')[$(this).data('index')];
|
||||
$("#table").on("click", ".opt-del", function () {
|
||||
const currentData =
|
||||
$("#table").bootstrapTable("getData")[$(this).data("index")];
|
||||
var id = currentData.id;
|
||||
const msg = '确定要删除吗?';
|
||||
const msg = "确定要删除吗?";
|
||||
if (confirm(msg)) {
|
||||
$.ajax({
|
||||
type: "get",
|
||||
url: "/admin/recharge/user/del?id=" + id,
|
||||
dataType: "json",
|
||||
success: function (json) {
|
||||
if (json.success == 'true' || json.code == 200) {
|
||||
if (json.success == "true" || json.code == 200) {
|
||||
$("#tipMsg").text("删除成功");
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipModal").modal("show");
|
||||
TableHelper.doRefresh("#table");
|
||||
$("#editModal").modal('hide');
|
||||
$("#editModal").modal("hide");
|
||||
} else {
|
||||
$("#tipMsg").text("删除失败." + json.message);
|
||||
$("#tipModal").modal('show');
|
||||
$("#editModal").modal('hide');
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
});
|
||||
$("#tipModal").modal("show");
|
||||
$("#editModal").modal("hide");
|
||||
}
|
||||
},
|
||||
|
||||
});
|
||||
}
|
||||
});
|
||||
});
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
|
@@ -16,10 +16,22 @@
|
||||
</div>
|
||||
<!-- 按钮 -->
|
||||
<div class="buttonBox">
|
||||
<el-button @click="addClick()" class="primary" type="primary" size="default"
|
||||
style="margin-right: 10px">新增</el-button>
|
||||
<el-button @click="getData()" class="primary" type="primary" size="default"
|
||||
style="margin-right: 10px">查询</el-button>
|
||||
<el-button
|
||||
@click="addClick()"
|
||||
class="primary"
|
||||
type="primary"
|
||||
size="default"
|
||||
style="margin-right: 10px"
|
||||
>新增</el-button
|
||||
>
|
||||
<el-button
|
||||
@click="getData()"
|
||||
class="primary"
|
||||
type="primary"
|
||||
size="default"
|
||||
style="margin-right: 10px"
|
||||
>查询</el-button
|
||||
>
|
||||
</div>
|
||||
<!-- 表格 -->
|
||||
<el-table :data="tableData" border style="width: 100%; margin-top: 25px">
|
||||
@@ -32,105 +44,299 @@
|
||||
</el-table-column>
|
||||
<el-table-column align="center" prop="url" label="开屏页" width="200">
|
||||
<template v-slot="scope">
|
||||
<el-image style="width: 100%; height: 100px" :src="scope.row.url" :zoom-rate="1.1"
|
||||
:preview-src-list="[scope.row.url]" fit="scale-down" preview-teleported="true"
|
||||
hide-on-click-modal="true" />
|
||||
<el-image
|
||||
style="width: 100%; height: 100px"
|
||||
:src="scope.row.url"
|
||||
:zoom-rate="1.1"
|
||||
:preview-src-list="[scope.row.url]"
|
||||
fit="scale-down"
|
||||
preview-teleported="true"
|
||||
hide-on-click-modal="true"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" prop="skipType" label="跳转">
|
||||
<template v-slot="scope">
|
||||
<span>{{ scope.row.skipType == 1 ? "native" : (scope.row.skipType == 2 ? "房间内" : scope.row.skipType == 3
|
||||
? "H5" : "") }}</span>
|
||||
<span>{{
|
||||
scope.row.skipType == 1
|
||||
? "native"
|
||||
: scope.row.skipType == 2
|
||||
? "房间内"
|
||||
: scope.row.skipType == 3
|
||||
? "H5"
|
||||
: ""
|
||||
}}</span>
|
||||
<br />
|
||||
<span>{{ scope.row.skipContent }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="生效时间">
|
||||
<template v-slot="scope">
|
||||
<span>{{ scope.row.startTime == null && scope.row.endTime ? "不限" : (scope.row.startTime + "~" +
|
||||
(scope.row.endTime == null ? "不限" : scope.row.endTime)) }}</span>
|
||||
<span>{{
|
||||
scope.row.startTime == null && scope.row.endTime
|
||||
? "不限"
|
||||
: scope.row.startTime +
|
||||
"~" +
|
||||
(scope.row.endTime == null ? "不限" : scope.row.endTime)
|
||||
}}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" prop="USER_LEVEL" label="可见等级" :formatter="ruleJsonFormatter" />
|
||||
<el-table-column align="center" prop="PLATFORM" label="生效平台" :formatter="ruleJsonFormatter" />
|
||||
<el-table-column align="center" prop="IOS" label="iOS版本号" :formatter="ruleJsonFormatter" />
|
||||
<el-table-column align="center" prop="ANDROID" label="安卓版本号" :formatter="ruleJsonFormatter" />
|
||||
<el-table-column align="center" prop="NOT_CHANNELS" label="不展示渠道" :formatter="ruleJsonFormatter" />
|
||||
<el-table-column
|
||||
align="center"
|
||||
prop="USER_LEVEL"
|
||||
label="可见等级"
|
||||
:formatter="ruleJsonFormatter"
|
||||
/>
|
||||
<el-table-column
|
||||
align="center"
|
||||
prop="PLATFORM"
|
||||
label="生效平台"
|
||||
:formatter="ruleJsonFormatter"
|
||||
/>
|
||||
<el-table-column
|
||||
align="center"
|
||||
prop="IOS"
|
||||
label="iOS版本号"
|
||||
:formatter="ruleJsonFormatter"
|
||||
/>
|
||||
<el-table-column
|
||||
align="center"
|
||||
prop="ANDROID"
|
||||
label="安卓版本号"
|
||||
:formatter="ruleJsonFormatter"
|
||||
/>
|
||||
<el-table-column
|
||||
align="center"
|
||||
prop="NOT_CHANNELS"
|
||||
label="不展示渠道"
|
||||
:formatter="ruleJsonFormatter"
|
||||
/>
|
||||
<el-table-column align="center" label="操作" width="200">
|
||||
<template v-slot="scope">
|
||||
<el-button @click="editClick(scope.row)" class="primary" type="primary" size="default">编辑</el-button>
|
||||
<el-button @click="delClick(scope.row)" class="danger" type="danger" size="default">删除</el-button>
|
||||
<el-button
|
||||
@click="editClick(scope.row)"
|
||||
class="primary"
|
||||
type="primary"
|
||||
size="default"
|
||||
>编辑</el-button
|
||||
>
|
||||
<el-button
|
||||
@click="delClick(scope.row)"
|
||||
class="danger"
|
||||
type="danger"
|
||||
size="default"
|
||||
>删除</el-button
|
||||
>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!-- 分页 -->
|
||||
<el-pagination style="margin-top: 10px" class="paginationClass" v-model:current-page="currentPage"
|
||||
v-model:page-size="pageSize" :page-sizes="[10, 20, 30, 40, 50, 100, 200, 300, 400, 500]" :small="small"
|
||||
:disabled="disabled" :background="background" layout="sizes, prev, pager, next" :total="totals"
|
||||
@size-change="handleSizeChange" @current-change="handleCurrentChange" />
|
||||
<el-pagination
|
||||
style="margin-top: 10px"
|
||||
class="paginationClass"
|
||||
v-model:current-page="currentPage"
|
||||
v-model:page-size="pageSize"
|
||||
:page-sizes="[10, 20, 30, 40, 50, 100, 200, 300, 400, 500]"
|
||||
:small="small"
|
||||
:disabled="disabled"
|
||||
:background="background"
|
||||
layout="sizes, prev, pager, next"
|
||||
:total="totals"
|
||||
@size-change="handleSizeChange"
|
||||
@current-change="handleCurrentChange"
|
||||
/>
|
||||
<!-- 编辑弹窗 -->
|
||||
<el-dialog v-model="editDialog" title="开屏配置" width="50%" center>
|
||||
<div style="margin-bottom: 25px">
|
||||
<span style="display: inline-block; margin-right: 20px" class="col-sm-2 control-label">活动名称</span>
|
||||
<el-input v-model="resource.name" style="width: 75%" class="input" placeholder="请输入活动名称"></el-input>
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>活动名称</span
|
||||
>
|
||||
<el-input
|
||||
v-model="resource.name"
|
||||
style="width: 75%"
|
||||
class="input"
|
||||
placeholder="请输入活动名称"
|
||||
></el-input>
|
||||
</div>
|
||||
<div style="margin-bottom: 25px;margin-top: 70px;">
|
||||
<span style="display: inline-block; margin-right: 20px" class="col-sm-2 control-label">选择地区</span>
|
||||
<el-select v-model="resource.partitionId" style="width: 75%" placeholder="请选择">
|
||||
<el-option v-for="item in partitionInfos" :key="item.id" :label="item.desc"
|
||||
:value="item.id"></el-option>
|
||||
<div style="margin-bottom: 25px; margin-top: 70px">
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>选择地区</span
|
||||
>
|
||||
<el-select
|
||||
v-model="resource.partitionId"
|
||||
style="width: 75%"
|
||||
placeholder="请选择"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in partitionInfos"
|
||||
:key="item.id"
|
||||
:label="item.desc"
|
||||
:value="item.id"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</div>
|
||||
<div style="margin-bottom: 25px">
|
||||
<span style="display: inline-block; margin-right: 20px" class="col-sm-2 control-label">开屏页</span>
|
||||
<input type="hidden" class="form-control" name="avatar" v-model="resource.url" />
|
||||
<img :src="resource.url" style="width:120px;"/>
|
||||
<input type="file" style="width: 26%; display: inline-block;" id="urlFile" name="uploadFile"/>
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>开屏页</span
|
||||
>
|
||||
<input
|
||||
type="hidden"
|
||||
class="form-control"
|
||||
name="avatar"
|
||||
v-model="resource.url"
|
||||
/>
|
||||
<img :src="resource.url" style="width: 120px" />
|
||||
<input
|
||||
type="file"
|
||||
style="width: 26%; display: inline-block"
|
||||
id="urlFile"
|
||||
name="uploadFile"
|
||||
/>
|
||||
</div>
|
||||
<div style="margin-bottom: 25px">
|
||||
<span style="display: inline-block; margin-right: 20px" class="col-sm-2 control-label"></span>
|
||||
<button class="btn btn-success col-sm-4" type="button" id="urlUploadBtn" @click="uploadUrl()">上传</button>
|
||||
<span class="btn col-sm-4" id="urlUploadInfo" style="color:red;"></span>
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
></span>
|
||||
<button
|
||||
class="btn btn-success col-sm-4"
|
||||
type="button"
|
||||
id="urlUploadBtn"
|
||||
@click="uploadUrl()"
|
||||
>
|
||||
上传
|
||||
</button>
|
||||
<span class="btn col-sm-4" id="urlUploadInfo" style="color: red"></span>
|
||||
</div>
|
||||
<div style="margin-bottom: 25px;margin-top: 70px;">
|
||||
<span style="display: inline-block; margin-right: 20px" class="col-sm-2 control-label">跳转位置</span>
|
||||
<el-select v-model="resource.skipType" style="width: 75%" placeholder="请选择">
|
||||
<el-option v-for="item in options" :key="item.value" :label="item.label"
|
||||
:value="item.value"></el-option>
|
||||
<div style="margin-bottom: 25px; margin-top: 70px">
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>跳转位置</span
|
||||
>
|
||||
<el-select
|
||||
v-model="resource.skipType"
|
||||
style="width: 75%"
|
||||
placeholder="请选择"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in options"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</div>
|
||||
<div style="margin-bottom: 25px" v-if="resource.skipType == 2 || resource.skipType == 3">
|
||||
<span style="display: inline-block; margin-right: 20px" class="col-sm-2 control-label">{{ resource.skipType == 3 ? "跳转链接" :
|
||||
(resource.skipType == 2 ? "跳转房间" : "") }}</span>
|
||||
<el-input v-model="resource.skipContent" style="width: 75%" class="input"
|
||||
:placeholder="[resource.skipType == 3 ? '请输入跳转链接' : (resource.skipType == 2 ? '请输入房间ID' : '')]"></el-input>
|
||||
<div
|
||||
style="margin-bottom: 25px"
|
||||
v-if="
|
||||
resource.skipType == 2 ||
|
||||
resource.skipType == 3 ||
|
||||
resource.skipType == 4 ||
|
||||
resource.skipType == 5 ||
|
||||
resource.skipType == 6
|
||||
"
|
||||
>
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>{{ resource.skipType == 3 ? "跳转链接" : "跳转房间" }}</span
|
||||
>
|
||||
<el-input
|
||||
v-model="resource.skipContent"
|
||||
style="width: 75%"
|
||||
class="input"
|
||||
:placeholder="[
|
||||
resource.skipType == 2 ? '请输入房间ID' : '请输入跳转链接',
|
||||
]"
|
||||
></el-input>
|
||||
</div>
|
||||
<div style="margin-bottom: 25px;">
|
||||
<span style="display: inline-block; margin-right: 20px" class="col-sm-2 control-label">生效时间</span>
|
||||
<el-date-picker v-model="resource.startTime" type="datetime" placeholder="选择日期时间" required>
|
||||
<div style="margin-bottom: 25px">
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>生效时间</span
|
||||
>
|
||||
<el-date-picker
|
||||
v-model="resource.startTime"
|
||||
type="datetime"
|
||||
placeholder="选择日期时间"
|
||||
required
|
||||
>
|
||||
</el-date-picker>
|
||||
</div>
|
||||
<div style="margin-bottom: 25px">
|
||||
<span style="display: inline-block; margin-right: 20px" class="col-sm-2 control-label">失效时间</span>
|
||||
<el-date-picker v-model="resource.endTime" type="datetime" placeholder="选择日期时间" required>
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>失效时间</span
|
||||
>
|
||||
<el-date-picker
|
||||
v-model="resource.endTime"
|
||||
type="datetime"
|
||||
placeholder="选择日期时间"
|
||||
required
|
||||
>
|
||||
</el-date-picker>
|
||||
</div>
|
||||
<div style="margin-bottom: 25px">
|
||||
<span style="display: inline-block; margin-right: 20px" class="col-sm-2 control-label">排序</span>
|
||||
<el-input v-model="resource.seqNo" style="width: 75%" class="input" placeholder="请输入排序"></el-input>
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>排序</span
|
||||
>
|
||||
<el-input
|
||||
v-model="resource.seqNo"
|
||||
style="width: 75%"
|
||||
class="input"
|
||||
placeholder="请输入排序"
|
||||
></el-input>
|
||||
</div>
|
||||
<div style="margin-bottom: 25px" v-for="(rule, index) in rules" :key="rule" :index="index">
|
||||
<span style="display: inline-block; margin-right: 20px" class="col-sm-2 control-label">{{ rule.ruleName }}</span>
|
||||
<el-input v-model="resource.ruleValue[rule.ruleCode]" style="width: 75%" class="input" :placeholder="rule.description" v-if="rule.ruleKind != 'IN'"></el-input>
|
||||
<el-select v-model="resource.ruleValue[rule.ruleCode]" style="width: 75%" placeholder="请选择" v-if="rule.ruleKind == 'IN'">
|
||||
<div
|
||||
style="margin-bottom: 25px"
|
||||
v-for="(rule, index) in rules"
|
||||
:key="rule"
|
||||
:index="index"
|
||||
>
|
||||
<span
|
||||
style="display: inline-block; margin-right: 20px"
|
||||
class="col-sm-2 control-label"
|
||||
>{{ rule.ruleName }}</span
|
||||
>
|
||||
<el-input
|
||||
v-model="resource.ruleValue[rule.ruleCode]"
|
||||
style="width: 75%"
|
||||
class="input"
|
||||
:placeholder="rule.description"
|
||||
v-if="rule.ruleKind != 'IN'"
|
||||
></el-input>
|
||||
<el-select
|
||||
v-model="resource.ruleValue[rule.ruleCode]"
|
||||
style="width: 75%"
|
||||
placeholder="请选择"
|
||||
v-if="rule.ruleKind == 'IN'"
|
||||
>
|
||||
<el-option label="全部" :value="''"></el-option>
|
||||
<el-option v-for="value in rule.ruleValue.split(',')" :key="value" :label="value" :value="value"></el-option>
|
||||
<el-option
|
||||
v-for="value in rule.ruleValue.split(',')"
|
||||
:key="value"
|
||||
:label="value"
|
||||
:value="value"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</div>
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button @click="editDialog = false">取消</el-button>
|
||||
<el-button type="primary" @click="editDialogClick()"> 确认 </el-button>
|
||||
<el-button type="primary" @click="editDialogClick()">
|
||||
确认
|
||||
</el-button>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
@@ -148,12 +354,16 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import { getResourcePage, delResource, saveResource, effective } from "@/api/resource/resource";
|
||||
import { getResourceRuleList } from '@/api/resource/resourceRule';
|
||||
import { uploadFile } from '@/api/common/upload';
|
||||
import {
|
||||
getResourcePage,
|
||||
delResource,
|
||||
saveResource,
|
||||
effective,
|
||||
} from "@/api/resource/resource";
|
||||
import { getResourceRuleList } from "@/api/resource/resourceRule";
|
||||
import { uploadFile } from "@/api/common/upload";
|
||||
import { hideLoading, showLoading } from "@/utils/maintainer";
|
||||
import { getPartitionInfoList } from '@/api/partition/partitionInfo';
|
||||
import { getPartitionInfoList } from "@/api/partition/partitionInfo";
|
||||
|
||||
export default {
|
||||
name: "SplashView",
|
||||
@@ -168,37 +378,49 @@ export default {
|
||||
options: [
|
||||
{
|
||||
value: 0,
|
||||
label: "无"
|
||||
label: "无",
|
||||
},
|
||||
{
|
||||
value: 1,
|
||||
label: "APP首页"
|
||||
label: "APP首页",
|
||||
},
|
||||
{
|
||||
value: 2,
|
||||
label: "房间内"
|
||||
label: "房间内",
|
||||
},
|
||||
{
|
||||
value: 3,
|
||||
label: "H5"
|
||||
}
|
||||
label: "H5",
|
||||
},
|
||||
{
|
||||
value: 4,
|
||||
label: "CP活动",
|
||||
},
|
||||
{
|
||||
value: 6,
|
||||
label: "定制礼物活动",
|
||||
},
|
||||
{
|
||||
value: 5,
|
||||
label: "周星榜活动",
|
||||
},
|
||||
],
|
||||
tableData: [], //表单数据存放
|
||||
rules: [],
|
||||
resource: {
|
||||
id: null,
|
||||
name: '',
|
||||
icon: '',
|
||||
name: "",
|
||||
icon: "",
|
||||
skipType: 0,
|
||||
skipContent: '',
|
||||
url: '',
|
||||
skipContent: "",
|
||||
url: "",
|
||||
startTime: null,
|
||||
endTime: null,
|
||||
seqNo: 0,
|
||||
ruleValue: {},
|
||||
partitionId: null,
|
||||
},
|
||||
imageUrl: '',
|
||||
imageUrl: "",
|
||||
partitionInfos: [],
|
||||
searchValues: {
|
||||
partitionId: null,
|
||||
@@ -216,29 +438,31 @@ export default {
|
||||
methods: {
|
||||
uploadUrl() {
|
||||
let $this = this;
|
||||
let file = $('#urlFile').val();
|
||||
let file = $("#urlFile").val();
|
||||
console.log(file);
|
||||
if (file && file.length > 0) {
|
||||
showLoading();
|
||||
uploadFile('urlFile').then(res => {
|
||||
uploadFile("urlFile")
|
||||
.then((res) => {
|
||||
if (res.path) {
|
||||
$this.resource.url = res.path;
|
||||
$('#urlUploadInfo').html('上传成功');
|
||||
$("#urlUploadInfo").html("上传成功");
|
||||
}
|
||||
}).finally(() => {
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoading();
|
||||
});
|
||||
}
|
||||
},
|
||||
getRule() {
|
||||
getResourceRuleList({
|
||||
ruleType: 1
|
||||
}).then(res => {
|
||||
ruleType: 1,
|
||||
}).then((res) => {
|
||||
this.rules = res.data;
|
||||
});
|
||||
},
|
||||
ruleJsonFormatter(row, col, cell, index) {
|
||||
let value = '';
|
||||
let value = "";
|
||||
let key = col.property;
|
||||
let ruleValue = row.ruleValue;
|
||||
if (!ruleValue) {
|
||||
@@ -247,16 +471,19 @@ export default {
|
||||
let ruleObj = JSON.parse(ruleValue);
|
||||
value = ruleObj[key];
|
||||
if (!value) {
|
||||
if (key == 'NOT_CHANNELS') {
|
||||
value = '-';
|
||||
if (key == "NOT_CHANNELS") {
|
||||
value = "-";
|
||||
} else {
|
||||
value = '全部';
|
||||
value = "全部";
|
||||
}
|
||||
}
|
||||
if (key == 'IOS') {
|
||||
value = ruleObj['IOS_LOW_VERSION'] + '~' + ruleObj['IOS_HIGH_VERSION'];
|
||||
} else if (key == 'ANDROID') {
|
||||
value = ruleObj['ANDROID_LOW_VERSION'] + '~' + ruleObj['ANDROID_HIGH_VERSION'];
|
||||
if (key == "IOS") {
|
||||
value = ruleObj["IOS_LOW_VERSION"] + "~" + ruleObj["IOS_HIGH_VERSION"];
|
||||
} else if (key == "ANDROID") {
|
||||
value =
|
||||
ruleObj["ANDROID_LOW_VERSION"] +
|
||||
"~" +
|
||||
ruleObj["ANDROID_HIGH_VERSION"];
|
||||
}
|
||||
return value;
|
||||
},
|
||||
@@ -266,11 +493,11 @@ export default {
|
||||
partitionId: this.searchValues.partitionId,
|
||||
page: this.currentPage,
|
||||
pageSize: this.pageSize,
|
||||
}).then(res => {
|
||||
}).then((res) => {
|
||||
let data = res.data;
|
||||
this.totals = data.total;
|
||||
this.tableData = data.records.map(v => {
|
||||
v['enabled'] = (v.isEnabled == 1);
|
||||
this.tableData = data.records.map((v) => {
|
||||
v["enabled"] = v.isEnabled == 1;
|
||||
return v;
|
||||
});
|
||||
console.log(this.tableData);
|
||||
@@ -278,25 +505,25 @@ export default {
|
||||
},
|
||||
switchClick(id) {
|
||||
effective({
|
||||
id: id
|
||||
}).then(res => {
|
||||
id: id,
|
||||
}).then((res) => {
|
||||
this.getData();
|
||||
});
|
||||
},
|
||||
addClick() {
|
||||
this.resource.id = null;
|
||||
this.resource.name = '';
|
||||
this.resource.icon = '';
|
||||
this.resource.name = "";
|
||||
this.resource.icon = "";
|
||||
this.resource.skipType = 0;
|
||||
this.resource.skipContent = '';
|
||||
this.resource.url = '';
|
||||
this.resource.skipContent = "";
|
||||
this.resource.url = "";
|
||||
this.resource.startTime = null;
|
||||
this.resource.endTime = null;
|
||||
this.resource.seqNo = 0;
|
||||
this.resource.ruleValue = {};
|
||||
for (let i = 0, len = this.rules.length; i < len; i++) {
|
||||
let rule = this.rules[i];
|
||||
this.resource.ruleValue[rule.ruleCode] = '';
|
||||
this.resource.ruleValue[rule.ruleCode] = "";
|
||||
}
|
||||
this.partitionId = null;
|
||||
this.editDialog = true;
|
||||
@@ -327,18 +554,22 @@ export default {
|
||||
editDialogClick() {
|
||||
let startTime = this.resource.startTime;
|
||||
if (startTime) {
|
||||
this.resource.startTime = new Date(startTime).format("yyyy-MM-dd hh:mm:ss");
|
||||
this.resource.startTime = new Date(startTime).format(
|
||||
"yyyy-MM-dd hh:mm:ss"
|
||||
);
|
||||
} else {
|
||||
$("#tipMsg").text('生效时间不能为空');
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipMsg").text("生效时间不能为空");
|
||||
$("#tipModal").modal("show");
|
||||
$("#tipModal").css("z-index",'99999999');
|
||||
return;
|
||||
}
|
||||
let endTime = this.resource.endTime;
|
||||
if (endTime) {
|
||||
this.resource.endTime = new Date(endTime).format("yyyy-MM-dd hh:mm:ss");
|
||||
} else {
|
||||
$("#tipMsg").text('失效时间不能为空');
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipMsg").text("失效时间不能为空");
|
||||
$("#tipModal").modal("show");
|
||||
$("#tipModal").css("z-index",'99999999');
|
||||
return;
|
||||
}
|
||||
let isEnabled = 0;
|
||||
@@ -360,7 +591,7 @@ export default {
|
||||
isEnabled: isEnabled,
|
||||
ruleValue: JSON.stringify(this.resource.ruleValue),
|
||||
partitionId: this.resource.partitionId,
|
||||
}).then(res => {
|
||||
}).then((res) => {
|
||||
this.getData();
|
||||
this.editDialog = false;
|
||||
});
|
||||
@@ -381,14 +612,14 @@ export default {
|
||||
this.getData();
|
||||
},
|
||||
initPartition() {
|
||||
getPartitionInfoList().then(res => {
|
||||
getPartitionInfoList().then((res) => {
|
||||
this.partitionInfos = res.data;
|
||||
});
|
||||
},
|
||||
getPartitionInfo(partitionId) {
|
||||
let partitions = this.partitionInfos.filter(v => v.id == partitionId);
|
||||
let partitions = this.partitionInfos.filter((v) => v.id == partitionId);
|
||||
if (!partitions || partitions.length <= 0) {
|
||||
return '';
|
||||
return "";
|
||||
}
|
||||
return partitions[0].desc;
|
||||
},
|
||||
|
@@ -83,20 +83,20 @@
|
||||
>
|
||||
<div class="col-sm-9">
|
||||
<select name="isTop" id="modal_isTop" class="form-control">
|
||||
<option value=""></option>
|
||||
<option value="1">是</option>
|
||||
<option value="0">否</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="modal_type" class="col-sm-3 control-label"
|
||||
<label for="homeType" class="col-sm-3 control-label"
|
||||
>房间类型:<font color="red">*</font>:</label
|
||||
>
|
||||
<div class="col-sm-9">
|
||||
<select name="type" id="modal_type" class="form-control">
|
||||
<option value="1">客服房间</option>
|
||||
<option value="2">热门房间</option>
|
||||
<select name="type" id="homeType" class="form-control">
|
||||
<option value="0">普通</option>
|
||||
<option value="1">热门房间</option>
|
||||
<option value="2">客服房间</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
@@ -113,7 +113,7 @@
|
||||
min="1"
|
||||
max="5"
|
||||
placeholder="填入的数字=在首页的第几个位置"
|
||||
oninput="this.value = Math.min(Math.max(this.value, 1), 5)"
|
||||
oninput="this.value = Math.min(Math.max(this.value, 0), 5)"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
@@ -283,7 +283,6 @@ export default {
|
||||
} else if (val == 0) {
|
||||
return "否";
|
||||
}
|
||||
return "是";
|
||||
},
|
||||
},
|
||||
{ field: "seq", title: "置顶排序", align: "center", width: "5%" },
|
||||
@@ -304,23 +303,40 @@ export default {
|
||||
formatter: formatTime,
|
||||
},
|
||||
{
|
||||
field: "isHourTop1",
|
||||
title: "小时榜top1",
|
||||
field: "hourTop",
|
||||
title: "小时榜排名",
|
||||
align: "center",
|
||||
valign: "middle",
|
||||
width: "10%",
|
||||
},
|
||||
{
|
||||
field: "hotValue",
|
||||
title: "热力值",
|
||||
align: "center",
|
||||
valign: "middle",
|
||||
width: "10%",
|
||||
},
|
||||
{
|
||||
field: "regionFlag",
|
||||
title: "地区旗帜",
|
||||
align: "center",
|
||||
width: "5%",
|
||||
formatter: function (val, row, index) {
|
||||
return val ? "是" : "否";
|
||||
return "<img src='" + val + "' width='40' height='40'>";
|
||||
},
|
||||
},
|
||||
{
|
||||
field: "isHourTop1",
|
||||
title: "周榜top1",
|
||||
field: "homeType",
|
||||
title: "房间类型",
|
||||
align: "center",
|
||||
valign: "middle",
|
||||
width: "10%",
|
||||
formatter: function (val, row, index) {
|
||||
return val ? "是" : "否";
|
||||
return val == 1
|
||||
? "热门房间"
|
||||
: val == 0
|
||||
? "普通房间"
|
||||
: "客服房间";
|
||||
},
|
||||
},
|
||||
{
|
||||
@@ -404,11 +420,28 @@ export default {
|
||||
var roomUid = $("#roomUid").val();
|
||||
var seq = $("#modal_seq").val();
|
||||
var isTop = $("#modal_isTop").val();
|
||||
var type = $("#modal_type").val();
|
||||
var homeType = $("#homeType").val();
|
||||
var iconContent = $("#modal_iconContent").val();
|
||||
var topStart = $("#modal_topStart").val();
|
||||
var topEnd = $("#modal_topEnd").val();
|
||||
var isShow = $("#modal_isShow").val();
|
||||
if (
|
||||
isTop == 1 && seq <1
|
||||
) {
|
||||
alert("置顶为是时,排序必须大于等于1");
|
||||
return;
|
||||
}
|
||||
if (
|
||||
isTop == "" ||
|
||||
homeType == "" ||
|
||||
seq == "" ||
|
||||
topStart == "" ||
|
||||
topEnd == "" ||
|
||||
isShow == ""
|
||||
) {
|
||||
alert("请填写必填项");
|
||||
return;
|
||||
}
|
||||
if ($("#addForm").validationEngine("validate")) {
|
||||
$.ajax({
|
||||
type: "post",
|
||||
@@ -416,6 +449,7 @@ export default {
|
||||
data: {
|
||||
id: id,
|
||||
roomUid: roomUid,
|
||||
homeType: homeType,
|
||||
seq: seq,
|
||||
isTop: isTop,
|
||||
iconContent: iconContent,
|
||||
@@ -449,10 +483,10 @@ export default {
|
||||
$("#id").val(null);
|
||||
$("#modal_seq").val(0);
|
||||
$("#modal_isTop").val(0);
|
||||
$("#modal_type").val(0);
|
||||
$("#modal_topStart").val("");
|
||||
$("#modal_topEnd").val("");
|
||||
$("#modal_isShow").val(0);
|
||||
$("#homeType").val(record.homeType + "");
|
||||
$("#modal_topStart").val(formatTime(record.topStart));
|
||||
$("#modal_topEnd").val(formatTime(record.topEnd));
|
||||
$("#modal_isShow").val(1);
|
||||
$("#roomUid").val(record.roomUid);
|
||||
if (id && id != "null") {
|
||||
$.ajax({
|
||||
@@ -466,7 +500,7 @@ export default {
|
||||
$("#id").val(id);
|
||||
$("#modal_seq").val(json.seq);
|
||||
$("#modal_isTop").val(json.isTop ? 1 : 0);
|
||||
$("#modal_type").val(json.type);
|
||||
$("#homeType").val(json.homeType);
|
||||
$("#modal_topStart").val(formatTime(json.topStart));
|
||||
$("#modal_topEnd").val(formatTime(json.topEnd));
|
||||
$("#modal_isShow").val(json.isShow ? 1 : 0);
|
||||
|
@@ -6,6 +6,14 @@
|
||||
<section class="content-header">
|
||||
<h1 id="itemTitle"></h1>
|
||||
</section>
|
||||
<div class="col-sm-12">
|
||||
<label for="partitionId" class="col-sm-1 control-label">地区:</label>
|
||||
<div class="col-sm-2">
|
||||
<select name="partitionId" id="partitionId" class="form-control">
|
||||
<option value="4" selected>华语区</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div id="toolbar">
|
||||
<div class="col-sm-12">
|
||||
<button id="btnSearch" class="btn btn-default">
|
||||
@@ -16,22 +24,32 @@
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<input type="hidden" id="currentPageNum">
|
||||
<input type="hidden" id="currentPageNum" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- .content -->
|
||||
<div id="table"></div>
|
||||
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<div class="modal fade" id="roomTabModal" tabindex="-1" role="dialog" aria-labelledby="modalLabel">
|
||||
<div
|
||||
class="modal fade"
|
||||
id="roomTabModal"
|
||||
tabindex="-1"
|
||||
role="dialog"
|
||||
aria-labelledby="modalLabel"
|
||||
>
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
|
||||
aria-hidden="true">×</span>
|
||||
<button
|
||||
type="button"
|
||||
class="close"
|
||||
data-dismiss="modal"
|
||||
aria-label="Close"
|
||||
>
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
<h4 class="modal-title" id="modalLabel">编辑房间标签</h4>
|
||||
</div>
|
||||
@@ -39,34 +57,81 @@
|
||||
<form class="form-horizontal" id="addForm">
|
||||
<input type="hidden" name="id" id="id" />
|
||||
<div class="form-group">
|
||||
<label for="modal_seq" class="col-sm-3 control-label">排序<font color="red">*</font>:</label>
|
||||
<label for="modal_seq" class="col-sm-3 control-label"
|
||||
>排序<font color="red">*</font>:</label
|
||||
>
|
||||
<div class="col-sm-9">
|
||||
<input type="text" class="form-control validate[custom[integer]]" name="seq" id="modal_seq"
|
||||
placeholder="数字小的排前面,必填">
|
||||
<input
|
||||
type="text"
|
||||
class="form-control validate[custom[integer]]"
|
||||
name="seq"
|
||||
id="modal_seq"
|
||||
placeholder="数字小的排前面,必填"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="modal_name" class="col-sm-3 control-label">名称<font color="red">*</font>:</label>
|
||||
<label for="modal_name" class="col-sm-3 control-label"
|
||||
>名称<font color="red">*</font>:</label
|
||||
>
|
||||
<div class="col-sm-9">
|
||||
<input type="text" class="form-control validate[required]" name="name" id="modal_name">
|
||||
<input
|
||||
type="text"
|
||||
class="form-control validate[required]"
|
||||
name="name"
|
||||
id="modal_name"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="ar_modal_name" class="col-sm-3 control-label">阿语名称<font color="red">*</font>:</label>
|
||||
<label for="ar_modal_name" class="col-sm-3 control-label"
|
||||
>阿语名称<font color="red">*</font>:</label
|
||||
>
|
||||
<div class="col-sm-9">
|
||||
<input type="text" class="form-control validate[required]" name="name" id="ar_modal_name">
|
||||
<input
|
||||
type="text"
|
||||
class="form-control validate[required]"
|
||||
name="name"
|
||||
id="ar_modal_name"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="en_modal_name" class="col-sm-3 control-label">英语名称<font color="red">*</font>:</label>
|
||||
<label for="en_modal_name" class="col-sm-3 control-label"
|
||||
>英语名称<font color="red">*</font>:</label
|
||||
>
|
||||
<div class="col-sm-9">
|
||||
<input type="text" class="form-control validate[required]" name="name" id="en_modal_name">
|
||||
<input
|
||||
type="text"
|
||||
class="form-control validate[required]"
|
||||
name="name"
|
||||
id="en_modal_name"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="status" class="col-sm-3 control-label">显示状态<font color="red">*</font>:</label>
|
||||
<label for="tr_modal_name" class="col-sm-3 control-label"
|
||||
>土耳其名称<font color="red">*</font>:</label
|
||||
>
|
||||
<div class="col-sm-9">
|
||||
<select name="status" id="modal_status" class="form-control validate[required]">
|
||||
<input
|
||||
type="text"
|
||||
class="form-control validate[required]"
|
||||
name="name"
|
||||
id="tr_modal_name"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="status" class="col-sm-3 control-label"
|
||||
>显示状态<font color="red">*</font>:</label
|
||||
>
|
||||
<div class="col-sm-9">
|
||||
<select
|
||||
name="status"
|
||||
id="modal_status"
|
||||
class="form-control validate[required]"
|
||||
>
|
||||
<option value=""></option>
|
||||
<option value="1">显示</option>
|
||||
<option value="0">不显示</option>
|
||||
@@ -74,32 +139,64 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="room_tab_show" class="col-sm-3 control-label">房间管理列表展示状态<font color="red">*</font>
|
||||
:</label>
|
||||
<label for="room_tab_show" class="col-sm-3 control-label"
|
||||
>房间管理列表展示状态<font color="red">*</font> :</label
|
||||
>
|
||||
<div class="col-sm-9">
|
||||
<select name="room_tab_show" id="modal_room_tab_show"
|
||||
class="form-control validate[required]">
|
||||
<select
|
||||
name="room_tab_show"
|
||||
id="modal_room_tab_show"
|
||||
class="form-control validate[required]"
|
||||
>
|
||||
<option value=""></option>
|
||||
<option value="true">展示</option>
|
||||
<option value="false">不展示</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group" id="imgBox">
|
||||
<label class="col-sm-3 control-label">icon</label>
|
||||
<div class="col-sm-8">
|
||||
<img
|
||||
src=""
|
||||
id="iconImgUrl"
|
||||
style="width: 108px; height: 45px"
|
||||
alt=""
|
||||
/>
|
||||
<input
|
||||
type="file"
|
||||
id="iconFile"
|
||||
name="uploadFile"
|
||||
accept="image/gif,image/jpeg,image/jpg,image/png,image/svg"
|
||||
/>
|
||||
<button class="btn btn-success" type="button" id="iconBtn">
|
||||
上传
|
||||
</button>
|
||||
<input
|
||||
type="hidden"
|
||||
id="iconUrl"
|
||||
name="alertWinPic"
|
||||
class="form-control validate[required]"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">
|
||||
关闭
|
||||
</button>
|
||||
<button type="button" class="btn btn-primary" id="add">确定</button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import TableHelper from '@/utils/bootstrap-table-helper';
|
||||
|
||||
import TableHelper from "@/utils/bootstrap-table-helper";
|
||||
import { getPartitionInfoList } from "@/api/partition/partitionInfo";
|
||||
import { buildSelectOption } from "@/utils/system-helper";
|
||||
export default {
|
||||
name: "RoomTabView",
|
||||
setup() {
|
||||
@@ -107,53 +204,103 @@ export default {
|
||||
},
|
||||
created() {
|
||||
this.$nextTick(function () {
|
||||
this.initPartition();
|
||||
this.initData();
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
initData() {
|
||||
$(function () {
|
||||
$('#table').bootstrapTable('destroy');
|
||||
$('#table').bootstrapTable({
|
||||
$("#table").bootstrapTable("destroy");
|
||||
$("#table").bootstrapTable({
|
||||
columns: [
|
||||
{ field: 'seq', title: '排序', align: 'center', width: '5%' },
|
||||
{field: 'name.zh', title: 'Tab名称', align: 'center', width: '10%'},
|
||||
{field: 'name.ar', title: '阿语Tab名称', align: 'center', width: '10%'},
|
||||
{field: 'name.en', title: '英语Tab名称', align: 'center', width: '10%'},
|
||||
{ field: "seq", title: "排序", align: "center", width: "5%" },
|
||||
{
|
||||
field: 'status', title: '显示状态', align: 'center', valign: 'middle', width: '5%',
|
||||
formatter: function (val, row, index) {
|
||||
if (val) {
|
||||
return '显示';
|
||||
} else {
|
||||
return '不显示';
|
||||
}
|
||||
|
||||
}
|
||||
field: "name.zh",
|
||||
title: "Tab名称",
|
||||
align: "center",
|
||||
width: "10%",
|
||||
},
|
||||
{
|
||||
field: 'roomTabShow', title: '房间管理列表展示状态', align: 'center', valign: 'middle', width: '5%',
|
||||
formatter: function (val, row, index) {
|
||||
if (val) {
|
||||
return '展示';
|
||||
} else {
|
||||
return '不展示';
|
||||
}
|
||||
|
||||
}
|
||||
field: "name.ar",
|
||||
title: "阿语Tab名称",
|
||||
align: "center",
|
||||
width: "10%",
|
||||
},
|
||||
{
|
||||
field: 'id',
|
||||
title: '操作',
|
||||
align: 'center',
|
||||
width: '10%',
|
||||
field: "name.en",
|
||||
title: "英语Tab名称",
|
||||
align: "center",
|
||||
width: "10%",
|
||||
},
|
||||
{
|
||||
field: "name.tr",
|
||||
title: "土耳其Tab名称",
|
||||
align: "center",
|
||||
width: "10%",
|
||||
},
|
||||
{
|
||||
field: "status",
|
||||
title: "显示状态",
|
||||
align: "center",
|
||||
valign: "middle",
|
||||
width: "5%",
|
||||
formatter: function (val, row, index) {
|
||||
return '<button id="btnEdit" name="btnEdit" class="btn btn-sm btn-success opt-edit" data-id=' + val + '>' +
|
||||
if (val) {
|
||||
return "显示";
|
||||
} else {
|
||||
return "不显示";
|
||||
}
|
||||
},
|
||||
},
|
||||
{
|
||||
field: "icon",
|
||||
title: "图标",
|
||||
align: "center",
|
||||
valign: "middle",
|
||||
width: "10%",
|
||||
formatter: function (val, row, index) {
|
||||
if (null != val && val != "") {
|
||||
return (
|
||||
'<img src="' +
|
||||
val +
|
||||
'" alt="" style="width: 50px; height: 50px;">'
|
||||
);
|
||||
}
|
||||
return "-";
|
||||
},
|
||||
},
|
||||
{
|
||||
field: "roomTabShow",
|
||||
title: "房间管理列表展示状态",
|
||||
align: "center",
|
||||
valign: "middle",
|
||||
width: "5%",
|
||||
formatter: function (val, row, index) {
|
||||
if (val) {
|
||||
return "展示";
|
||||
} else {
|
||||
return "不展示";
|
||||
}
|
||||
},
|
||||
},
|
||||
{
|
||||
field: "id",
|
||||
title: "操作",
|
||||
align: "center",
|
||||
width: "10%",
|
||||
formatter: function (val, row, index) {
|
||||
return (
|
||||
'<button id="btnEdit" name="btnEdit" class="btn btn-sm btn-success opt-edit" data-id=' +
|
||||
val +
|
||||
">" +
|
||||
'<i class="glyphicon glyphicon-edit"></i> 编辑</button>' +
|
||||
' <button class="btn btn-sm btn-danger opt-remove" data-id=' + val +
|
||||
'><i class="glyphicon glyphicon-remove"></i>删除</button>';
|
||||
}
|
||||
}
|
||||
' <button class="btn btn-sm btn-danger opt-remove" data-id=' +
|
||||
val +
|
||||
'><i class="glyphicon glyphicon-remove"></i>删除</button>'
|
||||
);
|
||||
},
|
||||
},
|
||||
],
|
||||
undefinedText: 0,
|
||||
cache: false,
|
||||
@@ -165,27 +312,30 @@ export default {
|
||||
search: false,
|
||||
sidePagination: "server", //表示服务端请求
|
||||
queryParamsType: "undefined",
|
||||
queryParams: function queryParams(params) { //设置查询参数
|
||||
queryParams: function queryParams(params) {
|
||||
//设置查询参数
|
||||
$("#currentPageNum").val(params.pageNumber);
|
||||
var param = {
|
||||
page: params.pageNumber,
|
||||
pageSize: params.pageSize,
|
||||
partitionId: $("#partitionId").val(),
|
||||
};
|
||||
return param;
|
||||
},
|
||||
ajax: function (request) { //使用ajax请求
|
||||
ajax: function (request) {
|
||||
//使用ajax请求
|
||||
$.ajax({
|
||||
type: "GET",
|
||||
url: '/admin/roomTab/list',
|
||||
contentType: 'application/json;charset=utf-8',
|
||||
dataType: 'json',
|
||||
url: "/admin/roomTab/list",
|
||||
contentType: "application/json;charset=utf-8",
|
||||
dataType: "json",
|
||||
data: request.data,
|
||||
success: function (res) {
|
||||
console.log(res);
|
||||
request.success({
|
||||
"rows": res.rows.map(i=>{
|
||||
rows: res.rows.map((i) => {
|
||||
let name = i.name;
|
||||
if (name.startsWith('{') && name.endsWith('}')) {
|
||||
if (name.startsWith("{") && name.endsWith("}")) {
|
||||
i.name = JSON.parse(i.name);
|
||||
} else {
|
||||
i.name = {
|
||||
@@ -196,45 +346,46 @@ export default {
|
||||
}
|
||||
return i;
|
||||
}),
|
||||
"total": res.total
|
||||
total: res.total,
|
||||
});
|
||||
},
|
||||
error: function (error) {
|
||||
console.log(error);
|
||||
}
|
||||
})
|
||||
},
|
||||
toolbar: '#toolbar',
|
||||
onLoadSuccess: function () { //加载成功时执行
|
||||
});
|
||||
},
|
||||
toolbar: "#toolbar",
|
||||
onLoadSuccess: function () {
|
||||
//加载成功时执行
|
||||
console.log("load success");
|
||||
},
|
||||
onLoadError: function () { //加载失败时执行
|
||||
onLoadError: function () {
|
||||
//加载失败时执行
|
||||
console.log("load fail");
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
|
||||
// 查询刷新
|
||||
$('#btnSearch').on('click', function () {
|
||||
TableHelper.doRefresh('#table');
|
||||
$("#btnSearch").on("click", function () {
|
||||
TableHelper.doRefresh("#table");
|
||||
});
|
||||
|
||||
//新建标签
|
||||
$("#btnAdd").click(function () {
|
||||
$("#id").val("");
|
||||
$("#modal_name").val("");
|
||||
$("#ar_modal_name").val("");
|
||||
$("#en_modal_name").val("");
|
||||
$("#tr_modal_name").val("");
|
||||
$("#modal_seq").val("");
|
||||
$("#modal_status").val("");
|
||||
$("#modal_room_tab_show").val("");
|
||||
$("#modal_type").val("");
|
||||
$("#modal_istop").val("");
|
||||
$("#modal_description").val("");
|
||||
$('#addActPic').val('');
|
||||
$('#addUploadFile').val('');
|
||||
$('#addImgUrl').attr('src', '');
|
||||
$("#roomTabModal").modal('show');
|
||||
$("#addActPic").val("");
|
||||
$("#addUploadFile").val("");
|
||||
$("#addImgUrl").attr("src", "");
|
||||
$("#roomTabModal").modal("show");
|
||||
});
|
||||
|
||||
$("#add").click(function () {
|
||||
@@ -244,14 +395,16 @@ export default {
|
||||
var ar_name = $("#ar_modal_name").val();
|
||||
// 英语名称
|
||||
var en_name = $("#en_modal_name").val();
|
||||
var tr_name = $("#tr_modal_name").val();
|
||||
// 国际化字段
|
||||
var jsonName = {"zh":name,"ar":ar_name,"en":en_name}
|
||||
var jsonName = { zh: name, ar: ar_name, en: en_name, tr: tr_name };
|
||||
const nameValue = JSON.stringify(jsonName);
|
||||
var seq = $("#modal_seq").val();
|
||||
var status = $("#modal_status").val();
|
||||
var roomTabShow = $("#modal_room_tab_show").val();
|
||||
var icon = $("#iconImgUrl").attr("src");
|
||||
|
||||
if ($("#addForm").validationEngine('validate')) {
|
||||
if ($("#addForm").validationEngine("validate")) {
|
||||
$.ajax({
|
||||
type: "post",
|
||||
url: "/admin/roomTab/save",
|
||||
@@ -261,31 +414,31 @@ export default {
|
||||
seq: seq,
|
||||
status: status,
|
||||
roomTabShow: roomTabShow,
|
||||
icon: icon,
|
||||
},
|
||||
dataType: "json",
|
||||
success: function (json) {
|
||||
if (json.code == 200) {
|
||||
$("#tipMsg").text("保存成功");
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipModal").modal("show");
|
||||
TableHelper.doRefresh("#table");
|
||||
$("#roomTabModal").modal('hide');
|
||||
$("#roomTabModal").modal("hide");
|
||||
} else {
|
||||
$("#tipMsg").text("保存失败." + json.msg);
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipModal").modal("show");
|
||||
TableHelper.doRefresh("#table");
|
||||
$("#roomTabModal").modal('hide');
|
||||
}
|
||||
$("#roomTabModal").modal("hide");
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
$("#table").on("click", '.opt-edit', function () {
|
||||
$("#table").on("click", ".opt-edit", function () {
|
||||
var id = $(this).attr("data-id");
|
||||
$('#addImgUrl').attr('src', '');
|
||||
$('#addActPic').val('');
|
||||
$('#addUploadFile').val('');
|
||||
$("#addImgUrl").attr("src", "");
|
||||
$("#addActPic").val("");
|
||||
$("#addUploadFile").val("");
|
||||
$.ajax({
|
||||
type: "get",
|
||||
url: "/admin/roomTab/get",
|
||||
@@ -297,19 +450,24 @@ export default {
|
||||
var json = ret.data.roomTab;
|
||||
$("#id").val(id);
|
||||
let name = json.name;
|
||||
if (name.startsWith('{') && name.endsWith('}')) {
|
||||
$('#iconImgUrl').attr('src',json.icon);
|
||||
if (name.startsWith("{") && name.endsWith("}")) {
|
||||
var jsonName = JSON.parse(json.name);
|
||||
$("#modal_name").val(jsonName.zh);
|
||||
// 阿语名称
|
||||
$("#ar_modal_name").val(jsonName.ar);
|
||||
// 英语名称
|
||||
$("#en_modal_name").val(jsonName.en);
|
||||
// 土耳其名称
|
||||
$("#tr_modal_name").val(jsonName.tr);
|
||||
} else {
|
||||
$("#modal_name").val(name);
|
||||
// 阿语名称
|
||||
$("#ar_modal_name").val(name);
|
||||
// 英语名称
|
||||
$("#en_modal_name").val(name);
|
||||
// 土耳其名称
|
||||
$("#tr_modal_name").val(name);
|
||||
}
|
||||
$("#modal_seq").val(json.seq);
|
||||
if (json.status == 1) {
|
||||
@@ -323,47 +481,104 @@ export default {
|
||||
$("#modal_room_tab_show").val("false");
|
||||
}
|
||||
// 打开编辑弹窗
|
||||
$("#roomTabModal").modal('show');
|
||||
$("#roomTabModal").modal("show");
|
||||
$("#modalLabel").text("编辑房间Tab");
|
||||
} else {
|
||||
$("#tipMsg").text("获取菜单信息出错");
|
||||
$("#tipModal").modal('show');
|
||||
}
|
||||
$("#tipModal").modal("show");
|
||||
}
|
||||
},
|
||||
});
|
||||
});
|
||||
|
||||
$("#table").on("click", '.opt-remove', function () {
|
||||
$("#table").on("click", ".opt-remove", function () {
|
||||
var id = $(this).attr("data-id");
|
||||
if (id == 'undefined') {
|
||||
if (id == "undefined") {
|
||||
$("#tipMsg").text("id参数有误");
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipModal").modal("show");
|
||||
return;
|
||||
}
|
||||
if (confirm("你确认删除吗? \r\n 删除后隐藏tab不会显示,请谨慎操作!")) {
|
||||
if (
|
||||
confirm("你确认删除吗? \r\n 删除后隐藏tab不会显示,请谨慎操作!")
|
||||
) {
|
||||
$.ajax({
|
||||
type: 'post',
|
||||
type: "post",
|
||||
url: "/admin/roomTab/hide",
|
||||
data: { id: id },
|
||||
dataType: "json",
|
||||
success: function (json) {
|
||||
if (json.code == 200) {
|
||||
$("#tipMsg").text("删除成功");
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipModal").modal("show");
|
||||
TableHelper.doRefresh("#table");
|
||||
} else {
|
||||
$("#tipMsg").text("删除失败");
|
||||
$("#tipModal").modal('show');
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
});
|
||||
$("#tipModal").modal("show");
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
$("#iconBtn").on("click", function () {
|
||||
if ($("#iconFile").val() == "") {
|
||||
$("#tipMsg").text("上传图片为空");
|
||||
$("#tipModal").modal("show");
|
||||
return;
|
||||
}
|
||||
$.ajaxFileUpload({
|
||||
fileElementId: "iconFile", //需要上传的文件域的ID,即<input type="file">的ID。
|
||||
url: "/admin/upload/img", //后台方法的路径
|
||||
type: "post", //当要提交自定义参数时,这个参数要设置成post
|
||||
dataType: "json", //服务器返回的数据类型。可以为xml,script,json,html。如果不填写,jQuery会自动判断。
|
||||
secureuri: false, //是否启用安全提交,默认为false。
|
||||
async: true, //是否是异步
|
||||
success: function (json) {
|
||||
//提交成功后自动执行的处理函数,参数data就是服务器返回的数据。
|
||||
if (json.path) {
|
||||
$("#iconUrl").val(json.path);
|
||||
$("#iconImgUrl").attr("src", json.path);
|
||||
} else {
|
||||
$("#tipMsg").text(json.msg);
|
||||
$("#tipModal").modal("show");
|
||||
}
|
||||
},
|
||||
error: function (data, status, e) {
|
||||
//提交失败自动执行的处理函数。
|
||||
console.error(e);
|
||||
},
|
||||
});
|
||||
});
|
||||
|
||||
function clearModal() {
|
||||
$("#iconImgUrl").attr("src", "");
|
||||
|
||||
$("#addForm")
|
||||
.find("input[type=text],input[type=hidden],input[type=file]")
|
||||
.each(function () {
|
||||
$(this).val("");
|
||||
});
|
||||
|
||||
$("#type").val(1);
|
||||
}
|
||||
});
|
||||
},
|
||||
initPartition() {
|
||||
getPartitionInfoList().then((res) => {
|
||||
let data = res.data;
|
||||
buildSelectOption(
|
||||
"#partitionId",
|
||||
4,
|
||||
data.map((v) => {
|
||||
return {
|
||||
value: v.id,
|
||||
text: v.desc,
|
||||
};
|
||||
})
|
||||
);
|
||||
});
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
|
@@ -107,7 +107,9 @@
|
||||
</div>
|
||||
<div class="userId">
|
||||
<span>值</span>
|
||||
<el-input v-model="configValue" style="width: 75%" class="input"></el-input>
|
||||
<el-input type="textarea"
|
||||
:autosize="{ minRows: 2}"
|
||||
v-model="configValue" style="width: 75%" class="input"></el-input>
|
||||
</div>
|
||||
<div class="userId">
|
||||
<span>命名空间</span>
|
||||
|
@@ -87,17 +87,15 @@ export default {
|
||||
{ field: 'nick', title: '查询用户昵称', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'erbanNo', title: '查询用户平台号', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'targetNick', title: '对应对象昵称', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'targetErbanNo', title: '对应对象平台号', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'targetErbanNo', title: '对应对象平台号', align: 'center', valign: 'middle', width: '5%' },
|
||||
{ field: 'roomNick', title: '消费地点房主昵称', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'roomErbanNo', title: '房主平台号', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'roomErbanNo', title: '房主平台号', align: 'center', valign: 'middle', width: '5%' },
|
||||
{ field: 'giftName', title: '礼物名称', align: 'center', valign: 'middle', width: '5%' },
|
||||
{ field: 'giftNum', title: '礼物数量', align: 'center', valign: 'middle', width: '5%' },
|
||||
{ field: 'amount', title: '金币/水晶/钻石', align: 'center', valign: 'middle', width: '5%' },
|
||||
{ field: 'country', title: '国家/地区', align: 'center', valign: 'middle', width: '5%' },
|
||||
{ field: 'localCurrencyCode', title: '本地货币数', align: 'center', valign: 'middle', width: '5%' },
|
||||
{ field: 'localAmount', title: '货币数', align: 'center', valign: 'middle', width: '5%' },
|
||||
{ field: 'currencyDesc', title: '交易币种', align: 'center', valign: 'middle', width: '5%' },
|
||||
{ field: 'billTypeDesc', title: '账单类型', align: 'center', valign: 'middle', width: '10%' },
|
||||
{ field: 'beforeAmount', title: '变动前', align: 'center', valign: 'middle', width: '5%' },
|
||||
{ field: 'amount', title: '金币/钻石', align: 'center', valign: 'middle', width: '5%' },
|
||||
{ field: 'afterAmount', title: '变动后', align: 'center', valign: 'middle', width: '5%' },
|
||||
{ field: 'objTypeDesc', title: '业务类型', align: 'center', valign: 'middle', width: '10%' },
|
||||
{
|
||||
field: 'createTime', title: '创建时间', align: 'center', valign: 'middle', width: '10%', formatter: function (val, row, index) {
|
||||
@@ -113,9 +111,9 @@ export default {
|
||||
cache: false,
|
||||
striped: true,
|
||||
showRefresh: false,
|
||||
pageSize: 10,
|
||||
pageSize: 20,
|
||||
pagination: true,
|
||||
pageList: [10, 20, 30, 50],
|
||||
pageList: [ 20, 30, 50],
|
||||
sidePagination: "server", //表示服务端请求
|
||||
//设置为undefined可以获取pageNumber,pageSize,searchText,sortName,sortOrder
|
||||
//设置为limit可以获取limit, offset, search, sort, order
|
||||
|
@@ -101,6 +101,7 @@ export default {
|
||||
columns: [
|
||||
{ field: 'date', title: '日期', align: 'center', width: '14%' },
|
||||
{ field: 'googleUsd', title: 'google充值美元', align: 'center', width: '14%' },
|
||||
{ field: 'razerUsd', title: 'razer充值', align: 'center', width: '14%' },
|
||||
{ field: 'payermaxUsd', title: 'payermax充值美元', align: 'center', width: '14%' },
|
||||
{ field: 'myCardUsd', title: 'myCard充值美元', align: 'center', width: '14%' },
|
||||
{ field: 'startPayUsd', title: 'startPay充值美元', align: 'center', width: '14%' },
|
||||
|
@@ -96,6 +96,7 @@ export default {
|
||||
{field: 'iosPayAmount', title: 'IOS支付', align: 'center', width: '5%'},
|
||||
{field: 'wxMiniAppAmount', title: '小程序支付', align: 'center', width: '5%'},*/
|
||||
{ field: 'googleAmount', title: 'google支付', align: 'center', width: '5%' },
|
||||
{ field: 'razerAmount', title: 'razer充值', align: 'center', width: '14%' },
|
||||
{ field: 'payermaxAmount', title: 'payermax支付', align: 'center', width: '5%' },
|
||||
{ field: 'myCardAmount', title: 'MyCard支付', align: 'center', width: '5%' },
|
||||
{ field: 'startPayAmount', title: 'startPay支付', align: 'center', width: '5%' },
|
||||
@@ -163,7 +164,7 @@ export default {
|
||||
columns: [
|
||||
{ field: 'channel', title: '渠道', align: 'center', width: '5%' },
|
||||
{ field: 'amount', title: '充值金额', align: 'center', width: '5%' },
|
||||
{ field: 'count', title: '充值笔数', align: 'center', width: '5%' }
|
||||
{ field: 'count', title: '充值笔数', align: 'center', width: '5%' },
|
||||
|
||||
],
|
||||
undefinedText: 0,
|
||||
|
@@ -101,6 +101,7 @@ export default {
|
||||
columns: [
|
||||
{ field: 'date', title: '日期', align: 'center', width: '14%' },
|
||||
{ field: 'googleUsd', title: 'google充值美元', align: 'center', width: '14%' },
|
||||
{ field: 'razerUsd', title: 'razer充值', align: 'center', width: '14%' },
|
||||
{ field: 'payermaxUsd', title: 'payermax充值美元', align: 'center', width: '14%' },
|
||||
{ field: 'myCardUsd', title: 'myCard充值美元', align: 'center', width: '14%' },
|
||||
{ field: 'startPayUsd', title: 'startPay充值美元', align: 'center', width: '14%' },
|
||||
|
@@ -97,6 +97,7 @@ export default {
|
||||
columns: [
|
||||
{ field: 'partitionName', title: '分区', align: 'center', width: '25%' },
|
||||
{ field: 'googleUsd', title: 'google充值美元', align: 'center', width: '25%' },
|
||||
{ field: 'razerUsd', title: 'razer充值', align: 'center', width: '14%' },
|
||||
{ field: 'payermaxUsd', title: 'payermax充值美元', align: 'center', width: '25%' },
|
||||
{ field: 'myCardUsd', title: 'myCard充值美元', align: 'center', width: '25%' },
|
||||
{ field: 'iosUsd', title: 'ios充值美元', align: 'center', width: '25%' },
|
||||
|
@@ -115,6 +115,7 @@ export default {
|
||||
{field: 'iosPayAmount', title: 'IOS支付', align: 'center', width: '5%'},
|
||||
{field: 'wxMiniAppAmount', title: '小程序支付', align: 'center', width: '5%'},*/
|
||||
{ field: 'googleAmount', title: 'google支付', align: 'center', width: '5%' },
|
||||
{ field: 'razerAmount', title: 'razer充值', align: 'center', width: '14%' },
|
||||
{ field: 'payermaxAmount', title: 'payermax支付', align: 'center', width: '5%' },
|
||||
{ field: 'myCardAmount', title: 'myCard支付', align: 'center', width: '5%' },
|
||||
{ field: 'startPayAmount', title: 'startPay支付', align: 'center', width: '5%' },
|
||||
|
@@ -101,6 +101,7 @@ export default {
|
||||
columns: [
|
||||
{ field: 'date', title: '日期', align: 'center', width: '14%' },
|
||||
{ field: 'googleUsd', title: 'google充值美元', align: 'center', width: '14%' },
|
||||
{ field: 'razerUsd', title: 'razer充值', align: 'center', width: '14%' },
|
||||
{ field: 'payermaxUsd', title: 'payermax充值美元', align: 'center', width: '14%' },
|
||||
{ field: 'myCardUsd', title: 'myCard充值美元', align: 'center', width: '14%' },
|
||||
{ field: 'startPayUsd', title: 'startPay充值美元', align: 'center', width: '14%' },
|
||||
|
@@ -101,6 +101,7 @@ export default {
|
||||
columns: [
|
||||
{ field: 'date', title: '日期', align: 'center', width: '14%' },
|
||||
{ field: 'googleUsd', title: 'google充值美元', align: 'center', width: '14%' },
|
||||
{ field: 'razerUsd', title: 'razer充值1', align: 'center', width: '14%' },
|
||||
{ field: 'payermaxUsd', title: 'payermax充值美元', align: 'center', width: '14%' },
|
||||
{ field: 'myCardUsd', title: 'myCard充值美元', align: 'center', width: '14%' },
|
||||
{ field: 'startPayUsd', title: 'startPay充值美元', align: 'center', width: '14%' },
|
||||
|
@@ -1283,6 +1283,7 @@ export default {
|
||||
$("input:checkbox[name='partitionFlag']")[0].checked = false;
|
||||
$("input:checkbox[name='partitionFlag']")[1].checked = false;
|
||||
$("input:checkbox[name='partitionFlag']")[2].checked = false;
|
||||
$("input:checkbox[name='partitionFlag']")[3].checked = false;
|
||||
console.log("btnEdit");
|
||||
var id = $(this).attr("data-id");
|
||||
$this.files = {};
|
||||
@@ -1441,6 +1442,11 @@ export default {
|
||||
} else {
|
||||
$("input:checkbox[name='partitionFlag']")[2].checked = false;
|
||||
}
|
||||
if ((partitionFlag & 8) != 0) {
|
||||
$("input:checkbox[name='partitionFlag']")[3].checked = true;
|
||||
} else {
|
||||
$("input:checkbox[name='partitionFlag']")[3].checked = false;
|
||||
}
|
||||
// 打开编辑弹窗
|
||||
$("#giftModal").modal('show');
|
||||
} else {
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -271,7 +271,7 @@
|
||||
|
||||
<script>
|
||||
import TableHelper from '@/utils/bootstrap-table-helper';
|
||||
import { getPartitionInfoList } from '@/api/partition/partitionInfo';
|
||||
import { listAll } from '@/api/partition/partitionInfo';
|
||||
import { buildSelectOption } from '@/utils/system-helper';
|
||||
|
||||
export default {
|
||||
@@ -902,7 +902,7 @@ export default {
|
||||
|
||||
},
|
||||
initPartition() {
|
||||
getPartitionInfoList().then(res => {
|
||||
listAll().then(res => {
|
||||
let data = res.data;
|
||||
this.partitionInfos = data;
|
||||
buildSelectOption(
|
||||
|
@@ -20,6 +20,14 @@
|
||||
class="input-sm validate[required]"
|
||||
name="deviceId"
|
||||
id="deviceId">
|
||||
IP:<input type="text"
|
||||
class="input-sm validate[required]"
|
||||
name="ip"
|
||||
id="ip">
|
||||
IP地区:<input type="text"
|
||||
class="input-sm validate[required]"
|
||||
name="ipRegion"
|
||||
id="ipRegion">
|
||||
查询类型:<select name="loginType"
|
||||
id="loginType"
|
||||
class="input-sm">
|
||||
@@ -31,8 +39,8 @@
|
||||
<option value="5">苹果登录</option>
|
||||
<option value="6">ticket登录</option>
|
||||
</select>
|
||||
<button id="btnSearch"
|
||||
class="btn btn-sm btn-primary">查询</button>
|
||||
<button id="btnSearch" class="btn btn-primary">查询</button>
|
||||
<button id="btnExport" class="btn">导出</button>
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
@@ -59,7 +67,6 @@ export default {
|
||||
$('#table').bootstrapTable('destroy');
|
||||
$('#table').bootstrapTable({
|
||||
columns: [
|
||||
{ field: 'recordId', title: 'recordId', align: 'center', valign: 'middle', width: '5%' },
|
||||
{ field: 'phone', title: '手机号', align: 'center', valign: 'middle', width: '5%' },
|
||||
{ field: 'erbanNo', title: '平台号', align: 'center', valign: 'middle', width: '5%' },
|
||||
{
|
||||
@@ -128,6 +135,7 @@ export default {
|
||||
align: 'center', width: '10%',
|
||||
valign: 'middle'
|
||||
},*/
|
||||
{ field: 'appVersion', title: 'app版本', align: 'center', width: '5%', valign: 'middle' },
|
||||
{
|
||||
field: 'os',
|
||||
title: '系统类型',
|
||||
@@ -136,7 +144,6 @@ export default {
|
||||
valign: 'middle'
|
||||
},
|
||||
{ field: 'osversion', title: '系统版本', align: 'center', width: '5%', valign: 'middle' },
|
||||
{ field: 'ispType', title: '运营商类型', align: 'center', width: '5%', valign: 'middle' },
|
||||
{ field: 'deviceId', title: '设备号', align: 'center', width: '10%', valign: 'middle' },
|
||||
{ field: 'model', title: '手机型号', align: 'center', width: '10%', valign: 'middle' },
|
||||
{
|
||||
@@ -182,6 +189,8 @@ export default {
|
||||
phone: $('#phone').val(),
|
||||
erbanNo: $('#erbanNo').val(),
|
||||
deviceId: $('#deviceId').val(),
|
||||
ip: $('#ip').val(),
|
||||
ipRegion: $('#ipRegion').val(),
|
||||
loginType: $('#loginType').val(),
|
||||
};
|
||||
return param;
|
||||
@@ -201,6 +210,17 @@ export default {
|
||||
$('#btnSearch').on('click', function () {
|
||||
TableHelper.doRefresh('#table');
|
||||
})
|
||||
|
||||
// 导出
|
||||
$('#btnExport').on('click', function () {
|
||||
const phone = $('#phone').val();
|
||||
const erbanNo = $('#erbanNo').val();
|
||||
const deviceId = $('#deviceId').val();
|
||||
const ip = $('#ip').val();
|
||||
const ipRegion = $('#ipRegion').val();
|
||||
const loginType = $('#loginType').val();
|
||||
window.location.href = `/admin/accountLoginRecord/export?phone=${phone}&erbanNo=${erbanNo}&deviceId=${deviceId}&ip=${ip}&ipRegion=${ipRegion}&loginType=${loginType}`;
|
||||
})
|
||||
})
|
||||
}
|
||||
},
|
||||
|
@@ -8,32 +8,82 @@
|
||||
</section>
|
||||
<!-- .content -->
|
||||
<div id="table"></div>
|
||||
<div id="toolbar" style="height: auto;">
|
||||
<form id="searchForm" class="col-sm-pull-12" action="/admin/dynamic/verify/export" method="post"
|
||||
target="_blank">
|
||||
<div id="toolbar" style="height: auto">
|
||||
<form
|
||||
id="searchForm"
|
||||
class="col-sm-pull-12"
|
||||
action="/admin/dynamic/verify/export"
|
||||
method="post"
|
||||
target="_blank"
|
||||
>
|
||||
<div class="col-sm-12">
|
||||
<label for="erbanNo" class="col-sm-1 control-label">平台号:</label>
|
||||
<div class="col-sm-2"><input type="text" class="form-control" name="erbanNo" id="erbanNo"></div>
|
||||
<label for="partitionId" class="col-sm-1 control-label">地区:</label>
|
||||
<div class="col-sm-2">
|
||||
<select name="partitionId" id="partitionId" class="form-control">
|
||||
<option value="4" selected>华语区</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-sm-12">
|
||||
<label for="erbanNo" class="col-sm-1 control-label"
|
||||
>平台号:</label
|
||||
>
|
||||
<div class="col-sm-2">
|
||||
<input
|
||||
type="text"
|
||||
class="form-control"
|
||||
name="erbanNo"
|
||||
id="erbanNo"
|
||||
/>
|
||||
</div>
|
||||
|
||||
<label for="nick" class="col-sm-1 control-label">昵称:</label>
|
||||
<div class="col-sm-2"><input type="text" class="form-control" name="nick" id="nick"></div>
|
||||
<div class="col-sm-2">
|
||||
<input type="text" class="form-control" name="nick" id="nick" />
|
||||
</div>
|
||||
|
||||
<label for="status" class="col-sm-1 control-label">状态:</label>
|
||||
<div class="col-sm-2">
|
||||
<select name="status" id="status" data-btn-class="btn-warning" class="form-control">
|
||||
<select
|
||||
name="status"
|
||||
id="status"
|
||||
data-btn-class="btn-warning"
|
||||
class="form-control"
|
||||
>
|
||||
<option value="" selected="selected">全部</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-sm-12">
|
||||
<label class="col-sm-1 control-label">发布时间:</label>
|
||||
<div class="col-sm-2"><input type="text" class="form-control" name="beginDate" id="beginDate">
|
||||
</div><span class="col-sm-1">至</span>
|
||||
<div class="col-sm-2"><input type="text" class="form-control" name="endDate" id="endDate"></div>
|
||||
|
||||
<label for="wolrdId" class="col-sm-1 control-label">话题名称:</label>
|
||||
<div class="col-sm-2">
|
||||
<select name="wolrdId" id="wolrdId" data-btn-class="btn-warning" class="form-control">
|
||||
<input
|
||||
type="text"
|
||||
class="form-control"
|
||||
name="beginDate"
|
||||
id="beginDate"
|
||||
/>
|
||||
</div>
|
||||
<span class="col-sm-1">至</span>
|
||||
<div class="col-sm-2">
|
||||
<input
|
||||
type="text"
|
||||
class="form-control"
|
||||
name="endDate"
|
||||
id="endDate"
|
||||
/>
|
||||
</div>
|
||||
|
||||
<label for="wolrdId" class="col-sm-1 control-label"
|
||||
>话题名称:</label
|
||||
>
|
||||
<div class="col-sm-2">
|
||||
<select
|
||||
name="wolrdId"
|
||||
id="wolrdId"
|
||||
data-btn-class="btn-warning"
|
||||
class="form-control"
|
||||
>
|
||||
<option value="" selected="selected">全部</option>
|
||||
<option value="-1">动态广场</option>
|
||||
</select>
|
||||
@@ -56,33 +106,57 @@
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<div class="modal fade" id="showModal" tabindex="-1" role="dialog" aria-labelledby="modalLabel">
|
||||
<div
|
||||
class="modal fade"
|
||||
id="showModal"
|
||||
tabindex="-1"
|
||||
role="dialog"
|
||||
aria-labelledby="modalLabel"
|
||||
>
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-content" style="width: 500px;">
|
||||
<div class="modal-content" style="width: 500px">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
|
||||
aria-hidden="true">×</span></button>
|
||||
<button
|
||||
type="button"
|
||||
class="close"
|
||||
data-dismiss="modal"
|
||||
aria-label="Close"
|
||||
>
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
<h4 class="modal-title" id="modalLabel">查看</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<input type="hidden" name="id" id="dynamicId" />
|
||||
<div class="show" style="margin-left: 60px">
|
||||
|
||||
<div class="show" style="margin-left: 60px"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="imgMask"><img src="" alt=""></div>
|
||||
<div id="imgMask"><img src="" alt="" /></div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">
|
||||
关闭
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal fade" id="notPassModal" tabindex="-1" role="dialog" aria-labelledby="modalLabe2">
|
||||
<div
|
||||
class="modal fade"
|
||||
id="notPassModal"
|
||||
tabindex="-1"
|
||||
role="dialog"
|
||||
aria-labelledby="modalLabe2"
|
||||
>
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-content" style="width: 600px;">
|
||||
<div class="modal-content" style="width: 600px">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
|
||||
aria-hidden="true">×</span></button>
|
||||
<button
|
||||
type="button"
|
||||
class="close"
|
||||
data-dismiss="modal"
|
||||
aria-label="Close"
|
||||
>
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
<h4 class="modal-title" id="modalLabe2">请选择原因</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
@@ -91,13 +165,21 @@
|
||||
<input type="hidden" name="status" id="status1" />
|
||||
<div class="form-group">
|
||||
<div class="col-sm-10">
|
||||
<select id="quick_reason" class="form-control" data-btn-class="btn-warning"
|
||||
onchange="setReason()">
|
||||
<option value="0">動態可能包含抽煙、喝酒、辱罵、攻擊他人等不文明內容</option>
|
||||
<select
|
||||
id="quick_reason"
|
||||
class="form-control"
|
||||
data-btn-class="btn-warning"
|
||||
onchange="setReason()"
|
||||
>
|
||||
<option value="0">
|
||||
動態可能包含抽煙、喝酒、辱罵、攻擊他人等不文明內容
|
||||
</option>
|
||||
<option value="1">動態涉及色情、暴力、病毒等違規內容</option>
|
||||
<option value="2">動態包含政治敏感信息</option>
|
||||
<option value="3">動態包含廣告、營銷內容</option>
|
||||
<option value="4">動態可能包含個人隱私信息或涉及他人營私信息</option>
|
||||
<option value="4">
|
||||
動態可能包含個人隱私信息或涉及他人營私信息
|
||||
</option>
|
||||
<option value="5">動態可能涉及線下交易</option>
|
||||
<option value="6">動態內容無意義</option>
|
||||
<option value="7">動態內容與世界主題無關</option>
|
||||
@@ -109,32 +191,54 @@
|
||||
|
||||
<div class="form-group">
|
||||
<div class="col-sm-10">
|
||||
<textarea name="reason" id="reason" class="form-control" rows="3"></textarea>
|
||||
<textarea
|
||||
name="reason"
|
||||
id="reason"
|
||||
class="form-control"
|
||||
rows="3"
|
||||
></textarea>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
|
||||
<button type="button" class="btn btn-primary" id="not-pass-save">保存</button>
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">
|
||||
关闭
|
||||
</button>
|
||||
<button type="button" class="btn btn-primary" id="not-pass-save">
|
||||
保存
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal fade" id="showContentModal" tabindex="-1" role="dialog" aria-labelledby="modalLabe3">
|
||||
<div
|
||||
class="modal fade"
|
||||
id="showContentModal"
|
||||
tabindex="-1"
|
||||
role="dialog"
|
||||
aria-labelledby="modalLabe3"
|
||||
>
|
||||
<div class="modal-dialog" role="document">
|
||||
<div class="modal-content" style="width: 500px;">
|
||||
<div class="modal-content" style="width: 500px">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
|
||||
aria-hidden="true">×</span></button>
|
||||
<button
|
||||
type="button"
|
||||
class="close"
|
||||
data-dismiss="modal"
|
||||
aria-label="Close"
|
||||
>
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
<h4 class="modal-title" id="modalLabe3">查看动态内容详情</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<span id="dynamic-content"></span>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">
|
||||
关闭
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -142,68 +246,78 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import TableHelper from '@/utils/bootstrap-table-helper';
|
||||
import { showLoading, hideLoading } from '@/utils/maintainer';
|
||||
|
||||
import TableHelper from "@/utils/bootstrap-table-helper";
|
||||
import { showLoading, hideLoading } from "@/utils/maintainer";
|
||||
import { getPartitionInfoList } from "@/api/partition/partitionInfo";
|
||||
import { buildSelectOption } from "@/utils/system-helper";
|
||||
|
||||
var picker1 = $("#beginDate").datetimepicker({
|
||||
format: 'yyyy-mm-dd hh:ii:00',
|
||||
format: "yyyy-mm-dd hh:ii:00",
|
||||
autoclose: true,
|
||||
todayBtn: true
|
||||
todayBtn: true,
|
||||
});
|
||||
var picker2 = $("#endDate").datetimepicker({
|
||||
format: 'yyyy-mm-dd hh:ii:00',
|
||||
format: "yyyy-mm-dd hh:ii:00",
|
||||
autoclose: true,
|
||||
todayBtn: true
|
||||
todayBtn: true,
|
||||
});
|
||||
picker1.on('changeDate', function () {
|
||||
var date = $('#beginDate').datetimepicker('getDate');
|
||||
picker2.datetimepicker('setStartDate', date);
|
||||
picker1.on("changeDate", function () {
|
||||
var date = $("#beginDate").datetimepicker("getDate");
|
||||
picker2.datetimepicker("setStartDate", date);
|
||||
});
|
||||
picker2.on('changeDate', function () {
|
||||
var date = $('#endDate').datetimepicker('getDate');
|
||||
picker1.datetimepicker('setEndDate', date);
|
||||
picker2.on("changeDate", function () {
|
||||
var date = $("#endDate").datetimepicker("getDate");
|
||||
picker1.datetimepicker("setEndDate", date);
|
||||
});
|
||||
export default {
|
||||
name: "DynamicVerifyView",
|
||||
setup() {
|
||||
|
||||
function setReason() {
|
||||
if ($("#quick_reason option:selected").val() != 9) {
|
||||
$("#reason").val($("#quick_reason option:selected").text());
|
||||
} else {
|
||||
$("#reason").val('');
|
||||
$("#reason").val("");
|
||||
}
|
||||
}
|
||||
|
||||
function showContent(note) {
|
||||
var content = $(note).parent().find('input').val();
|
||||
$('#dynamic-content').text(content);
|
||||
$('#showContentModal').modal('show');
|
||||
var content = $(note).parent().find("input").val();
|
||||
$("#dynamic-content").text(content);
|
||||
$("#showContentModal").modal("show");
|
||||
}
|
||||
|
||||
function showPic(resUrl, id) {
|
||||
var html = '<div style="width: 320px;">';
|
||||
console.log(resUrl);
|
||||
if (resUrl != null && resUrl != '' && resUrl != undefined) {
|
||||
if (resUrl != null && resUrl != "" && resUrl != undefined) {
|
||||
var resUrls = resUrl.split(",");
|
||||
for (var i = 0; i < resUrls.length; i++) {
|
||||
if (resUrls[i] != null && resUrls[i] != undefined && resUrls[i] != "") {
|
||||
html += '<img id="imgs" src="' + resUrls[i] + '" style="width: 100px;height: 100px;">';
|
||||
if (
|
||||
resUrls[i] != null &&
|
||||
resUrls[i] != undefined &&
|
||||
resUrls[i] != ""
|
||||
) {
|
||||
html +=
|
||||
'<img id="imgs" src="' +
|
||||
resUrls[i] +
|
||||
'" style="width: 100px;height: 100px;">';
|
||||
}
|
||||
}
|
||||
}
|
||||
html += '</div>';
|
||||
html += "</div>";
|
||||
// 打开编辑弹窗
|
||||
$("#showModal").modal('show');
|
||||
$("#showModal").modal("show");
|
||||
$("#dynamicId").val(id);
|
||||
$(".show").html(html);
|
||||
}
|
||||
|
||||
function showVideo(resUrl, id) {
|
||||
var html = '<video width="320" height="240" controls autoplay><source src="' + resUrl + '" type="video/mp4"></video>';
|
||||
var html =
|
||||
'<video width="320" height="240" controls autoplay><source src="' +
|
||||
resUrl +
|
||||
'" type="video/mp4"></video>';
|
||||
// 打开编辑弹窗
|
||||
$("#showModal").modal('show');
|
||||
$("#showModal").modal("show");
|
||||
$("#dynamicId").val(id);
|
||||
$(".show").html(html);
|
||||
}
|
||||
@@ -215,113 +329,168 @@ export default {
|
||||
setReason,
|
||||
showContent,
|
||||
showPic,
|
||||
showVideo
|
||||
showVideo,
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.$nextTick(function () {
|
||||
this.initData();
|
||||
this.initPartition();
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
initData() {
|
||||
|
||||
$(function () {
|
||||
$('#table').bootstrapTable('destroy');
|
||||
$("#table").bootstrapTable("destroy");
|
||||
setStatusSelectOption();
|
||||
setTypeSelectOption();
|
||||
$('#table').bootstrapTable({
|
||||
$("#table").bootstrapTable({
|
||||
columns: [
|
||||
//{field: 'id', title: 'id', align: 'center', width: '5%'},
|
||||
{ field: 'tmp', title: 'id', align: 'center', checkbox: true, width: '5%' },
|
||||
{ field: 'erbanNo', title: '平台号', align: 'center', width: '5%' },
|
||||
{ field: 'nick', title: '昵称', align: 'center', width: '5%' },
|
||||
{ field: 'gender', title: '性别', align: 'center', width: '5%' },
|
||||
{ field: 'worldName', title: '话题', align: 'center', width: '5%' },
|
||||
{
|
||||
field: 'content',
|
||||
title: '动态内容',
|
||||
align: 'center',
|
||||
width: '5%',
|
||||
field: "tmp",
|
||||
title: "id",
|
||||
align: "center",
|
||||
checkbox: true,
|
||||
width: "5%",
|
||||
},
|
||||
{ field: "erbanNo", title: "平台号", align: "center", width: "5%" },
|
||||
{ field: "nick", title: "昵称", align: "center", width: "5%" },
|
||||
{ field: "gender", title: "性别", align: "center", width: "5%" },
|
||||
{ field: "worldName", title: "话题", align: "center", width: "5%" },
|
||||
{
|
||||
field: "content",
|
||||
title: "动态内容",
|
||||
align: "center",
|
||||
width: "5%",
|
||||
formatter: function (val, row, index) {
|
||||
if (isEmpty(val)) {
|
||||
return "-";
|
||||
} else {
|
||||
if (val.length > 50) {
|
||||
var content = "<input type='hidden' id='input-content' value='" + val + "'>";
|
||||
return val.substring(0, 50) + "..." + content + "<button href='#' class='btn btn-sm' style='color: #00acd6;background:none' onclick=showContent(this) style='margin-left: 10px;'>查看更多</a>";
|
||||
var content =
|
||||
"<input type='hidden' id='input-content' value='" +
|
||||
val +
|
||||
"'>";
|
||||
return (
|
||||
val.substring(0, 50) +
|
||||
"..." +
|
||||
content +
|
||||
"<button href='#' class='btn btn-sm' style='color: #00acd6;background:none' onclick=showContent(this) style='margin-left: 10px;'>查看更多</a>"
|
||||
);
|
||||
} else {
|
||||
return val;
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
{
|
||||
field: 'resUrl',
|
||||
title: '图片/视频/语音',
|
||||
align: 'center',
|
||||
width: '5%',
|
||||
field: "resUrl",
|
||||
title: "图片/视频/语音",
|
||||
align: "center",
|
||||
width: "5%",
|
||||
formatter: function (val, row, index) {
|
||||
if (row.type == 1) {
|
||||
return '<audio controls="controls"><source src="' + val + '" type="audio/mpeg"></audio>';
|
||||
return (
|
||||
'<audio controls="controls"><source src="' +
|
||||
val +
|
||||
'" type="audio/mpeg"></audio>'
|
||||
);
|
||||
} else if (row.type == 2) {
|
||||
return "<button href='#' class='btn btn-sm' style='color: #00acd6;background:none' onclick=showPic('" + row.resUrl + "'," + row.id + ")>查看图片</button>";
|
||||
return (
|
||||
"<button href='#' class='btn btn-sm' style='color: #00acd6;background:none' onclick=showPic('" +
|
||||
row.resUrl +
|
||||
"'," +
|
||||
row.id +
|
||||
")>查看图片</button>"
|
||||
);
|
||||
} else if (row.type == 3) {
|
||||
return "<button href='#' class='btn btn-sm' style='color: #00acd6;background:none' onclick=showVideo('" + row.resUrl + "'," + row.id + ")>查看视频</button>";
|
||||
}
|
||||
return (
|
||||
"<button href='#' class='btn btn-sm' style='color: #00acd6;background:none' onclick=showVideo('" +
|
||||
row.resUrl +
|
||||
"'," +
|
||||
row.id +
|
||||
")>查看视频</button>"
|
||||
);
|
||||
}
|
||||
},
|
||||
},
|
||||
{
|
||||
field: 'createTime',
|
||||
title: '发布时间',
|
||||
align: 'center',
|
||||
width: '5%',
|
||||
valign: 'middle',
|
||||
field: "createTime",
|
||||
title: "发布时间",
|
||||
align: "center",
|
||||
width: "5%",
|
||||
valign: "middle",
|
||||
formatter: function (val, row, index) {
|
||||
if (val) {
|
||||
var date = new Date(val);
|
||||
return date.format("yyyy-MM-dd hh:mm:00");
|
||||
} else {
|
||||
return '-';
|
||||
}
|
||||
return "-";
|
||||
}
|
||||
},
|
||||
{ field: 'statusStr', title: '状态', align: 'center', width: '5%' },
|
||||
{ field: 'updateBy', title: '操作人', align: 'center', width: '5%' },
|
||||
},
|
||||
{ field: "statusStr", title: "状态", align: "center", width: "5%" },
|
||||
{
|
||||
field: 'updateTime',
|
||||
title: '操作时间',
|
||||
align: 'center',
|
||||
width: '5%',
|
||||
valign: 'middle',
|
||||
field: "updateBy",
|
||||
title: "操作人",
|
||||
align: "center",
|
||||
width: "5%",
|
||||
},
|
||||
{
|
||||
field: "updateTime",
|
||||
title: "操作时间",
|
||||
align: "center",
|
||||
width: "5%",
|
||||
valign: "middle",
|
||||
formatter: function (val, row, index) {
|
||||
if (val) {
|
||||
var date = new Date(val);
|
||||
return date.format("yyyy-MM-dd hh:mm:00");
|
||||
} else {
|
||||
return '-';
|
||||
}
|
||||
return "-";
|
||||
}
|
||||
},
|
||||
},
|
||||
{
|
||||
field: 'id',
|
||||
title: '操作',
|
||||
align: 'center',
|
||||
width: '5%',
|
||||
field: "id",
|
||||
title: "操作",
|
||||
align: "center",
|
||||
width: "5%",
|
||||
formatter: function (val, row, index) {
|
||||
var pass = '<button class="btn btn-sm btn-primary opt-pass" data-id=' + val + ' data-status=1>通 过</button>';
|
||||
var noPass = '<button class="btn btn-sm btn-danger opt-not-pass" data-id=' + val + ' data-status=2>不通过</button>';
|
||||
var shelve = '<button class="btn btn-sm btn-primary opt-pass" data-id=' + val + ' data-status=4>上 架</button>';
|
||||
var unshelve = '<button class="btn btn-sm btn-danger opt-not-pass" data-id=' + val + ' data-status=5>下 架</button>';
|
||||
var pass =
|
||||
'<button class="btn btn-sm btn-primary opt-pass" data-id=' +
|
||||
val +
|
||||
" data-status=1>通 过</button>";
|
||||
var noPass =
|
||||
'<button class="btn btn-sm btn-danger opt-not-pass" data-id=' +
|
||||
val +
|
||||
" data-status=2>不通过</button>";
|
||||
var shelve =
|
||||
'<button class="btn btn-sm btn-primary opt-pass" data-id=' +
|
||||
val +
|
||||
" data-status=4>上 架</button>";
|
||||
var unshelve =
|
||||
'<button class="btn btn-sm btn-danger opt-not-pass" data-id=' +
|
||||
val +
|
||||
" data-status=5>下 架</button>";
|
||||
if (row.status == 0) {
|
||||
return pass + '</br>' + noPass;
|
||||
} else if (row.status == 1 || row.status == 6 || row.status == 4) {
|
||||
return pass + "</br>" + noPass;
|
||||
} else if (
|
||||
row.status == 1 ||
|
||||
row.status == 6 ||
|
||||
row.status == 4
|
||||
) {
|
||||
return unshelve;
|
||||
} else if (row.status == 2 || row.status == 5 || row.status == 7) {
|
||||
} else if (
|
||||
row.status == 2 ||
|
||||
row.status == 5 ||
|
||||
row.status == 7
|
||||
) {
|
||||
return shelve;
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
],
|
||||
cache: false,
|
||||
striped: true,
|
||||
@@ -334,63 +503,66 @@ export default {
|
||||
//设置为undefined可以获取pageNumber,pageSize,searchText,sortName,sortOrder
|
||||
//设置为limit可以获取limit, offset, search, sort, order
|
||||
queryParamsType: "-",
|
||||
queryParams: function queryParams(params) { //设置查询参数
|
||||
queryParams: function queryParams(params) {
|
||||
//设置查询参数
|
||||
var param = {
|
||||
pageNumber: params.pageNumber,
|
||||
pageSize: params.pageSize,
|
||||
erbanNo: $('#erbanNo').val(),
|
||||
nick: $('#nick').val(),
|
||||
status: $('#status').val(),
|
||||
beginDate: $('#beginDate').val(),
|
||||
endDate: $('#endDate').val(),
|
||||
wolrdId: $('#wolrdId').val(),
|
||||
erbanNo: $("#erbanNo").val(),
|
||||
nick: $("#nick").val(),
|
||||
status: $("#status").val(),
|
||||
beginDate: $("#beginDate").val(),
|
||||
endDate: $("#endDate").val(),
|
||||
wolrdId: $("#wolrdId").val(),
|
||||
partitionId: $("#partitionId").val(),
|
||||
};
|
||||
return param;
|
||||
},
|
||||
toolbar: '#toolbar',
|
||||
url: '/admin/dynamic/verify/list',
|
||||
onLoadSuccess: function () { //加载成功时执行
|
||||
toolbar: "#toolbar",
|
||||
url: "/admin/dynamic/verify/list",
|
||||
onLoadSuccess: function () {
|
||||
//加载成功时执行
|
||||
console.log("load success");
|
||||
},
|
||||
onLoadError: function () { //加载失败时执行
|
||||
onLoadError: function () {
|
||||
//加载失败时执行
|
||||
console.log("load fail");
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
// 查询刷新
|
||||
$('#btnSearch').on('click', function () {
|
||||
TableHelper.doRefresh('#table');
|
||||
$("#btnSearch").on("click", function () {
|
||||
TableHelper.doRefresh("#table");
|
||||
});
|
||||
|
||||
//重置
|
||||
$('#btnReset').on('click', function () {
|
||||
$('#erbanNo').val("");
|
||||
$('#nick').val("");
|
||||
$('#status').val("");
|
||||
$('#beginDate').val("");
|
||||
$('#endDate').val("");
|
||||
$('#wolrdId').val("");
|
||||
$("#btnReset").on("click", function () {
|
||||
$("#erbanNo").val("");
|
||||
$("#nick").val("");
|
||||
$("#status").val("");
|
||||
$("#beginDate").val("");
|
||||
$("#endDate").val("");
|
||||
$("#wolrdId").val("");
|
||||
});
|
||||
|
||||
//审核不通过/下架弹框
|
||||
$("#table").on("click", '.opt-not-pass', function () {
|
||||
|
||||
$("#table").on("click", ".opt-not-pass", function () {
|
||||
var id = $(this).attr("data-id");
|
||||
var status = $(this).attr("data-status");
|
||||
if (id == 'undefined') {
|
||||
if (id == "undefined") {
|
||||
$("#tipMsg").text("id参数有误");
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipModal").modal("show");
|
||||
return;
|
||||
}
|
||||
if (status == 'undefined') {
|
||||
if (status == "undefined") {
|
||||
$("#tipMsg").text("状态参数有误");
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipModal").modal("show");
|
||||
return;
|
||||
}
|
||||
$("#dynamicId1").val(id);
|
||||
$("#status1").val(status);
|
||||
// 打开编辑弹窗
|
||||
$("#notPassModal").modal('show');
|
||||
$("#notPassModal").modal("show");
|
||||
$("#modalLabe2").text("请选择不通过的原因");
|
||||
status = 5;
|
||||
if (status) {
|
||||
@@ -401,15 +573,15 @@ export default {
|
||||
//审核不通过/下架弹窗
|
||||
$("#not-pass-save").click(function () {
|
||||
var id = $("#dynamicId1").val();
|
||||
if (id == 'undefined') {
|
||||
if (id == "undefined") {
|
||||
$("#tipMsg").text("id参数有误");
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipModal").modal("show");
|
||||
return;
|
||||
}
|
||||
var status = $("#status1").val();
|
||||
if (status == 'undefined') {
|
||||
if (status == "undefined") {
|
||||
$("#tipMsg").text("状态参数有误");
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipModal").modal("show");
|
||||
return;
|
||||
}
|
||||
var reason = $("#reason").val();
|
||||
@@ -424,18 +596,17 @@ export default {
|
||||
verify(text, id, status, reason);
|
||||
});
|
||||
|
||||
$("#table").on("click", '.opt-pass', function () {
|
||||
|
||||
$("#table").on("click", ".opt-pass", function () {
|
||||
var id = $(this).attr("data-id");
|
||||
var status = $(this).attr("data-status");
|
||||
if (id == 'undefined') {
|
||||
if (id == "undefined") {
|
||||
$("#tipMsg").text("id参数有误");
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipModal").modal("show");
|
||||
return;
|
||||
}
|
||||
if (status == 'undefined') {
|
||||
if (status == "undefined") {
|
||||
$("#tipMsg").text("状态参数有误");
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipModal").modal("show");
|
||||
return;
|
||||
}
|
||||
var text = "通过";
|
||||
@@ -445,40 +616,60 @@ export default {
|
||||
verify(text, id, status, "");
|
||||
});
|
||||
//导出
|
||||
$('#btnExport').on('click', function () {
|
||||
var erbanNo = $('#erbanNo').val();
|
||||
var nick = $('#nick').val();
|
||||
var status = $('#status').val();
|
||||
var beginDate = $('#beginDate').val();
|
||||
var endDate = $('#endDate').val();
|
||||
var wolrdId = $('#wolrdId').val();
|
||||
if (isEmpty(erbanNo) && isEmpty(nick) && isEmpty(status) && isEmpty(beginDate) && isEmpty(endDate) && isEmpty(wolrdId)) {
|
||||
$("#btnExport").on("click", function () {
|
||||
var erbanNo = $("#erbanNo").val();
|
||||
var nick = $("#nick").val();
|
||||
var status = $("#status").val();
|
||||
var beginDate = $("#beginDate").val();
|
||||
var endDate = $("#endDate").val();
|
||||
var wolrdId = $("#wolrdId").val();
|
||||
if (
|
||||
isEmpty(erbanNo) &&
|
||||
isEmpty(nick) &&
|
||||
isEmpty(status) &&
|
||||
isEmpty(beginDate) &&
|
||||
isEmpty(endDate) &&
|
||||
isEmpty(wolrdId)
|
||||
) {
|
||||
$("#tipMsg").text("请输入导出条件!");
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipModal").modal("show");
|
||||
return;
|
||||
}
|
||||
$('#searchForm').submit();
|
||||
$("#searchForm").submit();
|
||||
});
|
||||
//图片放大
|
||||
$('#showModal').on('mouseenter', '#imgs', function (e) {
|
||||
var src = $(this).attr('src');
|
||||
$('#imgMask img').attr('src', src);
|
||||
$('#imgMask').show();
|
||||
$('#imgMask').css({
|
||||
$("#showModal").on("mouseenter", "#imgs", function (e) {
|
||||
var src = $(this).attr("src");
|
||||
$("#imgMask img").attr("src", src);
|
||||
$("#imgMask").show();
|
||||
$("#imgMask").css({
|
||||
top: e.clientY + 20,
|
||||
})
|
||||
})
|
||||
$('#showModal').on('mouseleave', '#imgs', function (e) {
|
||||
console.log('移出');
|
||||
$('#imgMask').hide();
|
||||
})
|
||||
});
|
||||
}
|
||||
});
|
||||
$("#showModal").on("mouseleave", "#imgs", function (e) {
|
||||
console.log("移出");
|
||||
$("#imgMask").hide();
|
||||
});
|
||||
});
|
||||
},
|
||||
initPartition() {
|
||||
getPartitionInfoList().then((res) => {
|
||||
let data = res.data;
|
||||
buildSelectOption(
|
||||
"#partitionId",
|
||||
4,
|
||||
data.map((v) => {
|
||||
return {
|
||||
value: v.id,
|
||||
text: v.desc,
|
||||
};
|
||||
})
|
||||
);
|
||||
});
|
||||
},
|
||||
},
|
||||
|
||||
};
|
||||
|
||||
|
||||
//判断空值
|
||||
function isEmpty(data) {
|
||||
if (data == null || data == undefined || data == "") {
|
||||
@@ -491,40 +682,40 @@ function verify(text, id, status, reason) {
|
||||
//if (confirm("你确认【"+ text + "】该动态吗?")) {
|
||||
showLoading();
|
||||
$.ajax({
|
||||
type: 'post',
|
||||
type: "post",
|
||||
url: "/admin/dynamic/verify/changeStatus",
|
||||
data: {
|
||||
dynamicId: id,
|
||||
status: status,
|
||||
reason: reason
|
||||
reason: reason,
|
||||
},
|
||||
dataType: "json",
|
||||
success: function (json) {
|
||||
hideLoading();
|
||||
if (status == 2 || status == 5) {
|
||||
$("#notPassModal").modal('hide');
|
||||
$("#notPassModal").modal("hide");
|
||||
}
|
||||
if (json.success == 'true') {
|
||||
if (json.success == "true") {
|
||||
$("#tipMsg").text("操作成功");
|
||||
$("#tipModal").modal('show');
|
||||
$("#tipModal").modal("show");
|
||||
TableHelper.doRefresh("#table");
|
||||
} else {
|
||||
$("#tipMsg").text("操作失败");
|
||||
$("#tipModal").modal('show');
|
||||
}
|
||||
$("#tipModal").modal("show");
|
||||
}
|
||||
},
|
||||
});
|
||||
//}
|
||||
}
|
||||
|
||||
function setTypeSelectOption() {
|
||||
$.ajax({
|
||||
type: 'get',
|
||||
type: "get",
|
||||
url: "/admin/world/list",
|
||||
data: {
|
||||
status: 1,
|
||||
pageNumber: 1,
|
||||
pageSize: 1000
|
||||
pageSize: 1000,
|
||||
},
|
||||
dataType: "json",
|
||||
success: function (json) {
|
||||
@@ -533,28 +724,32 @@ function setTypeSelectOption() {
|
||||
for (var i = 0; i < rows.length; i++) {
|
||||
let item = rows[i];
|
||||
let name = item.name;
|
||||
if (name.startsWith('{') && name.endsWith('}')) {
|
||||
if (name.startsWith("{") && name.endsWith("}")) {
|
||||
name = JSON.parse(name).zh;
|
||||
}
|
||||
$('#wolrdId').append('<option value="' + rows[i].id + '">' + name + '</option>');
|
||||
}
|
||||
$("#wolrdId").append(
|
||||
'<option value="' + rows[i].id + '">' + name + "</option>"
|
||||
);
|
||||
}
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
function setStatusSelectOption() {
|
||||
$.ajax({
|
||||
type: 'get',
|
||||
type: "get",
|
||||
url: "/admin/dynamic/verify/getStatus",
|
||||
success: function (json) {
|
||||
if (json != null && json != undefined) {
|
||||
var rows = json;
|
||||
for (var i = 0; i < rows.length; i++) {
|
||||
$('#status').append('<option value="' + rows[i].value + '">' + rows[i].key + '</option>');
|
||||
}
|
||||
$("#status").append(
|
||||
'<option value="' + rows[i].value + '">' + rows[i].key + "</option>"
|
||||
);
|
||||
}
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
</script>
|
||||
|
Reference in New Issue
Block a user