소스 검색

Merge branch 'master' into zengjun

# Conflicts:
#	app/Http/Controllers/OrderController.php
#	app/Http/Controllers/TestController.php
#	app/Services/LogisticService.php
#	app/Services/QualityLabelService.php
#	app/Services/RejectedService.php
#	app/Services/WaybillService.php
#	resources/views/order/wave/menu.blade.php
#	resources/views/order/wave/search.blade.php
#	resources/views/process/index.blade.php
#	routes/web.php
#	webpack.mix.js
ajun 5 년 전
부모
커밋
ac51d7b0e7

+ 11 - 4
app/Console/Commands/FluxOrderFix.php

@@ -44,9 +44,16 @@ class FluxOrderFix extends Command
     }
 
     public function fixEdisendflagAtWrong(){
-        OracleDOCOrderHeader::where('edisendflag','W')->whereNotNull('edisendtime')->where('edisendtime','>',Carbon::now()->subDays(2))
-            ->update(['edisendflag'=>'N','manualflag'=>'N',
-//                'edisendtime'=>null
-            ]);
+        OracleDOCOrderHeader::where('edisendflag','W')
+            ->whereNull('EDI_RESENDTIME')
+            ->where('edisendtime','>',Carbon::now()->subDays(2))
+            ->where('ediremarks2','<>','不支持的单据类型')
+        ->update(['edisendflag'=>'N','manualflag'=>'N','EDI_RESENDTIME'=>Carbon::now()]);
+
+        OracleDOCOrderHeader::where('edisendflag','W')
+            ->where('EDI_RESENDTIME','>',Carbon::now()->subDays(2))
+            ->where('edisendtime','>',Carbon::now()->subDays(2))
+            ->where('ediremarks2','<>','不支持的单据类型')
+        ->update(['edisendflag'=>'N','manualflag'=>'N']);
     }
 }

+ 1 - 1
app/Console/Kernel.php

@@ -29,7 +29,7 @@ class Kernel extends ConsoleKernel
     protected function schedule(Schedule $schedule)
     {
         $schedule->command('LogExpireDelete')->dailyAt('00:01');
-        $schedule->command('FluxOrderFix')->hourlyAt(6);
+        $schedule->command('FluxOrderFix')->hourlyAt(1);
     }
 
     /**

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

@@ -1123,8 +1123,8 @@ class ProcessController extends Controller
             'user_id'=>'参与人',
             'started_at'=>'开始时间',
             'ended_at'=>'结束时间',
-            'hour_price'=>'计时工资',
-            'unit_price'=>'计件工资',
+            'hour_price'=>'计时单价',
+            'unit_price'=>'计件单价',
             'dinner_duration'=>'晚饭时间',
             'hour_count'=>'计时工时',
             'unit_count'=>'计件数量',

+ 7 - 23
app/Http/Controllers/TestController.php

@@ -87,29 +87,14 @@ class TestController extends Controller
     function t2(Request $request)
     { //x        $packagesBatch=Package::where('batch_number',$batch_number)->first();
 
-        $uploaded = 0;
-        $count = DB::table('logs')->where('operation', 'like', "%PackageController::new_%")
-            ->where('created_at', '>', "2020-06-03 14:02:00")
-            ->where('created_at', '<', "2020-06-03 15:05:00")
-            ->where('type', "request_new_")
-            ->where('description', 'like', "%W200603000117%")
-            ->count();
-        $requests = DB::table('logs')->where('operation', 'like', "%PackageController::new_%")
-            ->where('created_at', '>', "2020-06-03 14:02:00")
-            ->where('created_at', '<', "2020-06-03 15:05:00")
-            ->where('description', 'like', "%W200603000117%")
-            ->where('type', "request_new_")
+
+        $objs=OracleDOCOrderHeader::select(['EDI_RESENDTIME'])->where('edisendflag','W')
+            ->where('EDI_RESENDTIME','>',Carbon::now()->subDays(2))
+            ->where('edisendtime','>',Carbon::now()->subDays(2))
+            ->where('ediremarks2','<>','不支持的单据类型')
             ->get();
-        $requests->each(function ($request) use (&$uploaded) {
-            $requestJson = json_decode($request->description, true);
-            $response = Zttp::withHeaders(['content-type' => 'application/json',
-            ])->post('https://was.baoshi56.com/api/thirdPart/flux/package/new',
-                $requestJson
-            );
-            if ($response->json() && $response->json()['response'] && $response->json()['response']['flag'] == 'Y')
-                $uploaded += 1;
-        });
-        dd($uploaded . '/' . $count);
+//        ->update(['edisendflag'=>'N','manualflag'=>'N','EDI_RESENDTIME'=>Carbon::now()]);
+        dd($objs);
 
 
     }
@@ -292,7 +277,6 @@ class TestController extends Controller
     /*1*/
     function test(Request $request)
     {/**/
-        dd(City::select('id','name')->first());
     }
 
 }

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

