1. 修复swiper箭头点击动画丢失问题 - 改用固定7天窗口,滑动到边缘时整体滚动数据 - 保持dayIndex连续,确保swiper平滑动画 2. 修复宜忌两行显示压在一起 - 设置item固定高度32rpx和行距12rpx - 超出2行显示...省略号 3. 修复月历数字竖向排列问题 - 修正wxml嵌套结构,让42个格子正确排成6行7列 - 压缩格子高度,放大数字字体 4. 节日速查功能优化 - 默认显示3条,右侧添加更多
72 lines
4.9 KiB
JavaScript
72 lines
4.9 KiB
JavaScript
// Settings 页面组件
|
|
export default {
|
|
template: `
|
|
<div class="min-h-screen bg-gray-100">
|
|
<nav class="bg-white shadow-sm">
|
|
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
|
|
<div class="flex justify-between h-16">
|
|
<div class="flex">
|
|
<div class="flex-shrink-0 flex items-center">
|
|
<h1 class="text-xl font-bold text-red-600">祈福小助手</h1>
|
|
</div>
|
|
<div class="hidden sm:ml-6 sm:flex sm:space-x-8">
|
|
<a href="/admin" class="border-transparent text-gray-500 hover:border-gray-300 hover:text-gray-700 inline-flex items-center px-1 pt-1 border-b-2 text-sm font-medium">
|
|
仪表盘
|
|
</a>
|
|
<a href="/admin/users" class="border-transparent text-gray-500 hover:border-gray-300 hover:text-gray-700 inline-flex items-center px-1 pt-1 border-b-2 text-sm font-medium">
|
|
用户管理
|
|
</a>
|
|
<a href="/admin/orders" class="border-transparent text-gray-500 hover:border-gray-300 hover:text-gray-700 inline-flex items-center px-1 pt-1 border-b-2 text-sm font-medium">
|
|
订单管理
|
|
</a>
|
|
<a href="/admin/wishes" class="border-transparent text-gray-500 hover:border-gray-300 hover:text-gray-700 inline-flex items-center px-1 pt-1 border-b-2 text-sm font-medium">
|
|
许愿管理
|
|
</a>
|
|
<a href="/admin/wiki" class="border-transparent text-gray-500 hover:border-gray-300 hover:text-gray-700 inline-flex items-center px-1 pt-1 border-b-2 text-sm font-medium">
|
|
百科管理
|
|
</a>
|
|
<a href="/admin/settings" class="border-red-500 text-gray-900 inline-flex items-center px-1 pt-1 border-b-2 text-sm font-medium">
|
|
系统设置
|
|
</a>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</nav>
|
|
|
|
<main class="max-w-7xl mx-auto py-6 sm:px-6 lg:px-8">
|
|
<div class="px-4 py-6 sm:px-0">
|
|
<div class="bg-white shadow rounded-lg">
|
|
<div class="px-4 py-5 sm:p-6">
|
|
<h2 class="text-lg font-medium text-gray-900 mb-4">系统设置</h2>
|
|
<form class="space-y-6">
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700">许愿树最大许愿数</label>
|
|
<input type="number" class="mt-1 block w-full border-gray-300 rounded-md shadow-sm focus:ring-red-500 focus:border-red-500 sm:text-sm" value="100">
|
|
</div>
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700">免费许愿最大字数</label>
|
|
<input type="number" class="mt-1 block w-full border-gray-300 rounded-md shadow-sm focus:ring-red-500 focus:border-red-500 sm:text-sm" value="20">
|
|
</div>
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700">付费许愿最大字数</label>
|
|
<input type="number" class="mt-1 block w-full border-gray-300 rounded-md shadow-sm focus:ring-red-500 focus:border-red-500 sm:text-sm" value="100">
|
|
</div>
|
|
<div>
|
|
<label class="block text-sm font-medium text-gray-700">机器人许愿间隔(小时)</label>
|
|
<input type="number" class="mt-1 block w-full border-gray-300 rounded-md shadow-sm focus:ring-red-500 focus:border-red-500 sm:text-sm" value="2">
|
|
</div>
|
|
<div>
|
|
<button type="submit" class="inline-flex justify-center py-2 px-4 border border-transparent shadow-sm text-sm font-medium rounded-md text-white bg-red-600 hover:bg-red-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-red-500">
|
|
保存设置
|
|
</button>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</main>
|
|
</div>
|
|
`
|
|
}
|