updates to M3 module
This commit is contained in:
@@ -97,7 +97,9 @@ class userPickingStats4 extends Controller
|
||||
|
||||
#echo "$sqlstmt<br>";
|
||||
|
||||
$lbpf1 = DB::connection(config('m3.connection', 'pgsql'))->select($sqlstmt);
|
||||
$lbpf1 = $schema->hasTable('lbpf')
|
||||
? DB::connection(config('m3.connection', 'pgsql'))->select($sqlstmt)
|
||||
: [];
|
||||
|
||||
$lbpf = 0;
|
||||
foreach ($lbpf1 as $key => $val) {
|
||||
@@ -107,7 +109,7 @@ class userPickingStats4 extends Controller
|
||||
$sql = "select * from perfstat where dt='$starting' and a5pickcomu='$user' ";
|
||||
#@dd($sql);
|
||||
|
||||
if (isset($request->dates) || isset($request->user)) {
|
||||
if ((isset($request->dates) || isset($request->user)) && $schema->hasTable('perfstat')) {
|
||||
$statistic4 = DB::connection(config('m3.connection', 'pgsql'))->select($sql);
|
||||
} else {
|
||||
$statistic4 = array();
|
||||
@@ -306,7 +308,7 @@ class userPickingStats4 extends Controller
|
||||
#error_log("Time required to xyz: " . $duration . "\n", 3, "/temp/v4.log");
|
||||
|
||||
return view(
|
||||
'liberty-theme.pages.userPickingStats4',
|
||||
'm3::liberty-theme.pages.userPickingStats4',
|
||||
compact('statistic4', 'starting', 'user', 'user_array', 'monitor_array', 'totals_array', 'perf_array', 'request', 'no_data')
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user