当前位置:网站首页>Uni app ceiling fixed style
Uni app ceiling fixed style
2022-06-26 05:22:00 【Black and white】
<template>
<view class="full">
<view class="sticky-box">
<!-- Search for -->
<uni-search-bar class="unisearchbar" radius="5" placeholder=" Please enter search keywords " clearButton="auto" bgColor="#EEEEEE" cancelButton="none" @input="input" />
<!-- Search for -->
<view class="doctor">
<!-- All departments -->
<view class="doctor_l">
<view class="uni-list-cell-db">
<picker @change="bindPickerChange" :value="form.id" :range-key="'name'" :range="deptLists">
<text v-if="form.id" class="uni-input">{
{deptLists.find(item => item.id == form.id).name}}</text>
<text v-else style="color: #000;"> All departments </text>
<uni-icons type="bottom" size="15"></uni-icons>
</picker>
</view>
</view>
<!-- All professional titles -->
<view class="doctor_r">
<view class="uni-list-cell-db">
<picker @change="bindPickerChangeone" :value="form.infoCode" :range-key="'infoName'" :range="findByTypeCodeList">
<text v-if="form.infoCode" class="uni-input">{
{findByTypeCodeList.find(item => item.infoCode == form.infoCode).infoName}}</text>
<text v-else style="color: #000;"> All professional titles </text>
<uni-icons type="bottom" size="15"></uni-icons>
</picker>
</view>
</view>
</view>
</view>
<view>
<doctorList :doctorList="doctorList"></doctorList>
</view>
</view>
</template>
<script> import doctorList from '../../components/doctorList/index.vue' import {
tranfrom } from '@/utils/util.js' import {
selectUserList, selectDeptList } from '@/api/home' export default {
components: {
doctorList }, data() {
return {
// Select switch form: {
id: '', infoCode: '' }, // Initial value datesize: {
pageNum: 1, pageSize: 10, params: {
userName: "", deptId: "", ysZc: "" } }, deptLists: [], findByTypeCodeList: [], doctorList: [], }; }, watch: {
// All functions '$store.state.findByTypeCode'(newVal, oldVal) {
this.findByTypeCodeList = this.$store.state.findByTypeCode }, // All departments '$store.state.selectDeptList'(newVal, oldVal) {
this.deptLists = this.$store.state.selectDeptList } }, created() {
this.$store.commit('findByTypeCode') this.$store.commit('selectDeptList') this.fetchSwiperList(this.datesize) }, onPullDownRefresh() {
this.form.id = "" this.form.infoCode = "" this.datesize.pageSize = 10 this.fetchSwiperList(this.datesize) }, onReachBottom() {
this.datesize.pageSize = this.datesize.pageSize + 5 this.fetchSwiperList(this.datesize) }, methods: {
async fetchSwiperList(date) {
await selectUserList(date).then(res => {
res.data.rows.map(it => {
it.ysZc = tranfrom(this.findByTypeCodeList,it.ysZc) }) this.doctorList = res.data.rows }) }, input(res) {
this.fetchSwiperList({
"pageNum": 1, "pageSize": 9999, "params": {
"userName": res, "deptId": "", "ysZc": "" } }) }, // Select all departments bindPickerChange(e) {
this.form.id = this.deptLists[e.detail.value].id this.fetchSwiperList({
"pageNum": 1, "pageSize": 9999, "params": {
"userName": "", "deptId": this.form.id, "ysZc": "" } }) }, // Select all professional titles bindPickerChangeone(e) {
this.form.infoCode = this.findByTypeCodeList[e.detail.value].infoCode this.fetchSwiperList({
"pageNum": 1, "pageSize": 999, "params": {
"userName": "", "deptId": "", "ysZc": this.form.infoCode } }) }, } } </script>
<style lang="scss" scoped> .full {
width: 750upx; margin: 0; padding: 0; } .sticky-box {
/* #ifndef APP-PLUS-NVUE */ // display: flex; position: -webkit-sticky; /* #endif */ position: sticky; top: var(--window-top); z-index: 99; flex-direction: row; margin: 0px; // padding: 15px 0 15px 0; background-color: #F4F5F6; // border-bottom-style: solid; // border-bottom-color: #E2E2E2; } .unisearchbar {
width: 100%; } .doctor {
height: 100rpx; display: flex; justify-content: space-around; align-items: center; border-top: 1px solid #e1e1e1; border-bottom: 1px solid #e1e1e1; .doctor_l {
width: 50%; height: 100rpx; line-height: 100rpx; text-align: center; border-right: 1px solid #e1e1e1; } .doctor_r {
width: 50%; height: 100rpx; line-height: 100rpx; text-align: center; } } .textcenter {
text-align: center; font-size: 18px; } </style>

边栏推荐
- Could not get unknown property ‘*‘ for SigningConfig container of type org.gradle.api.internal
- 【PHP】PHP二维数组按照多个字段进行排序
- Data storage: the difference between MySQL InnoDB and MyISAM
- Ad tutorial series | 4 - creating an integration library file
- Introduction to GUI programming to game practice (II)
- 10 set
- 6.1 - 6.2 introduction to public key cryptography
- 【MYSQL】MySQL 百万级数据量分页查询方法及其优化
- Redis installation on Linux
- 《财富自由之路》读书之一点体会
猜你喜欢

Practical cases | getting started and mastering tkinter+pyinstaller

SOFA Weekly | 开源人—于雨、本周 QA、本周 Contributor

cartographer_backend_constraint

Happy New Year!

ECCV 2020 double champion team, take you to conquer target detection on the 7th

cartographer_fast_correlative_scan_matcher_2d分支定界粗匹配
![[unity3d] rigid body component](/img/57/344aae65e4ac6a7d44b235584f95d1.png)
[unity3d] rigid body component

【ARM】在NUC977上搭建基于boa的嵌入式web服务器

Yunqi lab recommends experience scenarios this week, free cloud learning

慢慢学JVM之缓存行和伪共享
随机推荐
apktool 工具使用文档
【PHP】PHP二维数组按照多个字段进行排序
skimage. morphology. medial_ axis
Why does the mobile IM based on TCP still need to keep the heartbeat alive?
Command line interface of alluxio
Yunqi lab recommends experience scenarios this week, free cloud learning
C# 39. string类型和byte[]类型相互转换(实测)
Technical past: tcp/ip protocol that has changed the world (precious pictures, caution for mobile phones)
Two step processing of string regular matching to get JSON list
【Unity3D】碰撞体组件Collider
[greedy college] recommended system engineer training plan
cartographer_optimization_problem_2d
慢慢学JVM之缓存行和伪共享
How to select the data transmission format of instant messaging application
data = self._ data_ queue. get(timeout=timeout)
Cookie and session Basics
PHP 2D / multidimensional arrays are sorted in ascending and descending order according to the specified key values
Codeforces Round #802 (Div. 2)(A-D)
Douban top250
两步处理字符串正则匹配得到JSON列表