getBudgetDetailList static method

List<UserDetailData> getBudgetDetailList(
  1. BuildContext context, {
  2. required double capTotal,
  3. required double usedTotal,
})

Implementation

static List<UserDetailData> getBudgetDetailList(BuildContext context,
    {required double capTotal, required double usedTotal}) {
  return <UserDetailData>[
    UserDetailData(
      title: "Total cap",
      value: usdWithSignFormat(context).format(capTotal),
    ),
    UserDetailData(
      title: "Amount used",
      value: usdWithSignFormat(context).format(usedTotal),
    ),
    UserDetailData(
      title: "Amount left",
      value: usdWithSignFormat(context).format(capTotal - usedTotal),
    ),
  ];
}