MYS: add support for cold menu slots (change to paper cup -22-), SGP: move cashless reset & add delay to cashless cancel btn & WIP full screen video

This commit is contained in:
Pakin 2025-03-20 10:59:15 +07:00
parent b141606ecf
commit ddcb4273c5
26 changed files with 10029 additions and 6780 deletions

View file

@ -0,0 +1,238 @@
<Popup>
<Cache> "Enable" </Cache>
<Width> 1080 </Width>
<Height> 1920 </Height>
;<Background> "0xeae6e1" </Background>
;<Volume> SoundVolume </Volume>
<EventOpen>
</EventOpen>
;include="ROOT/taobin_project/inc/video_page_board.inc"
; button-click
<Button>
<X> 212 </X>
<Y> 1481 </Y>
<State> ShowButtonClick_WTC </State>
;<Color> "0x00BDFF" </Color>
<Filename> img_rest_main_page </Filename>
<FilenamePress> img_press_main_page </FilenamePress>
;<Sound> "/mnt/sdcard/coffeevending/wav/click.wav" </Sound>
<Volume> SoundVolume </Volume>
<EventClick>
SAVELOG "click ShowButtonClick WTC"
TRY "ROOT/taobin_project/inter/whatthecup/common/xml/feature.page_board_fullscreen/show_button_click_script.ev"
</EventClick>
<Button>
<X> 2 </X>
<Y> 609 </Y>
<State> ShowButtonClickFull_WTC </State>
;<Color> "0x00BDFF" </Color>
<Width> 1070 </Width>
<Height> 1310 </Height>
<Sound> "/mnt/sdcard/coffeevending/wav/click.wav" </Sound>
<Volume> SoundVolume </Volume>
<EventClick>
SAVELOG "click ShowButtonClickFull WTC"
TRY "ROOT/taobin_project/inter/whatthecup/common/xml/feature.page_board_fullscreen/show_button_click_script.ev"
</EventClick>
</Button>
; button-click-full
<Button>
<X> btnRemoveCupX </X>
<Y> btnRemoveCupY </Y>
<State> buttonRemoveCup </State>
;<Color> "0x00BDFF" </Color>
<Interval> 500 </Interval>
<Filename> bnRemoveCup </Filename>
<Filename> bpRemoveCup </Filename>
<EventClick>
Machine RemoveCup
Machine DoorLidOpen
Var CheckCupStateDoorCupClose = "reset"
Var buttonRemoveCup = "Invisible"
</EventClick>
</Button>
<Button>
<X> 0 </X>
<Y> 1870 </Y>
<State> ShowNetworkProblem </State>
<Color> "0xFF0000" </Color>
<Width> 1080 </Width>
<Height> 60 </Height>
<EventClick>
If IgnoreNetCore = "true" Then
Var NextPage = "-"
OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_advert.xml"
OpenInst 2 "/mnt/sdcard/coffeevending/taobin_project/xml/page_catalog.lxml"
TopView "show"
OpenInst 0 "/mnt/sdcard/coffeevending/taobin_project/xml/page_main_blank.xml"
EndIf
</EventClick>
</Button>
<Button>
<X> 0 </X>
<Y> 608 </Y>
<State> "Enable" </State>
<Width> 120 </Width>
<Height> 120 </Height>
<EventClick>
Var NextPage = "ROOT/taobin_project/xml/page_back_to_main.xml"
OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_advert2.xml"
If DoorCupPosition = "bottom" Then
If CupOnArm = "true" Then
Else
__CMD "CLI" "arm_id=3,arm_position=posi_espresso_ii" "-" "-"
EndIf
EndIf
Var OpenFromPageBoard = 1
If InternationalEnable = 1 Then
If CountryName = "Thailand" Then
SAVELOG " Thailand Thailand Thailand Thailand Pooon Pooon Pooon Pooon Pooon"
TRY "/mnt/sdcard/coffeevending/taobin_project/inter/tha/xml/event/script_common_for_open_promotion_xml.ev"
Else ; show language icon
OpenInst 3 "ROOT/taobin_project/xml/topview2.xml"
RootLayoutVisible 3 "show"
Var OpenFileXML = CountryRootPath + "xml/event/script_common_for_open_promotion_xml.ev"
TRY OpenFileXML
EndIf
Else
If CocktailShow = "true" Then
OpenInst 2 "/mnt/sdcard/coffeevending/taobin_project/xml/page_catalog_cocktail.xml"
Else
TRY "/mnt/sdcard/coffeevending/taobin_project/xml/event/script_common_for_open_promotion_xml.ev"
EndIf
EndIf
Machine DoorClose
TopView "show"
OpenInst 0 "/mnt/sdcard/coffeevending/taobin_project/xml/page_main_blank.xml"
</EventClick>
</Button>
<Text>
<State> ShowNetworkProblem </State>
<X> 5 </X>
<Y> 1880 </Y>
<Size> 24 </Size>
<Align> Center </Align>
<Width> 1080 </Width>
<Font> RobotoRegular </Font>
<Color> 0xFFFFFF </Color>
<Value> ShowNetworkProblemText </Value>
</Text>
<Button>
<X> 0 </X>
<Y> 1870 </Y>
<State> eval(
If LangProcess = "LoadConfig" Then
Var return = "Enable"
Else
Var return = "Invisible"
EndIf
) </State>
<Color> "0xFFFF00" </Color>
<Width> 1080 </Width>
<Height> 60 </Height>
<EventClick>
</EventClick>
</Button>
<Text>
<State> eval(
If LangProcess = "LoadConfig" Then
Var return = "Enable"
Else
Var return = "Invisible"
EndIf
) </State>
<X> 5 </X>
<Y> 1880 </Y>
<Size> 24 </Size>
<Align> Center </Align>
<Width> 1080 </Width>
<Font> RobotoRegular </Font>
<Color> 0x000000 </Color>
<Value> eval(
If LangProcess = "LoadConfig" Then
Var return = "Loading ..."
Else
Var return = ""
EndIf
) </Value>
</Text>
; add-vending-info-access-button
<Image>
<X> 670 </X>
<Y> 0 </Y>
<Width> 400 </Width>
<Height> 400 </Height>
<Sound> "/mnt/sdcard/coffeevending/wav/click.wav" </Sound>
<Volume> SoundVolume </Volume>
<EventClickLong>
OpenInst 0 "//mnt/sdcard/coffeevending/taobin_project/xml/vending_info.xml"
</EventClickLong>
<EventClick>
Var ClickCountMainTe = ClickCountMainTe + 1
DEBUGVAR ClickCountMainTe
If ClickCountMainTe = 2 Then
RootLayoutVisible 2 "hide"
OpenInst 0 "/mnt/sdcard/coffeevending/taobin_project/xml/vending_info.xml"
EndIf
;OpenInst 0 "//mnt/sdcard/coffeevending/taobin_project/xml/page_remove_cup.xml"
</EventClick>
</Image>
</Popup>

