Restructure (unfinished)

This commit is contained in:
Vortrex
2022-03-12 05:20:14 -06:00
parent 2dc6d65a50
commit ef4a2877d0
51 changed files with 2314 additions and 2524 deletions

View File

@@ -7,6 +7,27 @@
// TYPE: Server (JavaScript)
// ===========================================================================
class RadioStationData {
constructor(dbAssoc = false) {
this.databaseId = 0;
this.name = "";
this.url = "";
this.genre = "";
this.codec = "";
this.index = -1;
if(dbAssoc) {
this.databaseId = dbAssoc["radio_id"];
this.name = dbAssoc["radio_name"];
this.url = dbAssoc["radio_url"];
this.genre = dbAssoc["radio_genre"];
this.codec = dbAssoc["radio_codec"];
}
}
};
// ===========================================================================
function initRadioScript() {
logToConsole(LOG_INFO, "[VRR.Radio]: Initializing radio script ...");
getServerData().radioStations = loadRadioStationsFromDatabase();