<template>
<view><!-- address -->
<view class="title">
<span>当前定位城市</span>
<uni-icons type="location" size="20px" color="#559DF1"></uni-icons>
<span style="color: #559DF1;">{{add}}</span>
</view>
<view class="content">
<view>
<p>热门地区</p>
</view>
<view class="add">
<ul>
<li v-for="(item, i) in list.slice(0,9)" :key="i" @click="getadd(i)">
{{item.simpleName}}
</li>
</ul>
</view>
</view>
<view style="margin-top: 30px;">
<view>
<p>所有地区</p>
</view>
<view class="">
<ul style="list-style: none; padding: 0;">
<li style="height: 30px;border-bottom: 1px solid #eee;" v-for="(item, i) in list" :key="i" @click="getadd(i)">
{{item.simpleName}}
</li>
</ul>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
list:[],
add:'北京',
}
},
methods: {
getadd(i){
uni.showModal({
title:"是否更换城市" + this.list[i].simpleName,
success: (res) => {
if(res.confirm){
this.add = this.list[i].simpleName
}
}
})
}
},
onLoad(){
uni.request({
url:"http://127.0.0.1:5502/system/region/list?level=1",
success: (res) => {
this.list = res.data.rows
console.log(this.list)
}
})
}
}
</script>
<style>
page{
padding: 20px;
padding-right: 50px;
background-color: #fff;
}
.title{
display: flex;
}
.content{
margin-top: 25px;
}
.content ul{
margin-top: 10px;
height: 120px;
list-style: none;
display: flex;
flex-wrap: wrap;
justify-content: space-between;
align-content: space-between;
padding: 0;
}
.content ul li{
flex: 0 31%;
height: 35px;
line-height: 2.5;
background-color: #f2f2f2;
text-align: center;
border-radius: 5px;
}
</style>
<template>
<view><!-- in -->
asd
</view>
</template>
<script>
export default {
data() {
return {
}
},
methods: {
},
onLoad() {
uni.request({
url:"http://127.0.0.1:5502/store/list",
success: (res) => {
console.log(res)
}
})
}
}
</script>
<style>
</style>
<template>
<view><!-- details -->
<view>
<h3>机构简介</h3>
<view style="margin-top: 10px;">
{{obj.storeDesc}}
</view>
</view>
<view style="margin-top: 50px;">
<h3>服务</h3>
<view style="margin-top: 10px;" v-for="(obj, i) in list" :key="i" @click="gotoIn()">
<uni-card>
{{obj.storeName}}
</uni-card>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
obj:[],
list:[]
}
},
methods: {
gotoIn(){
uni.navigateTo({
url:"/pages/index/detail/in/in"
})
}
},
onLoad: function(option) {
this.obj = JSON.parse(option.obj)
console.log(this.obj)
},
mounted() {
uni.request({
url:"http://127.0.0.1:5502/system/store/list",
success: (res) => {
this.list = res.data.rows
console.log(this.list)
}
})
}
}
</script>
<style>
page{
padding: 20px;
}
</style>
<template>
<view class="">
<!-- family -->
<view class="box">
<image src="../../../static/u39.svg" mode=""class="tp"></image>
<view class="box_name">
<view class="user_name">1111</view>
<view class="user_age">女 30岁</view>
</view>
<view class="box_btn">
<button type="warn">本人</button>
<button type="default">已签约</button>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
}
},
methods: {
}
}
</script>
<style>
.box{
display: flex;
padding: 20px;
width: 100%;
height: 180px;
border-radius: 20px;
background-color:palegoldenrod;
color: white;
justify-content: space-between;
}
.box image{
width: 80px;
height: 80px;
}
.box_name{
display: flex;
flex-direction: column;
}
.box_name .user_name{
margin-top: 25px;
font-size: 25px;
}
.box_name .user_age{
margin-top: 5px;
}
.box_btn{
display: flex;
}
.box_btn button{
height: 25px;
width: 55px;
font-size: 12px;
}
</style>
<template>
<view><!-- healthmsg -->
<p>评论</p>
<ul>
<li v-for="(item, i) in content" :key="i">
{{item.content}}
</li>
</ul>
</view>
</template>
<script>
export default {
data() {
return {
content:[]
}
},
methods: {
},
onLoad() {
uni.request({
url:"http://127.0.0.1:5502/system/newscomment/list?newsId=13",
success: (res) => {
this.content = res.data.rows
}
})
}
}
</script>
<style>
page{
padding: 20px;
}
ul{
list-style: none;
}
li{
height: 30px;
border-bottom:1px solid #cecece;
}
</style>
<template>
<view class="">
<uni-card title="已完成" extra="2021/01/01">
<view class="card">
<view class="card_1" @click="fufei">老人日间照料</view>
<view class="card_2">巴拉巴拉养老社区</view>
</view>
</uni-card>
<uni-card title="已完成" extra="2021/01/01">
<view class="card">
<view class="card_1" @click="fufei">老人日间照料</view>
<view class="card_2">巴拉巴拉养老社区</view>
</view>
</uni-card>
<uni-card title="已完成" extra="2021/01/01">
<view class="card">
<view class="card_1" @click="fufei">老人日间照料</view>
<view class="card_2">巴拉巴拉养老社区</view>
</view>
</uni-card>
<uni-card title="已完成" extra="2021/01/01">
<view class="card">
<view class="card_1" @click="fufei">老人日间照料</view>
<view class="card_2">巴拉巴拉养老社区</view>
</view>
</uni-card>
<uni-card title="已完成" extra="2021/01/01">
<view class="card">
<view class="card_1" @click="fufei">老人日间照料</view>
<view class="card_2">巴拉巴拉养老社区</view>
</view>
</uni-card>
</view>
</template>
<script>
export default {
data() {
return {
}
},
methods: {
fufei(){
uni.navigateTo({
url:'/pages/index/fufei/fufei'
})
}
}
}
</script>
<style>
.card{
display: flex;
flex-direction: column;
}
.card_1{
color: black;
font-size: 20px;
}
.card_2{
color: darkgray;
}
</style>
<template>
<view>
<view class="search">
<u-input style="padding-left: 35px;background-color: #fff;" type="text" border=""
placeholder="搜索养老机构/服务" @click="gotoSearch()" />
<uni-icons class="icon_search" type="search" size="20" color="#559DF1"></uni-icons>
<span style="margin-top: 8px;margin-left: 8px;" @click="goback()">取消</span>
</view>
<view style="margin-bottom: 10px;" v-for="(obj, i) in list" :key="i" @click="gotoDetail(obj)">
<uni-card :is-full="true" class="box">
<image :src="obj.storeLogo" style="width: 50px;height: 80px;" mode=""></image>
<text>
{{obj.storeName}}
</text>
</uni-card>
</view>
</view>
</template>
<script>
export default {
data() {
return {
list:[]
}
},
methods: {
goback(){
uni.navigateBack()
},
gotoDetail(obj){
uni.navigateTo({
url:"/pages/index/detail/detail?obj=" + JSON.stringify(obj)
})
}
},
mounted(){
uni.request({
url:"http://127.0.0.1:5502/system/store/list",
success: (res) => {
this.list = res.data.rows
console.log(this.list)
}
})
}
}
</script>
<style>
page{
padding: 20px;
}
.search {
margin-top: 20px;
position: relative;
display: flex;
}
.search .icon_search {
position: absolute;
top: 7px;
left: 8px;
}
.box{
display: flex;
}
</style>
{
"easycom": {
"^u-(.*)": "@/uview-ui/components/u-$1/u-$1.vue"
},
"pages": [{
"path": "pages/login/login",
"style": {
"navigationBarTitleText": "",
"navigationBarBackgroundColor": "#fff"
}
}, {
"path": "pages/login/forget",
"style": {
"navigationBarTitleText": "忘记密码",
"navigationBarBackgroundColor": "#fff"
}
}, {
"path": "pages/reg/reg",
"style": {
"navigationBarTitleText": "",
"navigationBarBackgroundColor": "#fff",
"enablePullDownRefresh": false
}
}, {
"path": "pages/index/index",
"style": {
"navigationBarTitleText": "",
"navigationBarBackgroundColor": "#fff",
"enablePullDownRefresh": false
}
} ,{
"path" : "pages/index/health",
"style" :
{
"navigationBarTitleText": "",
"enablePullDownRefresh": true,
"onReachBottomDistance": 10
}
}
,{
"path" : "pages/index/survey",
"style" :
{
"navigationBarTitleText": "",
"enablePullDownRefresh": false
}
}
,{
"path" : "pages/index/user",
"style" :
{
"navigationBarTitleText": "",
"enablePullDownRefresh": false
}
}
,{
"path" : "pages/index/healthmsg/healthmsg",
"style" :
{
"navigationBarTitleText": "咨询详情",
"enablePullDownRefresh": false
}
}
,{
"path" : "pages/index/address/address",
"style" :
{
"navigationBarTitleText": "选择地区",
"enablePullDownRefresh": false
}
}
,{
"path" : "pages/index/search/search",
"style" :
{
"navigationBarTitleText": "",
"enablePullDownRefresh": false,
"app-plus": {
"titleNView": false
}
}
}
,{
"path" : "pages/index/detail/detail",
"style" :
{
"navigationBarTitleText": "机构主页",
"enablePullDownRefresh": false
}
}
,{
"path" : "pages/index/detail/in/in",
"style" :
{
"navigationBarTitleText": "",
"enablePullDownRefresh": false
}
}
,{
"path" : "pages/index/my/my",
"style" :
{
"navigationBarTitleText": "",
"enablePullDownRefresh": false
}
}
,{
"path" : "pages/index/jtcy/jtcy",
"style" :
{
"navigationBarTitleText": "",
"enablePullDownRefresh": false
}
}
,{
"path" : "pages/index/family/family",
"style" :
{
"navigationBarTitleText": "",
"enablePullDownRefresh": false
}
}
],
"globalStyle": {
"navigationBarTextStyle": "black",
"navigationBarTitleText": "uni-app",
"navigationBarBackgroundColor": "#F8F8F8",
"backgroundColor": "#F8F8F8",
"app-plus": {
"background": "#efeff4"
}
},
"tabBar": {
"list": [
{
"iconPath": "static/c1.png",
"text": "首页",
"pagePath": "pages/index/index"
},
{
"iconPath": "static/c2.png",
"text": "健康资讯",
"pagePath": "pages/index/health"
},
{
"iconPath": "static/c3.png",
"text": "健康监测",
"pagePath": "pages/index/survey"
},
{
"iconPath": "static/c4.png",
"text": "我的",
"pagePath": "pages/index/user"
}
]
}
}