update
parent
71e1342728
commit
bc9febdb00
|
|
@ -0,0 +1,64 @@
|
||||||
|
<template>
|
||||||
|
<view class="h-full relative px-24rpx bg-#fff">
|
||||||
|
<view class="fixed top-0 left-0 right-0 px-24rpx bg-#fff">
|
||||||
|
<u-search
|
||||||
|
v-model="searchVal"
|
||||||
|
@change="$u.debounce(handleChange, 1000)"
|
||||||
|
@search="$u.debounce(handleChange, 300)"
|
||||||
|
shape="square"
|
||||||
|
margin="20rpx 0rpx 30rpx 0rpx"
|
||||||
|
height="80rpx"
|
||||||
|
searchIconSize="48rpx"
|
||||||
|
:showAction="false"
|
||||||
|
:searchIcon="$assets('/sou.png')"
|
||||||
|
placeholderColor="#666"
|
||||||
|
placeholder="搜索您需要陪诊的医院"
|
||||||
|
clearabled
|
||||||
|
focus
|
||||||
|
/>
|
||||||
|
</view>
|
||||||
|
<view class="pt-130rpx pb-80rpx">
|
||||||
|
<view
|
||||||
|
v-for="item in dataList"
|
||||||
|
:key="item.id"
|
||||||
|
class="flex items-center justify-between px-30rpx py-20rpx text-#000 border-border-black border-b border-solid"
|
||||||
|
@click="
|
||||||
|
$Router.push({
|
||||||
|
path: '/form',
|
||||||
|
query: { hospitaId: item.id, hospitaName: item.name }
|
||||||
|
})
|
||||||
|
"
|
||||||
|
>
|
||||||
|
<view class="">
|
||||||
|
{{ item.name }}
|
||||||
|
</view>
|
||||||
|
<view
|
||||||
|
class="text-white bg-#FF8CA6 rounded-24rpx px-30rpx py-10rpx text-center hover:shadow-md"
|
||||||
|
>
|
||||||
|
选择
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
<script setup>
|
||||||
|
const instance = getCurrentInstance()
|
||||||
|
const { $api } = instance.proxy
|
||||||
|
const searchVal = ref('')
|
||||||
|
const dataList = ref([])
|
||||||
|
|
||||||
|
const handleChange = async () => {
|
||||||
|
const { list = [] } = await $api.fetchPzHospitalList({
|
||||||
|
name: searchVal.value.trim()
|
||||||
|
})
|
||||||
|
dataList.value = list
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
:deep {
|
||||||
|
.u-search__content {
|
||||||
|
border-radius: 16rpx !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
Loading…
Reference in New Issue