1
0
mirror of https://github.com/Zrips/Jobs.git synced 2024-11-26 04:25:15 +01:00

Add "%jobsr_user_points_fixed%" placeholder

Closes #843
This commit is contained in:
montlikadani 2020-07-05 11:52:52 +02:00
parent eb978e6db8
commit 321c5e331a

View File

@ -47,6 +47,7 @@ public class Placeholder {
user_displayhonorific, user_displayhonorific,
user_joinedjobcount, user_joinedjobcount,
user_points, user_points,
user_points_fixed,
user_total_points, user_total_points,
user_archived_jobs, user_archived_jobs,
user_jobs, user_jobs,
@ -412,6 +413,8 @@ public class Placeholder {
case user_points: case user_points:
DecimalFormat dec = new DecimalFormat("00.0"); DecimalFormat dec = new DecimalFormat("00.0");
return dec.format(user.getPointsData().getCurrentPoints()); return dec.format(user.getPointsData().getCurrentPoints());
case user_points_fixed:
return Integer.toString((int) user.getPointsData().getCurrentPoints());
case user_total_points: case user_total_points:
format = NumberFormat.getInstance(Locale.ENGLISH); format = NumberFormat.getInstance(Locale.ENGLISH);
return format.format(user.getPointsData().getTotalPoints()); return format.format(user.getPointsData().getTotalPoints());