1
0
mirror of https://github.com/RaidMax/IW4M-Admin.git synced 2025-06-10 15:20:48 -05:00

-removes flag penality when unflagging a player

-fixed 'just now ago' on webfront
-webfront playerlist level colors are hidden to non admin users
-tempban length can now be specified (<int>m, <int>h, <int>d,  <int>y)
This commit is contained in:
RaidMax
2017-08-23 17:29:48 -05:00
parent 6a94882d20
commit 9227335d25
18 changed files with 221 additions and 157 deletions

View File

@ -209,6 +209,8 @@ namespace IW4MAdmin
chatHistory = S.ChatHistory,
players = new List<PlayerInfo>()
};
bool authed = ApplicationManager.GetInstance().GetClientDatabase().GetAdmins().FindAll(x => x.IP == querySet["IP"] && x.Level > Player.Permission.Trusted).Count > 0
|| querySet["IP"] == "127.0.0.1";
foreach (Player P in S.GetPlayersAsList())
{
@ -216,7 +218,7 @@ namespace IW4MAdmin
{
playerID = P.DatabaseID,
playerName = P.Name,
playerLevel = P.Level.ToString()
playerLevel = authed ? P.Level.ToString() : Player.Permission.User.ToString()
};
eachServer.players.Add(pInfo);
}
@ -383,7 +385,6 @@ namespace IW4MAdmin
try
{
//selectedPenalties = Manager.GetInstance().Servers.First().Bans.OrderByDescending(x => x.When).ToList().GetRange(Convert.ToInt32(querySet["from"]), 15);
selectedPenalties = ((ApplicationManager.GetInstance().GetClientPenalties()) as PenaltyList).AsChronoList(Convert.ToInt32(querySet["from"]), 15).OrderByDescending(b => b.When).ToList();
}