mirror of
https://github.com/grocy/grocy.git
synced 2025-10-15 09:46:03 +00:00
Implemented "Scan mode"
This commit is contained in:
26
public/js/grocy_uisound.js
Normal file
26
public/js/grocy_uisound.js
Normal file
@@ -0,0 +1,26 @@
|
||||
Grocy.UISound = { };
|
||||
|
||||
Grocy.UISound.Play = function(url)
|
||||
{
|
||||
new Audio(url).play();
|
||||
}
|
||||
|
||||
Grocy.UISound.AskForPermission = function()
|
||||
{
|
||||
Grocy.UISound.Play(U("/uisounds/silence.mp3"));
|
||||
}
|
||||
|
||||
Grocy.UISound.Success = function()
|
||||
{
|
||||
Grocy.UISound.Play(U("/uisounds/success.mp3"));
|
||||
}
|
||||
|
||||
Grocy.UISound.Error = function()
|
||||
{
|
||||
Grocy.UISound.Play(U("/uisounds/error.mp3"));
|
||||
}
|
||||
|
||||
Grocy.UISound.BarcodeScannerBeep = function()
|
||||
{
|
||||
Grocy.UISound.Play(U("/uisounds/barcodescannerbeep.mp3"));
|
||||
}
|
Reference in New Issue
Block a user