What were DJI drones spying on? What data did they capture?
I doubt anything was gleaned per se, but there was recognized a significant security risk here and the military discontinued the use of the produce for fear of integral malware which could give an unfriendly foreign power a readily available means to spy on other nations.

If you have large numbers of these drones in operation all over the United States and other nations of interest equipped with a GPS receiver, and they make use of a controller linked to a smartphone or other device with internet access, you now effectively have an unwitting air force of spy aircraft operating within your target's airspace where the information transmitted from the drone is readily accessible to intelligence agencies within China.  It probably cannot gather sensitive national security information, but these kinds of drones could be used to uncover non-classified government or military activities which could be of use to Chinese data analysts.  We use to do this on a regular basis using spy satellites over Russia and Eastern Europe and thinking several levels ahead, considering how interference with more mundane activities could have a real impact on.

Analysts in China can glean through users until they find ones doing something of interest.  People operating drones near military installations and ranges, etc can be useful and their video can be analyzed e.g. a kid in Las Vegas who lived near Nellis AFB may have his drone targeted when he/she flies it.  If the video captures images of the airbase, analysts can look at day to day differences for things like base maintenance, vehicles in the motorpool, movement of aircraft on the flightline, etc. and the data could be used to predict patterns of behavior, operations protocol, etc. that can be useful to military intelligence.  It's no wonder the US military stopped using DJI products for that reason.