|
|
@@ -8,7 +8,7 @@
|
|
|
</span>
|
|
|
<div class="container-fluid" id="container">
|
|
|
<div class="row">
|
|
|
- <div class="card offset-md-3 col-md-6 col-sm-12">
|
|
|
+ <div class="card offset-md-1 col-md-5 col-sm-12">
|
|
|
<div class="card-body">
|
|
|
<div class="form-group text-center font-weight-bold h4">
|
|
|
入库信息
|
|
|
@@ -46,6 +46,41 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
+ <div class="card col-md-5 col-sm-12">
|
|
|
+ <div class="card-body">
|
|
|
+ <div class="mt-1 text-center">
|
|
|
+ <button class="btn btn-primary" @click="submitBox()">为选中格口手动补充料箱</button>
|
|
|
+ </div>
|
|
|
+ <div class="mt-2 h-75">
|
|
|
+ <table class="table table-sm table-bordered border-dark w-100 h-100 text-center" style="cursor: pointer">
|
|
|
+ <tr>
|
|
|
+ <th :class="[shelfOccupy['HAIB1-03-03'] ? 'bg-danger' : 'bg-success',selectedBox['HAIB1-03-03'] ? 'box-shadow-dark' : '']"
|
|
|
+ @click="fillingBox('HAIB1-03-03')">HAIB1-03-03</th>
|
|
|
+ <th :class="[shelfOccupy['HAIB1-02-03'] ? 'bg-danger' : 'bg-success',selectedBox['HAIB1-02-03'] ? 'box-shadow-dark' : '']"
|
|
|
+ @click="fillingBox('HAIB1-02-03')">HAIB1-02-03</th>
|
|
|
+ <th :class="[shelfOccupy['HAIB1-01-03'] ? 'bg-danger' : 'bg-success',selectedBox['HAIB1-01-03'] ? 'box-shadow-dark' : '']"
|
|
|
+ @click="fillingBox('HAIB1-01-03')">HAIB1-01-03</th>
|
|
|
+ </tr>
|
|
|
+ <tr>
|
|
|
+ <th :class="[shelfOccupy['HAIB1-03-02'] ? 'bg-danger' : 'bg-success',selectedBox['HAIB1-03-02'] ? 'box-shadow-dark' : '']"
|
|
|
+ @click="fillingBox('HAIB1-03-02')">HAIB1-03-02</th>
|
|
|
+ <th :class="[shelfOccupy['HAIB1-02-02'] ? 'bg-danger' : 'bg-success',selectedBox['HAIB1-02-02'] ? 'box-shadow-dark' : '']"
|
|
|
+ @click="fillingBox('HAIB1-02-02')">HAIB1-02-02</th>
|
|
|
+ <th :class="[shelfOccupy['HAIB1-01-02'] ? 'bg-danger' : 'bg-success',selectedBox['HAIB1-01-02'] ? 'box-shadow-dark' : '']"
|
|
|
+ @click="fillingBox('HAIB1-01-02')">HAIB1-01-02</th>
|
|
|
+ </tr>
|
|
|
+ <tr>
|
|
|
+ <th :class="[shelfOccupy['HAIB1-03-01'] ? 'bg-danger' : 'bg-success',selectedBox['HAIB1-03-01'] ? 'box-shadow-dark' : '']"
|
|
|
+ @click="fillingBox('HAIB1-03-01')">HAIB1-03-01</th>
|
|
|
+ <th :class="[shelfOccupy['HAIB1-02-01'] ? 'bg-danger' : 'bg-success',selectedBox['HAIB1-02-01'] ? 'box-shadow-dark' : '']"
|
|
|
+ @click="fillingBox('HAIB1-02-01')">HAIB1-02-01</th>
|
|
|
+ <th :class="[shelfOccupy['HAIB1-01-01'] ? 'bg-danger' : 'bg-success',selectedBox['HAIB1-01-01'] ? 'box-shadow-dark' : '']"
|
|
|
+ @click="fillingBox('HAIB1-01-01')">HAIB1-01-01</th>
|
|
|
+ </tr>
|
|
|
+ </table>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</div>
|
|
|
@stop
|
|
|
@@ -65,13 +100,40 @@
|
|
|
ide:"",
|
|
|
},
|
|
|
errors:{},
|
|
|
+ shelfOccupy:{},
|
|
|
+ selectedBox:{},
|
|
|
},
|
|
|
mounted(){
|
|
|
+ @foreach($storages as $storage)this.$set(this.shelfOccupy,"{{$storage->station->code}}",true);@endforeach
|
|
|
this.codeFocus();
|
|
|
this.globalClick();
|
|
|
this.createBefore();
|
|
|
},
|
|
|
methods:{
|
|
|
+ //选中填充料箱
|
|
|
+ fillingBox(ideCode){
|
|
|
+ this.$set(this.selectedBox,ideCode,this.selectedBox[ideCode] ? !this.selectedBox[ideCode] : true);
|
|
|
+ },
|
|
|
+ //提交填充料箱
|
|
|
+ submitBox(){
|
|
|
+ window.tempTip.setDuration(3000);
|
|
|
+ if (JSON.stringify(this.selectedBox)==='{}'){window.tempTip.show("未选中格口");return;}
|
|
|
+ window.tempTip.confirm("确定选中格口已无料箱存在?",()=>{
|
|
|
+ let boxes = [];
|
|
|
+ for (let key in this.selectedBox)boxes.push(key);
|
|
|
+ window.tempTip.postBasicRequest("{{url('store/inStorage/resetCacheShelf')}}",{boxes:boxes},res=>{
|
|
|
+ for (let i=0;i<res.boxes.length;i++){
|
|
|
+ this.$set(this.shelfOccupy,res.boxes[i],false);
|
|
|
+ this.$set(this.selectedBox,res.boxes[i],false);
|
|
|
+ }
|
|
|
+ if (res.data){
|
|
|
+ window.tempTip.show(res.data);
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ return "手动补充成功";
|
|
|
+ },true);
|
|
|
+ })
|
|
|
+ },
|
|
|
//聚焦 白名单
|
|
|
codeFocus(){
|
|
|
if (!this.permissionList.includes(document.activeElement.id)) document.getElementById("barCode").focus();
|