M3 Integration fixes

This commit is contained in:
Mark Gregory
2026-09-21 13:25:44 +01:00
parent 47085e5160
commit 3521e47ef0
62 changed files with 131 additions and 173 deletions
@@ -77,7 +77,7 @@ class BoxPackToPalletController extends Controller
$box = trim((string) ($request->R659BOX ?? ''));
abort_if($box === '', 400, 'Box Not Found');
$user = m3_user() !== '' ? Str::upper(m3_user()) : 'WebUser';
$user = m3User() !== '' ? Str::upper(m3User()) : 'WebUser';
$profile = self::getUserWhsCoPlant();
$validation = self::validateScannedBox($pallet, $box, $profile);
@@ -268,7 +268,7 @@ class BoxPackToPalletController extends Controller
// Get Logged User CO/WHS/PLANT
public static function getUserWhsCoPlant()
{
$sHUSER = m3_user() !== '' ? Str::upper(trim(m3_user())) : '';
$sHUSER = m3User() !== '' ? Str::upper(trim(m3User())) : '';
// Get users from ICM428M
$iCM428M = DB::connection(config('m3.connection', 'pgsql'))->table('icm428m')
->select('R428US', 'R428CO', 'R428WH', 'R428PL')