hldy_app_mini/pages/NursingNew/component/pleasetake/takehome.vue

66 lines
1.9 KiB
Vue
Raw Normal View History

2025-11-27 14:47:04 +08:00
<template>
2025-11-27 15:02:08 +08:00
<view class="index-content-other" :style="transition?{opacity: `1`}:{opacity: `0`}">
2025-11-27 14:47:04 +08:00
<view class="right-container-title-nav">
<text style="margin-left: 30rpx;">
NUID{{ uni.getStorageSync('nuId')}}
</text>
<text class="new-weight">
{{ uni.getStorageSync('nuName')}}
</text>
<view class="right-icons">
<image class="right-icons-img" src="/static/index/requestform/touxiang.png" />
2025-11-27 16:21:31 +08:00
<view>{{uni.getStorageSync('realname')}}</view>
2025-12-02 13:34:13 +08:00
<image class="right-icons-img-back" src="/static/index/requestform/back.png" v-if="hometype>0" @click="hometype=0" />
<view v-if="hometype>0" @click="hometype=0">返回</view>
2025-11-27 14:47:04 +08:00
</view>
</view>
2025-12-02 13:34:13 +08:00
<takehomep v-if="hometype==0" @changePageNumber="changehometype" ></takehomep>
2025-11-28 17:34:02 +08:00
<requestformView v-if="hometype==1" />
2025-11-27 14:47:04 +08:00
</view>
</template>
<script setup lang="ts">
2025-12-02 13:34:13 +08:00
import { ref, onMounted, onBeforeUnmount, computed, nextTick, watch, reactive } from 'vue';
2025-11-27 14:47:04 +08:00
import { onShow, onLoad, onHide, onPageScroll } from "@dcloudio/uni-app"
import { queryCgdList } from '@/pages/Warehouse/api/lunpan.js'
2025-11-27 16:21:31 +08:00
import requestformView from './component/requestform.vue'
2025-11-28 17:34:02 +08:00
import takehomep from './component/takehomep.vue'
const hometype = ref(0)
2025-11-27 14:47:04 +08:00
const transition = ref(false);
const props = defineProps({
isShow: {
type: Boolean,
required: true,
},
});
2025-11-27 15:02:08 +08:00
watch(
() => props.isShow,
(newVal, oldVal) => {
// 当旧值为false新值为true时延迟0.2秒调用方法
if (!oldVal && newVal) {
transition.value = false;
setTimeout(() => {
transition.value = true;
}, 50)
} else {
transition.value = false;
}
}
)
2025-12-02 13:34:13 +08:00
const changehometype = (index:number) => {
hometype.value = index
}
2025-11-27 14:47:04 +08:00
</script>
<style scoped lang="scss">
@import "./css/take.less";
2025-11-27 15:02:08 +08:00
.index-content-other {
width: calc(100% - 260rpx);
// background-color: red;
height: 100%;
transition: opacity 1s ease;
position: relative;
}
2025-11-27 14:47:04 +08:00
</style>