LD před 5 roky
rodič
revize
4672db040f

+ 1 - 0
app/Http/Controllers/StationController.php

@@ -59,6 +59,7 @@ class StationController extends Controller
             "currentStationTask.stationTaskCommodities.commodity.barcodes",
             "currentStationTask.stationTaskCommodities.materialBox",
             "currentStationTask.stationTaskBatches.batch",
+            "currentStationTask.stationTaskMaterialBoxes.materialBox",
             "stationTypeBinMonitor",
         ]);
         if (!$station['stationTypeBinMonitor']){

+ 1 - 1
laravel-echo-server.lock

@@ -1,3 +1,3 @@
 {
-	"process": 5544
+	"process": 6376
 }

+ 13 - 11
resources/views/station/monitor/show.blade.php

@@ -24,8 +24,10 @@
                             <div class="col py-3 h4">
                                 <div>波次号:</div>
                                 <div class=" text-center">
-                                    <b v-if="task&&task.stationTaskBatch">
-                                        @{{ task.stationTaskBatch.batch.code }}
+                                    <b v-if="task&&task.station_task_batches">
+                                        <div v-for="taskBatch in task.station_task_batches">
+                                            @{{ taskBatch.batch.code }}
+                                        </div>
                                     </b>
                                 </div>
                             </div>
@@ -38,10 +40,10 @@
                         <div class="row">
                             <div class="col py-3 h4">
                                 料箱号:
-                                <span v-if="task&&task.stationTaskMaterialBoxes">
-                                    <b v-for="taskMaterialBox in task.stationTaskMaterialBoxes">
+                                <span v-if="task&&task.station_task_material_boxes">
+                                    <b v-for="taskMaterialBox in task.station_task_material_boxes">
                                         <span v-if="taskMaterialBox.status==='处理中'">
-                                            @{{taskMaterialBox.materialBox.code}}
+                                            @{{taskMaterialBox.material_box.code}}
                                         </span>
                                     </b>
                                 </span>
@@ -55,12 +57,12 @@
                         </div>
                     </div>
                     <div class="col text-center">
-                        <div class="row" v-if="station&&station.stationTypeBinMonitor">
-                            <div class="col py-3 h4" v-for="(wall, wIndex) in station.stationTypeBinMonitor.bin_wall_amount">
+                        <div class="row" v-if="station&&station.station_type_bin_monitor">
+                            <div class="col py-3 h4" v-for="(wIndex) in station.station_type_bin_monitor.bin_wall_amount">
                                 <table class="table border">
-                                    <tr v-for="(row, rIndex) in station.stationTypeBinMonitor.bin_row_length">
+                                    <tr v-for="(rIndex) in station.station_type_bin_monitor.bin_row_length">
                                         <td class="border p-0"
-                                            v-for="(column, cIndex) in station.stationTypeBinMonitor.bin_column_length"
+                                            v-for="(cIndex) in station.station_type_bin_monitor.bin_column_length"
                                             :class="
                                                 task.currentCommodityIndex
                                                 && task.currentCommodityIndex!==-1
@@ -137,12 +139,12 @@
                 // color:"red",
                 error:"",
                 station:{!! $station??[] !!},
-        {{dd($station)}}
                 task:null, //指向station.stationTask的快捷方式
                 {{--stationTypeBinMonitor:{!! $stationTypeBinMonitor !!},--}}
             },
             mounted() {
-                this.task=this.station['stationTask']; //为快捷方式绑定指针
+                this.task=this.station['current_station_task']; //为快捷方式绑定指针
+                console.log(this.station,this.task)
                 this._makeMenuHiding();
                 this._listenBroadcast();
                 // this._renderingstationTypeBinMonitor(this.stationTypeBinMonitor.amount,this.stationTypeBinMonitor.row,this.stationTypeBinMonitor.column);