Topic: Manufacturing dashboard issue

I'm not sure this is a bug, Top 10 Manufactured Items in fiscal year just confuses me on it's presents.

Once I create a work order then manufacturing dashboard shows:
_________________________________________________
|     Items      |           Amount         |          Quantity        |
|-------------------------------------------------------------------|
|AP Surf Set    |                    366.00  |                        1.00 |
|-------------------------------------------------------------------|

After item is sold  the table shows

_________________________________________________
|     Items      |           Amount         |          Quantity        |
|-------------------------------------------------------------------|
|AP Surf Set    |                        0.00  |                        0.00 |
|-------------------------------------------------------------------|

1. Does this widget just present on hand manufactured items ?
2. Should it be changed to all manufactured items includes sold item?

If 1 : this does not make sense much
If 2 : Line 275 of dashboard.inc need to change to $sql .= "AND s.mb_flag='M' AND m.qty > 0 ";

Phuong

Re: Manufacturing dashboard issue

Of course it should. Will fix this later. Thanks for detecting this.

Joe

Re: Manufacturing dashboard issue

Fixed. Committed to Repo.

/Joe

Re: Manufacturing dashboard issue

Does this account for returns / rejects where negative qty will get lost?

Re: Manufacturing dashboard issue

No, I guess not. We will have to replace the line with:

$sql .= "AND s.mb_flag='M' AND m.qty > 0 AND m.type <> ".CUSTCREDIT." ";

Right?

Joe

Re: Manufacturing dashboard issue

Should it not be:

$sql .= " AND s.mb_flag='M' AND (
                     (m.qty > 0 AND m.type <> " . CUSTCREDIT . ") OR 
                     (m.qty < 0 AND m.type = " . CUSTCREDIT . ")
                   )" ;

Re: Manufacturing dashboard issue

No, I guess it should just be:

$sql .= "AND s.mb_flag='M' AND m.type <> ".ST_CUSTDELIVERY." AND m.type <> ".ST_CUSTCREDIT." ";

Right? We are only interested in the produced numbers.

/Joe

8 (edited by notrinos 11/07/2017 02:18:08 pm)

Re: Manufacturing dashboard issue

Which transaction can make m.qty < 0 AND m.type = " .ST_ CUSTCREDIT . " ? @apmuthu

seems $sql .= "AND s.mb_flag='M' AND m.qty > 0 AND m.type <> ".ST_CUSTCREDIT." "; is working.

Phuong

Re: Manufacturing dashboard issue

@notrinos, Well

Look at my explanation in my former post. We are only interested in produced items (minus ev. disassemblies).
All deliveries and credits are of no interest for us. Isn't that right?

$sql .= "AND s.mb_flag='M' AND m.type <> ".ST_CUSTDELIVERY." AND m.type <> ".ST_CUSTCREDIT." ";

I have double checked this and it works.

I will rerun a commit  now.

/Joe

Re: Manufacturing dashboard issue

No @Joe, what about location transfer ?

Phuong

Re: Manufacturing dashboard issue

It should be ok to make location transfer. It will be included with plus and minus. Remember it is a total of all locations.

/Joe

Re: Manufacturing dashboard issue

And even location adjustments can cause the wrong statistics

Phuong

Re: Manufacturing dashboard issue

Not much. It will be added if it is a positive adjustment and subtracted if it is a negative adjustment.

I guess we have taken care of all options now, right? smile

/Joe

Re: Manufacturing dashboard issue

As you mentioned we are only interested in the produced numbers.
I think the flowing is ok :

$sql .= "AND s.mb_flag='M' AND m.type = ".ST_WORKORDER."  ";

Phuong

Re: Manufacturing dashboard issue

Ah @notrinos, you are persistent smile

As you said yourself, what about Item Adjustments (ST_INVADJUST) should be included.

Just to eliminate misunderstandings it is easier to just exclude ST_CUSTDELIVERY and ST_CUSTCREDIT.

So we have committed this as a rerun.

But thanks for the discussion. It is a refreshment to do a little thinking smile

/Joe