<template>
	<view class="content">
		<!-- 自定义导航 -->
		<view class="navbar-box">
			<u-navbar title="物资出库详情" :safeAreaInsetTop="true" @leftClick="leftClick"></u-navbar>
		</view>
		<view class="wrap">
			
			<view class="title">物资出库</view>
			<u-card title="物资单号">
				<view class="" slot="body">
					<view class="u-body-item u-flex u-row-between u-p-t-0">
						<image src="https://img11.360buyimg.com/n7/jfs/t1/94448/29/2734/524808/5dd4cc16E990dfb6b/59c256f85a8c3757.jpg" mode="aspectFill"></image>
						<view class="u-body-item-title">
							<view class="u-m-b-10">医用消毒湿巾</view>
							<view class="">80抽</view>
						</view>
						<view class="">X500</view>
					</view>
				</view>
			</u-card>
			<view class="title">领取信息</view>
			<view class="getway u-m-b-24">
				<view class="getway-item">领取方式:库房派送</view>
				<view class="getway-item">派送地址:库房派送</view>
				<view class="getway-item">联系人:库房派送</view>
				<view class="getway-item">联系电话:库房派送</view>
			</view>
			<view class="title">出库信息核实</view>
			<view class="u-m-b-24">计划出库量:500</view>
			<view class="u-flex">
				<view class="u-m-r-20">实际出库量:500</view>
				<u-number-box v-model="value" @change="valChange"></u-number-box>
			</view>
			<view class="fixed-button">
				<u-button type="success" @click="submit">提交</u-button>
			</view>
			
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				value:2,
			}
		},
		onLoad() {

		},
		methods: {
			leftClick() {
			   let canNavBack = getCurrentPages();
			     if(canNavBack && canNavBack.length>1) {  
			       uni.navigateBack({  
			         delta: 1  
			       });  
			     } else {  
			       history.back();  
			     }
			},
			valChange(e) {
				console.log('valChange当前值为: ' + e.value)
			},
			submit(){
				this.$u.route({
					url: 'pages/succeed/succeed',
					params: {
						title: '出库完成'
					}
				})
			}
		}
	}
</script>

<style lang="scss" scoped>
.title{
	font-size: 30rpx;
	border-left: 2px solid;
	border-color: var(--main-color);
	padding-left: 10rpx;
	color: var(--main-color);
	font-weight: bold;
	margin-bottom: 24rpx;
}
.u-body-item image {
	width: 120rpx;
	height: 120rpx;
	border-radius: 8rpx;
	margin-right: 12rpx;
}
.getway{
	&-item{
		margin-bottom: 10rpx;
	}
}
</style>
