Reset lengths in models
Improved post code generator