updates to M3 module

This commit is contained in:
Mark Gregory
2026-09-16 16:46:15 +01:00
parent 13a7e804af
commit ce06aa9fac
20 changed files with 191 additions and 203 deletions
@@ -11,7 +11,7 @@ use Str;
use Log;
use Http;
use File;
use Helper;
use Modules\M3\Helpers\Helper;
use Modules\M3\Http\Controllers\GetContentsController;
//use Request;
@@ -9,7 +9,7 @@ use DB;
use Config;
use Str;
use Log;
use Helper;
use Modules\M3\Helpers\Helper;
class M3Controller extends Controller
{
@@ -14,7 +14,7 @@ use Cache;
use DateTime;
use Smalot\PdfParser\Parser;
use File;
use Helper;
use Modules\M3\Helpers\Helper;
use Json;
class M3InventoryReport extends Controller
@@ -14,7 +14,7 @@ use Cache;
use DateTime;
use Smalot\PdfParser\Parser;
use File;
use Helper;
use Modules\M3\Helpers\Helper;
class PdfStorage extends Controller
{
@@ -14,7 +14,7 @@ use Cache;
use DateTime;
use Smalot\PdfParser\Parser;
use File;
use Helper;
use Modules\M3\Helpers\Helper;
class ReplenAPI extends Controller
{
@@ -14,7 +14,7 @@ use Cache;
use DateTime;
use Smalot\PdfParser\Parser;
use File;
use Helper;
use Modules\M3\Helpers\Helper;
class TransferAPI extends Controller
{
@@ -14,7 +14,7 @@ use Cache;
use DateTime;
use Smalot\PdfParser\Parser;
use File;
use Helper;
use Modules\M3\Helpers\Helper;
class TwoShipAPIs extends Controller
{
@@ -14,33 +14,20 @@ class M3DeliveryController extends Controller
{
public static function index(Request $request) {
$power_user = DB::connection(config('m3.connection', 'pgsql'))->table('icm428m')
->select('R428PWRUSR','R428US','R428CO','R428PL','R428WH')
->where('R428US','=',strtoUpper(m3_user()))
->first();
$co = $power_user->R428CO;
$plant = $power_user->R428PL;
$whs = $power_user->R428WH;
$ICM664M = DB::connection(config('m3.connection', 'pgsql'))->select("select * from ICM664M
where AVCO='$co' and AVPLANT='$plant' and AVWHS='$whs'");
$IC670M = DB::connection(config('m3.connection', 'pgsql'))->select("select * from IC670M where WDCO='$co' and WDPL='$plant' and WDWHS='$whs'");
$shipvia = DB::connection(config('m3.connection', 'pgsql'))->select("select AXCODE, AXDESC from ICM319M order by 1");
#646 where AXCO='$co' and AXWHS='$whs' and AXPLANT='$plant'
$connection = config('m3.connection', 'pgsql');
$power_user = (object) ['R428PWRUSR'=>'N','R428US'=>strtoUpper(m3_user()),'R428CO'=>'','R428PL'=>'','R428WH'=>''];
if (\Illuminate\Support\Facades\Schema::connection($connection)->hasTable('icm428m')) {
$power_user = DB::connection($connection)->table('icm428m')->select('R428PWRUSR','R428US','R428CO','R428PL','R428WH')
->where('R428US',strtoUpper(m3_user()))->first() ?? $power_user;
}
$co=$power_user->R428CO; $plant=$power_user->R428PL; $whs=$power_user->R428WH;
$ICM664M = \Illuminate\Support\Facades\Schema::connection($connection)->hasTable('icm664m')
? DB::connection($connection)->table('icm664m')->where('AVCO',$co)->where('AVPLANT',$plant)->where('AVWHS',$whs)->get() : collect();
$IC670M = \Illuminate\Support\Facades\Schema::connection($connection)->hasTable('ic670m')
? DB::connection($connection)->table('ic670m')->where('WDCO',$co)->where('WDPL',$plant)->where('WDWHS',$whs)->get() : collect();
$shipvia = \Illuminate\Support\Facades\Schema::connection($connection)->hasTable('icm319m')
? DB::connection($connection)->table('icm319m')->select('AXCODE','AXDESC')->orderBy('AXCODE')->get() : collect();
return view('m3::liberty-theme.pages.M3Delivery', compact('ICM664M','IC670M','power_user','shipvia'));
// AVCO AVCO CHARACTER 3 No ' ' Division
// AVWHS AVWHS CHARACTER 3 No ' ' Warehouse
// AVPLANT AVPLANT CHARACTER 3 No ' ' Plant
// AVDELMETH AVDELMETH CHARACTER 4 No ' ' Delivery method
// AVSHPVIA AVSHPVIA CHARACTER 4 No ' ' Sentinel ship via
// AVSHSRT AVSHSRT CHARACTER 6 No ' ' Sentinel route
// AVSHORCL AVSHORCL CHARACTER 3 No ' ' Sentinel intl code
// AVSPR1A01 AVSPR1A01 CHARACTER 1 No ' ' Spare field 1A 01
// AVSPR1A02 AVSPR1A02 CHARACTER 1 No ' ' Spare field 1A 02
// AVSPR10A01 AVSPR10A01 CHARACTER 10 No ' ' Spare field 10A 1
// AVSPR15A01 AVSPR15A01 CHARACTER 15 No ' ' Spare field 15A 1
// AVSPR30A01 AVSPR30A01 CHARACTER 30 No ' ' Spare field 30A 1
}
//
@@ -23,9 +23,10 @@ class M3ErrorsDispController extends Controller
$skipdates = isset($request->skipdates) ? trim($request->skipdates) : "N";
# Get users from ICM428M
$ICM428M = DB::connection(config('m3.connection', 'pgsql'))->table('icm428m')
->select('R428US', 'R428FIRST', 'R428FAMILY')
->get();
$connection = config('m3.connection', 'pgsql');
$ICM428M = \Illuminate\Support\Facades\Schema::connection($connection)->hasTable('icm428m')
? DB::connection($connection)->table('icm428m')->select('R428US', 'R428FIRST', 'R428FAMILY')->get()
: collect();
$ICM428MCOL = collect($ICM428M);
$ICM428MCOL->filter(function ($value) {
return $value->R428US = trim($value->R428US);
@@ -19,7 +19,10 @@ class M3GetPDFFromCacheController extends Controller
// Parse PDF file and build necessary objects.
$parser = new \Smalot\PdfParser\Parser();
$aggno = $aggmsg = ""; #$carrier = $trackingno = "";
$aggno = $aggmsg = "";
$IC670M = $PDFArray = $carrier = $trackingno = $ICM688M1 = [];
$AYMACPKR = $WHDDA = $COMPANY = $PLANT = $WHS = '';
#$carrier = $trackingno = "";
# PDF File PATH
$pdfFilePath = Config::get('arrays.PdfPath');
@@ -15,6 +15,10 @@ use Storage;
class OrderLinesOfClosedOrder extends Controller
{
public static function index(Request $request){
$IC670M = $ICM688M2 = [];
$WHDDA = $COMPANY = $PLANT = $WHS = '';
$REPORTDATEDisp = today()->format('Ymd');
$allReportsUrls = [];
try {
$SHUSER = m3_user() !== '' ? Str::upper(trim(m3_user())) : '';
// dd($SHUSER);
@@ -23,10 +23,10 @@ class ReplenishSettingsController extends Controller
# Get Logged user Id
$userId = m3_user() !== '' ? strtoupper(m3_user()) : '' ;
// $userId = 'E1135818'; // Brad : E1135818 Malak : E2011812 ACOM_PDF
$ICM428M = DB::connection(config('m3.connection', 'pgsql'))->table('icm428m')
->where('R428US',$userId)
->where('R428STS','A')
->first();
$connection = config('m3.connection', 'pgsql');
$ICM428M = \Illuminate\Support\Facades\Schema::connection($connection)->hasTable('icm428m')
? DB::connection($connection)->table('icm428m')->where('R428US',$userId)->where('R428STS','A')->first()
: null;
$userCO = isset($ICM428M->R428CO) ? $ICM428M->R428CO : '';
$userPL = isset($ICM428M->R428PL) ? $ICM428M->R428PL : '';
@@ -34,11 +34,13 @@ class ReplenishSettingsController extends Controller
if ($userCO!='') {
# Warehouse Table
$IC670M = DB::connection(config('m3.connection', 'pgsql'))->table('ic670m')
$IC670M = \Illuminate\Support\Facades\Schema::connection($connection)->hasTable('ic670m')
? DB::connection($connection)->table('ic670m')
->where('WDCO',$userCO)
->where('WDPL',$userPL)
->where('WDWHS',$userWH)
->get();
->get()
: [];
}
else{
// $REFCAT658 =[];
@@ -151,10 +153,10 @@ class ReplenishSettingsController extends Controller
# Get Logged user Id
$userId = m3_user() !== '' ? strtoupper(m3_user()) : '' ;
// $userId = 'E1135818'; // Brad : E1135818 Malak : E2011812 ACOM_PDF
$ICM428M = DB::connection(config('m3.connection', 'pgsql'))->table('icm428m')
->where('R428US',$userId)
->where('R428STS','A')
->first();
$connection = config('m3.connection', 'pgsql');
$ICM428M = \Illuminate\Support\Facades\Schema::connection($connection)->hasTable('icm428m')
? DB::connection($connection)->table('icm428m')->where('R428US',$userId)->where('R428STS','A')->first()
: null;
$userCO = isset($ICM428M->R428CO) ? $ICM428M->R428CO : '';
$userPL = isset($ICM428M->R428PL) ? $ICM428M->R428PL : '';
@@ -8,7 +8,7 @@ use Config;
use Illuminate\Http\Request;
use Symfony\Component\HttpFoundation\Response;
use Modules\M3\Models\ICM160M;
use Helper;
use Modules\M3\Helpers\Helper;
class carrierMaintController extends Controller
@@ -14,24 +14,19 @@ class palletQtyController extends Controller
{
public static function index(Request $request) {
#$IC670M = DB::connection(config('m3.connection', 'pgsql'))->table('ic670m')->get();
#$power_user = DB::connection(config('m3.connection', 'pgsql'))->select("select R428PWRUSR, R428CO, R428PL, R428WH from ICM428M where R428US='".strtoUpper(m3_user())."'");
$power_user = DB::connection(config('m3.connection', 'pgsql'))->table('icm428m')
->select('R428PWRUSR','R428US','R428CO','R428PL','R428WH')
->where('R428US','=',strtoUpper(m3_user()))
->first();
$co = $power_user->R428CO;
$plant = $power_user->R428PL;
$whs = $power_user->R428WH;
$ICM709M = DB::connection(config('m3.connection', 'pgsql'))->table('icm709m')
->where('AT9CO','=',$co)
->where('AT9PLT','=',$plant)
->where('AT9WHS','=',$whs)
->get();
$IC670M = DB::connection(config('m3.connection', 'pgsql'))->select("select * from IC670M where WDCO='$co' and WDPL='$plant' and WDWHS='$whs'");
$connection = config('m3.connection', 'pgsql');
$power_user = (object) ['R428PWRUSR'=>'N','R428US'=>strtoUpper(m3_user()),'R428CO'=>'','R428PL'=>'','R428WH'=>''];
if (\Illuminate\Support\Facades\Schema::connection($connection)->hasTable('icm428m')) {
$power_user = DB::connection($connection)->table('icm428m')
->select('R428PWRUSR','R428US','R428CO','R428PL','R428WH')
->where('R428US','=',strtoUpper(m3_user()))->first() ?? $power_user;
}
$co=$power_user->R428CO; $plant=$power_user->R428PL; $whs=$power_user->R428WH;
$ICM709M = \Illuminate\Support\Facades\Schema::connection($connection)->hasTable('icm709m')
? DB::connection($connection)->table('icm709m')->where('AT9CO',$co)->where('AT9PLT',$plant)->where('AT9WHS',$whs)->get() : collect();
$IC670M = \Illuminate\Support\Facades\Schema::connection($connection)->hasTable('ic670m')
? DB::connection($connection)->table('ic670m')->where('WDCO',$co)->where('WDPL',$plant)->where('WDWHS',$whs)->get() : collect();
return view('m3::liberty-theme.pages.palletQty', compact('ICM709M','IC670M','power_user'));
}
//
@@ -14,28 +14,20 @@ class userControlController extends Controller
{
public static function index(Request $request) {
#$sqlstmt="select * from ICM428M";
#$ICM428M = DB::connection(config('m3.connection', 'pgsql'))->table('icm428m')->get();
$ICM428M = DB::connection(config('m3.connection', 'pgsql'))->table('icm428m')
->select('R428US','R428CO', 'R428WH')
->where('R428US','=',strtoUpper(m3_user()))
->first();
$co = $ICM428M->R428CO;
$whs = $ICM428M->R428WH;
$ICM428M = DB::connection(config('m3.connection', 'pgsql'))->select("SELECT * FROM ICM428M where R428CO='$co' and R428WH='$whs'");
#765 add DATE_PASSWORD_EXPIRES as DATE_EXPIRED, SET_PASSWORD_TO_EXPIRE as EXPIRED
$USER_INFO = DB::connection(config('m3.connection', 'pgsql'))->table('icm428m')->selectRaw('R428US as USERPRF, R428STS as STATUS, NULL as DATE_EXPIRED, NULL as EXPIRED')->get()->all();
#echo "<pre>"; var_dump($USER_INFO); echo "</pre>";
$power_user = DB::connection(config('m3.connection', 'pgsql'))->select("select R428PWRUSR, R428CO, R428PL, R428WH from ICM428M where R428US='".strtoUpper(m3_user())."'");
#765
# $expired_users = DB::connection(config('m3.connection', 'pgsql'))->select("SELECT USER_PROFILE FROM TABLE (SYSTOOLS.AUDIT_JOURNAL_CP () ) WHERE PASSWORD_EXPIRED = '*YES'");
# echo "<pre>"; print_r($expired_users); echo "</pre>";
$IC670M = DB::connection(config('m3.connection', 'pgsql'))->table('ic670m')->get();
$connection = config('m3.connection', 'pgsql');
$profile = null;
if (\Illuminate\Support\Facades\Schema::connection($connection)->hasTable('icm428m')) {
$profile = DB::connection($connection)->table('icm428m')->where('R428US',strtoUpper(m3_user()))->first();
}
$co=$profile->R428CO ?? ''; $whs=$profile->R428WH ?? '';
$ICM428M = \Illuminate\Support\Facades\Schema::connection($connection)->hasTable('icm428m')
? DB::connection($connection)->table('icm428m')->where('R428CO',$co)->where('R428WH',$whs)->get() : collect();
$USER_INFO = \Illuminate\Support\Facades\Schema::connection($connection)->hasTable('icm428m')
? DB::connection($connection)->table('icm428m')->selectRaw('R428US as USERPRF, R428STS as STATUS, NULL as DATE_EXPIRED, NULL as EXPIRED')->get()->all() : [];
$power_user = [(object)['R428PWRUSR'=>$profile->R428PWRUSR ?? 'N','R428CO'=>$co,'R428PL'=>$profile->R428PL ?? '','R428WH'=>$whs]];
$IC670M = \Illuminate\Support\Facades\Schema::connection($connection)->hasTable('ic670m')
? DB::connection($connection)->table('ic670m')->get() : collect();
return view('m3::liberty-theme.pages.userControl', compact('ICM428M','IC670M','power_user','USER_INFO'));
}
//
@@ -0,0 +1,26 @@
/* M3 integration inside the Core WMS shell. Core owns the global sidebar, topbar, typography and appearance. */
.m3-core-page{font-family:inherit;color:inherit;width:100%;max-width:1600px;margin:0 auto;padding:1.5rem}
.m3-core-header{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem;margin-bottom:1.5rem;padding:1.5rem;border:1px solid rgb(228 228 231);border-radius:1.5rem;background:linear-gradient(135deg,#020617,#0f172a 55%,#172554);color:#fff}
.m3-core-eyebrow{margin:0 0 .5rem;font-size:.75rem;font-weight:700;letter-spacing:.28em;color:#bfdbfe}
.m3-core-title{margin:0;font:inherit;font-size:2rem;font-weight:650;line-height:1.15;letter-spacing:-.025em;color:#fff}
.m3-core-context{margin:.5rem 0 0;color:#dbeafe}
.m3-core-actions{display:flex;gap:.5rem;flex-wrap:wrap}
.m3-core-breadcrumb{margin-bottom:1rem;color:rgb(82 82 91);font-size:.875rem}
.m3-core-content{color:rgb(24 24 27)}
.m3-core-content .container-fluid{padding:0}
.m3-core-content .panel,.m3-core-content .card,.m3-core-content .well{border:1px solid rgb(228 228 231);border-radius:1rem;background:#fff;box-shadow:0 1px 2px rgb(0 0 0/.04);overflow:hidden}
.m3-core-content .panel-heading,.m3-core-content .card-header{background:rgb(250 250 250);border-bottom:1px solid rgb(228 228 231);padding:.9rem 1rem;font-weight:600}
.m3-core-content table{color:inherit;background:transparent}
.m3-core-content .table>tbody>tr>td,.m3-core-content .table>tbody>tr>th,.m3-core-content .table>tfoot>tr>td,.m3-core-content .table>tfoot>tr>th,.m3-core-content .table>thead>tr>td,.m3-core-content .table>thead>tr>th{border-color:rgb(228 228 231)}
.m3-core-content input,.m3-core-content select,.m3-core-content textarea,.m3-core-content button{font-family:inherit}
.m3-core-alert{padding:1rem;border:1px solid rgb(254 202 202);border-radius:1rem;background:rgb(254 242 242);color:rgb(153 27 27);font-weight:600}
html.dark .m3-core-header{border-color:rgb(63 63 70);background:linear-gradient(135deg,#020617,#0f172a 55%,#172554)}
html.dark .m3-core-breadcrumb{color:rgb(161 161 170)}
html.dark .m3-core-content{color:rgb(244 244 245)}
html.dark .m3-core-content .panel,html.dark .m3-core-content .card,html.dark .m3-core-content .well{border-color:rgb(63 63 70);background:rgb(24 24 27)}
html.dark .m3-core-content .panel-heading,html.dark .m3-core-content .card-header{background:rgb(39 39 42);border-color:rgb(63 63 70);color:rgb(244 244 245)}
html.dark .m3-core-content .table{color:rgb(244 244 245)}
html.dark .m3-core-content .table>tbody>tr>td,html.dark .m3-core-content .table>tbody>tr>th,html.dark .m3-core-content .table>tfoot>tr>td,html.dark .m3-core-content .table>tfoot>tr>th,html.dark .m3-core-content .table>thead>tr>td,html.dark .m3-core-content .table>thead>tr>th{border-color:rgb(63 63 70)}
html.dark .m3-core-content input,html.dark .m3-core-content select,html.dark .m3-core-content textarea{background:rgb(39 39 42);border-color:rgb(82 82 91);color:rgb(244 244 245)}
html.dark .m3-core-alert{border-color:rgb(127 29 29);background:rgb(69 10 10);color:rgb(254 202 202)}
@media(max-width:768px){.m3-core-page{padding:1rem}.m3-core-header{padding:1.25rem}.m3-core-title{font-size:1.6rem}}
@@ -0,0 +1,26 @@
/* M3 integration inside the Core WMS shell. Core owns the global sidebar, topbar, typography and appearance. */
.m3-core-page{font-family:inherit;color:inherit;width:100%;max-width:1600px;margin:0 auto;padding:1.5rem}
.m3-core-header{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem;margin-bottom:1.5rem;padding:1.5rem;border:1px solid rgb(228 228 231);border-radius:1.5rem;background:linear-gradient(135deg,#020617,#0f172a 55%,#172554);color:#fff}
.m3-core-eyebrow{margin:0 0 .5rem;font-size:.75rem;font-weight:700;letter-spacing:.28em;color:#bfdbfe}
.m3-core-title{margin:0;font:inherit;font-size:2rem;font-weight:650;line-height:1.15;letter-spacing:-.025em;color:#fff}
.m3-core-context{margin:.5rem 0 0;color:#dbeafe}
.m3-core-actions{display:flex;gap:.5rem;flex-wrap:wrap}
.m3-core-breadcrumb{margin-bottom:1rem;color:rgb(82 82 91);font-size:.875rem}
.m3-core-content{color:rgb(24 24 27)}
.m3-core-content .container-fluid{padding:0}
.m3-core-content .panel,.m3-core-content .card,.m3-core-content .well{border:1px solid rgb(228 228 231);border-radius:1rem;background:#fff;box-shadow:0 1px 2px rgb(0 0 0/.04);overflow:hidden}
.m3-core-content .panel-heading,.m3-core-content .card-header{background:rgb(250 250 250);border-bottom:1px solid rgb(228 228 231);padding:.9rem 1rem;font-weight:600}
.m3-core-content table{color:inherit;background:transparent}
.m3-core-content .table>tbody>tr>td,.m3-core-content .table>tbody>tr>th,.m3-core-content .table>tfoot>tr>td,.m3-core-content .table>tfoot>tr>th,.m3-core-content .table>thead>tr>td,.m3-core-content .table>thead>tr>th{border-color:rgb(228 228 231)}
.m3-core-content input,.m3-core-content select,.m3-core-content textarea,.m3-core-content button{font-family:inherit}
.m3-core-alert{padding:1rem;border:1px solid rgb(254 202 202);border-radius:1rem;background:rgb(254 242 242);color:rgb(153 27 27);font-weight:600}
html.dark .m3-core-header{border-color:rgb(63 63 70);background:linear-gradient(135deg,#020617,#0f172a 55%,#172554)}
html.dark .m3-core-breadcrumb{color:rgb(161 161 170)}
html.dark .m3-core-content{color:rgb(244 244 245)}
html.dark .m3-core-content .panel,html.dark .m3-core-content .card,html.dark .m3-core-content .well{border-color:rgb(63 63 70);background:rgb(24 24 27)}
html.dark .m3-core-content .panel-heading,html.dark .m3-core-content .card-header{background:rgb(39 39 42);border-color:rgb(63 63 70);color:rgb(244 244 245)}
html.dark .m3-core-content .table{color:rgb(244 244 245)}
html.dark .m3-core-content .table>tbody>tr>td,html.dark .m3-core-content .table>tbody>tr>th,html.dark .m3-core-content .table>tfoot>tr>td,html.dark .m3-core-content .table>tfoot>tr>th,html.dark .m3-core-content .table>thead>tr>td,html.dark .m3-core-content .table>thead>tr>th{border-color:rgb(63 63 70)}
html.dark .m3-core-content input,html.dark .m3-core-content select,html.dark .m3-core-content textarea{background:rgb(39 39 42);border-color:rgb(82 82 91);color:rgb(244 244 245)}
html.dark .m3-core-alert{border-color:rgb(127 29 29);background:rgb(69 10 10);color:rgb(254 202 202)}
@media(max-width:768px){.m3-core-page{padding:1rem}.m3-core-header{padding:1.25rem}.m3-core-title{font-size:1.6rem}}
@@ -58,125 +58,35 @@
// dump($callingProgramPacking);
@endphp
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />
<meta name="description" content="" />
<meta name="author" content="" />
<meta name="csrf-token" content="{{ csrf_token() }}" />
<title>@yield('title') - {{ config('app.name', 'WMS') }}</title>
{{-- Use Core's favicon set so M3 keeps the same browser identity as WMS. --}}
<link rel="icon" href="{{ asset('favicons/favicon.ico') }}" sizes="any">
<link rel="icon" href="{{ asset('favicons/favicon.svg') }}" type="image/svg+xml">
<link rel="icon" type="image/png" sizes="32x32" href="{{ asset('favicons/favicon-32x32.png') }}">
<link rel="icon" type="image/png" sizes="192x192" href="{{ asset('favicons/favicon-192x192.png') }}">
<link rel="apple-touch-icon" sizes="180x180" href="{{ asset('favicons/apple-touch-icon.png') }}">
<link rel="manifest" href="{{ asset('favicons/site.webmanifest') }}">
<meta name="application-name" content="{{ config('app.name') }}">
<meta name="apple-mobile-web-app-title" content="{{ config('app.name') }}">
<meta name="msapplication-config" content="{{ asset('favicons/browserconfig.xml') }}">
{{-- Load the same locally managed font family used by Core. --}}
@fonts
<x-layouts.app :title="trim($__env->yieldContent('title', 'M3'))">
<div class="m3-core-page" data-m3-module>
@include('m3::liberty-theme.partials.styles')
<script src="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.3/js/all.min.js" crossorigin="anonymous"></script>
</head>
<body class="sb-nav-fixed">
@include('m3::liberty-theme.partials.top-navigation')
<div id="layoutSidenav">
@if ( !($pdfURL && $callingProgramPacking))
@include('m3::liberty-theme.partials.left-navigation')
@endif
<link href="{{ route('m3.assets', ['path' => 'liberty-theme/css/m3-core-shell.css']) }}" rel="stylesheet" />
<div id="layoutSidenav_content">
<main>
<div id="page-wrapper">
<div class="container-fluid">
<div class="row">
<div class="col-lg-12">
@yield('breadcrumb')
</div>
<div class="page-btn">
@yield('btn')
</div>
<!-- /.col-lg-12 -->
</div>
<!-- /.row -->
@if( $csr=='')
@yield('content')
@elseif( $csr=='Y' && $pdfURL)
@yield('content')
@else
{!! '<h1 class="text-center">403 - Unauthorized</h1>' !!}
@endif
<!-- /.container-fluid -->
</div>
</div>
<!-- /#page-wrapper -->
</main>
<footer class="py-4 bg-light mt-auto">
@include('m3::liberty-theme.partials.footer')
</footer>
<div class="m3-core-header">
<div>
<p class="m3-core-eyebrow">M3 INTEGRATION</p>
<h1 class="m3-core-title">@yield('title', 'M3')</h1>
@if($WDWNAM !== '')
<p class="m3-core-context">{{ $WDWNAM }}</p>
@endif
</div>
<div class="m3-core-actions">@yield('btn')</div>
</div>
@hasSection('breadcrumb')
<div class="m3-core-breadcrumb">@yield('breadcrumb')</div>
@endif
<section class="m3-core-content">
@if($csr === '' || ($csr === 'Y' && $pdfURL))
@yield('content')
@else
<div class="m3-core-alert">403 - Unauthorized</div>
@endif
</section>
@include('m3::liberty-theme.partials.scripts')
@yield('scripts')
</body>
<script>
$(document).ready(function() {
$("#R428DPWSel").on('change', function() {
var R428DPW = $(this).val();
var R428US = '{{ $loggedUser }}';
var currentWHS = $(this).find('option:selected').text();
// console.log(R428DPW);
// console.log(R428US);
var form_post2 = {
R428DPW : R428DPW,
R428US : R428US,
_token : '{{ csrf_token() }}'
};
// console.log(form_post2);
$.ajax({
url: "{{ route('m3.userprofileupdateajax') }}",
type: "POST",
data: form_post2,
success: function(response) {
if(response.success==true){
Swal.fire({
title: "Warehouse changed successfully",
text: "",
icon: "success",
confirmButtonColor: "#3085d6"
}).then((result) => {
if (result.isConfirmed) {
window.location.reload();
}
});
// Swal.fire('Warehouse changed successfully');
// $("#currentWHSPAN").html(currentWHS);
}
else{
Swal.fire('Warehouse change Failed');
}
},
error: function(error) {
// console.log(error);
// alert(error);
}
});
});
});
</script>
</html>
</div>
</x-layouts.app>
@@ -0,0 +1,24 @@
<nav class="m3-module-nav" aria-label="M3 navigation">
<a class="m3-module-nav-link {{ request()->routeIs('m3.index') ? 'is-active' : '' }}" href="{{ route('m3.index') }}"><i class="fas fa-gauge-high"></i><span>Dashboard</span></a>
@if($execUser !== 'Y')
@if($csr !== 'Y')
<a class="m3-module-nav-link {{ request()->routeIs('m3.replenishmentSettings.*') ? 'is-active' : '' }}" href="{{ route('m3.replenishmentSettings.index') }}"><i class="fas fa-arrows-rotate"></i><span>Replenishment</span></a>
<a class="m3-module-nav-link {{ request()->routeIs('m3.M3ErrorsDisplay.*') ? 'is-active' : '' }}" href="{{ route('m3.M3ErrorsDisplay.index') }}"><i class="fas fa-list-check"></i><span>Transactions</span></a>
@endif
<a class="m3-module-nav-link {{ request()->routeIs('m3.M3GetPDFFromCache.*') ? 'is-active' : '' }}" href="{{ route('m3.M3GetPDFFromCache.index') }}"><i class="fas fa-file-pdf"></i><span>Documents</span></a>
@if($csr !== 'Y')
<a class="m3-module-nav-link {{ request()->routeIs('m3.userControl') ? 'is-active' : '' }}" href="{{ route('m3.userControl') }}"><i class="fas fa-users-gear"></i><span>Users</span></a>
<a class="m3-module-nav-link {{ request()->routeIs('m3.palletQty') ? 'is-active' : '' }}" href="{{ route('m3.palletQty') }}"><i class="fas fa-boxes-stacked"></i><span>Part Data</span></a>
<a class="m3-module-nav-link {{ request()->routeIs('m3.M3Delivery') ? 'is-active' : '' }}" href="{{ route('m3.M3Delivery') }}"><i class="fas fa-truck"></i><span>Delivery</span></a>
<a class="m3-module-nav-link {{ request()->routeIs('m3.OrderLinesOfClosedOrder') ? 'is-active' : '' }}" href="{{ route('m3.OrderLinesOfClosedOrder') }}"><i class="fas fa-file-excel"></i><span>Closed Orders</span></a>
@if($power_users === 'Y' || $admin_users === 'Y')
<a class="m3-module-nav-link {{ request()->routeIs('m3.carrierMaint') ? 'is-active' : '' }}" href="{{ route('m3.carrierMaint') }}"><i class="fas fa-route"></i><span>Carriers</span></a>
<a class="m3-module-nav-link {{ request()->routeIs('m3.userPickingStats4') || request()->routeIs('m3.userPickingStats5') ? 'is-active' : '' }}" href="{{ route('m3.userPickingStats4') }}"><i class="fas fa-chart-line"></i><span>Efficiency</span></a>
<a class="m3-module-nav-link {{ request()->routeIs('m3.pendingClosure') ? 'is-active' : '' }}" href="{{ route('m3.pendingClosure') }}"><i class="fas fa-clock"></i><span>Pending Closure</span></a>
@endif
<a class="m3-module-nav-link {{ request()->routeIs('m3.ship-to.*') ? 'is-active' : '' }}" href="{{ route('m3.ship-to.index') }}"><i class="fas fa-warehouse"></i><span>Ship-to</span></a>
<a class="m3-module-nav-link {{ request()->routeIs('m3.execsummary') || request()->routeIs('m3.execsummaryline') ? 'is-active' : '' }}" href="{{ route('m3.execsummary') }}"><i class="fas fa-chart-column"></i><span>KPI</span></a>
<a class="m3-module-nav-link {{ request()->routeIs('m3.whsePerf*') ? 'is-active' : '' }}" href="{{ route('m3.whsePerf') }}"><i class="fas fa-chart-area"></i><span>OTTC</span></a>
@endif
@endif
</nav>
+19 -1
View File
@@ -231,7 +231,7 @@
</div>
@endif
<div class="wms-sidebar-group" data-wms-menu-group="integration-reporting">
<div class="wms-sidebar-group" data-wms-menu-group="integration-reporting" @if (request()->routeIs('m3.*')) data-wms-selected="true" data-wms-has-active="true" data-wms-menu-open="true" @endif>
<button type="button" class="wms-sidebar-heading wms-sidebar-heading-button" data-wms-menu-toggle
data-wms-sidebar-label aria-expanded="false">
<span class="wms-sidebar-heading-content">
@@ -248,6 +248,24 @@
<i class="fa-solid fa-cubes-stacked wms-sidebar-icon" aria-hidden="true"></i>
<span data-wms-sidebar-label>{{ __('M3') }}</span>
</a>
@if (request()->routeIs('m3.*'))
<div class="wms-m3-submenu space-y-1 border-l border-zinc-200/70 pl-3 dark:border-zinc-700/70" data-wms-sidebar-label>
<a href="{{ route('m3.index') }}" class="wms-sidebar-link wms-m3-submenu-link @if (request()->routeIs('m3.index')) is-active @endif"><i class="fa-solid fa-gauge-high wms-sidebar-icon" aria-hidden="true"></i><span>{{ __('Dashboard') }}</span></a>
@if (Route::has('m3.replenishmentSettings.index'))<a href="{{ route('m3.replenishmentSettings.index') }}" class="wms-sidebar-link wms-m3-submenu-link @if (request()->routeIs('m3.replenishmentSettings.*')) is-active @endif"><i class="fa-solid fa-sliders wms-sidebar-icon" aria-hidden="true"></i><span>{{ __('Replenishment Settings') }}</span></a>@endif
@if (Route::has('m3.M3ErrorsDisplay.index'))<a href="{{ route('m3.M3ErrorsDisplay.index') }}" class="wms-sidebar-link wms-m3-submenu-link @if (request()->routeIs('m3.M3ErrorsDisplay*')) is-active @endif"><i class="fa-solid fa-list-check wms-sidebar-icon" aria-hidden="true"></i><span>{{ __('Transaction Log') }}</span></a>@endif
@if (Route::has('m3.M3GetPDFFromCache.index'))<a href="{{ route('m3.M3GetPDFFromCache.index') }}" class="wms-sidebar-link wms-m3-submenu-link @if (request()->routeIs('m3.M3GetPDFFromCache*')) is-active @endif"><i class="fa-solid fa-box-archive wms-sidebar-icon" aria-hidden="true"></i><span>{{ __('Sentinel Doc Archive') }}</span></a>@endif
@if (Route::has('m3.userControl'))<a href="{{ route('m3.userControl') }}" class="wms-sidebar-link wms-m3-submenu-link @if (request()->routeIs('m3.userControl*')) is-active @endif"><i class="fa-solid fa-users-gear wms-sidebar-icon" aria-hidden="true"></i><span>{{ __('User Control') }}</span></a>@endif
@if (Route::has('m3.palletQty'))<a href="{{ route('m3.palletQty') }}" class="wms-sidebar-link wms-m3-submenu-link @if (request()->routeIs('m3.palletQty*')) is-active @endif"><i class="fa-solid fa-boxes-stacked wms-sidebar-icon" aria-hidden="true"></i><span>{{ __('ERP/TMS Part Data') }}</span></a>@endif
@if (Route::has('m3.M3Delivery'))<a href="{{ route('m3.M3Delivery') }}" class="wms-sidebar-link wms-m3-submenu-link @if (request()->routeIs('m3.M3Delivery*')) is-active @endif"><i class="fa-solid fa-truck-fast wms-sidebar-icon" aria-hidden="true"></i><span>{{ __('M3 Delivery Methods') }}</span></a>@endif
@if (Route::has('m3.OrderLinesOfClosedOrder'))<a href="{{ route('m3.OrderLinesOfClosedOrder') }}" class="wms-sidebar-link wms-m3-submenu-link @if (request()->routeIs('m3.OrderLinesOfClosedOrder')) is-active @endif"><i class="fa-solid fa-file-excel wms-sidebar-icon" aria-hidden="true"></i><span>{{ __('Closed Order Lines') }}</span></a>@endif
@if (Route::has('m3.carrierMaint'))<a href="{{ route('m3.carrierMaint') }}" class="wms-sidebar-link wms-m3-submenu-link @if (request()->routeIs('m3.carrierMaint*')) is-active @endif"><i class="fa-solid fa-location-dot wms-sidebar-icon" aria-hidden="true"></i><span>{{ __('Distribution WHS Addresses') }}</span></a>@endif
@if (Route::has('m3.userPickingStats4'))<a href="{{ route('m3.userPickingStats4') }}" class="wms-sidebar-link wms-m3-submenu-link @if (request()->routeIs('m3.userPickingStats4')) is-active @endif"><i class="fa-solid fa-chart-column wms-sidebar-icon" aria-hidden="true"></i><span>{{ __('KPI1 Bar') }}</span></a>@endif
@if (Route::has('m3.userPickingStats5'))<a href="{{ route('m3.userPickingStats5') }}" class="wms-sidebar-link wms-m3-submenu-link @if (request()->routeIs('m3.userPickingStats5')) is-active @endif"><i class="fa-solid fa-chart-line wms-sidebar-icon" aria-hidden="true"></i><span>{{ __('KPI1 Line') }}</span></a>@endif
@if (Route::has('m3.execsummary'))<a href="{{ route('m3.execsummary') }}" class="wms-sidebar-link wms-m3-submenu-link @if (request()->routeIs('m3.execsummary*')) is-active @endif"><i class="fa-solid fa-chart-simple wms-sidebar-icon" aria-hidden="true"></i><span>{{ __('OTTC') }}</span></a>@endif
@if (Route::has('sentinel-integration.index'))<a href="{{ route('sentinel-integration.index') }}" class="wms-sidebar-link wms-m3-submenu-link"><i class="fa-solid fa-satellite-dish wms-sidebar-icon" aria-hidden="true"></i><span>{{ __('Sentinel Home') }}</span></a>@endif
</div>
@endif
@endif
@if (Route::has('sentinel-integration.index'))