<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
  <meta charset="UTF-8" />
  <meta http-equiv="pragma" content="no-cache" />
  <meta http-equiv="expires" content="0" />
  <meta http-equiv="cache-control" content="no-cache, no-store, must-revalidate" />
  <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no" />
  <title>Error</title>
  <link rel="shortcut icon" th:href="@{'/favicon.ico'}" />
  <link rel="stylesheet" th:href="@{'/css/reset.css'}">
  <link rel="stylesheet" th:href="@{'/css/public.css'}">
  <link rel="stylesheet" th:href="@{'/js/plugins/layui/css/layui.css'}">
  <style>
    body { background: #f4f4f5; }
    .error-icon-404 {
        display: block; width: 128px; height: 128px; margin: 0 auto 20px;
        background: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIAAAACACAMAAAD04JH5AAAAq1BMVEUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA0NbREAAAAOHRSTlMAgEDSb8ClbXi1hbpTOGAK8erf7tplKfYwInQd5VxEGBMO1sl9ZwXznrGtqllOkUjDt0smzpmLoii4lvQAAATtSURBVHja7NXZcqJQGATgVkGNorJYgEsB6gSjEmPFJf3+TzYHcDxF5ibKllTlu2MpaH5oDn79cL7rBqjN85NOwdi9og5NkzeHCSqnMXFaMja3UbFXkvrZAzDSDiSNimdgO6S6wJU2J8eo1IY8hbiZWaSCCtkkMzOPyDkq1CNfkDEmm6jO6b/bNcgeqmOQyGqSW1SHtJA1I1eojk4HWUdSRXWWsgTyx9hGNRYAPsgppHRPJzlYtnC/DJPnNUNA8h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AAFgkAH2BKNQBigD3SA0IAPwVADLAegE/bPDcGy/v3MJYA4Qz4TZQJwBjwzXM+WIFpbiuO8B4lRRIgAKYLCTCDOu9jAODvFMZ7Ad36AM+tBdBcDbUjBIZE0hHIWWANK1wNKwI6VBXgAGY5AFUBhwoA/dVw/v9HYEmfQ/tij1oAJeojEOkBYqQb6f3mQQMQ1QckYK1Tfqw854aAFLyV/SUN/dNjuiGA+ih0uCmANsj1QLcFUM/DRYFNHwhw1N8PvBrnSv7D3GBF7S8mLaAFfHrAkRoqOwEyaqiXE2C2pEaKcAJgQE2UjgE88W+Yvjt061yb369OXTSaQ2ShwXpE5L6hsXrEWtw1lEttbZ+gv2WLvhEMjN+8AAAAAElFTkSuQmCC') no-repeat;
        background-size: 100%;
    }
    .error-container {

    }
  </style>
</head>
<body>
<div class="hjcl-layout-top mt-4">
  <div th:replace="~{components/language::language}"></div>
</div>
<div class="error-container p-4">
  <div class="p-4 box-border text-black bg-white rounded-lg font-sans">

    <div>
      <div th:if="${errorMessage != null}" th:text="${errorMessage}"></div>
      <div th:if="${errorMessage == null}" class="text-base mb-2">找不到页面或资源</div>
    </div>
    <div class="flex mt-2">
      <div class="text-sm mr-4"><a href="/" class="link">返回首页</a></div>
      <div class="text-sm mr-4"><a href="javascript:history.back()" class="link">返回上一页</a></div>
      <div class="text-sm mr-4"><a href="javascript:;" class="link" id="clear-cache">清除缓存</a></div>
    </div>

    <script>
        document.addEventListener("DOMContentLoaded", function () {
            const clearCacheLink = document.getElementById("clear-cache");
            clearCacheLink.addEventListener("click", function () {
                const isConfirmed = confirm("确定要清除缓存吗？这将删除所有Cookie。");
                if (isConfirmed) {
                    clearAllCookies();
                }
            });
        });
        function clearAllCookies() {
            const cookies = document.cookie.split(";");
            for (let i = 0; i < cookies.length; i++) {
                const cookie = cookies[i];
                const eqPos = cookie.indexOf("=");
                const name = eqPos > -1 ? cookie.substr(0, eqPos) : cookie;
                document.cookie = name + "=;expires=Thu, 01 Jan 1970 00:00:00 GMT;path=/";
            }
        }
    </script>

  </div>
</div>

</body>
</html>