Make the SaleItem replication for batches an api

The logic for replicating at another place so, instead of duplicating a
"complicated" logic, make it an api and add tests for it.

Change-Id: I6a045057feb04d12b970017efca03b6eb145943a