introductoryRoundUnitText method

String introductoryRoundUnitText()

introductoryRoundUnit 转换为中文描述

  • "day" -> "天"
  • "week" -> "周"
  • "month" -> "月"
  • "year" -> "年"
  • 其他/null -> ""

Implementation

String introductoryRoundUnitText() {
  switch (introductoryRoundUnit) {
    case "day":
      return "天";
    case "week":
      return "周";
    case "month":
      return "月";
    case "year":
      return "年";
    default:
      return "";
  }
}