Remove parameter paymentMethod.
Add GetDurationForPrice().
This commit is contained in:
		| @@ -32,18 +32,20 @@ public: | ||||
|     // Daily ticket | ||||
|     QDateTime GetDailyTicketDuration(Configuration* cfg, const QDateTime start_datetime, uint8_t payment_option, bool carry_over); | ||||
|  | ||||
|     // | ||||
|     // helper function to find time steps for a tariff with PaymentMethod::Steps | ||||
|     // (e.g. Schoenau/Koenigsee) | ||||
|     // | ||||
|     QList<int> GetTimeSteps(Configuration *cfg) const; | ||||
|  | ||||
| private: | ||||
|     // Introduced for PaymentMethod::Steps (e.g. Schoenau) | ||||
|     // For tariff of following structure: only steps, no special days, nonstop. | ||||
|     uint32_t GetCostFromDuration(Configuration const* cfg, QDateTime const &start, quint64 durationMinutes, uint8_t paymentMethod = PaymentMethod::Steps); | ||||
|     uint32_t GetCostFromDuration(Configuration const* cfg, QDateTime const &start, QDateTime const &end, uint8_t paymentMethod = PaymentMethod::Steps); | ||||
|     uint32_t GetCostFromDuration(Configuration *cfg, QDateTime const &start, quint64 durationMinutes) const; | ||||
|     uint32_t GetCostFromDuration(Configuration *cfg, QDateTime const &start, QDateTime const &end) const; | ||||
|  | ||||
|  | ||||
|     // | ||||
|     // helper functions for PaymentMethod::Steps | ||||
|     // | ||||
|     QList<int> GetTimeSteps(Configuration const *cfg, int paymentMethod); | ||||
|     // | ||||
|     uint32_t GetPriceForTimeStep(Configuration const *cfg, uint8_t paymentMethod, int timeStep); | ||||
|     uint32_t GetPriceForTimeStep(Configuration *cfg, int timeStep) const; | ||||
|     uint32_t GetDurationForPrice(Configuration *cfg, int price) const; | ||||
| }; | ||||
|   | ||||
		Reference in New Issue
	
	Block a user