Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in
Toggle navigation
政
政企识别终端
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
终端组
政企识别终端
Commits
3a63a7b5
Commit
3a63a7b5
authored
Dec 04, 2020
by
姜春辉
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加北洋通道无卡离开/进入提示
parent
a1d7a62d
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
89 additions
and
47 deletions
+89
-47
CardHandler.cs
...ification.Enterprise.Logic/CallbackHandler/CardHandler.cs
+14
-0
App.config
src/GS.Terminal.Identification.EnterpriseHost/App.config
+1
-1
MainPageViewModel.cs
src/IdentificationViewModels/MainPage/MainPageViewModel.cs
+23
-1
MainPage.xaml
src/IdentificationViews/MainPage.xaml
+51
-45
No files found.
src/GS.Terminal.Identification.Enterprise.Logic/CallbackHandler/CardHandler.cs
View file @
3a63a7b5
...
@@ -55,6 +55,20 @@ namespace GS.Terminal.Identification.Enterprise.Logic
...
@@ -55,6 +55,20 @@ namespace GS.Terminal.Identification.Enterprise.Logic
#endif
#endif
if
(
string
.
IsNullOrEmpty
(
cardNum
))
return
;
if
(
string
.
IsNullOrEmpty
(
cardNum
))
return
;
//通道机 无卡闯入 0000000000000000
if
(
cardNum
==
"0000000000000000"
)
{
ViewModel
.
ShowError
=
true
;
ViewModel
.
ErrorText
=
$"无卡
{(
cardMsg
.
OperaDeviceData
.
Tag
==
"I"
?
"进入"
:
"离开"
)}
"
;
return
;
}
else
{
ViewModel
.
ShowError
=
false
;
ViewModel
.
ErrorText
=
""
;
}
try
try
{
{
ViewModel
.
IsStandby
=
false
;
ViewModel
.
IsStandby
=
false
;
...
...
src/GS.Terminal.Identification.EnterpriseHost/App.config
View file @
3a63a7b5
...
@@ -8,7 +8,7 @@
...
@@ -8,7 +8,7 @@
<
add
key
=
"UpdateUrl"
value
=
"http://192.168.1.210/Soft/update"
/>
<
add
key
=
"UpdateUrl"
value
=
"http://192.168.1.210/Soft/update"
/>
<
add
key
=
"ServerIP"
value
=
"192.168.1.210"
/>
<
add
key
=
"ServerIP"
value
=
"192.168.1.210"
/>
<
add
key
=
"tCode"
value
=
"D1"
/>
<
add
key
=
"tCode"
value
=
"D1"
/>
<
add
key
=
"WebPath"
value
=
"http://192.168.1.
210
/"
/>
<
add
key
=
"WebPath"
value
=
"http://192.168.1.
150:666
/"
/>
<
add
key
=
"ClientSettingsProvider.ServiceUri"
value
=
""
/>
<
add
key
=
"ClientSettingsProvider.ServiceUri"
value
=
""
/>
</
appSettings
>
</
appSettings
>
<
system
.
web
>
<
system
.
web
>
...
...
src/IdentificationViewModels/MainPage/MainPageViewModel.cs
View file @
3a63a7b5
...
@@ -19,6 +19,8 @@ namespace IdentificationViewModels
...
@@ -19,6 +19,8 @@ namespace IdentificationViewModels
{
{
ActiveHuman
=
new
Human
{
IsCard
=
false
,
IsVisitor
=
false
};
ActiveHuman
=
new
Human
{
IsCard
=
false
,
IsVisitor
=
false
};
IsStandby
=
true
;
IsStandby
=
true
;
ShowError
=
false
;
ErrorText
=
""
;
}
}
#
endregion
#
endregion
...
@@ -29,6 +31,9 @@ namespace IdentificationViewModels
...
@@ -29,6 +31,9 @@ namespace IdentificationViewModels
private
string
_Footer
;
private
string
_Footer
;
private
int
_AutoResetTime
;
private
int
_AutoResetTime
;
private
bool
_IsStandby
=
true
;
private
bool
_IsStandby
=
true
;
private
string
_VersionString
=
"-"
;
private
bool
_ShowError
;
private
string
_ErrorText
;
#
endregion
#
endregion
#
region
属性
#
region
属性
...
@@ -96,7 +101,7 @@ namespace IdentificationViewModels
...
@@ -96,7 +101,7 @@ namespace IdentificationViewModels
set
{
_tCode
=
value
;
RaisePropertyChanged
(
"tCode"
);
}
set
{
_tCode
=
value
;
RaisePropertyChanged
(
"tCode"
);
}
}
}
private
string
_VersionString
=
"-"
;
public
string
VersionString
public
string
VersionString
{
{
...
@@ -104,6 +109,23 @@ namespace IdentificationViewModels
...
@@ -104,6 +109,23 @@ namespace IdentificationViewModels
set
{
_VersionString
=
value
;
RaisePropertyChanged
(
"VersionString"
);
}
set
{
_VersionString
=
value
;
RaisePropertyChanged
(
"VersionString"
);
}
}
}
public
bool
ShowError
{
get
{
return
_ShowError
;
}
set
{
_ShowError
=
value
;
RaisePropertyChanged
(
"ShowError"
);
}
}
public
string
ErrorText
{
get
{
return
_ErrorText
;
}
set
{
_ErrorText
=
value
;
RaisePropertyChanged
(
"ErrorText"
);
}
}
#
endregion
#
endregion
}
}
...
...
src/IdentificationViews/MainPage.xaml
View file @
3a63a7b5
...
@@ -64,54 +64,60 @@
...
@@ -64,54 +64,60 @@
</Image.RenderTransform>
</Image.RenderTransform>
</Image>
</Image>
<!--当前信息 - 员工-->
<!--当前信息 - 员工-->
<Border Visibility="{Binding ActiveHuman.IsVisitor, Converter={StaticResource ReverseBooleanToVisibilityConverter}}" d:IsHidden="False" Grid.Row="1" Width="881" Margin="84,0,84,31" CornerRadius="25" BorderThickness="0" Background="#4Cffffff">
<Border Visibility="{Binding ActiveHuman.IsVisitor, Converter={StaticResource ReverseBooleanToVisibilityConverter}}" d:IsHidden="False" Grid.Row="1" Width="881" Margin="84,0,84,31" CornerRadius="25" BorderThickness="0" Background="#4Cffffff">
<Grid>
<Grid>
<Grid.ColumnDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition/>
<ColumnDefinition/>
<ColumnDefinition Width="510"/>
<ColumnDefinition Width="510"/>
</Grid.ColumnDefinitions>
</Grid.ColumnDefinitions>
<wpf:HttpImage Stretch="Fill" Grid.Column="0" Url="{Binding ActiveHuman.HumanPhoto}" DefaultImage="/IdentificationViews;component/Images/standby.png" Height="257" Width="181"/>
<wpf:HttpImage Stretch="Fill" Grid.Column="0" Url="{Binding ActiveHuman.HumanPhoto}" DefaultImage="/IdentificationViews;component/Images/standby.png" Height="257" Width="181"/>
<StackPanel Orientation="Vertical" Grid.Column="1">
<StackPanel Orientation="Vertical" Grid.Column="1">
<StackPanel Orientation="Horizontal" Margin="0,64,0,0">
<StackPanel Orientation="Horizontal" Margin="0,64,0,0">
<TextBlock Text="部门:" FontSize="36"/>
<TextBlock Text="部门:" FontSize="36"/>
<TextBlock Text="{Binding ActiveHuman.Depart}" FontSize="36" Margin="40,0,0,0"/>
<TextBlock Text="{Binding ActiveHuman.Depart}" FontSize="36" Margin="40,0,0,0"/>
</StackPanel>
<StackPanel Orientation="Horizontal" Margin="0,30,0,0">
<TextBlock Text="姓名:" FontSize="36"/>
<TextBlock Text="{Binding ActiveHuman.Name}" FontSize="36" Margin="40,0,0,0"/>
</StackPanel>
<StackPanel Orientation="Horizontal" Margin="0,30,0,0">
<TextBlock Text="时间:" FontSize="36" />
<TextBlock Text="{Binding ActiveHuman.Time}" FontSize="36" Margin="40,0,0,0"/>
</StackPanel>
</StackPanel>
</StackPanel>
</Grid>
<StackPanel Orientation="Horizontal" Margin="0,30,0,0">
</Border>
<TextBlock Text="姓名:" FontSize="36"/>
<!--当前信息 - 访客-->
<TextBlock Text="{Binding ActiveHuman.Name}" FontSize="36" Margin="40,0,0,0"/>
<Border Visibility="{Binding ActiveHuman.IsVisitor, Converter={StaticResource BooleanToVisibilityConverter}}" d:IsHidden="True" Grid.Row="1" Width="881" Margin="84,0,84,31" CornerRadius="25" BorderThickness="2" Background="#aa1e96c5" BorderBrush="#4Cffffff">
</StackPanel>
<Grid>
<StackPanel Orientation="Horizontal" Margin="0,30,0,0">
<Grid.ColumnDefinitions>
<TextBlock Text="时间:" FontSize="36" />
<ColumnDefinition/>
<TextBlock Text="{Binding ActiveHuman.Time}" FontSize="36" Margin="40,0,0,0"/>
<ColumnDefinition Width="510"/>
</StackPanel>
</Grid.ColumnDefinitions>
</StackPanel>
<wpf:HttpImage Stretch="Fill" Grid.Column="0" Url="{Binding ActiveHuman.HumanPhoto}" DefaultImage="/IdentificationViews;component/Images/standby.png" Height="257" Width="181"/>
</Grid>
</Border>
<!--当前信息 - 访客-->
<Border Visibility="{Binding ActiveHuman.IsVisitor, Converter={StaticResource BooleanToVisibilityConverter}}" d:IsHidden="True" Grid.Row="1" Width="881" Margin="84,0,84,31" CornerRadius="25" BorderThickness="2" Background="#aa1e96c5" BorderBrush="#4Cffffff">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition/>
<ColumnDefinition Width="510"/>
</Grid.ColumnDefinitions>
<wpf:HttpImage Stretch="Fill" Grid.Column="0" Url="{Binding ActiveHuman.HumanPhoto}" DefaultImage="/IdentificationViews;component/Images/standby.png" Height="257" Width="181"/>
<StackPanel Orientation="Vertical" Grid.Column="1">
<StackPanel Orientation="Vertical" Grid.Column="1">
<StackPanel Orientation="Horizontal" Margin="0,64,0,0">
<StackPanel Orientation="Horizontal" Margin="0,64,0,0">
<TextBlock Text="被访部门:" FontSize="36"/>
<TextBlock Text="被访部门:" FontSize="36"/>
<TextBlock Text="{Binding ActiveHuman.Depart}" FontSize="36" Margin="40,0,0,0"/>
<TextBlock Text="{Binding ActiveHuman.Depart}" FontSize="36" Margin="40,0,0,0"/>
</StackPanel>
</StackPanel>
<StackPanel Orientation="Horizontal" Margin="0,30,0,0">
<StackPanel Orientation="Horizontal" Margin="0,30,0,0">
<TextBlock Text="访客姓名:" FontSize="36"/>
<TextBlock Text="访客姓名:" FontSize="36"/>
<TextBlock Text="{Binding ActiveHuman.Name}" FontSize="36" Margin="40,0,0,0"/>
<TextBlock Text="{Binding ActiveHuman.Name}" FontSize="36" Margin="40,0,0,0"/>
</StackPanel>
</StackPanel>
<StackPanel Orientation="Horizontal" Margin="0,30,0,0">
<StackPanel Orientation="Horizontal" Margin="0,30,0,0">
<TextBlock Text="访问时间:" FontSize="36" />
<TextBlock Text="访问时间:" FontSize="36" />
<TextBlock Text="{Binding ActiveHuman.Time}" FontSize="36" Margin="40,0,0,0"/>
<TextBlock Text="{Binding ActiveHuman.Time}" FontSize="36" Margin="40,0,0,0"/>
</StackPanel>
</StackPanel>
</StackPanel>
</Grid>
</StackPanel>
</Border>
</Grid>
</Border>
<Border Visibility="{Binding ShowError, Converter={StaticResource BooleanToVisibilityConverter}}"
Grid.Row="1" Width="881" Margin="84,0,84,31"
CornerRadius="25" BorderThickness="2"
Background="#FF0000" BorderBrush="#4Cffffff">
<TextBlock Text="{Binding ErrorText}" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="64" Foreground="white"/>
</Border>
</Grid>
</Grid>
</Border>
</Border>
<!--Main 下-->
<!--Main 下-->
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment