Sockets allowing for live updates rather than complete rebuilds #7
2 changed files with 6 additions and 3 deletions
|
|
@ -67,9 +67,9 @@ async function getFromServer(bodyInfo, source="", secure=false, password=adminPa
|
|||
// im suprised i didn't comment on this already but this is kinda lame desing
|
||||
// its not wrong but you know
|
||||
// it is easy which i like
|
||||
// and it overrides any other non-async alerts which is nice
|
||||
alertText("Error: Admin restricted action")
|
||||
} else if(!response.ok){
|
||||
throw new Error(data.error);
|
||||
alertText("Error: "+data.error);
|
||||
}
|
||||
// we add some information from the response just in case it is needed
|
||||
|
|
@ -508,7 +508,7 @@ async function generateVisualPlaylist(conditions="") {
|
|||
|
||||
async function submitSong(songid) {
|
||||
let returncode = await getFromServer({song: songid}, "songadd");
|
||||
if(returncode == ERR_NO_ADMIN) {
|
||||
if(returncode["status"] === ERR_NO_ADMIN) {
|
||||
// right now the error is alerted in getFromServer, maybe will change that
|
||||
} else if(returncode["status"]!==200) {
|
||||
alertText("That song's already in the queue! Hang on!")
|
||||
|
|
|
|||
|
|
@ -60,7 +60,6 @@ These are specific details on each section of the app, and how to use them
|
|||
- Accepts Play-Pause and Skip commands
|
||||
- Uses port 19054 by default
|
||||
- Can be changed in the `.env` file
|
||||
- The default port can be changed in the file
|
||||
- Running with `--admin (admin password)` sets an admin password for moderation on the client
|
||||
- ***Note: Do not reuse a password, the password is hashed before being sent over the network, but I still wouldn't bet my house on it, no security is guaranteed***
|
||||
- Anyone who knows the admin password can enter it on the client and change the abilities of any non-admin users (for example to limit skipping)
|
||||
|
|
@ -70,6 +69,9 @@ These are specific details on each section of the app, and how to use them
|
|||
- Add track to queue
|
||||
- Partymode toggle
|
||||
- Change volume
|
||||
- Add duplicate track to queue
|
||||
- This is a seperate toggle, but is based on the setting "Add track to queue"
|
||||
- Basically if you can't add at all, you can't add a duplicate either (obviously)
|
||||
- When this argument is left out a random string is generated and printed in console to be the admin password (so keep the console window hidden if you don't want to use it)
|
||||
|
||||
### Client:
|
||||
|
|
@ -89,6 +91,7 @@ From left to right:
|
|||
- Volume controls the VLC volume of the connected server
|
||||
- *Because the volume can be controlled in the client, for best usage set your device volume as high as possible and turn it down using this slider*
|
||||
- QR code to allow others to connect to and use the Remote
|
||||
- Admin password can be set to restrict actions for general users, or avoid the set restrictions
|
||||
|
||||
### A quick note on the password feature
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue