Files
hht-oulun-uni/pages/home/home.vue

239 lines
9.2 KiB
Vue
Raw Normal View History

2025-06-18 10:48:40 +08:00
<template>
<view class="home_wraper">
<view class="zd_content">
<view class="header">首页</view>
<view class="userInfo-wrap">
<view class="userInfo">
<text v-if="userName !== ''" class="p1">{{userName}}</text>
<text class="p2">欢迎进入欧伦WMS手持系统</text>
</view>
<view class="exit" @tap="Quit">
<view class="icon-exit"></view>
<view class="exit-text">退出</view>
</view>
</view>
<view class="zd_home_wrapper">
<view class="menus_wrap">
<view class="fir_menu_wrap">
<view class="fir_menu-item" v-for="(e, i) in menuList" :key="i" @tap="toPage1(e)">
<image class="menu-img" :src="require('../../static/image/menu/' + e.path + '.png')" alt="">
<view class="menu-name">{{e.title}}</view>
</view>
</view>
</view>
</view>
</view>
<view class="sec_menu_wraper" :class="show ? 'popshow' : 'pophide'">
<view class="pop-title">{{title}}</view>
<view class="sec_menu_w">
<view class="sec_menu-item" :style="{'background-image': 'url(' + require('../../static/image/menu/' + icon + '.png') + ')'}" v-for="(e, i) in secM" :key="'sontree' + i" @click="toPage2(e)">
<view class="menu-name_inner">{{e.title}}</view>
</view>
</view>
</view>
<view v-if="show" class="modal" @click.stop="show = false"></view>
</view>
</template>
<script>
export default {
data() {
return {
userName: '',
menuList: [
2025-07-17 20:02:06 +08:00
{title: '预装管理', path: 'RF04', sonTree: [{title: '物料组盘', path: '/pages/entry/mater-group2'}, {title: '货架绑定', path: '/pages/outbound/shelf-bind'}]},
2025-07-22 17:11:47 +08:00
{title: '产线管理', path: 'RF07', sonTree: [{title: '产线叫料', path: '/pages/outbound/line-callmater'}, {title: '线边仓出库', path: '/pages/outbound/mater-outstore'}, {title: '产线转运', path: '/pages/outbound/line-transfer2'}]},
2025-07-08 18:33:15 +08:00
{title: '入库管理', path: 'RF01', sonTree: [{title: '物料组盘', path: '/pages/entry/mater-group'}, {title: '组盘入库', path: '/pages/entry/groupplate-instore'}, {title: '货架绑定', path: '/pages/outbound/shelf-bind'}, {title: '拣选余料回库', path: '/pages/entry/pick-yl-return-store'}, {title: '空载具入库', path: '/pages/entry/empty-vehicle-instore'}]},
2025-07-24 17:40:49 +08:00
{title: '出库管理', path: 'RF02', sonTree: [{title: '线边仓出库', path: '/pages/outbound/mater-outstore'}, {title: '产线叫料', path: '/pages/outbound/line-callmater'}, {title: '产线转运', path: '/pages/outbound/line-transfer'}, {title: '空载具出库', path: '/pages/outbound/empty-vehicle-outstore'}, {title: 'CTU载具出库', path: '/pages/outbound/ctu-vehicle-outstore'}, {title: '出库确认', path: '/pages/outbound/out-store-confirm'}]},
2025-07-17 14:16:23 +08:00
// {title: '入库管理', path: 'RF01', sonTree: [{title: '组盘入库', path: '/pages/entry/groupplate-instore'}, {title: '拣选余料回库', path: '/pages/entry/pick-yl-return-store'}, {title: '空载具入库', path: '/pages/entry/empty-vehicle-instore'}]},
// {title: '出库管理', path: 'RF02', sonTree: [{title: '产线转运', path: '/pages/outbound/line-transfer'}, {title: '空载具出库', path: '/pages/outbound/empty-vehicle-outstore'}, {title: 'CTU载具出库', path: '/pages/outbound/ctu-vehicle-outstore'}]}
2025-07-08 17:54:02 +08:00
// {title: '入库管理', path: 'RF01', sonTree: [{title: '物料组盘入库', path: '/pages/entry/mater-group-to-store'}, {title: '合格证入库', path: '/pages/entry/qualified-to-store'}, {title: '单据入库', path: '/pages/entry/bill-to-store'}, {title: '盘点入库', path: '/pages/entry/check-to-store'}, {title: '空托盘入库', path: '/pages/entry/empty-tray-to-store'}]},
// {title: '出库管理', path: 'RF02', sonTree: [{title: '空托盘出库', path: '/pages/outbound/tray-out-store'}, {title: '出库确认', path: '/pages/outbound/out-store-confirm'}, {title: '单据出库', path: '/pages/outbound/bill-list'}, {title: '盘点出库', path: '/pages/outbound/stock-out-store'}, {title: '物料出库', path: '/pages/outbound/mater-outstore'}, {title: '货架绑定', path: '/pages/outbound/shelf-bind'}, {title: '产线转运', path: '/pages/outbound/line-transfer'}, {title: '空载具出库', path: '/pages/outbound/empty-vehicle-outstore'}, {title: 'CTU载具出库', path: '/pages/outbound/ctu-vehicle-outstore'}]}
// {title: '拣选管理', path: 'RF04', sonTree: [{title: '拣选作业', path: '/pages/pick/pick-task'}]},
// {title: '设备操控', path: 'RF07', sonTree: [{title: '切换出入库模式', path: '/pages/mode/switch-in-out'}, {title: '拣选工位启停模式', path: '/pages/mode/pick'}, {title: '下发输送线运动命令', path: '/pages/mode/command'}]},
// {title: '产线叫料', path: 'RF10', sonTree: [{title: '二楼生产出库', path: '/pages/outbound/produce-out-store-2nd'}, {title: '二楼取货确认', path: '/pages/outbound/pick-confirm-2nd'}, {title: '二楼货架绑定', path: '/pages/outbound/shelf-bind-2nd'}]},
// {title: '转运管理', path: 'RF09', sonTree: [{title: '托盘转运', path: '/pages/transfer/tray-transfer'}]},
// {title: '叫料搬运', path: 'RF11', sonTree: [{title: '叫料搬运', path: '/pages/carry/call-carry'}]}
2025-06-18 10:48:40 +08:00
],
menu: [{title: '叫料搬运', path: 'RF11', sonTree: [{title: '叫料搬运', path: '/pages/carry/call-carry'}]}],
show: false,
secM: [],
icon: '',
title: '',
pwd: '1'
};
},
2025-07-17 14:16:23 +08:00
// onShow () {
// if (this.$store.getters.userInfo) {
// const info = JSON.parse(this.$store.getters.userInfo)
// this.userName = info.username
// if (info.pwd_reset_user_id === '0') {
// this.menuList = [...this.menu]
// }
2025-06-18 10:48:40 +08:00
2025-07-17 14:16:23 +08:00
// }
// },
2025-06-18 10:48:40 +08:00
methods: {
toPage1 (e) {
if (e.sonTree.length > 0) {
this.show = true
this.secM = e.sonTree
this.icon = e.path
this.title = e.title
}
},
toPage2 (e) {
let url = e.path + '?title=' + e.title
if (e.active === false) {
return
}
uni.redirectTo({
url: url
})
},
Quit () {
this.$store.dispatch('delUserInfo', '')
uni.redirectTo({
url: '/pages/login/login'
})
}
}
}
</script>
<style lang="stylus">
@import '../../common/style/mixin.styl';
.home_wraper
_wh(100%, 100%)
overflow hidden
.zd_content
padding 0 24rpx
height 100%
top 0
padding-top calc(var(--status-bar-height) + 86rpx)
// background linear-gradient(to bottom, #fae2ca 0%, #fff5ea 20%, #fdfdfd 100%)
background linear-gradient(to bottom, #f5f6fb 0%, #fff 100%)
.header
position fixed
left 0
top 0
padding-top var(--status-bar-height)
z-index 100
_wh(100%, calc(var(--status-bar-height) + 86rpx))
_font(36rpx,86rpx,#333,,center)
.userInfo-wrap
_fj()
_wh(100%,190rpx)
padding 0 30rpx
background-color $red
_bis('../../static/image/info_bg.png',auto,100%,right,bottom)
border-radius 12rpx
margin-bottom 24rpx
.userInfo
_fj(,flex-start,column)
.p1
_font(34rpx,1,#fff)
padding-bottom 18rpx
.p2
_font(26rpx,1,#fff)
.exit
_fj()
height 50rpx
padding 0 20rpx
border 1px solid #FF967C
border-radius 20rpx
.icon-exit
_wh(22rpx, 22rpx)
_bis('../../static/image/exit.png',22rpx)
.exit-text
_font(32rpx,50rpx,#fff,,right)
padding-left 10rpx
.zd_home_wrapper
_wh(100%, calc(100% - 238rpx))
margin-bottom 24rpx
background-color #fff
border-radius: 12rpx;
padding: 14rpx;
margin-bottom 24rpx
box-shadow: 0 4rpx 10rpx 4rpx rgba(0,0,0,.1)
overflow-y scroll
.menus_wrap
width 100%
.fir_menu_wrap
_fj(flex-start,flex-start,,wrap)
align-content: flex-start
.fir_menu-item
_fj()
flex-direction column
_wh(30%, auto)
margin-bottom 40rpx
_font(26rpx, 60rpx,#e74f1a,,center)
&:nth-child(3n+2)
margin-left 5%
margin-right 5%
::v-deep .menu-img
_wh(100%, auto)
img
position relative
opacity 1
_wh(55%, auto)
margin 0 auto 0.2rpx
.menu-name
_font(28rpx, 38rpx, #444,,center)
padding 0 20rpx
.sec_menu_wraper
position fixed
bottom 0
left 0
width 100%
background-color #f4f5f5
box-shadow 0 -8px 16px 0 rgba(28,31,33,.1)
border-top-left-radius 20rpx
border-top-right-radius 20rpx
z-index 2017
transition all .3s
.modal
position fixed
bottom 0
left 0
_wh(100%, 100%)
background-color rgba(0,0,0,0.8)
z-index 2010
.sec_menu_w
width calc(100% - 76rpx)
margin 30rpx auto 60rpx auto
_fj(flex-start)
flex-wrap wrap
.sec_menu-item
_wh(30%, 120rpx)
margin-bottom 20rpx
border-radius 10rpx
background-size 40% auto
background-position right 90%
background-repeat no-repeat
&:nth-child(3n+2)
margin-left 5%
margin-right 5%
&:nth-child(5n+1) .menu-name_inner
background linear-gradient(to right, rgba(73,102,255,0.8) 0%, rgba(117,142,255,0.8) 100%)
&:nth-child(5n+2) .menu-name_inner
background linear-gradient(to right, rgba(254, 168, 20,0.8) 0%, rgba(255, 177, 1,0.8) 100%)
&:nth-child(5n+3) .menu-name_inner
background linear-gradient(to right, rgba(0, 228, 153,0.8) 0%, rgba(0, 241, 197,0.8) 100%)
&:nth-child(5n+4) .menu-name_inner
background linear-gradient(to right, rgba(196, 5, 219,0.8) 0%, rgba(183,120,190,0.8) 100%)
&:nth-child(5n+5) .menu-name_inner
background linear-gradient(to right, rgba(146, 94, 52,0.8) 0%, rgba(162, 116, 79,0.8) 100%)
.menu-name_inner
_wh(100%, 100%)
_fj(center)
_font(28rpx, 30rpx, #fff, 700, center)
border-radius 10rpx
padding 10rpx
overflow hidden
.pop-title
margin 60rpx 38rpx 0 38rpx
_font(30rpx, 60rpx, #000,700,center)
</style>