|
|
@@ -30,8 +30,29 @@
|
|
|
color="#000000" fontSize="25rpx"></u-notice-bar>
|
|
|
</view>
|
|
|
</view>
|
|
|
- <view class="">
|
|
|
-
|
|
|
+ <view class="main">
|
|
|
+ <view class="main-item" v-for="(item,index) in list" @click="navTo(item)">
|
|
|
+ <view class="main-bg">
|
|
|
+ <image :src="item.bg" mode=""></image>
|
|
|
+ </view>
|
|
|
+ <view class="main-info" v-if="item.num">
|
|
|
+ <view class="main-info-bg">
|
|
|
+ <image src="../../static/img/infoBg.png" mode=""></image>
|
|
|
+ </view>
|
|
|
+ <view class="main-info-name">
|
|
|
+ {{item.num}}条未读
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ <view class="main-icon">
|
|
|
+ <image :src="item.icon" mode="heightFix"></image>
|
|
|
+ </view>
|
|
|
+ <view class="main-name">
|
|
|
+ {{item.name}}
|
|
|
+ </view>
|
|
|
+ <view class="main-tip">
|
|
|
+ {{item.tip}}
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
</view>
|
|
|
</template>
|
|
|
@@ -51,97 +72,126 @@
|
|
|
list: [{
|
|
|
icon: '../../static/icon/u1.png',
|
|
|
name: '领单',
|
|
|
- tip: '领取新订单'
|
|
|
+ tip: '领取新订单',
|
|
|
+ bg: '../../static/img/user-item1.png'
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u2.png',
|
|
|
name: '待检验订单',
|
|
|
- tip: '检验 | 添加记录'
|
|
|
+ tip: '检验 | 添加记录',
|
|
|
+ bg: '../../static/img/user-item2.png'
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u3.png',
|
|
|
name: '外发检验订单',
|
|
|
- tip: '订单外发处理'
|
|
|
+ tip: '订单外发处理',
|
|
|
+ bg: '../../static/img/user-item1.png'
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u4.png',
|
|
|
name: '我的订单',
|
|
|
- tip: '订单列表 | 提交记录'
|
|
|
+ tip: '订单列表 | 提交记录',
|
|
|
+ bg: '../../static/img/user-item2.png'
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u5.png',
|
|
|
name: '工资记录',
|
|
|
- tip: '历月工资详情'
|
|
|
+ tip: '历月工资详情',
|
|
|
+ bg: '../../static/img/user-item1.png'
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u6.png',
|
|
|
name: '打卡记录',
|
|
|
- tip: '上班 | 迟到记录'
|
|
|
+ tip: '上班 | 迟到记录',
|
|
|
+ bg: '../../static/img/user-item2.png',
|
|
|
+ src: '/pages/user/dkdetail'
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u7.png',
|
|
|
name: '奖罚记录',
|
|
|
- tip: '奖励 | 处罚记录'
|
|
|
+ tip: '奖励 | 处罚记录',
|
|
|
+ bg: '../../static/img/user-item2.png'
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u8.png',
|
|
|
name: '订单监管',
|
|
|
- tip: '订单详情'
|
|
|
+ tip: '订单详情',
|
|
|
+ bg: '../../static/img/user-item2.png'
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u9.png',
|
|
|
name: '待处理办件',
|
|
|
- tip: '处罚 | 报废返工处理'
|
|
|
+ tip: '处罚 | 报废返工处理',
|
|
|
+ bg: '../../static/img/user-item1.png',
|
|
|
+ num: 2
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u10.png',
|
|
|
name: '外发不合格处理',
|
|
|
- tip: '订单外发处理'
|
|
|
+ tip: '订单外发处理',
|
|
|
+ bg: '../../static/img/user-item2.png',
|
|
|
+ num: 2
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u11.png',
|
|
|
name: '处罚管理',
|
|
|
- tip: '奖励 | 处罚记录'
|
|
|
+ tip: '奖励 | 处罚记录',
|
|
|
+ bg: '../../static/img/user-item1.png',
|
|
|
+ num: 2
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u12.png',
|
|
|
name: '报废返工处理',
|
|
|
- tip: '提交报废返工的数量'
|
|
|
+ tip: '提交报废返工的数量',
|
|
|
+ bg: '../../static/img/user-item1.png',
|
|
|
+ num: 2
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u13.png',
|
|
|
name: '外发订单管理',
|
|
|
- tip: '提交检验 | 检验记录'
|
|
|
+ tip: '提交检验 | 检验记录',
|
|
|
+ bg: '../../static/img/user-item2.png'
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u14.png',
|
|
|
name: '外发不合格通知',
|
|
|
- tip: '外发不合格消息'
|
|
|
+ tip: '外发不合格消息',
|
|
|
+ bg: '../../static/img/user-item2.png',
|
|
|
+ num: 2
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u15.png',
|
|
|
name: '订单状态预警',
|
|
|
- tip: '订单到期时间预警'
|
|
|
+ tip: '订单到期时间预警',
|
|
|
+ bg: '../../static/img/user-item1.png',
|
|
|
+ num: 2
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u16.png',
|
|
|
name: '材料未到通知',
|
|
|
- tip: '材料未到预警'
|
|
|
+ tip: '材料未到预警',
|
|
|
+ bg: '../../static/img/user-item1.png',
|
|
|
+ num: 2
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u17.png',
|
|
|
name: '外发未到通知',
|
|
|
- tip: '外发时间到期预警'
|
|
|
+ tip: '外发时间到期预警',
|
|
|
+ bg: '../../static/img/user-item2.png',
|
|
|
+ num: 2
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u18.png',
|
|
|
name: '订单外发',
|
|
|
- tip: '订单外发给合作公司'
|
|
|
+ tip: '订单外发给合作公司',
|
|
|
+ bg: '../../static/img/user-item2.png',
|
|
|
+ num: 2
|
|
|
},
|
|
|
{
|
|
|
- icon: '../../static/icon/u1.png',
|
|
|
+ icon: '../../static/icon/u19.png',
|
|
|
name: '订单抽检',
|
|
|
- tip: '订单抽取检验'
|
|
|
+ tip: '订单抽取检验',
|
|
|
+ bg: '../../static/img/user-item1.png'
|
|
|
},
|
|
|
]
|
|
|
};
|
|
|
@@ -150,36 +200,21 @@
|
|
|
...mapState('user', ['hasLogin']),
|
|
|
},
|
|
|
onShow() {
|
|
|
- uni.setTabBarStyle({
|
|
|
- backgroundColor: '#FFFFFF'
|
|
|
- })
|
|
|
// 判断是否已经登录
|
|
|
// this.loadBaseData();
|
|
|
- // 判断是否用户页面
|
|
|
- if (this.isUserPage && this.hasLogin) {
|
|
|
- this.$nextTick(() => {
|
|
|
- this.$refs.userPage.getUser();
|
|
|
- })
|
|
|
- } else if (this.hasLogin) {
|
|
|
- this.$nextTick(() => {
|
|
|
- this.$refs.shopPage.getInit();
|
|
|
- })
|
|
|
- }
|
|
|
},
|
|
|
methods: {
|
|
|
toJSON() {
|
|
|
return this;
|
|
|
},
|
|
|
...mapMutations('user', ['setUserInfo', 'setOrderInfo']),
|
|
|
- changeTab(bool) {
|
|
|
- if (bool) {
|
|
|
- this.$refs.shopPage.getInit();
|
|
|
- }
|
|
|
- if (!bool) {
|
|
|
- this.$refs.userPage.getUser();
|
|
|
+ navTo(item) {
|
|
|
+ if (item.src) {
|
|
|
+ console.log(111);
|
|
|
+ uni.navigateTo({
|
|
|
+ url: item.src
|
|
|
+ })
|
|
|
}
|
|
|
- // 判断 是否切换为商家
|
|
|
- this.isUserPage = !bool;
|
|
|
},
|
|
|
// 加载初始数据
|
|
|
loadBaseData() {
|
|
|
@@ -318,4 +353,91 @@
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
+ .main {
|
|
|
+ padding: 50rpx 10rpx;
|
|
|
+ display: flex;
|
|
|
+ flex-wrap: wrap;
|
|
|
+
|
|
|
+ .main-item {
|
|
|
+ padding: 26rpx 36rpx 34rpx;
|
|
|
+ width: 46%;
|
|
|
+ height: 220rpx;
|
|
|
+ box-shadow: 0px 7rpx 20rpx 0px rgba(50, 50, 52, 0.09);
|
|
|
+ border-radius: 15rpx;
|
|
|
+ margin: 0 10rpx 30rpx;
|
|
|
+ position: relative;
|
|
|
+ line-height: 1;
|
|
|
+
|
|
|
+ image {
|
|
|
+ width: 100%;
|
|
|
+ height: 100%;
|
|
|
+ }
|
|
|
+
|
|
|
+ .main-bg {
|
|
|
+ position: absolute;
|
|
|
+ top: 0;
|
|
|
+ left: 0;
|
|
|
+ right: 0;
|
|
|
+ width: 100%;
|
|
|
+ height: 220rpx;
|
|
|
+ }
|
|
|
+
|
|
|
+ .main-info {
|
|
|
+ position: absolute;
|
|
|
+ z-index: 3;
|
|
|
+ right: 0;
|
|
|
+ top: 0;
|
|
|
+ width: 120rpx;
|
|
|
+ height: 38rpx;
|
|
|
+ display: flex;
|
|
|
+ justify-content: center;
|
|
|
+ align-items: center;
|
|
|
+
|
|
|
+ .main-info-bg {
|
|
|
+ position: absolute;
|
|
|
+ left: 0;
|
|
|
+ right: 0;
|
|
|
+ top: 0;
|
|
|
+ width: 120rpx;
|
|
|
+ height: 38rpx;
|
|
|
+ }
|
|
|
+
|
|
|
+ .main-info-name {
|
|
|
+ position: relative;
|
|
|
+ z-index: 4;
|
|
|
+ font-size: 22rpx;
|
|
|
+ font-family: PingFang SC;
|
|
|
+ font-weight: 500;
|
|
|
+ color: #FFFFFF;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .main-icon {
|
|
|
+ position: relative;
|
|
|
+ z-index: 2;
|
|
|
+ height: 50rpx;
|
|
|
+ }
|
|
|
+
|
|
|
+ .main-name {
|
|
|
+ position: relative;
|
|
|
+ z-index: 2;
|
|
|
+ margin-top: 26rpx;
|
|
|
+ font-size: 36rpx;
|
|
|
+ font-family: PingFang SC;
|
|
|
+ font-weight: bold;
|
|
|
+ color: #3F3F3F;
|
|
|
+ }
|
|
|
+
|
|
|
+ .main-tip {
|
|
|
+ font-size: 24rpx;
|
|
|
+ font-family: PingFang SC;
|
|
|
+ font-weight: 500;
|
|
|
+ color: #8C8C8C;
|
|
|
+ position: relative;
|
|
|
+ z-index: 2;
|
|
|
+ margin-top: 14rpx;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
</style>
|