Просмотр исходного кода

Merge remote-tracking branch 'origin/master'

yuang 4 лет назад
Родитель
Сommit
6fc3de483d

+ 2 - 2
app/Http/Controllers/HandInStorageController.php

@@ -217,8 +217,8 @@ class HandInStorageController extends Controller
         $checkData=$request->input('checkData')[0];
 
         //九干仓禁止使用当前app上架
-        $res=$this->screenWarehouseAndContrast($checkData['customerid']);
-        if ($res)$this->error('禁止使用当前app上架,请换用新版app上架!');
+//        $res=$this->screenWarehouseAndContrast($checkData['customerid']);
+//        if ($res)$this->error('禁止使用当前app上架,请换用新版app上架!');
 
         /** @var HandInStorageService $handInStorageService  */
         $handInStorageService=app('HandInStorageService');

+ 1 - 1
app/Http/Controllers/WorkOrderProcessLogController.php

@@ -106,7 +106,7 @@ class WorkOrderProcessLogController extends Controller
 
     public function batchStoreApi(Request $request): array
     {
-        if (Gate::denies('订单管理-工单处理-宝时编辑') ||
+        if (Gate::denies('订单管理-工单处理-宝时编辑') &&
             Gate::denies('订单管理-工单处理-承运商编辑')) {
             return ['success' => false, 'message' => '没有对应的权限'];
         }

+ 6 - 2
resources/views/rejected/search/general.blade.php

@@ -149,8 +149,7 @@
                                         </div>
                                     </div>
                                     <div class="col-1 border border-1">
-                                        <div align="center" @mouseleave="removeCommonImg('common_img_'+item.id)"
-                                             @mouseenter="commonImg('img_'+item.id,item.upload_files)">
+                                        <div align="center" @mouseleave="removeCommonImg('common_img_'+item.id)" @mouseenter="commonImg('img_'+item.id,item.upload_files)">
                                             <div :id="'img_'+item.id">
                                                 <img v-for="uploadFile in item.upload_files"
                                                      :src="imgPrefix+uploadFile.url+'-thumbnail.'+uploadFile.type">
@@ -333,6 +332,11 @@
                     condition: data
                 });
                 this.form.init();
+                setTimeout(()=>{
+                    if (this.form.isRender()){
+                        this.getTotal();
+                    }
+                }, 300);
                 let column = [
                     {name: 'index', value: '序号', neglect: true},
                     {name: 'checked_numbers', value: '是否审核',},

+ 26 - 3
resources/views/store/receivingDashboard/punctualityProgress/index.blade.php

@@ -74,12 +74,17 @@
                 <td class="td-warm text-muted"><span>@{{ item.putawayAmount }}</span></td>
                 <td class="td-warm text-muted"><span>@{{ item.receiveConsumeDuration }}</span></td>
                 <td class="td-warm text-muted"><span>@{{ item.putawayConsumeDuration }}</span></td>
-                <td class="td-warm text-muted">
+                <td class="td-warm text-muted text-center">
                     <button @click="showDetail(item.receiveTaskNo,item.reservationNo,item.asnNo,item.createSingleTime)" type="button"
                             class="btn btn-primary" data-toggle="modal"
                             data-target="#staticBackdrop">
                         查看明细
                     </button>
+                    @can('入库管理-实时收货看板-删除')
+                        <button @click="deleteTask(item.receiveTaskNo)" type="button" class="btn btn-danger float-right">
+                            删除
+                        </button>
+                    @endcan
                 </td>
             </tr>
         </table>
@@ -218,7 +223,7 @@
                     {name: 'putawayAmount', value: '已上架总数', neglect: true},
                     {name: 'receiveConsumeDuration', value: ' 收货总耗时(分)', neglect: true},
                     {name: 'putawayConsumeDuration', value: '上架总耗时(分)', neglect: true},
-
+                    {name: 'make', value: '操作', neglect: true,class:'text-center'},
                 ];
                 new Header({
                     el: "table",
@@ -329,7 +334,25 @@
                             this.resData.itemDetail = res.data.data;
                         }
                     });
-                }
+                },
+                deleteTask(receiveTaskNo) {
+                    if(!confirm('确定要删除收获任务号单号为:“'+receiveTaskNo+'”的开单任务吗?')){return};
+                    let url = this.getBaseUrl() + `/api/receiveBoard/deleteTask?receiveTaskNo=${receiveTaskNo}`
+                    axios.get(url).then(res => {
+                        if (res.data.code !== 200 || !res.data.data) {
+                            window.tempTip.setDuration(2000);
+                            window.tempTip.show("删除开单任务失败!");
+                        } else {
+                            window.tempTip.setDuration(2000);
+                            window.tempTip.showSuccess("删除开单任务成功!");
+                            for (let i = this.resData.details.data.length - 1; i >= 0; i--) {
+                                if (this.resData.details.data[i].receiveTaskNo === receiveTaskNo) {
+                                    this.resData.details.data.splice(i, 1);
+                                }
+                            }
+                        }
+                    });
+                },
 
             },
 

+ 28 - 4
resources/views/store/receivingDashboard/receivingTableList/index.blade.php

@@ -80,13 +80,18 @@
                         查看明细
                     </button>
                 </td>
-                <td class="td-warm text-muted">
+                <td class="td-warm text-muted text-center">
                     @can('入库管理-实时收货看板-关单')
                     <button v-if="item.asnStatus!=99" @click="closeAsn(item)" type="button"
                             class="btn btn-success">
                         关单
                     </button>
                     @endcan
+                    @can('入库管理-实时收货看板-删除')
+                    <button @click="deleteTask(item.receiveTaskNo)" type="button" class="btn btn-danger float-right">
+                            删除
+                    </button>
+                    @endcan
                 </td>
             </tr>
         </table>
@@ -247,9 +252,7 @@
                     {name: 'unfinishedReceiveAmount', value: '未收数', neglect: true},
                     {name: 'receiveConsumeDuration', value: '收货耗时', neglect: true},
                     {name: 'action', value: '查看明细', neglect: true},
-                    @can('入库管理-实时收货看板-关单')
-                    {name: 'closeAsn', value: '关单', neglect: true},
-                    @endcan
+                    {name: 'make', value: '操作', neglect: true,class:'text-center'},
                 ];
                 new Header({
                     el: "table",
@@ -368,6 +371,7 @@
 
                 },
                 getCloseAsnParam(item){
+                    this.closeAsnParam.receiveTaskNo=item.receiveTaskNo;
                     this.closeAsnParam.asnType=item.asnType;
                     this.closeAsnParam.customerId=item.customerCode;
                     this.closeAsnParam.asnNo=item.asnNo;
@@ -384,6 +388,7 @@
                     return Object.assign({}, this.closeAsnParam);
                 },
                 cleanCloseAsnParam(){
+                    this.closeAsnParam.receiveTaskNo=null;
                     this.closeAsnParam.asnNo=null;
                     this.closeAsnParam.asnType=null;
                     this.closeAsnParam.customerId=null;
@@ -428,6 +433,25 @@
                         }
                     });
                 },
+                deleteTask(receiveTaskNo) {
+                    if(!confirm('确定要删除收获任务号单号为:“'+receiveTaskNo+'”的开单任务吗?')){return};
+                    let url = this.getBaseUrl() + `/api/receiveBoard/deleteTask?receiveTaskNo=${receiveTaskNo}`
+                    axios.get(url).then(res => {
+                        if (res.data.code !== 200 || !res.data.data) {
+                            window.tempTip.setDuration(2000);
+                            window.tempTip.show("删除开单任务失败!");
+                        } else {
+                            window.tempTip.setDuration(2000);
+                            window.tempTip.showSuccess("删除开单任务成功!");
+                            for (let i = this.resData.details.data.length - 1; i >= 0; i--) {
+                                if (this.resData.details.data[i].receiveTaskNo === receiveTaskNo) {
+                                    this.resData.details.data.splice(i, 1);
+                                }
+                            }
+                            this.cleanCloseAsnParam();
+                        }
+                    });
+                },
 
             },