MYS: add disabled buttons & show name for pro mystery, WIP staging e-receipt

This commit is contained in:
Pakin 2025-06-13 10:47:30 +07:00
parent ccbd8f8071
commit cfb19451ad
27 changed files with 2051 additions and 1238 deletions

View file

@ -0,0 +1,135 @@
<Popup>
<Cache> "Enable" </Cache>
<Width> 1080 </Width>
<Height> 1920 </Height>
<Background> "0xeae6e1" </Background>
<Volume> SoundVolume </Volume>
;<Refresh> "Partial" </Refresh>
<EventOpen>
SAVELOG "Prompt E-Receipt v1"
; init-default
Var Seeker.e_receipt = "false"
Var Timeout = 0
Var ShowCaution = "Invisible"
; check-case-pay-with-code
DEBUGVAR Seeker.CodeChannel
If Seeker.CodeChannel = 1 Then
DEBUGVAR "Pay with code, nah-ah no e receipt"
Open "ROOT/taobin_project/xml/page_lid_straw.xml"
EndIf
Var EReceiptImgDir = CountryRootPath + "/image/page_e_receipt/"
; prompt-Popup
Var PromptImg = EReceiptImgDir + "img_popup_eReceiptPrompt.png"
Var PromptImgIfYes = EReceiptImgDir + "img_popup_eReceiptPrompt_yes.png"
Var bn_yes = EReceiptImgDir + "bn_yes.png"
Var bn_no = EReceiptImgDir + "bn_no.png"
Var bp_yes = EReceiptImgDir + "bp_yes.png"
Var bp_no = EReceiptImgDir + "bp_no.png"
DEBUGVAR EReceiptImgDir
DEBUGVAR PromptImg
DEBUGVAR bn_yes
DEBUGVAR bn_no
DEBUGVAR bp_yes
DEBUGVAR bp_no
</EventOpen>
<Timeout> 1000 </Timeout>
<EventTimeout>
Var Timeout = Timeout + 1
; auto-no
If Timeout > 15 Then
If TestReceiptPage = 1 Then
Var TestReceiptPage = 0
Open "ROOT/taobin_project/xml/page_board.xml"
Else
Open "ROOT/taobin_project/xml/page_lid_straw.xml"
EndIf
EndIf
Refresh
TimerReset
</EventTimeout>
; dim-bg
<Image>
<X> 0 </X>
<Y> 380 </Y>
<Filename> "ROOT/taobin_project/image/collectiing/alpha.png" </Filename>
</Image>
; prompt-Popup
<Image>
<X> 178 </X>
<Y> 665 </Y>
<Filename> PromptImg </Filename>
</Image>
<Button>
<X> 288 </X>
<Y> 971 </Y>
<Filename> bn_yes </Filename>
<FilenamePress> bp_yes </FilenamePress>
<Sound> "ROOT/sounds/codebuttom.wav" </Sound>
<Volume> SoundVolume </Volume>
<EventClick>
Var Seeker.e_receipt = "true"
; Open "ROOT/taobin_project/xml/page_lid_straw.xml"
Var SelectMenuBetweenBrewEnable1Blink = "Invisible"
Var SelectMenuBetweenBrewEnable1 = "Invisible"
Var ShowCaution = "Enable"
Var Timeout = 10
</EventClick>
</Button>
<Button>
<X> 288 </X>
<Y> 1171 </Y>
<Filename> bn_no </Filename>
<FilenamePress> bp_no </FilenamePress>
<Sound> "ROOT/sounds/codebuttom.wav" </Sound>
<Volume> SoundVolume </Volume>
<EventClick>
Var Seeker.e_receipt = "false"
Open "ROOT/taobin_project/xml/page_lid_straw.xml"
</EventClick>
</Button>
<Image>
<X> 178 </X>
<Y> 665 </Y>
<State> ShowCaution </State>
<Filename> PromptImgIfYes </Filename>
</Image>
</Popup>

View file

@ -0,0 +1,138 @@
<Popup>
<Width> 1080 </Width>
<Height> 1920 </Height>
<Background> BackgroundColor </Background>
<Volume> SoundVolume </Volume>
<EventOpen>
Var Timeout = 0
Var service = "eInvoice.mys"
If Seeker.VendingTSID = "" Then
DEBUGVAR Seeker.VendingTSID
DEBUGVAR VendingTSID
If VendingTSID = "" Then
Else
Var Seeker.VendingTSID = VendingTSID
EndIf
EndIf
DEBUGVAR Seeker.VendingTSID
DEBUGVAR Seeker.PriceDrinkTmpShow
DEBUGVAR Seeker.showname
DEBUGVAR Seeker.PictureDrink
Var EReceiptImgDir = CountryRootPath + "/image/page_e_receipt/"
Var EReceiptQRDialog = EReceiptImgDir + "img_popup_eReceiptPrompt_result.png"
TRY "ROOT/taobin_project/inter/mys/xml/process/e_receipt.ev"
</EventOpen>
<Timeout> 1000 </Timeout>
<EventTimeout>
Var Timeout = Timeout + 1
If Timeout > 10 Then
Open "ROOT/taobin_project/xml/page_drinkok.xml"
EndIf
Refresh
TimerReset
</EventTimeout>
; dim-bg
<Image>
<X> 0 </X>
<Y> 380 </Y>
<Filename> "ROOT/taobin_project/image/collectiing/alpha.png" </Filename>
</Image>
; show-qr-Popup
<Image>
<X> 178 </X>
<Y> 665 </Y>
<Filename> EReceiptQRDialog </Filename>
</Image>
; need-change-position
<QRCode>
<X> 415 </X>
<Y> 875 </Y>
<Width> 250 </Width>
<Height> 250 </Height>
<State> "Enable" </State>
<Service> service </Service>
</QRCode>
; menu-name
<Image>
<X> 175 </X>
<Y> 1100 </Y>
<Height> 300 </Height>
<Width> 320 </Width>
<Filename> Seeker.PictureDrink </Filename>
</Image>
<Text>
<X> 300 </X>
<Y> 1200 </Y>
<Width> 1080 </Width>
<Align> Center </Align>
<Font> KanitLightTTF </Font>
<Size> 48 </Size>
<Color> HeadlineColor </Color>
<Value>
eval(
STRCONTAIN "size" Seeker.showname SizeFromSheet
If SizeFromSheet = "true" Then
SPLIT Seeker.showname "###" 1 PureName
Var return = PureName
Else
Var return = Seeker.showname
EndIf
)
</Value>
</Text>
; show-price
<Text>
<X> 450 </X>
<Y> 1300 </Y>
<Font> KanitTTF </Font>
<Size> 48 </Size>
<Width> 1080 </Width>
<Color> HeadlineColor </Color>
<Value> Seeker.PriceDrinkTmpShow </Value>
</Text>
</Popup>