@@ -140,7 +140,7 @@ class UserLaborController extends Controller
             'mobile_phone'=>'电话',
             'gender'=>'性别',
             'identity_number'=>'身份证号',
-            'default_hour_price'=>'默认计时工资',
+            'default_hour_price'=>'默认计时单价',
             'name'=>'劳务所',
         ])->validate();
         $userDetail=UserDetail::find($id);

+ 2 - 2
database/migrations/2020_03_25_164303_create_process_daily_participants_table.php

@@ -21,9 +21,9 @@ class CreateProcessDailyParticipantsTable extends Migration
             $table->bigInteger('user_id')->index()->comment('外键用户');
             $table->time('started_at')->nullable()->comment('开始时间');
             $table->time('ended_at')->nullable()->comment('开始时间');
-            $table->decimal('hour_price')->nullable()->comment('计时工资');
+            $table->decimal('hour_price')->nullable()->comment('计时单价');
             $table->tinyInteger('hour_count')->nullable()->comment('计时工时');
-            $table->decimal('unit_price')->nullable()->comment('计件工资');
+            $table->decimal('unit_price')->nullable()->comment('计件单价');
             $table->integer('unit_count')->nullable()->comment('计件数');
             $table->integer('dinner_duration')->default(0)->comment('晚饭时间');
             $table->string('remark')->nullable()->comment('备注');

+ 1 - 1
database/migrations/2020_03_25_164350_create_user_labors_table.php

@@ -17,7 +17,7 @@ class CreateUserLaborsTable extends Migration
     {
         Schema::create('user_labors', function (Blueprint $table) {
             $table->bigInteger('user_id')->unique()->comment('外键用户');
-            $table->decimal('default_hour_price')->nullable()->comment('默认计时工资');
+            $table->decimal('default_hour_price')->nullable()->comment('默认计时单价');
             $table->string('company')->nullable()->index()->comment('劳务所');
         });
     }

+ 1 - 1
database/migrations/2020_05_22_173230_change_user_labors_table.php

@@ -17,7 +17,7 @@ class ChangeUserLaborsTable extends Migration
         Schema::dropIfExists('user_labors');
         Schema::create('user_labors', function (Blueprint $table) {
             $table->bigInteger('user_id')->index()->comment('外键用户');
-            $table->decimal('default_hour_price')->nullable()->comment('默认计时工资');
+            $table->decimal('default_hour_price')->nullable()->comment('默认计时单价');
             $table->bigInteger('labor_company_id')->nullable()->index()->comment('外键劳务所');
         });
     }

+ 1 - 1
resources/views/maintenance/userLabor/edit.blade.php

@@ -57,7 +57,7 @@
                     @enderror
                 </div>
                 <div class="form-group row">
-                    <label for="default_hour_price" class="form-check-label col-3 pull-left">默认计时工资/小时:</label>
+                    <label for="default_hour_price" class="form-check-label col-3 pull-left">默认计时单价/小时:</label>
                     <input name="default_hour_price" :value="userLabor.default_hour_price" id="default_hour_price" class="@error('default_hour_price') is-invalid @enderror col-7 form-control" type="text">
                     @error('default_hour_price')
                     <span class="invalid-feedback col-7 offset-3 mt-0" role="alert">

