diff --git a/StartWebServer.bat b/StartWebServer.bat index b179f02..6cfaa1f 100644 --- a/StartWebServer.bat +++ b/StartWebServer.bat @@ -1,3 +1,3 @@ @ECHO OFF ECHO Starting Web Server... -python3 -m http.server \ No newline at end of file +python -m http.server \ No newline at end of file diff --git a/admin/index.html b/admin/index.html index 24803d6..aae22cb 100644 --- a/admin/index.html +++ b/admin/index.html @@ -60,6 +60,10 @@ Admin Dashboard
+ +
diff --git a/css/style.css b/css/style.css index 7721eb5..8053f68 100644 --- a/css/style.css +++ b/css/style.css @@ -1,3 +1,5 @@ +.news-item:nth-child(odd) {background: #CCC} + .accountbutton { display: inline-block; } diff --git a/help/assets/companyselect.png b/help/assets/companyselect.png new file mode 100644 index 0000000..cc0f38d Binary files /dev/null and b/help/assets/companyselect.png differ diff --git a/help/assets/preview.png b/help/assets/preview.png new file mode 100644 index 0000000..b5e8c07 Binary files /dev/null and b/help/assets/preview.png differ diff --git a/help/assets/sendcompany.png b/help/assets/sendcompany.png new file mode 100644 index 0000000..d4439cb Binary files /dev/null and b/help/assets/sendcompany.png differ diff --git a/help/assets/update.png b/help/assets/update.png new file mode 100644 index 0000000..5dc7415 Binary files /dev/null and b/help/assets/update.png differ diff --git a/help/assets/updateformation.png b/help/assets/updateformation.png new file mode 100644 index 0000000..17edac5 Binary files /dev/null and b/help/assets/updateformation.png differ diff --git a/help/css/style.css b/help/css/style.css new file mode 100644 index 0000000..7cd6d16 --- /dev/null +++ b/help/css/style.css @@ -0,0 +1,38 @@ +img { + width: 75% +} + +.mdl-layout__content { + margin-left: 10px; +} +.docs-toc { + font-size: 14px; + font-weight: 400; + line-height: 20px; + margin-left: 5px; +} + +.docs-toc ul { + border-left: solid 3px #3f51b5; + padding-left: 20px; + line-height: 28px +} + +.docs-toc a { + font-weight: 400; + color: #00BCD4 +} + +.docs-toc li { + font-size: 16px; + list-style: none +} + +a { + text-decoration: none; + color: black; +} + +td a { + color: #00BCD4; +} \ No newline at end of file diff --git a/help/index.html b/help/index.html new file mode 100644 index 0000000..910d97b --- /dev/null +++ b/help/index.html @@ -0,0 +1,154 @@ + + + + + Nokomis JROTC - Help + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+ + Help + +
+
+
+
+
+

Nokomis JROTC Admin Help

+

Contents

+ +
+

+ Account Login Information and External Services +

+ For security purposes, the account information cannot be listed here. However, the email for the accounts is nokomisarmyjrotc@gmail.com. + The password is the same as the one used on the computers in the JROTC office.
+
+ Here is the list of the external services that this app employs, their function, and their URL. + + + + + + + + + + + + + + + + + + + + + + + + + +
Service NameFunctionURL
FirebaseDatabase, Authentication, and Backend ServicesOpen
LetReachPush Notification ServiceOpen
WordpressBlogOpen
+

+ Update Next Formation Event +

+ To update the next event display found on the homepage, follow the steps below. +

+ 1. Go to the Admin Console. +

+

+ 2. Find the box as shown below. +

+ +

+ 3. Fill in fields with information of the next formation. +

+

+ 4. Click "Preview" to see changes in the preview box. +

+ +

+ 5. When satisfied with the results, press update to update homepage. +

+ +

+ Update Company Values and Comments +

+ To update the commanders cup points and the comments, located on the company pages, follow the steps below. +

+ 1. Go to the Admin Console. +

+

+ 2. Find the box as shown below. +

+
+ Choose the box that corresponds to the company that you wish to edit +
+ +
+
+ + + \ No newline at end of file diff --git a/js/script.js b/js/script.js index 4271264..05ce82f 100644 --- a/js/script.js +++ b/js/script.js @@ -1,7 +1,7 @@ function externalOnLoad() { var isMobile = window.orientation > -1; if (isMobile) { - location.href = "https://lax18.github.io/WebJROTC/index.html" + location.href = "https://lax18.github.io/MobileJROTC/index.html" } console.log("[index.html] LOADED") var data = readData("nextevent", function(data) { diff --git a/news.html b/news.html new file mode 100644 index 0000000..bb7564a --- /dev/null +++ b/news.html @@ -0,0 +1,87 @@ + + + + + Nokomis JROTC + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+
+ + News + +
+
info
+
+
+
+ Nokomis JROTC + +
+
+
+
+
+
+
+
+ + + \ No newline at end of file diff --git a/nscript.js b/nscript.js new file mode 100644 index 0000000..a7dacbd --- /dev/null +++ b/nscript.js @@ -0,0 +1,33 @@ +// onLoad Script to fetch and sort +function externalOnLoad() { +firebase.database().ref("news") + .orderByChild('timestamp') + .on('value', function(snapshot) { + this.data = []; + + snapshot.forEach(function(child) { + console.log(child) + var data = child.val + var a = document.createElement("div") + a.innerHTML = "

"+child.key+"

"+data.timestamp+"
"+data.content+"
" + document.getElementById("news-holder").appendChild(a); + }.bind(this)); + +}); +} + +// Firebase Scripts +// global read data and place on page function +function setData(ref, element, read1) { + var array = readData(ref, function(array) { + document.getElementById(element).innerHTML = array[read1] + }); +} + +function readData(ref, callback) { + var nextformation = firebase.database().ref(ref); + nextformation.on("value", function(data) { + var array = data.val(); + callback(array) + }); +} \ No newline at end of file diff --git a/ribbon/css/style.css b/ribbon/css/style.css index 27165a9..5e6f742 100644 --- a/ribbon/css/style.css +++ b/ribbon/css/style.css @@ -1,3 +1,7 @@ +.ribbon-center { + justify-content: center; +} + .ribbons-display { margin-left: auto; margin-right: auto; @@ -27,11 +31,11 @@ } .ribbons { - margin-right: auto; + margin-right: auto; margin-left: 0px; display: inline; } .ribbon_selector { margin: auto; -} \ No newline at end of file +} diff --git a/ribbon/index.html b/ribbon/index.html index cb9e25f..b2a6500 100644 --- a/ribbon/index.html +++ b/ribbon/index.html @@ -49,12 +49,12 @@
-
- +
+
- \ No newline at end of file + diff --git a/ribbon/js/script.js b/ribbon/js/script.js index 090e8cf..f9b3eea 100644 --- a/ribbon/js/script.js +++ b/ribbon/js/script.js @@ -1,5 +1,5 @@ // Ribbon Rack Builder -// v.2 +// v.2.0.1 // // // (C) 2019 Nicholas Pease @@ -17,7 +17,7 @@ function onLoad() { var newelement = document.createElement("span") newelement.setAttribute("class", "ribbon-selector-span") if (i <= 1) { - newelement.innerHTML = "

" + ribbon_name[i] + "
 

" + newelement.innerHTML = "

" + ribbon_name[i] + "
 

" } else { newelement.innerHTML = "

" + ribbon_name[i] + "
" + ribbon_filename[i] + "

" } @@ -47,6 +47,7 @@ function updatePage() { img.setAttribute("src", "assets/ribbons/" + ribbon_filename[i] + ".gif"); img.setAttribute("width", "33%"); img.setAttribute("class", "ribbons") + var ribbbonselector = document.getElementById() if (ribbons <= 3) { console.log(rows) img.setAttribute("id",ribbons)