xg
This commit is contained in:
parent
c67cae7caf
commit
e450469daa
@ -1,8 +1,8 @@
|
|||||||
import request from "@/api/request.js"
|
import request from "@/api/request.js"
|
||||||
|
|
||||||
export function getHeathHousingList(pageNum, pageSize) {
|
export function getHeathHousingList(pageNum, pageSize, idCard) {
|
||||||
return request({
|
return request({
|
||||||
url: `/nurseApplet/nearbyNursingStation/getHeathHousingList?pageNum=${pageNum}&pageSize=${pageSize}&informationCategoryType=HEALTH_NOUS`,
|
url: `/nurseApplet/nearbyNursingStation/getHeathHousingList?pageNum=${pageNum}&pageSize=${pageSize}&informationCategoryType=HEALTH_NOUS&idCard=${idCard}`,
|
||||||
method: 'get',
|
method: 'get',
|
||||||
header: {
|
header: {
|
||||||
Authorization: 'Bearer' + ' ' + uni.getStorageSync('token'),
|
Authorization: 'Bearer' + ' ' + uni.getStorageSync('token'),
|
||||||
|
|||||||
@ -130,7 +130,7 @@
|
|||||||
},
|
},
|
||||||
// 健康常识
|
// 健康常识
|
||||||
getHeathHousing() {
|
getHeathHousing() {
|
||||||
getHeathHousingList(this.pageNum, this.pageSize).then(res => {
|
getHeathHousingList(this.pageNum, this.pageSize, uni.getStorageSync('userinfo').cardNo).then(res => {
|
||||||
if (res.rows) {
|
if (res.rows) {
|
||||||
res.rows.forEach(e => {
|
res.rows.forEach(e => {
|
||||||
e.leadThumbnailUrl = baseurl + e.leadThumbnailUrl
|
e.leadThumbnailUrl = baseurl + e.leadThumbnailUrl
|
||||||
|
|||||||
@ -21,7 +21,7 @@
|
|||||||
</view>
|
</view>
|
||||||
<u-tabs :list="hospitalDepartmentList" :current="tabcurrent" @change="tabchange" active-color='#26A888'
|
<u-tabs :list="hospitalDepartmentList" :current="tabcurrent" @change="tabchange" active-color='#26A888'
|
||||||
:show-bar='false'></u-tabs>
|
:show-bar='false'></u-tabs>
|
||||||
<view class="list" v-if="HospitalPersonlist">
|
<view class="list" v-if="HospitalPersonlist.length>0">
|
||||||
<view class="item" @tap="godoctordetails" v-for="item in HospitalPersonlist">
|
<view class="item" @tap="godoctordetails" v-for="item in HospitalPersonlist">
|
||||||
<image v-if="item.personPictureUrl" :src="baseurl+item.personPictureUrl" mode=""></image>
|
<image v-if="item.personPictureUrl" :src="baseurl+item.personPictureUrl" mode=""></image>
|
||||||
<image v-else :src="baseurl + '/profile/weChatPicture/docHead.png'" />
|
<image v-else :src="baseurl + '/profile/weChatPicture/docHead.png'" />
|
||||||
@ -68,7 +68,7 @@
|
|||||||
pageNum: 1,
|
pageNum: 1,
|
||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
departmentId: null,
|
departmentId: null,
|
||||||
HospitalPersonlist: null,
|
HospitalPersonlist: [],
|
||||||
HospitalPersontotal: 0,
|
HospitalPersontotal: 0,
|
||||||
hospitalDepartmentList: null,
|
hospitalDepartmentList: null,
|
||||||
cardNo: '',
|
cardNo: '',
|
||||||
@ -94,7 +94,7 @@
|
|||||||
selectHospitalPersonInfo() {
|
selectHospitalPersonInfo() {
|
||||||
var status = '1'
|
var status = '1'
|
||||||
selectHospitalPerson(this.pageNum, this.pageSize, this.departmentId, status).then(res => {
|
selectHospitalPerson(this.pageNum, this.pageSize, this.departmentId, status).then(res => {
|
||||||
this.HospitalPersonlist = res.rows
|
this.HospitalPersonlist = [...this.HospitalPersonlist, ...res.rows]
|
||||||
this.HospitalPersontotal = res.total
|
this.HospitalPersontotal = res.total
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
@ -159,17 +159,12 @@
|
|||||||
onReachBottom() { //下滑加载
|
onReachBottom() { //下滑加载
|
||||||
if (this.HospitalPersonlist.length >= this.HospitalPersontotal) {} else {
|
if (this.HospitalPersonlist.length >= this.HospitalPersontotal) {} else {
|
||||||
this.pageNum++
|
this.pageNum++
|
||||||
getHeathHousingList(this.pageNum, this.pageSize).then(res => {
|
this.selectHospitalPersonInfo();
|
||||||
if (res.rows) {
|
|
||||||
res.rows.forEach(e => {
|
|
||||||
this.HospitalPersonlist.push(e)
|
|
||||||
})
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onPullDownRefresh() { //下拉刷新
|
onPullDownRefresh() { //下拉刷新
|
||||||
this.pageNum = 1;
|
this.pageNum = 1;
|
||||||
|
this.HospitalPersonlist = []
|
||||||
this.selectHospitalPersonInfo();
|
this.selectHospitalPersonInfo();
|
||||||
setTimeout(function() {
|
setTimeout(function() {
|
||||||
uni.stopPullDownRefresh();
|
uni.stopPullDownRefresh();
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user