mobile app admin_base admin_contests admin_dashboard chat contest_detail exam_create exam_detail exam_grade exam_list profile themes
This commit is contained in:
@@ -51,9 +51,9 @@
|
||||
<label class="block text-sm font-medium text-slate-700">考试可见性</label>
|
||||
<select id="exam-visibility" class="mt-1 block w-full px-3 py-2 border border-slate-300 rounded-md sm:text-sm">
|
||||
<option value="private">私有(仅自己可见)</option>
|
||||
<option value="public">公开(所有人可见)</option>
|
||||
{% if not (is_cup_teacher|default(false)) %}<option value="public">公开(所有人可见)</option>{% endif %}
|
||||
</select>
|
||||
<p class="mt-1 text-xs text-slate-400">私有考试只有您自己可以看到和管理</p>
|
||||
<p class="mt-1 text-xs text-slate-400">{% if is_cup_teacher|default(false) %}杯赛老师仅可创建自己可见的杯赛考试{% else %}私有考试只有您自己可以看到和管理{% endif %}</p>
|
||||
</div>
|
||||
<div>
|
||||
<label class="block text-sm font-medium text-slate-700">考试密码 <span class="text-slate-400 font-normal">(可选)</span></label>
|
||||
@@ -104,7 +104,7 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- VIP 弹窗 -->
|
||||
<!-- 智能识别功能开发中弹窗 -->
|
||||
<div id="vipModal" class="fixed inset-0 z-[999] hidden" onclick="if(event.target===this)closeVipModal()">
|
||||
<!-- 背景:深空黑 + 动态星点 -->
|
||||
<div class="absolute inset-0 bg-gradient-to-br from-[#0a0015] via-[#0d0d2b] to-[#0a0015]">
|
||||
@@ -121,56 +121,42 @@
|
||||
<div class="absolute -top-10 left-1/2 -translate-x-1/2 w-40 h-40 bg-cyan-400/10 rounded-full blur-2xl"></div>
|
||||
<!-- 关闭按钮 -->
|
||||
<button onclick="closeVipModal()" class="absolute top-4 right-4 w-8 h-8 flex items-center justify-center rounded-full bg-white/5 hover:bg-white/10 text-white/40 hover:text-white/80 transition text-lg">×</button>
|
||||
<!-- 皇冠图标 -->
|
||||
<div class="relative flex justify-center mb-4">
|
||||
<div class="w-20 h-20 rounded-2xl bg-gradient-to-br from-amber-400 via-yellow-300 to-amber-500 flex items-center justify-center shadow-lg shadow-amber-500/30 vip-crown">
|
||||
<svg class="w-10 h-10 text-amber-900" fill="currentColor" viewBox="0 0 24 24"><path d="M5 16L3 5l5.5 5L12 4l3.5 6L21 5l-2 11H5zm0 2h14v2H5v-2z"/></svg>
|
||||
<!-- 动漫小人辛苦工作插图 -->
|
||||
<div class="relative flex justify-center mb-6">
|
||||
<div class="dev-character relative">
|
||||
<div class="absolute inset-0 flex items-center justify-center">
|
||||
<div class="w-28 h-28 rounded-full bg-cyan-500/10 blur-2xl"></div>
|
||||
</div>
|
||||
<svg class="w-36 h-36 mx-auto relative z-10" viewBox="0 0 120 120" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<!-- 身体/工作服 -->
|
||||
<ellipse cx="60" cy="85" rx="28" ry="18" fill="#6366f1"/>
|
||||
<rect x="32" y="55" width="56" height="35" rx="8" fill="#4f46e5"/>
|
||||
<!-- 头部 -->
|
||||
<circle cx="60" cy="38" r="26" fill="#fde68a"/>
|
||||
<circle cx="60" cy="38" r="26" stroke="#f59e0b" stroke-width="2"/>
|
||||
<!-- 大眼睛 -->
|
||||
<ellipse cx="52" cy="35" rx="6" ry="8" fill="#1e293b"/>
|
||||
<ellipse cx="68" cy="35" rx="6" ry="8" fill="#1e293b"/>
|
||||
<circle cx="54" cy="33" r="2" fill="white"/>
|
||||
<circle cx="70" cy="33" r="2" fill="white"/>
|
||||
<!-- 腮红 -->
|
||||
<ellipse cx="42" cy="42" rx="4" ry="3" fill="#fda4af" opacity="0.7"/>
|
||||
<ellipse cx="78" cy="42" rx="4" ry="3" fill="#fda4af" opacity="0.7"/>
|
||||
<!-- 汗珠(辛苦工作) -->
|
||||
<ellipse cx="88" cy="28" rx="4" ry="6" fill="#93c5fd" opacity="0.9" class="sweat-drop"/>
|
||||
<ellipse cx="92" cy="32" rx="3" ry="5" fill="#93c5fd" opacity="0.7" class="sweat-drop"/>
|
||||
<!-- 锤子/工具(敲代码) -->
|
||||
<rect x="75" y="45" width="8" height="25" rx="2" fill="#78716c" transform="rotate(-30 79 57)"/>
|
||||
<rect x="70" y="35" width="18" height="10" rx="2" fill="#a8a29e" transform="rotate(-30 79 40)"/>
|
||||
<!-- 代码符号 -->
|
||||
<text x="42" y="72" fill="white" font-size="10" font-family="monospace" font-weight="bold" opacity="0.95"></></text>
|
||||
</svg>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 标题 -->
|
||||
<h2 class="text-center text-2xl font-bold bg-gradient-to-r from-amber-200 via-yellow-100 to-amber-200 bg-clip-text text-transparent mb-1">SVIP 超级会员</h2>
|
||||
<p class="text-center text-purple-300/60 text-xs mb-6 tracking-widest">SUPREME VIP MEMBERSHIP</p>
|
||||
<!-- 功能列表 -->
|
||||
<div class="space-y-3 mb-8">
|
||||
<div class="flex items-center space-x-3 px-4 py-3 rounded-xl bg-white/[0.03] border border-white/[0.06]">
|
||||
<span class="flex-shrink-0 w-8 h-8 rounded-lg bg-purple-500/20 flex items-center justify-center text-purple-400">
|
||||
<svg class="w-4 h-4" fill="none" stroke="currentColor" stroke-width="2" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" d="M9.663 17h4.673M12 3v1m6.364 1.636l-.707.707M21 12h-1M4 12H3m3.343-5.657l-.707-.707m2.828 9.9a5 5 0 117.072 0l-.548.547A3.374 3.374 0 0014 18.469V19a2 2 0 11-4 0v-.531c0-.895-.356-1.754-.988-2.386l-.548-.547z"/></svg>
|
||||
</span>
|
||||
<div><p class="text-white/90 text-sm font-medium">AI 智能识别试卷</p><p class="text-white/30 text-xs">PDF 一键导入,公式图形全自动解析</p></div>
|
||||
</div>
|
||||
<div class="flex items-center space-x-3 px-4 py-3 rounded-xl bg-white/[0.03] border border-white/[0.06]">
|
||||
<span class="flex-shrink-0 w-8 h-8 rounded-lg bg-cyan-500/20 flex items-center justify-center text-cyan-400">
|
||||
<svg class="w-4 h-4" fill="none" stroke="currentColor" stroke-width="2" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" d="M13 10V3L4 14h7v7l9-11h-7z"/></svg>
|
||||
</span>
|
||||
<div><p class="text-white/90 text-sm font-medium">量子级 OCR 引擎</p><p class="text-white/30 text-xs">手写体、印刷体、火星文通通拿下</p></div>
|
||||
</div>
|
||||
<div class="flex items-center space-x-3 px-4 py-3 rounded-xl bg-white/[0.03] border border-white/[0.06]">
|
||||
<span class="flex-shrink-0 w-8 h-8 rounded-lg bg-amber-500/20 flex items-center justify-center text-amber-400">
|
||||
<svg class="w-4 h-4" fill="none" stroke="currentColor" stroke-width="2" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" d="M12 8v4l3 3m6-3a9 9 0 11-18 0 9 9 0 0118 0z"/></svg>
|
||||
</span>
|
||||
<div><p class="text-white/90 text-sm font-medium">永久有效 · 无限次数</p><p class="text-white/30 text-xs">一次开通,终身尊享(真的吗?)</p></div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 价格区 -->
|
||||
<div class="text-center mb-6">
|
||||
<div class="inline-flex items-baseline space-x-2 mb-1">
|
||||
<span class="text-white/30 text-sm line-through decoration-red-400/60">原价 ¥998/年</span>
|
||||
</div>
|
||||
<div class="flex items-baseline justify-center">
|
||||
<span class="text-white/50 text-lg mr-1">¥</span>
|
||||
<span class="text-5xl font-black bg-gradient-to-r from-cyan-300 via-purple-400 to-pink-400 bg-clip-text text-transparent vip-price">∞</span>
|
||||
</div>
|
||||
<p class="text-white/20 text-xs mt-2">限时优惠 · 仅剩 <span class="text-amber-400/80">0</span> 个名额</p>
|
||||
</div>
|
||||
<!-- 无支付按钮区域 -->
|
||||
<div class="relative">
|
||||
<div class="w-full py-3 rounded-xl bg-white/[0.04] border border-dashed border-white/10 text-center">
|
||||
<p class="text-white/20 text-sm">支付通道维护中,预计恢复时间:</p>
|
||||
<p class="text-purple-300/40 text-xs mt-1 font-mono tracking-wider">2099年12月31日 23:59:59</p>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 底部小字 -->
|
||||
<p class="text-center text-white/10 text-[10px] mt-4">本页面仅供观赏,不构成任何消费邀约。如有雷同,纯属巧合。</p>
|
||||
<!-- 主文案 -->
|
||||
<h2 class="text-center text-2xl font-bold bg-gradient-to-r from-cyan-300 via-purple-400 to-pink-400 bg-clip-text text-transparent mb-2">该功能正在开发中</h2>
|
||||
<p class="text-center text-purple-200/90 text-lg font-medium mb-1">敬请期待</p>
|
||||
<p class="text-center text-purple-300/50 text-sm">渔鱼余正在努力敲代码中...</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -204,6 +190,20 @@
|
||||
0%, 100% { transform: translateY(0); }
|
||||
50% { transform: translateY(-6px); }
|
||||
}
|
||||
.dev-character {
|
||||
animation: workBounce 2s ease-in-out infinite;
|
||||
}
|
||||
@keyframes workBounce {
|
||||
0%, 100% { transform: translateY(0) scale(1); }
|
||||
50% { transform: translateY(-4px) scale(1.02); }
|
||||
}
|
||||
.dev-character .sweat-drop {
|
||||
animation: sweatDrop 1.5s ease-in-out infinite;
|
||||
}
|
||||
@keyframes sweatDrop {
|
||||
0%, 100% { opacity: 0.9; }
|
||||
50% { opacity: 0.4; }
|
||||
}
|
||||
.vip-price {
|
||||
animation: glow 2s ease-in-out infinite alternate;
|
||||
}
|
||||
@@ -229,6 +229,8 @@
|
||||
{% endblock %}
|
||||
{% block scripts %}
|
||||
<script>
|
||||
// 从杯赛页面进入时传入的 contest_id,用于创建杯赛考试
|
||||
const PAGE_CONTEST_ID = {{ contest_id|default(none)|tojson }};
|
||||
// VIP 弹窗
|
||||
function showVipModal() {
|
||||
const modal = document.getElementById('vipModal');
|
||||
@@ -585,12 +587,16 @@ function submitExam() {
|
||||
}
|
||||
const access_password = document.getElementById('exam-password').value.trim();
|
||||
const visibility = document.getElementById('exam-visibility').value;
|
||||
const payload = { title, subject, duration, questions, scheduled_start, scheduled_end, score_release_time, access_password, visibility };
|
||||
if (PAGE_CONTEST_ID) payload.contest_id = PAGE_CONTEST_ID;
|
||||
fetch('/api/exams', {
|
||||
method: 'POST', headers: {'Content-Type':'application/json'},
|
||||
body: JSON.stringify({ title, subject, duration, questions, scheduled_start, scheduled_end, score_release_time, access_password, visibility })
|
||||
body: JSON.stringify(payload)
|
||||
}).then(r => r.json()).then(data => {
|
||||
if (data.success) { alert('试卷创建成功!'); window.location.href = '/exams'; }
|
||||
else alert(data.message);
|
||||
if (data.success) {
|
||||
alert('试卷创建成功!');
|
||||
window.location.href = PAGE_CONTEST_ID ? '/contests/' + PAGE_CONTEST_ID : '/exams';
|
||||
} else alert(data.message);
|
||||
}).catch(() => alert('创建失败'));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user