+ 2 - 2
resources/views/maintenance/userLabor/index.blade.php

@@ -24,9 +24,9 @@
                                     <td>开始时间</td>
                                     <td>结束时间</td>
                                     <td>计件数</td>
-                                    <td>计件工资</td>
+                                    <td>计件单价</td>
                                     <td>计时数</td>
-                                    <td>计时工资</td>
+                                    <td>计时单价</td>
                                 </tr>
                                 </thead>
                                 <tbody>

+ 0 - 4
resources/views/order/wave/menu.blade.php

@@ -6,11 +6,7 @@
             <ul class="nav nav-pills">
                 @can('订单管理-波次-查询')
                     <li class="nav-item">
-<<<<<<< HEAD
-                        <a class="nav-link" href="{{url('order/wave/index/')}}" :class="{active:isActive('index',3)}">查询</a>
-=======
                         <a class="nav-link" href="{{url('order/wave/index/')}}" :class="{active:isActive('wave',2)}">查询</a>
->>>>>>> master
                     </li> @endcan
             </ul>
         </div>

+ 5 - 18
resources/views/order/wave/search.blade.php

@@ -3,7 +3,7 @@
 
 @section("content")
     @component("order.wave.menu")@endcomponent
-    <div class="container-fluid" id="wave_div">
+    <div class="container-fluid d-none" id="wave_div">
         <div style="min-width: 2000px;">
 
 
@@ -83,7 +83,7 @@
 @endsection
 
 @section("lastScript")
