refactor(ui): 替换CDN资源为本地文件并统一按钮样式
- 将Font Awesome从CDN引用改为本地文件/css/all.min.css - 为所有按钮添加图标以提升用户体验 - 修复登出弹窗的DOM加载问题 - 更新config.php中的数据库和SMTP配置
This commit is contained in:
@@ -111,7 +111,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['add_app'])) {
|
||||
<!-- Bootstrap CSS -->
|
||||
<link href="../css/bootstrap.min.css" rel="stylesheet">
|
||||
<!-- Font Awesome -->
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css">
|
||||
<link rel="stylesheet" href="/css/all.min.css">
|
||||
<!-- 自定义CSS -->
|
||||
<link rel="stylesheet" href="../styles.css">
|
||||
<script src="/js/sweetalert.js"></script>
|
||||
@@ -287,7 +287,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['add_app'])) {
|
||||
<label for="images" class="form-label"><i class="fas fa-upload me-2"></i>预览图片 (可多选)</label>
|
||||
</div>
|
||||
<button type="submit" name="add_app" class="btn btn-primary"><i class="fas fa-plus-circle me-2"></i>添加App</button>
|
||||
<a href="index.php" class="btn btn-secondary ms-2">取消</a>
|
||||
<a href="index.php" class="btn btn-secondary ms-2"><i class="fas fa-times me-1"></i>取消</a>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -64,7 +64,7 @@ $result = $conn->query($sql);
|
||||
<!-- Bootstrap CSS -->
|
||||
<link href="../css/bootstrap.min.css" rel="stylesheet">
|
||||
<!-- Font Awesome -->
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css">
|
||||
<link rel="stylesheet" href="/css/all.min.css">
|
||||
<!-- SweetAlert2 CSS -->
|
||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/sweetalert2@11/dist/sweetalert2.min.css">
|
||||
<!-- 自定义CSS -->
|
||||
|
||||
@@ -128,7 +128,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['edit_app'])) {
|
||||
<!-- Bootstrap CSS -->
|
||||
<link href="../css/bootstrap.min.css" rel="stylesheet">
|
||||
<!-- Font Awesome -->
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css">
|
||||
<link rel="stylesheet" href="/css/all.min.css">
|
||||
<!-- 自定义CSS -->
|
||||
<link rel="stylesheet" href="../styles.css">
|
||||
<script src="/js/sweetalert.js"></script>
|
||||
@@ -301,7 +301,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['edit_app'])) {
|
||||
<input class="form-control" type="file" id="images" name="images[]" multiple>
|
||||
</div>
|
||||
<button type="submit" name="edit_app" class="btn btn-primary"><i class="fas fa-save me-2"></i>保存修改</button>
|
||||
<a href="index.php" class="btn btn-secondary ms-2">取消</a>
|
||||
<a href="index.php" class="btn btn-secondary ms-2"><i class="fas fa-times me-1"></i>取消</a>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -65,7 +65,7 @@ if (!$resultApps) {
|
||||
<!-- Bootstrap CSS -->
|
||||
<link href="../css/bootstrap.min.css" rel="stylesheet">
|
||||
<!-- Font Awesome -->
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css">
|
||||
<link rel="stylesheet" href="/css/all.min.css">
|
||||
<!-- 自定义CSS -->
|
||||
<link rel="stylesheet" href="../styles.css">
|
||||
<script src="/js/sweetalert.js"></script>
|
||||
@@ -182,7 +182,7 @@ if (!$resultApps) {
|
||||
if (result.isConfirmed) {
|
||||
window.location.href = this.href;
|
||||
}
|
||||
});">删除</a>
|
||||
});"><i class="fas fa-trash-alt me-1"></i>删除</a>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endwhile; ?>
|
||||
|
||||
@@ -62,7 +62,7 @@ if (!isset($_SESSION['admin'])) {
|
||||
<!-- Bootstrap CSS -->
|
||||
<link href="../css/bootstrap.min.css" rel="stylesheet">
|
||||
<!-- Font Awesome -->
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css">
|
||||
<link rel="stylesheet" href="/css/all.min.css">
|
||||
<!-- 自定义CSS -->
|
||||
<link rel="stylesheet" href="../styles.css">
|
||||
<!-- 顶栏样式 -->
|
||||
@@ -135,11 +135,11 @@ if (!isset($_SESSION['admin'])) {
|
||||
<?php endif; ?> -->
|
||||
<form method="post">
|
||||
<div class="form-floating mb-3">
|
||||
<input type="text" class="form-control" id="username" name="username" required>
|
||||
<input type="text" class="form-control" id="username" name="username" placeholder="请输入用户名" required>
|
||||
<label for="username"><i class="fas fa-user me-2"></i>用户名</label>
|
||||
</div>
|
||||
<div class="form-floating mb-3">
|
||||
<input type="password" class="form-control" id="password" name="password" required>
|
||||
<input type="password" class="form-control" id="password" name="password" placeholder="请输入密码" required>
|
||||
<label for="password"><i class="fas fa-lock me-2"></i>密码</label>
|
||||
</div>
|
||||
<div class="form-check mb-3">
|
||||
|
||||
@@ -24,5 +24,14 @@ session_destroy();
|
||||
|
||||
// 使用Sweet Alert弹窗提示并跳转登录页
|
||||
echo '<script src="/js/sweetalert.js"></script>';
|
||||
echo '<script>Swal.fire({title: "登出成功", text: "您已安全登出系统", icon: "success", timer: 1500, showConfirmButton: false}).then(() => { window.location.href = "login.php"; });</script>';
|
||||
echo '<script>document.addEventListener("DOMContentLoaded", function() {
|
||||
Swal.fire({
|
||||
title: "登出成功",
|
||||
text: "您已安全登出系统",
|
||||
icon: "success",
|
||||
timer: 1500,
|
||||
showConfirmButton: false,
|
||||
target: document.body
|
||||
}).then(() => { window.location.href = "login.php"; });
|
||||
});</script>';
|
||||
exit();
|
||||
@@ -203,7 +203,7 @@ if (!$stmt) {
|
||||
<!-- Bootstrap CSS -->
|
||||
<link href="../css/bootstrap.min.css" rel="stylesheet">
|
||||
<!-- Font Awesome -->
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css">
|
||||
<link rel="stylesheet" href="/css/all.min.css">
|
||||
<!-- 自定义CSS -->
|
||||
<link rel="stylesheet" href="../styles.css">
|
||||
<!-- Fluent Design 模糊效果 -->
|
||||
|
||||
@@ -68,7 +68,7 @@ $tagsResult = $conn->query("SELECT * FROM tags ORDER BY created_at DESC");
|
||||
<title>标签管理 - 应用商店后台</title>
|
||||
<link href="../css/bootstrap.min.css" rel="stylesheet">
|
||||
<!-- Font Awesome -->
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css">
|
||||
<link rel="stylesheet" href="/css/all.min.css">
|
||||
<link rel="stylesheet" href="../styles.css">
|
||||
<script src="/js/sweetalert.js"></script>
|
||||
<script>
|
||||
|
||||
@@ -189,7 +189,7 @@ if (isset($_GET['success'])) {
|
||||
<!-- Bootstrap CSS -->
|
||||
<link href="../css/bootstrap.min.css" rel="stylesheet">
|
||||
<!-- Font Awesome -->
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css">
|
||||
<link rel="stylesheet" href="/css/all.min.css">
|
||||
<!-- 自定义CSS -->
|
||||
<link rel="stylesheet" href="../styles.css">
|
||||
<style>
|
||||
@@ -278,7 +278,15 @@ if (isset($_GET['success'])) {
|
||||
echo '文件不存在';
|
||||
}
|
||||
?></small>
|
||||
<div> <button type="button" class="btn btn-sm btn-outline-secondary action-btn" data-bs-toggle="modal" data-bs-target="#editVersionModal_<?php echo $version['id']; ?>"> 编辑 </button> <a href="../<?php echo htmlspecialchars($version['file_path']); ?>" class="btn btn-sm btn-primary action-btn" download>下载</a> <a href="?app_id=<?php echo $appId; ?>&delete_id=<?php echo $version['id']; ?>" class="btn btn-sm btn-outline-danger action-btn" onclick="return confirm('确定要删除此版本吗?');"> 删除 </a> </div>
|
||||
<div> <button type="button" class="btn btn-sm btn-outline-secondary action-btn" data-bs-toggle="modal" data-bs-target="#editVersionModal_<?php echo $version['id']; ?>">
|
||||
<i class="fas fa-edit me-1"></i>编辑
|
||||
</button>
|
||||
<a href="../<?php echo htmlspecialchars($version['file_path']); ?>" class="btn btn-sm btn-primary action-btn" download>
|
||||
<i class="fas fa-download me-1"></i>下载
|
||||
</a>
|
||||
<a href="?app_id=<?php echo $appId; ?>&delete_id=<?php echo $version['id']; ?>" class="btn btn-sm btn-outline-danger action-btn" onclick="return confirm('确定要删除此版本吗?');">
|
||||
<i class="fas fa-trash-alt me-1"></i>删除
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -309,8 +317,12 @@ if (isset($_GET['success'])) {
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">取消</button>
|
||||
<button type="submit" class="btn btn-primary" name="edit_version">保存更改</button>
|
||||
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">
|
||||
<i class="fas fa-times-circle me-1"></i>取消
|
||||
</button>
|
||||
<button type="submit" class="btn btn-primary" name="edit_version">
|
||||
<i class="fas fa-save me-1"></i>保存更改
|
||||
</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
@@ -141,7 +141,7 @@ if (!($conn instanceof mysqli)) {
|
||||
<!-- Bootstrap CSS -->
|
||||
<link href="../css/bootstrap.min.css" rel="stylesheet">
|
||||
<!-- Font Awesome -->
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css">
|
||||
<link rel="stylesheet" href="/css/all.min.css">
|
||||
<!-- SweetAlert2 CSS -->
|
||||
<link rel="stylesheet" href="/js/sweetalert.js/dist/sweetalert2.min.css">
|
||||
<!-- 自定义CSS -->
|
||||
|
||||
@@ -105,7 +105,7 @@
|
||||
<!-- Bootstrap CSS -->
|
||||
<link href="../css/bootstrap.min.css" rel="stylesheet">
|
||||
<!-- Font Awesome -->
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css">
|
||||
<link rel="stylesheet" href="/css/all.min.css">
|
||||
<link rel="stylesheet" href="../styles.css">
|
||||
<!-- 自定义CSS -->
|
||||
<link rel="stylesheet" href="../styles.css">
|
||||
|
||||
Reference in New Issue
Block a user