In energy harvesting wireless sensor networks (EH-WSNs), maximizing the data collection throughput is one of the most challenging issues. In this paper, we consider the problem of data collection on a pre-specified path using a mobile sink which has a fixed-mobility pattern. As a generalization of the previous works, we propose an optimization model for the problem which incorporates the effective and heterogeneous duration of sensors' transmission in each time slot. To improve the network throughput, a simple condition is proposed which determines the maximum number of available time slots to each sensor node. Accordingly, the proposed condition specifies the constant velocity of the mobile sink. The NP-Hardness of the problem under the proposed condition is proved and an online centralized algorithm with less complexity is designed to handle the problem. Its complexity is in polynomial order and is easily scalable to the networks with large number of sensor nodes. Furthermore, we address the effect of increase in time slot period on the total amount of collected data which has not been yet exploited well. Finally, through extensive simulations on different set of deployed nodes, we observe that the proposed algorithm significantly increases the network throughput when the travelled distance by sink per time slot is reduced down to the adjusted point.