<template>
	<view class="" style="background-color:#fff;">
		<view class="uni-flex uni-row u-col-center" >
			库位 <uni-easyinput ref='scanInput' v-model="locationCode" :focus="inputFocus"
				@confirm="confirmLocation" suffixIcon="arrowdown" style='font-size: 18px;padding: 10rpx 20rpx;'
				placeholder="请输入库位" @iconClick="showLocationSelect" :disabled="locationDisabled">
			</uni-easyinput>
		</view>
		<view class="" >
			<u-select v-model="showLocation" mode="mutil-column-auto" :list="listLode" @confirm="confirmSelectLocation">
			</u-select>
		</view>
		
	</view>
</template>

<script>
	export default {
		components: {
		},
		data(){
			return {
				locationCode:"",
				inputFocus: false,
				showLocation: false,
				showPartCode: false
			}
		},
		props: {
			locationDisabled:{
				type: Boolean,
				default: false
			},
			listLode:{
				type: Object,
				default: []
			},
		},
		methods:{
			confirmLocation(){
				// this.showLocation =true
				
			},
			confirmSelectLocation(e) {
				this.locationCode = e[2].label
				this.$emit("confirm",this.locationCode)
			},
			
			showLocationSelect() {
				this.showLocation = true;
			},
		}
		
	}
</script>

<style>
</style>