Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
@@ -10,7 +10,7 @@
|
||||
<span v-else>欢迎进入{{ user.areaName }}!</span>
|
||||
|
||||
</div>
|
||||
<div class="signin" @click="toPages('./signIn')">签到</div>
|
||||
<div class="signin" @click="toPages('./signIn',status)">{{ status==1? '已签到':'签到' }}</div>
|
||||
</div>
|
||||
<div class="card-list">
|
||||
<div class="jfsq" @click="toPages('./integralApply')">
|
||||
@@ -30,27 +30,30 @@
|
||||
<h4>兑换得好物</h4>
|
||||
</div>
|
||||
</div>
|
||||
<div class="handpick">
|
||||
<div class="handpick" v-if="list.length">
|
||||
<div class="title">
|
||||
<h1>精选动态</h1>
|
||||
<div class="more" @click="toPages('./handpick')">
|
||||
<div class="more" v-if="list.length > 3" @click="toPages('./handpick')">
|
||||
<span>更多</span>
|
||||
<u-icon name="arrow-right" color="#687DA6" size="28"></u-icon>
|
||||
</div>
|
||||
</div>
|
||||
<div class="list" @click="toPages('内容建设中...')">
|
||||
<div class="top">
|
||||
<div class="left">百年征和波澜壮阔,百年初心历争议弥坚。7月1日上午,庆祝中国共产党成立100周年…</div>
|
||||
<div class="right">
|
||||
<img src="https://cdn.cunwuyun.cn/wxmp/fengdu/zan-active.png" alt="">
|
||||
<!-- https://cdn.cunwuyun.cn/wxmp/fengdu/zan.png -->
|
||||
<span>99+</span>
|
||||
<div class="list" v-if="list.length">
|
||||
<div class="card" v-for="(item,index) in list" :key="index" @click="toPages(`./handpick?id=${item.id}`)">
|
||||
<div class="top">
|
||||
<div class="left">百年征和波澜壮阔,百年初心历争议弥坚。7月1日上午,庆祝中国共产党成立100周年…</div>
|
||||
<div class="right">
|
||||
<img src="https://cdn.cunwuyun.cn/wxmp/fengdu/zan-active.png" alt="">
|
||||
<!-- https://cdn.cunwuyun.cn/wxmp/fengdu/zan.png -->
|
||||
<span>99+</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="bottom">
|
||||
<img src="https://cdn.cunwuyun.cn/fengdu/img-jifenlist.png" alt="">
|
||||
</div>
|
||||
</div>
|
||||
<div class="bottom">
|
||||
<img src="https://cdn.cunwuyun.cn/fengdu/img-jifenlist.png" alt="">
|
||||
</div>
|
||||
</div>
|
||||
<!-- <AiEmpty :description="`暂无数据`" class="emptyWrap" v-else/> -->
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
@@ -62,24 +65,32 @@ export default {
|
||||
appName: "功德银行",
|
||||
data() {
|
||||
return {
|
||||
|
||||
status: null,
|
||||
current: 1,
|
||||
list: [],
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
...mapState(['user'])
|
||||
},
|
||||
methods: {
|
||||
getList() {
|
||||
this.$instance.post(``).then(res=> {
|
||||
getList(moduleId) {
|
||||
this.$instance.post(`/app/appcontentinfo/list-web`,null,{
|
||||
params: {
|
||||
moduleId: moduleId,
|
||||
current: this.current,
|
||||
// areaId: this.user.areaId
|
||||
}
|
||||
}).then(res=> {
|
||||
if(res?.data) {
|
||||
console.log(res);
|
||||
this.list = res.data.records.length > 3 ? res.data.records.slice(2) : res.data.records
|
||||
}
|
||||
})
|
||||
},
|
||||
handleBannerClick() {
|
||||
|
||||
|
||||
},
|
||||
toPages(url) {
|
||||
toPages(url,status) {
|
||||
if(!this.user.idNumber) {
|
||||
this.$dialog.confirm({
|
||||
content: '您只有完成信息认证后,才可进行相关操作。',
|
||||
@@ -89,22 +100,41 @@ export default {
|
||||
}).catch(() => {
|
||||
})
|
||||
} else {
|
||||
this.$linkTo(url)
|
||||
if(!status) {
|
||||
this.$linkTo(url)
|
||||
} else {
|
||||
// 停留
|
||||
}
|
||||
|
||||
}
|
||||
},
|
||||
getStatus() {
|
||||
this.$instance.post(`/app/appwechatsigninfo/checkSign`).then(res=> {
|
||||
if(res?.data !== null) {
|
||||
this.status = 1
|
||||
}
|
||||
})
|
||||
},
|
||||
getModule() {
|
||||
this.$instance.post(`/app/appintegraluserapply/queryModuleByName`).then(res=> {
|
||||
if(res?.data) {
|
||||
this.getList(res.data)
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
},
|
||||
onShow() {
|
||||
uni.setNavigationBarTitle({
|
||||
title: '功德银行'
|
||||
});
|
||||
// this.getList()
|
||||
this.getStatus()
|
||||
this.getModule()
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.AppNewFarmerBank {
|
||||
|
||||
padding-bottom: 20px;
|
||||
box-sizing: border-box;
|
||||
.swiper-content {
|
||||
width: 100%;
|
||||
height: 332px;
|
||||
@@ -221,40 +251,42 @@ export default {
|
||||
}
|
||||
|
||||
.list {
|
||||
padding: 32px 24px;
|
||||
box-sizing: border-box;
|
||||
background: #FFF;
|
||||
border-radius: 12px;
|
||||
// margin-bottom: 24px;
|
||||
.top {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
.left {
|
||||
width: 562px;
|
||||
overflow:hidden;
|
||||
text-overflow: ellipsis;
|
||||
display: -webkit-box;
|
||||
-webkit-box-orient: vertical;
|
||||
-webkit-line-clamp: 2;
|
||||
.card {
|
||||
margin-bottom: 24px;
|
||||
padding: 32px 24px;
|
||||
box-sizing: border-box;
|
||||
background: #FFF;
|
||||
border-radius: 12px;
|
||||
.top {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
.left {
|
||||
width: 562px;
|
||||
overflow:hidden;
|
||||
text-overflow: ellipsis;
|
||||
display: -webkit-box;
|
||||
-webkit-box-orient: vertical;
|
||||
-webkit-line-clamp: 2;
|
||||
}
|
||||
.right {
|
||||
width: 52px;
|
||||
text-align: center;
|
||||
img {
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
}
|
||||
span {
|
||||
font-size: 28px;
|
||||
font-weight: 400;
|
||||
color: #687DA6;
|
||||
}
|
||||
}
|
||||
}
|
||||
.right {
|
||||
width: 52px;
|
||||
text-align: center;
|
||||
.bottom {
|
||||
img {
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
width: 100%;
|
||||
height: 202px;
|
||||
}
|
||||
span {
|
||||
font-size: 28px;
|
||||
font-weight: 400;
|
||||
color: #687DA6;
|
||||
}
|
||||
}
|
||||
}
|
||||
.bottom {
|
||||
img {
|
||||
width: 100%;
|
||||
height: 202px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -84,6 +84,10 @@ export default {
|
||||
return this.$u.toast('请选择事件类型')
|
||||
}
|
||||
|
||||
if (!this.form.content) {
|
||||
return this.$u.toast('请输入详细描述')
|
||||
}
|
||||
|
||||
if ((this.form.images.length + this.form.videos.length) > 9) {
|
||||
return this.$u.toast('图片和视频不得超过9个')
|
||||
} else {
|
||||
@@ -98,7 +102,6 @@ export default {
|
||||
this.$instance.post(`/app/appintegraluserapply/addOrUpdate`,{
|
||||
...this.form
|
||||
}).then(res=> {
|
||||
this.flag = false
|
||||
if(res?.data) {
|
||||
this.$u.toast('提交成功')
|
||||
uni.$emit('edit')
|
||||
|
||||
@@ -5,10 +5,10 @@
|
||||
<img src="https://cdn.cunwuyun.cn/fengdu/img-qiandaochenggong.png" alt="">
|
||||
</div>
|
||||
<p class="status">今日已完成签到</p>
|
||||
<h4>积分<span>+5</span></h4>
|
||||
<h4>积分<span v-if="data.changeIntegral">+{{ data.changeIntegral || 0}}</span></h4>
|
||||
<div class="times">
|
||||
<div>时间</div>
|
||||
<div class="value">2020-12-11 10:10</div>
|
||||
<div class="value">{{ data.createTime.slice(0,16) }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -20,14 +20,21 @@ export default {
|
||||
appName: '签到',
|
||||
data() {
|
||||
return {
|
||||
|
||||
showPage: false,
|
||||
data: {},
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
|
||||
sign() {
|
||||
this.$instance.post(`/app/appwechatsigninfo/sign`,{}).then(res=> {
|
||||
if(res?.data) {
|
||||
this.data = res.data
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
onShow() {
|
||||
|
||||
this.sign()
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user