家族-家族信息=增加会长分区信息

This commit is contained in:
khalil
2024-07-12 23:43:17 +08:00
parent 5b41dbabed
commit 00b2bf5917

View File

@@ -3,126 +3,120 @@
<!-- 查询 --> <!-- 查询 -->
<div class="inquire"> <div class="inquire">
<span>ID</span> <span>ID</span>
<el-input <el-input v-model="inquire.userId"
v-model="inquire.userId" placeholder=""
placeholder="" class="input"></el-input>
class="input"
></el-input>
</div> </div>
<div class="inquire"> <div class="inquire">
<span>推荐人</span> <span>推荐人</span>
<el-input <el-input v-model="inquire.referrer"
v-model="inquire.referrer" placeholder=""
placeholder="" class="input"></el-input>
class="input"
></el-input>
</div> </div>
<!-- 时间选择器 --> <!-- 时间选择器 -->
<div class="inquire"> <div class="inquire">
<div class="block"> <div class="block">
<span class="demonstration">日期</span> <span class="demonstration">日期</span>
<el-date-picker <el-date-picker v-model="inquire.time"
v-model="inquire.time" type="datetimerange"
type="datetimerange" range-separator=""
range-separator="" start-placeholder="开始日期"
start-placeholder="开始日期" end-placeholder="结束日期">
end-placeholder="结束日期"
>
</el-date-picker> </el-date-picker>
</div> </div>
</div> </div>
<!-- 查询按钮 --> <!-- 查询按钮 -->
<el-button class="primary" type="primary" @click="getData()" <el-button class="primary"
>查询</el-button type="primary"
> @click="getData()">查询</el-button>
<el-button class="primary" type="primary" @click="addDialog = true" <el-button class="primary"
>添加</el-button type="primary"
> @click="addDialog = true">添加</el-button>
<!-- 表格 --> <!-- 表格 -->
<el-table <el-table v-loading="loading"
v-loading="loading" :data="tableData"
:data="tableData" border
border style="width: 100%; margin-top: 25px">
style="width: 100%; margin-top: 25px" <el-table-column prop="referrer"
> align="center"
<el-table-column prop="referrer" align="center" label="推荐人" /> label="推荐人" />
<el-table-column prop="ownerErbanNo" align="center" label="会长ID" /> <el-table-column prop="ownerErbanNo"
<el-table-column prop="ownerNick" align="center" label="会长昵称" /> align="center"
<el-table-column prop="name" align="center" label="公会昵称" /> label="会长ID" />
<el-table-column align="center" prop="giftInfo" label="公会背景图"> <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"> <template v-slot="scope">
<el-image <el-image style="width: 100px; height: 100px"
style="width: 100px; height: 100px" :src="scope.row.backgroundUrl"
:src="scope.row.backgroundUrl" :zoom-rate="1.1"
:zoom-rate="1.1" :preview-src-list="[scope.row.backgroundUrl]"
:preview-src-list="[scope.row.backgroundUrl]" fit="cover"
fit="cover" preview-teleported="true"
preview-teleported="true" hide-on-click-modal="true" />
hide-on-click-modal="true"
/>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="createTime" align="center" label="创建日期" /> <el-table-column prop="createTime"
align="center"
label="创建日期" />
<!-- <el-table-column prop="memberNum" align="center" label="成员数量" /> --> <!-- <el-table-column prop="memberNum" align="center" label="成员数量" /> -->
<el-table-column <el-table-column align="center"
align="center" label="成员数量/上限"><template v-slot="scope">{{ scope.row.memberNum }}/{{ scope.row.memberNumLimit }}</template></el-table-column>
label="成员数量/上限" <el-table-column prop="goldIncome"
><template v-slot="scope" align="center"
>{{ scope.row.memberNum }}/{{ scope.row.memberNumLimit }}</template label="金币总收入" />
></el-table-column> <el-table-column prop="diamondRemain"
<el-table-column prop="goldIncome" align="center" label="金币总收入" /> align="center"
<el-table-column prop="diamondRemain" align="center" label="钻石总收入" /> label="钻石总收入" />
<el-table-column align="center" label="操作" width="300"> <el-table-column align="center"
label="操作"
width="300">
<template v-slot="scope"> <template v-slot="scope">
<el-button <el-button @click="ediClick(scope)"
@click="ediClick(scope)" class="primary"
class="primary" type="primary"
type="primary" size="default"
size="default" :disabled="!scope.row.enable">编辑</el-button>
:disabled="!scope.row.enable" <el-button @click="
>编辑</el-button
>
<el-button
@click="
delDialog = true; delDialog = true;
delDialogData = scope.row; delDialogData = scope.row;
" "
:class="scope.row.enable ? 'danger' : 'info'" :class="scope.row.enable ? 'danger' : 'info'"
:type="scope.row.enable ? 'danger' : 'info'" :type="scope.row.enable ? 'danger' : 'info'"
size="default" size="default"
:disabled="!scope.row.enable" :disabled="!scope.row.enable">{{ scope.row.enable ? "移除" : "已解散" }}</el-button>
>{{ scope.row.enable ? "移除" : "已解散" }}</el-button
>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<!-- 新增弹窗 --> <!-- 新增弹窗 -->
<el-dialog v-model="addDialog" title="新增" width="28%" center> <el-dialog v-model="addDialog"
title="新增"
width="28%"
center>
<div style="margin-bottom: 25px"> <div style="margin-bottom: 25px">
<span <span style="display: inline-block; margin-right: 20px; width: 100px"
style="display: inline-block; margin-right: 20px; width: 100px" class="col-sm-2 control-label">会长ID</span>
class="col-sm-2 control-label" <el-input v-model="resource.id"
>会长ID</span style="width: 75%"
> class="input"></el-input>
<el-input
v-model="resource.id"
style="width: 75%"
class="input"
></el-input>
</div> </div>
<div style="margin-bottom: 25px"> <div style="margin-bottom: 25px">
<span <span style="display: inline-block; margin-right: 20px; width: 100px"
style="display: inline-block; margin-right: 20px; width: 100px" class="col-sm-2 control-label">推荐人</span>
class="col-sm-2 control-label" <el-input v-model="resource.referrer"
>推荐人</span style="width: 75%"
> class="input"></el-input>
<el-input
v-model="resource.referrer"
style="width: 75%"
class="input"
></el-input>
</div> </div>
<!-- <div style="margin-bottom: 25px"> <!-- <div style="margin-bottom: 25px">
<span <span
@@ -139,95 +133,82 @@
<template #footer> <template #footer>
<span class="dialog-footer"> <span class="dialog-footer">
<el-button @click="addDialog = false">取消</el-button> <el-button @click="addDialog = false">取消</el-button>
<el-button type="primary" @click="add()"> 确认 </el-button> <el-button type="primary"
@click="add()"> 确认 </el-button>
</span> </span>
</template> </template>
</el-dialog> </el-dialog>
<!-- 分页 --> <!-- 分页 -->
<el-pagination <el-pagination style="margin-top: 10px"
style="margin-top: 10px" class="paginationClass"
class="paginationClass" v-model:current-page="currentPage"
v-model:current-page="currentPage" v-model:page-size="pageSize"
v-model:page-size="pageSize" :page-sizes="[10, 20, 30, 40, 50, 100, 200, 300, 400, 500, 999999999]"
:page-sizes="[10, 20, 30, 40, 50, 100, 200, 300, 400, 500, 999999999]" layout="sizes, prev, pager, next"
layout="sizes, prev, pager, next" :total="total"
:total="total" @size-change="handleSizeChange"
@size-change="handleSizeChange" @current-change="handleCurrentChange" />
@current-change="handleCurrentChange"
/>
<!-- 编辑弹窗 --> <!-- 编辑弹窗 -->
<el-dialog v-model="editDialog" title="编辑" width="28%" center> <el-dialog v-model="editDialog"
title="编辑"
width="28%"
center>
<!-- 会长ID --> <!-- 会长ID -->
<div style="margin-bottom: 25px; margin-top: 10px"> <div style="margin-bottom: 25px; margin-top: 10px">
<span <span style="display: inline-block; margin-right: 20px"
style="display: inline-block; margin-right: 20px" class="col-sm-2 control-label">会长ID</span>
class="col-sm-2 control-label" <el-input v-model="ediObj.leaderId"
>会长ID</span style="width: 75%"
> class="input"
<el-input disabled></el-input>
v-model="ediObj.leaderId"
style="width: 75%"
class="input"
disabled
></el-input>
</div> </div>
<!-- 会长昵称 --> <!-- 会长昵称 -->
<div style="margin-bottom: 25px; margin-top: 10px"> <div style="margin-bottom: 25px; margin-top: 10px">
<span <span style="display: inline-block; margin-right: 20px"
style="display: inline-block; margin-right: 20px" class="col-sm-2 control-label">会长昵称</span>
class="col-sm-2 control-label" <el-input v-model="ediObj.leaderNick"
>会长昵称</span style="width: 75%"
> class="input"
<el-input disabled></el-input>
v-model="ediObj.leaderNick"
style="width: 75%"
class="input"
disabled
></el-input>
</div> </div>
<!-- 公会昵称 --> <!-- 公会昵称 -->
<div style="margin-bottom: 25px; margin-top: 10px"> <div style="margin-bottom: 25px; margin-top: 10px">
<span <span style="display: inline-block; margin-right: 20px"
style="display: inline-block; margin-right: 20px" class="col-sm-2 control-label">公会昵称</span>
class="col-sm-2 control-label" <el-input v-model="ediObj.guildNick"
>公会昵称</span style="width: 75%"
> class="input"
<el-input disabled></el-input>
v-model="ediObj.guildNick"
style="width: 75%"
class="input"
disabled
></el-input>
</div> </div>
<!-- 成员数量上限 --> <!-- 成员数量上限 -->
<div style="margin-bottom: 25px; margin-top: 10px"> <div style="margin-bottom: 25px; margin-top: 10px">
<span <span style="display: inline-block; margin-right: 20px"
style="display: inline-block; margin-right: 20px" class="col-sm-2 control-label">成员数量上限</span>
class="col-sm-2 control-label" <el-input v-model="ediObj.guildNumber"
>成员数量上限</span style="width: 75%"
> class="input"></el-input>
<el-input
v-model="ediObj.guildNumber"
style="width: 75%"
class="input"
></el-input>
</div> </div>
<template #footer> <template #footer>
<span class="dialog-footer"> <span class="dialog-footer">
<el-button @click="editDialog = false">取消</el-button> <el-button @click="editDialog = false">取消</el-button>
<el-button type="primary" @click="editDialogClick()"> <el-button type="primary"
@click="editDialogClick()">
确认 确认
</el-button> </el-button>
</span> </span>
</template> </template>
</el-dialog> </el-dialog>
<!-- 二次确认删除弹窗 --> <!-- 二次确认删除弹窗 -->
<el-dialog v-model="delDialog" title="提示" width="30%" center> <el-dialog v-model="delDialog"
title="提示"
width="30%"
center>
<span> 确定要解散该公会吗?</span> <span> 确定要解散该公会吗?</span>
<template #footer> <template #footer>
<span class="dialog-footer"> <span class="dialog-footer">
<el-button @click="delDialog = false">取消</el-button> <el-button @click="delDialog = false">取消</el-button>
<el-button type="primary" @click="delClick()"> 确认 </el-button> <el-button type="primary"
@click="delClick()"> 确认 </el-button>
</span> </span>
</template> </template>
</el-dialog> </el-dialog>
@@ -241,7 +222,7 @@ import { dateFormat } from "@/utils/system-helper";
import { ElMessage } from "element-plus"; import { ElMessage } from "element-plus";
export default { export default {
name: "GuildInfo", name: "GuildInfo",
data() { data () {
return { return {
loading: false, loading: false,
delDialog: false, delDialog: false,
@@ -277,12 +258,12 @@ export default {
}, },
}; };
}, },
created() { created () {
this.getData(); this.getData();
}, },
methods: { methods: {
// 查询接口 // 查询接口
getData() { getData () {
this.loading = true; this.loading = true;
let time = this.inquire.time; let time = this.inquire.time;
let startTime = ""; let startTime = "";
@@ -306,7 +287,7 @@ export default {
}); });
}, },
// 添加 // 添加
add() { add () {
this.addDialog = false; this.addDialog = false;
create({ create({
erbanNo: this.resource.id, erbanNo: this.resource.id,
@@ -316,7 +297,7 @@ export default {
}); });
}, },
// 编辑按钮 // 编辑按钮
ediClick(res) { ediClick (res) {
var obj = res.row; var obj = res.row;
this.ediObj.leaderId = obj.ownerErbanNo; this.ediObj.leaderId = obj.ownerErbanNo;
this.ediObj.leaderNick = obj.ownerNick; this.ediObj.leaderNick = obj.ownerNick;
@@ -326,7 +307,7 @@ export default {
this.editDialog = true; this.editDialog = true;
}, },
// 二次确认弹窗 // 二次确认弹窗
editDialogClick() { editDialogClick () {
console.log(this.ediObj); console.log(this.ediObj);
update({ update({
id: this.ediObj.id, id: this.ediObj.id,
@@ -351,7 +332,7 @@ export default {
}); });
}, },
// 解散按钮 // 解散按钮
delClick() { delClick () {
console.log(this.delDialogData.id); console.log(this.delDialogData.id);
var familyId = this.delDialogData.id; var familyId = this.delDialogData.id;
dismiss({ familyId }).then((res) => { dismiss({ familyId }).then((res) => {
@@ -374,10 +355,10 @@ export default {
}); });
}, },
// 分页导航 // 分页导航
handleSizeChange() { handleSizeChange () {
this.getData(); this.getData();
}, },
handleCurrentChange() { handleCurrentChange () {
this.getData(); this.getData();
}, },
}, },