This commit is contained in:
sjeam 2025-09-06 15:48:24 +08:00
parent 748dffc419
commit 711a4f65f0
16 changed files with 85 additions and 62 deletions

View File

@ -85,7 +85,7 @@ const onSubmit = async () => {
height: 100%;
display: flex;
bottom: 0;
z-index: 999;
z-index: 999 !important;
position: fixed;
inset: 0;

View File

@ -50,8 +50,8 @@ export const tabbarList = [
]
const _tabbar = {
color: '#2d2d2d',
selectedColor: '#ff0000',
color: '#333333',
selectedColor: '#87d76b',
backgroundColor: '#F8F8F8',
borderStyle: 'black',
height: '60px',

View File

@ -15,8 +15,8 @@
}
},
"tabBar": {
"color": "#2d2d2d",
"selectedColor": "#ff0000",
"color": "#333333",
"selectedColor": "#87d76b",
"backgroundColor": "#F8F8F8",
"borderStyle": "black",
"height": "60px",

View File

@ -19,7 +19,7 @@
style="backdrop-filter: blur(2rpx); border-radius: 10rpx"
>
<view class="p-4">
<view class="flex items-center leading-6" v-if="hasLogin">
<view class="flex items-center leading-6" v-if="islogin">
<image class="w-18 h-18 rounded-full" :src="userStore.userInfo?.avatar"></image>
<view class="ml-2 flex-content-column">
@ -70,18 +70,25 @@
icon: '/static/icons/my3.png',
color: 'blue',
},
// {
// name: '',
// url: '/pages/users/browsingHistory/index',
// type: 2,
// icon: '/static/icons/my4.png',
// color: 'blue',
// },
{
name: '浏览记录',
url: '/pages/users/browsingHistory/index',
name: '平台客服',
url: '17309090670',
type: 2,
icon: '/static/icons/my4.png',
color: 'blue',
},
{
name: '平台客服',
url: '17309090670',
type: 2,
name: '上传商品',
url: '/pages/my/uploadProduct',
type: 1,
icon: '/static/icons/my5.png',
color: 'red',
},
@ -92,19 +99,19 @@
icon: '/static/icons/my7.png',
color: 'red',
},
{
name: '上传商品',
url: '/pages/my/uploadProduct',
type: 1,
icon: '/static/icons/rural_ecommerce.png',
color: 'red',
},
// {
// name: '',
// url: '/pages/my/uploadProduct',
// type: 1,
// icon: '/static/icons/rural_ecommerce.png',
// color: 'red',
// },
]"
>
<wd-grid-item use-slot>
<view class="p-2">
<wd-img radius="20rpx" :width="'60rpx'" :height="'60rpx'" :src="item.icon" />
<view class="ps-2 pt-2 pb-2 text-center color-black font-size-3">
<view class="p-2 text-center color-black font-size-3">
{{ item.name }}
</view>
</view>
@ -118,48 +125,64 @@
</view>
</template>
<script lang="ts" setup name="WxLogin">
<script lang="ts" name="WxLogin">
import { useUserStore } from '@/store'
import { getUrl, getWebUrl } from '@/utils'
const show = ref(false)
const userStore = useUserStore()
console.log('获取用户信息', userStore.userInfo)
const hasLogin = computed(() => userStore.userInfo?.id)
const logout = () => {
uni.showModal({
title: '确认退出当前账号?',
success: (res) => {
if (res.confirm) {
userStore.logout()
import { getUrl, getWebUrl, getShopWebUrl, hasLogin } from '@/utils'
// const userStore = useUserStore()
import { defineComponent } from 'vue'
export default defineComponent({
data() {
return {
islogin: false,
show: false,
userStore: useUserStore(),
}
},
onLoad(option) {},
methods: {
// logout() {
// uni.showModal({
// title: '退',
// success: (res) => {
// if (res.confirm) {
// userStore.logout()
// }
// },
// })
// },
more(item) {
this.islogin = hasLogin()
if (this.islogin === false) {
this.show = true
return
}
if (this.islogin === true) {
// console.log(item)
if (item.type == 1) {
getUrl(item.url)
} else if (item.type == 2) {
getWebUrl(item.url)
} else if (item.type == 3) {
getShopWebUrl(item.url)
}
}
},
})
}
},
})
function more(item) {
// if (!hasLogin.value) {
// show.value = true
// return
// }
if (item.name == '平台客服') {
uni.showModal({
title: '提示',
content: ' 确定拨打客服电话:' + 17309090670 + '吗?',
success: function (res) {
if (res.confirm) {
uni.makePhoneCall({
phoneNumber: 17309090670,
})
}
},
})
return
}
if (item.type == 1) {
getUrl(item.url)
} else if (item.type == 2) {
getWebUrl(item.url)
}
}
// const show = ref(false)
// const userStore = useUserStore()
// console.log('', userStore.userInfo)
// // const hasLogin = computed(() => userStore.userInfo?.id)
// const logout = () => {
// uni.showModal({
// title: '退',
// success: (res) => {
// if (res.confirm) {
// userStore.logout()
// }
// },
// })
// }
</script>

View File

@ -13,7 +13,7 @@
import { useUserStore } from '@/store'
import { http } from '@/utils/http'
import WxLogin from './components/wx-login.vue'
const userStore = useUserStore()
// const userStore = useUserStore()
// const hasLogin = computed(() => userStore.userInfo?.nickname)
// userStore.wxLogin()

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.3 KiB

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.2 KiB

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 3.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.5 KiB

After

Width:  |  Height:  |  Size: 3.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.7 KiB

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.5 KiB

After

Width:  |  Height:  |  Size: 3.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

After

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.0 KiB

After

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.3 KiB

View File

@ -48,11 +48,11 @@ page {
}
.color-black {
color: #333333ff !important;
color: #333333 !important;
}
.color-gary {
color: #999999ff !important;
color: #999999 !important;
}
.default-color {