| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596 |
- @extends('layouts.app')
- @section('title')运单发货@endsection
- @section('content')
- <div class="container-fluid d-none" id="container">
- <div class="mt-3 col-8 offset-2">
- <div class="form-group row">
- <label for="waybill">运单号</label>
- <input id="waybill" type="text" class="form-control" v-model="info.waybill" @keydown.enter="enterVal($event)"></input>
- </div>
- <div class="form-group row">
- <label for="logistic">物流单号</label>
- <input id="logistic" type="text" class="form-control form-control-sm" v-model="info.waybill" @keydown.enter="enterVal($event)"></input>
- </div>
- <div class="form-group row">
- <label for="phone">查件电话</label>
- <input id="phone" type="text" class="form-control form-control-sm" v-model="info.waybill" @keydown.enter="enterVal($event)"></input>
- </div>
- <div class="form-group row">
- <label for="amount">数量</label>
- <div class="input-group input-group-sm">
- <input id="amount" type="text" class="form-control" v-model="info.waybill" @keydown.enter="enterVal($event)"></input>
- <div class="input-group-append">
- <span class="input-group-text">件</span>
- </div>
- </div>
- </div>
- <div class="form-group row">
- <label for="weight">重量</label>
- <div class="input-group input-group-sm">
- <input id="weight" type="text" class="form-control" v-model="info.waybill" @keydown.enter="enterVal($event)"></input>
- <div class="input-group-append">
- <span class="input-group-text">KG</span>
- </div>
- </div>
- </div>
- <div class="form-group row">
- <label for="volume">体积</label>
- <div class="input-group input-group-sm">
- <input id="volume" type="text" class="form-control" v-model="info.waybill" @keydown.enter="enterVal($event)"></input>
- <div class="input-group-append">
- <span class="input-group-text">M³</span>
- </div>
- </div>
- </div>
- <div class="input-group row">
- <button type="submit" id="submit" class="btn btn-success offset-2 col-10" @click="executeSubmit()">提交调配信息</button>
- </div>
- </div>
- </div>
- @stop
- @section('lastScript')
- <script type="text/javascript">
- new Vue({
- el:"#container",
- data:{
- isAndroid:false,
- info:{},
- element:["waybill","logistic"],
- counter:0,
- },
- mounted(){
- if (navigator.userAgent.indexOf("Android")!==-1)this.isAndroid = true;
- this.pageInit();
- $("#container").removeClass("d-none");
- let element = document.getElementById("waybill");
- if (element)element.focus();
- },
- methods:{
- //页面初始化
- pageInit(){
- if (!this.isAndroid)return;
- let element = document.getElementById("navbarSupportedContent").parentElement;
- element.className = "row";
- element.children[0].className += " col-5";
- element.children[0].href = "#";
- element.innerHTML = element.children[0].outerHTML;
- let e1 = document.getElementById("menu");
- let e2 = document.getElementById("demand-div");
- if (e1)e1.remove();
- if (e2)e2.remove();
- document.getElementById("container").style.height = (window.innerHeight-100)+"px";
- },
- //回车向下TAB
- enterVal(e){
- let index = this.element.indexOf(e.target.id)+1;
- let element = document.getElementById(this.element[index]);
- if (element)element.focus();
- e.preventDefault();
- return false;
- },
- },
- });
- </script>
- @stop
|