新增“数据编辑”
This commit is contained in:
		@@ -81,6 +81,17 @@
 | 
			
		||||
        cursor: pointer;
 | 
			
		||||
        font-weight: 500;
 | 
			
		||||
        transition: all 0.3s;
 | 
			
		||||
        margin: 0 2px;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    .edit-btn {
 | 
			
		||||
        background: linear-gradient(to right, #4CAF50, #45a049);
 | 
			
		||||
        color: white;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    .edit-btn:hover {
 | 
			
		||||
        transform: translateY(-2px);
 | 
			
		||||
        box-shadow: 0 4px 8px rgba(76, 175, 80, 0.3);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    .delete-btn {
 | 
			
		||||
@@ -122,7 +133,7 @@
 | 
			
		||||
 | 
			
		||||
<div class="container">
 | 
			
		||||
    <h2>所有已录入的奖项信息</h2>
 | 
			
		||||
    <p>在此页面可以查看所有已录入的成果信息,并进行删除操作</p>
 | 
			
		||||
    <p>在此页面可以查看所有已录入的成果信息,并进行编辑和删除操作</p>
 | 
			
		||||
 | 
			
		||||
    <div class="table-container">
 | 
			
		||||
        <table>
 | 
			
		||||
@@ -144,9 +155,12 @@
 | 
			
		||||
                            <td>{% if item.students is string %}{{ item.students or '无' }}{% else %}{{ item.students|join(', ') if item.students else '无' }}{% endif %}</td>
 | 
			
		||||
                            <td>{% if item.teacher is string %}{{ item.teacher or '无' }}{% else %}{{ item.teacher|join(', ') if item.teacher else '无' }}{% endif %}</td>
 | 
			
		||||
                            <td style="text-align: center;">
 | 
			
		||||
                                <form action="{{ url_for('delete_entry', doc_id=item._id) }}" method="POST" onsubmit="return confirm('确定要删除这条记录吗?')">
 | 
			
		||||
                                    <button type="submit" class="action-button delete-btn">删除</button>
 | 
			
		||||
                                </form>
 | 
			
		||||
                                <div style="display: flex; justify-content: center; gap: 8px;">
 | 
			
		||||
                                    <a href="{{ url_for('edit_entry', doc_id=item._id) }}" class="action-button edit-btn">编辑</a>
 | 
			
		||||
                                    <form action="{{ url_for('delete_entry', doc_id=item._id) }}" method="POST" onsubmit="return confirm('确定要删除这条记录吗?')" style="margin: 0;">
 | 
			
		||||
                                        <button type="submit" class="action-button delete-btn">删除</button>
 | 
			
		||||
                                    </form>
 | 
			
		||||
                                </div>
 | 
			
		||||
                            </td>
 | 
			
		||||
                        </tr>
 | 
			
		||||
                    {% endfor %}
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user