Spaces:
Running
Running
File size: 11,961 Bytes
e64f1fb | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 | <!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>流程跟踪 - PyQuantFlow</title>
<link rel="icon" type="image/x-icon" href="/static/favicon.ico">
<link rel="stylesheet" href="style.css">
<script src="https://cdn.tailwindcss.com"></script>
<script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
<script src="https://unpkg.com/feather-icons"></script>
<script>
tailwind.config = {
theme: {
extend: {
colors: {
primary: '#ef4444',
secondary: '#f43f5e'
}
}
}
}
</script>
</head>
<body class="bg-gray-50 text-gray-800 min-h-screen flex flex-col">
<script src="components/navigation.js" defer></script>
<custom-navigation></custom-navigation>
<main class="container mx-auto px-4 py-8 flex-grow">
<div class="flex flex-col md:flex-row justify-between items-start md:items-center mb-8">
<div>
<h1 class="text-4xl font-bold text-gray-800 mb-2">
<span class="text-primary">流程跟踪</span> 数据库
</h1>
<p class="text-gray-600">实时任务管理、进度监控与团队协作</p>
</div>
<a href="index.html" class="mt-4 md:mt-0 bg-gray-800 hover:bg-gray-900 text-white px-6 py-3 rounded-lg font-semibold shadow-lg transition duration-300 flex items-center">
<i data-feather="arrow-left" class="mr-2"></i> 返回仪表板
</a>
</div>
<!-- Filters and Controls -->
<div class="bg-white rounded-xl shadow-lg p-6 mb-8">
<div class="flex flex-col md:flex-row justify-between items-center gap-4">
<div class="flex flex-wrap gap-4">
<select class="px-4 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-primary">
<option>所有状态</option>
<option>待开始</option>
<option>进行中</option>
<option>已完成</option>
</select>
<select class="px-4 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-primary">
<option>所有负责人</option>
<option>张明</option>
<option>李华</option>
<option>王伟</option>
<option>刘芳</option>
</select>
<input type="date" class="px-4 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-primary">
</div>
<button id="addNewTask" class="bg-primary hover:bg-red-600 text-white px-6 py-3 rounded-lg font-semibold shadow-lg transition duration-300 flex items-center">
<i data-feather="plus" class="mr-2"></i> 添加新任务
</button>
</div>
</div>
<!-- Enhanced Tracker Table -->
<div class="bg-white rounded-2xl shadow-xl overflow-hidden">
<div class="overflow-x-auto">
<table class="min-w-full divide-y divide-gray-200">
<thead class="bg-gray-50">
<tr>
<th class="px-6 py-4 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">ID</th>
<th class="px-6 py-4 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">任务名称</th>
<th class="px-6 py-4 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">状态</th>
<th class="px-6 py-4 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">优先级</th>
<th class="px-6 py-4 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">负责人</th>
<th class="px-6 py-4 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">截止日期</th>
<th class="px-6 py-4 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">进度</th>
<th class="px-6 py-4 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">操作</th>
</tr>
</thead>
<tbody id="trackerTableBody" class="bg-white divide-y divide-gray-200">
<!-- Will be populated by JavaScript -->
</tbody>
</table>
</div>
</div>
<!-- Statistics -->
<div class="grid grid-cols-1 md:grid-cols-4 gap-6 mt-8">
<div class="bg-white p-6 rounded-xl shadow-lg">
<div class="flex items-center">
<div class="w-12 h-12 bg-red-100 rounded-lg flex items-center justify-center mr-4">
<i data-feather="check-circle" class="w-6 h-6 text-red-600"></i>
</div>
<div>
<p class="text-gray-500 text-sm">已完成</p>
<p class="text-2xl font-bold text-gray-800">24</p>
</div>
</div>
</div>
<div class="bg-white p-6 rounded-xl shadow-lg">
<div class="flex items-center">
<div class="w-12 h-12 bg-yellow-100 rounded-lg flex items-center justify-center mr-4">
<i data-feather="clock" class="w-6 h-6 text-yellow-600"></i>
</div>
<div>
<p class="text-gray-500 text-sm">进行中</p>
<p class="text-2xl font-bold text-gray-800">8</p>
</div>
</div>
</div>
<div class="bg-white p-6 rounded-xl shadow-lg">
<div class="flex items-center">
<div class="w-12 h-12 bg-blue-100 rounded-lg flex items-center justify-center mr-4">
<i data-feather="calendar" class="w-6 h-6 text-blue-600"></i>
</div>
<div>
<p class="text-gray-500 text-sm">下周截止</p>
<p class="text-2xl font-bold text-gray-800">5</p>
</div>
</div>
</div>
<div class="bg-white p-6 rounded-xl shadow-lg">
<div class="flex items-center">
<div class="w-12 h-12 bg-green-100 rounded-lg flex items-center justify-center mr-4">
<i data-feather="trending-up" class="w-6 h-6 text-green-600"></i>
</div>
<div>
<p class="text-gray-500 text-sm">总体进度</p>
<p class="text-2xl font-bold text-gray-800">68%</p>
</div>
</div>
</div>
</div>
</main>
<script src="components/footer.js" defer></script>
<custom-footer></custom-footer>
<script src="script.js"></script>
<script>
// Initialize tracker table for this page
document.addEventListener('DOMContentLoaded', function() {
const trackerData = [
{ id: 1, name: "SDK核心架构设计", status: "已完成", priority: "高", owner: "张明", deadline: "2024-01-15", progress: 100 },
{ id: 2, name: "量化算法集成", status: "进行中", priority: "高", owner: "李华", deadline: "2024-02-28", progress: 75 },
{ id: 3, name: "多平台兼容测试", status: "进行中", priority: "中", owner: "王伟", deadline: "2024-03-15", progress: 60 },
{ id: 4, name: "用户界面开发", status: "待开始", priority: "中", owner: "刘芳", deadline: "2024-04-10", progress: 0 },
{ id: 5, name: "性能优化测试", status: "进行中", priority: "高", owner: "陈强", deadline: "2024-03-01", progress: 40 },
{ id: 6, name: "文档编写", status: "已完成", priority: "低", owner: "赵敏", deadline: "2024-01-31", progress: 100 },
];
const tableBody = document.getElementById('trackerTableBody');
if (tableBody) {
trackerData.forEach(item => {
const row = document.createElement('tr');
row.className = 'hover:bg-red-50/30 transition-colors duration-200';
row.innerHTML = `
<td class="px-6 py-4 whitespace-nowrap text-sm font-medium text-gray-900">${item.id}</td>
<td class="px-6 py-4 text-sm text-gray-900 font-medium">${item.name}</td>
<td class="px-6 py-4 whitespace-nowrap">
<span class="px-3 py-1 rounded-full text-xs font-medium ${
item.status === '已完成' ? 'bg-green-100 text-green-800' :
item.status === '进行中' ? 'bg-yellow-100 text-yellow-800' :
'bg-gray-100 text-gray-800'
}">${item.status}</span>
</td>
<td class="px-6 py-4 whitespace-nowrap">
<span class="px-3 py-1 rounded-full text-xs font-medium ${
item.priority === '高' ? 'bg-red-100 text-red-800' :
item.priority === '中' ? 'bg-blue-100 text-blue-800' :
'bg-gray-100 text-gray-800'
}">${item.priority}</span>
</td>
<td class="px-6 py-4 whitespace-nowrap text-sm text-gray-700">${item.owner}</td>
<td class="px-6 py-4 whitespace-nowrap text-sm text-gray-700">${item.deadline}</td>
<td class="px-6 py-4 whitespace-nowrap">
<div class="flex items-center">
<div class="w-32 bg-gray-200 rounded-full h-2 mr-2">
<div class="h-2 rounded-full ${
item.progress === 100 ? 'bg-green-500' :
item.progress >= 50 ? 'bg-yellow-500' : 'bg-red-500'
}" style="width: ${item.progress}%"></div>
</div>
<span class="text-sm text-gray-700">${item.progress}%</span>
</div>
</td>
<td class="px-6 py-4 whitespace-nowrap text-sm text-gray-700">
<button class="text-primary hover:text-red-600 mr-3">
<i data-feather="edit-2" class="w-4 h-4"></i>
</button>
<button class="text-red-500 hover:text-red-700">
<i data-feather="trash-2" class="w-4 h-4"></i>
</button>
</td>
`;
tableBody.appendChild(row);
});
}
// Add new task button
document.getElementById('addNewTask')?.addEventListener('click', function() {
alert('添加新任务功能将在下一版本中实现!');
});
if (typeof feather !== 'undefined') {
feather.replace();
}
});
</script>
</body>
</html> |