From b586d247109d5bdb410c473ab161aff005e1bd70 Mon Sep 17 00:00:00 2001
From: lss <lsc@hdlchina.com.cn>
Date: 星期一, 13 六月 2022 19:37:31 +0800
Subject: [PATCH] 1

---
 HDL_ON/UI/UI2/4-PersonalCenter/Visitor/VisitorQRCodePage.cs |   36 ++++++++++++++++++++++++++++++------
 1 files changed, 30 insertions(+), 6 deletions(-)

diff --git a/HDL_ON/UI/UI2/4-PersonalCenter/Visitor/VisitorQRCodePage.cs b/HDL_ON/UI/UI2/4-PersonalCenter/Visitor/VisitorQRCodePage.cs
index 97bc8c8..a17f6c3 100644
--- a/HDL_ON/UI/UI2/4-PersonalCenter/Visitor/VisitorQRCodePage.cs
+++ b/HDL_ON/UI/UI2/4-PersonalCenter/Visitor/VisitorQRCodePage.cs
@@ -1,10 +1,10 @@
 锘縰sing System;
 using HDL_ON.UI.CSS;
 using Shared;
-using Com.Hdl.Hdllinphonesdk.Dialog;
 using HDL_ON.DAL.Server;
 using System.Collections.Generic;
 using Com.Hdl.Hdllinphonesdk.Utils;
+using Com.Hdl.Hdllinphonesdk.Dialog;
 
 namespace HDL_ON.UI.UI2.PersonalCenter.Visitor
 {
@@ -27,6 +27,9 @@
             bodyView = this;
         }
 
+
+
+
         public VisitorQRCodePage(VisitorTempPassword pwd)
         {
             bodyView = this;
@@ -42,7 +45,10 @@
 
                 Action click = () =>
                 {
-                    VisitorHistoryPage page = new VisitorHistoryPage();
+                    Action action = () => {
+                        LoadPage();
+                    };
+                    VisitorHistoryPage page = new VisitorHistoryPage(action);
                     MainPage.BasePageView.AddChidren(page);
                     page.LoadPage();
                     MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1;
@@ -389,13 +395,31 @@
             };
             visitorVoucherBtn.MouseUpEventHandler += (sender, e) =>
             {
-                if (phoneNumberEditText.Text.Trim() == "" || pwdEditText.Text.Trim() == ""
-                || startTimeText.Text.Trim() == "" || endTimeText.Text.Trim() == "")
+                if (startTimeText.Text.Trim() == "")
                 {
+                    var tip_dialog = new Tip()
+                    {
+                        Text = Language.StringByID(StringId.VisitorStartTime),
+                        CloseTime = 2,
+                        Direction = AMPopTipDirection.None
+                    };
+                    tip_dialog.Show(MainPage.BaseView);
                     return;
                 }
 
-                if (phoneNumberEditText.Text.Trim().Length != 11)
+                if (endTimeText.Text.Trim() == "")
+                {
+                    var tip_dialog = new Tip()
+                    {
+                        Text = Language.StringByID(StringId.VisitorEndTime),
+                        CloseTime = 2,
+                        Direction = AMPopTipDirection.None
+                    };
+                    tip_dialog.Show(MainPage.BaseView);
+                    return;
+                }
+
+                if (phoneNumberEditText.Text.Trim() == "" || phoneNumberEditText.Text.Trim().Length != 11)
                 {
                     var tip_dialog = new Tip()
                     {
@@ -408,7 +432,7 @@
                     return;
                 }
 
-                if (pwdEditText.Text.Trim().Length != 6)
+                if (pwdEditText.Text.Trim() == "" || pwdEditText.Text.Trim().Length != 6)
                 {
                     var tip_dialog = new Tip()
                     {

--
Gitblit v1.8.0