{"id":227,"date":"2021-06-21T15:30:17","date_gmt":"2021-06-21T07:30:17","guid":{"rendered":"http:\/\/std.puiching.edu.mo\/~pcmsams\/?page_id=227"},"modified":"2021-06-21T15:30:26","modified_gmt":"2021-06-21T07:30:26","slug":"weatherwarning","status":"publish","type":"page","link":"https:\/\/std.puiching.edu.mo\/~pcmsams\/index.php\/weatherdata\/weatherwarning\/","title":{"rendered":"\u5929\u6c23\u8b66\u544a\u8a18\u9304"},"content":{"rendered":"<!DOCTYPE html>\r\n<html>\r\n  <head>\r\n    <meta charset=\"utf-8\">\r\n    <meta name=\"description\" content=\"\u8cc7\u6599\u75312021\u5e741\u6708\u8d77\uff0c\u63d0\u4f9b\u6fb3\u9580\u6c23\u8c61\u5c40\u5929\u6c23\u8b66\u544a\u767c\u51fa\u8a18\u9304\u67e5\u8a62\">\r\n    <script src=\"..\/..\/..\/js\/jquery-3.5.1.min.js\"><\/script>\r\n    <link rel=\"stylesheet\" href=\"..\/..\/..\/css\/weatherData\/searchElement.css\">\r\n  <\/head>\r\n  <body>\r\n    <div class=\"mainTitle\">\r\n      \u5929\u6c23\u8b66\u544a\u8a18\u9304\r\n    <\/div>\r\n    <div class=\"mainContainer\">\r\n      <div class=\"card\" id=\"\">\r\n        <div class=\"cardContent\">\r\n          <form id=\"warningForm\">\r\n            <fieldset>\r\n                \u958b\u59cb\u6708\u4efd\uff1a<input type=\"month\" name=\"startDate\" id=\"startDate\" min=\"1999-01\" max=2026-04>\r\n                \u7d50\u675f\u6708\u4efd\uff1a<input type=\"month\" name=\"endDate\" id=\"endDate\" min=\"1999-01\" max=2026-04>\r\n                <input type=\"checkbox\" id=\"searchBy\" name=\"searchBy\" value=\"history\">\r\n                <label for=\"searchBy\">\u6709\u8a18\u9304\u4ee5\u4f86<\/label>\r\n              <span class=\"selectName\">\u5929\u6c23\u8b66\u544a\uff1a<\/span><select name=\"warning\" id=\"warning\">\r\n                <optgroup label=\"\u66b4\u96e8\u8b66\u544a\">\r\n                  <option value=\"yellowRainstorm\" type=\"rainstorm\">\u9ec3\u8272\u66b4\u96e8\u8b66\u544a(\u65b0\u5236)<\/option>\r\n                  <option value=\"redRainstorm\" type=\"rainstorm\">\u7d05\u8272\u66b4\u96e8\u8b66\u544a(\u65b0\u5236)<\/option>\r\n                  <option value=\"blackRainstorm\" type=\"rainstorm\">\u9ed1\u8272\u66b4\u96e8\u8b66\u544a(\u65b0\u5236)<\/option>\r\n                  <option value=\"oldRedRainstorm\" type=\"rainstorm\">\u7d05\u8272\u66b4\u96e8\u8b66\u544a(2004\u5e74\u524d)<\/option>\r\n                  <option value=\"oldBlackRainstorm\" type=\"rainstorm\">\u9ed1\u8272\u66b4\u96e8\u8b66\u544a(2004\u5e74\u524d)<\/option>\r\n                  <option value=\"oldRainstorm\" type=\"rainstorm\">\u66b4\u96e8\u8b66\u544a\u4fe1\u865f(\u820a\u5236)<\/option>\r\n                  <option value=\"allRainstorm\" type=\"rainstorm\">\u6240\u6709\u66b4\u96e8\u8b66\u544a<\/option>\r\n                <\/optgroup>\r\n                <optgroup label=\"\u5176\u5b83\u5929\u6c23\u8b66\u544a\">\r\n                  <option value=\"thunderstorm\" type=\"thunderstorm\">\u96f7\u66b4\u8b66\u544a<\/option>\r\n                  <option value=\"monsoon\" type=\"monsoon\">\u5f37\u70c8\u5b63\u5019\u98a8\u4fe1\u865f(\u9ed1\u7403)<\/option>\r\n                  <option value=\"stormsurge\" type=\"stormsurge\">\u98a8\u66b4\u6f6e\u8b66\u544a<\/option>\r\n                <\/optgroup>\r\n              <\/select>\r\n              \u8acb\u9078\u64c7\uff1a<select name=\"record\" id=\"record\">\r\n                      <option value=\"all\">\u5168\u90e8\u767c\u51fa\u8a18\u9304<\/option>\r\n                      <option value=\"longest\">\u6700\u9577\u6301\u7e8c\u6642\u9593\u8a18\u9304<\/option>\r\n                      <option value=\"shortest\">\u6700\u77ed\u6301\u7e8c\u6642\u9593\u8a18\u9304<\/option>\r\n                <\/select>\r\n              <input type=\"submit\" id=\"submit\">\r\n            <\/fieldset>\r\n          <\/form>\r\n          <div id=\"form-message\">\r\n            <p class=\"selectRemark\">\r\n              \u8acb\u9078\u64c7\r\n            <\/p>\r\n          <\/div>\r\n        <\/div>\r\n        <\/div>\r\n      <\/div>\r\n      <div class=\"card reminder\">\r\n        <div class=\"cardTitle\">\r\n          \u5099\u8a3b\r\n        <\/div>\r\n        <div class=\"cardContent\">\r\n          <ul>\r\n            <li>\u66b4\u96e8\u8b66\u544a\u53ca\u96f7\u66b4\u8b66\u544a\u8cc7\u6599\u75312000\u5e74\u8d77\uff1b\u5f37\u70c8\u5b63\u5019\u98a8\u8b66\u544a(\u9ed1\u7403)\u8cc7\u6599\u75311999\u5e74\u8d77\uff1b\u98a8\u66b4\u6f6e\u8b66\u544a\u8cc7\u6599\u75312009\u5e74\u8d77\u3002<\/li>\r\n            <li>\u66b4\u96e8\u8b66\u544a\u65bc1992\u5e74\u81f32004\u5e746\u670830\u65e5\u671f\u9593\u4f7f\u7528\u7d05\u3001\u9ed1\u5169\u7d1a\u5236\uff0c2004\u5e747\u67081\u65e5\u81f32020\u5e748\u670831\u65e5\u671f\u9593\u4f7f\u7528\u4e0d\u5206\u984f\u8272\u7684\u66b4\u96e8\u8b66\u544a\u4fe1\u865f\uff08\u820a\u5236\uff09\uff0c2020\u5e749\u67081\u65e5\u8d77\u4f7f\u7528\u9ec3\u3001\u7d05\u3001\u9ed1\u4e09\u7d1a\u5236\uff08\u65b0\u5236\uff09\u3002<\/li>\r\n            <li>1992\u5e74\u81f32004\u5e746\u670830\u65e5\u671f\u9593\u4f7f\u7528\u7684\u7d05\u3001\u9ed1\u5169\u7d1a\u5236\u66b4\u96e8\u8b66\u544a\u8207\u65b0\u5236\u7684\u7d05\u3001\u9ed1\u66b4\u96e8\u8b66\u544a\u6a19\u6e96\u4e0d\u540c\u3002<\/li>\r\n            <li>\u66b4\u96e8\u8b66\u544a\u5831\u544a\u53ef\u5230\u6c23\u8c61\u5c40\u7db2\u7ad9\u700f\u89bd\u3002<\/li>\r\n          <\/ul>\r\n        <\/div>\r\n      <\/div>\r\n    <\/div>\r\n    <script type=\"text\/javascript\">\r\n    $(\"body\").delegate(\".removeSearchStationDataChart\", \"click\", function(){\r\n          $(\"#form-message\").html(\"<p class='selectRemark'>\u8acb\u9078\u64c7<\/p>\");\r\n    });\r\n\r\n    $(\"#searchBy\").click(function() {\r\n        if($(this).is(':checked')){\r\n          $(\"input[type=month]\").prop('disabled', true);\r\n        }else{\r\n          $(\"input[type=month]\").prop('disabled', false);\r\n        }\r\n    });\r\n\r\n    $(\"#warningForm\").submit(function(event){\r\n      event.preventDefault();\r\n      var startDate = $(\"#startDate\").val();\r\n      var endDate = $(\"#endDate\").val();\r\n      var warning = $(\"#warning\").val();\r\n      var type = $(\"option:selected\", this).attr('type');\r\n      var record = $(\"#record\").val();\r\n      if($(\"#searchBy\").is(':checked')){\r\n          startDate = \"1999-01\";\r\n          var d = new Date();\r\n          var month = d.getMonth()+1;\r\n          endDate = d.getFullYear() + '-' + (month<10 ? '0' : '') + month;\r\n      }\r\n\r\n      if(startDate==\"\"){\r\n        $(\"#form-message\").html(\"<p class='selectRemark' style='color:red;'>\u8acb\u9078\u958b\u59cb\u6708\u4efd<\/p>\");\r\n      }else if(endDate==\"\"){\r\n        $(\"#form-message\").html(\"<p class='selectRemark' style='color:red;'>\u8acb\u9078\u7d50\u675f\u6708\u4efd<\/p>\");\r\n      }else if(endDate<startDate){\r\n        $(\"#form-message\").html(\"<p class='selectRemark' style='color:red;'>\u7d50\u675f\u6708\u4efd\u65e9\u65bc\u958b\u59cb\u6708\u4efd<\/p>\");\r\n      }else{\r\n      $(\"#form-message\").html(\"<p class='selectRemark'>\u6578\u64da\u6293\u53d6\u4e2d\uff0c\u8acb\u7a0d\u7b49<\/p>\");\r\n      var url = '..\/..\/..\/pages\/weatherData\/weatherWarning\/search.php?startDate='+startDate+'&endDate='+endDate+'&warning='+warning+'&type='+type+'&record='+record;\r\n      xmlhttp = new XMLHttpRequest();\r\n      xmlhttp.onreadystatechange = function() {\r\n          if (this.readyState == 4 && this.status == 200) {\r\n              $(\"#form-message\").html(this.responseText);\r\n              $(\"#form-message\").append(\"<p class='removeSearchStationDataChart'>\u9084\u539f\u67e5\u8a62<\/p>\");\r\n          }\r\n    }\r\n    };\r\n      xmlhttp.open(\"GET\",url ,true);\r\n      xmlhttp.send();\r\n    });\r\n    <\/script>\r\n  <\/body>\r\n<\/html>\n","protected":false},"excerpt":{"rendered":"","protected":false},"author":1,"featured_media":0,"parent":25,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-227","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/std.puiching.edu.mo\/~pcmsams\/index.php\/wp-json\/wp\/v2\/pages\/227","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/std.puiching.edu.mo\/~pcmsams\/index.php\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/std.puiching.edu.mo\/~pcmsams\/index.php\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/std.puiching.edu.mo\/~pcmsams\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/std.puiching.edu.mo\/~pcmsams\/index.php\/wp-json\/wp\/v2\/comments?post=227"}],"version-history":[{"count":1,"href":"https:\/\/std.puiching.edu.mo\/~pcmsams\/index.php\/wp-json\/wp\/v2\/pages\/227\/revisions"}],"predecessor-version":[{"id":228,"href":"https:\/\/std.puiching.edu.mo\/~pcmsams\/index.php\/wp-json\/wp\/v2\/pages\/227\/revisions\/228"}],"up":[{"embeddable":true,"href":"https:\/\/std.puiching.edu.mo\/~pcmsams\/index.php\/wp-json\/wp\/v2\/pages\/25"}],"wp:attachment":[{"href":"https:\/\/std.puiching.edu.mo\/~pcmsams\/index.php\/wp-json\/wp\/v2\/media?parent=227"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}