The two 20k pots are the treble and bass tone controls. The B500k is the volume pot and the MN500k is the pickup blend pot.
Both pickups get wired to the blend pot.
Here's a SD diagram for a passive version, but the wiring for the blend pot should be the same.
https://docs.google.com/gview?embedd...1V_1T_1Bld.pdf.
You can attach the ground wires to the back of the blend pot if you wish, as it often makes it easier (though looking at pictures, it might not have a metal back, in which case, solder the grounds to the back of the volume pot). The hot wire of the P bass goes to the centre tag of the row of 3 tags nearest the shaft, the J-bass hot wire goes to the centre tag of the row of 3 tags furthest away from the shaft (which hopefully means that you turn it forwards/clockwise for the P-Bass and backwards/anti-clockwise for the J-bass). If it ends up being the reverse, then you can either live with it or swap the two connections over.
I'd twist the two J-bass pup wires together, as it does reduce the amount of noise picked up by the leads, plus it looks neater.