Frappe Cloud Support Partners Foundation Frappe School

Incomplete Job Card Submission. (Garments)

Hi there,

We are in a scenario under garments manufacturing, Let say we got an order 1000 units of a particular SKU, as an SOP we will be manufacturing 10% extra, that i.e 1100 units as work order qty.

Manufacturing data will be entered operation wise and material transfer will be done on Job Card.

Cutting, Making, Washing, Finishing and Packing, (Sequential operations).

Cutting will be done for 1100 and 1050 will be available at packing level.

50pc raw material is ideally damaged and will be considered as wastage.

Now ERPnext is not allowing me submit job card with AN actual qty i.e
Cutting: 1100 (Successfully submitted)
Making: 1080 (Partial Qty, not allowed to submit)

Paking: 1050 (Partial Qty, not allowed to submit)

Technically, on every job finalized qties will be lower than previous operation.

So my question is how to deal with this situation, how do I complete the work with adjusted/finalized qty.

Do you have a custom app, and your own fork of erpnext code ?

This manufacturing module is almost unusable as-is for real world scenarios… it is like it has been built for the single most simplest use-case ever.

There is no ‘manual’ way to force complete a Job Card / Work Order, all logic is based on comparing quantities, which is so flawed by design…

I have fought a lot with all these non-sense validations…
I can share some customizations we did if you are interested.

One quick suggestion would be to consider the Job Card’s ‘Qty to Manufacture’ as the qty produced, so you update it to be the same value as the ‘For Qty’ submitted on the Stock Entry ‘Material Transfer for Manufacture’. You can even update it prior to creating material transfer.
So basically these 3 quantities must be equals to submit a Job Card:

  • Job Card - Qty to Manufacture
  • Stock Entry ‘Material Transfer for Manufacture’ - For Quantity
  • Job Card - Completed Qty (Sum of Time logs)

What we did as customization is to show this dialog on submit of Job Card.
We capture the Completed Qty and have some logic to update Qty and Required Items of next Job Cards.

1 Like

@guimorin thanks for the quick suggestion, This is similar to what we were thinking.

Could you let me know how are you managing wastages during these job cards ? Like if we are reducing qty to manufacture then ideally there is wastage and should be part of the system to balance out overall raw materials.

can you share the solution at code/configuration detail level? thanks.

1 Like

@guimorin what calculations are you making behind
Recalculate Required Items of next Job cards?

We ask this question when updating the ‘For Quantity’ in the Stock Entry ‘Material Transfer for Manufacture’


Yes -> Recalculate Raw Materials qty based on the new For Quantity
No -> Raw Materials qty remain as-is

So for example you had 100 qty to produce, but only produced 90:

  • Job Card ‘Qty to Manufacture’ is 100
  • Create Material Transfer
  • Update ‘For Quantity’ in Stock Entry to be 90
  • Our custom dialog question pops-up, we answer NO, so the system doesn’t recalculate the Items for a qty of 90, they remain for a qty of 100
  • Submit Stock Entry
  • Back in Job Card, update ‘Qty to Manufacture’ to 90, Qty Completed to 90 and Submit the Job Card

We recalculate raw materials qty based on the new qty to produce.

Here is the code handling both checkboxes on submit of Job Card:

  • update_next_job_card_qty_ggc
  • scale_next_job_card_items_ggc