分页
This commit is contained in:
@@ -2,20 +2,20 @@
|
|||||||
<div class="AppNeighborLinkage">
|
<div class="AppNeighborLinkage">
|
||||||
<div class="header">
|
<div class="header">
|
||||||
<div class="search">
|
<div class="search">
|
||||||
<u-search placeholder="请输入需要搜索的内容" v-model="keyword" :show-action="false"></u-search>
|
<u-search placeholder="请输入需要搜索的内容" v-model="keyword" :show-action="false" @search="search"></u-search>
|
||||||
</div>
|
</div>
|
||||||
<div class="select">
|
<div class="select">
|
||||||
<div class="item" @click="typeSelect">
|
<div class="item" >
|
||||||
<AiSelect class="right" v-model="type" dict="yesOrNo">
|
<AiSelect class="right" v-model="status" dict="partyFourLinkageStatus" @data="typeSelect">
|
||||||
<span v-if="!type">全部状态</span>
|
<span v-if="!status">全部状态</span>
|
||||||
<span v-else>{{ type }}</span>
|
<span v-else>{{ $dict.getLabel('partyFourLinkageStatus',status) }}</span>
|
||||||
<u-icon name="arrow-down-fill" color="#666666" size="28"></u-icon>
|
<u-icon name="arrow-down-fill" color="#666666" size="28"></u-icon>
|
||||||
</AiSelect>
|
</AiSelect>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="item" @click="isShowDate = true">
|
<div class="item" @click="isShowDate = true">
|
||||||
<span v-if="!checkTime">时间选择</span>
|
<span v-if="!linksageDate">时间选择</span>
|
||||||
<span v-else>{{ checkTime }}</span>
|
<span v-else>{{ linksageDate }}</span>
|
||||||
<u-icon name="arrow-down-fill" color="#666666" size="28"></u-icon>
|
<u-icon name="arrow-down-fill" color="#666666" size="28"></u-icon>
|
||||||
</div>
|
</div>
|
||||||
<u-picker mode="time" :params="params" v-model="isShowDate" @confirm="onDateChange"></u-picker>
|
<u-picker mode="time" :params="params" v-model="isShowDate" @confirm="onDateChange"></u-picker>
|
||||||
@@ -23,14 +23,17 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="section" v-if="list.length">
|
<div class="section" v-if="list.length">
|
||||||
<div class="card" @click="$linkTo('./neighborDetail')">
|
<div class="card" v-for="(item,index) in list" :key="index" @click="$linkTo(`./neighborDetail?id=${item.id}`)">
|
||||||
<div class="info">
|
<div class="info">
|
||||||
<p>帮助赵顺伟咨询户口迁移问题帮助赵顺伟咨询</p>
|
<p>{{ item.description }}</p>
|
||||||
<div><span>事件日期</span><span>2022-04-15</span></div>
|
<div><span>事件日期</span><span>{{ item.linksageDate }}</span></div>
|
||||||
<div><span>四邻对象</span><span>李白</span></div>
|
<div><span>四邻对象</span><span>{{ item.residentName }}</span></div>
|
||||||
</div>
|
</div>
|
||||||
<div class="status">
|
<div class="status">
|
||||||
<span></span><span>待审核</span>
|
<span :style="{background: item.status==0? '#FF883C': item.status==1? '#42D784': '#FF4466'}"></span>
|
||||||
|
<span :style="{color: item.status==0? '#FF883C': item.status==1? '#42D784': '#FF4466'}">
|
||||||
|
{{ $dict.getLabel('partyFourLinkageStatus',item.status) }}
|
||||||
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -51,8 +54,8 @@ export default {
|
|||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
keyword:'',
|
keyword:'',
|
||||||
type: '',
|
status: '',
|
||||||
checkTime: '',
|
linksageDate: '',
|
||||||
isShowDate: false,
|
isShowDate: false,
|
||||||
params: {
|
params: {
|
||||||
year: true,
|
year: true,
|
||||||
@@ -64,18 +67,42 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
onShow() {
|
onShow() {
|
||||||
this.$dict.load('yesOrNo')
|
this.$dict.load('partyFourLinkageStatus')
|
||||||
this.getList()
|
this.getList()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
search(e) {
|
||||||
|
this.keyword = e
|
||||||
|
},
|
||||||
|
typeSelect(e) {
|
||||||
|
this.list = []
|
||||||
|
this.status = e.value
|
||||||
|
this.current = 1
|
||||||
|
this.getList()
|
||||||
|
},
|
||||||
onDateChange(e) {
|
onDateChange(e) {
|
||||||
this.checkTime = `${e.year}-${e.month}-${e.day}`
|
this.list = []
|
||||||
|
this.linksageDate = `${e.year}-${e.month}-${e.day}`
|
||||||
|
this.current = 1
|
||||||
|
this.getList()
|
||||||
},
|
},
|
||||||
getList() {
|
getList() {
|
||||||
// this.$instance.post('/app/apppartyfourresident/listFourResident').then(res=>{
|
this.$instance.post('/app/apppartyfourlinkage/listByApplet',null,{
|
||||||
// console.log(res);
|
params: {
|
||||||
// })
|
current: this.current,
|
||||||
|
status: this.status,
|
||||||
|
linksageDate: this.linksageDate,
|
||||||
|
}
|
||||||
|
}).then(res=>{
|
||||||
|
if (res?.data) {
|
||||||
|
this.list = this.current==1? res.data.records : [...this.list, ...res.data.records]
|
||||||
|
}
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
onReachBottom() {
|
||||||
|
this.current ++,
|
||||||
|
this.getList()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
@@ -118,6 +145,8 @@ export default {
|
|||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
border-bottom: 1px solid #DDDDDD;
|
border-bottom: 1px solid #DDDDDD;
|
||||||
p {
|
p {
|
||||||
|
font-size: 32px;
|
||||||
|
font-weight: 600;
|
||||||
overflow:hidden;
|
overflow:hidden;
|
||||||
text-overflow:ellipsis;
|
text-overflow:ellipsis;
|
||||||
display:-webkit-box;
|
display:-webkit-box;
|
||||||
|
|||||||
@@ -47,16 +47,36 @@ export default {
|
|||||||
type: '',
|
type: '',
|
||||||
checkTime: '',
|
checkTime: '',
|
||||||
name: '',
|
name: '',
|
||||||
}
|
partyId: ''
|
||||||
|
},
|
||||||
|
userList: []
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onShow() {
|
onShow() {
|
||||||
this.$dict.load('agriculturalType')
|
this.$dict.load('agriculturalType')
|
||||||
|
this.getFourResident()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
onDateChange(e) {
|
onDateChange(e) {
|
||||||
this.form.checkTime = `${e.year}-${e.month}-${e.day}`
|
this.form.checkTime = `${e.year}-${e.month}-${e.day}`
|
||||||
},
|
},
|
||||||
|
getFourResident() {
|
||||||
|
this.$instance.post('/app/apppartyfourresident/listFourResident', null, {
|
||||||
|
params: {
|
||||||
|
size: 10,
|
||||||
|
partyId: this.form.partyId,
|
||||||
|
},
|
||||||
|
}).then((res) => {
|
||||||
|
if (res.code == 0) {
|
||||||
|
this.userList = res.data.records
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
confirm() {
|
||||||
|
if(!this.form.checkTime)
|
||||||
|
this.$instance.post('/app/apppartyfourlinkage/addOrUpdate')
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -1,26 +1,29 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="neighborDetail">
|
<div class="neighborDetail">
|
||||||
<div class="type">
|
<div class="type">
|
||||||
<span>审核状态</span><span>已通过</span>
|
<span>审核状态</span>
|
||||||
|
<span :style="{color: data.status==0? '#FF883C': data.status==1? '#42D784': '#FF4466'}">
|
||||||
|
{{ $dict.getLabel('partyFourLinkageStatus',data.status) }}
|
||||||
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="user-info">
|
<div class="user-info">
|
||||||
<div class="item">
|
<div class="item">
|
||||||
<span>事件日期</span>
|
<span>事件日期</span>
|
||||||
<span>2022-04-18</span>
|
<span>{{ data.linksageDate }}</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="item">
|
<div class="item">
|
||||||
<span>四邻对象</span>
|
<span>四邻对象</span>
|
||||||
<span>1555665646</span>
|
<span>{{ data.residentName }}</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="description">
|
<div class="description">
|
||||||
<div>事件描述</div>
|
<div>事件描述</div>
|
||||||
<div>
|
<div>
|
||||||
帮助赵顺伟咨询户口迁移问题
|
{{ data.description }}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="btn">
|
<div class="btn">
|
||||||
<div class="delBtn">删除联动记录</div>
|
<div class="delBtn" @click="delBtn">删除联动记录</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@@ -30,12 +33,39 @@ export default {
|
|||||||
name: 'neighborDetail',
|
name: 'neighborDetail',
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
id: '',
|
||||||
|
data: {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onShow() {},
|
onLoad(o) {
|
||||||
|
this.$dict.load('partyFourLinkageStatus')
|
||||||
|
this.id = o.id
|
||||||
|
this.getDetail()
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
getDetail() {
|
||||||
|
this.$instance.post('/app/apppartyfourlinkage/queryDetailById',null,{
|
||||||
|
params: {
|
||||||
|
id: this.id,
|
||||||
|
}
|
||||||
|
}).then(res => {
|
||||||
|
if(res.code == 0) {
|
||||||
|
this.data = res.data
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
delBtn() {
|
||||||
|
this.$dialog.confirm({content: '确定要删除该记录吗?'}).then(()=>{
|
||||||
|
this.$instance.post(`/app/apppartyfourlinkage/delete?ids=${this.id}`).then(res => {
|
||||||
|
if(res.code == 0) {
|
||||||
|
this.$u.toast('删除成功')
|
||||||
|
setTimeout(() => {
|
||||||
|
uni.navigateBack()
|
||||||
|
},600)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
})
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
Reference in New Issue
Block a user