Browse Source

底部导航栏修改;增加扫码页面等

htc 3 months ago
parent
commit
acf80bdd2f
5 changed files with 170 additions and 7 deletions
  1. 4 4
      components/CusTabbar/index.vue
  2. 11 0
      pages.json
  3. 149 0
      pagesCode/index.vue
  4. 4 0
      pagesHome/index.vue
  5. 2 3
      pagesInspection/index.vue

+ 4 - 4
components/CusTabbar/index.vue

@@ -23,10 +23,10 @@
 						path: '/pagesHome/index'
 					},
 					{
-						inactiveImg: this.$imgBase+'icon_xunjian_grey.png',
-						activeImg: this.$imgBase+'icon_xunjian_blue.png',
-						text: '智能巡检',
-						path: '/pagesInspection/index'
+						inactiveImg: this.$imgBase+'icon_code_grey.png',
+						activeImg: this.$imgBase+'icon_code_blue.png',
+						text: '扫码',
+						path: '/pagesCode/index'
 					},
 					{
 						inactiveImg: this.$imgBase+'icon_storage_grey.png',

+ 11 - 0
pages.json

@@ -115,6 +115,17 @@
 				}
 			]
 		},
+		{
+			"root": "pagesCode",
+			"pages": [
+				{
+					"path": "index",
+					"style": {
+						"navigationStyle": "custom"
+					}
+				}
+			]
+		},
 		{
 			"root": "pagesStorage",
 			"pages": [

+ 149 - 0
pagesCode/index.vue

@@ -0,0 +1,149 @@
+<template>
+	<view class="tabPage" :style="{'min-height':h+'px', 'padding-top':mt+'px'}">
+		<cus-header title='扫码' :showback="false" bgColor='transparent'></cus-header>
+		<image class="topbg" :src="imgBase+'/img_code_bg.png'" mode="widthFix"></image>
+		<view class="content" :style="{'height':'calc(100vh - '+(mt+84)+'px)'}">
+			<view class="box">
+				<view class="title">请选择您的操作</view>
+				<view class="tip">产品入库or 出库</view>
+				<view class="cards">
+					<view class="card" @tap="toTurn('/pagesStorage/inStorage/add')">
+						<view class="left">
+							<image :src="imgBase+'/img_code_rk.png'"></image>
+							<view class="info">
+								<view class="ititle">扫码入库</view>
+								<view class="itip">新增入库,扫描产品二维码入库</view>
+							</view>
+						</view>
+						<view class="right">
+							<image :src="imgBase+'/img_arrow_right.png'"></image>
+						</view>
+					</view>
+					<view class="card" @tap="toTurn('/pagesStorage/outStorage/add')">
+						<view class="left">
+							<image :src="imgBase+'/img_code_ck.png'"></image>
+							<view class="info">
+								<view class="ititle">扫码出库</view>
+								<view class="itip">新增出库,扫描产品二维码出库</view>
+							</view>
+						</view>
+						<view class="right">
+							<image :src="imgBase+'/img_arrow_right.png'"></image>
+						</view>
+					</view>
+				</view>
+			</view>
+		</view>
+		<Tabbar :tabbarIndex="1"></Tabbar>
+	</view>
+</template>
+
+<script>
+	import Tabbar from '@/components/CusTabbar/index.vue'
+	export default {
+		components:{
+			Tabbar
+		},
+		data(){
+			return {
+				imgBase:this.$imgBase
+			}
+		},
+		methods:{
+			toTurn(url){
+				uni.navigateTo({ url })
+			}
+		}
+	}
+</script>
+
+<style scoped lang="less">
+	.tabPage{
+		width: 100%;
+		padding: 0 24rpx 168rpx;
+		box-sizing: border-box;
+		background: #E8F6FC;
+		
+		.topbg{
+			width: 100%;
+			position: fixed;
+			top: 0;
+			left: 0;
+			z-index: 0;
+		}
+	
+		.content{
+			width: 100%;
+			padding: 0 50rpx;
+			box-sizing: border-box;
+			position: relative;
+			display: flex;
+			align-items: center;
+			justify-content: center;
+			.box{
+				width: 100%;
+				.title{
+					font-family: PingFang-SC, PingFang-SC;
+					font-weight: bold;
+					font-size: 48rpx;
+					color: #1D2129;
+					line-height: 48rpx;
+				}
+				.tip{
+					font-family: PingFangSC, PingFang SC;
+					font-weight: 400;
+					font-size: 30rpx;
+					color: #86909C;
+					line-height: 30rpx;
+					margin-top: 30rpx;
+				}
+				.cards{
+					margin-top: 60rpx;
+					.card{
+						width: 100%;
+						padding: 60rpx 36rpx;
+						background: #FFFFFF;
+						box-sizing: border-box;
+						border-radius: 32rpx;
+						display: flex;
+						align-items: center;
+						justify-content: space-between;
+						margin-top: 40rpx;
+						.left{
+							display: flex;
+							align-items: center;
+							&>image{
+								width: 80rpx;
+								height: 80rpx;
+							}
+							.info{
+								padding-left: 36rpx;
+								.ititle{
+									font-family: PingFang-SC, PingFang-SC;
+									font-weight: bold;
+									font-size: 36rpx;
+									color: #1D2129;
+									line-height: 50rpx;
+								}
+								.itip{
+									font-family: PingFangSC, PingFang SC;
+									font-weight: 400;
+									font-size: 26rpx;
+									color: #86909C;
+									line-height: 36rpx;
+									margin-top: 18rpx;
+								}
+							}
+						}
+						.right{
+							image{
+								width: 36rpx;
+								height: 36rpx;
+							}
+						}
+					}
+				}
+			}
+		}
+	}
+</style>

+ 4 - 0
pagesHome/index.vue

@@ -55,6 +55,10 @@
 				<image :src="imgBase+'home/home_icon_yggl.png'"></image>
 				<text>员工管理</text>
 			</div>
+			<div class="box" @tap="tuTurn('/pagesInspection/index')">
+				<image :src="imgBase+'/img_home_znxj.png'"></image>
+				<text>智能巡检</text>
+			</div>
 		</div>
 		<Tabbar :tabbarIndex="0"></Tabbar>
 	</view>

+ 2 - 3
pagesInspection/index.vue

@@ -1,6 +1,6 @@
 <template>
 	<view class="tabPage" :style="{'min-height':h+'px', 'padding-top':mt+'px'}">
-		<cus-header title='智能巡检' :showback='false' bgColor='transparent'></cus-header>
+		<cus-header title='智能巡检' bgColor='transparent'></cus-header>
 		<image class="topbg" :src="imgBase+'inspection/inspection_top_bg.png'" mode="widthFix"></image>
 		<div class="top">
 			<div class="box" @tap="toTurn('/pagesInspection/onlineRepair/index')">
@@ -62,7 +62,6 @@
 				</div>
 			</div>
 		</div>
-		<Tabbar :tabbarIndex="1"></Tabbar>
 	</view>
 </template>
 
@@ -101,7 +100,7 @@
 <style scoped lang="less">
 	.tabPage{
 		width: 100%;
-		padding: 0 24rpx 188rpx;
+		padding: 0 24rpx 20rpx;
 		box-sizing: border-box;
 		background: #F4F8FB;