mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/portal.git
synced 2026-08-26 16:04:23 +00:00
Merge branch 'master' of gitlab.com:CIEFWorldwideSdnBhd/shipping-portal into development
# Conflicts: # resources/views/pages/warehouse_list.blade.php
This commit is contained in:
@@ -66,10 +66,10 @@ class CreateOrderLogic extends AbstractControllerLogic
|
||||
|
||||
$originWarehouse = $this->fetchesCompanyModule->execute(['id' => $request->input('warehouse_id')]);
|
||||
|
||||
$originWarehouse = $originWarehouse->reference === WarehouseReferences::VT_GUANG_ZHOU ? $this->fetchesCompanyModule->execute(['reference' => in_array($company->id, [2376]) ? WarehouseReferences::VT_GUANG_ZHOU : WarehouseReferences::YD_GUANG_ZHOU]) : $this->fetchesCompanyModule->execute(['reference' => $company->id === WarehouseReferences::YD_YIWU]);
|
||||
$originWarehouse = $originWarehouse->reference === WarehouseReferences::VT_GUANG_ZHOU ? $this->fetchesCompanyModule->execute(['reference' => in_array($company->id, [2376]) ? WarehouseReferences::VT_GUANG_ZHOU : WarehouseReferences::YD_GUANG_ZHOU]) : $this->fetchesCompanyModule->execute(['reference' => WarehouseReferences::YD_YIWU]);
|
||||
|
||||
if($originWarehouse->reference === WarehouseReferences::YD_YIWU && in_array($address->state_id, [5, 13, 14])) {
|
||||
throw new RequestValidationException('Our Yiwu warehouse is unable to ship goods to Sabah & Sarawak at the moment due to the chinese new year\'s holiday. you can select our Guangzhou warehouse as an alternative.');
|
||||
throw new RequestValidationException('Our Yiwu warehouse is unable to ship goods to Sabah & Sarawak at the moment. you can select our Guangzhou warehouse as an alternative.');
|
||||
}
|
||||
|
||||
$order = $this->createOrderProcessor->execute($company, $originWarehouse, $address, $this->generatesOrderNumber->execute());
|
||||
|
||||
@@ -74,6 +74,7 @@ class UpdateDoFromVTPortalProcessor
|
||||
$vt_do = $this->fetchesDataFRomVTPortal->clientRequest('http://portal.vtnation.com.my/Services/DataControllerService.asmx/GetPage', 'POST', json_decode('{"controller":"Do","view":"grid1","request":{"PageIndex":-1,"PageSize":10000,"Filter": ["FullMarking:$contains$%js%\"' . $order->reference . '\"\u0000"]}}'), '');
|
||||
|
||||
$vt_do = $this->fetchesDataFRomVTPortal->getResponseBody($vt_do);
|
||||
|
||||
if ($vt_do) {
|
||||
foreach ($vt_do->Rows as $key => $row) {
|
||||
$vt_do_update = $this->fetchesDataFRomVTPortal->clientRequest(
|
||||
|
||||
@@ -100,8 +100,7 @@ class AssignPackingListOrderLogic extends AbstractControllerLogic
|
||||
{
|
||||
$warehouse_packing_list = $this->fetchesPackingList->execute([
|
||||
'id' => $request->route('id'),
|
||||
'type' => PackingListType::WAREHOUSE_RECEIVE_LIST,
|
||||
'status' => ApprovalStatus::REJECTED
|
||||
'type' => PackingListType::WAREHOUSE_RECEIVE_LIST
|
||||
]);
|
||||
|
||||
$order = $this->fetchesOrder->execute(['reference' => $request->route('reference')]);
|
||||
@@ -129,8 +128,7 @@ class AssignPackingListOrderLogic extends AbstractControllerLogic
|
||||
|
||||
$packing_list = $this->fetchesPackingList->execute([
|
||||
'reference' => $warehouse_packing_list->reference,
|
||||
'type' => PackingListType::SHIPPING_PACKING_LIST,
|
||||
'status' => ApprovalStatus::PENDING_VERIFICATION
|
||||
'type' => PackingListType::SHIPPING_PACKING_LIST
|
||||
]);
|
||||
|
||||
$warehouse_packing_list = $this->updatesPackingListOwner->execute($packing_list, $order);
|
||||
|
||||
@@ -74,8 +74,10 @@ class UpdatePackingListStatusLogic extends AbstractControllerLogic
|
||||
$address = $packing_list->owner()->first()->addresses()->where('status', ApprovalStatus::APPROVED)->first();
|
||||
|
||||
|
||||
$appointee = $address->owner->orderRoles()->where('role_id', '=', OrderRoleTypes::ORIGIN_FREIGHT_FORWARDER)->first()->appointee->id;
|
||||
$appointee === 2 ? $this->updateDoFromVTPortalProcessor->execute($address) : $this->updateDoFromYDPortalProcessor->execute($address);
|
||||
// $appointee = $address->owner->orderRoles()->where('role_id', '=', OrderRoleTypes::ORIGIN_FREIGHT_FORWARDER)->first()->appointee->id;
|
||||
|
||||
$this->updateDoFromVTPortalProcessor->execute($address);
|
||||
$this->updateDoFromYDPortalProcessor->execute($address);
|
||||
|
||||
return $this->resourceResponse(new PackingListResource($packing_list));
|
||||
}
|
||||
|
||||
+1
-1
@@ -126,7 +126,7 @@ class FetchLoadedContainersFromVTPortalProcessor
|
||||
|
||||
DB::beginTransaction();
|
||||
try {
|
||||
$start = $start ? $start : Carbon::now()->subDays(10);
|
||||
$start = $start ? $start : Carbon::now()->subDays(15);
|
||||
|
||||
$startLimit = Carbon::parse('11-08-2021');
|
||||
|
||||
|
||||
+17
-2
@@ -269,7 +269,7 @@ class FetchOrderListsFromYdPortalProcessor
|
||||
$this->unityAssignContractEntity->execute($supervisorContractEntity->hash_id, $contractObligations);
|
||||
}
|
||||
|
||||
$packingListObject = new PackingListObject($packingListReference, $appointee_id, PackingListType::SHIPPING_PACKING_LIST, ApprovalStatus::PENDING_VERIFICATION, !$allow_contract ? null : $contractReference);
|
||||
$packingListObject = new PackingListObject($packingListReference, $appointee_id, PackingListType::SHIPPING_PACKING_LIST, ApprovalStatus::SUSPENDED, !$allow_contract ? null : $contractReference);
|
||||
|
||||
/** @var PackingList $packingList */
|
||||
$packingList = $this->createPackingListProcessor->execute($packingListObject, $order);
|
||||
@@ -310,6 +310,7 @@ class FetchOrderListsFromYdPortalProcessor
|
||||
if($containerReference) {
|
||||
try {
|
||||
$container = $this->fetchesContainer->execute(['reference' => $containerReference]);
|
||||
$container->packingLists()->syncWithoutDetaching([$packingList->id]);
|
||||
} catch (ResourceNotFoundException $exception){
|
||||
|
||||
if (!$allow_contract) {
|
||||
@@ -325,7 +326,8 @@ class FetchOrderListsFromYdPortalProcessor
|
||||
/** @var Container $container */
|
||||
$container = $this->createContainerProcessor->execute($containerObject, $originWarehouse);
|
||||
|
||||
$container->packingLists()->attach($packingList);
|
||||
$container->packingLists()->detach($packingList);
|
||||
$container->packingLists()->attach($packingList);
|
||||
|
||||
$transport = $container->transports()->first();
|
||||
|
||||
@@ -337,6 +339,18 @@ class FetchOrderListsFromYdPortalProcessor
|
||||
}
|
||||
}
|
||||
|
||||
if($delayDate){
|
||||
|
||||
$transport = $container->transports()->first();
|
||||
|
||||
if(!$transport->schedules()->where('eta', '=', $delayDate)->first()) {
|
||||
$etd = $transport->schedules()->where('status', '=', ApprovalStatus::APPROVED)->first()->etd;
|
||||
$transport->schedules()->update(['status' => ApprovalStatus::EXPIRED]);
|
||||
$this->createsSchedule->execute($transport, new ScheduleObject($etd, $delayDate, ApprovalStatus::APPROVED));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
if($unstuffingDate && $container->status !== ApprovalStatus::COMPLETED){
|
||||
$container->update(['status' => ApprovalStatus::COMPLETED]);
|
||||
$container->transports()->first()->update(['drop_date' => $unstuffingDate, 'status' => ApprovalStatus::COMPLETED]);
|
||||
@@ -380,6 +394,7 @@ class FetchOrderListsFromYdPortalProcessor
|
||||
}
|
||||
|
||||
DB::commit();
|
||||
echo 'successful';
|
||||
|
||||
}
|
||||
} catch (\Exception $exception) {
|
||||
|
||||
+1
-1
@@ -116,7 +116,7 @@ class FetchWarehouseReceiveListFromVTPortalProcessor
|
||||
|
||||
try {
|
||||
|
||||
$start = $start ? $start : Carbon::now()->subMonth();
|
||||
$start = $start ? $start : Carbon::now()->subMonths(2);
|
||||
|
||||
$startLimit = Carbon::parse('11-08-2021');
|
||||
|
||||
|
||||
-23
@@ -11,29 +11,6 @@
|
||||
<on-boarding-section-component v-if="!company.last_order"></on-boarding-section-component>
|
||||
<div class="row" v-if="company.last_order">
|
||||
<div class="col">
|
||||
<div class="row m-b-20">
|
||||
<div class="col no-padding">
|
||||
<div class="alert alert-warning m-t-20" role="alert">
|
||||
<div class="row">
|
||||
<div class="col">
|
||||
<div class="row">
|
||||
<div class="col">
|
||||
<p class="fs-18 p-t-15"><i class="fa fa-exclamation-triangle m-r-5"></i> !!!! 海运费涨价通知 NOTICE OF PRICE INCREMENT !!! <i class="fa fa-exclamation-triangle m-l-5"></i></p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col">
|
||||
<p>由于近期海运费非常不稳定,运费每个星期都会调整,请发货入仓之前按以下按键确认最新运费价格。</p>
|
||||
<p>Due to the recent unstable shipping rates, shipping costs are adjusted weekly, please confirm the latest shipping prices before shipping into the warehouse by following the button below.</p>
|
||||
<a href="https://www.cief-malaysia.com/services-sea-shipping/" target="_blank"><div class="btn btn-complete">Sea Shipping Price List</div></a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row m-b-30 relative">
|
||||
<div class="col">
|
||||
<div class="row">
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<div class="row">
|
||||
<div class="col">
|
||||
<div class="row align-items-center p-t-5 p-b-5">
|
||||
<div class="col-auto p-r-0">
|
||||
<div class="col-auto p-r-0" v-if="!$store.getters.isAdmin">
|
||||
<div class="padding-5 lh-25 btn-rounded bg-white" v-if="item.type === 0">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" x="0px" y="0px"
|
||||
width="30" height="30"
|
||||
@@ -22,19 +22,19 @@
|
||||
<p class="no-margin all-caps fs-10 light">Arrival Date</p>
|
||||
<p class="no-margin text-success bold">{{item.transport ? item.transport.drop_date : 'n/a'}}</p>
|
||||
</div>
|
||||
<div class="col-auto text-center">
|
||||
<div class="col-auto p-l-0 p-r-0 text-center">
|
||||
<p class="no-margin all-caps fs-10 light">Qty</p>
|
||||
<p class="no-margin bold">{{item.quantity}}</p>
|
||||
</div>
|
||||
<div class="col-auto" v-if="!$store.getters.isAdmin">
|
||||
<div class="col-auto">
|
||||
<p class="no-margin all-caps fs-10 light">Est. CBM</p>
|
||||
<p class="no-margin">{{((parseFloat(item.cbm) * 1000) / 1000).toFixed(3)}}</p>
|
||||
</div>
|
||||
<div class="col-auto" v-if="$store.getters.isAdmin">
|
||||
<div class="col" v-if="$store.getters.isAdmin">
|
||||
<p class="no-margin all-caps fs-10 light">Warehouse</p>
|
||||
<p class="no-margin">{{item.order.warehouse.reference}}</p>
|
||||
</div>
|
||||
<div class="col text-right">
|
||||
<div class="col-auto text-right">
|
||||
<div class="btn btn-xs btn-default" @click="expanded = !expanded"><i class="fa" :class="{'fa-angle-up': expanded, 'fa-angle-down': !expanded}"></i></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -45,16 +45,14 @@
|
||||
<div class="col-6">
|
||||
<div class="row m-t-20">
|
||||
<div class="col">
|
||||
<p>请注意!! 由于近期船公司对于重量严格把控,我司对于货物超重的算法也进行了调整。新超重算法将从 2022 年 1 月 20日(货物装箱日期)起实行。</p>
|
||||
<p>Attention!! Due to the shipping liner company are strict on checking the weight recently, our company has modified the calculation formula against overweight goods. The new formula will start to be applied on 20th January 2022 (goods loaded date).</p>
|
||||
<p>For more details: <a href="https://www.cief-malaysia.com/services-sea-shipping/" target="_blank">https://www.cief-malaysia.com/services-sea-shipping/</a></p>
|
||||
<p class="text-center">最新运费价格 <a href="https://www.cief-malaysia.com/services-sea-shipping/" class="text-underline" target="_blank">点击 “这里 </a><br>For the latest shipping prices <a href="https://www.cief-malaysia.com/services-sea-shipping/" class="text-underline" target="_blank">click here</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row text-center justify-content-center">
|
||||
<div class="col-8">
|
||||
<p class="m-b-0 text-danger m-t-15" v-if="parameters.warehouse_id === 4">浙江北仑疫情爆发, 义乌船期非常不稳定,建议发广州仓库<br>Due to Beilun, Zhejiang pandemic outbreak our Yiwu warehouse might experience unexpected shipping delays, you can select our Guangzhou warehouse as an alternative.</p>
|
||||
<p class="m-b-0 text-danger m-t-15" v-if="parameters.warehouse_id === 4">由于义乌船期不稳定,建议发广州仓库。<br>Due to unexpected shipping delays for Yiwu warehouse, you may select an alternative warehouse.</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
@extends('layouts.base_portal')
|
||||
@section('inner_content')
|
||||
<div class="row">
|
||||
<div class="col-4">
|
||||
<div class="col-5">
|
||||
<div class="row p-b-5 b-b b-grey m-b-10 m-l-0 m-r-0">
|
||||
<div class="col no-padding">
|
||||
<h6>Arrived Parcel</h6>
|
||||
|
||||
Reference in New Issue
Block a user