|
|
@@ -884,11 +884,11 @@ class WaybillsController extends Controller
|
|
|
if ($request->input('type')=='直发车'){
|
|
|
$validator=Validator::make($request->input(),[
|
|
|
'carrier_bill'=>"nullable|max:50|unique:waybills,carrier_bill,$id",
|
|
|
- // 'fee'=>'required|min:0|numeric|max:999999',
|
|
|
+ 'fee'=>'nullable|min:0|numeric|max:999999',
|
|
|
'other_fee'=>'nullable|min:0|numeric|max:999999',
|
|
|
'charge'=>'nullable|min:0|numeric|max:999999',
|
|
|
- 'mileage'=>'nullable|numeric',
|
|
|
- 'amount'=>'nullable|numeric',
|
|
|
+ 'mileage'=>'nullable|numeric|min:0',
|
|
|
+ 'amount'=>'nullable|numeric|min:0',
|
|
|
],[
|
|
|
'required'=>':attribute 为必填项',
|
|
|
'alpha_num'=>':attribute 应为字母或数字',
|
|
|
@@ -898,7 +898,7 @@ class WaybillsController extends Controller
|
|
|
'unique'=>':attribute 已存在',
|
|
|
],[
|
|
|
'carrier_bill'=>'承运商单号',
|
|
|
- //'fee'=>'运费',
|
|
|
+ 'fee'=>'运费',
|
|
|
'other_fee'=>'其他费用',
|
|
|
'charge'=>'收费',
|
|
|
'mileage'=>'里程数',
|
|
|
@@ -928,6 +928,7 @@ class WaybillsController extends Controller
|
|
|
'carrier_weight_unit_id'=>'required_with:carrier_weight',
|
|
|
'carrier_weight_other'=>'nullable|min:0|numeric|max:999999',
|
|
|
'carrier_weight_unit_id_other'=>'required_with:carrier_weight_other',
|
|
|
+ 'mileage'=>'nullable|min:0'
|
|
|
],[
|
|
|
'required'=>':attribute 为必填项',
|
|
|
'alpha_num'=>':attribute 应为字母或数字',
|
|
|
@@ -952,6 +953,7 @@ class WaybillsController extends Controller
|
|
|
'carrier_weight_other'=>'承运商计数二',
|
|
|
'warehouse_weight_unit_id_other'=>'仓库技数单位二',
|
|
|
'carrier_weight_unit_id_other'=>'承运商计数单位二',
|
|
|
+ 'mileage'=>'计数',
|
|
|
]);
|
|
|
return $validator;
|
|
|
}
|