Payment logs added. A lot of fix in models and scripts