{"id":182,"date":"2014-05-05T13:44:01","date_gmt":"2014-05-05T13:44:01","guid":{"rendered":"http:\/\/www.autorouter.eu\/wiki\/?page_id=182"},"modified":"2014-05-05T21:14:51","modified_gmt":"2014-05-05T21:14:51","slug":"fpal-document-list","status":"publish","type":"page","link":"https:\/\/www.autorouter.aero\/wiki\/flight-plan-addressing\/fpal-document-list\/","title":{"rendered":"FPAL &#8211; Document List"},"content":{"rendered":"<p>These are the current FPAL documents. Click on a document to view it.<\/p>\n<p>&nbsp;<\/p>\n<p>Most recent update: <span id=\"fpalmostrecent\"><\/span><\/p><ul id=\"fdallist\"><\/ul><a><span id=\"fpalmissingspan\" style=\"cursor: pointer\">Currently missing countries<\/span><\/a><ul id=\"fpalmissinglist\" style=\"display: none\"><\/ul><div id=\"fpaldocumentdiv\" style=\"display: none;\"><h1>Viewing document \"<span id=\"fpaldocumentid\"><\/span>\"<\/h1><span id=\"fpaldocument\"><\/span><\/div><script>\n\t\t\t\tjQuery.getJSON(\"\/api\/flightplan\/fpal\/countrycodes\", function(fpalCC) {\n\t\t\t\t\tjQuery.get(\"\/api\/flightplan\/fpal\", function(data)\n\t\t\t\t\t{\n\t\t\t\t\t\tvar fdalList = jQuery(\"#fdallist\");\n\t\t\t\t\t\tvar timeMostRecent = 0;\n\t\t\t\t\t\tvar countriesCovered = {};\n\t\t\t\t\t\tjQuery.each(data, function(index, fpalDocument)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (fpalDocument.modified > timeMostRecent)\n\t\t\t\t\t\t\t\ttimeMostRecent = fpalDocument.modified;\n\t\t\t\t\t\t\tvar cname = fpalCC[fpalDocument.id];\n\t\t\t\t\t\t\tif (cname === undefined) {\n\t\t\t\t\t\t\t\tif (fpalDocument.id === \"gen\") {\n\t\t\t\t\t\t\t\t\tcname = \"Generic (gen)\";\n\t\t\t\t\t\t\t\t} else if (fpalDocument.id === \"def\") {\n\t\t\t\t\t\t\t\t\tcname = \"Definitions (def)\";\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\tcname = fpalDocument.id;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tcname += \" (\" + fpalDocument.id + \")\";\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tvar node = \"<li class=\\\"fdal\\\" data-fpalid=\\\"\" + fpalDocument.id + \"\\\"><a href=\\\"#\" + fpalDocument.id + \"\\\">\" + cname + \"<\/a>\" +\n\t\t\t\t\t\t\t\t\t\", dated \" + new Date(fpalDocument.modified * 1000).toUTCString() + \"<\/li>\";\n\t\t\t\t\t\t\tif (fpalDocument.id === \"def\") {\n\t\t\t\t\t\t\t\tfdalList.prepend(node);\n\t\t\t\t\t\t\t} else if (fpalDocument.id === \"gen\") {\n\t\t\t\t\t\t\t\tjQuery(\"li:first-child\", fdalList).after(node);\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tfdalList.append(node);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tcountriesCovered[fpalDocument.id] = true;\n\t\t\t\t\t\t});\n\t\t\t\t\t\tjQuery(\"#fpalmostrecent\").html(new Date(timeMostRecent * 1000).toUTCString());\n\t\t\t\t\t\tjQuery(\"li.fdal[data-fpalid=\\\"\" + window.location.hash.substr(1) + \"\\\"]\").click();\n\t\t\t\t\t\tvar fpalMissingList = jQuery(\"#fpalmissinglist\");\n\t\t\t\t\t\tjQuery.each(fpalCC, function(code) {\n\t\t\t\t\t\t\tif (countriesCovered[code] === undefined) {\n\t\t\t\t\t\t\t\tfpalMissingList.append(\"<li>\" + code + \": \" + fpalCC[code] + \"<\/li>\");\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t\tjQuery(\"#fdallist\").on(\"click\", \"li.fdal\", function()\n\t\t\t\t\t{\n\t\t\t\t\t\tvar fpalDocumentId = jQuery(this).data(\"fpalid\");\n\t\t\t\t\t\tvar docName = fpalCC[fpalDocumentId];\n\t\t\t\t\t\tif (docName === undefined) {\n\t\t\t\t\t\t\tif (fpalDocumentId === \"gen\") {\n\t\t\t\t\t\t\t\tdocName = \"Generic (gen)\";\n\t\t\t\t\t\t\t} else if (fpalDocumentId === \"def\") {\n\t\t\t\t\t\t\t\tdocName = \"Definitions (gen)\";\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tdocName = fpalDocumentId;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tdocName += \" (\" + fpalDocumentId + \")\";\n\t\t\t\t\t\t}\n\t\t\t\t\t\tjQuery(\"#fpaldocumentid\").text(docName);\n\t\t\t\t\t\tjQuery.get(\"\/api\/flightplan\/fpal\/\" + fpalDocumentId, function(data)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tdata = data.replace(\"\\\"\", \"&quot;\");\n\t\t\t\t\t\t\tdata = data.replace(\/\\t\/g, \"    \");\n\t\t\t\t\t\t\tjQuery(\"#fpaldocument\").html(\"<pre>\" + data.replace(\/\\<\/g, \"&lt;\") + \"<\/pre>\");\n\t\t\t\t\t\t\tjQuery(\"#fpaldocumentdiv\").show();\n\t\t\t\t\t\t\tjQuery(\"html, body\").animate(\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tscrollTop: jQuery(\"#fpaldocumentdiv\").offset().top\n\t\t\t\t\t\t\t}, 500);\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t\tjQuery(\"#fpalmissingspan\").click(function() {\n\t\t\t\t\t\tjQuery(\"#fpalmissinglist\").slideToggle();\n\t\t\t\t\t});\n\t\t\t\t})<\/script>\n","protected":false},"excerpt":{"rendered":"<p>These are the current FPAL documents. Click on a document to view it. &nbsp;<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":157,"menu_order":0,"comment_status":"closed","ping_status":"open","template":"","meta":{"footnotes":""},"class_list":["post-182","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.autorouter.aero\/wiki\/wp-json\/wp\/v2\/pages\/182","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.autorouter.aero\/wiki\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.autorouter.aero\/wiki\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.autorouter.aero\/wiki\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.autorouter.aero\/wiki\/wp-json\/wp\/v2\/comments?post=182"}],"version-history":[{"count":6,"href":"https:\/\/www.autorouter.aero\/wiki\/wp-json\/wp\/v2\/pages\/182\/revisions"}],"predecessor-version":[{"id":207,"href":"https:\/\/www.autorouter.aero\/wiki\/wp-json\/wp\/v2\/pages\/182\/revisions\/207"}],"up":[{"embeddable":true,"href":"https:\/\/www.autorouter.aero\/wiki\/wp-json\/wp\/v2\/pages\/157"}],"wp:attachment":[{"href":"https:\/\/www.autorouter.aero\/wiki\/wp-json\/wp\/v2\/media?parent=182"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}