This commit is contained in:
王创世 2024-04-18 17:57:52 +08:00
parent 2284534e06
commit b7be4ee343
6 changed files with 654 additions and 97 deletions

View File

@ -173,7 +173,7 @@ export default Vue.extend({
handleLogout() {
this.$store.commit('user/removeAssociation');
this.$store.commit('user/removeToken');
this.$router.push(`/login`);
this.$router.push(`/login?id=`+this.association.id);
//this.$router.push(`/login?redirect=${this.$router.history.current.fullPath}`);
},
changeCollapsed() {

View File

@ -45,7 +45,7 @@
<t-checkbox>记住账号</t-checkbox>
<div style="color: var(--td-brand-color)">
<span @click="openUrl(0)">会员注册</span>
<span style="margin-left: 20px" @click="openUrl(1)">会员登录</span>
<!-- <span style="margin-left: 20px" @click="openUrl(1)">会员登录</span>-->
</div>
</div>
</template>

View File

@ -8,7 +8,8 @@
</t-steps>
<div style="margin-top: 40px">
<template v-if="current==0">
<t-card :title="info.association_name+'入会须知'" :bordered="true" hover-shadow :style="{ width: '1200px',margin:'0 auto' }">
<t-card :title="info.association_name+'入会须知'" :bordered="true" hover-shadow
:style="{ width: '1200px',margin:'0 auto' }">
<div v-html="info.ruhuixizhu"
style="height: 500px; overflow-y: auto;white-space: break-spaces;line-height: 25px;"></div>
<div style="text-align: center;padding: 20px">
@ -20,99 +21,321 @@
</t-card>
</template>
<template v-if="current==1">
<t-card title="安装环境监测" :bordered="true" hover-shadow :style="{ width: '1200px',margin:'0 auto' }">
<div style="text-align: center;padding: 20px">
<t-table
row-key="index"
:data="receiveCode"
:columns="columns"
<t-card title="会员信息填写" :bordered="true" hover-shadow :style="{ width: '1200px',margin:'0 auto' }">
<div style="padding: 20px">
<div style="padding-bottom: 20px;font-weight: bold">登陆信息</div>
<t-form
layout="inline"
labelAlign="top"
>
<template #value="{ row }">
<t-tag style="cursor: pointer" v-if="row.check==0" theme="danger">{{ row.value }}</t-tag>
<t-tag style="cursor: pointer" v-if="row.check==1" theme="success">{{ row.value }}</t-tag>
</template>
</t-table>
<t-form-item label="手机号" name="phone">
<t-input v-model="formData.phone" placeholder="请输入手机号"></t-input>
</t-form-item>
<t-form-item label="密码" name="password">
<t-input v-model="formData.password" placeholder="请输入密码"></t-input>
</t-form-item>
</t-form>
</div>
<div style="text-align: center">
<div style="padding: 20px">
<div style="padding-bottom: 20px;font-weight: bold">人员信息</div>
<t-form
labelAlign="top"
layout="inline"
>
<t-form-item label="真实姓名" name="nikename">
<t-input v-model="formData.nikename" placeholder="请输入真实姓名"></t-input>
</t-form-item>
<t-form-item label="性别" name="gender">
<t-select v-model="formData.gender" :style="{ width: '200px' }">
<t-option key="0" label="女" value="0"></t-option>
<t-option key="1" label="男" value="1"></t-option>
</t-select>
</t-form-item>
<t-form-item label="民族" name="nation">
<t-input v-model="formData.nation" placeholder="请输入民族"></t-input>
</t-form-item>
<t-form-item label="政治面貌" name="political">
<t-input v-model="formData.political" placeholder="请输入政治面貌"></t-input>
</t-form-item>
<t-form-item label="出生日期" name="birth_time">
<t-date-picker :style="{ width: '200px' }" v-model="formData.birth_time"/>
</t-form-item>
<t-form-item label="身份证号码" name="card_number">
<t-input v-model="formData.card_number" placeholder="请输入身份证号码"></t-input>
</t-form-item>
<t-form-item label="籍贯" name="jiguan">
<t-input v-model="formData.jiguan" placeholder="请输入籍贯"></t-input>
</t-form-item>
<t-form-item label="毕业院校" name="institution">
<t-input v-model="formData.institution" placeholder="请输入毕业院校"></t-input>
</t-form-item>
<t-form-item label="学历" name="education">
<t-input v-model="formData.education" placeholder="请输入学历"></t-input>
</t-form-item>
<t-form-item label="学位" name="academic_degree">
<t-input v-model="formData.academic_degree" placeholder="请输入学位"></t-input>
</t-form-item>
<t-form-item label="工作单位" name="academic_degree">
<t-input v-model="formData.work_unit" placeholder="请输入工作单位"></t-input>
</t-form-item>
<t-form-item label="单位职务" name="unit_position">
<t-input v-model="formData.unit_position" placeholder="请输入单位职务"></t-input>
</t-form-item>
<t-form-item label="微信号" name="wx_number">
<t-input v-model="formData.wx_number" placeholder="请输入微信号"></t-input>
</t-form-item>
<t-form-item label="邮箱" name="mailbox">
<t-input v-model="formData.mailbox" placeholder="请输入邮箱"></t-input>
</t-form-item>
<t-form-item label="固定电话" name="fixed_telephone">
<t-input v-model="formData.fixed_telephone" placeholder="请输入固定电话"></t-input>
</t-form-item>
<t-form-item label="其他社会职务" name="other_social_positions">
<t-input v-model="formData.other_social_positions" placeholder="请输入其他社会职务"></t-input>
</t-form-item>
<t-form-item label="其他联系人" name="other_contacts">
<t-input v-model="formData.other_contacts" placeholder="请输入其他联系人"></t-input>
</t-form-item>
<t-form-item label="意向协会职务" name="position">
<t-input v-model="formData.position" placeholder="请输入意向协会职务"></t-input>
</t-form-item>
<t-form-item label="主要成就以及获奖情况" name="achievement_award">
<t-textarea placeholder="请输入主要成就以及获奖情况" :autosize="{ minRows: 3, maxRows: 5 }"
v-model="formData.achievement_award"/>
</t-form-item>
</t-form>
</div>
<div style="padding: 0px 20px">
<t-form labelAlign="top"
layout="inline">
<t-form-item label="证件照">
<t-upload
:action="$store.state.user.apiUrl+'/api/common/upload'"
v-model="formData.photo_image_show"
theme="image"
tips="请选择证件照"
accept="image/*"
:format-response="(response) => formatResponse(response, 0)"
></t-upload>
</t-form-item>
<t-form-item label="身份证正面照">
<t-upload
:action="$store.state.user.apiUrl+'/api/common/upload'"
v-model="formData.cardz_image_show"
theme="image"
tips="请选择身份证正面照"
accept="image/*"
:format-response="(response) => formatResponse(response, 1)"
></t-upload>
</t-form-item>
<t-form-item label="身份证反面照">
<t-upload
:action="$store.state.user.apiUrl+'/api/common/upload'"
v-model="formData.cardf_image_show"
theme="image"
tips="请选择身份证反面照"
accept="image/*"
:format-response="(response) => formatResponse(response, 2)"
></t-upload>
</t-form-item>
</t-form>
</div>
<div style="text-align: center;margin-top: 40px">
<t-space :style="{ width: '300px',margin:'0 auto',textAlign:'center' }">
<t-button @click="getreceiveCode">重新检测</t-button>
<t-button @click="okreceiveCode">下一步</t-button>
</t-space>
</div>
</t-card>
</template>
<!-- <template v-if="current==2">-->
<!-- <t-card title="数据库信息" :bordered="true" hover-shadow :style="{ width: '900px',margin:'0 auto' }">-->
<!-- <t-form-->
<!-- :data="formData"-->
<!-- :rules="rules"-->
<!-- @submit="onSubmit"-->
<!-- :label-width="150"-->
<!-- >-->
<!-- <t-space direction="vertical" :size="40">-->
<!-- <t-form-item label="数据库地址" name="database_ip">-->
<!-- <t-input :style="{ width: '480px' }" v-model="formData.database_ip"-->
<!-- placeholder="请填写数据库地址"></t-input>-->
<!-- </t-form-item>-->
<!-- <t-form-item label="数据库端口" name="database_no">-->
<!-- <t-input :style="{ width: '480px' }" v-model="formData.database_no"-->
<!-- placeholder="请填写数据库端口"></t-input>-->
<!-- </t-form-item>-->
<!-- <t-form-item label="数据库名称" name="database_name">-->
<!-- <t-input :style="{ width: '480px' }" v-model="formData.database_name"-->
<!-- placeholder="请填写数据库名称"></t-input>-->
<!-- </t-form-item>-->
<!-- <t-form-item label="数据库用户名" name="database_user_name">-->
<!-- <t-input :style="{ width: '480px' }" v-model="formData.database_user_name"-->
<!-- placeholder="请填写数据库用户名"></t-input>-->
<!-- </t-form-item>-->
<!-- <t-form-item label="数据库密码" name="database_pwd">-->
<!-- <t-input :style="{ width: '480px' }" v-model="formData.database_pwd"-->
<!-- placeholder="请填写数据库密码"></t-input>-->
<!-- </t-form-item>-->
<!-- <div style="font-weight: 600;font-size: 16px">创始人信息</div>-->
<!-- <t-form-item label="管理员账号" name="admin_user_name">-->
<!-- <t-input :style="{ width: '480px' }" v-model="formData.admin_user_name"-->
<!-- placeholder="请填写管理员账号"></t-input>-->
<!-- </t-form-item>-->
<!-- <t-form-item label="管理员密码" name="admin_user_pwd">-->
<!-- <t-input :style="{ width: '480px' }" v-model="formData.admin_user_pwd"-->
<!-- placeholder="请填写管理员密码"></t-input>-->
<!-- </t-form-item>-->
<!-- <t-form-item label="重复密码" name="admin_user_pwd2">-->
<!-- <t-input :style="{ width: '480px' }" v-model="formData.admin_user_pwd2"-->
<!-- placeholder="请重复填写密码"></t-input>-->
<!-- </t-form-item>-->
<!-- <t-form-item label="二级密码" help="升级框架、卸载应用的时候需要验证,请妥善保管" name="admin_two_pwd">-->
<!-- <t-input :style="{ width: '480px' }" v-model="formData.admin_two_pwd"-->
<!-- placeholder="请填写二级密码"></t-input>-->
<!-- </t-form-item>-->
<!-- <t-form-item>-->
<!-- <t-space :style="{ width: '300px',margin:'0 auto',textAlign:'center' }">-->
<!-- <t-button theme="primary" type="submit">创建数据</t-button>-->
<!-- </t-space>-->
<!-- </t-form-item>-->
<!-- </t-space>-->
<!-- </t-form>-->
<!-- </t-card>-->
<!-- </template>-->
<template v-if="current==2">
<t-card title="公司信息填写" :bordered="true" hover-shadow :style="{ width: '1200px',margin:'0 auto' }">
<div style="padding: 20px">
<t-form labelAlign="top"
layout="inline">
<t-form-item label="营业执照">
<t-upload
:action="$store.state.user.apiUrl+'/api/common/upload'"
v-model="formData.business_license_image_show"
theme="image"
tips="请选择营业执照"
accept="image/*"
:format-response="(response) => formatResponse(response, 3)"
></t-upload>
</t-form-item>
<t-form-item label="统一社会信用代码" name="unified_code">
<t-input v-model="formData.unified_code" placeholder="请输入统一社会信用代码"></t-input>
</t-form-item>
<t-form-item label="企业性质" name="enterprise_nature">
<t-input v-model="formData.enterprise_nature" placeholder="请输入企业性质"></t-input>
</t-form-item>
<t-form-item label="企业网址" name="enterprise_website">
<t-input v-model="formData.enterprise_website" placeholder="请输入企业网址"></t-input>
</t-form-item>
<t-form-item label="是否上市" name="if_list">
<t-select v-model="formData.if_list" :style="{ width: '200px' }">
<t-option key="0" label="是" value="0"></t-option>
<t-option key="1" label="否" value="1"></t-option>
</t-select>
</t-form-item>
<t-form-item label="员工人数" name="employee">
<t-input v-model="formData.employee" placeholder="请输入员工人数"></t-input>
</t-form-item>
<t-form-item label="企业注册地" name="enterprise_location">
<t-input v-model="formData.enterprise_location" placeholder="请输入企业注册地"></t-input>
</t-form-item>
<t-form-item label="上年度营业额" name="previous_revenue">
<t-input v-model="formData.previous_revenue" placeholder="请输入上年度营业额"></t-input>
</t-form-item>
<t-form-item label="上年度纳税额" name="previous_tax">
<t-input v-model="formData.previous_tax" placeholder="请输入上年度纳税额"></t-input>
</t-form-item>
<t-form-item label="上年度净利润" name="previous_profit">
<t-input v-model="formData.previous_profit" placeholder="请输入上年度净利润"></t-input>
</t-form-item>
<t-form-item label="上年度公益性捐赠支出" name="previous_donation">
<t-input v-model="formData.previous_donation" placeholder="上年度公益性捐赠支出"></t-input>
</t-form-item>
<t-form-item label="其他企业任职情况" name="qitaqiyerenzhiqingkuang">
<t-input v-model="formData.qitaqiyerenzhiqingkuang" placeholder="其他企业任职情况"></t-input>
</t-form-item>
<t-form-item label="企业介绍" name="enterprise_Introduction">
<t-textarea placeholder="请输入企业介绍" :autosize="{ minRows: 3, maxRows: 5 }"
v-model="formData.enterprise_Introduction"/>
</t-form-item>
<t-form-item label="业务介绍" name="introdiction">
<t-textarea placeholder="请输入业务介绍" :autosize="{ minRows: 3, maxRows: 5 }"
v-model="formData.introdiction"/>
</t-form-item>
<t-form-item label="企业所获荣誉以及专利" name="enterprise_honor">
<t-textarea placeholder="请输入企业所获荣誉以及专利" :autosize="{ minRows: 3, maxRows: 5 }"
v-model="formData.enterprise_honor"/>
</t-form-item>
</t-form>
<t-form labelAlign="top"
layout="inline">
<t-form-item label="是否建立团组织" name="if_organization">
<t-select v-model="formData.if_organization" :style="{ width: '200px' }">
<t-option key="0" label="是" value="0"></t-option>
<t-option key="1" label="否" value="1"></t-option>
</t-select>
</t-form-item>
</t-form>
<t-form v-if="formData.if_organization==0" labelAlign="top"
layout="inline">
<t-form-item label="团组织性质" name="nature">
<t-input v-model="formData.nature" placeholder="团组织性质"></t-input>
</t-form-item>
<t-form-item label="建团时间" name="jiantuan_time">
<t-date-picker :style="{ width: '200px' }" v-model="formData.jiantuan_time"/>
</t-form-item>
<t-form-item label="建团人数" name="jiantuan_number">
<t-input v-model="formData.jiantuan_number" placeholder="建团人数"></t-input>
</t-form-item>
<t-form-item label="青年人数" name="youth_number">
<t-input v-model="formData.youth_number" placeholder="青年人数"></t-input>
</t-form-item>
<t-form-item label="上级团组织" name="superior_nature">
<t-input v-model="formData.superior_nature" placeholder="上级团组织"></t-input>
</t-form-item>
<t-form-item label="团委负责人信息" name="tuanweifuzerenxinxi">
<t-input v-model="formData.tuanweifuzerenxinxi" placeholder="团委负责人信息"></t-input>
</t-form-item>
<t-form-item label="批复文件">
<t-upload
:action="$store.state.user.apiUrl+'/api/common/upload'"
v-model="formData.documents_file_show"
theme="image"
tips="请选择批复文件(图片)"
accept="image/*"
:format-response="(response) => formatResponse(response, 4)"
></t-upload>
</t-form-item>
</t-form>
<div style="text-align: center;margin-top: 40px">
<t-space :style="{ width: '300px',margin:'0 auto',textAlign:'center' }">
<t-button @click="current=1" theme="default">上一步</t-button>
<t-button @click="submit">提交申请</t-button>
</t-space>
</div>
</div>
</t-card>
</template>
</div>
</t-card>
<div class="result-success">
<check-circle-icon class="result-success-icon" />
<div class="result-success-title">申请已提交</div>
<div class="result-success-describe">登陆小程序可查看审核结果</div>
<div>
<t-button @click="() => this.$router.push('/login?id='+id)">返回首页</t-button>
</div>
</div>
</div>
</template>
<script>
import {UserIcon, LockOnIcon} from 'tdesign-icons-vue';
import { CheckCircleIcon } from 'tdesign-icons-vue';
export default {
components: {
CheckCircleIcon,
UserIcon,
LockOnIcon,
},
data() {
return {
formData: {
zhanghu: '',
phone: '',
password: '',
nikename: '',
gender: null,
birth_time: '',
nation: '',
political: '',
jiguan: '',
institution: '',
education: '',
academic_degree: '',
card_number: '',
work_unit: '',
unit_position: '',
wx_number: '',
mailbox: '',
fixed_telephone: '',
achievement_award: '',
other_contacts: '',
other_social_positions: '',
position: '',
cardf_image_show: [],
cardz_image_show: [],
photo_image_show: [],
cardf_image: '',
cardz_image: '',
photo_image: '',
business_license_image_show: [],
business_license_image: '',
unified_code: '',
enterprise_nature: '',
enterprise_website: '',
if_list: null,
employee: '',
previous_revenue: '',
previous_tax: '',
previous_profit: '',
previous_donation: '',
qitaqiyerenzhiqingkuang: '',
enterprise_Introduction: '',
introdiction: '',
enterprise_honor: '',
if_organization: null,
nature: '',
jiantuan_time: '',
jiantuan_number: '',
youth_number: '',
superior_nature: '',
tuanweifuzerenxinxi: '',
documents_file: '',
documents_file_show: []
},
ok: false,
current: 0,
@ -130,6 +353,22 @@ export default {
}
},
methods: {
formatResponse(res, type) {
console.log(res);
if (type == 0) {
this.formData.photo_image = res.data.url;
} else if (type == 1) {
this.formData.cardz_image = res.data.url;
} else if (type == 2) {
this.formData.cardf_image = res.data.url;
} else if (type == 3) {
this.formData.business_license_image = res.data.url;
} else {
this.formData.documents_file = res.data.url;
}
return {url: res.data.fullurl};
},
getInfo() {
this.$request
.post("/association/find", {association_id: this.id})
@ -151,10 +390,250 @@ export default {
this.current = 1;
//this.getreceiveCode();
},
okreceiveCode() {
//
if (this.formData.phone == '') {
this.$message.error('请输入手机号!');
return;
}
if (this.formData.password == '') {
this.$message.error('请输入密码!');
return;
}
if (this.formData.nikename == '') {
this.$message.error('请输入真实姓名!');
return;
}
if (this.formData.birth_time == '') {
this.$message.error('请输入出生日期!');
return;
}
if (this.formData.gender == null) {
this.$message.error('请选择性别!');
return;
}
if (this.formData.nation == '') {
this.$message.error('请输入民族!');
return;
}
if (this.formData.political == '') {
this.$message.error('请输入政治面貌!');
return;
}
if (this.formData.jiguan == '') {
this.$message.error('请输入籍贯!');
return;
}
if (this.formData.institution == '') {
this.$message.error('请输入毕业院校!');
return;
}
if (this.formData.education == '') {
this.$message.error('请输入学历!');
return;
}
if (this.formData.academic_degree == '') {
this.$message.error('请输入学位!');
return;
}
if (this.formData.card_number == '') {
this.$message.error('请输入身份证号!');
return;
}
if (this.formData.work_unit == '') {
this.$message.error('请输入工作单位!');
return;
}
if (this.formData.unit_position == '') {
this.$message.error('请输入单位职务!');
return;
}
if (this.formData.wx_number == '') {
this.$message.error('请输入微信号!');
return;
}
if (this.formData.mailbox == '') {
this.$message.error('请输入邮箱!');
return;
}
if (this.formData.fixed_telephone == '') {
this.$message.error('请输入固定电话!');
return;
}
if (this.formData.achievement_award == '') {
this.$message.error('请输主要成就以及获奖情况!');
return;
}
if (this.formData.other_contacts == '') {
this.$message.error('请输入其他联系人!');
return;
}
if (this.formData.other_social_positions == '') {
this.$message.error('请输入其他社会职务!');
return;
}
if (this.formData.position == '') {
this.$message.error('请输入意向协会职务!');
return;
}
if (this.formData.cardf_image == '') {
this.$message.error('请上传身份证正面!');
return;
}
if (this.formData.cardz_image == '') {
this.$message.error('请上传身份证反面!');
return;
}
if (this.formData.photo_image == '') {
this.$message.error('请上传个人照片!');
return;
}
this.current = 2;
},
submit(){
if (this.formData.business_license_image == '') {
this.$message.error('请上传营业执照!');
return;
}
if (this.formData.unified_code == '') {
this.$message.error('请输入统一社会信用代码!');
return;
}
if (this.formData.enterprise_nature == '') {
this.$message.error('请输入企业性质!');
return;
}
if (this.formData.enterprise_website == '') {
this.$message.error('请输入企业网址!');
return;
}
if (this.formData.if_list == null) {
this.$message.error('请选择是否上市!');
return;
}
if (this.formData.employee == '') {
this.$message.error('请输入员工人数!');
return;
}
if (this.formData.enterprise_location == '') {
this.$message.error('请输入企业注册地!');
return;
}
if (this.formData.previous_revenue == '') {
this.$message.error('请输入上年度营业额!');
return;
}
if (this.formData.previous_tax == '') {
this.$message.error('请输入上年度纳税额!');
return;
}
if (this.formData.education == '') {
this.$message.error('请输入学历!');
return;
}
if (this.formData.previous_profit == '') {
this.$message.error('请输入上年度净利润!');
return;
}
if (this.formData.previous_donation == '') {
this.$message.error('请输入上年度公益性捐赠支出!');
return;
}
if (this.formData.qitaqiyerenzhiqingkuang == '') {
this.$message.error('请输入其他企业任职情况!');
return;
}
if (this.formData.enterprise_Introduction == '') {
this.$message.error('请输入企业介绍!');
return;
}
if (this.formData.introdiction == '') {
this.$message.error('请输入业务介绍!');
return;
}
if (this.formData.enterprise_honor == '') {
this.$message.error('请输入企业所获荣誉以及专利!');
return;
}
if (this.formData.if_organization == null) {
this.$message.error('是否建立团组织!');
return;
}
if (this.formData.nature == '') {
this.$message.error('请输主团组织性质!');
return;
}
if (this.formData.jiantuan_time == '') {
this.$message.error('请输入建团时间!');
return;
}
if (this.formData.jiantuan_number == '') {
this.$message.error('请输入建团人数!');
return;
}
if (this.formData.youth_number == '') {
this.$message.error('请输入青年人数!');
return;
}
if (this.formData.superior_nature == '') {
this.$message.error('请输入上级团组织!');
return;
}
if (this.formData.tuanweifuzerenxinxi == '') {
this.$message.error('请输入团委负责人信息!');
return;
}
if (this.formData.documents_file == '') {
this.$message.error('请上传批复文件!');
return;
}
this.formData.association_id=this.id;
this.$request
.post("/user/login/add", this.formData)
.then((res) => {
console.log(res);
})
.catch((e) => {
console.log(e);
});
},
},
};
</script>
<style lang="less">
<style lang="less" scoped>
@import '@/style/variables.less';
.result-success {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
height: 75vh;
&-icon {
font-size: 72px;
color: var(--td-success-color);
}
&-title {
margin-top: 28px;
font-size: 20px;
color: var(--td-text-color-primary);
text-align: center;
line-height: 28px;
font-weight: 500;
}
&-describe {
margin: 8px 0 32px;
font-size: 14px;
color: var(--td-text-color-secondary);
line-height: 22px;
}
}
.t-button + .t-button {
margin-left: var(--td-comp-margin-s);
}
</style>

View File

@ -57,11 +57,20 @@
<template #gender="{ row }">
{{row.gender==1?"男":"女"}}
</template>
<template #if_xianshi="{ row }">
<t-tag theme="primary" v-if="row.if_xianshi==0">待审核</t-tag>
<t-tag theme="success" v-if="row.if_xianshi==1">正式会员</t-tag>
<t-tag theme="danger" v-if="row.if_xianshi==2">申请已被拒绝</t-tag>
</template>
<template #select="{ row }">
<t-space size="24px">
<t-button theme="default" @click="openUrl(row.member_id)">详细信息</t-button>
<t-button theme="default" v-if="row.if_xianshi==1" @click="openUrl(row.member_id)">详细信息</t-button>
<t-button theme="default" v-if="row.if_xianshi==0" @click="openUrl(row.member_id)">审核</t-button>
<!-- <t-button>编辑</t-button>-->
<t-popconfirm content="确认要删除吗?" @confirm="del(row)">
<t-button theme="warning">删除</t-button>
</t-popconfirm>
</t-space>
</template>
</t-table>
@ -77,6 +86,8 @@
</t-card>
</template>
<script lang="ts">
import store from "@/store";
export default {
data() {
return {
@ -90,6 +101,7 @@ export default {
{ colKey: 'gender', title: '性别'},
{ colKey: 'phone', title: '手机号'},
{ colKey: 'nation', title: '民族'},
{ colKey: 'if_xianshi', title: '状态'},
{ colKey: 'select', title: '操作',width: 200},
],
total:0,
@ -103,10 +115,30 @@ export default {
}
},
mounted() {
if(typeof (this.$store.state.user.association)=='object'){
this.association=this.$store.state.user.association;
}else{
this.association=JSON.parse(this.$store.state.user.association);
}
this.getList();
},
methods: {
del(row){
this.$request
.post("/member/del",{member_id:row.id})
.then( (res) => {
console.log(res);
if (res.code==1){
this.$message.success(res.msg);
}else{
this.$message.error(res.msg);
}
this.getList();
})
.catch((e) => {
console.log(e);
});
},
onCurrentChange(d){
this.page=d;
this.getList();

View File

@ -4,7 +4,13 @@
<t-descriptions :column="4">
<t-descriptions-item label="证件照">
<div slot="content">
<img :src="$store.state.user.apiUrl+info.photo_image" style="width: 100px;height: 100px">
<t-image-viewer v-model="visible" :draggable="true" mode="modeless" :images="[$store.state.user.apiUrl+info.photo_image]">
<template #trigger="{ open }">
<div class="tdesign-demo-image-viewer__ui-image" @click="open">
<img alt="test" :src="$store.state.user.apiUrl+info.photo_image" class="tdesign-demo-image-viewer__ui-image--img" />
</div>
</template>
</t-image-viewer>
</div>
</t-descriptions-item>
<t-descriptions-item label="会员姓名" :content="info.nikename"></t-descriptions-item>
@ -29,7 +35,7 @@
<t-descriptions :column="2">
<t-descriptions-item label="身份证正面照">
<div slot="content">
<t-image-viewer v-model="visible" :draggable="true" mode="modeless" :images="[$store.state.user.apiUrl+info.cardz_image]">
<t-image-viewer v-model="visibleZm" :draggable="true" mode="modeless" :images="[$store.state.user.apiUrl+info.cardz_image]">
<template #trigger="{ open }">
<div class="tdesign-demo-image-viewer__ui-image" @click="open">
<img alt="test" :src="$store.state.user.apiUrl+info.cardz_image" class="tdesign-demo-image-viewer__ui-image--img" />
@ -40,7 +46,13 @@
</t-descriptions-item>
<t-descriptions-item label="身份证反面照">
<div slot="content">
<img :src="'http://192.168.3.130/'+info.cardf_image">
<t-image-viewer v-model="visibleFm" :draggable="true" mode="modeless" :images="[$store.state.user.apiUrl+info.cardf_image]">
<template #trigger="{ open }">
<div class="tdesign-demo-image-viewer__ui-image" @click="open">
<img alt="test" :src="$store.state.user.apiUrl+info.cardf_image" class="tdesign-demo-image-viewer__ui-image--img" />
</div>
</template>
</t-image-viewer>
</div>
</t-descriptions-item>
<t-descriptions-item label="身份证号码" :content="info.card_number"></t-descriptions-item>
@ -58,7 +70,7 @@
<t-descriptions :column="2">
<t-descriptions-item label="营业执照">
<div slot="content">
<t-image-viewer v-model="visible" :draggable="true" mode="modeless" :images="[$store.state.user.apiUrl+info.business_license_image]">
<t-image-viewer v-model="visibleZz" :draggable="true" mode="modeless" :images="[$store.state.user.apiUrl+info.business_license_image]">
<template #trigger="{ open }">
<div class="tdesign-demo-image-viewer__ui-image" @click="open">
<img alt="test" :src="$store.state.user.apiUrl+info.business_license_image" class="tdesign-demo-image-viewer__ui-image--img" />
@ -101,8 +113,16 @@
<t-descriptions-item label="团委负责人信息" :content="info.tuanweifuzerenxinxi"></t-descriptions-item>
<t-descriptions-item label="建团时间" :content="info.jiantuan_time"></t-descriptions-item>
</template>
</t-descriptions>
<div style="text-align: center" v-if="info.if_xianshi==0">
<t-popconfirm content="确认通过审核吗?" @confirm="tgSelect(2)">
<t-button theme="danger">拒绝</t-button>
</t-popconfirm>
<t-popconfirm content="确认通过审核吗?" @confirm="tgSelect(1)">
<t-button theme="primary" style="margin-left: 20px">通过审核</t-button>
</t-popconfirm>
</div>
</t-card>
</div>
</template>
@ -111,6 +131,10 @@ export default {
data() {
return {
visible:false,
visibleTg:false,
visibleZz:false,
visibleZm:false,
visibleFm:false,
info:{},
member_id:0,
}
@ -131,8 +155,21 @@ export default {
console.log(e);
});
},
onSubmit(){
this.getList();
tgSelect(type){
this.$request
.post("/member/update",{member_id:this.member_id,if_xianshi:type})
.then( (res) => {
console.log(res);
if (res.code==1){
this.$message.success(res.msg);
}else{
this.$message.error(res.msg);
}
this.getInfo();
})
.catch((e) => {
console.log(e);
});
},
}
}

View File

@ -14,6 +14,15 @@ router.beforeEach(async (to, from, next) => {
const token = localStorage.getItem('associationToken');
console.log(token);
console.log(to.path);
if(store.state.user.association){
if(typeof (store.state.user.association)=='object'){
var association=store.state.user.association;
}else{
var association=JSON.parse(store.state.user.association);
}
}
if (token) {
if (to.path === '/login') {
next();
@ -33,7 +42,7 @@ router.beforeEach(async (to, from, next) => {
next({ ...to });
} catch (error) {
await store.commit('user/removeToken');
next(`/login?redirect=${to.path}`);
next(`/login?id=`+association.id);
NProgress.done();
}
}
@ -42,7 +51,7 @@ router.beforeEach(async (to, from, next) => {
if (whiteListRouters.indexOf(to.path) !== -1) {
next();
} else {
next(`/login`);
next(`/login?id=`+association.id);
}
NProgress.done();
}