View file

@ -0,0 +1,29 @@
;OpenInst 1 "/mnt/sdcard/coffeevending/taobin_project/xml/page_advert.xml"
OpenInst 0 "/mnt/sdcard/coffeevending/taobin_project/xml/page_main_blank.xml"
If CocktailShow = "true" Then
OpenInst 2 "/mnt/sdcard/coffeevending/taobin_project/xml/page_catalog_cocktail.xml"
Else
If SpiralOnline = "true" Then
If InternationalEnable = 1 Then
If CountryName = "Thailand" Then
OpenInst 3 "ROOT/taobin_project/xml/topview2.xml"
Open "/mnt/sdcard/coffeevending/taobin_project/xml/page_catalog.lxml"
EndIf
Else
Open "/mnt/sdcard/coffeevending/taobin_project/xml/page_catalog_with_vending.xml"
EndIf
Else
If InternationalEnable = 1 Then
OpenInst 3 "ROOT/taobin_project/xml/topview2.xml"
OpenInst 2 "/mnt/sdcard/coffeevending/taobin_project/xml/page_catalog.lxml"
Else
OpenInst 2 "/mnt/sdcard/coffeevending/taobin_project/xml/page_catalog.xml"
EndIf
EndIf
EndIf
TopView "show"

View file

@ -24,8 +24,8 @@
Var PreScaleCanculate = 100
DEBUGVAR VendingCashless
CashlessReq FAIL ""
Var WaitForStableCashlessState = 3
Var WaitForStableCashlessState = 0
DEBUGVAR WaitForStableCashlessState
@ -480,6 +480,9 @@
Var CancelContinue = 0
Var QR_POPUP = "ROOT/taobin_project/inter/whatthecup/sgp/image/page_payment/img_tap_card_5_sec.png"
Var CountDownAllowCancel = 5
</EventOpen>
<EventActionOk>
@ -810,8 +813,6 @@
DEBUGVAR UserChoosePayment
DEBUGVAR VendingCashless
If WaitForStableCashlessState = 0 Then
If UserChoosePayment = "CreditCashless" Then
If VendingCashless = "READY" Then
Var QRCODE99 = ""
@ -843,14 +844,6 @@
Var UserChoosePayment = "CreditCashless"
EndIf
EndIf
Else
DEBUGVAR "Get EventCashless while not stable"
DEBUGVAR WaitForStableCashlessState
DEBUGVAR VendingCashless
EndIf
EndIf
@ -874,16 +867,12 @@
<EventTimeout>
DEBUGVAR VendingCashless
DEBUGVAR CountDownAllowCancel
If WaitForStableCashlessState > 0 Then
DEBUGVAR WaitForStableCashlessState
Var LOADING_STATE = "Enable"
Var WaitForStableCashlessState = WaitForStableCashlessState - 1
Else
Var LOADING_STATE = "Invisible"
If CountDownAllowCancel > 0 Then
Var CountDownAllowCancel = CountDownAllowCancel - 1
EndIf
If ReadyForBrew = "false" Then
SAVELOG "Back to main1"
DEBUGVAR UserChoosePayment
@ -1656,6 +1645,7 @@ If alphaState = "Invisible" Then
DEBUGVAR QR_POPUP
Refresh
Var alphaState = "Enable"
Var CountDownAllowCancel = 5
Coin CARD
EndIf
EndIf
@ -1851,12 +1841,7 @@ EndIf
<Filename> QR_POPUP </Filename>
</Image>
<Image>
<X> 0 </X>
<Y> 380 </Y>
<State> LOADING_STATE </State>
<Filename> "ROOT/taobin_project/inter/whatthecup/sgp/image/page_payment_en/page_payment/alpha.png" </Filename>
</Image>
<Image>
<X> 267 </X>
@ -1872,7 +1857,13 @@ EndIf
<Button>
<X> 438 </X>
<Y> 1345 </Y>
<State> alphaState </State>
<State> eval(
If CountDownAllowCancel > 0 Then
Var return = "Invisible"
Else
Var return = alphaState
EndIf
) </State>
<Filename> Var( DirImage + "/bn_cancel.png" )</Filename>
<FilenamePress> Var( DirImage + "/bp_cancel.png" )</FilenamePress>
<Sound> "/mnt/sdcard/coffeevending/wav/click.wav" </Sound>

View file

@ -343,7 +343,7 @@
Var SugarPressPicLv5 = "ROOT/taobin_project/inter/whatthecup/sgp/image/topping2_en/bp_sugarlevel_sg5.png"
Var SugarPressPicLv6 = "ROOT/taobin_project/inter/whatthecup/sgp/image/topping2_en/bp_sugarlevel_sg6.png"
CashlessReq FAIL ""
</EventOpen>
<Timeout> 1000 </Timeout>