mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2026-10-02 02:43:44 +00:00
Staff list contraband items on a new dashboard page (item search, reason, flag or flag and remove; contraband_manage to edit, reports_view to see). World servers check every inventory when a character loads and every item a player receives: each find is an economy flag of the new kind Contraband, shown with the other flags and in the character's related data. Items marked for removal are taken away, with a character snapshot kept first so they can be given back, an audit entry and a mail or chat message telling the player why. Staff are skipped unless contraband_ignore_staff is off. Worlds reload the list when it changes (RELOAD_CONTRABAND, added at the end of ePlayerAction). Fixes #1563 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
43 lines
2.1 KiB
Django/Jinja
43 lines
2.1 KiB
Django/Jinja
{% extends "base.jinja2" %}
|
|
|
|
{% block title %}Contraband - DarkflameServer{% endblock %}
|
|
|
|
{% block content %}
|
|
<div id="contrabandPage">
|
|
<div class="mb-3">
|
|
<h2 class="mb-1">Contraband</h2>
|
|
<p class="text-body-secondary mb-0">Items players shouldn't have. World servers check every inventory (vault included) when a character loads,
|
|
and every item a player receives. <strong>Flag</strong> adds an economy flag for staff to review; <strong>Remove</strong> flags it and takes the
|
|
item away (a snapshot of the character is kept first, so it can be given back from the character page). Staff accounts aren't checked unless
|
|
<code>contraband_ignore_staff</code> is off. Running worlds pick up changes straight away.
|
|
Flags found: <a href="/reports#flags">Economy & Map, Flags</a>.</p>
|
|
</div>
|
|
|
|
<div class="card mb-3 d-none" id="addCard">
|
|
<div class="card-body">
|
|
<form class="row g-2 align-items-end" id="addForm">
|
|
<div class="col-md-4"><label class="form-label small mb-1" for="lotInput">Item</label>
|
|
<input class="form-control form-control-sm" id="lotInput" list="lotSuggestions" required autocomplete="off" placeholder="Name or LOT">
|
|
<datalist id="lotSuggestions"></datalist></div>
|
|
<div class="col-md-4"><label class="form-label small mb-1" for="reasonInput">Reason</label>
|
|
<input class="form-control form-control-sm" id="reasonInput" maxlength="300" placeholder="Shown to staff, and to the player if it's removed"></div>
|
|
<div class="col-md-2"><label class="form-label small mb-1" for="actionInput">When found</label>
|
|
<select class="form-select form-select-sm" id="actionInput"><option value="flag">Flag</option><option value="remove">Flag and remove</option></select></div>
|
|
<div class="col-md-2"><button type="submit" class="btn btn-sm btn-primary w-100">Save</button></div>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="card">
|
|
<table class="table table-sm align-middle mb-0 table-stack">
|
|
<thead><tr><th>Item</th><th>Reason</th><th>When found</th><th>Added</th><th></th></tr></thead>
|
|
<tbody id="rows"></tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
{% endblock %}
|
|
|
|
{% block scripts %}
|
|
<script src="/js/contraband.js"></script>
|
|
{% endblock %}
|