toPrice method

String? toPrice(
  1. int amount, {
  2. MoneyFormats format = MoneyFormats.NORMAL,
  3. MoneyUnit unit = MoneyUnit.NORMAL,
})

Implementation

String? toPrice(
  int amount, {
  MoneyFormats format = MoneyFormats.NORMAL,
  MoneyUnit unit = MoneyUnit.NORMAL,
}) {
  if (this == null) {
    return null;
  }
  return MoneyUtil.changeFStr2YWithUnit(
    this!,
    format: format,
    unit: unit,
  );
}