convertDouble method

String convertDouble(
  1. double? number
)

Implementation

String convertDouble(double? number) {
  if (number == null) return '' ;

  int firstNumber = int.parse(number.toString().split('.')[0]);

  int secondNumber = int.parse(number.toString().split('.')[1]);
  String numberInCharecters;

  numberInCharecters = getTextForNumber(firstNumber);
  numberInCharecters += (secondNumber==0? "":" ${_numberMappings.mappings[999999999]} ${getTextForNumber(secondNumber)}" );

  return numberInCharecters;
}