住户审核

main
bibi 3 years ago
parent 83dc074670
commit 1cf7f614d5

@ -1,3 +1,3 @@
NODE_ENV = 'development' NODE_ENV = 'development'
VUE_APP_URL = 'http://121.41.26.225:8004/1' VUE_APP_URL = 'http://121.41.26.225:8004'
VUE_APP_CDN = 'http://121.41.26.225:8004/1' VUE_APP_CDN = 'http://121.41.26.225:8004'

@ -1,3 +1,3 @@
NODE_ENV = 'production' NODE_ENV = 'production'
VUE_APP_URL = 'http://121.41.26.225:8004/1' VUE_APP_URL = 'http://121.41.26.225:8004'
VUE_APP_CDN = 'http://121.41.26.225:8004/1' VUE_APP_CDN = 'http://121.41.26.225:8004'

@ -1,9 +1,9 @@
import httpService from "@/request" import httpService from "@/request"
// 获取预报列表 // 获取预报列表
export function forecastList(params) { export function functionName(params) {
return httpService({ return httpService({
url: `/order/forecast/lists`, url: `url`,
method: 'post', method: 'post',
data: params, data: params,
}) })

@ -0,0 +1,10 @@
import httpService from "@/request"
// 登录
export function loginTel(params) {
return httpService({
url: `/manage/loginTelCode`,
method: 'post',
data: params,
})
}

@ -1,15 +1,9 @@
/*
* @Author: your name
* @Date: 2021-10-13 09:28:02
* @LastEditTime: 2021-11-11 10:45:00
* @LastEditors: Please set LastEditors
* @Description: In User Settings Edit
* @FilePath: /data-show/src/request/index.js
*/
import axios from 'axios'; import axios from 'axios';
import qs from 'qs'; // import qs from 'qs';
import router from "@/permission" import router from "@/permission"
import { message} from 'ant-design-vue' import { message} from 'ant-design-vue'
import store from '@/store'
// import baseURL from "@/utils/baseURL"
function filterRequestData(obj) { function filterRequestData(obj) {
let o = {}; let o = {};
for(let key in obj) { for(let key in obj) {
@ -23,23 +17,20 @@ function filterRequestData(obj) {
} }
//创建axios的实例 //创建axios的实例
const httpService = axios.create({ const httpService = axios.create({
baseURL: 'http://cloud.sws010.com',// TODO:具体的配置可以根据项目情况而来 baseURL: process.env.VUE_APP_URL + '/1',// TODO:具体的配置可以根据项目情况而来
timeout: 5000 timeout: 5000
}) })
//axios的拦截--request //axios的拦截--request
httpService.interceptors.request.use(config => { httpService.interceptors.request.use(config => {
// 请求成功处理
// if(localStorage.getItem('token')){//判断浏览器中的cookie中是否存在项目的token
// config.headers.token = localStorage.getItem('token')
// }
const rqParams = filterRequestData(config.params); const rqParams = filterRequestData(config.params);
const rqData = filterRequestData(config.data); const rqData = filterRequestData(config.data);
// post 'Content-Type' === 'application/x-www-form-urlencoded' // post 'Content-Type' === 'application/x-www-form-urlencoded'
// manage-login-token config.headers['Content-Type'] = "application/json";
config.headers['Content-Type'] = 'application/x-www-form-urlencoded' config.headers['manage-login-token'] = store.getters.getToken;
config.headers['device-type'] = "web";
if(config.method === 'post') { if(config.method === 'post') {
config.data = qs.stringify(rqData); config.data = rqData;
} else { } else {
config.data = rqData; config.data = rqData;
config.params = rqParams; config.params = rqParams;
@ -53,24 +44,25 @@ httpService.interceptors.request.use(config => {
httpService.interceptors.response.use(response => { httpService.interceptors.response.use(response => {
// TODO:具体的code对应的处理可继续添加修改 // TODO:具体的code对应的处理可继续添加修改
let data = null; let data = null;
let data1 = null;
let msg = ''; let msg = '';
let res = response.data; let res = response.data;
let totalNum = 0; if(res.code == 0){
if(res.Code == 1){ data = res.data;
data = res.Data || []; msg = res.msg || "";
data1 = res.Data1 || []; return {data, msg};
msg = res.Msg || ""; } else if(res.code == 100000) {
totalNum = res.totalNum || 0; router.replace({
return {data,data1, msg, totalNum}; path: '/login'
});
} else { } else {
msg = res.Msg || ""; msg = res.msg || "";
message.error(msg); message.error(msg);
return Promise.reject(new Error(msg)) return Promise.reject(new Error(msg))
} }
},err => { },err => {
console.log(err)
// TODO:具体的code对应的处理可继续添加修改 // TODO:具体的code对应的处理可继续添加修改
if(err.response.Code === 301){ if(err.response.code === 301){
//登录过期跳转登录页面并将要浏览的页面fullPath传过去登录成功后跳转需要访问的页面 ---主页(index) 或者 退出到登录前的浏览的页面 //登录过期跳转登录页面并将要浏览的页面fullPath传过去登录成功后跳转需要访问的页面 ---主页(index) 或者 退出到登录前的浏览的页面
//这样登录页面登录接口成功之后可以进行跳转 主页(index) 或者 退出到登录前的页面: let path = this.$route.query.redirect || '/index.js'; this.$router.push(path); //这样登录页面登录接口成功之后可以进行跳转 主页(index) 或者 退出到登录前的页面: let path = this.$route.query.redirect || '/index.js'; this.$router.push(path);
setTimeout(() => { setTimeout(() => {

@ -70,7 +70,15 @@ export default [
hide: false, hide: false,
component: resolve => require(['@/views/Basic/EstateInfo/_houseHoldInfo'], resolve), component: resolve => require(['@/views/Basic/EstateInfo/_houseHoldInfo'], resolve),
meta: {title: '住户信息'}, meta: {title: '住户信息'},
} },
{
path: '/EstateInfo/HouseHoldAudit',
name: "HouseHoldAudit",
title: "住户审核",
hide: false,
component: resolve => require(['@/views/Basic/EstateInfo/_houseHoldAudit'], resolve),
meta: {title: '住户审核'},
},
] ]
}, },
// { // {

@ -25,8 +25,8 @@
> >
<template v-slot:actionBox="data"> <template v-slot:actionBox="data">
<a-space size="small"> <a-space size="small">
<a-button type="link" @click='detail(data)'>分配角色</a-button> <a class="ant-dropdown-link" @click='detail(data)'>分配角色</a>
<a-button type="link" @click='del(data)'>删除</a-button> <a class="ant-dropdown-link" @click='del(data)'>删除</a>
</a-space> </a-space>
</template> </template>
</commonTable> </commonTable>

@ -70,8 +70,8 @@
<!-- 操作 --> <!-- 操作 -->
<span slot="action" slot-scope="scope"> <span slot="action" slot-scope="scope">
<a-space size="small"> <a-space size="small">
<a-button type="link" @click='detail(scope)'>详情</a-button> <a class="ant-dropdown-link" @click='detail(scope)'>详情</a>
<a-button type="link" @click='del(scope)'>重置密码</a-button> <a class="ant-dropdown-link" @click='del(scope)'>重置密码</a>
</a-space> </a-space>
</span> </span>
<span slot="formatter" slot-scope="scope">{{ <span slot="formatter" slot-scope="scope">{{

@ -25,8 +25,8 @@
> >
<template v-slot:actionBox="data"> <template v-slot:actionBox="data">
<a-space size="small"> <a-space size="small">
<a-button type="link" @click='detail(data)'>详情</a-button> <a class="ant-dropdown-link" @click='detail(data)'>详情</a>
<a-button type="link" @click='del(data)'>删除</a-button> <a class="ant-dropdown-link" @click='del(data)'>删除</a>
</a-space> </a-space>
</template> </template>
</commonTable> </commonTable>

@ -0,0 +1,264 @@
<template>
<div>
<div class="cardTitle">住户审核&nbsp;
<a-radio-group default-value="1" button-style="solid" @change="tabsChange">
<a-radio-button value="0">
全部
</a-radio-button>
<a-radio-button value="1">
待审核
</a-radio-button>
<a-radio-button value="3">
已通过
</a-radio-button>
<a-radio-button value="2">
已驳回
</a-radio-button>
</a-radio-group>
</div>
<div class="search-box">
<a-row>
<a-col :span="20">
<a-space size="large">
<a-select placeholder="请选择用户身份" style="width:200px"/>
<a-button type="primary"> </a-button>
<a-button> </a-button>
</a-space>
</a-col>
</a-row>
</div>
<div class="main">
<div style="margin-bottom: 16px">
<!-- 批量操作 -->
<a-select
type="primary"
v-model="activeAction"
:disabled="!hasSelected"
:loading="loading"
style="width: 120px"
@change="Actions"
placeholder="请选择操作"
>
批量
<a-select-option v-for="item in ActionsList" :key="item.value">
{{ item.label }}
</a-select-option>
</a-select>
<span style="margin-left: 8px">
<template v-if="hasSelected">
{{ `已选择 ${selectedRowKeys.length}` }}
</template>
</span>
</div>
<!-- 表格 -->
<a-table
:columns="columns"
:data-source="tableData"
:pagination="pagination"
:scroll="{ x: 1300 }"
:row-selection="{
selectedRowKeys: selectedRowKeys,
onChange: selectionChoosed,
}"
:row-key="
(record, index) => {
return index;
}
"
>
<span slot="name" slot-scope="text, row">
{{
row.manageBuildingName +
"栋/" +
row.manageUnitName +
"单元/" +
row.floorLocation +
"层-" +
row.name +
"室"
}}
</span>
<span slot="action" slot-scope="text, row">
<a-space>
<a class="ant-dropdown-link" @click='audit(row.estateReviewId,1)'>通过</a>
<a class="ant-dropdown-link" @click='audit(row.estateReviewId,2)'>驳回</a>
</a-space>
</span>
<span slot="tags" slot-scope="tag">
<a-tag
:color="tag === 1 ? 'volcano' : tag === 2 ? 'geekblue' : tag === 3 ? 'geekblue' : 'red'"
>
{{ tag === 1 ? "业主" : tag === 2 ? "业主亲属" :tag === 3 ? "租户":tag === 4 ? "租户亲属":'-' }}
</a-tag>
</span>
</a-table>
</div>
</div>
</template>
<script>
export default {
data() {
return {
pagination: {
current: 1,
total: 0,
pageSize: 10,
showTotal: (total) => `${total}`,
showSizeChanger: true,
showQuickJumper: true,
},
searchForm:{
status:null,
identity:null
},
activeAction: undefined,
loading: false,
// index
selectedRowKeys: [],
tableChoosed: [],
//
//
columns: [
{
title: "申请人姓名",
dataIndex:"name",
width:'14%'
},
{
title: "申请人身份",
key: "tags",
width: "14%",
dataIndex: "identity",
scopedSlots: { customRender: "tags" },
},
{
title: "房屋名称",
dataIndex: "manageBuildingName",
scopedSlots: { customRender: "name" },
width: "20%",
},
{
title: "申请人手机号",
dataIndex:"tel",
width:'14%'
},
{
title: "申请人身份证号",
dataIndex:"idCard",
width:'14%'
},
{
title: "状态",
dataIndex:"status",
width:'14%',
customRender:function(status){
switch (status) {
case 1:
return '审核中'
case 2:
return '驳回'
case 3:
return '通过'
default:
break;
}
}
},
{
title: "房屋类型",
dataIndex:"estateTypeName",
width:'14%'
},
{
title: "操作",
dataIndex: "action",
key: "action",
width: "100",
fixed: "right",
scopedSlots: { customRender: "action" },
},
],
//
tableData: [
{
manageBuildingName: "1",
manageUnitName: "2",
floorLocation: "4",
name: "502",
roleNameList: ["点点3", "212", "点点"],
status: 1,
},
{
name: 1,
roleNameList: ["点点3", "212", "点点"],
status: 2,
isEnableLease: 1,
},
],
ActionsList: [
{
label: "批量删除",
value: 1,
},
{
label: "批量导出",
value: 2,
},
],
};
},
mounted(){
this.getData()
},
methods: {
getData(){},
tabsChange(e){
this.searchForm.status = e.target.value
this.getData()
},
// 1 2
audit(estateReviewId,operate){
this.$confirm({
title: "是否" + (operate===1?'通过':'驳回'),
// okText:'',
// cancelText:'',
icon: "",
onOk:async function () {
let res = await this.api({
estateReviewId:estateReviewId,
operate:operate
})
if(res.code===0){
this.$message()
}
},
})
},
handleTableChange(pagination) {
console.log(pagination);
const pager = { ...this.pagination };
pager.current = pagination.current;
pager.pageSize = pagination.pageSize;
this.pagination = pager;
},
Actions(data) {
console.log(data);
this.activeAction = undefined;
},
selectionChoosed(data) {
console.log(data);
this.tableChoosed = data;
},
},
computed: {
// selection
hasSelected() {
return this.selectedRowKeys.length > 0;
},
},
};
</script>
<style lang="less" scoped>
</style>

@ -60,7 +60,7 @@
" "
> >
<span slot="name" slot-scope="text, row"> <span slot="name" slot-scope="text, row">
<a-select style="width :200px" @change='changeHouse'> <a-select style="width :200px" @change='changeHouse' placeholder='请选择房屋'>
<a-select-option v-for="item,index in row.residentListEstateVoList" :key='index' :value="item.id"> <a-select-option v-for="item,index in row.residentListEstateVoList" :key='index' :value="item.id">
{{ {{
item.manageBuildingName + item.manageBuildingName +
@ -77,15 +77,15 @@
</span> </span>
<span slot="action" slot-scope="text, row"> <span slot="action" slot-scope="text, row">
<a-space> <a-space>
<a-button type="link" @click="edit(row)"></a-button> <a class="ant-dropdown-link">编辑</a>
<a-button type="link" @click="del(row)"></a-button> <a class="ant-dropdown-link" @click="del(row)"></a>
</a-space> </a-space>
</span> </span>
<span slot="tags" slot-scope="tag"> <span slot="tags" slot-scope="tag">
<a-tag <a-tag
:color="tag === 1 ? 'volcano' : tag === 2 ? 'geekblue' : tag === 3 ? 'geekblue' : 'red'" :color="tag === 1 ? 'volcano' : tag === 2 ? 'geekblue' : tag === 3 ? 'geekblue' : 'red'"
> >
{{ tag === 1 ? "业主" : tag === 2 ? "业主亲属" :tag === 3 ? "租户":'租户亲属' }} {{ tag === 1 ? "业主" : tag === 2 ? "业主亲属" :tag === 3 ? "租户":tag === 4 ? "租户亲属":'-' }}
</a-tag> </a-tag>
</span> </span>
</a-table> </a-table>
@ -96,17 +96,191 @@
:width="720" :width="720"
:visible="drawer.add.show" :visible="drawer.add.show"
:body-style="{ paddingBottom: '80px' }" :body-style="{ paddingBottom: '80px' }"
@close="onClose" @close="addClose"
> >
<div class="drawer-content"> <div class="drawer-content">
基本信息 基本信息
<a-divider></a-divider> <a-divider></a-divider>
<a-form-model
ref="ruleForm"
:model="form"
:rules="rules"
layout="vertical"
>
<a-row>
<a-col :span='8'>
<a-form-model-item label="关联房屋" prop="manageEstateId">
<a-cascader :options="options" placeholder="Please select" @change="onChange" style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span='8'>
<a-form-model-item label="房屋类型">
<a-input placeholder='请先选择关联房屋' disabled style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span='8'>
<a-form-model-item label="住户身份" prop="identity">
<a-select placeholder='请选择住户身份' style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span='12'>
<a-form-model-item label="姓名" prop="name">
<a-input placeholder='请输入姓名' style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span='12'>
<a-form-model-item label="手机号" prop="tel">
<a-input placeholder='请输入手机号' style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span='12'>
<a-form-model-item label="性别" prop="sex">
<a-input placeholder='请选择性别' style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span='12'>
<a-form-model-item label="身份证号" prop="idCard">
<a-input placeholder='请输入身份证号' style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span='12'>
<a-form-model-item label="入住时间" prop="checkTime">
<a-date-picker @change="onChange" />
</a-form-model-item>
</a-col>
<a-col :span='12'>
<a-form-model-item label="户籍所在地" prop="domicile">
<a-input placeholder='户籍所在地' style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span='12'>
身份证徽面照
<a-upload
name="avatar"
list-type="picture-card"
class="avatar-uploader"
:show-upload-list="false"
action="https://www.mocky.io/v2/5cc8019d300000980a055e76"
:before-upload="beforeUpload"
@change="handleChange"
>
<img v-if="imageUrl" :src="imageUrl" alt="avatar" />
<div v-else>
<a-icon :type="loading ? 'loading' : 'plus'" />
<div class="ant-upload-text">
</div>
</div>
</a-upload>
</a-col>
<a-col :span='12'>
身份证头像照
<a-upload
name="avatar"
list-type="picture-card"
class="avatar-uploader"
:show-upload-list="false"
action="https://www.mocky.io/v2/5cc8019d300000980a055e76"
:before-upload="beforeUpload"
@change="handleChange"
>
<img v-if="imageUrl" :src="imageUrl" alt="avatar" />
<div v-else>
<a-icon :type="loading ? 'loading' : 'plus'" />
<div class="ant-upload-text">
</div>
</div>
</a-upload>
</a-col>
<div v-show='form.identity===2||form.identity===4'>
关联信息
<a-divider></a-divider>
</div>
<div v-if="form.identity===2">
<a-col :span="12">
<a-form-model-item label="业主姓名" prop="ownerName">
<a-input placeholder='请输入业主姓名' style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="业主电话" prop="ownerTel">
<a-input placeholder='请输入业主电话' style='width:90%'/>
</a-form-model-item>
</a-col>
</div>
<div v-else-if="form.identity===4">
<a-col :span="12">
<a-form-model-item label="租户姓名" prop="tenantName">
<a-input placeholder='请输入租户姓名' style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="租户电话" prop="tenantTel">
<a-input placeholder='请输入租户电话' style='width:90%'/>
</a-form-model-item>
</a-col>
</div>
联系信息
<a-divider></a-divider>
<a-col :span="12">
<a-form-model-item label="紧急联系人" prop="emergencyContact">
<a-input placeholder='请输入紧急联系人' style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="紧急联系人电话" prop="emergencyContactNumber">
<a-input placeholder='请输入紧急联系人电话' style='width:90%'/>
</a-form-model-item>
</a-col>
其他信息
<a-divider></a-divider>
<a-col :span="12">
<a-form-model-item label="婚姻状况" prop="maritalStatus">
<a-select placeholder='请选择婚姻状况' style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="民族" prop="nation">
<a-input placeholder='请输入民族' style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="政治面貌" prop="politicalOutlook">
<a-select placeholder='请选择婚姻状况' style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="户口类型" prop="accountType">
<a-select placeholder='请选择户口类型' style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="从事职业" prop="occupation">
<a-input placeholder='请输入从事职业' style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span="12">
<a-form-model-item label="工作单位" prop="employer">
<a-input placeholder='请输入工作单位' style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="工作单位地址" prop="employerAddress">
<a-input placeholder='请输入工作单位地址' style='width:90%'/>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="备注" prop="remarks">
<a-textarea placeholder='请输入备注' style='width:90%'/>
</a-form-model-item>
</a-col>
</a-row>
</a-form-model>
</div> </div>
<div class="drawer-footer"> <div class="drawer-footer">
<a-button :style="{ marginRight: '8px' }" @click="drawer.add.show = false"> <a-button :style="{ marginRight: '8px' }" @click="drawer.add.show = false">
关闭 关闭
</a-button> </a-button>
<a-button type="primary" @click="onClose"> </a-button> <a-button type="primary" @click="addClose"> </a-button>
</div> </div>
</a-drawer> </a-drawer>
</div> </div>
@ -116,6 +290,10 @@
export default { export default {
data() { data() {
return { return {
imageUrl: '',
form:{
identity:2
},
drawer:{ drawer:{
add:{ add:{
show: false show: false
@ -269,6 +447,23 @@ export default {
this.newData = this.tableData this.newData = this.tableData
}, },
methods: { methods: {
addClose(){
this.drawer.add.show = false;
},
handleChange(info){
console.log(info);
},
beforeUpload(file) {
const isJpgOrPng = file.type === 'image/jpeg' || file.type === 'image/png';
if (!isJpgOrPng) {
this.$message.error('You can only upload JPG file!');
}
const isLt2M = file.size / 1024 / 1024 < 2;
if (!isLt2M) {
this.$message.error('Image must smaller than 2MB!');
}
return isJpgOrPng && isLt2M;
},
// //
changeHouse(value){ changeHouse(value){
// //
@ -321,13 +516,21 @@ export default {
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
.role-card { /deep/.ant-upload.ant-upload-select-picture-card{
line-height: 30px; width: 240px;
font-size: 16px; height: 160px;
cursor: pointer; }
border-bottom: 1px solid #d9d9d9; /deep/.avatar-uploader > .ant-upload {
margin-bottom: 10px; width: 240px;
display: flex; height: 160px;
justify-content: space-between; }
.ant-upload-select-picture-card i {
font-size: 32px;
color: #999;
}
.ant-upload-select-picture-card .ant-upload-text {
margin-top: 8px;
color: #666;
} }
</style> </style>

@ -70,8 +70,8 @@
</span> </span>
<span slot="action" slot-scope="text, row"> <span slot="action" slot-scope="text, row">
<a-space> <a-space>
<a-button type="link" @click="edit(row)"></a-button> <a class="ant-dropdown-link" @click='edit(row)'>编辑</a>
<a-button type="link" @click="del(row)"></a-button> <a class="ant-dropdown-link" @click='del(row)'>删除</a>
</a-space> </a-space>
</span> </span>
<span slot="tags" slot-scope="tag"> <span slot="tags" slot-scope="tag">

@ -24,7 +24,7 @@
<a-row> <a-row>
<a-col :span="12" style="margin-left:23px"><a-checkbox></a-checkbox>&nbsp;&nbsp;</a-col> <a-col :span="12" style="margin-left:23px"><a-checkbox></a-checkbox>&nbsp;&nbsp;</a-col>
</a-row> </a-row>
<a-button type="primary" style="width:90%;margin:30px"> <a-button type="primary" @click='login' style="width:90%;margin:30px">
登录 登录
</a-button> </a-button>
<a-row style="margin-top:20px;margin-left:23px"> <a-row style="margin-top:20px;margin-left:23px">
@ -149,6 +149,7 @@
</template> </template>
<script> <script>
import {loginTel} from "../../api/login"
export default { export default {
name: "Login", name: "Login",
data() { data() {
@ -189,8 +190,12 @@ export default {
}; };
}, },
methods: { methods: {
login() { async login() {
this.$router.push({ name: "Console" }); let res = await loginTel({
tel:'11',
code:'111111'
})
console.log(res);
}, },
// //
getCode(){}, getCode(){},

Loading…
Cancel
Save