That spring fits in the slot in the bottom piece in the parts picture. The long rivet holds both pieces to the tank at the bottom of the filler opening, with the spring keeping upward torsion on the lever that engages the base of the fuel cap.
It's kind of a trick to keep that little spring in place while threading the pin through, then orienting everything to match while guiding the pin all the way home, but it can be done. I like to use long screws (Hondaman's) since they are straight and easier to fasten. A magnet also helps to hold that little bugger still.
I believe the spring orientation will have both cut ends of the spring facing the rider when installed, slightly compressed. If you can push the lever only down, it is correct. One end of the spring will be digging in to the tank.
All the best,
Shane