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": "我的评价",
|
||||
"enablePullDownRefresh": false
|
||||
}
|
||||
},{
|
||||
"path": "behavior/behavior",
|
||||
"style": {
|
||||
"navigationBarTitleText": "健康行为",
|
||||
"onReachBottomDistance": 40, //距离底部多远时触发 单位为px
|
||||
"enablePullDownRefresh": true //设置参数为true
|
||||
}
|
||||
}
|
||||
]
|
||||
}, {
|
||||
|
||||
@ -1,127 +1,126 @@
|
||||
.app {
|
||||
background-color: #F7F5F5;
|
||||
height:100vh;
|
||||
padding-top: 30rpx;
|
||||
.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;
|
||||
}
|
||||
.app {
|
||||
background-color: #F7F5F5;
|
||||
height: 100vh;
|
||||
padding-top: 20rpx;
|
||||
|
||||
.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;
|
||||
}
|
||||
.flex {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
justify-content: space-evenly;
|
||||
position: absolute;
|
||||
bottom: 20%;
|
||||
left: 0%;
|
||||
}
|
||||
.bottomitem{
|
||||
background-color: #FFF;
|
||||
|
||||
.background {
|
||||
height: 100%;
|
||||
background-color: #fff;
|
||||
width: 95%;
|
||||
margin: 0 auto;
|
||||
padding-bottom: 100rpx;
|
||||
.item{
|
||||
|
||||
.content {
|
||||
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;
|
||||
font-weight: 400;
|
||||
color: #333333;
|
||||
line-height: 38rpx;
|
||||
padding: 8px 10px 5px 18px;
|
||||
}
|
||||
.integraltwo{
|
||||
color: red !important;
|
||||
}
|
||||
.integral{
|
||||
position: absolute;
|
||||
top: 34%;
|
||||
right: 3%;
|
||||
color: #26A888;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
.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;
|
||||
|
||||
.bottomitem {
|
||||
background-color: #FFF;
|
||||
margin: 0 auto;
|
||||
padding-bottom: 100rpx;
|
||||
|
||||
.item {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.Establishingarchives {
|
||||
font-size: 30rpx;
|
||||
font-weight: 400;
|
||||
color: #333333;
|
||||
line-height: 38rpx;
|
||||
padding: 8px 10px 5px 18px;
|
||||
}
|
||||
|
||||
.integraltwo {
|
||||
color: red !important;
|
||||
}
|
||||
|
||||
.integral {
|
||||
position: absolute;
|
||||
top: 34%;
|
||||
right: 3%;
|
||||
color: #26A888;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.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="background">
|
||||
<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 src="@/static/pagesB/Behave.png" mode="" v-if='region!=2' :style="region!=2?'height:350rpx':''">
|
||||
</image>
|
||||
@ -9,14 +12,21 @@
|
||||
</view>
|
||||
<view class="number" :style="region!=2?'top:35%':''">{{score?score:0}}
|
||||
</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 class="Exchangerecords" @tap="goexchange" :style="region!=2?'bottom:15%':''">
|
||||
兑换记录
|
||||
</view>
|
||||
<view class="wxSport" @tap="gowxSport" :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="item" @tap='gobehavior'>
|
||||
健康行为
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="bottomitem">
|
||||
@ -49,12 +59,18 @@
|
||||
scorelist,
|
||||
scoretotal
|
||||
} from '@/api/pagesB/Behaviorpoints/index.js'
|
||||
import {
|
||||
detail,
|
||||
} from '@/api/pages/homepage/homepage.js'
|
||||
// import {
|
||||
// mapActions
|
||||
// } from "vuex";
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
noticebarlist: [
|
||||
'给自己开一个健康储蓄账户',
|
||||
],
|
||||
query: {
|
||||
identity: uni.getStorageSync('userinfo').cardNo,
|
||||
pageNum: 1,
|
||||
@ -64,17 +80,24 @@
|
||||
list: null,
|
||||
total: 0,
|
||||
score: 0,
|
||||
title: '',
|
||||
orgNo: '',
|
||||
};
|
||||
},
|
||||
onLoad() {
|
||||
|
||||
this.info();
|
||||
this.scoretotalinfo();
|
||||
},
|
||||
onReady() { //更改导航栏文字
|
||||
if (uni.getStorageSync('region') == 2) {
|
||||
uni.setNavigationBarTitle({
|
||||
title: '东营健康银行'
|
||||
});
|
||||
detail(this.query.identity).then(res => {
|
||||
this.title = '东营健康银行' + res.data.countyName + '分行'
|
||||
this.orgNo = res.data.orgNo
|
||||
uni.setNavigationBarTitle({
|
||||
title: '东营健康银行' + res.data.countyName + '分行'
|
||||
});
|
||||
})
|
||||
} else {
|
||||
uni.setNavigationBarTitle({
|
||||
title: '积分兑换'
|
||||
@ -100,7 +123,12 @@
|
||||
},
|
||||
goexchange() {
|
||||
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() { //下滑加载
|
||||
if (this.list.length >= this.total) {} else {
|
||||
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