Set correct parentid on import
When importing over an existing page the parentid is set to the latest
rev id of the page, which makes the size diff in history unusable.
The import constructs the Revision object without a parentid and than
Revision::getPreviousRevisionId is using the page_latest field to
propagate the missing parentid.
Avoid this bad propagate by select the previous revision id depending on
timestamp before construct of the Revision object.
Bug: T114806
Change-Id: Iee44d5a74de459f733ea62373cdbe9911e77083f