fix conflict issue in sticker pdf service
Some checks failed
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (push) Successful in 12s
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (pull_request) Successful in 13s
Gemini PR Review / Gemini PR Review (pull_request) Successful in 20s
Laravel Pint / pint (pull_request) Failing after 2m32s
Laravel Larastan / larastan (pull_request) Failing after 5m36s
Some checks failed
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (push) Successful in 12s
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (pull_request) Successful in 13s
Gemini PR Review / Gemini PR Review (pull_request) Successful in 20s
Laravel Pint / pint (pull_request) Failing after 2m32s
Laravel Larastan / larastan (pull_request) Failing after 5m36s
This commit is contained in:
@@ -115,3 +115,5 @@ $sticker_id = $attributes->get('sticker_id');
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,19 +1,96 @@
|
||||
<x-filament-panels::page>
|
||||
|
||||
<h1 class="text-3xl font-bold mb-6">Welcome to CRI Digital Manufacturing IIOT</h1>
|
||||
<!-- HEADER -->
|
||||
<div class="mb-8">
|
||||
<h1 class="text-4xl font-bold tracking-tight">
|
||||
CRI Digital Manufacturing IIoT Platform
|
||||
</h1>
|
||||
<p class="text-lg text-gray-600 mt-2">
|
||||
Complete visibility, traceability, and control across your manufacturing operations
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="w-full overflow-hidden rounded-xl shadow">
|
||||
<img
|
||||
src="{{ asset('images/iiot-banner.jpg') }}"
|
||||
alt="CRI Digital Manufacturing IIoT"
|
||||
class="w-full h-64 object-cover"
|
||||
>
|
||||
</div>
|
||||
<!-- BANNER -->
|
||||
<div class="w-full overflow-hidden rounded-2xl shadow mb-10">
|
||||
<img
|
||||
src="{{ asset('images/iiot-banner.jpg') }}"
|
||||
alt="CRI Digital Manufacturing IIoT"
|
||||
class="w-full h-72 object-cover"
|
||||
>
|
||||
</div>
|
||||
|
||||
<p class="text-lg text-gray-600 mb-6">
|
||||
This dashboard provides real-time visibility into your manufacturing operations,
|
||||
enabling you to monitor production, track performance, and make data-driven decisions
|
||||
across plants and lines—all from one centralized platform.
|
||||
</p>
|
||||
<!-- INTRO -->
|
||||
<div class="max-w-4xl mb-10">
|
||||
<p class="text-lg text-gray-700 mb-4">
|
||||
CRI Digital Manufacturing IIoT is built to deliver
|
||||
<strong>end-to-end traceability, real-time insights, and operational transparency</strong>
|
||||
across plants, lines, and production processes.
|
||||
</p>
|
||||
|
||||
<p class="text-lg text-gray-700">
|
||||
The platform ensures <strong>right quality and on-time delivery</strong> by enabling
|
||||
complete tracking of materials, production orders, and finished goods—helping teams
|
||||
make faster, data-driven decisions with confidence.
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<!-- KEY PILLARS -->
|
||||
<div class="grid grid-cols-1 md:grid-cols-4 gap-6 mb-10">
|
||||
<div class="bg-white rounded-xl border p-6 shadow-sm">
|
||||
<h3 class="text-lg font-semibold mb-2">🔍 Traceability</h3>
|
||||
<p class="text-gray-600">
|
||||
Track materials, batches, and serials from input to dispatch.
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="bg-white rounded-xl border p-6 shadow-sm">
|
||||
<h3 class="text-lg font-semibold mb-2">✅ Quality Assurance</h3>
|
||||
<p class="text-gray-600">
|
||||
Validate process data and ensure first-time-right production.
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="bg-white rounded-xl border p-6 shadow-sm">
|
||||
<h3 class="text-lg font-semibold mb-2">⏱ On-Time Delivery</h3>
|
||||
<p class="text-gray-600">
|
||||
Identify delays early and meet production commitments.
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="bg-white rounded-xl border p-6 shadow-sm">
|
||||
<h3 class="text-lg font-semibold mb-2">📊 Real-Time Insights</h3>
|
||||
<p class="text-gray-600">
|
||||
Monitor performance and take quick corrective actions.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- SUPPORT -->
|
||||
<div class="bg-white rounded-xl border p-6 shadow-sm">
|
||||
<h2 class="text-2xl font-semibold mb-3">24×7 Support</h2>
|
||||
<p class="text-gray-700 mb-2">
|
||||
Our dedicated IIoT support team is available round-the-clock to ensure
|
||||
uninterrupted operations and quick issue resolution.
|
||||
</p>
|
||||
<p class="text-lg font-medium text-gray-900">
|
||||
📞 Support Contact: <span class="font-semibold">+91 8925899458 / +91 8925899459</span>
|
||||
</p>
|
||||
{{-- <p class="text-lg font-medium text-gray-900">
|
||||
📞 Technical Support Contact: <span class="font-semibold">9952468104 / 9100832269</span>
|
||||
</p> --}}
|
||||
</div>
|
||||
|
||||
<!-- TEAM -->
|
||||
<div class="bg-white rounded-xl border p-6 shadow-sm">
|
||||
<h2 class="text-2xl font-semibold mb-4">Our Team</h2>
|
||||
<div class="grid grid-cols-2 md:grid-cols-3 gap-4 text-gray-700">
|
||||
<div class="flex items-center gap-2">👤 Jothikumar</div>
|
||||
<div class="flex items-center gap-2">👤 Dhanabalan</div>
|
||||
<div class="flex items-center gap-2">👤 Shibu</div>
|
||||
<div class="flex items-center gap-2">👤 Ranjith</div>
|
||||
<div class="flex items-center gap-2">👤 Srimathi</div>
|
||||
<div class="flex items-center gap-2">👤 Gokul</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</x-filament-panels::page>
|
||||
|
||||
@@ -67,3 +67,29 @@ window.addEventListener('open-stickers-sequence', async (event) => {
|
||||
});
|
||||
</script>
|
||||
|
||||
<script>
|
||||
window.addEventListener('open-sticker-pdf', event => {
|
||||
|
||||
console.log('PDF event:', event.detail);
|
||||
|
||||
let url = null;
|
||||
|
||||
// Livewire v3 wraps payload in array
|
||||
if (Array.isArray(event.detail)) {
|
||||
url = event.detail[0]?.url;
|
||||
}
|
||||
|
||||
// fallback (if direct object comes)
|
||||
else if (event.detail?.url) {
|
||||
url = event.detail.url;
|
||||
}
|
||||
|
||||
if (url) {
|
||||
window.open(url, '_blank');
|
||||
} else {
|
||||
console.error('PDF URL missing', event.detail);
|
||||
}
|
||||
|
||||
});
|
||||
</script>
|
||||
|
||||
|
||||
@@ -64,88 +64,58 @@ document.addEventListener('DOMContentLoaded', function () {
|
||||
});
|
||||
|
||||
|
||||
// var calendar = new FullCalendar.Calendar(calendarEl, {
|
||||
// initialView: 'dayGridMonth',
|
||||
// height: 600,
|
||||
// showNonCurrentDates: true,
|
||||
// function updateWorkingDays(date) {
|
||||
// let totalDays = new Date(
|
||||
// date.getFullYear(),
|
||||
// date.getMonth()+1,
|
||||
// 0
|
||||
// ).getDate();
|
||||
|
||||
// dateClick: function(info) {
|
||||
// let workingDays = totalDays - selectedDates.length;
|
||||
// // document.querySelector('input[name="working_days"]').value = workingDays;
|
||||
|
||||
// let viewMonth = calendar.view.currentStart.getMonth();
|
||||
// let clickedMonth = info.date.getMonth();
|
||||
// const input = document.querySelector('#working_days');
|
||||
|
||||
// // let month = info.date.getMonth() + 1; // JS month: 0-11 → 1-12
|
||||
// // let year = info.date.getFullYear();
|
||||
// input.value = workingDays;
|
||||
|
||||
// if (viewMonth != clickedMonth) {
|
||||
// return; // Ignore next/prev month dates
|
||||
// }
|
||||
// input.dispatchEvent(new Event('input'));
|
||||
|
||||
// let dateStr = info.dateStr;
|
||||
// const monthInput = document.querySelector('#month');
|
||||
// monthInput.value = date.getMonth() + 1; // 1–12 month number
|
||||
// monthInput.dispatchEvent(new Event('input'));
|
||||
|
||||
// if (selectedDates.includes(dateStr)) {
|
||||
// selectedDates = selectedDates.filter(d => d !== dateStr);
|
||||
// const yearInput = document.querySelector('#year');
|
||||
// yearInput.value = date.getFullYear();
|
||||
// yearInput.dispatchEvent(new Event('input'));
|
||||
|
||||
// calendar.getEvents().forEach(event => {
|
||||
// if (event.startStr == dateStr) {
|
||||
// event.remove();
|
||||
// }
|
||||
// });
|
||||
// const selectedDatesInput = document.querySelector('#selected_dates');
|
||||
// selectedDatesInput.value = selectedDates.join(',');
|
||||
// selectedDatesInput.dispatchEvent(new Event('input'));
|
||||
|
||||
// } else {
|
||||
// selectedDates.push(dateStr);
|
||||
|
||||
// calendar.addEvent({
|
||||
// start: dateStr,
|
||||
// display: 'background',
|
||||
// color: '#f03f17'
|
||||
// });
|
||||
// }
|
||||
|
||||
// updateWorkingDays(info.date);
|
||||
// }
|
||||
// });
|
||||
|
||||
// yearSelect.addEventListener('change', function () {
|
||||
// let year = this.value;
|
||||
// if (!year) return;
|
||||
|
||||
// let currentDate = calendar.getDate();
|
||||
// let newDate = new Date(year, currentDate.getMonth(), 1);
|
||||
|
||||
// calendar.gotoDate(newDate);
|
||||
// });
|
||||
// }
|
||||
|
||||
function updateWorkingDays(date) {
|
||||
let totalDays = new Date(
|
||||
date.getFullYear(),
|
||||
date.getMonth()+1,
|
||||
date.getMonth() + 1,
|
||||
0
|
||||
).getDate();
|
||||
|
||||
let workingDays = totalDays - selectedDates.length;
|
||||
// document.querySelector('input[name="working_days"]').value = workingDays;
|
||||
|
||||
const input = document.querySelector('#working_days');
|
||||
|
||||
input.value = workingDays;
|
||||
|
||||
input.dispatchEvent(new Event('input'));
|
||||
|
||||
const monthInput = document.querySelector('#month');
|
||||
monthInput.value = date.getMonth() + 1; // 1–12 month number
|
||||
monthInput.dispatchEvent(new Event('input'));
|
||||
|
||||
const yearInput = document.querySelector('#year');
|
||||
yearInput.value = date.getFullYear();
|
||||
yearInput.dispatchEvent(new Event('input'));
|
||||
|
||||
const selectedDatesInput = document.querySelector('#selected_dates');
|
||||
selectedDatesInput.value = selectedDates.join(',');
|
||||
selectedDatesInput.dispatchEvent(new Event('input'));
|
||||
// Set values only
|
||||
document.querySelector('#working_days').value = workingDays;
|
||||
document.querySelector('#month').value = date.getMonth() + 1;
|
||||
document.querySelector('#year').value = date.getFullYear();
|
||||
document.querySelector('#selected_dates').value = selectedDates.join(',');
|
||||
|
||||
// Trigger only ONE update (important)
|
||||
document
|
||||
.querySelector('#selected_dates')
|
||||
.dispatchEvent(new Event('input'));
|
||||
}
|
||||
|
||||
|
||||
calendar.render();
|
||||
});
|
||||
</script>
|
||||
|
||||
@@ -4,17 +4,6 @@
|
||||
</h2>
|
||||
<div class="overflow-x-auto rounded-lg shadow">
|
||||
<table class="w-full divide-y divide-gray-200 text-sm text-center">
|
||||
{{-- <thead class="bg-gray-100 text-s font-semibold uppercase text-gray-700">
|
||||
<tr>
|
||||
<th class="border px-4 py-2">No</th>
|
||||
<th class="border px-4 py-2">Created Datetime</th>
|
||||
<th class="border px-4 py-2 whitespace-nowrap">Created By</th>
|
||||
<th class="border px-4 py-2 whitespace-nowrap">Plant</th>
|
||||
<th class="border px-4 py-2">Line</th>
|
||||
<th class="border px-4 py-2 whitespace-nowrap">Item Code</th>
|
||||
<th class="border px-4 py-2">Production Plan Dates</th>
|
||||
</tr>
|
||||
</thead> --}}
|
||||
<thead class="bg-gray-100 text-s font-semibold uppercase text-gray-700">
|
||||
<tr>
|
||||
<th class="border px-4 py-2" rowspan="3">No</th>
|
||||
@@ -22,21 +11,29 @@
|
||||
<th class="border px-4 py-2 whitespace-nowrap" rowspan="3">Line</th>
|
||||
<th class="border px-4 py-2 whitespace-nowrap" rowspan="3">Item Code</th>
|
||||
|
||||
<th class="border px-4 py-2 whitespace-nowrap" colspan="{{ count($dates) * 2 }}" class="text-center">
|
||||
<th class="border px-4 py-2 whitespace-nowrap" colspan="{{ count($dates) * 3 }}" class="text-center">
|
||||
Production Plan Dates
|
||||
</th>
|
||||
</tr>
|
||||
<tr>
|
||||
@foreach($dates as $date)
|
||||
<th colspan="2" class="text-center">
|
||||
{{-- <th colspan="3" class="text-center">
|
||||
{{ $date }}
|
||||
</th> --}}
|
||||
<th colspan="3" class="text-center border-r-4 border-gray-400">
|
||||
{{ $date }}
|
||||
</th>
|
||||
@endforeach
|
||||
</tr>
|
||||
<tr>
|
||||
@foreach($dates as $date)
|
||||
<th class="border px-4 py-2 whitespace-nowrap">Line Capacity</th>
|
||||
<th class="border px-4 py-2 whitespace-nowrap">Target Plan</th>
|
||||
<th class="border px-4 py-2 whitespace-nowrap">Produced Quantity</th>
|
||||
<th class="border px-4 py-2 whitespace-nowrap border-r-4 border-gray-400">
|
||||
Produced Quantity
|
||||
</th>
|
||||
|
||||
{{-- <th class="border px-4 py-2 whitespace-nowrap">Produced Quantity</th> --}}
|
||||
@endforeach
|
||||
</tr>
|
||||
</thead>
|
||||
@@ -58,8 +55,12 @@
|
||||
@if(in_array($date, $leaveDates))
|
||||
<td class="border px-4 py-2 whitespace-nowrap">-</td>
|
||||
<td class="border px-4 py-2 whitespace-nowrap">-</td>
|
||||
<td class="border px-4 py-2 whitespace-nowrap">-</td>
|
||||
@else
|
||||
{{-- <td class="border px-4 py-2 whitespace-nowrap">{{ $record['daily_target'] ?? '-' }}</td> --}}
|
||||
<td class="border px-4 py-2 whitespace-nowrap">
|
||||
{{ $record['daily_line_capacity'][$date] ?? '-' }}
|
||||
</td>
|
||||
<td class="border px-4 py-2 whitespace-nowrap">
|
||||
{{ $record['daily_target_dynamic'][$date] ?? '-' }}
|
||||
</td>
|
||||
@@ -72,7 +73,7 @@
|
||||
</tr>
|
||||
@empty
|
||||
<tr>
|
||||
<td colspan="9" class="px-4 py-4 text-center text-gray-500">
|
||||
<td colspan="10" class="px-4 py-4 text-center text-gray-500">
|
||||
No production plan data found.
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
<thead class="bg-gray-100 text-xs">
|
||||
<tr>
|
||||
<th class="border p-2">No</th>
|
||||
<th class="border p-2">Sticker ID</th>
|
||||
{{-- <th class="border p-2">Sticker ID</th> --}}
|
||||
<th class="border p-2">Production Order</th>
|
||||
<th class="border p-2">Serial Number</th>
|
||||
<th class="border p-2">Status</th>
|
||||
@@ -24,7 +24,7 @@
|
||||
@forelse($records as $index => $record)
|
||||
<tr>
|
||||
<td class="border p-2 text-center">{{ $index + 1 }}</td>
|
||||
<td class="border p-2 text-center">{{ $record->sticker_id }}</td>
|
||||
{{-- <td class="border p-2 text-center">{{ $record->sticker_id }}</td> --}}
|
||||
<td class="border p-2 text-center">{{ $refNumber }}</td>
|
||||
<td class="border p-2 text-center">{{ $record['serial_number'] }}</td>
|
||||
<td class="border p-2 text-center">{{ $record->status }}</td>
|
||||
@@ -32,7 +32,7 @@
|
||||
</tr>
|
||||
@empty
|
||||
<tr>
|
||||
<td class="border p-2 text-center" colspan="6">No serial numbers found.</td>
|
||||
<td class="border p-2 text-center" colspan="5">No serial numbers found.</td>
|
||||
</tr>
|
||||
@endforelse
|
||||
</tbody>
|
||||
|
||||
Reference in New Issue
Block a user