class Playbook::PbCurrency::Currency
def abbreviated_value(index = 0..-2)
def abbreviated_value(index = 0..-2) value = amount.split(".").first.split(",").join("") abbreviated_num = number_to_human(value, units: { thousand: "K", million: "M", billion: "B", trillion: "T" }).gsub(/\s+/, "").to_s abbreviated_num[index] end