xg
This commit is contained in:
parent
b737424eb3
commit
8b7f5295ea
@ -20,3 +20,16 @@ export function scoretotal(cardNo) {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
//健康行为
|
||||||
|
export function healthActlist(data) {
|
||||||
|
return request({
|
||||||
|
url: `/applet/score/healthAct/list`,
|
||||||
|
method: 'get',
|
||||||
|
data,
|
||||||
|
header: {
|
||||||
|
region: uni.getStorageSync('region'),
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
@ -440,6 +440,13 @@
|
|||||||
"navigationBarTitleText": "我的评价",
|
"navigationBarTitleText": "我的评价",
|
||||||
"enablePullDownRefresh": false
|
"enablePullDownRefresh": false
|
||||||
}
|
}
|
||||||
|
},{
|
||||||
|
"path": "behavior/behavior",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "健康行为",
|
||||||
|
"onReachBottomDistance": 40, //距离底部多远时触发 单位为px
|
||||||
|
"enablePullDownRefresh": true //设置参数为true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}, {
|
}, {
|
||||||
|
|||||||
@ -1,127 +1,126 @@
|
|||||||
.app {
|
.app {
|
||||||
background-color: #F7F5F5;
|
background-color: #F7F5F5;
|
||||||
height:100vh;
|
height: 100vh;
|
||||||
padding-top: 30rpx;
|
padding-top: 20rpx;
|
||||||
.background{
|
|
||||||
height:100%;
|
|
||||||
background-color: #fff;
|
|
||||||
width: 95%;
|
|
||||||
margin: 0 auto;
|
|
||||||
.content {
|
|
||||||
position: relative;
|
|
||||||
margin-bottom: 50rpx;
|
|
||||||
image {
|
|
||||||
width: 100%;
|
|
||||||
height: 500rpx;
|
|
||||||
}
|
|
||||||
.wxSport{
|
|
||||||
width: 25%;
|
|
||||||
height: 54rpx;
|
|
||||||
background: #00785C;
|
|
||||||
border-radius: 24rpx;
|
|
||||||
position: absolute;
|
|
||||||
bottom: 0%;
|
|
||||||
right: 6%;
|
|
||||||
color: #fff;
|
|
||||||
text-align: center;
|
|
||||||
border: 2rpx solid #00785C;
|
|
||||||
line-height: 54rpx;
|
|
||||||
}
|
|
||||||
.Exchangerecords {
|
|
||||||
width: 25%;
|
|
||||||
height: 54rpx;
|
|
||||||
background: #00785C;
|
|
||||||
border-radius: 24rpx;
|
|
||||||
position: absolute;
|
|
||||||
bottom: 0%;
|
|
||||||
left: 50%;
|
|
||||||
transform: translateX(-50%);
|
|
||||||
color: #fff;
|
|
||||||
text-align: center;
|
|
||||||
border: 2rpx solid #00785C;
|
|
||||||
line-height: 54rpx;
|
|
||||||
}
|
|
||||||
.PointsMall {
|
|
||||||
width: 25%;
|
|
||||||
height: 54rpx;
|
|
||||||
border: 2rpx solid #00785C;
|
|
||||||
background: #00785C;
|
|
||||||
border-radius: 24rpx;
|
|
||||||
position: absolute;
|
|
||||||
bottom: 0%;
|
|
||||||
left: 6%;
|
|
||||||
color: #fff;
|
|
||||||
text-align: center;
|
|
||||||
line-height: 54rpx;
|
|
||||||
}
|
|
||||||
|
|
||||||
.name {
|
.flex {
|
||||||
width: 90%;
|
width: 100%;
|
||||||
height: 100rpx;
|
display: flex;
|
||||||
font-size: 30rpx;
|
justify-content: space-evenly;
|
||||||
font-weight: 400;
|
position: absolute;
|
||||||
color: #FFFFFF;
|
bottom: 20%;
|
||||||
position: absolute;
|
left: 0%;
|
||||||
top: 10%;
|
|
||||||
left: 5%;
|
|
||||||
line-height: 33rpx;
|
|
||||||
|
|
||||||
}
|
|
||||||
.number {
|
|
||||||
font-size: 56rpx;
|
|
||||||
font-weight: 400;
|
|
||||||
color: #FFFFFF;
|
|
||||||
position: absolute;
|
|
||||||
left: 50%;
|
|
||||||
top: 58%;
|
|
||||||
transform: translateX(-50%);
|
|
||||||
text-overflow: ellipsis;
|
|
||||||
white-space: nowrap;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
.bottomitem{
|
|
||||||
background-color: #FFF;
|
.background {
|
||||||
|
height: 100%;
|
||||||
|
background-color: #fff;
|
||||||
|
width: 95%;
|
||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
padding-bottom: 100rpx;
|
|
||||||
.item{
|
.content {
|
||||||
position: relative;
|
position: relative;
|
||||||
|
margin-bottom: 80rpx;
|
||||||
|
padding-bottom: 50rpx;
|
||||||
|
|
||||||
|
.title {
|
||||||
|
position: absolute;
|
||||||
|
left: 40rpx;
|
||||||
|
top: 10rpx;
|
||||||
|
font-weight: 600;
|
||||||
|
color: #26A888;
|
||||||
|
padding-left: 20rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
image {
|
||||||
|
width: 100%;
|
||||||
|
height: 450rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
.item {
|
||||||
|
width: 25%;
|
||||||
|
height: 54rpx;
|
||||||
|
background: #00785C;
|
||||||
|
border-radius: 24rpx;
|
||||||
|
color: #fff;
|
||||||
|
text-align: center;
|
||||||
|
border: 2rpx solid #00785C;
|
||||||
|
line-height: 54rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
.name {
|
||||||
|
width: 90%;
|
||||||
|
height: 100rpx;
|
||||||
|
font-size: 30rpx;
|
||||||
|
font-weight: 400;
|
||||||
|
color: #FFFFFF;
|
||||||
|
position: absolute;
|
||||||
|
top: 10%;
|
||||||
|
left: 5%;
|
||||||
|
line-height: 33rpx;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
.number {
|
||||||
|
font-size: 56rpx;
|
||||||
|
font-weight: 400;
|
||||||
|
color: #FFFFFF;
|
||||||
|
position: absolute;
|
||||||
|
left: 50%;
|
||||||
|
top: 58%;
|
||||||
|
transform: translateX(-50%);
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
.Establishingarchives{
|
|
||||||
font-size: 30rpx;
|
.bottomitem {
|
||||||
font-weight: 400;
|
background-color: #FFF;
|
||||||
color: #333333;
|
margin: 0 auto;
|
||||||
line-height: 38rpx;
|
padding-bottom: 100rpx;
|
||||||
padding: 8px 10px 5px 18px;
|
|
||||||
}
|
.item {
|
||||||
.integraltwo{
|
position: relative;
|
||||||
color: red !important;
|
}
|
||||||
}
|
|
||||||
.integral{
|
.Establishingarchives {
|
||||||
position: absolute;
|
font-size: 30rpx;
|
||||||
top: 34%;
|
font-weight: 400;
|
||||||
right: 3%;
|
color: #333333;
|
||||||
color: #26A888;
|
line-height: 38rpx;
|
||||||
overflow: hidden;
|
padding: 8px 10px 5px 18px;
|
||||||
text-overflow: ellipsis;
|
}
|
||||||
white-space: nowrap;
|
|
||||||
}
|
.integraltwo {
|
||||||
.timeone{
|
color: red !important;
|
||||||
font-size: 20rpx;
|
}
|
||||||
font-weight: 400;
|
|
||||||
color: #333333;
|
.integral {
|
||||||
line-height: 38rpx;
|
position: absolute;
|
||||||
padding: 0 10px 10px 18px;
|
top: 34%;
|
||||||
border-bottom: 1px solid #E6E6E6;
|
right: 3%;
|
||||||
}
|
color: #26A888;
|
||||||
.PointsRecord {
|
overflow: hidden;
|
||||||
font-size: 30rpx;
|
text-overflow: ellipsis;
|
||||||
font-weight: 400;
|
white-space: nowrap;
|
||||||
color: #000000;
|
}
|
||||||
line-height: 33rpx;
|
|
||||||
padding: 10px 10px 10px 15px;
|
.timeone {
|
||||||
|
font-size: 20rpx;
|
||||||
|
font-weight: 400;
|
||||||
|
color: #333333;
|
||||||
|
line-height: 38rpx;
|
||||||
|
padding: 0 10px 10px 18px;
|
||||||
|
border-bottom: 1px solid #E6E6E6;
|
||||||
|
}
|
||||||
|
|
||||||
|
.PointsRecord {
|
||||||
|
font-size: 30rpx;
|
||||||
|
font-weight: 400;
|
||||||
|
color: #000000;
|
||||||
|
line-height: 33rpx;
|
||||||
|
padding: 10px 10px 10px 15px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
@ -2,6 +2,9 @@
|
|||||||
<view class="app">
|
<view class="app">
|
||||||
<view class="background">
|
<view class="background">
|
||||||
<view class="content">
|
<view class="content">
|
||||||
|
<view class="title" v-if="region==2">
|
||||||
|
{{title}}
|
||||||
|
</view>
|
||||||
<image mode="" :src="require('../images/jifen.png')" v-if='region==2'></image>
|
<image mode="" :src="require('../images/jifen.png')" v-if='region==2'></image>
|
||||||
<image src="@/static/pagesB/Behave.png" mode="" v-if='region!=2' :style="region!=2?'height:350rpx':''">
|
<image src="@/static/pagesB/Behave.png" mode="" v-if='region!=2' :style="region!=2?'height:350rpx':''">
|
||||||
</image>
|
</image>
|
||||||
@ -9,14 +12,21 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="number" :style="region!=2?'top:35%':''">{{score?score:0}}
|
<view class="number" :style="region!=2?'top:35%':''">{{score?score:0}}
|
||||||
</view>
|
</view>
|
||||||
<view class="PointsMall" @tap='gointegral' :style="region!=2?'bottom:15%':''">
|
<view class="flex" :style="region==2?'bottom:5%':''">
|
||||||
积分商城
|
<view class="item" @tap='gointegral'>
|
||||||
|
积分商城
|
||||||
|
</view>
|
||||||
|
<view class="item" @tap="goexchange">
|
||||||
|
兑换记录
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="Exchangerecords" @tap="goexchange" :style="region!=2?'bottom:15%':''">
|
<view class="flex" v-if="region==2" :style="region==2?'bottom:-10%':''">
|
||||||
兑换记录
|
<view class="item" @tap="gowxSport">
|
||||||
</view>
|
微信运动
|
||||||
<view class="wxSport" @tap="gowxSport" :style="region!=2?'bottom:15%':''">
|
</view>
|
||||||
微信运动
|
<view class="item" @tap='gobehavior'>
|
||||||
|
健康行为
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="bottomitem">
|
<view class="bottomitem">
|
||||||
@ -49,12 +59,18 @@
|
|||||||
scorelist,
|
scorelist,
|
||||||
scoretotal
|
scoretotal
|
||||||
} from '@/api/pagesB/Behaviorpoints/index.js'
|
} from '@/api/pagesB/Behaviorpoints/index.js'
|
||||||
|
import {
|
||||||
|
detail,
|
||||||
|
} from '@/api/pages/homepage/homepage.js'
|
||||||
// import {
|
// import {
|
||||||
// mapActions
|
// mapActions
|
||||||
// } from "vuex";
|
// } from "vuex";
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
noticebarlist: [
|
||||||
|
'给自己开一个健康储蓄账户',
|
||||||
|
],
|
||||||
query: {
|
query: {
|
||||||
identity: uni.getStorageSync('userinfo').cardNo,
|
identity: uni.getStorageSync('userinfo').cardNo,
|
||||||
pageNum: 1,
|
pageNum: 1,
|
||||||
@ -64,17 +80,24 @@
|
|||||||
list: null,
|
list: null,
|
||||||
total: 0,
|
total: 0,
|
||||||
score: 0,
|
score: 0,
|
||||||
|
title: '',
|
||||||
|
orgNo: '',
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
onLoad() {
|
onLoad() {
|
||||||
|
|
||||||
this.info();
|
this.info();
|
||||||
this.scoretotalinfo();
|
this.scoretotalinfo();
|
||||||
},
|
},
|
||||||
onReady() { //更改导航栏文字
|
onReady() { //更改导航栏文字
|
||||||
if (uni.getStorageSync('region') == 2) {
|
if (uni.getStorageSync('region') == 2) {
|
||||||
uni.setNavigationBarTitle({
|
detail(this.query.identity).then(res => {
|
||||||
title: '东营健康银行'
|
this.title = '东营健康银行' + res.data.countyName + '分行'
|
||||||
});
|
this.orgNo = res.data.orgNo
|
||||||
|
uni.setNavigationBarTitle({
|
||||||
|
title: '东营健康银行' + res.data.countyName + '分行'
|
||||||
|
});
|
||||||
|
})
|
||||||
} else {
|
} else {
|
||||||
uni.setNavigationBarTitle({
|
uni.setNavigationBarTitle({
|
||||||
title: '积分兑换'
|
title: '积分兑换'
|
||||||
@ -100,7 +123,12 @@
|
|||||||
},
|
},
|
||||||
goexchange() {
|
goexchange() {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pagesB/exchangerecords/exchangerecords'
|
url: `/pagesB/exchangerecords/exchangerecords`
|
||||||
|
})
|
||||||
|
},
|
||||||
|
gobehavior() {
|
||||||
|
uni.navigateTo({
|
||||||
|
url: `/pagesB/behavior/behavior?orgNo=${this.orgNo}`
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
//积分页面
|
//积分页面
|
||||||
@ -122,7 +150,6 @@
|
|||||||
// }
|
// }
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
onReachBottom() { //下滑加载
|
onReachBottom() { //下滑加载
|
||||||
if (this.list.length >= this.total) {} else {
|
if (this.list.length >= this.total) {} else {
|
||||||
this.query.pageNum++
|
this.query.pageNum++
|
||||||
|
|||||||
89
pagesB/behavior/behavior.vue
Normal file
89
pagesB/behavior/behavior.vue
Normal file
@ -0,0 +1,89 @@
|
|||||||
|
<template>
|
||||||
|
<view class="app">
|
||||||
|
<u-table>
|
||||||
|
<u-tr>
|
||||||
|
<u-th>适用</br>人群</u-th>
|
||||||
|
<u-th>行为</br>序号</u-th>
|
||||||
|
<u-th>行为</br>名称</u-th>
|
||||||
|
<u-th>具体</br>内容</u-th>
|
||||||
|
<u-th>积分</br>分值</u-th>
|
||||||
|
<u-th>积分</br>周期</u-th>
|
||||||
|
<u-th>分值</br>来源</u-th>
|
||||||
|
</u-tr>
|
||||||
|
<u-tr v-for="(item,index) in list" :key='index'>
|
||||||
|
<u-td>{{item.targetGroupsName}}</u-td>
|
||||||
|
<u-td>{{index+1}}</u-td>
|
||||||
|
<u-td>{{item.actName}}</u-td>
|
||||||
|
<u-td @tap='look(item)'>
|
||||||
|
<view class="utd">
|
||||||
|
查看
|
||||||
|
</view>
|
||||||
|
</u-td>
|
||||||
|
<u-td>{{item.score}}</u-td>
|
||||||
|
<u-td>{{item.periodName}}</u-td>
|
||||||
|
<u-td>{{item.sourceName}}</u-td>
|
||||||
|
</u-tr>
|
||||||
|
</u-table>
|
||||||
|
<u-popup v-model="lookopen" mode="center" closeable width='600rpx'>
|
||||||
|
<view style="padding:80rpx 30rpx">{{lookitem.actContent}}</view>
|
||||||
|
</u-popup>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import {
|
||||||
|
healthActlist
|
||||||
|
} from '@/api/pagesB/Behaviorpoints/index.js'
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
list: [],
|
||||||
|
total: 0,
|
||||||
|
query: {
|
||||||
|
identity: uni.getStorageSync('userinfo').cardNo,
|
||||||
|
pageNum: 1,
|
||||||
|
pageSize: 20,
|
||||||
|
orgNo: ''
|
||||||
|
},
|
||||||
|
lookopen: false,
|
||||||
|
lookitem: {},
|
||||||
|
};
|
||||||
|
},
|
||||||
|
onLoad(options) {
|
||||||
|
this.query.orgNo = options.orgNo
|
||||||
|
this.info();
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
look(item) {
|
||||||
|
this.lookitem = item
|
||||||
|
this.lookopen = true
|
||||||
|
},
|
||||||
|
info() {
|
||||||
|
healthActlist(this.query).then(res => {
|
||||||
|
this.list = [...this.list, ...res.rows]
|
||||||
|
this.total = res.total
|
||||||
|
})
|
||||||
|
},
|
||||||
|
},
|
||||||
|
onReachBottom() { //下滑加载
|
||||||
|
if (this.list.length >= this.total) {} else {
|
||||||
|
this.query.pageNum++;
|
||||||
|
this.info();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
onPullDownRefresh() { //下拉刷新
|
||||||
|
this.query.pageNum = 1;
|
||||||
|
this.list = []
|
||||||
|
this.info();
|
||||||
|
setTimeout(function() {
|
||||||
|
uni.stopPullDownRefresh();
|
||||||
|
}, 1000);
|
||||||
|
},
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss">
|
||||||
|
::v-deep .utd {
|
||||||
|
color: #26A888 !important;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
Binary file not shown.
|
Before Width: | Height: | Size: 33 KiB After Width: | Height: | Size: 185 KiB |
Loading…
Reference in New Issue
Block a user