v2.0.53 función
Reply to reports, private messages, heal all and duty logs
7cambios

Reply to reports, private messages, heal all and duty logs
7cambios

[02] Versión
Reports are now a conversation: players reply from My Reports and both sides are told when the other answers. Staff can send a private message to one player, heal every player at once, and see in Discord when each admin goes on and off duty and for how long. Revive and heal now work with the medical script even when it starts after the admin menu.
players.message and players.healAll are given automatically to OWNER and SUPERADMIN, and to any role that already has players.warn (message) or players.reviveAll (heal all). Framework admins have them already.config/main.lua: Config.MedicalResources (replaces the old medicalSystems list), ReplyNotify and ReplyRateLimitMs in Config.Reports, message in Config.NoticeDuration, and the new privateMessage, healAll, dutyStart and dutyEnd events in Config.Logs.Events.server/webhooks.lua: privateMessage, healAll and the new staff group (dutyStart, dutyEnd).custom/server.lua: the sv_medical block at the top. Replace it, don't merge it.Duty means time signed into the admin panel. The "duty ended" log shows how long the session lasted and why it ended: logout, disconnect or access revoked. Add a URL to staff._default in server/webhooks.lua to send both logs to one channel.
Players can't reply to a report that is closed or rejected. They can reply once every 5 seconds (Config.Reports.ReplyRateLimitMs), up to the same length as a report message.
Replace every file in the resource, except what you edited yourself:
config/main.lua, custom/server.lua, server/webhooks.lua, types.luaclient/modules/reports.luaserver/main.lua, server/modules/actions.lua, server/modules/admin_activity.lua, server/modules/self_actions.luaserver/modules/auth/migrations.lua, server/modules/auth/service.lua, server/modules/logs/format.luaserver/modules/reports/realtime.lua, server/modules/reports/service.luaserver/custom/medical/qs.lua, server/custom/medical/standalone.lua, server/custom/medical/tk.lualocales/ — every language.web/ — replace the whole folder.fxmanifest.lua — version only.Reports are now a conversation. A player opens a report in My Reports and writes back to staff, as long as the report is not closed or rejected.
The player is told when staff posts a public reply on their report. When the player replies, the assigned staff member is told; if nobody is assigned or they are offline, every online staff member who can read reports is told. Switch it off with Config.Reports.ReplyNotify.
Players > Message shows the player an on-screen notice from staff (up to 240 characters) and a chat line. It stays 10 seconds or until they dismiss it, and is logged. Needs the new players.message permission.
Heal All in the Control Center and in Fast Actions heals everyone online through your medical script, the same way Players > Heal does. Needs the new players.healAll permission.
A log and a Discord message when an admin signs into the panel, and another when they leave, with how long the session lasted and why it ended. Set the URLs in the new staff group of server/webhooks.lua.
The medical script was only looked for once, when the admin menu started. If it started afterwards, revive stood the player up while the medical script still thought they were dead. It is now looked for on every revive and heal. The list is Config.MedicalResources.
Without a supported medical script, revive and heal now also tell qb-ambulancejob, esx_ambulancejob and qbx_medical, and clear QBCore's dead and last-stand flags, so the player is no longer treated as dead after being revived.