This commit is contained in:
shijingjing
2022-05-19 13:35:55 +08:00
parent d242b9c10d
commit 4cc6ea3be7
8 changed files with 725 additions and 9 deletions

View File

@@ -0,0 +1,286 @@
<template>
<div class="add">
<div class="tips">我承认本次申请帮扶情况属实愿接受有关部门依法核实家庭资产信息如存在虚报伪造造成社会资源浪费本人资源承担相关惩戒措施</div>
<div class="user_info">
<div class="item">
<div class="left">
<span>*</span><span>申请人姓名</span>
</div>
<input type="text" class="right__text" v-model="form.name" placeholder="请输入" maxlength="20"/>
</div>
<div class="item">
<div class="left">
<span>*</span><span>申请人身份证号</span>
</div>
<input type="number" class="right__text" v-model="form.idNumber" placeholder="请输入" maxlength="20"/>
</div>
<div class="item">
<div class="left">
<span>*</span><span>联系方式</span>
</div>
<input type="number" class="right__text" v-model="form.phone" placeholder="请输入" maxlength="11"/>
</div>
</div>
<div class="family_info">
<div class="item">
<div class="left">
<span>*</span><span>家庭人口数</span>
</div>
<input type="number" class="right__text" v-model="form.householdNumber" placeholder="请输入" maxlength="10"/>
</div>
<div class="item">
<div class="left">
<span>*</span><span>所在地区</span>
</div>
<AiAreaPicker v-model="form.areaId" class="right__text" :fullName.sync="form.areaName">
<span :class="form.areaName == '' ? 'color-999' : 'color-333' ">{{ form.areaName || "请选择" }}</span>
<u-icon name="arrow-right" color="#ddd" style="display: inline-block;"/>
</AiAreaPicker>
</div>
<div class="items">
<div class="left">
<span>*</span><span>详细地址</span>
</div>
<input type="text" class="textarea" v-model="form.address" placeholder="请输入详细地址" maxlength="100"/>
</div>
<div class="items">
<div class="left">
<span>*</span><span>申请帮扶原因最多2项</span>
</div>
<div class="tags">
<span v-for="(item,index) in list" :key="index" :class="item.checked? 'isCheck':''" @click="helpCheck(item)">{{ item.dictName }}</span>
</div>
</div>
<div class="items">
<div class="left">
<span>*</span><span>返贫致贫风险说明</span>
</div>
<input type="text" class="text" v-model="form.riskDescription" placeholder="请简要说明返贫致贫风险说明" maxlength="200"/>
</div>
<div class="items">
<div class="left">
<span style="margin-right: 8px"></span><span>上传佐证材料最多9张</span>
</div>
<div style="margin-top: 10px;">
<AiUploader v-model="form.files" :limit="9" multiple></AiUploader>
</div>
</div>
</div>
<div style="height: 60px;"></div>
<div class="btn" @click="comfirm">提交</div>
</div>
</template>
<script>
export default {
data() {
return {
form: {
name: '',
idNumber: '',
phone: '',
householdNumber: '',
areaId: '',
areaName: '',
address: '',
declareReason: [],
reason: '',
riskDescription: '',
files: []
},
list: [],
flag: false,
checkList: [],
}
},
onLoad() {
this.$dict.load('helpDeclarationReason').then(()=>{
this.list = this.$dict.getDict('helpDeclarationReason').map((item)=>{
return {
dictName: item.dictName,
dictValue: item.dictValue,
checked: false
}
})
})
},
onShow() {
document.title = '添加帮扶申报'
},
methods: {
helpCheck(e) {
e.checked = !e.checked
this.checkList = this.list.filter(e=>e.checked)
this.form.declareReason = this.checkList.map(v=> v.dictValue).toString()
this.form.reason = this.checkList.map(o=>o.dictName).toString()
},
comfirm() {
if(this.flag) return
if(!this.form.name) {
return this.$u.toast('请输入姓名')
}
if(!this.form.idNumber) {
return this.$u.toast('请输入身份证号')
}
if(this.form.idNumber) {
if (!/(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/.test(this.form.idNumber)) {
return this.$u.toast('请输入正确的身份证号')
}
}
if(!this.form.phone) {
return this.$u.toast('请输入手机号')
}
if(!this.form.householdNumber) {
return this.$u.toast('请输入家庭人口数')
}
if(!this.form.areaId) {
return this.$u.toast('请选择所在地区')
}
if(!this.form.address) {
return this.$u.toast('请输入详细地址')
}
if(!this.form.declareReason) {
return this.$u.toast('请选择帮扶原因')
}
if(this.form.declareReason) {
if(this.checkList.length > 2) {
return this.$u.toast('帮扶原因最多选2项')
}
}
if(!this.form.riskDescription) {
return this.$u.toast('请输入帮扶原因说明')
}
this.flag = true
this.$http.post('/app/apphelpdeclarationinfo/addByEw',{...this.form}).then((res) => {
if(res.code ==0) {
uni.navigateTo({url: './result'})
}
})
}
},
}
</script>
<style lang="scss" scoped>
::v-deep uni-page-body {
height: 100%;
font-size: 32px !important;
}
.add {
.tips {
padding: 32px;
box-sizing: border-box;
background: #FFF8F3;
color: #FF883C;
font-size: 30px;
}
.user_info,
.family_info {
background: #FFF;
.item {
display: flex;
padding: 32px;
box-sizing: border-box;
border-bottom: 1px solid #DDDDDD;
.left {
width: 240px;
span:first-child {
color: #FF4466;
}
}
.right__text {
width: calc(100% - 240px);
text-align: right;
}
.color-999 {
color: #999;
}
.color-333 {
color: #333;
}
}
.item:last-child {
border-bottom: none;
}
.items {
padding: 32px;
box-sizing: border-box;
border-bottom: 1px solid #DDDDDD;
.left {
span:first-child {
color: #FF4466;
}
}
.text {
margin-top: 20px;
}
.textarea {
margin-top: 32px;
}
.tags {
margin-top: 20px;
span {
display: inline-block;
width: 31%;
height: 80px;
line-height: 80px;
text-align: center;
box-sizing: border-box;
border-radius: 16px;
border: 1px solid #CCCCCC;
margin-right: 20px;
margin-bottom: 16px;
}
span:nth-child(3n) {
margin-right: 0;
}
.isCheck {
color: #FFF;
background: #4181FF;
}
}
}
.items:last-child {
border-bottom: none;
}
}
.family_info {
margin-top: 16px;
}
::v-deep .uni-input-wrapper .uni-input-placeholder {
font-size: 28px;
color: #999;
}
.btn {
position: fixed;
bottom: 0;
left: 0;
width: 100%;
height: 112px;
line-height: 112px;
text-align: center;
background: #4181FF;
color: #FFF;
font-size: 34px;
z-index: 999;
}
}
</style>

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.7 KiB

View File

@@ -0,0 +1,142 @@
<template>
<div class="details">
<div class="event_info">
<div class="content">{{ data.riskDescription }}</div>
<div class="picture" v-if="data.files.length">
<img :src="item.url" v-for="(item,index) in data.files" :key="index" alt="" @click="preview(index)">
</div>
<div class="tags">
<span v-for="(item,index) in list" :key="index">{{item}}</span>
</div>
</div>
<div class="progress_info">
<div class="item">
<label>申报进度</label>
<div :style="{color: item.status == 0? '#FF883C':item.status == 1? '#1AAAFF': item.status==2? '#FF4466': '#42D784'}">{{ $dict.getLabel('helpDeclarationStatus', data.status) }}</div>
</div>
<div class="item">
<label>申报人姓名</label>
<div>{{ data.name }}</div>
</div>
<div class="item">
<label>申报时间</label>
<div>{{ data.declareTime }}</div>
</div>
<div class="items">
<label>详细地址</label>
<div>{{ data.address }}</div>
</div>
</div>
<div class="progress"></div>
</div>
</template>
<script>
export default {
data() {
return {
list: [],
data: {},
id: '',
}
},
onLoad(o) {
this.$dict.load('helpDeclarationStatus')
if (o.id) {
this.id = o.id
this.getDetail()
}
},
methods: {
getDetail() {
this.$instance.post(`/app/apphelpdeclarationinfo/queryDetailById?id=${this.id}`).then(res => {
if(res.code == 0) {
this.data = res.data
this.list = res.data.reason.split(',')
}
})
},
preview(index) {
this.$previewImage(this.data.files, index, "url");
},
}
}
</script>
<style lang="scss" scoped>
.details {
.event_info {
background: #FFFFFF;
padding: 32px;
box-sizing: border-box;
.content {
background: #FFFFFF;
}
.picture {
margin-top: 32px;
img {
width: 220px;
height: 220px;
margin-right: 10px;
}
}
.tags {
margin-top: 20px;
span {
display: inline-block;
margin-right: 16px;
background: #EEEEEE;
padding: 4px 16px;
box-sizing: border-box;
border-radius: 24px;
margin-bottom: 16px;
color: #999999;
}
}
}
.progress_info {
margin-top: 16px;
background: #FFF;
padding: 0 32px 20px 32px;
box-sizing: border-box;
.item {
padding: 32px;
box-sizing: border-box;
display: flex;
justify-content: space-between;
border-bottom: 1px solid #DDDDDD;
label {
color: #999999;
}
}
.items {
padding: 32px;
box-sizing: border-box;
label {
color: #999999;
}
div {
margin-top: 32px;
}
}
.status0 {
color: #FF883C
}
.status1 {
color: #1AAAFF
}
.status2 {
color: #42D784
}
.status3 {
color: #FF4466
}
}
}
</style>

View File

@@ -0,0 +1,208 @@
<template>
<div class="progress">
<AiTopFixed>
<div class="tab-select">
<div class="item" :class="tabIndex == index ? 'active' : ''" v-for="(item, index) in tabs" :key="index" @click="tabClick(index)">{{item}}<span></span></div>
</div>
<div class="select-box">
<div class="left">
<!-- :areaId="user.areaId" @select="areaSelect" select-root -->
<AiAreaPicker v-model="areaId" :name.sync="areaName" >
<div style="display: flex;">
<span v-if="areaName" style="color:#333;fontSize: 14px;" class="areaName">{{ areaName }}</span>
<span v-else style="color: #999;fontSize: 14px;" class="areaName">所在地区</span>
<u-icon name="arrow-down" color="#999" size="24" style="margin-left: 4px;width: 14px;display:inline-block;margin-top:18px"></u-icon>
<u-icon name="close-circle" v-if="areaId" color="#999" size="24" style="margin-left: 4px;width: 14px;display:inline-block;margin-top:18px"></u-icon>
</div>
</AiAreaPicker>
</div>
<div class="right">
<AiSelect dict="helpDeclarationStatus" v-model="status">
<span v-if="!status" style="color: #999;">风险类型</span>
<span v-else>{{status}}</span>
<u-icon name="arrow-down" color="#999" size="24" style="margin-left: 4px;width: 14px;display:inline-block;"></u-icon>
<u-icon name="close-circle" v-if="ststus" color="#999" size="24" style="margin-left: 4px;width: 14px;display:inline-block;"></u-icon>
</AiSelect>
</div>
</div>
</AiTopFixed>
<div v-if="list.length">
<div class="card_list" v-for="(item,index) in list" :key="index">
<div class="card" @click="$linkTo(`./details?id=${item.id}`)">
<div class="top">
<div class="title">{{ item.riskDescription }}</div>
<div class="time">{{ item.declareTime }}</div>
</div>
<div class="bottom">
<span :style="{background: item.status == 0? '#FF883C':item.status == 1? '#1AAAFF': item.status==2? '#FF4466': '#42D784'}"></span>
<span :class="item.status == 0? 'status0': item.status==1? 'status1': item.status==2? 'status3': 'status2'">{{ $dict.getLabel('helpDeclarationStatus',item.status) }}</span>
</div>
</div>
</div>
</div>
<AiEmpty v-else description="暂无数据"/>
<AiFixedBtn>
<div class="addBtn iconfont iconfont-iconfangda" @tap="toAdd()"/>
</AiFixedBtn>
</div>
</template>
<script>
export default {
data() {
return {
tabs: ['全部待办','办理历史'],
tabIndex: 0,
list: [],
current: 1,
areaId: '',
areaName: '',
status: '',
}
},
onShow() {
this.$dict.load('helpDeclarationStatus')
this.getList()
},
methods: {
tabClick(index) {
this.current = 1,
this.list = [],
this.tabIndex = index,
this.getList()
},
getList() {
this.$http.post('/app/apphelpdeclarationinfo/list',null,{
params: {
current: this.current,
// status: this.tabIndex == 0 ?
}
}).then((res) => {
if(res?.data) {
this.list = this.current == 1? res.data.records : [...this.list,...res.data.records]
}
})
},
toAdd() {
uni.navigateTo({url: './add'})
},
onReachBottom() {
this.current ++
this.getList()
}
}
}
</script>
<style lang="scss" scoped>
.progress {
// padding-top: 24px;
::v-deep .AiTopFixed .content {
padding: 0;
}
.tab-select {
width: 100%;
height: 96px;
line-height: 96px;
background: #3975C6;
display: flex;
.item{
flex: 1;
text-align: center;
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
color: #CDDCF0;
}
.active{
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
position: relative;
color: #fff;
span{
width: 48px;
height: 4px;
background: #FFF;
position: absolute;
bottom: 14px;
left: 50%;
margin-left: -24px;
}
}
}
.select-box {
display: flex;
height: 96px;
line-height: 96px;
width: 100%;
.left,
.right {
flex: 1;
text-align: center !important;
font-size: 28px;
}
}
.card_list {
padding: 0 32px;
box-sizing: border-box;
.card {
background: #FFFFFF;
box-shadow: 0px 0px 8px 0px #00000005;
border-radius: 16px;
margin-bottom: 24px;
.top {
padding: 32px;
box-sizing: border-box;
border-bottom: 2px solid #DDDDDD;
.title {
color: #333333;
font-size: 32px;
font-weight: 600;
overflow:hidden;
text-overflow:ellipsis;
display:-webkit-box;
-webkit-box-orient:vertical;
-webkit-line-clamp:2;
}
.time {
margin-top: 32px;
color: #999999;
font-size: 26px;
}
}
.bottom {
padding: 32px;
box-sizing: border-box;
span:first-child {
display: inline-block;
width: 8px;
height: 8px;
border-radius: 50%;
margin-right: 8px;
background: #FF4466;
}
}
.status0 {
color: #FF883C
}
.status1 {
color: #1AAAFF
}
.status2 {
color: #42D784
}
.status3 {
color: #FF4466
}
}
}
}
</style>

View File

@@ -0,0 +1,82 @@
<template>
<div class="service-result" >
<!-- v-if="showPage" -->
<img src="./components/resultPic.png" />
<h2>申请成功</h2>
<div class="service-btn" hover-class="text-hover" @click="myAdd">查看我的申报</div>
<div class="service-btn" hover-class="text-hover" @click="back">返回</div>
</div>
</template>
<script>
export default {
name: 'result',
data() {
return {
showPage: false,
title: '',
}
},
onLoad(query) {
this.title = query.title
uni.setNavigationBarTitle({
title: this.title,
})
if (this.title) {
this.showPage = true
}
},
methods: {
myAdd() {
uni.reLaunch({url: './progress'})
},
back() {
uni.navigateBack()
},
},
}
</script>
<style lang="scss" scoped>
.service-result {
min-height: 100vh;
padding-top: 96px;
text-align: center;
background: #fff;
box-sizing: border-box;
.service-btn {
width: 320px;
height: 88px;
line-height: 88px;
margin: 80px auto 0;
text-align: center;
background: #4181FF;
font-size: 36px;
color: #fff;
box-shadow: 0 8px 16px 0 rgba(0, 0, 0, 0.02);
border-radius: 16px;
}
.service-btn:last-child {
margin-top: 30px;
background: #FFF;
color: #4181FF;
border: 1px solid #4181FF;
}
h2 {
margin-bottom: 32px;
color: #333333;
font-size: 40px;
font-weight: 600;
}
image {
width: 240px;
height: 240px;
}
}
</style>

View File

@@ -9,13 +9,13 @@
<image :src="$cdn + 'yjjk.png'"/> <image :src="$cdn + 'yjjk.png'"/>
<h2>预警监控</h2> <h2>预警监控</h2>
</div> </div>
<div class="info-top__item" @click="linkTo('../AppServicePublic/AppServicePublic?moduleId=ac80f2857f2c4e4d8f0e266a703aed7a&listName=政策动态')"> <div class="info-top__item" @click="linkTo('../AppHelpDeclaration/list')">
<image :src="$cdn + 'news.png'"/> <image :src="$cdn + 'sbsp.png'"/>
<h2>政策动态</h2> <h2>申报审批</h2>
</div> </div>
</div> </div>
<div class="news"> <div class="news">
<h2>最新动态</h2> <u-section title="最新动态" :show-line="false" font-size="32" bold sub-title="全部" @click="linkTo('../AppServicePublic/AppServicePublic?moduleId=ac80f2857f2c4e4d8f0e266a703aed7a&listName=政策动态')"></u-section>
<div class="news-list" v-if="list.length"> <div class="news-list" v-if="list.length">
<div class="news-item" v-for="(item, index) in list" :key="index" <div class="news-item" v-for="(item, index) in list" :key="index"
@click="linkTo(`../AppServicePublic/Detail?id=${item.id}&listName=政策动态`)"> @click="linkTo(`../AppServicePublic/Detail?id=${item.id}&listName=政策动态`)">
@@ -48,7 +48,7 @@ export default {
this.getList() this.getList()
}) })
console.log(this.$cdn + 'wdbf.png') // console.log(this.$cdn + 'wdbf.png')
}, },
onShow() { onShow() {
document.title = "防返贫" document.title = "防返贫"
@@ -119,11 +119,8 @@ export default {
} }
.news { .news {
& > h2 { & > .u-section {
margin-bottom: 32px; margin-bottom: 32px;
color: #333333;
font-weight: 600;
font-size: 32px;
} }
.news-item { .news-item {

View File

@@ -107,6 +107,7 @@ export default {
color: #333333; color: #333333;
font-weight: 600; font-weight: 600;
font-size: 32px; font-size: 32px;
} }
.news-item { .news-item {