The actual law language says labels must include “…the date on which the food product was packaged, the net quantity of the food product…”
I’m not sure if the law is referring to net weight, or if you could simply put the number of cookies on the label (because of “net quantity”). But you can’t go wrong if you just put the net weight. As far as I know, it doesn’t matter how the info gets on the label, as long as it’s on there. So you could actually write the weight of the batch on the label when you package it. However, as a cookie maker myself, I’d say that if you are using a standard recipe and weighing out the ingredients as you make it, and using a portion scoop for consistent sizing of cookies, your final bagged weight should be pretty consistent and predictable.
As for the “produced on” date, it sounds like it’s really just the day you bag your cookies.
The above is based on what I’ve seen done before, and some of it is intuition. There are actually “labeling specialists” out there. If you try contacting health departments and can find one, they could give you more concrete answers.