|
|
@@ -44,7 +44,7 @@ namespace HKCardOUT.ViewModels |
|
|
|
{ |
|
|
|
Result = new ObservableCollection<SaleLog>(this.Container.Get<HKCore>().PullDaySaleLog()); |
|
|
|
Thread.Sleep(500); |
|
|
|
}, "消费记录查询",false); |
|
|
|
}, "消费记录查询", false); |
|
|
|
//广告初始化 |
|
|
|
var Init = DataBus.StoreInfo?.Devices.Join(DataBus.StoreInfo?.Stalls, t => t.GateId, x => x.Id, (t, x) => new AdDTO |
|
|
|
{ |
|
|
@@ -126,7 +126,7 @@ namespace HKCardOUT.ViewModels |
|
|
|
return; |
|
|
|
else |
|
|
|
{ |
|
|
|
var res = UHF_RS485_Helper.GetInstance().ReadCard(item.Address.AsInt()).Result; |
|
|
|
var res = UHF_RS485_Helper.GetInstance().ReadCard(item.Address.AsInt()).Result; |
|
|
|
if (res != null) |
|
|
|
{ |
|
|
|
if (!res.ResData.IsMatch(new Regex("0{20}"))) |
|
|
@@ -139,29 +139,41 @@ namespace HKCardOUT.ViewModels |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
private void AdOpen() |
|
|
|
private void AdOpen() |
|
|
|
{ |
|
|
|
var SC = System.Windows.Forms.Screen.AllScreens.Count(); |
|
|
|
Rectangle[] rectangle = new Rectangle[SC]; |
|
|
|
List<Window> wins = new List<Window>(); |
|
|
|
|
|
|
|
for (int i = 0; i < Ad.Count; i++) |
|
|
|
{ |
|
|
|
wins.Add(new Views.AdWindow(Ad[i].Ad)); |
|
|
|
} |
|
|
|
|
|
|
|
for (int i = 0; i < wins.Count; i++) |
|
|
|
{ |
|
|
|
rectangle[i] = System.Windows.Forms.Screen.AllScreens[i].WorkingArea; |
|
|
|
wins[i].Height = rectangle[i].Height; |
|
|
|
wins[i].Width = rectangle[i].Width; |
|
|
|
wins[i].Top = rectangle[i].Top; |
|
|
|
wins[i].Left = rectangle[i].Left; |
|
|
|
wins[i].Show(); |
|
|
|
//wins[i].Owner = this.Main; |
|
|
|
} |
|
|
|
wins[0].Owner = this.Main; |
|
|
|
wins[1].Owner = this.Main; |
|
|
|
var win = new Views.AdWindow(Ad[0].Ad); |
|
|
|
var rectangles = System.Windows.Forms.Screen.AllScreens[0].WorkingArea; |
|
|
|
win.Height = rectangles.Height; |
|
|
|
win.Width = rectangles.Width; |
|
|
|
win.Top = 0; |
|
|
|
win.Left = rectangles.Left; |
|
|
|
win.Owner = this.Main; |
|
|
|
win.Show(); |
|
|
|
|
|
|
|
|
|
|
|
var win1 = new Views.AdWindow(Ad[1].Ad); |
|
|
|
var rectangless = System.Windows.Forms.Screen.AllScreens[1].WorkingArea; |
|
|
|
win1.Height = rectangless.Height; |
|
|
|
win1.Width = rectangless.Width; |
|
|
|
win1.Top = 0; |
|
|
|
win1.Left = rectangless.Left; |
|
|
|
win1.Owner = this.Main; |
|
|
|
win1.Show(); |
|
|
|
|
|
|
|
//for (int i = 0; i < Ad.Count; i++) |
|
|
|
//{ |
|
|
|
// var win = new Views.AdWindow(Ad[i].Ad); |
|
|
|
// var rectangles = System.Windows.Forms.Screen.AllScreens[i].WorkingArea; |
|
|
|
// win.Height = rectangles.Height; |
|
|
|
// win.Width = rectangles.Width; |
|
|
|
// win.Top = rectangles.Top; |
|
|
|
// win.Left = rectangles.Left; |
|
|
|
// win.Show(); |
|
|
|
// win.Owner = this.Main; |
|
|
|
//} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|