Fix Laravel Pint formatting
This commit is contained in:
@@ -14,7 +14,7 @@ class PurchaseOrderReceiveService
|
||||
public function receive(int $poId, array $received, string $issuedBy): array
|
||||
{
|
||||
$po = PurchaseOrder::query()->find($poId);
|
||||
if (!$po || in_array($po->status, [PurchaseOrder::STATUS_CANCELED, PurchaseOrder::STATUS_RECEIVED], true)) {
|
||||
if (! $po || in_array($po->status, [PurchaseOrder::STATUS_CANCELED, PurchaseOrder::STATUS_RECEIVED], true)) {
|
||||
throw new RuntimeException('PO not receivable.');
|
||||
}
|
||||
|
||||
@@ -37,8 +37,9 @@ class PurchaseOrderReceiveService
|
||||
->where('id', $itemId)
|
||||
->first();
|
||||
|
||||
if (!$poItem) {
|
||||
if (! $poItem) {
|
||||
$completed = false;
|
||||
|
||||
continue;
|
||||
}
|
||||
|
||||
@@ -52,8 +53,9 @@ class PurchaseOrderReceiveService
|
||||
$poItem->save();
|
||||
|
||||
$supply = Supply::query()->find($poItem->supply_id);
|
||||
if (!$supply) {
|
||||
if (! $supply) {
|
||||
$completed = false;
|
||||
|
||||
continue;
|
||||
}
|
||||
|
||||
@@ -64,7 +66,7 @@ class PurchaseOrderReceiveService
|
||||
'supply_id' => $supply->id,
|
||||
'type' => 'in',
|
||||
'quantity' => $toReceive,
|
||||
'ref' => 'PO ' . ($po->po_number ?? $po->id),
|
||||
'ref' => 'PO '.($po->po_number ?? $po->id),
|
||||
'issued_to' => 'Inventory',
|
||||
'issued_by' => $issuedBy,
|
||||
'notes' => 'Received against PO',
|
||||
|
||||
Reference in New Issue
Block a user