本文整理汇总了Python中pyticketswitch.util.format_price_with_symbol函数的典型用法代码示例。如果您正苦于以下问题:Python format_price_with_symbol函数的具体用法?Python format_price_with_symbol怎么用?Python format_price_with_symbol使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了format_price_with_symbol函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: cost
def cost(self):
"""Formatted string value of the cost with currency symbol."""
return format_price_with_symbol(
self._core_despatch_method.despatch_cost,
self._core_currency.currency_pre_symbol,
self._core_currency.currency_post_symbol,
)
示例2: total_cost
def total_cost(self):
"""Formatted string value of the total combined price with currency
symbol."""
return format_price_with_symbol(
self._core_bundle.bundle_total_cost,
self._core_bundle.currency.currency_pre_symbol,
self._core_bundle.currency.currency_post_symbol
)
示例3: total_despatch
def total_despatch(self):
"""Formatted string value of the total despatch cost with currency
symbol."""
return format_price_with_symbol(
self._core_bundle.bundle_total_despatch,
self._core_bundle.currency.currency_pre_symbol,
self._core_bundle.currency.currency_post_symbol
)
示例4: total_surcharge
def total_surcharge(self):
"""Formatted string value of the total surcharge cost with currency
symbol."""
return format_price_with_symbol(
self._core_bundle.bundle_total_surcharge,
self._core_bundle.currency.currency_pre_symbol,
self._core_bundle.currency.currency_post_symbol
)
示例5: surcharge
def surcharge(self):
"""Formatted string value of the surcharge with currency symbol."""
return format_price_with_symbol(
self._core_avail_detail.surcharge,
self._core_currency.currency_pre_symbol,
self._core_currency.currency_post_symbol,
)
示例6: ticket_price
def ticket_price(self):
"""Formatted string value of the combined price with currency symbol.
"""
return format_price_with_symbol(
self._core_discount.combined,
self._core_currency.currency_pre_symbol,
self._core_currency.currency_post_symbol,
)
示例7: total_inc_despatch
def total_inc_despatch(self):
"""Formatted string value of the total combined price including
despatch with currency symbol.
"""
return format_price_with_symbol(
str(self.total_inc_despatch_float),
self._core_currency.currency_pre_symbol,
self._core_currency.currency_post_symbol
)
示例8: price_without_surcharge
def price_without_surcharge(self):
"""Formatted string value of the price excluding surcharge with
currency symbol."""
return format_price_with_symbol(
self._core_price_band.ticket_price,
self._core_currency.currency_pre_symbol,
self._core_currency.currency_post_symbol,
)
示例9: offer_surcharge_price
def offer_surcharge_price(self):
"""Formatted string value of the offer surcharge price with
currency symbol.
"""
return format_price_with_symbol(
self._core_offer['offer_surcharge'],
self.currency.pre_symbol,
self.currency.post_symbol
)
示例10: offer_combined_price
def offer_combined_price(self):
"""Formatted string value of the offer combined price with
currency symbol.
"""
return format_price_with_symbol(
self._core_offer['offer_combined'],
self.currency.pre_symbol,
self.currency.post_symbol
)
示例11: seatprice
def seatprice(self):
"""Formatted string value of the seat price (i.e. without surcharge)
with currency symbol.
"""
return format_price_with_symbol(
self._core_discount.seatprice,
self._core_currency.currency_pre_symbol,
self._core_currency.currency_post_symbol,
)
示例12: total_combined
def total_combined(self):
"""Formatted string value of the total combined price with currency
symbol.
"""
return format_price_with_symbol(
str(self.total_combined_float),
self._core_currency.currency_pre_symbol,
self._core_currency.currency_post_symbol
)
示例13: full_seatprice
def full_seatprice(self):
"""Formatted string value of the full seatprice price with
currency symbol.
"""
return format_price_with_symbol(
self._core_offer['full_seatprice'],
self.currency.pre_symbol,
self.currency.post_symbol
)
示例14: price_combined
def price_combined(self):
"""Formatted string value of the combined seatprice + surcharge with
currency symbol.
"""
combined_price = str(self.price_combined_float)
return format_price_with_symbol(
combined_price, self._core_currency.currency_pre_symbol, self._core_currency.currency_post_symbol
)
示例15: non_offer_combined
def non_offer_combined(self):
"""Formatted string value of the original combined price with
currency symbol (i.e. if there was no offer).
"""
formatted_price = None
combined_price = str(self.non_offer_combined_float)
formatted_price = format_price_with_symbol(
combined_price, self._core_currency.currency_pre_symbol, self._core_currency.currency_post_symbol
)
return formatted_price