The first total is a unit cost. A periodic count does not price each part as it leaves the shelf. Instead, it looks at the whole period at once. The OpenStax worked example explains that, for the weighted-average method, "considering the entire period, the weighted-average cost is computed by dividing total cost of goods available for sale ($16,155) by the total number of available units (585) to get the average cost of $27.62."
In practice, "goods available for sale" means everything you had to work with during the period: the parts already on hand when the period started plus everything bought during it. The dollar total covers all of that cost, and the unit total covers every unit in that same pool. Dividing one by the other gives a single average that applies to every part of that type, regardless of when it arrived.
This matters for a small shop because the average smooths out price changes. If a fitting cost one amount in January and a higher amount in March, the periodic average does not ask which specific unit went into which job. The result is one number you can apply to the count, which is exactly what the rest of the calculation needs.
The first total, then, is not a count of anything on a shelf. Keep the two inputs, $16,155 and 585, written down next to the result. You will need both again when you check the other totals.
It also helps to be clear about what goes into the pool. Opening stock, purchases during the period, and any other additions that increased the cost of parts on hand all belong in the dollar total. The unit total has to match that same set of parts. If the dollar side includes a purchase that the unit side leaves out, or the reverse, the average is off before any counting begins, and every later figure inherits the error.