新增关闭功能

This commit is contained in:
jia 2023-11-01 15:04:54 +08:00
parent 15b4ef5766
commit 7165b72777
5 changed files with 1930 additions and 3 deletions

View File

@ -0,0 +1,92 @@
<template>
<view class="contentgb">
<view class="return_top">
<view class="z-bootm-img1" @click="returnbom()">
<image src="@/static/icon/fb1.png" mode="aspectFit"></image>
</view>
<view class="z-bootm-l"></view>
<view class="z-bootm-img2" @click="returnbom()">
<image src="@/static/icon/fb2.png" mode="aspectFit"></image>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
}
},
methods: {
returnbom() {
uni.sendHostEvent('closeApp', (ret) => {
//
console.log('关闭应用' + JSON.stringify(ret));
});
}
}
}
</script>
<style lang="scss" scoped>
.contentgb {
width: 166rpx;
height: 56rpx;
.return_top {
width: 166rpx;
height: 56rpx;
background: rgba(255, 255, 255, 0.6);
border-radius: 44rpx 44rpx;
position: relative;
.z-bootm-img1 {
width: 41rpx;
height: 13rpx;
position: absolute;
top: 20rpx;
left: 25rpx;
image {
width: 100%;
height: 100%;
}
}
.z-bootm-l {
width: 1px;
height: 32rpx;
background: rgba(0, 0, 0, 0.2);
margin: auto 0;
position: absolute;
top: 10rpx;
left: 85rpx;
}
.z-bootm-img2 {
width: 38rpx;
height: 34rpx;
margin-top: -15rpx;
margin-left: -15rpx;
position: absolute;
right: 25rpx;
top: 25rpx;
image {
width: 100%;
height: 100%;
}
}
}
}
</style>

View File

@ -5,9 +5,10 @@
<view class="conten-top">
<view class="" style="position: absolute;left: 30rpx;"><i class="iconfont icon-xiangzuo"
style="font-size: 40rpx;text-align: left;"></i></view>
<view class="" style="font-size: 30rpx;">
<view class="" style="font-size: 30rpx;margin-top: 10rpx;">
养殖咨询
</view>
<returntop class="container-retun"/>
</view>
<view style="padding-top:var(--status-bar-height);padding-bottom: 30rpx; margin-bottom: 30rpx;"></view>
@ -251,7 +252,7 @@
import BingMath from "@/components/bing-math/bing-math.vue"
import qiqbshare from "@/components/qiqb-share/qiqb-share.vue"
import returntop from '@/components/content-top/index.vue'
const recorderManager = uni.getRecorderManager()
const innerAudioContext = uni.createInnerAudioContext()
export default {
@ -259,7 +260,7 @@
'bing-math': BingMath,
'qiqbshare': qiqbshare,
returntop
},
data() {
return {
@ -1606,7 +1607,15 @@
top: 0;
position: fixed;
z-index: 10;
.container-retun{
position: absolute;
right: 20rpx;
padding-top: var(--status-bar-height);
top: 0;
}
}
.popup_box {

1826
pages/index/index1.vue Normal file

File diff suppressed because it is too large Load Diff

BIN
static/icon/fb1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 446 B

BIN
static/icon/fb2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB