Bläddra i källkod

订定,修改“指定分配”字样

LD 5 år sedan
förälder
incheckning
31e6f8de47

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

@@ -12,14 +12,14 @@ class OrderCommodityAssignController extends Controller
 {
     public function index()
     {
-        if(!Gate::allows('商品配置-查询')){ return redirect(url('denied'));  }
+        if(!Gate::allows('指定分配-查询')){ return redirect(url('denied'));  }
         $assigns = app("OrderCommodityAssignService")->paginate();
         return view("order.index.index",compact("assigns"));
     }
 
     public function import(Request $request)
     {
-        if(!Gate::allows('商品配置-编辑')){ return ["success"=>false,"data"=>"无权操作!"];  }
+        if(!Gate::allows('指定分配-编辑')){ return ["success"=>false,"data"=>"无权操作!"];  }
         $fileSuffix=$request->file('file')->getClientOriginalExtension();
         if ($fileSuffix != 'xlsx' && $fileSuffix != 'xls' && $fileSuffix != 'csv')
             return ['success'=>false,'data'=>'不支持该文件类型'];

+ 3 - 3
database/migrations/2020_12_02_150054_create_order_commodity_assigns_table.php

@@ -8,9 +8,9 @@ class CreateOrderCommodityAssignsTable extends Migration
 {
 
     protected $authorities = [
-        "商品配置",
-        "商品配置-查询",
-        "商品配置-编辑",
+        "指定分配",
+        "指定分配-查询",
+        "指定分配-编辑",
     ];
     /**
      * Run the migrations.

+ 1 - 1
resources/views/order/index/_importModal.blade.php

@@ -14,7 +14,7 @@
                 <div class="mt-5 mb-5">
                     <input id="file" type="file" class="d-none" accept=".csv, .xlsx, .xls" @change="importAssign($event)"/>
                     <label class="w-100 text-center small"><b>表头示例:</b><label class="text-primary">订单编号  商品条码  数量  生产日期  失效日期</label></label>
-                    <label class="w-100 row d-block ml-1"><input type="button" class="btn btn-dark col-6 offset-3" value="导入商品配置" @click="selectFile()"></label>
+                    <label class="w-100 row d-block ml-1"><input type="button" class="btn btn-dark col-6 offset-3" value="导入指定分配" @click="selectFile()"></label>
                 </div>
             </div>
             <div class="modal-footer">

+ 2 - 2
resources/views/order/index/index.blade.php

@@ -1,5 +1,5 @@
 @extends('layouts.app')
-@section('title')订单管理-商品配置@endsection
+@section('title')订单管理-指定分配@endsection
 
 @section('content')
     @component('order.index.menu')@endcomponent
@@ -122,4 +122,4 @@
         },
     });
 </script>
-@endsection
+@endsection

+ 2 - 2
resources/views/order/index/menu.blade.php

@@ -8,9 +8,9 @@
                     <li class="nav-item">
                         <a class="nav-link" href="{{url('order/index/delivering')}}" :class="{active:isActive('delivering',3)}">查询</a>
                     </li> @endcan
-                @can('商品配置')
+                @can('指定分配')
                     <li class="nav-item">
-                        <a class="nav-link" href="{{url('order/index/commodityAssign')}}" :class="{active:isActive('commodityAssign',3)}">商品配置</a>
+                        <a class="nav-link" href="{{url('order/index/commodityAssign')}}" :class="{active:isActive('commodityAssign',3)}">指定分配</a>
                     </li> @endcan
             </ul>
         </div>