Initial commit
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,142 @@
|
||||
<template>
|
||||
<div class="tags-box">
|
||||
<el-dialog
|
||||
:title="'图集详情'"
|
||||
:visible.sync="dialogVisible"
|
||||
:width="width"
|
||||
:before-close="handleClose"
|
||||
:close-on-click-modal="false"
|
||||
>
|
||||
<div class="picturePopup" :style="{ overflow: over }">
|
||||
<div v-for="(item, i) in pictureList" :key="i" class="pictureInside">
|
||||
<decrypt-img
|
||||
style="width: 180px; height: 180px"
|
||||
:src="imgUrl + item.src"
|
||||
fit="fill"
|
||||
></decrypt-img>
|
||||
<!-- <base-upload
|
||||
:cover="item.src"
|
||||
:action="action"
|
||||
@successCallback="item.successCallback"
|
||||
:wSize="360"
|
||||
:hSize="480"
|
||||
:width="'180px'"
|
||||
:height="'180px'"
|
||||
:hide="true"
|
||||
></base-upload> -->
|
||||
<!-- <el-button type="danger" icon="el-icon-delete" circle size="small" class="deleteButton" @click="deletePicture(i)"></el-button> -->
|
||||
</div>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import baseConfig from "@/utils/serverUrlConfig";
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
id: "",
|
||||
tags: [],
|
||||
flag: false,
|
||||
dialogVisible: false,
|
||||
// 封面上传地址
|
||||
action: baseConfig.baseServerUrl + "/vid/uploadStatic",
|
||||
imgUrl: baseConfig.imgUrl,
|
||||
pictureList: [],
|
||||
picturePopupLength: ["240px", "430px", "620px"],
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
width() {
|
||||
if (this.pictureList.length < 4 && this.pictureList.length > 0) {
|
||||
return this.picturePopupLength[this.pictureList.length - 1];
|
||||
} else if (this.pictureList.length < 10) {
|
||||
return "620px";
|
||||
} else {
|
||||
return "640px";
|
||||
}
|
||||
},
|
||||
over() {
|
||||
return this.pictureList.length < 10 ? "hidden" : "auto";
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
// 封面图上传成功回调
|
||||
successCallback(res) {
|
||||
this.params.cover = res.data.coverImg;
|
||||
},
|
||||
// 删除某张图片
|
||||
deletePicture(i) {
|
||||
if (this.pictureList.length === 1) {
|
||||
this.$message.error("请至少保留一张!");
|
||||
return;
|
||||
}
|
||||
this.pictureList.splice(i, 1);
|
||||
},
|
||||
// 新增图片
|
||||
addPicture() {
|
||||
let obj = {
|
||||
src: "",
|
||||
successCallback(res) {
|
||||
obj.src = res.data.coverImg;
|
||||
},
|
||||
};
|
||||
this.pictureList.push(obj);
|
||||
},
|
||||
// 打开弹窗并初始化tags数据
|
||||
open(pictureArr) {
|
||||
this.dialogVisible = true;
|
||||
let arr = [];
|
||||
for (var i = 0; i < pictureArr.length; i++) {
|
||||
let obj = {
|
||||
src: pictureArr[i],
|
||||
successCallback(res) {
|
||||
obj.src = res.data.coverImg;
|
||||
},
|
||||
};
|
||||
arr.push(obj);
|
||||
}
|
||||
this.pictureList = arr;
|
||||
},
|
||||
// 关闭弹窗
|
||||
handleClose() {
|
||||
this.dialogVisible = false;
|
||||
this.pictureList = [];
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style scoped lang="scss">
|
||||
.tags-box {
|
||||
.el-dialog {
|
||||
padding: 0 !important;
|
||||
margin: 0 !important;
|
||||
}
|
||||
.input-box {
|
||||
margin-top: 15px;
|
||||
text-align: left;
|
||||
}
|
||||
.el-input {
|
||||
width: 200px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
.picturePopup {
|
||||
border: solid 5px white;
|
||||
margin: 0 auto;
|
||||
display: flex;
|
||||
justify-content: flex-start;
|
||||
flex-wrap: wrap;
|
||||
max-height: 580px;
|
||||
.pictureInside {
|
||||
margin: 5px;
|
||||
position: relative;
|
||||
.deleteButton {
|
||||
position: absolute;
|
||||
opacity: 0.5;
|
||||
top: 0;
|
||||
right: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,125 @@
|
||||
<template>
|
||||
<div class="table-box">
|
||||
<el-table :data="tableData" border style="width: 100%">
|
||||
<el-table-column prop="id" label="ID" width="220"> </el-table-column>
|
||||
<el-table-column prop="mid" label="模块id" width="210"> </el-table-column>
|
||||
<el-table-column prop="title" label="标题" width="180"> </el-table-column>
|
||||
<el-table-column prop="businessHours" width="130" label="连线时间">
|
||||
</el-table-column>
|
||||
<el-table-column prop="contact" width="100" label="联系方式">
|
||||
</el-table-column>
|
||||
<el-table-column prop="cover" label="封面">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="!scope.row.cover">未知</span>
|
||||
<div
|
||||
v-else
|
||||
class="picturePreview"
|
||||
@click="checkMedia(imgUrl + scope.row.cover, 'img')"
|
||||
>
|
||||
<decrypt-img
|
||||
style="width: 50px; height: 80px"
|
||||
:src="imgUrl + scope.row.cover"
|
||||
fit="fill"
|
||||
></decrypt-img>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="fakeSaleNum" width="130" label="销售数量(假)">
|
||||
</el-table-column>
|
||||
<el-table-column prop="cup" width="50" label="罩杯"> </el-table-column>
|
||||
<el-table-column prop="age" width="50" label="年龄"> </el-table-column>
|
||||
<el-table-column prop="weight" label="体重(KG)"> </el-table-column>
|
||||
<el-table-column prop="height" width="50" label="身高"> </el-table-column>
|
||||
<el-table-column prop="images" label="图片列表">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="!scope.row.images || !scope.row.images.length">未知</span>
|
||||
<div
|
||||
v-else
|
||||
class="picturePreview"
|
||||
@click="previewPicture(scope.row.images)"
|
||||
>
|
||||
<decrypt-img
|
||||
style="width: 50px; height: 80px"
|
||||
:src="imgUrl + scope.row.images[0]"
|
||||
fit="fill"
|
||||
></decrypt-img>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="options" width="110" label="可供购买选项">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ "" + scope.row.options }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="price" label="价格(n金币/分钟)"> </el-table-column>
|
||||
<el-table-column prop="saleNum" label="销售数量"> </el-table-column>
|
||||
<el-table-column prop="sortCode" label="排序号"> </el-table-column>
|
||||
<el-table-column prop="status" width="110" label="上架/下架">
|
||||
<template slot-scope="scope">
|
||||
<el-tag :type="scope.row.status ? 'success' : ''">{{
|
||||
scope.row.status == 1 ? "上架" : "下架"
|
||||
}}</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="summary" width="180" label="简介">
|
||||
</el-table-column>
|
||||
<el-table-column prop="video" width="100" label="展示的视频">
|
||||
<template slot-scope="scope">
|
||||
<i
|
||||
class="el-icon-video-play views"
|
||||
title="点击预览"
|
||||
@click="checkMedia(scope.row.video, 'video')"
|
||||
v-if="scope.row.video && scope.row.video.length > 0"
|
||||
></i>
|
||||
<span v-else>暂无</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column width="160" prop="createdAt" label="文档创建时间">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.createdAt | changeDate }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column width="160" prop="updatedAt" label="文档更新时间">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.updatedAt | changeDate }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<media-popup ref="mediaPopup"></media-popup>
|
||||
<!-- 图集预览窗口 -->
|
||||
<preview-picture ref="previewPicture"></preview-picture>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import baseConfig from "@/utils/serverUrlConfig";
|
||||
import MediaPopup from "@/components/media-popup";
|
||||
import PreviewPicture from "./PreviewPicture";
|
||||
export default {
|
||||
props: {
|
||||
tableData: {
|
||||
type: Array,
|
||||
default: () => [],
|
||||
},
|
||||
},
|
||||
components: {
|
||||
MediaPopup,
|
||||
PreviewPicture,
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
imgUrl: baseConfig.imgUrl,
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
checkMedia(url, type) {
|
||||
this.$refs.mediaPopup.open(url, type);
|
||||
},
|
||||
// 图集预览
|
||||
previewPicture(pictureArr) {
|
||||
const Arr = JSON.parse(JSON.stringify(pictureArr));
|
||||
this.$refs.previewPicture.open(Arr);
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
@@ -0,0 +1,115 @@
|
||||
<template>
|
||||
<div class="edit-video-box">
|
||||
<el-dialog
|
||||
title="状态修改"
|
||||
:visible.sync="dialogVisible"
|
||||
width="400px"
|
||||
:before-close="handleClose"
|
||||
:close-on-click-modal="false"
|
||||
>
|
||||
<el-form
|
||||
ref="form"
|
||||
:model="form"
|
||||
:rules="rules"
|
||||
inline
|
||||
label-position="left"
|
||||
label-width="86px"
|
||||
>
|
||||
<el-form-item label="状态:" prop="status">
|
||||
<el-select
|
||||
v-model="form.status"
|
||||
placeholder="请选择"
|
||||
size="small"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in statusOptions"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="handleClose" size="small">取 消</el-button>
|
||||
<el-button
|
||||
type="primary"
|
||||
size="small"
|
||||
@click="submitDate"
|
||||
:loading="flag"
|
||||
>确 认</el-button
|
||||
>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import API from "@/api";
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
flag: false,
|
||||
dialogVisible: false,
|
||||
form: {
|
||||
status: "",
|
||||
id: ""
|
||||
},
|
||||
statusOptions: [
|
||||
{ label: "已完成", value: 1 },
|
||||
{ label: "已下单", value: 0 },
|
||||
],
|
||||
rules: {
|
||||
status: [
|
||||
{
|
||||
required: true,
|
||||
message: "请选择状态",
|
||||
trigger: ["blur", "change"],
|
||||
},
|
||||
],
|
||||
},
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
submitDate() {
|
||||
this.$refs.form.validate((valid) => {
|
||||
if (valid) {
|
||||
this.$confirm(`确定修改状态?`, "提示", {
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
type: "warning",
|
||||
}).then(() => {
|
||||
this.flag = true;
|
||||
API.updateNakedchatorder(this.form)
|
||||
.then((res) => {
|
||||
if (res.code === 200) {
|
||||
this.$message({
|
||||
message: "修改成功",
|
||||
type: "success",
|
||||
});
|
||||
this.handleClose();
|
||||
this.$emit("close");
|
||||
} else {
|
||||
this.$message.error("修改失败!");
|
||||
}
|
||||
})
|
||||
.finally(() => {
|
||||
this.flag = false;
|
||||
});
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
handleClose() {
|
||||
this.flag = false;
|
||||
this.form.status = "";
|
||||
this.form.id = "";
|
||||
this.dialogVisible = false;
|
||||
this.$refs.form.resetFields();
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped></style>
|
||||
@@ -0,0 +1,323 @@
|
||||
<template>
|
||||
<div class="louFeng-box">
|
||||
<!--操作栏-->
|
||||
<div class="action-bar">
|
||||
<el-input
|
||||
placeholder="裸聊id"
|
||||
v-model.trim="params.nid"
|
||||
clearable
|
||||
size="small"
|
||||
class="param-input"
|
||||
>
|
||||
</el-input>
|
||||
<el-input
|
||||
placeholder="订单id"
|
||||
v-model.number="params.orderId"
|
||||
clearable
|
||||
size="small"
|
||||
class="param-input"
|
||||
>
|
||||
</el-input>
|
||||
<el-input
|
||||
placeholder="请输入用户id"
|
||||
v-model.number="params.uid"
|
||||
clearable
|
||||
size="small"
|
||||
class="param-input"
|
||||
>
|
||||
</el-input>
|
||||
<!-- <el-select placeholder="是否使用" v-model="params.isUse" size="small" clearable style="width:200px;margin-right:5px">
|
||||
<el-option :value="true" label="已使用" key="已使用"></el-option>
|
||||
<el-option :value="false" label="未使用" key="未使用"></el-option>
|
||||
</el-select> -->
|
||||
<el-button
|
||||
type="primary"
|
||||
size="small"
|
||||
@click="getNakedChatBuyList('status')"
|
||||
style="margin-right: 20px"
|
||||
>搜索
|
||||
</el-button>
|
||||
</div>
|
||||
<!--数据表格-->
|
||||
<el-table
|
||||
:data="tableData"
|
||||
style="width: 100%"
|
||||
border
|
||||
v-loading="loading"
|
||||
element-loading-text="拼命加载中"
|
||||
element-loading-spinner="el-icon-loading"
|
||||
ref="multipleTable"
|
||||
height="550"
|
||||
>
|
||||
<el-table-column
|
||||
prop="id"
|
||||
label="ID"
|
||||
align="center"
|
||||
fixed
|
||||
min-width="210"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.id || "未知" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="uid" label="用户ID" align="center" min-width="100">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.uid || "未知" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="userContact" label="用户联系方式" align="center" min-width="120">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.userContact || "未知" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="amount"
|
||||
label="总额"
|
||||
align="center"
|
||||
min-width="100"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.amount }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="num"
|
||||
label="购买数量"
|
||||
align="center"
|
||||
min-width="100"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.num }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="nid" label="裸聊id" align="center" min-width="100">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.nid || "-" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="status"
|
||||
label="状态"
|
||||
align="center"
|
||||
min-width="100"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
v-if="scope.row.status == 0"
|
||||
size="small"
|
||||
type="success"
|
||||
disabled
|
||||
>已下单</el-button
|
||||
>
|
||||
<el-button
|
||||
v-else-if="scope.row.status == 1"
|
||||
size="small"
|
||||
type="warning"
|
||||
@click="confirmUseCode(scope.row)"
|
||||
>已完成</el-button
|
||||
>
|
||||
<span v-else>-</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="price"
|
||||
label="购买的单价"
|
||||
align="center"
|
||||
min-width="100"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.price }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="remark"
|
||||
label="订单备注信息"
|
||||
align="center"
|
||||
min-width="140"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.remark }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="snapshot"
|
||||
label="快照"
|
||||
align="center"
|
||||
min-width="100"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<el-button slot="reference" @click="clickSnapshort(scope.row.snapshot)" type="success" size="small"
|
||||
>快照查看</el-button
|
||||
>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="createdAt"
|
||||
label="创建时间"
|
||||
align="center"
|
||||
min-width="200"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.createdAt | changeDate }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="updatedAt"
|
||||
label="修改时间"
|
||||
align="center"
|
||||
min-width="200"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.updatedAt | changeDate }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
label="操作"
|
||||
align="center"
|
||||
fixed="right"
|
||||
min-width="100"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
type="success"
|
||||
size="mini"
|
||||
icon="el-icon-edit"
|
||||
@click="editChat(scope.row)"
|
||||
></el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!--分页组件-->
|
||||
<el-pagination
|
||||
:page-sizes="[10, 15, 20, 30]"
|
||||
:current-page="params.pageNumber"
|
||||
:page-size="params.pageSize"
|
||||
layout="total, sizes, prev, pager, next, jumper"
|
||||
:total="total"
|
||||
background
|
||||
v-if="total > 10"
|
||||
@size-change="changeSize"
|
||||
@current-change="changeCurrent"
|
||||
></el-pagination>
|
||||
<el-drawer title="快照" :visible.sync="snapShortShow" direction="rtl" size="70%">
|
||||
<SnapShortTable
|
||||
:tableData="snapShortData"
|
||||
/>
|
||||
</el-drawer>
|
||||
<UpdateStatusPopup ref="updateStatusPopup" @close="getNakedChatBuyList"/>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import API from "@/api";
|
||||
import SnapShortTable from "./components/SnapShortTable";
|
||||
import UpdateStatusPopup from "./components/UpdateStatusPopup"
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
snapShortShow: false,
|
||||
snapShortData: [],
|
||||
// 表格数据加载动画
|
||||
loading: false,
|
||||
// 列表数据
|
||||
tableData: [],
|
||||
total: 0,
|
||||
// 系统管理列表请求参数
|
||||
params: {
|
||||
pageNumber: 1,
|
||||
pageSize: 10,
|
||||
uid: "",
|
||||
orderId: "", //订单ID
|
||||
nid: "", //裸聊id
|
||||
// isUse: undefined,//是否使用
|
||||
},
|
||||
dialogVisible: false,
|
||||
};
|
||||
},
|
||||
components: { SnapShortTable, UpdateStatusPopup },
|
||||
created() {
|
||||
this.getNakedChatBuyList();
|
||||
},
|
||||
methods: {
|
||||
editChat(row) {
|
||||
this.$refs.updateStatusPopup.form.status = row.status;
|
||||
this.$refs.updateStatusPopup.form.id = row.id;
|
||||
this.$refs.updateStatusPopup.dialogVisible = true;
|
||||
},
|
||||
clickSnapshort(data) {
|
||||
if(!data) return;
|
||||
this.snapShortData = [data]
|
||||
this.snapShortShow = true;
|
||||
},
|
||||
// 请求列表
|
||||
getNakedChatBuyList(type) {
|
||||
this.loading = true;
|
||||
if (type === "status") {
|
||||
this.params.pageNumber = 1;
|
||||
}
|
||||
API.getNakedChatBuyList(this.params)
|
||||
.then((res) => {
|
||||
if (res.code === 200 && res.data) {
|
||||
this.tableData = res.data.list;
|
||||
this.total = res.data.total;
|
||||
} else {
|
||||
this.tableData = [];
|
||||
}
|
||||
this.loading = false;
|
||||
})
|
||||
.catch(() => {
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
confirmUseCode(row) {
|
||||
this.$confirm("确认该裸聊已使用?", "提示", {
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
type: "warning",
|
||||
}).then(() => {
|
||||
const params = Object.assign(
|
||||
{},
|
||||
{
|
||||
id: row.id,
|
||||
}
|
||||
);
|
||||
API.confirmUseCode(params)
|
||||
.then((res) => {
|
||||
if (res.code === 200) {
|
||||
this.$message({
|
||||
message: "确认成功",
|
||||
type: "success",
|
||||
});
|
||||
this.getNakedChatBuyList();
|
||||
} else {
|
||||
this.$message.error("确认失败!");
|
||||
}
|
||||
})
|
||||
.catch(() => {
|
||||
this.flag = false;
|
||||
this.getNakedChatBuyList();
|
||||
this.$message.error("确认失败!");
|
||||
});
|
||||
});
|
||||
},
|
||||
// 分页条数改变回掉
|
||||
changeSize(size) {
|
||||
this.params.pageSize = size;
|
||||
this.getNakedChatBuyList();
|
||||
},
|
||||
// 分页页码改变回掉
|
||||
changeCurrent(pageNumber) {
|
||||
this.params.pageNumber = pageNumber;
|
||||
this.getNakedChatBuyList();
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.payMethod {
|
||||
.add-input {
|
||||
margin-left: 0 !important;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,150 @@
|
||||
<template>
|
||||
<div class="edit-video-box">
|
||||
<el-dialog
|
||||
:title="title1"
|
||||
:visible.sync="dialogVisible"
|
||||
width="350px"
|
||||
:before-close="handleClose"
|
||||
:close-on-click-modal="false"
|
||||
>
|
||||
<el-form
|
||||
ref="form"
|
||||
:model="params"
|
||||
:rules="rules"
|
||||
label-width="90px"
|
||||
:label-position="labelPosition"
|
||||
>
|
||||
<el-form-item label="回执信息:" prop="receipt">
|
||||
<el-input
|
||||
v-model="params.receipt"
|
||||
size="small"
|
||||
type="textarea"
|
||||
:rows="4"
|
||||
placeholder="回执信息"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" style="text-align:center">
|
||||
<el-button @click="handleClose" size="small">取 消</el-button>
|
||||
<el-button type="primary" @click="submitForm('form')" :loading="flag" size="small">确 认</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import API from "@/api";
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
labelPosition: "left",
|
||||
dialogVisible: false,
|
||||
title1: "",
|
||||
flag: false,
|
||||
id: "",
|
||||
// 审核通过/拒绝 表单数据
|
||||
params: {
|
||||
receipt: "",
|
||||
type:'',
|
||||
nudeChatId: "",
|
||||
},
|
||||
|
||||
// 表单验证规则
|
||||
rules: {
|
||||
receipt: [
|
||||
{ required: true, message: "请填写回执信息", trigger: "blur" },
|
||||
],
|
||||
},
|
||||
};
|
||||
},
|
||||
|
||||
methods: {
|
||||
// 表单验证提交
|
||||
submitForm() {
|
||||
this.$refs.form.validate((valid) => {
|
||||
if (valid) {
|
||||
this.flag = true;
|
||||
this.passReview();
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
});
|
||||
},
|
||||
// 通过
|
||||
passReview() {
|
||||
let params = Object.assign({}, this.params, {
|
||||
id: this.id,
|
||||
processingStatus:1
|
||||
});
|
||||
API.operateFeedback(params)
|
||||
.then((res) => {
|
||||
if (res.code === 200) {
|
||||
this.$message({
|
||||
message: "操作成功",
|
||||
type: "success",
|
||||
});
|
||||
this.$emit("handlerAgentList");
|
||||
} else {
|
||||
if (res.tip) {
|
||||
this.$message.error(res.tip);
|
||||
} else {
|
||||
this.$message.error("操作失败");
|
||||
}
|
||||
}
|
||||
this.handleClose();
|
||||
this.flag = false;
|
||||
})
|
||||
.catch(() => {
|
||||
this.handleClose();
|
||||
this.flag = false;
|
||||
});
|
||||
},
|
||||
|
||||
|
||||
// 关闭弹窗
|
||||
handleClose() {
|
||||
this.dialogVisible = false;
|
||||
this.$refs.form.resetFields();
|
||||
this.params = {
|
||||
receipt: "",
|
||||
type:'',
|
||||
nudeChatId: "",
|
||||
};
|
||||
this.id = "";
|
||||
},
|
||||
// 打开编辑视频弹窗、传递需要编辑的参数
|
||||
open( data) {
|
||||
this.dialogVisible = true;
|
||||
this.id = data.id;
|
||||
this.title1 = "回复操作";
|
||||
this.params.receipt = data.receipt ? data.receipt : '该信息已经下架!请联系官方客服获取新的裸聊信息!';
|
||||
this.params.type = 1;
|
||||
this.params.nudeChatId = data.nudeChatId;
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.edit-video-box {
|
||||
.item-box {
|
||||
margin-left: 28px;
|
||||
width: 100%;
|
||||
display: flex;
|
||||
.item1 {
|
||||
flex: 1;
|
||||
.upload {
|
||||
position: relative;
|
||||
top: 35px;
|
||||
left: -90px;
|
||||
}
|
||||
}
|
||||
.item2 {
|
||||
flex: 3;
|
||||
width: 250px;
|
||||
position: relative;
|
||||
top: 0px;
|
||||
left: -60px;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,164 @@
|
||||
<template>
|
||||
<div class="add-pay-box">
|
||||
<el-dialog title="楼凤详情页" :visible.sync="dialogVisible" width="90%" :before-close="handleClose" :close-on-click-modal="false">
|
||||
<el-table :data="tableData" style="width: 100%" border ref="multipleTable" >
|
||||
<el-table-column prop="title" label="标题" align="center" min-width="100">
|
||||
<template slot-scope="scope">
|
||||
<span>{{scope.row.title }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="cover" label="封面" align="center" width="200">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="!scope.row.cover || !scope.row.cover.length">未知</span>
|
||||
<div
|
||||
v-else
|
||||
class="picturePreview"
|
||||
@click="previewPicture(scope.row.cover, scope.row.id)"
|
||||
>
|
||||
<decrypt-img
|
||||
style="width: 50px; height: 50px"
|
||||
:src="imgUrl + item"
|
||||
fit="fill"
|
||||
v-for="(item,i) in scope.row.cover"
|
||||
:key="i"
|
||||
></decrypt-img>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="city" label="城市" align="center" min-width="100">
|
||||
<template slot-scope="scope">
|
||||
<span>{{scope.row.city || '未知'}}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="district" label="区,县" align="center" min-width="100">
|
||||
<template slot-scope="scope">
|
||||
<span>{{scope.row.district}}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="age" label="年龄" align="center" min-width="100">
|
||||
<template slot-scope="scope">
|
||||
<span>{{(scope.row.age|| '未知') }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="contact" label="联系方式" align="center" min-width="260">
|
||||
<template slot-scope="scope">
|
||||
<span>{{scope.row.contact }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-dialog>
|
||||
<!-- 背景图集预览窗口 -->
|
||||
<preview-picture ref="previewPicture" @handlerChannelList="getLouFengList"></preview-picture>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import API from '@/api'
|
||||
import baseConfig from '@/utils/serverUrlConfig'
|
||||
import PreviewPicture from '../components/previewPicture'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
//图集上传
|
||||
action: baseConfig.baseServerUrl + '/vid/uploadStaticBatch',
|
||||
imgUrl: baseConfig.imgUrl,
|
||||
dialogVisible: false,
|
||||
tableData:[],
|
||||
lf_param:{
|
||||
pageNumber: 1,
|
||||
pageSize: 10,
|
||||
},
|
||||
param:{
|
||||
pageNumber: 1,
|
||||
pageSize: 10,
|
||||
}
|
||||
}
|
||||
},
|
||||
components: {
|
||||
PreviewPicture,
|
||||
},
|
||||
methods: {
|
||||
// 关闭弹窗
|
||||
handleClose() {
|
||||
this.dialogVisible = false
|
||||
this.$emit("handlerChannelList");
|
||||
},
|
||||
// 图集预览
|
||||
previewPicture(pictureArr, id) {
|
||||
const Arr = JSON.parse(JSON.stringify(pictureArr))
|
||||
this.$refs.previewPicture.open(Arr, id)
|
||||
},
|
||||
// 请求楼凤信息列表
|
||||
getLouFengList(id) {
|
||||
let lf_param=Object.assign({},this.lf_param,{id:id})
|
||||
API.queryFeedback(lf_param)
|
||||
.then((res) => {
|
||||
if (res.code === 200 && res.data) {
|
||||
this.tableData = res.data.data
|
||||
} else {
|
||||
this.tableData = []
|
||||
}
|
||||
})
|
||||
.catch(() => {
|
||||
})
|
||||
},
|
||||
// 打开编辑视频弹窗、传递需要编辑的参k
|
||||
open( data) {
|
||||
this.dialogVisible = true
|
||||
this.id=data.loufengID
|
||||
this.getLouFengList(this.id)
|
||||
},
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.add-pay-box {
|
||||
.el-date-picker,
|
||||
.el-input {
|
||||
width: 150px;
|
||||
}
|
||||
.form-flex-box {
|
||||
display: flex;
|
||||
.el-form-item {
|
||||
flex: 1;
|
||||
}
|
||||
}
|
||||
.avatar-uploader {
|
||||
width: 150px;
|
||||
height: 150px;
|
||||
}
|
||||
.el-upload {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
border: 1px dashed #d9d9d9;
|
||||
border-radius: 6px;
|
||||
cursor: pointer;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
&:hover {
|
||||
border: 1px dashed #e63765;
|
||||
}
|
||||
img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
.avatar-uploader-icon {
|
||||
font-size: 28px;
|
||||
color: #8c939d;
|
||||
width: 150px;
|
||||
height: 150px;
|
||||
line-height: 150px;
|
||||
text-align: center;
|
||||
&:hover {
|
||||
color: 1px dashed #e63765 !important;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
<style lang="scss">
|
||||
.add-pay-box .el-upload {
|
||||
width: 20%;
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,154 @@
|
||||
<template>
|
||||
<div class="tags-box">
|
||||
<el-dialog :title="'图集详情'" :visible.sync="dialogVisible" :width="width" height=100% :before-close="handleClose" :close-on-click-modal="false">
|
||||
<div class="picturePopup" :style="{ overflow: over}">
|
||||
<div v-for="(item,i) in pictureList" :key="i" class="pictureInside">
|
||||
<base-upload :cover="item.src" :action="action" @successCallback="item.successCallback" :wSize="360" :hSize="480" :width="'200px'" :height="'260px'" :hide="true"></base-upload>
|
||||
<el-button type="danger" icon="el-icon-delete" circle size="small" class="deleteButton" @click="deletePicture(i)"></el-button>
|
||||
</div>
|
||||
</div>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" size="small" @click="addPicture">新增</el-button>
|
||||
<el-button type="primary" size="small" @click="submitDate()" :loading="flag">确 认</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import baseConfig from '@/utils/serverUrlConfig'
|
||||
import API from '@/api'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
id: '',
|
||||
flag: false,
|
||||
dialogVisible: false,
|
||||
// 封面上传地址
|
||||
action: baseConfig.baseServerUrl + '/vid/uploadStatic',
|
||||
imgUrl: baseConfig.imgUrl,
|
||||
pictureList: [],
|
||||
picturePopupLength: ['260px','470px','680px'],
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
width() {
|
||||
if(this.pictureList.length <4 && this.pictureList.length > 0) {
|
||||
return this.picturePopupLength[this.pictureList.length-1]
|
||||
} else if(this.pictureList.length < 7){
|
||||
return '680px'
|
||||
} else {
|
||||
return '700px'
|
||||
}
|
||||
},
|
||||
over() {
|
||||
return this.pictureList.length < 6 ? 'hidden' : 'auto'
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
// 封面图上传成功回调
|
||||
successCallback(res) {
|
||||
this.params.cover = res.data.coverImg
|
||||
},
|
||||
// 删除某张图片
|
||||
deletePicture(i) {
|
||||
if(this.pictureList.length === 1) {
|
||||
this.$message.error('请至少保留一张!')
|
||||
return
|
||||
}
|
||||
this.pictureList.splice(i,1)
|
||||
},
|
||||
// 新增图片
|
||||
addPicture() {
|
||||
let obj = {
|
||||
src: '',
|
||||
successCallback(res) {
|
||||
obj.src = res.data.coverImg
|
||||
}
|
||||
}
|
||||
this.pictureList.push(obj)
|
||||
},
|
||||
// 提交表单
|
||||
submitDate() {
|
||||
let arr = [];
|
||||
this.pictureList.forEach(item => {
|
||||
arr.push(item.src)
|
||||
})
|
||||
this.updateLoufeng({cover:arr, id: this.id})
|
||||
},
|
||||
// 提交图集
|
||||
updateLoufeng(params) {
|
||||
API.updateLoufeng(params).then(res => {
|
||||
if (res.code === 200) {
|
||||
this.$message({
|
||||
message: '操作成功!',
|
||||
type: 'success'
|
||||
});
|
||||
this.$emit("handlerChannelList")
|
||||
} else {
|
||||
this.$message.error('操作失败!');
|
||||
}
|
||||
this.handleClose()
|
||||
this.flag = false
|
||||
}).catch(() => {
|
||||
this.handleClose()
|
||||
this.flag = false
|
||||
})
|
||||
},
|
||||
// 打开弹窗并初始化tags数据
|
||||
open(pictureArr, id) {
|
||||
this.dialogVisible = true
|
||||
this.id = id
|
||||
let arr = [];
|
||||
for(var i = 0; i< pictureArr.length; i++) {
|
||||
let obj = {
|
||||
src: pictureArr[i],
|
||||
successCallback(res) {
|
||||
obj.src = res.data.coverImg
|
||||
}
|
||||
}
|
||||
arr.push(obj)
|
||||
}
|
||||
this.pictureList = arr
|
||||
},
|
||||
// 关闭弹窗
|
||||
handleClose() {
|
||||
this.dialogVisible = false
|
||||
this.pictureList = []
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style scoped lang="scss">
|
||||
.tags-box {
|
||||
.el-dialog {
|
||||
padding: 0 !important;
|
||||
margin: 0 !important;
|
||||
}
|
||||
.input-box {
|
||||
margin-top: 15px;
|
||||
text-align: left;
|
||||
}
|
||||
.el-input {
|
||||
width: 200px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
.picturePopup {
|
||||
border: solid 5px black;
|
||||
margin: 0 auto;
|
||||
display: flex;
|
||||
justify-content: flex-start;
|
||||
flex-wrap: wrap;
|
||||
max-height: 580px;
|
||||
.pictureInside {
|
||||
margin: 5px;
|
||||
position: relative;
|
||||
.deleteButton {
|
||||
position: absolute;
|
||||
opacity: 0.5;
|
||||
top: 0;
|
||||
right: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,439 @@
|
||||
<!--
|
||||
* @Author: 王枫叶
|
||||
* @Date: 2020-10-21 16:53:48
|
||||
* @LastEditors: 王枫叶
|
||||
* @LastEditTime: 2020-12-18 19:42:17
|
||||
-->
|
||||
<!-- -->
|
||||
<template>
|
||||
<div class="action-bar">
|
||||
<div style="margin-bottom:20px">
|
||||
<!-- <el-select
|
||||
v-model="params.processingStatus"
|
||||
size="small"
|
||||
placeholder="请选择处理状态"
|
||||
clearable
|
||||
@change="getFeedbList"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in processingStatusList"
|
||||
:value="item.value"
|
||||
:label="item.label"
|
||||
:key="item.value"
|
||||
></el-option>
|
||||
</el-select> -->
|
||||
<el-select
|
||||
v-model="params.type"
|
||||
size="small"
|
||||
placeholder="请选择举报类型"
|
||||
clearable
|
||||
@change="getFeedbList"
|
||||
class="param-input"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in feedbackTypes"
|
||||
:value="item.value"
|
||||
:label="item.label"
|
||||
:key="item.value"
|
||||
></el-option>
|
||||
</el-select>
|
||||
<el-input
|
||||
placeholder="请输用户ID "
|
||||
v-model.number="params.uid"
|
||||
clearable
|
||||
size="small"
|
||||
@change="getFeedbList"
|
||||
class="param-input"
|
||||
></el-input>
|
||||
<el-input
|
||||
placeholder="请输入裸聊ID"
|
||||
v-model="params.nudeChatId"
|
||||
clearable
|
||||
size="small"
|
||||
@change="getFeedbList"
|
||||
class="param-input"
|
||||
></el-input>
|
||||
<!-- <el-date-picker
|
||||
v-model="time"
|
||||
type="datetimerange"
|
||||
range-separator="至"
|
||||
start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"
|
||||
size="small"
|
||||
@change="changeTime"
|
||||
></el-date-picker> -->
|
||||
<el-button type="primary" size="small" @click="getFeedbList('status')" style="margin-right:10px">搜索</el-button>
|
||||
</div>
|
||||
|
||||
<!--数据表格-->
|
||||
<el-table
|
||||
:data="tableData"
|
||||
style="width: 100%"
|
||||
border
|
||||
v-loading="loading"
|
||||
element-loading-text="拼命加载中"
|
||||
element-loading-spinner="el-icon-loading"
|
||||
ref="multipleTable"
|
||||
height="600"
|
||||
>
|
||||
<el-table-column
|
||||
prop="id"
|
||||
label="ID"
|
||||
align="center"
|
||||
min-width="160"
|
||||
fixed
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.id }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="uid" label="用户ID" align="center" min-width="100">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.uid }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="type"
|
||||
label="举报类型"
|
||||
align="center"
|
||||
min-width="120"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.type | feedbackTypeList }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="nudeChatId"
|
||||
label="楼凤id"
|
||||
align="center"
|
||||
min-width="160"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.nudeChatId }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="content"
|
||||
label="内容"
|
||||
align="center"
|
||||
min-width="200"
|
||||
:show-overflow-tooltip="true"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.content ? scope.row.content : "--" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="images"
|
||||
label="图片"
|
||||
align="center"
|
||||
min-width="200"
|
||||
:show-overflow-tooltip="true"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span v-if="!scope.row.images || !scope.row.images.length">未知</span>
|
||||
<div
|
||||
v-else
|
||||
class="picturePreview"
|
||||
@click="previewPicture(scope.row.images, scope.row.id)"
|
||||
>
|
||||
<decrypt-img
|
||||
style="width: 70px; height: 70px"
|
||||
:src="imgUrl + item"
|
||||
fit="fill"
|
||||
v-for="(item, i) in scope.row.images"
|
||||
:key="i"
|
||||
></decrypt-img>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="receipt"
|
||||
label="回执信息"
|
||||
align="center"
|
||||
min-width="160"
|
||||
:show-overflow-tooltip="true"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.receipt || '暂无回复!' }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- <el-table-column
|
||||
prop="processingStatus"
|
||||
label="处理状态"
|
||||
align="center"
|
||||
min-width="120"
|
||||
fixed="right"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<p class="stuate"
|
||||
:style="
|
||||
(colors =
|
||||
scope.row.processingStatus === 0
|
||||
? 'background:#fff'
|
||||
: scope.row.processingStatus === 1
|
||||
? 'background:rgba(29,211,66,1)'
|
||||
: 'background:rgba(255,100,97,1)')
|
||||
"
|
||||
>{{ scope.row.processingStatus | processingStatusList }}</p
|
||||
>
|
||||
</template>
|
||||
</el-table-column> -->
|
||||
<el-table-column
|
||||
prop="createdAt"
|
||||
label="创建时间"
|
||||
align="center"
|
||||
min-width="160"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.createdAt | changeDate }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="updatedAt"
|
||||
label="修改时间"
|
||||
align="center"
|
||||
min-width="160"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.updatedAt | changeDate }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
label="操作"
|
||||
align="center"
|
||||
fixed="right"
|
||||
min-width="200"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
type="success"
|
||||
size="mini"
|
||||
@click="toExamine(scope.row)"
|
||||
:disabled="scope.row.status === 0 ? false : true"
|
||||
>处理</el-button
|
||||
>
|
||||
<el-button
|
||||
type="info"
|
||||
size="mini"
|
||||
@click="refuseReview(scope.row)"
|
||||
:disabled="scope.row.status === 0 ? false : true"
|
||||
>忽略</el-button
|
||||
>
|
||||
<el-button
|
||||
type="danger"
|
||||
size="mini"
|
||||
@click="setChosen(scope.row)"
|
||||
>下架</el-button>
|
||||
<!-- <el-button
|
||||
type="warning"
|
||||
size="mini"
|
||||
@click="Action(scope.row)"
|
||||
>楼凤详情</el-button> -->
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!--分页组件-->
|
||||
<el-pagination
|
||||
:page-sizes="[10, 15, 20, 30]"
|
||||
:current-page="params.pageNumber"
|
||||
:page-size="params.pageSize"
|
||||
layout="total, sizes, prev, pager, next, jumper"
|
||||
:total="total"
|
||||
background
|
||||
v-if="total > 5"
|
||||
@size-change="changeSize"
|
||||
@current-change="changeCurrent"
|
||||
></el-pagination>
|
||||
<!-- 背景图集预览窗口 -->
|
||||
<preview-picture
|
||||
ref="previewPicture"
|
||||
@handlerChannelList="getFeedbList"
|
||||
></preview-picture>
|
||||
<!-- 添加审核检查 -->
|
||||
<check ref="check" @handlerAgentList="getFeedbList" />
|
||||
<!-- 楼凤详情 -->
|
||||
<lf-details ref="lfDetails" ></lf-details>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import API from '@/api'
|
||||
import baseConfig from '@/utils/serverUrlConfig'
|
||||
import PreviewPicture from './components/previewPicture'
|
||||
import Check from './components/check'
|
||||
import { changeTime } from "@/utils/global";
|
||||
import lfDetails from './components/lfDetails'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
imgUrl: baseConfig.imgUrl,
|
||||
// 表格数据加载动画
|
||||
loading: false,
|
||||
// 列表数据
|
||||
tableData: [],
|
||||
time: "",
|
||||
total: 0,
|
||||
// 系统管理列表请求参数
|
||||
params: {
|
||||
pageNumber: 1,
|
||||
pageSize: 10,
|
||||
// processingStatus:undefined,
|
||||
uid:undefined,
|
||||
nudeChatId:undefined,
|
||||
type:undefined,
|
||||
// startTime: undefined,
|
||||
// endTime: undefined,
|
||||
},
|
||||
param: {
|
||||
pageNumber: 1,
|
||||
pageSize: 10,
|
||||
},
|
||||
processingStatusList:[
|
||||
{label:'全部',value:undefined},
|
||||
{label:'等待处理',value:0},
|
||||
{label:'处理完成',value:1},
|
||||
{label:'忽略',value:2},
|
||||
],
|
||||
feedbackTypes:[
|
||||
{label:'无效联系方式',value:1},
|
||||
{label:'骗子',value:2},
|
||||
{label:'重复信息',value:3},
|
||||
],
|
||||
|
||||
}
|
||||
},
|
||||
components: {
|
||||
Check,
|
||||
PreviewPicture,
|
||||
lfDetails
|
||||
},
|
||||
created() {
|
||||
this.getFeedbList()
|
||||
},
|
||||
methods: {
|
||||
// 请求举报信息列表
|
||||
getFeedbList(type) {
|
||||
this.loading = true
|
||||
if (type === 'status') {
|
||||
this.params.pageNumber = 1
|
||||
}
|
||||
API.queryFeedback(this.params)
|
||||
.then((res) => {
|
||||
if (res.code === 200 && res.data) {
|
||||
this.tableData = res.data.data
|
||||
this.total = res.data.total
|
||||
} else {
|
||||
this.tableData = []
|
||||
}
|
||||
this.loading = false
|
||||
})
|
||||
.catch(() => {
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
|
||||
// 图集预览
|
||||
previewPicture(pictureArr, id) {
|
||||
const Arr = JSON.parse(JSON.stringify(pictureArr))
|
||||
this.$refs.previewPicture.open(Arr, id)
|
||||
},
|
||||
// 审核
|
||||
toExamine(data) {
|
||||
this.$refs.check.open(data)
|
||||
},
|
||||
// 楼凤详情
|
||||
Action(data) {
|
||||
this.$refs.lfDetails.open(data)
|
||||
},
|
||||
//是否激活
|
||||
setChosen(row) {
|
||||
{
|
||||
let params = {
|
||||
id: row.id,
|
||||
type: 3,
|
||||
nudeChatId: row.nudeChatId,
|
||||
};
|
||||
API.operateFeedback(params).then((res) => {
|
||||
if (res.code === 200) {
|
||||
this.$message({
|
||||
message:"下架操作成功!",
|
||||
type: "success",
|
||||
});
|
||||
this.getFeedbList();
|
||||
} else {
|
||||
this.$message.error("下架操作失败!");
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
},
|
||||
// 拒绝
|
||||
refuseReview(row) {
|
||||
let params = Object.assign(
|
||||
{},
|
||||
{
|
||||
id: row.id,
|
||||
type: 2,
|
||||
nudeChatId: row.nudeChatId,
|
||||
}
|
||||
);
|
||||
API.operateFeedback(params)
|
||||
.then((res) => {
|
||||
if (res.code === 200) {
|
||||
this.$message({
|
||||
message: "操作成功",
|
||||
type: "success",
|
||||
});
|
||||
this.getFeedbList();
|
||||
} else {
|
||||
if (res.tip) {
|
||||
this.$message.error(res.tip);
|
||||
} else {
|
||||
this.$message.error("操作失败");
|
||||
}
|
||||
}
|
||||
// this.handleClose();
|
||||
// this.flag = false;
|
||||
})
|
||||
.catch(() => {
|
||||
// this.handleClose();
|
||||
// this.flag = false;
|
||||
});
|
||||
},
|
||||
// 时间触发回调
|
||||
changeTime(time) {
|
||||
if (time) {
|
||||
this.params.startTime = changeTime(time[0]) || "";
|
||||
this.params.endTime = changeTime(time[1]) || "";
|
||||
} else {
|
||||
this.params.startTime = "";
|
||||
this.params.endTime = "";
|
||||
}
|
||||
this.getFeedbList("status");
|
||||
},
|
||||
// 分页条数改变回掉
|
||||
changeSize(size) {
|
||||
this.params.pageSize = size
|
||||
this.getFeedbList()
|
||||
},
|
||||
// 分页页码改变回掉
|
||||
changeCurrent(pageNumber) {
|
||||
this.params.pageNumber = pageNumber
|
||||
this.getFeedbList()
|
||||
},
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.payMethod {
|
||||
.stuate{
|
||||
display: block;
|
||||
width: 200px;
|
||||
}
|
||||
.add-input {
|
||||
margin-left: 0 !important;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,133 @@
|
||||
<template>
|
||||
<div>
|
||||
<el-dialog
|
||||
:title="title"
|
||||
align="center"
|
||||
:visible.sync="dialogVisible"
|
||||
width="40%"
|
||||
:before-close="handleClose"
|
||||
:close-on-click-modal="false"
|
||||
>
|
||||
<div :data="myData" class="my_data">
|
||||
<span>视频状态:{{ this.myData.status | videoStatus }}</span>
|
||||
<span>视频高度:{{ this.myData.height }}</span>
|
||||
<span>视频宽度:{{ this.myData.width }}</span>
|
||||
<span>视频时长:{{ this.myData.playTime + "s" }}</span>
|
||||
</div>
|
||||
<div class="media-box" id="media-box" v-if="videoShow"></div>
|
||||
<div class="media-box" id="img-box" v-if="imgShow">
|
||||
<img :src="mediaUrl" />
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import videojs from "video.js";
|
||||
import "videojs-contrib-hls";
|
||||
import baseConfig from "@/utils/serverUrlConfig";
|
||||
import API from "@/api";
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
dialogVisible: false,
|
||||
imgShow: true,
|
||||
mediaUrl: "",
|
||||
videoShow: false,
|
||||
title: "封面图查看",
|
||||
params: {},
|
||||
urll: "",
|
||||
myData: []
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
token() {
|
||||
return this.$store.state.token;
|
||||
}
|
||||
},
|
||||
mounted() { },
|
||||
methods: {
|
||||
// 视频审查列表
|
||||
videoFeviewList() {
|
||||
let urll = this.urll;
|
||||
API.videoFeviewList(this.params, urll).then(res => {
|
||||
this.myData = res.data;
|
||||
});
|
||||
},
|
||||
handleClose() {
|
||||
if (this.player) {
|
||||
this.player.dispose();
|
||||
}
|
||||
this.dialogVisible = false;
|
||||
this.imgShow = false;
|
||||
this.videoShow = false;
|
||||
this.mediaUrl = "";
|
||||
},
|
||||
open(url, type, data) {
|
||||
this.dialogVisible = true;
|
||||
if (type === "img") {
|
||||
this.imgShow = true;
|
||||
this.videoShow = false;
|
||||
this.title = "封面图查看";
|
||||
this.mediaUrl = url;
|
||||
} else {
|
||||
this.imgShow = false;
|
||||
this.videoShow = true;
|
||||
this.title = "视频查看";
|
||||
this.mediaUrl =
|
||||
baseConfig.baseServerUrl +
|
||||
baseConfig.playVideoUrl +
|
||||
url +
|
||||
"?token=" +
|
||||
this.token;
|
||||
// eslint-disable-next-line no-console
|
||||
this.urll = data.id;
|
||||
this.$nextTick(function () {
|
||||
document.getElementById("media-box").innerHTML =
|
||||
`<video id="my-video" class="video-js vjs-default-skin" controls preload="auto" style="width:100%;height:100%">
|
||||
</video>`;
|
||||
this.player = videojs(
|
||||
"my-video",
|
||||
{
|
||||
bigPlayButton: true,
|
||||
textTrackDisplay: false,
|
||||
posterImage: true,
|
||||
errorDisplay: true,
|
||||
controlBar: true,
|
||||
playbackRates: [0.5, 1, 2, 3, 4]
|
||||
},
|
||||
function () {
|
||||
this.play();
|
||||
}
|
||||
);
|
||||
this.player.src(this.mediaUrl);
|
||||
this.videoFeviewList();
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
.my_data {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
.media-box {
|
||||
width: 100%;
|
||||
height: 400px;
|
||||
text-align: center;
|
||||
overflow: hidden;
|
||||
img {
|
||||
height: 100%;
|
||||
max-width: 100%;
|
||||
}
|
||||
#my-video {
|
||||
width: 100% !important;
|
||||
height: 100% !important;
|
||||
border: none !important;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,142 @@
|
||||
<template>
|
||||
<div class="tags-box">
|
||||
<el-dialog
|
||||
:title="'图集详情'"
|
||||
:visible.sync="dialogVisible"
|
||||
:width="width"
|
||||
:before-close="handleClose"
|
||||
:close-on-click-modal="false"
|
||||
>
|
||||
<div class="picturePopup" :style="{ overflow: over }">
|
||||
<div v-for="(item, i) in pictureList" :key="i" class="pictureInside">
|
||||
<decrypt-img
|
||||
style="width: 180px; height: 180px"
|
||||
:src="imgUrl + item.src"
|
||||
fit="fill"
|
||||
></decrypt-img>
|
||||
<!-- <base-upload
|
||||
:cover="item.src"
|
||||
:action="action"
|
||||
@successCallback="item.successCallback"
|
||||
:wSize="360"
|
||||
:hSize="480"
|
||||
:width="'180px'"
|
||||
:height="'180px'"
|
||||
:hide="true"
|
||||
></base-upload> -->
|
||||
<!-- <el-button type="danger" icon="el-icon-delete" circle size="small" class="deleteButton" @click="deletePicture(i)"></el-button> -->
|
||||
</div>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import baseConfig from "@/utils/serverUrlConfig";
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
id: "",
|
||||
tags: [],
|
||||
flag: false,
|
||||
dialogVisible: false,
|
||||
// 封面上传地址
|
||||
action: baseConfig.baseServerUrl + "/vid/uploadStatic",
|
||||
imgUrl: baseConfig.imgUrl,
|
||||
pictureList: [],
|
||||
picturePopupLength: ["240px", "430px", "620px"],
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
width() {
|
||||
if (this.pictureList.length < 4 && this.pictureList.length > 0) {
|
||||
return this.picturePopupLength[this.pictureList.length - 1];
|
||||
} else if (this.pictureList.length < 10) {
|
||||
return "620px";
|
||||
} else {
|
||||
return "640px";
|
||||
}
|
||||
},
|
||||
over() {
|
||||
return this.pictureList.length < 10 ? "hidden" : "auto";
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
// 封面图上传成功回调
|
||||
successCallback(res) {
|
||||
this.params.cover = res.data.coverImg;
|
||||
},
|
||||
// 删除某张图片
|
||||
deletePicture(i) {
|
||||
if (this.pictureList.length === 1) {
|
||||
this.$message.error("请至少保留一张!");
|
||||
return;
|
||||
}
|
||||
this.pictureList.splice(i, 1);
|
||||
},
|
||||
// 新增图片
|
||||
addPicture() {
|
||||
let obj = {
|
||||
src: "",
|
||||
successCallback(res) {
|
||||
obj.src = res.data.coverImg;
|
||||
},
|
||||
};
|
||||
this.pictureList.push(obj);
|
||||
},
|
||||
// 打开弹窗并初始化tags数据
|
||||
open(pictureArr) {
|
||||
this.dialogVisible = true;
|
||||
let arr = [];
|
||||
for (var i = 0; i < pictureArr.length; i++) {
|
||||
let obj = {
|
||||
src: pictureArr[i],
|
||||
successCallback(res) {
|
||||
obj.src = res.data.coverImg;
|
||||
},
|
||||
};
|
||||
arr.push(obj);
|
||||
}
|
||||
this.pictureList = arr;
|
||||
},
|
||||
// 关闭弹窗
|
||||
handleClose() {
|
||||
this.dialogVisible = false;
|
||||
this.pictureList = [];
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style scoped lang="scss">
|
||||
.tags-box {
|
||||
.el-dialog {
|
||||
padding: 0 !important;
|
||||
margin: 0 !important;
|
||||
}
|
||||
.input-box {
|
||||
margin-top: 15px;
|
||||
text-align: left;
|
||||
}
|
||||
.el-input {
|
||||
width: 200px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
.picturePopup {
|
||||
border: solid 5px white;
|
||||
margin: 0 auto;
|
||||
display: flex;
|
||||
justify-content: flex-start;
|
||||
flex-wrap: wrap;
|
||||
max-height: 580px;
|
||||
.pictureInside {
|
||||
margin: 5px;
|
||||
position: relative;
|
||||
.deleteButton {
|
||||
position: absolute;
|
||||
opacity: 0.5;
|
||||
top: 0;
|
||||
right: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,101 @@
|
||||
<template>
|
||||
<div class="edit-video-box">
|
||||
<el-dialog
|
||||
title="批量修改模块"
|
||||
:visible.sync="dialogVisible"
|
||||
width="400px"
|
||||
:before-close="handleClose"
|
||||
:close-on-click-modal="false"
|
||||
>
|
||||
<el-form
|
||||
ref="form"
|
||||
:model="form"
|
||||
:rules="rules"
|
||||
inline
|
||||
label-position="left"
|
||||
label-width="86px"
|
||||
>
|
||||
<el-form-item label="模块ID:" prop="mid">
|
||||
<el-input
|
||||
style="width: 240px;"
|
||||
type="text"
|
||||
size="small"
|
||||
placeholder="请输入模块ID"
|
||||
v-model.trim="form.mid"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="handleClose" size="small">取 消</el-button>
|
||||
<el-button
|
||||
type="primary"
|
||||
size="small"
|
||||
@click="submitDate"
|
||||
:loading="flag"
|
||||
>确 认</el-button
|
||||
>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import API from "@/api";
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
flag: false,
|
||||
dialogVisible: false,
|
||||
form: {
|
||||
mid: "",
|
||||
ids: [],
|
||||
},
|
||||
rules: {
|
||||
mid: [
|
||||
{ required: true, message: "请输入模块ID", trigger: "blur" },
|
||||
],
|
||||
},
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
submitDate() {
|
||||
this.$refs.form.validate((valid) => {
|
||||
if (valid) {
|
||||
this.$confirm(`确定修改模块?`, "提示", {
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
type: "warning",
|
||||
}).then(() => {
|
||||
this.flag = true;
|
||||
API.batchUpdateNakedChat(this.form)
|
||||
.then((res) => {
|
||||
if (res.code === 200) {
|
||||
this.$message({
|
||||
message: "修改成功",
|
||||
type: "success",
|
||||
});
|
||||
this.handleClose()
|
||||
this.$emit('close')
|
||||
} else {
|
||||
this.$message.error("修改失败!");
|
||||
}
|
||||
})
|
||||
.finally(() => {
|
||||
this.flag = false;
|
||||
});
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
handleClose() {
|
||||
this.flag = false;
|
||||
this.form.mid = "";
|
||||
this.form.ids = [];
|
||||
this.dialogVisible = false;
|
||||
this.$refs.form.resetFields();
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped></style>
|
||||
@@ -0,0 +1,830 @@
|
||||
<template>
|
||||
<div class="louFeng-box">
|
||||
<!--操作栏-->
|
||||
<div class="action-bar">
|
||||
<el-input
|
||||
placeholder="请输入模块id"
|
||||
v-model.number="searchParams.mid"
|
||||
clearable
|
||||
size="small"
|
||||
class="param-input"
|
||||
>
|
||||
</el-input>
|
||||
<el-input
|
||||
placeholder="请输入标题"
|
||||
v-model.number="searchParams.title"
|
||||
clearable
|
||||
size="small"
|
||||
class="param-input"
|
||||
>
|
||||
</el-input>
|
||||
<el-select
|
||||
placeholder="上架/下架"
|
||||
v-model="searchParams.status"
|
||||
size="small"
|
||||
clearable
|
||||
style="width:200px;margin-right:5px"
|
||||
>
|
||||
<el-option :value="1" label="上架" key="上架"></el-option>
|
||||
<el-option :value="0" label="下架" key="下架"></el-option>
|
||||
</el-select>
|
||||
<el-button
|
||||
type="primary"
|
||||
size="small"
|
||||
@click="getNakedChatList('status')"
|
||||
style="margin-right: 20px"
|
||||
>搜索
|
||||
</el-button>
|
||||
<el-button
|
||||
type="primary"
|
||||
size="small"
|
||||
@click="addHandler"
|
||||
class="add-input"
|
||||
style="margin-right: 20px"
|
||||
>+新增</el-button
|
||||
>
|
||||
<el-button
|
||||
type="success"
|
||||
size="small"
|
||||
@click="batchUpdate"
|
||||
class="add-input"
|
||||
style="margin-right: 20px"
|
||||
:disabled="!multipleSelection.length"
|
||||
>批量更新裸聊模块</el-button
|
||||
>
|
||||
<!-- <el-button type="success" size="small" @click="announcement()" class="add-input">官方公告</el-button> -->
|
||||
</div>
|
||||
<!--数据表格-->
|
||||
<el-table
|
||||
:data="tableData"
|
||||
style="width: 100%"
|
||||
border
|
||||
v-loading="loading"
|
||||
element-loading-text="拼命加载中"
|
||||
element-loading-spinner="el-icon-loading"
|
||||
ref="multipleTable"
|
||||
height="550"
|
||||
@sort-change="handleSortChange"
|
||||
@selection-change="handleSelectionChange"
|
||||
>
|
||||
<el-table-column type="selection" width="55"> </el-table-column>
|
||||
<el-table-column
|
||||
prop="id"
|
||||
label="ID"
|
||||
align="center"
|
||||
fixed
|
||||
min-width="210"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.id || "未知" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="mid" label="模块id" align="center" min-width="140">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.mid || "未知" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="title" label="标题" align="center" min-width="100">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.title }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="age" label="年龄" align="center">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.age || "未知" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="businessHours"
|
||||
label="连线时间"
|
||||
align="center"
|
||||
min-width="140"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.businessHours || "未知" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="contact"
|
||||
label="联系方式"
|
||||
align="center"
|
||||
min-width="130"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.contact || "未知" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="cover" label="封面" align="center" width="200">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="!scope.row.cover">未知</span>
|
||||
<div
|
||||
v-else
|
||||
class="picturePreview"
|
||||
@click="checkMedia(imgUrl + scope.row.cover, 'img')"
|
||||
>
|
||||
<decrypt-img
|
||||
style="width: 50px; height: 80px"
|
||||
:src="imgUrl + scope.row.cover"
|
||||
fit="fill"
|
||||
></decrypt-img>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="cup" label="罩杯" align="center" min-width="100">
|
||||
<template slot-scope="scope">
|
||||
<el-tag type="danger">{{ cupParse(scope.row.cup) }}</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="height"
|
||||
label="身高"
|
||||
align="center"
|
||||
min-width="100"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.height || "-" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="weight"
|
||||
label="体重"
|
||||
align="center"
|
||||
min-width="100"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.weight || "-" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="saleNum"
|
||||
label="销售数量"
|
||||
align="center"
|
||||
min-width="120"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.saleNum }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="fakeSaleNum"
|
||||
label="销售数量(假)"
|
||||
align="center"
|
||||
min-width="120"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.fakeSaleNum }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="images"
|
||||
label="图片列表"
|
||||
align="center"
|
||||
width="200"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span v-if="!scope.row.images || !scope.row.images.length">未知</span>
|
||||
<div
|
||||
v-else
|
||||
class="picturePreview"
|
||||
@click="previewPicture(scope.row.images)"
|
||||
>
|
||||
<decrypt-img
|
||||
style="width: 50px; height: 80px"
|
||||
:src="imgUrl + scope.row.images[0]"
|
||||
fit="fill"
|
||||
></decrypt-img>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="options"
|
||||
label="可供购买选项(分钟)"
|
||||
align="center"
|
||||
min-width="100"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ "" + scope.row.options }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="price"
|
||||
label="价格(n金币/分钟)"
|
||||
align="center"
|
||||
min-width="100"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.price || "-" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="sortCode" label="排序" align="center">
|
||||
</el-table-column>
|
||||
<el-table-column prop="status" label="上架/下架" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-tag :type="scope.row.status ? 'success' : ''">{{
|
||||
scope.row.status == 1 ? "上架" : "下架"
|
||||
}}</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="summary"
|
||||
label="简介"
|
||||
align="center"
|
||||
min-width="140"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.summary }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="video" label="视频预览" align="center" width="100">
|
||||
<template slot-scope="scope">
|
||||
<i
|
||||
class="el-icon-video-play views"
|
||||
title="点击预览"
|
||||
@click="checkMedia(scope.row.video, 'video')"
|
||||
v-if="scope.row.video && scope.row.video.length > 0"
|
||||
></i>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="createdAt"
|
||||
label="创建时间"
|
||||
align="center"
|
||||
min-width="200"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.createdAt | changeDate }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="updatedAt"
|
||||
label="修改时间"
|
||||
align="center"
|
||||
min-width="200"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{ scope.row.updatedAt | changeDate }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
label="操作"
|
||||
align="center"
|
||||
fixed="right"
|
||||
min-width="100"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
type="success"
|
||||
size="mini"
|
||||
icon="el-icon-edit"
|
||||
@click="editChat(scope.row)"
|
||||
></el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!--分页组件-->
|
||||
<el-pagination
|
||||
:page-sizes="[10, 15, 20, 30]"
|
||||
:current-page="searchParams.pageNumber"
|
||||
:page-size="searchParams.pageSize"
|
||||
layout="total, sizes, prev, pager, next, jumper"
|
||||
:total="total"
|
||||
background
|
||||
v-if="total > 10"
|
||||
@size-change="changeSize"
|
||||
@current-change="changeCurrent"
|
||||
></el-pagination>
|
||||
|
||||
<el-dialog
|
||||
:title="isAdd ? '新增裸聊' : '修改裸聊'"
|
||||
:visible.sync="dialogVisible"
|
||||
width="700px"
|
||||
height="100%"
|
||||
:before-close="handleClose"
|
||||
:close-on-click-modal="false"
|
||||
>
|
||||
<el-form
|
||||
ref="form"
|
||||
:model="params"
|
||||
:rules="rules"
|
||||
label-width="132px"
|
||||
label-position="right"
|
||||
inline
|
||||
>
|
||||
<el-form-item label="封面:" prop="cover">
|
||||
<base-upload
|
||||
class="cover-box"
|
||||
:cover="params.cover"
|
||||
:action="action"
|
||||
@successCallback="successCallback"
|
||||
:wSize="168"
|
||||
:hSize="264"
|
||||
ref="coverUpload"
|
||||
></base-upload>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="图片列表:" prop="images">
|
||||
<imgs-upload
|
||||
:cover="params.images"
|
||||
:action="action"
|
||||
@successCallback="successImageCover"
|
||||
:notLimit="true"
|
||||
:wSize="180"
|
||||
:hSize="320"
|
||||
ref="imgUpload"
|
||||
></imgs-upload>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="上传视频:">
|
||||
<!--视频分片上传-->
|
||||
<uploader
|
||||
:options="options"
|
||||
class="uploader-example"
|
||||
ref="uploader"
|
||||
@file-added="fileAdd"
|
||||
@file-success="onFileSuccess"
|
||||
>
|
||||
<uploader-unsupport></uploader-unsupport>
|
||||
<uploader-drop>
|
||||
<uploader-btn :attrs="attrs">上传视频</uploader-btn>
|
||||
</uploader-drop>
|
||||
<uploader-list style="width: 350px"></uploader-list>
|
||||
</uploader>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="标题:" prop="title">
|
||||
<el-input v-model.trim="params.title" size="small"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="连线时间:" prop="businessHours">
|
||||
<el-input v-model.trim="params.businessHours" size="small"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="可供购买选项:" prop="options">
|
||||
<el-select
|
||||
v-model="params.options"
|
||||
multiple
|
||||
placeholder="请选择"
|
||||
size="small"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in buyOptions"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="联系方式:" prop="contact">
|
||||
<el-input v-model.trim="params.contact" size="small"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="排序:" prop="sortCode">
|
||||
<el-input v-model.number="params.sortCode" size="small"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="价格(n金币/分钟):" prop="price">
|
||||
<el-input v-model.number="params.price" size="small"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="年龄:" prop="age">
|
||||
<el-input v-model.number="params.age" size="small"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="身高:" prop="height">
|
||||
<el-input v-model.number="params.height" size="small"></el-input>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="体重:" prop="weight">
|
||||
<el-input v-model.number="params.weight" size="small"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="罩杯:" prop="cup">
|
||||
<el-select v-model="params.cup" placeholder="请选择罩杯" size="small">
|
||||
<el-option
|
||||
v-for="item in cupSelect"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="销售数量(假):" prop="fakeSaleNum">
|
||||
<el-input v-model.number="params.fakeSaleNum" size="small"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="" prop=""></el-form-item>
|
||||
|
||||
<el-form-item label="简介:" prop="summary">
|
||||
<el-input
|
||||
type="textarea"
|
||||
:rows="3"
|
||||
v-model="params.summary"
|
||||
size="small"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="上架/下架:" prop="status">
|
||||
<el-select v-model="params.status" placeholder="请选择" size="small">
|
||||
<el-option
|
||||
v-for="item in statusOptions"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" size="small" @click="handleClose()"
|
||||
>取 消</el-button
|
||||
>
|
||||
<el-button type="primary" size="small" @click="submitDate()"
|
||||
>确 认</el-button
|
||||
>
|
||||
</div>
|
||||
</el-dialog>
|
||||
<!--封面图、视频弹窗组件-->
|
||||
<media-popup ref="mediaPopup"></media-popup>
|
||||
<!-- 图集预览窗口 -->
|
||||
<preview-picture ref="previewPicture"></preview-picture>
|
||||
<UpdateModulePopup ref="updateModulePopupRef" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import API from "@/api";
|
||||
import MediaPopup from "@/components/media-popup";
|
||||
import baseConfig from "@/utils/serverUrlConfig";
|
||||
import { sortEscape } from "@/utils/global";
|
||||
import local from "@/utils/localStroage.js";
|
||||
import PreviewPicture from "./components/previewPicture";
|
||||
import UpdateModulePopup from "./components/updateModulePopup";
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
action: baseConfig.baseServerUrl + "/vid/uploadStaticBatch",
|
||||
imgUrl: baseConfig.imgUrl,
|
||||
// 表格数据加载动画
|
||||
loading: false,
|
||||
// 列表数据
|
||||
tableData: [],
|
||||
total: 0,
|
||||
// 罩杯数据
|
||||
cupSelect: [
|
||||
{ label: "A", value: "A" },
|
||||
{ label: "B", value: "B" },
|
||||
{ label: "C", value: "C" },
|
||||
{ label: "D", value: "D" },
|
||||
{ label: "E", value: "E" },
|
||||
{ label: "F", value: "F" },
|
||||
{ label: "G", value: "G" },
|
||||
],
|
||||
buyOptions: [
|
||||
{ label: "10分钟", value: 10 },
|
||||
{ label: "20分钟", value: 20 },
|
||||
{ label: "30分钟", value: 30 },
|
||||
{ label: "40分钟", value: 40 },
|
||||
{ label: "50分钟", value: 50 },
|
||||
{ label: "60分钟", value: 60 },
|
||||
{ label: "70分钟", value: 70 },
|
||||
{ label: "80分钟", value: 80 },
|
||||
{ label: "90分钟", value: 90 },
|
||||
{ label: "100分钟", value: 100 },
|
||||
{ label: "110分钟", value: 110 },
|
||||
{ label: "120分钟", value: 120 },
|
||||
],
|
||||
statusOptions: [
|
||||
{ label: "上架", value: 1 },
|
||||
{ label: "下架", value: 0 },
|
||||
],
|
||||
attrs: {
|
||||
accept: [
|
||||
".mp4",
|
||||
".qlv",
|
||||
".qsv",
|
||||
".ogg",
|
||||
".flv",
|
||||
".avi",
|
||||
".wmv",
|
||||
".rmvb",
|
||||
], //接受文件类型
|
||||
},
|
||||
// 系统管理列表请求参数
|
||||
searchParams: {
|
||||
pageNumber: 1,
|
||||
pageSize: 10,
|
||||
},
|
||||
params: {
|
||||
id: undefined,
|
||||
cover: "", // 封面
|
||||
images: [], // 图片列表
|
||||
video: "",
|
||||
title: "",
|
||||
businessHours: "",
|
||||
sortCode: "",
|
||||
age: "",
|
||||
height: "",
|
||||
weight: "",
|
||||
cup: "",
|
||||
fakeSaleNum: "",
|
||||
summary: "",
|
||||
contact: "",
|
||||
price: "",
|
||||
status: "",
|
||||
options: [],
|
||||
},
|
||||
dialogVisible: false,
|
||||
isAdd: true,
|
||||
rules: {
|
||||
title: [{ required: true, message: "必填", trigger: "blur" }],
|
||||
age: [{ required: true, message: "必填", trigger: "blur" }],
|
||||
height: [{ required: true, message: "必填", trigger: "blur" }],
|
||||
cup: [{ required: true, message: "必填", trigger: ["blur", "change"] }],
|
||||
businessHours: [{ required: true, message: "必填", trigger: "blur" }],
|
||||
contact: [{ required: true, message: "必填", trigger: "blur" }],
|
||||
cover: [
|
||||
{ required: true, message: "必填", trigger: ["blur", "change"] },
|
||||
],
|
||||
fakeSaleNum: [{ required: true, message: "必填", trigger: "blur" }],
|
||||
weight: [{ required: true, message: "必填", trigger: "blur" }],
|
||||
price: [{ required: true, message: "必填", trigger: "blur" }],
|
||||
options: [
|
||||
{ required: true, message: "必填", trigger: ["blur", "change"] },
|
||||
],
|
||||
},
|
||||
multipleSelection: [],
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
options() {
|
||||
return {
|
||||
target: baseConfig.baseServerUrl + "/vid/uploadDotStream", //上传地址
|
||||
testChunks: false, //是否开启服务器分片校验
|
||||
method: "application/json",
|
||||
headers: {
|
||||
// 额外请求头
|
||||
Authorization: local.get("userInfo")
|
||||
? local.get("userInfo").token
|
||||
: "",
|
||||
},
|
||||
fileParameterName: "upload", //文件名参数,默认为file
|
||||
query: this.uploadQuery, //额外参数
|
||||
singleFile: true, //单文件上传
|
||||
chunkSize: 2048000, //分片大小,默认1M
|
||||
simultaneousUploads: 6,
|
||||
// 把英文时间转成中文
|
||||
parseTimeRemaining: function(timeRemaining, parsedTimeRemaining) {
|
||||
return parsedTimeRemaining
|
||||
.replace(/\syears?/, "年")
|
||||
.replace(/\days?/, "天")
|
||||
.replace(/\shours?/, "小时")
|
||||
.replace(/\sminutes?/, "分钟")
|
||||
.replace(/\sseconds?/, "秒");
|
||||
},
|
||||
};
|
||||
},
|
||||
},
|
||||
components: { MediaPopup, PreviewPicture, UpdateModulePopup },
|
||||
created() {
|
||||
this.getNakedChatList();
|
||||
},
|
||||
methods: {
|
||||
handleSelectionChange(val) {
|
||||
this.multipleSelection = val;
|
||||
},
|
||||
batchUpdate() {
|
||||
let ids = this.multipleSelection.map(item => item.id);
|
||||
this.$refs.updateModulePopupRef.dialogVisible = true;
|
||||
this.$refs.updateModulePopupRef.form.ids = ids;
|
||||
},
|
||||
cupParse(cup) {
|
||||
let name = "";
|
||||
this.cupSelect.forEach((e) => {
|
||||
if (cup === e.value) {
|
||||
name = e.label;
|
||||
}
|
||||
});
|
||||
return name;
|
||||
},
|
||||
// 请求列表
|
||||
getNakedChatList(type) {
|
||||
this.loading = true;
|
||||
if (type === "status") {
|
||||
this.searchParams.pageNumber = 1;
|
||||
}
|
||||
API.getNakedChatList(this.searchParams)
|
||||
.then((res) => {
|
||||
if (res.code === 200 && res.data) {
|
||||
this.tableData = res.data.list;
|
||||
this.total = res.data.total;
|
||||
} else {
|
||||
this.tableData = [];
|
||||
}
|
||||
this.loading = false;
|
||||
})
|
||||
.catch(() => {
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
//视频上传额外参数
|
||||
uploadQuery(file, chunk) {
|
||||
return {
|
||||
pos: chunk.offset,
|
||||
id: String(this.trackId),
|
||||
// totalPos:chunk.offset+1,
|
||||
// data:data
|
||||
};
|
||||
},
|
||||
//视频上传选中时
|
||||
fileAdd() {
|
||||
this.generateTaskId();
|
||||
},
|
||||
//定义视频上传唯一标识符id
|
||||
generateTaskId() {
|
||||
const time = new Date().getTime();
|
||||
this.trackId = time;
|
||||
},
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
onFileSuccess(rootFile, file, response, chunk) {
|
||||
// this.params.video = [];
|
||||
let res = JSON.parse(response);
|
||||
// this.params.video.push(res.data.sourceURL);
|
||||
this.params.video = res.data.sourceURL;
|
||||
},
|
||||
|
||||
// 查看媒体
|
||||
checkMedia(url, type) {
|
||||
this.$refs.mediaPopup.open(url, type);
|
||||
},
|
||||
// 删除
|
||||
remove(id) {
|
||||
this.$confirm("您确定要删除当前信息吗?", "删除提示", {
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
type: "warning",
|
||||
})
|
||||
.then(() => {
|
||||
API.deleteLoufeng({ id: id }).then((res) => {
|
||||
if (res.code === 200) {
|
||||
this.$message({
|
||||
message: "删除成功",
|
||||
type: "success",
|
||||
});
|
||||
this.getNakedChatList();
|
||||
} else {
|
||||
this.$message.error("删除失败");
|
||||
}
|
||||
});
|
||||
})
|
||||
.catch(() => {});
|
||||
},
|
||||
// 关闭弹窗
|
||||
handleClose() {
|
||||
this.params.id = undefined;
|
||||
this.params.cover = "";
|
||||
this.params.video = "";
|
||||
this.params.images = [];
|
||||
this.dialogVisible = false;
|
||||
this.params.price = "";
|
||||
this.params.age = "";
|
||||
this.params.height = "";
|
||||
this.params.weight = "";
|
||||
this.params.cup = "";
|
||||
this.params.contact = "";
|
||||
this.params.options = [];
|
||||
this.params.businessHours = "";
|
||||
this.params.summary = "";
|
||||
this.params.title = "";
|
||||
this.params.status = "";
|
||||
this.params.sortCode = "";
|
||||
this.params.fakeSaleNum = "";
|
||||
this.$refs["form"].resetFields();
|
||||
this.$refs.imgUpload.clearImg();
|
||||
this.$refs.coverUpload.clearImg();
|
||||
this.getNakedChatList();
|
||||
},
|
||||
// 数据排序
|
||||
handleSortChange(column) {
|
||||
this.params.value = sortEscape(column.order);
|
||||
this.params.key = column.prop;
|
||||
this.getNakedChatList();
|
||||
},
|
||||
// 封面图上传成功回调
|
||||
successImageCover(cover) {
|
||||
this.params.images = cover;
|
||||
},
|
||||
successCallback(res) {
|
||||
this.params.cover = res.data.coverImg;
|
||||
},
|
||||
// 新增
|
||||
addHandler() {
|
||||
this.dialogVisible = true;
|
||||
this.isAdd = true;
|
||||
},
|
||||
// 修改
|
||||
editChat(row) {
|
||||
this.params.id = row.id;
|
||||
this.params.price = row.price;
|
||||
this.params.cover = row.cover;
|
||||
this.params.video = row.video;
|
||||
this.params.age = row.age;
|
||||
this.params.height = row.height;
|
||||
this.params.weight = row.weight;
|
||||
this.params.cup = row.cup;
|
||||
this.params.contact = row.contact;
|
||||
this.params.options = row.options;
|
||||
this.params.businessHours = row.businessHours;
|
||||
this.params.summary = row.summary;
|
||||
this.params.title = row.title;
|
||||
this.params.status = row.status;
|
||||
this.params.sortCode = row.sortCode;
|
||||
this.params.images = row.images;
|
||||
this.params.fakeSaleNum = row.fakeSaleNum;
|
||||
this.isAdd = false;
|
||||
this.dialogVisible = true;
|
||||
setTimeout(() => {
|
||||
this.$refs.imgUpload.getFileList(row.images);
|
||||
}, 100);
|
||||
},
|
||||
|
||||
// 确认提交
|
||||
submitDate() {
|
||||
this.$refs.form.validate((valid) => {
|
||||
if (valid) {
|
||||
if (this.isAdd) {
|
||||
API.addNakedChat(this.params)
|
||||
.then((res) => {
|
||||
if (res.code === 200) {
|
||||
this.$message({
|
||||
message: "操作成功!",
|
||||
type: "success",
|
||||
});
|
||||
this.getNakedChatList('status');
|
||||
} else {
|
||||
this.$message.error("操作失败!");
|
||||
}
|
||||
this.handleClose();
|
||||
})
|
||||
.catch(() => {
|
||||
this.handleClose();
|
||||
});
|
||||
} else {
|
||||
API.updateNakedChat(this.params)
|
||||
.then((res) => {
|
||||
if (res.code === 200) {
|
||||
this.$message({
|
||||
message: "操作成功!",
|
||||
type: "success",
|
||||
});
|
||||
this.getNakedChatList();
|
||||
} else {
|
||||
this.$message.error("操作失败!");
|
||||
}
|
||||
this.handleClose();
|
||||
})
|
||||
.catch(() => {
|
||||
this.handleClose();
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
// 图集预览
|
||||
previewPicture(pictureArr) {
|
||||
const Arr = JSON.parse(JSON.stringify(pictureArr));
|
||||
this.$refs.previewPicture.open(Arr);
|
||||
},
|
||||
// 分页条数改变回掉
|
||||
changeSize(size) {
|
||||
this.searchParams.pageSize = size;
|
||||
this.getNakedChatList();
|
||||
},
|
||||
// 分页页码改变回掉
|
||||
changeCurrent(pageNumber) {
|
||||
this.searchParams.pageNumber = pageNumber;
|
||||
this.getNakedChatList();
|
||||
},
|
||||
// 置顶操作
|
||||
upmost(data) {
|
||||
this.$refs.upmost.open(data);
|
||||
},
|
||||
// 取消置顶
|
||||
cancelTop(id) {
|
||||
API.cancelToplf({ id: id }).then((res) => {
|
||||
if (res.code === 200) {
|
||||
this.$message({
|
||||
message: "取消置顶操作成功!",
|
||||
type: "success",
|
||||
});
|
||||
this.getNakedChatList();
|
||||
} else {
|
||||
this.$message.error("取消置顶操作失败!");
|
||||
}
|
||||
});
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.cover-box {
|
||||
/deep/ .avatar-uploader {
|
||||
width: 100.8px;
|
||||
height: 158.4px;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user