-    <script type="text/javascript" src="{{asset('queryForm.js.queryForm.js.tempscript>
+    <script type="text/javascript" src="{{asset('js/queryForm/queryForm.js')}}"></script>
     <script>
         let vueList = new Vue({
             el: "#wave_div",
@@ -114,9 +114,10 @@
                 checkData: [],
                 pageTotal:'{{$param['pageTotal']}}',
                 currPage:'{{$param['currPage']}}',
-                selectedWaveNo:'',
+
             },
             mounted: function () {
+                $('#wave_div').removeClass('d-none')
                 let data = [[
                     {name: 'start_time', type: 'dataTime', tip: '选择显示指定日期的起始时间', placeholder: ''},
                     {name: 'end_time', type: 'dataTime', tip: '选择显示指定日期的结束时间', placeholder: ''},
@@ -130,17 +131,6 @@
                 this.form.init();
                 $(".tooltipTarget").tooltip({'trigger': 'hover'});
             },
-            watch:{
-                checkData:{
-                    handler(){
-                        if(this.checkData.length === this.waves.length){
-                            document.querySelector("#all").checked = true;
-                        }else{
-                            document.querySelector("#all").checked = false;
-                        }
-                    }
-                }
-            },
             methods: {
                 singleCancelPrint: function ($event) {
                     let ids = $($event.target).attr("data-value");
@@ -220,11 +210,7 @@
                     let url = window.location.search ;
                     url = url.length< 2 ? '' : url.substring(1);
                     console.log(search,url);
-<<<<<<< HEAD
-                    window.open("{{url('order/wave/exportExcel?')}}"+search+"&"+url);
-=======
                     window.open("{{url('oder/wave/exportExcel?')}}"+search+url);
->>>>>>> master
                     // todo
                    /* let instance = axios.create({
                         {{--url:'{{url("wave/exportExcel")}}',--}}
@@ -270,6 +256,7 @@
                         this.checkData = [];
                     }
                 },
+
                 getCheckedIds(){
                     // HACK
                     let values = [];

+ 5 - 5
resources/views/process/index.blade.php

@@ -81,14 +81,14 @@
                         </div>
                         <div v-if="errors.hour_price" class="row"><label class="col-3"></label><small  class="text-danger col-7">@{{ errors.hour_price[0] }}</small></div>
                         <div class="form-group row">
-                            <label for="initial_weight" class="col-3 col-form-label text-right">计时工资</label>
+                            <label for="initial_weight" class="col-3 col-form-label text-right">计时单价</label>
                             <div class="col-7">
                                 <input :class="{ 'is-invalid' : errors.hour_price }"  type="text" class="form-control" autocomplete="off" v-model="processDailyParticipantOne.hour_price" >
                             </div>
                         </div>
                         <div v-if="errors.unit_price" class="row"><label class="col-3"></label><small  class="text-danger col-7">@{{ errors.unit_price[0] }}</small></div>
                         <div class="form-group row">
-                            <label for="initial_weight" class="col-3 col-form-label text-right">计件工资</label>
+                            <label for="initial_weight" class="col-3 col-form-label text-right">计件单价</label>
                             <div class="col-7">
                                 <input :class="{ 'is-invalid' : errors.unit_price }" type="text" class="form-control" autocomplete="off" v-model="processDailyParticipantOne.unit_price" >
                             </div>
@@ -318,9 +318,9 @@
                             </tr>
                         </table>
                         <div v-else :style="[{background: (!processOne.id || processOne.is_multi_row)  ? (!processOne.id) ? '#e8eef6' :'rgb(246, 238, 232)' : (processOne.processesContents.length>0 ? ((processOne.processesContents[0].type=='成品单') ? '#e8eef6' : 'rgb(246, 238, 232)') :'')}
-                        ,{'-webkit-transform':'scale('+(1/Math.ceil(arrayFilter(processOne.processesContents,processOne).length/3))+')'},{height: (35*Math.ceil(arrayFilter(processOne.processesContents,processOne).length/3))+'px'}
-                        ,{width: (100*Math.ceil(arrayFilter(processOne.processesContents,processOne).length/3))+'%'},{'margin-left': (-100*((Math.ceil(arrayFilter(processOne.processesContents,processOne).length/3))-1)/2)+'%'}
-                        ,{'margin-top': (-35*((Math.ceil(arrayFilter(processOne.processesContents,processOne).length/3))-1)/2)+'px'},{'margin-bottom': (-35*((Math.ceil(arrayFilter(processOne.processesContents,processOne).length/3))-1)/2)+'px'}]">
+                        ,{'-webkit-transform':'scale('+(1/Math.ceil(arrayFilter(processOne.processesContents,processOne).length/2))+')'},{height: (35*Math.ceil(arrayFilter(processOne.processesContents,processOne).length/2))+'px'}
+                        ,{width: (100*Math.ceil(arrayFilter(processOne.processesContents,processOne).length/2))+'%'},{'margin-left': (-100*((Math.ceil(arrayFilter(processOne.processesContents,processOne).length/2))-1)/2)+'%'}
+                        ,{'margin-top': (-35*((Math.ceil(arrayFilter(processOne.processesContents,processOne).length/2))-1)/2)+'px'},{'margin-bottom': (-35*((Math.ceil(arrayFilter(processOne.processesContents,processOne).length/2))-1)/2)+'px'}]">
                             <div v-for="(processesContent,i) in arrayFilter(processOne.processesContents,processOne)"  class=" row  p-1" style="float: left;margin-right: 10px;-webkit-transform-origin: 0" :style="[{opacity:1/0.7},
                             {'margin-left': arrayFilter(processOne.processesContents,processOne).length >3 ? (1*parseInt(arrayFilter(processOne.processesContents,processOne).length/3))+'px' : '0px'}]">
                                 <span>@{{ processesContent.bill_type }}</span>&nbsp;&nbsp;

+ 0 - 1
routes/web.php

@@ -324,7 +324,6 @@ Route::group(['prefix'=>'order'],function(){
     Route::post('wave/cancelPrinting','WaveController@cancelPrinting');
     // export Excel
     Route::any('wave/exportExcel','WaveController@exportExcelOnParams');
-
 });
 /**
  * 问题件