666
This commit is contained in:
parent
f5fbcae5c3
commit
824cca2457
@ -13,10 +13,10 @@
|
||||
<t-input size="large" placeholder="请输入活动标题" v-model="addForm.activity_name"
|
||||
:style="{ width: '480px' }"/>
|
||||
</t-form-item>
|
||||
<t-form-item label="活动简介" name="activity_desc">
|
||||
<!-- <t-form-item label="活动简介" name="activity_desc">
|
||||
<t-input size="large" placeholder="请输入活动简介" v-model="addForm.activity_desc"
|
||||
:style="{ width: '480px' }"/>
|
||||
</t-form-item>
|
||||
</t-form-item> -->
|
||||
<t-form-item label="活动地址" name="activity_location">
|
||||
<t-input size="large" placeholder="请输入活动地址" v-model="addForm.activity_location"
|
||||
:style="{ width: '480px' }"/>
|
||||
@ -29,12 +29,12 @@
|
||||
<!-- <t-option key="4" label="学习培训" value="4"/>-->
|
||||
<!-- </t-select>-->
|
||||
<!-- </t-form-item>-->
|
||||
<t-form-item label="显示报名人" name="if_display_registrants">
|
||||
<!-- <t-form-item label="显示报名人" name="if_display_registrants">
|
||||
<t-select size="large" v-model="addForm.if_display_registrants" :style="{ width: '480px' }">
|
||||
<t-option key="1" label="显示" value="1"/>
|
||||
<t-option key="2" label="不显示" value="2"/>
|
||||
</t-select>
|
||||
</t-form-item>
|
||||
</t-form-item> -->
|
||||
<t-form-item label="报名范围" name="range">
|
||||
<t-select size="large" v-model="addForm.range" :style="{ width: '480px' }">
|
||||
<t-option key="1" label="会员" value="1"/>
|
||||
@ -92,7 +92,7 @@
|
||||
:sizeLimit="{ size: 50, unit: 'MB', message: '视频大小不超过50MB' }"
|
||||
></t-upload>
|
||||
</t-form-item>
|
||||
<t-form-item label="活动简介" name="activity_desc">
|
||||
<t-form-item label="活动详情" name="activity_desc">
|
||||
<div style="border: 1px solid #ccc;width: 100%;">
|
||||
<!-- 工具栏 -->
|
||||
<Toolbar
|
||||
@ -180,7 +180,7 @@ export default {
|
||||
activity_content: '',
|
||||
activity_location: '',
|
||||
activity_type: null,
|
||||
if_display_registrants: null,
|
||||
if_display_registrants: 2,
|
||||
signup_start_time: '',
|
||||
signup_end_time: '',
|
||||
if_auditing: '1',
|
||||
@ -276,10 +276,10 @@ export default {
|
||||
this.$message.error('活动标题不能为空');
|
||||
return;
|
||||
}
|
||||
if (this.addForm.activity_desc == '') {
|
||||
this.$message.error('活动简介不能为空');
|
||||
return;
|
||||
}
|
||||
// if (this.addForm.activity_desc == '') {
|
||||
// this.$message.error('活动简介不能为空');
|
||||
// return;
|
||||
// }
|
||||
if (this.addForm.activity_type == null) {
|
||||
this.$message.error('活动类别不能为空');
|
||||
return;
|
||||
|
@ -7,10 +7,10 @@
|
||||
<t-input size="large" placeholder="请输入活动标题" v-model="addForm.activity_name"
|
||||
:style="{ width: '480px' }"/>
|
||||
</t-form-item>
|
||||
<t-form-item label="活动简介" name="activity_desc">
|
||||
<!-- <t-form-item label="活动简介" name="activity_desc">
|
||||
<t-input size="large" placeholder="请输入活动简介" v-model="addForm.activity_desc"
|
||||
:style="{ width: '480px' }"/>
|
||||
</t-form-item>
|
||||
</t-form-item> -->
|
||||
<t-form-item label="活动地址" name="activity_location">
|
||||
<t-input size="large" placeholder="请输入活动地址" v-model="addForm.activity_location"
|
||||
:style="{ width: '480px' }"/>
|
||||
@ -23,12 +23,12 @@
|
||||
<!-- <t-option key="4" label="学习培训" value="4"/>-->
|
||||
<!-- </t-select>-->
|
||||
<!-- </t-form-item>-->
|
||||
<t-form-item label="显示报名人" name="if_display_registrants">
|
||||
<!-- <t-form-item label="显示报名人" name="if_display_registrants">
|
||||
<t-select size="large" v-model="addForm.if_display_registrants" :style="{ width: '480px' }">
|
||||
<t-option key="1" label="显示" value="1"/>
|
||||
<t-option key="2" label="不显示" value="2"/>
|
||||
</t-select>
|
||||
</t-form-item>
|
||||
</t-form-item> -->
|
||||
<t-form-item label="报名范围" name="range">
|
||||
<t-select size="large" v-model="addForm.range" :style="{ width: '480px' }">
|
||||
<t-option key="1" label="会员" value="1"/>
|
||||
@ -87,7 +87,7 @@
|
||||
:sizeLimit="{ size: 50, unit: 'MB', message: '视频大小不超过50MB' }"
|
||||
></t-upload>
|
||||
</t-form-item>
|
||||
<t-form-item label="活动简介" name="activity_desc">
|
||||
<t-form-item label="活动详情" name="activity_desc">
|
||||
<div style="border: 1px solid #ccc;width: 100%;">
|
||||
<!-- 工具栏 -->
|
||||
<Toolbar
|
||||
@ -313,10 +313,10 @@ export default {
|
||||
this.$message.error('活动标题不能为空');
|
||||
return;
|
||||
}
|
||||
if (this.addForm.activity_desc == '') {
|
||||
this.$message.error('活动简介不能为空');
|
||||
return;
|
||||
}
|
||||
// if (this.addForm.activity_desc == '') {
|
||||
// this.$message.error('活动简介不能为空');
|
||||
// return;
|
||||
// }
|
||||
if (this.addForm.activity_type == null) {
|
||||
this.$message.error('活动类别不能为空');
|
||||
return;
|
||||
|
@ -117,6 +117,12 @@
|
||||
<CloudDownloadIcon slot="icon"/>
|
||||
导出
|
||||
</t-button>
|
||||
<!-- <t-dropdown :options="options">
|
||||
<t-button>
|
||||
<CloudDownloadIcon slot="icon"/>
|
||||
导出
|
||||
</t-button>
|
||||
</t-dropdown> -->
|
||||
</div>
|
||||
<div v-if="infoIfAuditing==2">
|
||||
<t-tabs v-model="InfotabIndex" @change="InfotabIndexChange">
|
||||
@ -457,6 +463,32 @@ export default {
|
||||
getType: 3,
|
||||
infoIfAuditing: 1,//否
|
||||
association: {},
|
||||
options: [
|
||||
{
|
||||
content: '全部名单',
|
||||
value: 1,
|
||||
onClick: () => {
|
||||
const token = store.state.user.token;
|
||||
window.open(store.state.user.apiUrl + '/api/excel_controller/applicationexport?id=' + this.infoId + "&token=" + token+"&type=4");
|
||||
},
|
||||
},
|
||||
{
|
||||
content: '已通过',
|
||||
value: 2,
|
||||
onClick: () => {
|
||||
const token = store.state.user.token;
|
||||
window.open(store.state.user.apiUrl + '/api/excel_controller/applicationexport?id=' + this.infoId + "&token=" + token+"&type=2");
|
||||
},
|
||||
},
|
||||
{
|
||||
content: '已拒绝',
|
||||
value: 3,
|
||||
onClick: () => {
|
||||
const token = store.state.user.token;
|
||||
window.open(store.state.user.apiUrl + '/api/excel_controller/applicationexport?id=' + this.infoId + "&token=" + token+"&type=3");
|
||||
},
|
||||
},
|
||||
],
|
||||
}
|
||||
},
|
||||
beforeDestroy() {
|
||||
|
@ -72,7 +72,10 @@
|
||||
<div style="height: 2px; background-color: #999999; width: 100%; margin-top: 20px"></div>
|
||||
<div style="display: flex; justify-items: center; padding: 30px 0px">
|
||||
<div style="width: 50%">
|
||||
<div>证件照</div>
|
||||
<div style="display: flex; align-items: center; margin-bottom: 10px">
|
||||
<span style="color: red; margin-right: 5px">*</span>
|
||||
<span style="color: #000;">证件照</span>
|
||||
</div>
|
||||
<div style="height: 1px; background-color: #999999; width: 100%; margin-top: 10px"></div>
|
||||
<div class="t-upload" @click="openCai" style="margin-top: 20px">
|
||||
<div
|
||||
@ -142,7 +145,7 @@
|
||||
<t-option value="九三学社社员" label="九三学社社员" key="九三学社社员"></t-option>
|
||||
<t-option value="台盟盟员" label="台盟盟员" key="台盟盟员"></t-option>
|
||||
<t-option value="无党派人士" label="无党派人士" key="无党派人士"></t-option>
|
||||
<t-option value="无党派人士" label="无党派人士" key="无党派人士"></t-option>
|
||||
<t-option value="群众" label="群众" key="群众"></t-option>
|
||||
</t-select>
|
||||
</t-form-item>
|
||||
<t-form-item label="身份证号码" :requiredMark="true">
|
||||
@ -570,7 +573,10 @@
|
||||
style="width: 100%; max-height: 200px"
|
||||
/>
|
||||
</div>
|
||||
<div style="margin: 10px 0px">请上传营业执照</div>
|
||||
<div style="margin: 10px 0px">
|
||||
<span style="color: red; margin-right: 5px">*</span>
|
||||
<span style="color: #000;">请上传营业执照</span>
|
||||
</div>
|
||||
<t-upload
|
||||
:action="$store.state.user.apiUrl + '/api/common/upload'"
|
||||
v-model="formData.business_license_image_show"
|
||||
@ -602,7 +608,10 @@
|
||||
style="width: 100%; max-height: 200px"
|
||||
/>
|
||||
</div>
|
||||
<div style="margin: 10px 0px">请上传公司LOGO</div>
|
||||
<div style="margin: 10px 0px">
|
||||
<span style="color: red; margin-right: 5px">*</span>
|
||||
<span style="color: #000;">请上传公司LOGO</span>
|
||||
</div>
|
||||
<t-upload
|
||||
:action="$store.state.user.apiUrl + '/api/common/upload'"
|
||||
v-model="formData.company_image_show"
|
||||
|
271
src/pages/tweets/detail.vue
Normal file
271
src/pages/tweets/detail.vue
Normal file
@ -0,0 +1,271 @@
|
||||
<template>
|
||||
<t-card title="青企圈详情" :bordered="false">
|
||||
<template #actions>
|
||||
<t-button theme="default" @click="goBack">返回列表</t-button>
|
||||
</template>
|
||||
<div v-if="loading" class="loading-container">
|
||||
<t-loading />
|
||||
</div>
|
||||
<div v-else class="tweet-detail-container">
|
||||
<div class="tweet-header">
|
||||
<h2 class="tweet-title">{{ detail.title }}</h2>
|
||||
<div class="tweet-meta">
|
||||
<span class="author">发布者: {{ detail.member?.nikename || '未知' }}</span>
|
||||
<span class="time">发布时间: {{ detail.createtime }}</span>
|
||||
<t-tag v-if="detail.is_top > 0" theme="warning">置顶</t-tag>
|
||||
<t-tag v-if="detail.status == 1" theme="warning">待审核</t-tag>
|
||||
<t-tag v-if="detail.status == 2" theme="success">已通过</t-tag>
|
||||
<t-tag v-if="detail.status == 3" theme="danger">已拒绝</t-tag>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="tweet-content">
|
||||
{{ detail.content }}
|
||||
</div>
|
||||
|
||||
<div class="tweet-images" v-if="detail.files && detail.files.length > 0">
|
||||
<h3>图片附件</h3>
|
||||
<t-image-viewer v-model="visible" :images="detail.files">
|
||||
<template #trigger="{ open }">
|
||||
<div class="image-grid">
|
||||
<div
|
||||
v-for="(image, index) in detail.files"
|
||||
:key="index"
|
||||
class="image-item"
|
||||
@click="open"
|
||||
>
|
||||
<img :src="image" :alt="`附件图片${index+1}`" />
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
</t-image-viewer>
|
||||
</div>
|
||||
|
||||
<div class="tweet-actions" v-if="detail.status == 1">
|
||||
<t-space>
|
||||
<t-popconfirm content="确定要审核通过吗?" @confirm="review(1)">
|
||||
<t-button theme="primary">通过</t-button>
|
||||
</t-popconfirm>
|
||||
<t-popconfirm theme="danger" @confirm="review(2)">
|
||||
<template #content>
|
||||
<p class="title">拒绝理由</p>
|
||||
<p class="describe" style="margin-top: 10px">
|
||||
<t-input v-model="reason" placeholder="请输入拒绝理由"/>
|
||||
</p>
|
||||
</template>
|
||||
<t-button theme="warning">拒绝</t-button>
|
||||
</t-popconfirm>
|
||||
</t-space>
|
||||
</div>
|
||||
|
||||
<div class="tweet-actions">
|
||||
<t-space>
|
||||
<t-button v-if="detail.is_top == 0" theme="success" @click="topNews">置顶</t-button>
|
||||
<t-button v-else theme="warning" @click="topNews">取消置顶</t-button>
|
||||
<t-popconfirm content="确认删除吗?" @confirm="del">
|
||||
<t-button theme="danger">删除</t-button>
|
||||
</t-popconfirm>
|
||||
</t-space>
|
||||
</div>
|
||||
</div>
|
||||
</t-card>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import store from "@/store";
|
||||
|
||||
interface StoreState {
|
||||
user: {
|
||||
apiUrl: string;
|
||||
};
|
||||
}
|
||||
|
||||
export default {
|
||||
name: 'TweetDetail',
|
||||
data() {
|
||||
return {
|
||||
loading: true,
|
||||
id: null,
|
||||
detail: {},
|
||||
visible: false,
|
||||
reason: '',
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
this.id = this.$route.params.id || this.$route.query.id;
|
||||
if (!this.id) {
|
||||
this.$message.error('参数错误,未找到对应的青企圈信息');
|
||||
this.goBack();
|
||||
return;
|
||||
}
|
||||
this.getDetail();
|
||||
},
|
||||
methods: {
|
||||
goBack() {
|
||||
this.$router.push('/tweets/index');
|
||||
},
|
||||
getDetail() {
|
||||
this.loading = true;
|
||||
this.$request
|
||||
.post('/tweets/detail', { id: this.id })
|
||||
.then((res) => {
|
||||
if (res.code == 1) {
|
||||
let detail = res.data;
|
||||
// 处理图片URL
|
||||
const apiUrl = (store.state as unknown as StoreState).user.apiUrl;
|
||||
if (detail.files && detail.files.length > 0) {
|
||||
detail.files = detail.files.map(file => apiUrl + file);
|
||||
} else {
|
||||
detail.files = [];
|
||||
}
|
||||
this.detail = detail;
|
||||
} else {
|
||||
this.$message.error(res.msg || '获取详情失败');
|
||||
setTimeout(() => {
|
||||
this.goBack();
|
||||
}, 1500);
|
||||
}
|
||||
})
|
||||
.catch((e) => {
|
||||
console.error(e);
|
||||
this.$message.error('获取详情失败');
|
||||
})
|
||||
.finally(() => {
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
topNews() {
|
||||
this.$request
|
||||
.post('/tweets/pin', { id: this.id })
|
||||
.then((res) => {
|
||||
if (res.code == 1) {
|
||||
this.$message.success(this.detail.is_top > 0 ? '取消置顶成功' : '置顶成功');
|
||||
this.getDetail();
|
||||
} else {
|
||||
this.$message.error(res.msg);
|
||||
}
|
||||
})
|
||||
.catch((e) => {
|
||||
console.error(e);
|
||||
this.$message.error('操作失败');
|
||||
});
|
||||
},
|
||||
review(type) {
|
||||
this.$request
|
||||
.post('/tweets/review', {
|
||||
id: this.id,
|
||||
status: type,
|
||||
reason: this.reason,
|
||||
member_id: this.detail.member_id
|
||||
})
|
||||
.then((res) => {
|
||||
if (res.code == 1) {
|
||||
this.$message.success(res.msg || '审核操作成功');
|
||||
this.getDetail();
|
||||
} else {
|
||||
this.$message.error(res.msg);
|
||||
}
|
||||
})
|
||||
.catch((e) => {
|
||||
console.error(e);
|
||||
this.$message.error('审核操作失败');
|
||||
});
|
||||
},
|
||||
del() {
|
||||
this.$request
|
||||
.post('/tweets/destroy', { id: this.id })
|
||||
.then((res) => {
|
||||
if (res.code == 1) {
|
||||
this.$message.success('删除成功!');
|
||||
this.goBack();
|
||||
} else {
|
||||
this.$message.error(res.msg);
|
||||
}
|
||||
})
|
||||
.catch((e) => {
|
||||
console.error(e);
|
||||
this.$message.error('删除失败');
|
||||
});
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.loading-container {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
padding: 50px 0;
|
||||
}
|
||||
|
||||
.tweet-detail-container {
|
||||
padding: 20px 0;
|
||||
}
|
||||
|
||||
.tweet-header {
|
||||
margin-bottom: 20px;
|
||||
padding-bottom: 15px;
|
||||
border-bottom: 1px solid #eee;
|
||||
}
|
||||
|
||||
.tweet-title {
|
||||
margin: 0 0 10px 0;
|
||||
font-size: 24px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.tweet-meta {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 15px;
|
||||
color: #666;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.tweet-content {
|
||||
margin-bottom: 30px;
|
||||
font-size: 16px;
|
||||
line-height: 1.6;
|
||||
white-space: pre-wrap;
|
||||
}
|
||||
|
||||
.tweet-images {
|
||||
margin-bottom: 30px;
|
||||
}
|
||||
|
||||
.tweet-images h3 {
|
||||
margin-bottom: 15px;
|
||||
font-size: 18px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.image-grid {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: 10px;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.image-item {
|
||||
width: 150px;
|
||||
height: 150px;
|
||||
overflow: hidden;
|
||||
border-radius: 4px;
|
||||
border: 1px solid #eee;
|
||||
}
|
||||
|
||||
.image-item img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: cover;
|
||||
transition: transform 0.3s;
|
||||
}
|
||||
|
||||
.image-item:hover img {
|
||||
transform: scale(1.05);
|
||||
}
|
||||
|
||||
.tweet-actions {
|
||||
margin-top: 20px;
|
||||
}
|
||||
</style>
|
@ -25,7 +25,7 @@
|
||||
<!-- <a v-for="item in row.files" :href="$store.state.user.apiUrl+item" target="_blank">-->
|
||||
<!-- <img :src="$store.state.user.apiUrl+item" style="width: 100px;margin-right: 10px"/>-->
|
||||
<!-- </a>-->
|
||||
<t-image-viewer v-model="visible[rowIndex]" :images="row.files" @close="delViewer(index)">
|
||||
<t-image-viewer v-model="visible[rowIndex]" :images="row.files" @close="delViewer(rowIndex)">
|
||||
<template #trigger="{ open }">
|
||||
<div @click="open" style="cursor: pointer" v-if="row.files.length>0">
|
||||
<img alt="test" :src="row.files[0]" style="width: 200px"/>
|
||||
@ -40,8 +40,9 @@
|
||||
</template>
|
||||
<template #select="{ row }">
|
||||
<t-space :size="0">
|
||||
<t-button theme="primary" @click="viewDetail(row)" style="margin-right: 10px">详情</t-button>
|
||||
<t-popconfirm v-if="row.status==1" content="确定要审核通过吗?" @confirm="review(row,1)">
|
||||
<t-button theme="primary">通过</t-button>
|
||||
<t-button theme="success">通过</t-button>
|
||||
</t-popconfirm>
|
||||
<t-popconfirm v-if="row.status==1" theme="danger" @confirm="review(row,2)">
|
||||
<template slot="content">
|
||||
@ -67,6 +68,50 @@
|
||||
></t-pagination>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 添加详情弹窗 -->
|
||||
<t-dialog
|
||||
:visible.sync="detailVisible"
|
||||
header="青企圈详情"
|
||||
:width="800"
|
||||
:footer="false"
|
||||
>
|
||||
<div v-if="detailLoading" class="loading-container">
|
||||
<t-loading />
|
||||
</div>
|
||||
<div v-else class="tweet-detail-container">
|
||||
<div class="tweet-header">
|
||||
<div class="tweet-meta">
|
||||
<span class="author">发布者: {{ detailInfo.member?.nikename || '未知' }}</span>
|
||||
<span class="time">发布时间: {{ detailInfo.createtime }}</span>
|
||||
<t-tag v-if="detailInfo.is_top > 0" theme="warning">置顶</t-tag>
|
||||
<t-tag v-if="detailInfo.status == 1" theme="warning">待审核</t-tag>
|
||||
<t-tag v-if="detailInfo.status == 2" theme="success">已通过</t-tag>
|
||||
<t-tag v-if="detailInfo.status == 3" theme="danger">已拒绝</t-tag>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="tweet-content" v-html="detailInfo.content"></div>
|
||||
|
||||
<div class="tweet-images" v-if="detailInfo.files && detailInfo.files.length > 0">
|
||||
<h3>图片附件</h3>
|
||||
<t-image-viewer v-model="detailImageVisible" :images="detailInfo.files">
|
||||
<template #trigger="{ open }">
|
||||
<div class="image-grid">
|
||||
<div
|
||||
v-for="(image, index) in detailInfo.files"
|
||||
:key="index"
|
||||
class="image-item"
|
||||
@click="open"
|
||||
>
|
||||
<img :src="image" :alt="`附件图片${index+1}`" />
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
</t-image-viewer>
|
||||
</div>
|
||||
</div>
|
||||
</t-dialog>
|
||||
</t-card>
|
||||
|
||||
</template>
|
||||
@ -74,6 +119,14 @@
|
||||
import store from "@/store";
|
||||
import {toInteger} from "lodash";
|
||||
|
||||
// 添加类型声明
|
||||
interface StoreState {
|
||||
user: {
|
||||
association: any;
|
||||
apiUrl: string;
|
||||
};
|
||||
}
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
@ -81,6 +134,13 @@ export default {
|
||||
state: 2,
|
||||
list: [],
|
||||
reason:'',
|
||||
association: null,
|
||||
// 详情弹窗相关
|
||||
detailVisible: false,
|
||||
detailLoading: false,
|
||||
detailInfo: {},
|
||||
detailImageVisible: false,
|
||||
currentDetailId: null,
|
||||
columns: [
|
||||
{colKey: 'title', title: '标题', align: 'center'},
|
||||
{colKey: 'content', title: '内容', align: 'center'},
|
||||
@ -109,13 +169,14 @@ export default {
|
||||
this.getList();
|
||||
},
|
||||
methods: {
|
||||
delViewer(d){
|
||||
console.log(d);
|
||||
delViewer(rowIndex){
|
||||
console.log(rowIndex);
|
||||
},
|
||||
tabIndexChange(index){
|
||||
this.state=index;
|
||||
this.pagination.page=1;
|
||||
this.getList();
|
||||
viewDetail(row) {
|
||||
// 修改为打开弹窗而不是导航
|
||||
this.currentDetailId = row.id;
|
||||
this.detailVisible = true;
|
||||
this.detailInfo = row;
|
||||
},
|
||||
topNews(row){
|
||||
console.log(row);
|
||||
@ -180,7 +241,7 @@ export default {
|
||||
console.log(res);
|
||||
if (res.code == 1) {
|
||||
var list = res.data.paginator.data;
|
||||
const apiUrl = store.state.user.apiUrl; // 假设这是你的 API URL
|
||||
const apiUrl = (store.state as unknown as StoreState).user.apiUrl;
|
||||
const transformedSelectList = list.map(item => ({
|
||||
...item, // 保留其他所有属性
|
||||
files: item.files.length > 0 ? item.files.map(file => apiUrl + file) : []
|
||||
@ -196,6 +257,136 @@ export default {
|
||||
console.log(e);
|
||||
});
|
||||
},
|
||||
topNewsDetail() {
|
||||
this.$request
|
||||
.post('/tweets/pin', { id: this.currentDetailId })
|
||||
.then((res) => {
|
||||
if (res.code == 1) {
|
||||
this.$message.success(this.detailInfo.is_top > 0 ? '取消置顶成功' : '置顶成功');
|
||||
this.getDetailInfo(); // 刷新详情
|
||||
this.getList(); // 刷新列表
|
||||
} else {
|
||||
this.$message.error(res.msg);
|
||||
}
|
||||
})
|
||||
.catch((e) => {
|
||||
console.error(e);
|
||||
this.$message.error('操作失败');
|
||||
});
|
||||
},
|
||||
reviewDetail(type) {
|
||||
this.$request
|
||||
.post('/tweets/review', {
|
||||
id: this.currentDetailId,
|
||||
status: type,
|
||||
reason: this.reason,
|
||||
member_id: this.detailInfo.member_id
|
||||
})
|
||||
.then((res) => {
|
||||
if (res.code == 1) {
|
||||
this.$message.success(res.msg || '审核操作成功');
|
||||
this.detailVisible = false; // 关闭弹窗
|
||||
this.getList(); // 刷新列表
|
||||
} else {
|
||||
this.$message.error(res.msg);
|
||||
}
|
||||
})
|
||||
.catch((e) => {
|
||||
console.error(e);
|
||||
this.$message.error('审核操作失败');
|
||||
});
|
||||
},
|
||||
delDetail() {
|
||||
this.$request
|
||||
.post('/tweets/destroy', { id: this.currentDetailId })
|
||||
.then((res) => {
|
||||
if (res.code == 1) {
|
||||
this.$message.success('删除成功!');
|
||||
this.detailVisible = false; // 关闭弹窗
|
||||
this.getList(); // 刷新列表
|
||||
} else {
|
||||
this.$message.error(res.msg);
|
||||
}
|
||||
})
|
||||
.catch((e) => {
|
||||
console.error(e);
|
||||
this.$message.error('删除失败');
|
||||
});
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
/* 详情弹窗样式 */
|
||||
.loading-container {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
padding: 50px 0;
|
||||
}
|
||||
|
||||
.tweet-detail-container {
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.tweet-header {
|
||||
margin-bottom: 20px;
|
||||
padding-bottom: 15px;
|
||||
border-bottom: 1px solid #eee;
|
||||
}
|
||||
|
||||
.tweet-meta {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 15px;
|
||||
color: #666;
|
||||
font-size: 14px;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.tweet-content {
|
||||
margin-bottom: 30px;
|
||||
font-size: 16px;
|
||||
line-height: 1.6;
|
||||
white-space: pre-wrap;
|
||||
}
|
||||
|
||||
.tweet-images {
|
||||
margin-bottom: 30px;
|
||||
}
|
||||
|
||||
.tweet-images h3 {
|
||||
margin-bottom: 15px;
|
||||
font-size: 18px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.image-grid {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: 10px;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.image-item {
|
||||
width: 120px;
|
||||
overflow: hidden;
|
||||
border-radius: 4px;
|
||||
border: 1px solid #eee;
|
||||
}
|
||||
|
||||
.image-item img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: cover;
|
||||
transition: transform 0.3s;
|
||||
}
|
||||
|
||||
.image-item:hover img {
|
||||
transform: scale(1.05);
|
||||
}
|
||||
|
||||
.tweet-actions {
|
||||
margin-top: 20px;
|
||||
}
|
||||
</style>
|
||||
|
@ -153,7 +153,7 @@
|
||||
<t-option value="九三学社社员" label="九三学社社员" key="九三学社社员"></t-option>
|
||||
<t-option value="台盟盟员" label="台盟盟员" key="台盟盟员"></t-option>
|
||||
<t-option value="无党派人士" label="无党派人士" key="无党派人士"></t-option>
|
||||
<t-option value="无党派人士" label="无党派人士" key="无党派人士"></t-option>
|
||||
<t-option value="群众" label="群众" key="群众"></t-option>
|
||||
</t-select>
|
||||
</t-form-item>
|
||||
<t-form-item label="身份证号码">
|
||||
|
@ -162,7 +162,7 @@
|
||||
<t-option value="九三学社社员" label="九三学社社员" key="九三学社社员"></t-option>
|
||||
<t-option value="台盟盟员" label="台盟盟员" key="台盟盟员"></t-option>
|
||||
<t-option value="无党派人士" label="无党派人士" key="无党派人士"></t-option>
|
||||
<t-option value="无党派人士" label="无党派人士" key="无党派人士"></t-option>
|
||||
<t-option value="群众" label="群众" key="群众"></t-option>
|
||||
</t-select>
|
||||
</t-form-item>
|
||||
<t-form-item label="身份证号码">
|
||||
|
@ -1,6 +1,10 @@
|
||||
<template>
|
||||
<div class="detail-base">
|
||||
<t-card title="会员详情" :bordered="false" class="info-block" style="padding: 30px">
|
||||
<template #actions>
|
||||
<t-button theme="primary" @click="openPDF" size="large" style="margin-left: 20px">查看PDF文件</t-button>
|
||||
</template>
|
||||
<div>
|
||||
<t-steps :current="0" readonly v-if="info.if_xianshi != 1">
|
||||
<t-step-item title="信息审核" content="提交的信息审核"></t-step-item>
|
||||
<t-step-item v-if="info.if_xianshi != 2" title="会费缴纳" content="等待会费缴纳"></t-step-item>
|
||||
@ -8,7 +12,8 @@
|
||||
:content="info.result.content"></t-step-item>
|
||||
<t-step-item title="成功入会" content="已成功入会"></t-step-item>
|
||||
</t-steps>
|
||||
<div>
|
||||
</div>
|
||||
<div style="margin-top: 20px;">
|
||||
<div>
|
||||
<div style="color: #2E2E2E;font-size: 28px;font-weight: bold">1.入会资料</div>
|
||||
<div style="height: 2px;background-color: #999999;width: 100%;margin-top: 20px"></div>
|
||||
@ -52,7 +57,8 @@
|
||||
:closeOnEscKeydown="false">
|
||||
<template #trigger="{ open }">
|
||||
<div style="cursor: pointer" @click="open">
|
||||
<img v-if="info.photo_image!=''&&info.photo_image!=null" :src="$store.state.user.apiUrl+info.photo_image" style="width: 200px;height: 200px;">
|
||||
<img v-if="info.photo_image != '' && info.photo_image != null"
|
||||
:src="$store.state.user.apiUrl + info.photo_image" style="width: 150px;">
|
||||
<span v-if="info.photo_image == '' || info.photo_image == null">未上传</span>
|
||||
</div>
|
||||
</template>
|
||||
@ -61,7 +67,7 @@
|
||||
<td>姓名</td>
|
||||
<td>{{ info.nikename }}</td>
|
||||
<td>性别</td>
|
||||
<td>{{ info.gender == 0 ? '女' : '男' }}</td>
|
||||
<td>{{ info.gender === 0 ? '女' : info.gender === 1 ? '男' : '未填写' }}</td>
|
||||
<td>协会职务</td>
|
||||
<td>{{ info.position_name }}</td>
|
||||
<td>出生年月日</td>
|
||||
@ -113,7 +119,8 @@
|
||||
:closeOnEscKeydown="false">
|
||||
<template #trigger="{ open }">
|
||||
<div style="cursor: pointer" @click="open">
|
||||
<img v-if="info.cardz_image!=''&&info.cardz_image!=null" :src="$store.state.user.apiUrl+info.cardz_image" style="height: 150px;">
|
||||
<img v-if="info.cardz_image != '' && info.cardz_image != null"
|
||||
:src="$store.state.user.apiUrl + info.cardz_image" style="height: 150px;">
|
||||
<span v-if="info.cardz_image == '' || info.cardz_image == null">未上传</span>
|
||||
</div>
|
||||
</template>
|
||||
@ -125,7 +132,8 @@
|
||||
:closeOnEscKeydown="false">
|
||||
<template #trigger="{ open }">
|
||||
<div style="cursor: pointer" @click="open">
|
||||
<img v-if="info.cardf_image!=''&&info.cardf_image!=null" :src="$store.state.user.apiUrl+info.cardf_image" style="height: 150px;">
|
||||
<img v-if="info.cardf_image != '' && info.cardf_image != null"
|
||||
:src="$store.state.user.apiUrl + info.cardf_image" style="height: 150px;">
|
||||
<span v-if="info.cardf_image == '' || info.cardf_image == null">未上传</span>
|
||||
</div>
|
||||
</template>
|
||||
@ -221,7 +229,8 @@
|
||||
<td colspan="1">{{ info.enterprise_location }}</td>
|
||||
<td>企业地址</td>
|
||||
<td colspan="1">
|
||||
<a href="https://lbs.qq.com/tool/getpoint/get-point.html" target="_blank">{{ info.longitude }},{{ info.dimension }}</a>
|
||||
<a href="https://lbs.qq.com/tool/getpoint/get-point.html" target="_blank">{{ info.longitude }},{{
|
||||
info.dimension }}</a>
|
||||
</td>
|
||||
<td>注册资金(万元)</td>
|
||||
<td>{{ info.registered_capital }}</td>
|
||||
@ -257,7 +266,8 @@
|
||||
:closeOnEscKeydown="false">
|
||||
<template #trigger="{ open }">
|
||||
<div style="cursor: pointer" @click="open">
|
||||
<img v-if="info.business_license_image!=''&&info.business_license_image!=null" :src="$store.state.user.apiUrl + info.business_license_image" style="height: 150px; ">
|
||||
<img v-if="info.business_license_image != '' && info.business_license_image != null"
|
||||
:src="$store.state.user.apiUrl + info.business_license_image" style="height: 150px; ">
|
||||
<span v-if="info.business_license_image == '' || info.business_license_image == null">未上传</span>
|
||||
</div>
|
||||
</template>
|
||||
@ -271,7 +281,8 @@
|
||||
:closeOnEscKeydown="false">
|
||||
<template #trigger="{ open }">
|
||||
<div style="cursor: pointer" @click="open">
|
||||
<img v-if="info.company_image!=''&&info.company_image!=null" :src="$store.state.user.apiUrl + info.company_image" style="height: 150px; ">
|
||||
<img v-if="info.company_image != '' && info.company_image != null"
|
||||
:src="$store.state.user.apiUrl + info.company_image" style="height: 150px; ">
|
||||
<span v-if="info.company_image == '' || info.company_image == null">未上传</span>
|
||||
</div>
|
||||
</template>
|
||||
@ -354,7 +365,8 @@
|
||||
:closeOnEscKeydown="false">
|
||||
<template #trigger="{ open }">
|
||||
<div style="cursor: pointer" @click="open">
|
||||
<img v-if="info.documents_file!=''&&info.documents_file!=null" :src="$store.state.user.apiUrl + info.documents_file" style="height: 150px; ">
|
||||
<img v-if="info.documents_file != '' && info.documents_file != null"
|
||||
:src="$store.state.user.apiUrl + info.documents_file" style="height: 150px; ">
|
||||
<span v-if="info.documents_file == '' || info.documents_file == null">未上传</span>
|
||||
</div>
|
||||
</template>
|
||||
@ -412,6 +424,7 @@
|
||||
<t-button theme="primary" size="large" style="margin-left: 20px">会费已缴纳</t-button>
|
||||
</t-popconfirm>
|
||||
</div>
|
||||
|
||||
</t-card>
|
||||
</div>
|
||||
</template>
|
||||
@ -437,6 +450,27 @@ export default {
|
||||
this.getInfo();
|
||||
},
|
||||
methods: {
|
||||
openPDF() {
|
||||
const link = document.createElement('a');
|
||||
if (this.info.openid == '' || this.info.openid == null) {
|
||||
//const token = this.$store.state.user.token;
|
||||
//link.href = `https://hnyea.0rui.cn/api/member/getMemberPdf?member_id=${this.info.member_id}&token=${token}`;
|
||||
this.$message.error('当前用户暂无法生成PDF');
|
||||
return;
|
||||
} else {
|
||||
if (this.info.pdf_url == '' || this.info.pdf_url == null) {
|
||||
link.href = `https://hnyea.0rui.cn/api/move/pdf_member/exportPdf?openid=${this.info.openid}`;
|
||||
} else {
|
||||
link.href = `https://hnyea.0rui.cn${this.info.pdf_url}`;
|
||||
}
|
||||
}
|
||||
link.target = '_blank'; // 新标签页打开
|
||||
link.rel = 'noopener noreferrer'; // 安全考虑
|
||||
link.style.display = 'none';
|
||||
document.body.appendChild(link);
|
||||
link.click();
|
||||
document.body.removeChild(link); // 清理 DOM
|
||||
},
|
||||
getInfo() {
|
||||
this.$request
|
||||
.post("/member/find", { member_id: this.member_id })
|
||||
@ -482,12 +516,14 @@ export default {
|
||||
}
|
||||
|
||||
.my_table {
|
||||
border-collapse: collapse; /* 合并边框 */
|
||||
border-collapse: collapse;
|
||||
/* 合并边框 */
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.my_table td {
|
||||
border: 1px solid black; /* 设置单元格边框 */
|
||||
border: 1px solid black;
|
||||
/* 设置单元格边框 */
|
||||
text-align: center;
|
||||
min-width: 100px;
|
||||
padding: 13px;
|
||||
|
@ -1,8 +1,8 @@
|
||||
import axios from 'axios';
|
||||
import store from '../store';
|
||||
//const API_HOST = env === 'mock' ? '/' : proxy[env].API; // 如果是mock模式 就不配置host 会走本地Mock拦截
|
||||
//const API_HOST = 'https://hnyea.0rui.cn/api/';
|
||||
const API_HOST = '/api/';
|
||||
const API_HOST = 'https://hnyea.0rui.cn/api/';
|
||||
//const API_HOST = '/api/';
|
||||
const CODE = {
|
||||
LOGIN_TIMEOUT: 1000000,
|
||||
REQUEST_SUCCESS: 0,
|
||||
|
Loading…
x
Reference in New Issue
Block a user