I'm pretty certain this isn't a "bug" and the locked items intentionally show up there. You're more than welcome to ask for them to change it in the Suggestions & Ideas forum (I believe there's a thread there already). I personally like that they show up, so I don't lose any precious gifts between purchasing them and sending them out. Though, it'd be nice if someplace explained more thoroughly where the lock does and does not work - Ariel and Amber have been working on this kind of thing.
When you use an item (from your inventory, through the lab, gift center, etc.) it's probably set up to take the first copy that was added to your inventory, which is why the locked one was used over the unlocked one.