edit reset area

This commit is contained in:
Flatlogic Bot 2026-05-05 05:19:53 +00:00
parent 3694996f67
commit ed77a396a7
2 changed files with 36 additions and 29 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

View File

@ -70,6 +70,35 @@
<div class="tab-content" id="settingsTabsContent">
<div class="tab-pane fade show active" id="settings-company-pane" role="tabpanel" aria-labelledby="settings-company-tab" tabindex="0">
<div class="row g-3">
<div class="col-md-12">
<div class="rounded-4 border bg-body-tertiary p-3 settings-eid-card settings-company-pane-top-card">
<div class="d-flex flex-column flex-xl-row justify-content-between align-items-xl-start gap-3 settings-eid-header-row">
<div class="flex-grow-1">
<div class="small text-uppercase text-muted mb-1"><?= h(tr('طلبات العيد', 'Eid orders')) ?></div>
<h6 class="fw-bold mb-1"><?= h(tr('إعادة ضبط التسلسل الموسمي', 'Reset seasonal serial')) ?></h6>
<p class="text-muted small mb-0"><?= h(tr('يعيد الرقم القادم لطلبات العيد إلى 1 للطلبات الجديدة فقط، بدون تغيير أرقام الطلبات السابقة.', 'Resets the next Eid order serial to 1 for new orders only, without changing older saved orders.')) ?></p>
</div>
<div class="bg-white border rounded-3 px-3 py-2 settings-eid-reset-box">
<div class="small text-muted mb-1"><?= h(tr('الرقم القادم', 'Next serial')) ?></div>
<div class="d-flex align-items-center gap-2 flex-nowrap settings-eid-inline-controls" dir="auto">
<div class="fs-5 fw-bold mb-0" data-eid-serial-next-label="1"><?= h(eid_serial_label($eidSerialNext)) ?></div>
<button
type="button"
class="btn btn-outline-danger btn-sm px-3 text-nowrap"
data-reset-eid-serial="1"
data-reset-url="<?= h(url_for('api/settings.php')) ?>"
data-reset-label="<?= h(eid_serial_label(1)) ?>"
data-reset-confirm="<?= h(tr('سيتم تعيين الرقم القادم لطلبات العيد إلى 1. لن يتم تعديل الطلبات القديمة. هل تريد المتابعة؟', 'The next Eid order serial will be reset to 1. Old orders will not be changed. Do you want to continue?')) ?>"
data-reset-success="<?= h(tr('تمت إعادة الضبط بنجاح.', 'Reset completed successfully.')) ?>"
data-reset-error="<?= h(tr('تعذر تنفيذ إعادة الضبط حالياً. حاول مرة أخرى.', 'Could not reset the Eid serial right now. Please try again.')) ?>">
<i class="bi bi-arrow-counterclockwise me-1"></i><?= h(tr('إعادة الضبط إلى 1', 'Reset to 1')) ?>
</button>
</div>
</div>
</div>
</div>
</div>
<div class="col-md-12">
<label class="form-label"><?= h(tr('المنطقة الزمنية (Timezone)', 'Timezone')) ?></label>
<select class="form-select" name="timezone" required>
@ -127,34 +156,6 @@
<div class="mt-2"><img src="<?= h(get_setting('company_favicon')) ?>" height="32" style="background: #f8f9fa; padding: 2px; border-radius: 4px;"></div>
<?php endif; ?>
</div>
<div class="col-md-12">
<div class="rounded-4 border bg-body-tertiary p-3 settings-eid-card">
<div class="d-flex flex-column flex-xl-row justify-content-between align-items-xl-start gap-3 settings-eid-header-row">
<div class="flex-grow-1">
<div class="small text-uppercase text-muted mb-1"><?= h(tr('طلبات العيد', 'Eid orders')) ?></div>
<h6 class="fw-bold mb-1"><?= h(tr('إعادة ضبط التسلسل الموسمي', 'Reset seasonal serial')) ?></h6>
<p class="text-muted small mb-0"><?= h(tr('يعيد الرقم القادم لطلبات العيد إلى 1 للطلبات الجديدة فقط، بدون تغيير أرقام الطلبات السابقة.', 'Resets the next Eid order serial to 1 for new orders only, without changing older saved orders.')) ?></p>
</div>
<div class="bg-white border rounded-3 px-3 py-2 settings-eid-reset-box">
<div class="small text-muted mb-1"><?= h(tr('الرقم القادم', 'Next serial')) ?></div>
<div class="d-flex align-items-center gap-2 flex-nowrap settings-eid-inline-controls" dir="auto">
<div class="fs-5 fw-bold mb-0" data-eid-serial-next-label="1"><?= h(eid_serial_label($eidSerialNext)) ?></div>
<button
type="button"
class="btn btn-outline-danger btn-sm px-3 text-nowrap"
data-reset-eid-serial="1"
data-reset-url="<?= h(url_for('api/settings.php')) ?>"
data-reset-label="<?= h(eid_serial_label(1)) ?>"
data-reset-confirm="<?= h(tr('سيتم تعيين الرقم القادم لطلبات العيد إلى 1. لن يتم تعديل الطلبات القديمة. هل تريد المتابعة؟', 'The next Eid order serial will be reset to 1. Old orders will not be changed. Do you want to continue?')) ?>"
data-reset-success="<?= h(tr('تمت إعادة الضبط بنجاح.', 'Reset completed successfully.')) ?>"
data-reset-error="<?= h(tr('تعذر تنفيذ إعادة الضبط حالياً. حاول مرة أخرى.', 'Could not reset the Eid serial right now. Please try again.')) ?>">
<i class="bi bi-arrow-counterclockwise me-1"></i><?= h(tr('إعادة الضبط إلى 1', 'Reset to 1')) ?>
</button>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
@ -353,7 +354,13 @@
}
#settingsModal .settings-eid-card {
margin-top: -0.125rem;
margin-top: 0;
}
#settingsModal .settings-company-pane-top-card {
position: sticky;
top: -0.35rem;
z-index: 1;
}
#settingsModal .settings-eid-header-row {