From 7d4de6792f49ea239bd09798c0c844517584d835 Mon Sep 17 00:00:00 2001 From: vadivelJ96 Date: Sat, 21 Dec 2024 14:39:13 +0530 Subject: [PATCH] stock module-2 vadivel J 21-12-2024 --- app/Controllers/StockController.php | 15 +-- app/Views/drierMachineDetails.php | 27 +++-- app/Views/incomingSilicaSandDetails.php | 126 +++++++++++++----------- 3 files changed, 87 insertions(+), 81 deletions(-) diff --git a/app/Controllers/StockController.php b/app/Controllers/StockController.php index 952f5bc0..aa61707d 100644 --- a/app/Controllers/StockController.php +++ b/app/Controllers/StockController.php @@ -413,7 +413,7 @@ class StockController extends BaseController '_140' => $postData['140Mm'], '_200' => $postData['200Mm'], '_300' => $postData['300Mm'], - 'pan' => $postData['pan'], + 'pan' => $postData['pan'], 'total' => $postData['total'], 'plus20loss' => $postData['plus20Loss'], 'plus30Loss' => $postData['plus30Loss'], @@ -1231,19 +1231,6 @@ class StockController extends BaseController ->orderBy('date','asc') ->findAll(); - if (!count($data['drierDetails'])) { - //insert empty data - $tempInsert = []; - foreach ($monthData as $key => $value) { - array_push($tempInsert, ['date' => $value['database']]); - } - $this->drierMachineDetails_model->insertBatch($tempInsert); - - $data['drierDetails'] = $this->drierMachineDetails_model->where('date >=', $data['startDate']) - ->where('date <=', $data['endDate']) - ->orderBy('date','asc') - ->findAll(); - } $data['datefordropdown'] = $currentMonth; diff --git a/app/Views/drierMachineDetails.php b/app/Views/drierMachineDetails.php index 871b2181..96d7adc9 100644 --- a/app/Views/drierMachineDetails.php +++ b/app/Views/drierMachineDetails.php @@ -271,8 +271,11 @@ $datefordropdown = format_date($datefordropdown, 0, 'M-Y'); - + + + + - + + + +

+
+

No Drier machine details present for this month..!!

+
+ + + + +
@@ -779,9 +793,6 @@ $datefordropdown = format_date($datefordropdown, 0, 'M-Y'); if (qtyPerHrs && qtyPerHrs != NaN && qtyPerHrs != Infinity) tr.find('td:eq(11)').text(qtyPerHrs.toFixed(3)); - - - } } @@ -907,12 +918,12 @@ $datefordropdown = format_date($datefordropdown, 0, 'M-Y'); $('#drierTable').find('tbody tr').each(function() { const rowCells = $(this).find('td'); - let tableDate = rowCells.eq(0).text(); // prints every date in the month from 1 to 30 . + let tableDate = rowCells.eq(0).text(); let result = checkDateRange(fromDate,toDate,tableDate); if (result) { - $(this).show(); // Show the row if the date is within range + $(this).show(); } else { - $(this).hide(); // Hide the row if the date is out of range + $(this).hide(); } }); diff --git a/app/Views/incomingSilicaSandDetails.php b/app/Views/incomingSilicaSandDetails.php index f8eb9b83..1070b34b 100644 --- a/app/Views/incomingSilicaSandDetails.php +++ b/app/Views/incomingSilicaSandDetails.php @@ -370,7 +370,7 @@ - + @@ -715,11 +715,11 @@ - + 10 2.0 2000 - + 5 @@ -727,7 +727,7 @@ 20 0.85 0850 - + 10 @@ -735,7 +735,7 @@ 30 0.60 0600 - + 20 @@ -743,7 +743,7 @@ 40 0.42 0425 - + 30 @@ -751,7 +751,7 @@ 50 0.30 0300 - + 40 @@ -760,7 +760,7 @@ 70 0.21 0212 - + 50 @@ -768,7 +768,7 @@ 100 0.15 0150 - + 70 @@ -776,7 +776,7 @@ 140 0.106 0106 - + 100 @@ -784,7 +784,7 @@ 200 0.075 0075 - + 140 @@ -792,7 +792,7 @@ 300 0.053 0053 - + 200 @@ -801,7 +801,7 @@ PAN PAN - + 300 @@ -1298,60 +1298,68 @@