体检-首页

This commit is contained in:
binbin_pan 2024-09-02 15:08:09 +08:00
parent dbbb7c1269
commit 3a48134bc4
21 changed files with 262 additions and 39 deletions

View File

@ -35,6 +35,8 @@ module.exports = {
// 上传文件地址
uploadUrl: 'http://192.168.0.14:19999/exam-file/file/uploadBase64',
bmwUrl: 'http://192.168.0.14:19999/exam-bmw',
// 体检-基础路径
tjBaseUrl: 'http://192.168.0.14:20000/AppPeaManager',
// 应用信息
appInfo: {
// 应用名称

View File

@ -5,7 +5,7 @@
"pages": [
// pageshttps://uniapp.dcloud.io/collocation/pages
// {
// "path": "pages/YNEduApp/index/index",
// "path": "pages/YNEduApp/index/index",
// "style": {
// "navigationStyle" : "custom"
// }
@ -199,11 +199,34 @@
}
},
{
"path" : "pages/HealthExaminationApp/index/index",
"style" :
{
"navigationStyle": "custom"
}
"path": "pages/HealthExaminationApp/index/index",
"style": {
"navigationStyle": "custom"
}
},
{
"path": "pages/HealthExaminationApp/appointment/appointment",
"style": {
"navigationBarTitleText": "体检预约"
}
},
{
"path": "pages/HealthExaminationApp/report/report",
"style": {
"navigationBarTitleText": "提交报告"
}
},
{
"path": "pages/HealthExaminationApp/myAppointment/myAppointment",
"style": {
"navigationBarTitleText": "我的预约"
}
},
{
"path": "pages/HealthExaminationApp/jobAppointment/jobAppointment",
"style": {
"navigationBarTitleText": "职业预约"
}
}
],
"globalStyle": {

View File

@ -0,0 +1,19 @@
<template>
<view>
体检预约
</view>
</template>
<script>
export default {
data() {
return {
};
}
}
</script>
<style lang="scss" scoped>
</style>

View File

@ -0,0 +1,117 @@
<template>
<view>
<!-- <u-navbar title="首页" placeholder @leftClick="leftClick" /> -->
<div v-if="isShow">
<div class="top-swiper">
<div class="swiper">
<u-swiper :list="swiperList" indicator indicatorMode="dot" height="170" />
</div>
</div>
<div class="title">体检服务</div>
<div class="opt-list">
<div class="opt-item" v-for="(item, index) in optList" :key="index" @click="handlePage(item.url)">
<div class="item">
<u--image :showLoading="true" :src="item.src" width="70px" height="60px" />
<div class="name">{{ item.name }}</div>
</div>
</div>
</div>
</div>
<div v-else>
<div class="top-swiper">个人中心</div>
</div>
<!-- 底部导航 -->
<u-tabbar :value="selectValue" @change="changeTab" fixed placeholder safeAreaInsetBottom activeColor="#1989fa">
<u-tabbar-item text="首页" :icon="homeIcon"></u-tabbar-item>
<u-tabbar-item text="我的" :icon="myIcon"></u-tabbar-item>
</u-tabbar>
</view>
</template>
<script>
export default {
data() {
return {
isShow: true,
selectValue: 0,
homeIcon: '/static/images-tijian/home-selected.png',
myIcon: '/static/images-tijian/my-unselected.png',
swiperList: [
'/static/images-tijian/swiper-1.png',
'/static/images-tijian/swiper-2.png',
'/static/images-tijian/swiper-3.png'
],
optList: [
{ name: '体检预约', src: '/static/images-tijian/preOrder.png', url: 'appointment' },
{ name: '体检报告', src: '/static/images-tijian/report.png', url: 'report' },
{ name: '我的预约', src: '/static/images-tijian/myPreOrder.png', url: 'myAppointment' },
{ name: '职业预约', src: '/static/images-tijian/careerExam.png', url: 'jobAppointment' }
]
}
},
methods: {
changeTab(e) {
console.log('🚀 ~ changeTab ~ e:', e)
this.selectValue = e
this.homeIcon = e === 0 ? '/static/images-tijian/home-selected.png' : '/static/images-tijian/home-unselected.png'
this.myIcon = e === 1 ? '/static/images-tijian/my-selected.png' : '/static/images-tijian/my-unselected.png'
this.isShow = !this.isShow
},
//
handlePage(url) {
uni.navigateTo({
url: `/pages/HealthExaminationApp/${url}/${url}`
})
}
}
}
</script>
<style lang="scss" scoped>
.top-swiper {
height: 300px;
padding: 10px;
background: url('/static/images-tijian/home-bg.png') no-repeat;
background-size: 100% 100%;
.swiper {
margin-top: 130px;
}
}
.title {
margin: 20px 10px;
font-size: 20px;
font-weight: bold;
color: #333;
}
.opt-list {
margin: 0 10px;
padding: 10px;
background: #fff;
border-radius: 5px;
display: flex;
justify-content: space-between;
flex-wrap: wrap;
.opt-item {
width: 30%;
margin: 10px 0;
.item {
display: flex;
flex-direction: column;
align-items: center;
.name {
margin-top: 5px;
font-size: 14px;
color: #333;
}
}
}
}
</style>

View File

@ -0,0 +1,19 @@
<template>
<view>
职业预约
</view>
</template>
<script>
export default {
data() {
return {
};
}
}
</script>
<style lang="scss" scoped>
</style>

View File

@ -0,0 +1,19 @@
<template>
<view>
我的预约
</view>
</template>
<script>
export default {
data() {
return {
};
}
}
</script>
<style lang="scss" scoped>
</style>

View File

@ -0,0 +1,19 @@
<template>
<view>
提交报告
</view>
</template>
<script>
export default {
data() {
return {
};
}
}
</script>
<style lang="scss" scoped>
</style>

View File

@ -15,7 +15,7 @@
<div class="name-status">
<div class="status">{{ item.alreadyNum > 0 ? '已练习' : '未练习' }}</div>
</div>
<div class="time">练习时长 {{ item.practiceDuration }}</div>
<div class="time">练习时长 {{ item.practiceDuration || 0 }}分钟</div>
<div class="count-total">
<div class="count">{{ item.totalNum || 0 }}, 已练习{{ item.alreadyNum || 0 }}</div>
</div>

View File

@ -196,6 +196,11 @@
username: uni.getStorageSync('userPhone'),
jwtToken: uni.getStorageSync('App-Token')
}
const tjparams = {
username: '14755181965',
password: 'YNsbd@123456'
}
console.log('🚀 ~ gotoYy ~ tjparams:', tjparams)
if (name == '考试培训移动端') {
uni.request({
url: config.login + '/login',
@ -235,38 +240,38 @@
}
})
} else if( name == '健康体检移动端') {
// uni.request({
// url: config.login + '/login',
// method: 'POST',
// data: JSON.stringify(params),
// header: {
// 'Content-Type': 'application/json'
// },
// success: res => {
// console.log(res)
// let req = res.data
// console.log('🚀 ~ getUserInfo ~ req:', req)
// if (req.code == 200) {
// setTimeout(() => {
// uni.reLaunch({
// url: '/pages/HealthExaminationApp/index/index'
// })
// }, 500)
// } else {
// uni.showToast({
// title: req.msg,
// icon: 'none'
// })
// }
// },
// fail: err => {
// console.log('🚀 ~ gotoYy ~ err:', err)
// uni.showToast({
// title: err.msg,
// icon: 'none'
// })
// }
// })
uni.request({
url: config.tjBaseUrl + '/login',
method: 'POST',
data: tjparams,
header: {
'Content-Type': 'application/x-www-form-urlencoded'
},
success: res => {
console.log(res)
let req = res.data
console.log('🚀 ~ getUserInfo ~ req:', req)
if (req.code == 200) {
// setTimeout(() => {
// uni.reLaunch({
// url: '/pages/HealthExaminationApp/index/index'
// })
// }, 500)
} else {
uni.showToast({
title: req.message,
icon: 'none'
})
}
},
fail: err => {
console.log('🚀 ~ gotoYy ~ err:', err)
uni.showToast({
title: err.message,
icon: 'none'
})
}
})
setTimeout(() => {
uni.reLaunch({
url: '/pages/HealthExaminationApp/index/index'

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 207 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 257 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 301 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 294 KiB