幸运转盘

v1.1.0 lucky_draw 官方出品 Officially signed

幸运转盘:消耗积分随机抽取奖品,支持奖品池(名称/权重/库存/稀有度 N·R·SR·SSR)、每日次数限制与中奖记录

Author FlintHub Verified developer
Downloads4
Min core version1.3.0
Updated2026-10-30 18:32
Log in to download Log in to download the package directly — for servers that cannot install plugins online.
After downloading, upload the zip in your own site admin: Plugin Store → Upload & Install. If your server has outbound access, prefer the online install — it can auto-update.

Screenshots 1

Changelog

1.0.1:修复「不限库存(stock=-1)的奖品永远抽不到」(扣库存语句 rowCount 恒为 0,被误判成已抢空并退分);修复「单次消耗配成 0 时每次抽奖都报积分不足」(Points::deduct 对 0 直接返回 false);失败补偿改为「撤奖 → 还库存 → 退抽奖成本」逆序;清页缓存改走核心 PageCache::invalidate()(原先 glob 的是插件自己的 data 目录,从未生效);删除奖品确认从内联 onsubmit 改为 data-ld-confirm 绑定(FH-INL-002);抽奖按钮禁用时显示具体原因;卸载时同步删除 schema marker;后台 Tab 补齐 aria-selected/aria-controls;前台布局对齐全站积分类应用页范式(头部 h1.mn-fs-20.mn-fw-600 + 积分 chip + 信息型说明句,正文拆成三张 mn-section 卡片,按钮改用核心 mn-btn,警示条改用自定义 ld-alert-warn)。

Files 17 90.7 KB

  • plugins 17 files · 90.7 KB
    • lucky_draw 17 files · 90.7 KB
      • assets 2 files · 16.6 KB
        • script.js 9.2 KB
        • style.css 7.4 KB
      • hook 4 files · 2.9 KB
        • admin_route_register.php 674 B
        • init_after.php 670 B
        • nav_plugin_links.php 1.2 KB
        • route_register.php 452 B
      • lang 3 files · 12.7 KB
        • en.php 4.2 KB
        • zh.php 4.2 KB
        • zh_tw.php 4.3 KB
      • views 3 files · 23.2 KB
        • admin.php 12.1 KB
        • index.php 9 KB
        • records.php 2 KB
      • AdminController.php 5.8 KB
      • FrontController.php 7.5 KB
      • Plugin.php 13.4 KB
      • plugin.json 1.6 KB
      • 说明.md 6.9 KB

Discussion 0

No discussion yet. Be the first to share your thoughts.
Please sign in to join the discussion.