Files
klp-mono/apps/hand-factory/pages/index.vue

80 lines
1.2 KiB
Vue
Raw Normal View History

2025-10-27 13:21:43 +08:00
<template>
<div></div>
2025-10-27 13:21:43 +08:00
</template>
<script>
2025-10-29 11:17:50 +08:00
export default {
data() {
return {
hasJumped: false,
}
},
onShow() {
if (this.hasJumped) return;
this.$store.dispatch('GetInfo')
.then(() => {
uni.switchTab({
url: '/pages/scan/scan',
success: () => {
this.hasJumped = true;
},
fail: (err) => {
console.error('跳转失败:', err);
}
});
})
.catch(() => {
uni.reLaunch({ url: '/pages/login' })
});
2025-10-29 11:17:50 +08:00
}
}
</script>
<style scoped lang="scss">
/* 样式保持不变 */
2025-10-29 11:17:50 +08:00
.production-page {
min-height: 100vh;
background: #f6f6f6;
}
.page-header {
display: flex;
align-items: center;
justify-content: center;
padding: 40rpx 30rpx 20rpx;
background: #fff;
border-bottom: 1rpx solid #e8e8e8;
.header-title {
font-size: 28rpx;
font-weight: 500;
color: #333;
letter-spacing: 2rpx;
padding: 0 30rpx;
}
.header-line {
height: 2rpx;
background: linear-gradient(90deg, transparent, #ddd, transparent);
flex: 1;
max-width: 100rpx;
&.line-left {
background: linear-gradient(90deg, transparent, #ddd);
}
&.line-right {
background: linear-gradient(90deg, #ddd, transparent);
2025-10-27 13:21:43 +08:00
}
}
2025-10-29 11:17:50 +08:00
}
.line-header {
background: #fff;
}
.content-wrapper {
2025-10-29 15:38:20 +08:00
padding: 0;
2025-10-29 11:17:50 +08:00
}
</style>