issue #10 #11 Apply 2nd welcome suppression feature.

This commit is contained in:
paul kim
2024-05-08 15:14:51 +09:00
parent 1b0d48a31f
commit f2046b2cb3
8 changed files with 51 additions and 38 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 64 KiB

After

Width:  |  Height:  |  Size: 65 KiB

View File

@@ -924,23 +924,6 @@ HotelTV.hcap = (function() {
_devinfo["power_mode"] = hcap.power.PowerMode.NORMAL;
console.log("power_mode mode set as " + _devinfo["power_mode"]);
});
// hcap.power.getPowerMode({
// "onSuccess": function(s) {
// console.log("onSuccess power mode " + s.mode);
// if (s.mode != hcap.power.PowerMode.NORMAL) {
// hcap.power.setPowerMode({
// "mode": hcap.power.PowerMode.NORMAL,
// "onSuccess": null,
// "onFailure": function(f) {
// console.log("onFailure : errorMessage = " + f.errorMessage);
// }
// });
// }
// },
// "onFailure": function(f) {
// console.log("onFailure : errorMessage = " + f.errorMessage);
// }
// });
}
}

View File

@@ -28,7 +28,7 @@ var HotelTV = HotelTV || {
'message': {},
'translation': {},
'state': {
'lang': 'kr',
'lang': 'en-US',
'menu': {
'stage': {
'cur':null,
@@ -208,7 +208,6 @@ HotelTV.Init = async function() {
//SETP#02::> Set Debug Options
__fxn_Set_DebugOpt(false, 'osd', false);
//__fxn_Set_DebugOpt(true, 'native', true);
//STEP#03::> Get Device Info
HotelTV.ui_utils.SetBusy(true);
@@ -490,19 +489,32 @@ HotelTV.Init = async function() {
sessionStorage.setItem("translation", JSON.stringify(HotelTV.translation));
//Now Switch Over Welcome page
if (HotelTV.opening != null) {
const __ifxn_getAndrestorBgServiceInfo = async function() {
try {
HotelTV.services = await HotelTV.api.GetServiceInfo();
sessionStorage.setItem("services", JSON.stringify(HotelTV.services));
} catch (_error) {
console.error("Display Error page for get service info");
}
}
if (HotelTV.opening != null ) {
if ( HotelTV.guestinfo.watchTV==true ) {
HotelTV.state.lang = HotelTV.guestinfo.language;
__ifxn_getAndrestorBgServiceInfo();
HotelTV.UnloadWelCome(true, 2000);
} else {
$(".startup").fadeOut(1000, function() {
window.location.replace('./wellcome.html');
});
} else {
if (HotelTV.state['registration'].license == 'hotel-full') {
setTimeout(function() {
window.location.replace('./app_hoteltv_full.html');
}, 1000);
}
}
} else {
let _tmval = 30;
__ifxn_getAndrestorBgServiceInfo();
HotelTV.state.lang = HotelTV.guestinfo.language;
HotelTV.UnloadWelCome(true, 2000);
}
} else {
let _tmval = 60;
HotelTV.ui_utils.ShowErrMsg(true,
"system.error.unregistered-device",
"SYSTEM ERROR",
@@ -517,7 +529,8 @@ HotelTV.Init = async function() {
}
},
"cb_eoe": function() {
$('.error #countdown #message').text(`The Device ID is ${HotelTV.devinfo.serial_number}.\r\n\r\nPlease reboot the device by manualy(using remote contoller)`);
$('.error #countdown #message').text(`The Device ID is ${HotelTV.devinfo.serial_number}.\r\n\r\nSystem will be reboot`);
setTimeout(HotelTV.hcap.Reboot, 500);
}
}
);
@@ -535,7 +548,6 @@ HotelTV.LoadWelCome = async function() {
HotelTV.dbginfo = await JSON.parse(sessionStorage.getItem("dbginfo"));
//SETP#02::> Set Debug Options
__fxn_Set_DebugOpt(false, 'native', true);
//__fxn_Set_DebugOpt(true, 'native', true);
HotelTV.devinfo = await JSON.parse(sessionStorage.getItem("devinfo"));
HotelTV.svrinfo = await JSON.parse(sessionStorage.getItem("svrinfo"));
@@ -645,9 +657,12 @@ HotelTV.LoadWelCome = async function() {
}
}
HotelTV.UnloadWelCome = async function() {
HotelTV.UnloadWelCome = async function(_skip_ui_close=false, _main_load_delay=1000) {
sessionStorage.setItem("state", JSON.stringify(HotelTV.state));
if ( _skip_ui_close==false ){
HotelTV.ui_welcome.Close();
}
//MQTT Disconnect
if( HotelTV.services.client ){
@@ -655,9 +670,10 @@ HotelTV.UnloadWelCome = async function() {
}
if (HotelTV.state['registration'].license == 'hotel-full') {
setTimeout(function() {
const __ifxn_replace_page = function() {
window.location.replace('./app_hoteltv_full.html');
}, 1000);
}
setTimeout(__ifxn_replace_page, _main_load_delay);
}
}

View File

@@ -2020,6 +2020,10 @@ HotelTV.ui_appfull = (function() {
_elAmCtgyBg.append(_elDiv_Ctgy);
}
// popup:amenity 프레임 활성화
if ( _elAmPupRoot.css('display') == "none") {
_elAmPupRoot.show();
}
_elAmCtgyBg.owlCarousel({
center: true,
@@ -3559,6 +3563,10 @@ HotelTV.ui_appfull = (function() {
_elRsCtgyBg.append(_elDiv_Ctgy);
}
// popup:roomservice 프레임 활성화
if ( _elRsPupRoot.css('display') == "none") {
_elRsPupRoot.show();
}
_elRsCtgyBg.owlCarousel({
center: true,
@@ -6234,8 +6242,10 @@ HotelTV.ui_appfull = (function() {
$('.widjet .top .message').hide();
}
if ( $('div#lst_mypagebg').find('div #mp_message_title').length>0 ){
$('div#lst_mypagebg div #mp_message_title').text(_guest.name + _trTbl.ui.mypage.message.title.title[_state.lang].replace("_XX", _msgCnt.toString()));
}
}
/**
* HotelTV UI Wrapper Function::> Build Main Menu::> Flight
@@ -7258,7 +7268,8 @@ HotelTV.ui_appfull = (function() {
$('.error #countdown #message').text(`System will be shutdown in ${_tmval} second...`);
},
"cb_eoe": function() {
setTimeout(HotelTV.hcap.PwrOff, 500);
//setTimeout(HotelTV.hcap.PwrOff, 500);
setTimeout(HotelTV.hcap.Reboot, 500);
HotelTV.api.ReportEvent([{'power': false, 'location':null}])
}
});

View File

@@ -525,7 +525,8 @@ HotelTV.ui_welcome = (function() {
$('.error #countdown #message').text(`System will be shutdown in ${_tmval} second...`);
},
"cb_eoe": function() {
setTimeout(HotelTV.hcap.PwrOff, 500);
//setTimeout(HotelTV.hcap.PwrOff, 500);
setTimeout(HotelTV.hcap.Reboot, 500);
HotelTV.api.ReportEvent([{'power': false, 'location':null}])
}
});

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

View File

@@ -438,6 +438,7 @@
left: 0px;
width: 100%;
height: 100%;
display: none;
}
.popup .amenity div .item {
@@ -1591,6 +1592,7 @@
left: 0px;
width: 100%;
height: 100%;
display: none;
}
.popup .roomservice div .item {