Collapse the sprawling role taxonomy (dedupe/compound/typo merge)
The dynamic taxonomy minted ~150 roles incl. exact triplicates («پرستار کودک» x3), multi-role compounds («پرستار و بهیار»، «ماما / پرستار»، «پزشک و پرستار و بهیار»), and typos («بیهیار»، «بیار»). Creation hardening: ResolveOrCreateRole now collapses a compound to its FIRST base role when that segment is a known role (so «پرستار و بهیار»→«پرستار», but specialty names like «قلب و عروق»/«پوست و مو» are left whole), and new aliases fold typos/synonyms (بیهیار/بیار→بهیار، فیزیوتراپ→فیزیوتراپیست، نسخه پیچ→تکنسین داروخانه، پرستار بچه/اطفال→پرستار کودک). Cleanup: MergeDuplicateRolesAsync (+ admin button) maps every role to a canonical form and merges same-canonical roles into one keeper, repointing all shifts/jobs/talent/preferences/alerts/profiles first (mirrors the manual /Admin/Roles merge). Combined with the no-fan-out change this should cut the dropdown to a clean base set. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -87,6 +87,15 @@
|
||||
🩺 اصلاح نقشِ آگهیهای «پزشک عمومی» (دندانپزشک/متخصص و …)
|
||||
</button>
|
||||
</form>
|
||||
|
||||
<form method="post" onsubmit="return confirm('نقشهای تکراری/ترکیبی/غلطاملایی (مثل «پرستار کودک» سهتایی، «پرستار و بهیار»، «بیهیار») در نقشهای اصلی ادغام و حذف میشوند؛ آگهیهایشان به نقشِ معتبر منتقل میشود. ادامه؟');">
|
||||
<button type="submit" asp-page-handler="MergeRoles" class="btn btn-primary btn-block" style="margin-top:10px;">
|
||||
🏷️ ادغام نقشهای تکراری/ترکیبی/غلطاملایی
|
||||
</button>
|
||||
</form>
|
||||
<p class="muted" style="font-size:11px; margin:6px 0 0;">
|
||||
نقشهای هممعنا (تکراری، ترکیبی مثل «پرستار و بهیار»، یا غلطاملایی مثل «بیهیار») در یک نقشِ پایه ادغام میشوند تا فهرستِ نقشها تمیز شود. مدیریتِ دستی در <a asp-page="/Admin/Roles">نقشها</a>.
|
||||
</p>
|
||||
<p class="muted" style="font-size:11px; margin:6px 0 0;">
|
||||
آگهیهایی که هوش مصنوعی به اشتباه «پزشک عمومی» زده ولی متنشان نقش دیگری دارد، از روی متن اصلاح میشوند (درجا، بدون تغییر شناسه/آدرس).
|
||||
</p>
|
||||
|
||||
Reference in New Issue
Block a user