Merge pull request 'Added logic for columns missing invoice in transit' (#176) from ranjith-dev into master
All checks were successful
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (push) Successful in 17s

Reviewed-on: #176
This commit was merged in pull request #176.
This commit is contained in:
2026-01-07 03:59:10 +00:00

View File

@@ -454,6 +454,22 @@ class InvoiceInTransitResource extends Resource
return;
}
$mandatoryColumns = 23;
$firstRow = $rows[0] ?? [];
if (count($firstRow) < $mandatoryColumns) {
Notification::make()
->title('Invalid Excel Format')
->body('Few columns not found. Columns A to W are mandatory.')
->danger()
->persistent()
->send();
return;
}
foreach ($rows as $index => $row)
{
if ($index == 0) {