base.py 243 B

12345678910111213
  1. # coding=utf-8
  2. class Formater(object):
  3. @staticmethod
  4. def formatPrice(value):
  5. return int(round(float(value or 0) * 100,0))
  6. @staticmethod
  7. def formatPriceShow(value):
  8. return '%.2f' % (float(value or 0)/100.0)