fix: keep job card actions visible for corrective job cards

Corrective job cards regenerate required items but are exempt from the
transfer gate on the server; mirror that exemption in materials_ready.
This commit is contained in:
Mihir Kandoi
2026-08-11 13:18:55 +05:30
parent c95705dc64
commit e9533495fc

View File

@@ -597,7 +597,7 @@ frappe.ui.form.on("Job Card", {
const has_remaining_qty = doc.for_quantity + doc.process_loss_qty > doc.total_completed_qty;
const pending_transfer =
has_items && doc.items.some((row) => flt(row.transferred_qty) < flt(row.required_qty));
const materials_ready = doc.skip_material_transfer || !pending_transfer;
const materials_ready = doc.skip_material_transfer || doc.is_corrective_job_card || !pending_transfer;
let last_row = {};
const has_sub_ops_or_pending_qty = doc.sub_operations?.length || doc.pending_qty > 0;