呼叫相关功能
This commit is contained in:
commit
3d501babf9
3 files changed
+30
-6
No files matched your search
@@ -25,6 +25,7 @@ using System.Xml.Linq;
|
|||||||
using TouchSocket.Core;
|
using TouchSocket.Core;
|
||||||
using TouchSocket.Sockets;
|
using TouchSocket.Sockets;
|
||||||
using static SunlightCentralizedControlManagement_SCCM_.UserClass.SqliteHelper;
|
using static SunlightCentralizedControlManagement_SCCM_.UserClass.SqliteHelper;
|
||||||
|
using static SunlightCentralizedControlManagement_SCCM_.View.MachinesView;
|
||||||
using static System.Windows.Forms.AxHost;
|
using static System.Windows.Forms.AxHost;
|
||||||
using static System.Windows.Forms.VisualStyles.VisualStyleElement;
|
using static System.Windows.Forms.VisualStyles.VisualStyleElement;
|
||||||
using static System.Windows.Forms.VisualStyles.VisualStyleElement.TaskbarClock;
|
using static System.Windows.Forms.VisualStyles.VisualStyleElement.TaskbarClock;
|
||||||
@@ -168,11 +169,21 @@ namespace SunlightCentralizedControlManagement_SCCM_.UserClass
|
|||||||
}
|
}
|
||||||
catch (Exception ex) { LogGing.LogGingDATA("[ERR='" + ex + "']=Exception"); MainWindowViewModel.ERR_c++; }
|
catch (Exception ex) { LogGing.LogGingDATA("[ERR='" + ex + "']=Exception"); MainWindowViewModel.ERR_c++; }
|
||||||
}
|
}
|
||||||
|
else if (SYSAPI == "SC827")
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
DAT = DAT.Substring(DAT.IndexOf("]") + 1);
|
||||||
|
MainWindowViewModel.Dyelot_CALL = JsonConvert.DeserializeObject<DataTable>(DAT).Copy();//反序列化
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
catch (Exception ex) { LogGing.LogGingDATA("[ERR='" + ex + "']=Exception"); MainWindowViewModel.ERR_c++; }
|
||||||
|
}//呼叫领料单
|
||||||
else if (SYSAPI == "SC830")
|
else if (SYSAPI == "SC830")
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
|
||||||
DAT = DAT.Substring(DAT.IndexOf("]") + 1);
|
DAT = DAT.Substring(DAT.IndexOf("]") + 1);
|
||||||
Dictionary<string, object> _new = new Dictionary<string, object>();//缓存函数
|
Dictionary<string, object> _new = new Dictionary<string, object>();//缓存函数
|
||||||
_new = JsonConvert.DeserializeObject<Dictionary<string, object>>(DAT);//反序列化
|
_new = JsonConvert.DeserializeObject<Dictionary<string, object>>(DAT);//反序列化
|
||||||
|
|||||||
@@ -120,7 +120,7 @@
|
|||||||
<Grid.ColumnDefinitions>
|
<Grid.ColumnDefinitions>
|
||||||
<ColumnDefinition/>
|
<ColumnDefinition/>
|
||||||
<ColumnDefinition Width="5"/>
|
<ColumnDefinition Width="5"/>
|
||||||
<ColumnDefinition/>
|
<ColumnDefinition MinWidth="1200"/>
|
||||||
</Grid.ColumnDefinitions>
|
</Grid.ColumnDefinitions>
|
||||||
<DataGrid Grid.Column="2" x:Name="Gridstep" AlternationCount="2" SelectionChanged="Gridstep_SelectionChanged"
|
<DataGrid Grid.Column="2" x:Name="Gridstep" AlternationCount="2" SelectionChanged="Gridstep_SelectionChanged"
|
||||||
d:ItemsSource="{d:SampleData ItemCount=90}" AutoGenerateColumns="False" MinColumnWidth="30"
|
d:ItemsSource="{d:SampleData ItemCount=90}" AutoGenerateColumns="False" MinColumnWidth="30"
|
||||||
@@ -128,8 +128,7 @@
|
|||||||
HorizontalGridLinesBrush="#FFC9C9C9" VerticalGridLinesBrush="#FFC9C9C9" Background="White"
|
HorizontalGridLinesBrush="#FFC9C9C9" VerticalGridLinesBrush="#FFC9C9C9" Background="White"
|
||||||
GridLinesVisibility="All" ColumnHeaderHeight="40" HorizontalContentAlignment="Right" BorderBrush="{x:Null}"
|
GridLinesVisibility="All" ColumnHeaderHeight="40" HorizontalContentAlignment="Right" BorderBrush="{x:Null}"
|
||||||
CanUserReorderColumns="False" CanUserSortColumns="False" CanUserResizeRows="False" CanUserResizeColumns="False"
|
CanUserReorderColumns="False" CanUserSortColumns="False" CanUserResizeRows="False" CanUserResizeColumns="False"
|
||||||
CanUserDeleteRows="False" SelectionMode="Single" FontSize="15" Focusable="True" AllowDrop="False"
|
CanUserDeleteRows="False" SelectionMode="Single" FontSize="15" Focusable="True" CanUserAddRows="False">
|
||||||
HeadersVisibility ="Column" >
|
|
||||||
<DataGrid.RowStyle >
|
<DataGrid.RowStyle >
|
||||||
<Style TargetType="{x:Type DataGridRow}">
|
<Style TargetType="{x:Type DataGridRow}">
|
||||||
<Setter Property="IsHitTestVisible" Value="{Binding DataContext.IsInteractive,
|
<Setter Property="IsHitTestVisible" Value="{Binding DataContext.IsInteractive,
|
||||||
|
|||||||
@@ -73,6 +73,7 @@ namespace SunlightCentralizedControlManagement_SCCM_.ViewModel
|
|||||||
public static DataTable Machines = new DataTable(); //设备表缓存
|
public static DataTable Machines = new DataTable(); //设备表缓存
|
||||||
// public static DataRow MachinesROW;
|
// public static DataRow MachinesROW;
|
||||||
public static DataTable USER_data = new DataTable();
|
public static DataTable USER_data = new DataTable();
|
||||||
|
public static DataTable Dyelot_CALL = new DataTable();
|
||||||
public static UserControls.info[] inf = new UserControls.info[999]; //定义总览信息卡
|
public static UserControls.info[] inf = new UserControls.info[999]; //定义总览信息卡
|
||||||
public static int ERR_c = 0;//错误计数器
|
public static int ERR_c = 0;//错误计数器
|
||||||
public static bool[] USER_Capacity { set; get; } = new bool[99];
|
public static bool[] USER_Capacity { set; get; } = new bool[99];
|
||||||
@@ -318,7 +319,7 @@ namespace SunlightCentralizedControlManagement_SCCM_.ViewModel
|
|||||||
/**染机用户信息**/
|
/**染机用户信息**/
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
if (Selet_Machines(Machines, "UserInfoStart", "ID='" + i + "'").ToString() == "901")
|
if ((int)Selet_Machines(Machines, "UserInfoStart", "ID='" + i + "'") == 901)
|
||||||
{
|
{
|
||||||
MainWindow.InfData.Rows.Add(new object[] {
|
MainWindow.InfData.Rows.Add(new object[] {
|
||||||
Selet_Machines(Machines, "Name", "ID='" + i + "'"),
|
Selet_Machines(Machines, "Name", "ID='" + i + "'"),
|
||||||
@@ -333,9 +334,22 @@ namespace SunlightCentralizedControlManagement_SCCM_.ViewModel
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch (Exception) { }
|
catch (Exception) { }
|
||||||
|
try
|
||||||
|
{
|
||||||
|
if ((bool)Selet_Machines(Machines, "CALL", "ID='" + i + "'"))
|
||||||
|
{
|
||||||
|
stringQueue.Enqueue(new QueueString
|
||||||
|
{
|
||||||
|
ID = i,
|
||||||
|
DAT = "SC827" + Selet_Machines(Machines, "SYSKEY", "ID='" + i + "'")
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception) { }
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
void Tick_Event_60S()
|
void Tick_Event_60S()
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in new issue
Block a user