|
@@ -137,11 +137,6 @@ namespace SCADA_DAQ.Customer
|
|
|
// - TimeSpan.FromSeconds(DeviceStateCodeStopBetweenTime("亚威PBC折弯机", "维修时间")));
|
|
|
//var baiChaoTimeMaintenanceTable = Convert.ToString(DevicMainTableTime("百超折弯机") + TimeSpan.FromSeconds(DeviceTimeValue("百超折弯机", "维修时间"))
|
|
|
// - TimeSpan.FromSeconds(DeviceStateCodeStopBetweenTime("百超折弯机", "维修时间")));
|
|
|
- var firstYaWeiTimeMaintenanceTable = Convert.ToString(DevicMainTableTime("亚威一号折弯机") + TimeSpan.FromSeconds(DeviceTimeValue("1号YaWei折弯机", "维修时间")));
|
|
|
- var secondYaWeiTimeMaintenanceTable = Convert.ToString(DevicMainTableTime("亚威二号折弯机") + TimeSpan.FromSeconds(DeviceTimeValue("2号YaWei折弯机", "维修时间")));
|
|
|
- var thirdYaWeiTimeMaintenanceTable = Convert.ToString(DevicMainTableTime("亚威三号折弯机") + TimeSpan.FromSeconds(DeviceTimeValue("3号YaWei折弯机", "维修时间")));
|
|
|
- var pbcYaWweiTimeMaintenanceTable = Convert.ToString(DevicMainTableTime("亚威PBC折弯机") + TimeSpan.FromSeconds(DeviceTimeValue("亚威PBC折弯机", "维修时间")));
|
|
|
- var baiChaoTimeMaintenanceTable = Convert.ToString(DevicMainTableTime("百超折弯机") + TimeSpan.FromSeconds(DeviceTimeValue("百超折弯机", "维修时间")));
|
|
|
|
|
|
//double totalTimeOfDay = TimeSpan.Parse(DateTime.Now.ToString("HH:mm:ss")).TotalSeconds;
|
|
|
//var firstYaWeiStopTime = totalTimeOfDay - firstYaWeiRunTime - firstYaWeiMoldTime - DevicScheduleStop("1号YaWei折弯机")
|
|
@@ -155,6 +150,19 @@ namespace SCADA_DAQ.Customer
|
|
|
//var baiChaoStopTime = totalTimeOfDay - baiChaoRunTime - baiChaoMoldTime - DevicScheduleStop("百超折弯机")
|
|
|
// - DevicMainTableTime("百超折弯机").TotalSeconds - DeviceTimeValue("百超折弯机", "维修时间") + DeviceStateCodeStopBetweenTime("百超折弯机", "维修时间");//百超折弯机折弯机等待时间
|
|
|
|
|
|
+ var firstYaWeiTimeMaintenanceTableDouble = DevicMainTableTime("亚威一号折弯机").TotalSeconds + DeviceTimeValue("1号YaWei折弯机", "维修时间");
|
|
|
+ var secondYaWeiTimeMaintenanceTableDouble = DevicMainTableTime("亚威二号折弯机").TotalSeconds + DeviceTimeValue("2号YaWei折弯机", "维修时间");
|
|
|
+ var thirdYaWeiTimeMaintenanceTableDouble = DevicMainTableTime("亚威三号折弯机").TotalSeconds + DeviceTimeValue("3号YaWei折弯机", "维修时间");
|
|
|
+ var pbcYaWweiTimeMaintenanceTableDouble = DevicMainTableTime("亚威PBC折弯机").TotalSeconds + DeviceTimeValue("亚威PBC折弯机", "维修时间");
|
|
|
+ var baiChaoTimeMaintenanceTableDouble = DevicMainTableTime("百超折弯机").TotalSeconds + DeviceTimeValue("百超折弯机", "维修时间");
|
|
|
+
|
|
|
+ var firstYaWeiTimeMaintenanceTable = TimeSpan.FromSeconds(Math.Round(firstYaWeiTimeMaintenanceTableDouble)).ToString();
|
|
|
+ var secondYaWeiTimeMaintenanceTable = TimeSpan.FromSeconds(Math.Round(secondYaWeiTimeMaintenanceTableDouble)).ToString();
|
|
|
+ var thirdYaWeiTimeMaintenanceTable = TimeSpan.FromSeconds(Math.Round(thirdYaWeiTimeMaintenanceTableDouble)).ToString();
|
|
|
+ var pbcYaWweiTimeMaintenanceTable = TimeSpan.FromSeconds(Math.Round(pbcYaWweiTimeMaintenanceTableDouble)).ToString();
|
|
|
+ var baiChaoTimeMaintenanceTable = TimeSpan.FromSeconds(Math.Round(baiChaoTimeMaintenanceTableDouble)).ToString();
|
|
|
+
|
|
|
+
|
|
|
var firstYaWeiStopTime = DeviceTimeValue("1号YaWei折弯机", "停止标志位")- DevicMainTableTime("亚威一号折弯机").TotalSeconds;//1号YaWei折弯机等待时间
|
|
|
var sencondYaWeiStopTime = DeviceTimeValue("2号YaWei折弯机", "停止标志位") - DevicMainTableTime("亚威二号折弯机").TotalSeconds;//2号YaWei折弯机等待时间
|
|
|
var thirdYaWweiStopTime = DeviceTimeValue("3号YaWei折弯机", "停止标志位") - DevicMainTableTime("亚威三号折弯机").TotalSeconds; //3号YaWei折弯机等待时间
|
|
@@ -384,7 +392,7 @@ namespace SCADA_DAQ.Customer
|
|
|
|
|
|
try
|
|
|
{
|
|
|
- if (e.ChangeType == SCADA.CommonLib.DateTimeChangeType.SecondChanged &&
|
|
|
+ if (e.ChangeType == SCADA.CommonLib.DateTimeChangeType.MinuteChanged &&
|
|
|
e.TimeFlag.Minute % 1 == 0)
|
|
|
{
|
|
|
GetDBData();
|
|
@@ -415,23 +423,24 @@ namespace SCADA_DAQ.Customer
|
|
|
var pbcYaWweiRepairTime = "倒计时" + DeviceRepairTime("亚威PBC折弯机").ToString() + "天";//亚威PBC折弯机设备保养信息
|
|
|
var baiChaoRepairTime = "倒计时" + DeviceRepairTime("百超折弯机").ToString() + "天";//百超折弯机设备保养信息
|
|
|
|
|
|
- var firstYaWeiTimeMaintenanceTable = Convert.ToString(DevicMainTableTime("亚威一号折弯机") + TimeSpan.FromSeconds(DeviceTimeValue("1号YaWei折弯机", "维修时间")));
|
|
|
- var secondYaWeiTimeMaintenanceTable = Convert.ToString(DevicMainTableTime("亚威二号折弯机") + TimeSpan.FromSeconds(DeviceTimeValue("2号YaWei折弯机", "维修时间")));
|
|
|
- var thirdYaWeiTimeMaintenanceTable = Convert.ToString(DevicMainTableTime("亚威三号折弯机") + TimeSpan.FromSeconds(DeviceTimeValue("3号YaWei折弯机", "维修时间")));
|
|
|
- var pbcYaWweiTimeMaintenanceTable = Convert.ToString(DevicMainTableTime("亚威PBC折弯机") + TimeSpan.FromSeconds(DeviceTimeValue("亚威PBC折弯机", "维修时间")));
|
|
|
- var baiChaoTimeMaintenanceTable = Convert.ToString(DevicMainTableTime("百超折弯机") + TimeSpan.FromSeconds(DeviceTimeValue("百超折弯机", "维修时间")));
|
|
|
-
|
|
|
- //double totalTimeOfDay = TimeSpan.Parse(DateTime.Now.ToString("HH:mm:ss")).TotalSeconds;
|
|
|
- //var firstYaWeiStopTime = totalTimeOfDay - firstYaWeiRunTime - firstYaWeiMoldTime - DevicScheduleStop("1号YaWei折弯机")
|
|
|
- // - DevicMainTableTime("亚威一号折弯机").TotalSeconds - DeviceTimeValue("1号YaWei折弯机", "维修时间") + DeviceStateCodeStopBetweenTime("1号YaWei折弯机", "维修时间");//1号YaWei折弯机等待时间
|
|
|
- //var sencondYaWeiStopTime = totalTimeOfDay - sencondYaWeiRunTime - sencondYaWeiMoldTime - DevicScheduleStop("2号YaWei折弯机")
|
|
|
- // - DevicMainTableTime("亚威二号折弯机").TotalSeconds - DeviceTimeValue("2号YaWei折弯机", "维修时间") + DeviceStateCodeStopBetweenTime("2号YaWei折弯机", "维修时间");//2号YaWei折弯机等待时间
|
|
|
- //var thirdYaWweiStopTime = totalTimeOfDay - thirdYaWweiRunTime - thirdYaWweiMoldTime - DevicScheduleStop("3号YaWei折弯机")
|
|
|
- // - DevicMainTableTime("亚威三号折弯机").TotalSeconds - DeviceTimeValue("3号YaWei折弯机", "维修时间") + DeviceStateCodeStopBetweenTime("3号YaWei折弯机", "维修时间"); //3号YaWei折弯机等待时间
|
|
|
- //var pbcYaWweiStopTime = totalTimeOfDay - pbcYaWweiRunTime - pbcYaWweiMoldTime - DevicScheduleStop("亚威PBC折弯机")
|
|
|
- // - DevicMainTableTime("亚威PBC折弯机").TotalSeconds - DeviceTimeValue("亚威PBC折弯机", "维修时间") + DeviceStateCodeStopBetweenTime("亚威PBC折弯机", "维修时间");//亚威PBC折弯机等待时间
|
|
|
- //var baiChaoStopTime = totalTimeOfDay - baiChaoRunTime - baiChaoMoldTime - DevicScheduleStop("百超折弯机")
|
|
|
- // - DevicMainTableTime("百超折弯机").TotalSeconds - DeviceTimeValue("百超折弯机", "维修时间") + DeviceStateCodeStopBetweenTime("百超折弯机", "维修时间");//百超折弯机折弯机等待时间
|
|
|
+ //var firstYaWeiTimeMaintenanceTable = Convert.ToString(DevicMainTableTime("亚威一号折弯机") + TimeSpan.FromSeconds(DeviceTimeValue("1号YaWei折弯机", "维修时间")));
|
|
|
+ //var secondYaWeiTimeMaintenanceTable = Convert.ToString(DevicMainTableTime("亚威二号折弯机") + TimeSpan.FromSeconds(DeviceTimeValue("2号YaWei折弯机", "维修时间")));
|
|
|
+ //var thirdYaWeiTimeMaintenanceTable = Convert.ToString(DevicMainTableTime("亚威三号折弯机") + TimeSpan.FromSeconds(DeviceTimeValue("3号YaWei折弯机", "维修时间")));
|
|
|
+ //var pbcYaWweiTimeMaintenanceTable = Convert.ToString(DevicMainTableTime("亚威PBC折弯机") + TimeSpan.FromSeconds(DeviceTimeValue("亚威PBC折弯机", "维修时间")));
|
|
|
+ //var baiChaoTimeMaintenanceTable = Convert.ToString(DevicMainTableTime("百超折弯机") + TimeSpan.FromSeconds(DeviceTimeValue("百超折弯机", "维修时间")));
|
|
|
+
|
|
|
+ var firstYaWeiTimeMaintenanceTableDouble = DevicMainTableTime("亚威一号折弯机").TotalSeconds + DeviceTimeValue("1号YaWei折弯机", "维修时间");
|
|
|
+ var secondYaWeiTimeMaintenanceTableDouble = DevicMainTableTime("亚威二号折弯机").TotalSeconds + DeviceTimeValue("2号YaWei折弯机", "维修时间");
|
|
|
+ var thirdYaWeiTimeMaintenanceTableDouble = DevicMainTableTime("亚威三号折弯机").TotalSeconds + DeviceTimeValue("3号YaWei折弯机", "维修时间");
|
|
|
+ var pbcYaWweiTimeMaintenanceTableDouble = DevicMainTableTime("亚威PBC折弯机").TotalSeconds + DeviceTimeValue("亚威PBC折弯机", "维修时间");
|
|
|
+ var baiChaoTimeMaintenanceTableDouble = DevicMainTableTime("百超折弯机").TotalSeconds + DeviceTimeValue("百超折弯机", "维修时间");
|
|
|
+
|
|
|
+ var firstYaWeiTimeMaintenanceTable = TimeSpan.FromSeconds(Math.Round(firstYaWeiTimeMaintenanceTableDouble)).ToString();
|
|
|
+ var secondYaWeiTimeMaintenanceTable = TimeSpan.FromSeconds(Math.Round(secondYaWeiTimeMaintenanceTableDouble)).ToString();
|
|
|
+ var thirdYaWeiTimeMaintenanceTable = TimeSpan.FromSeconds(Math.Round(thirdYaWeiTimeMaintenanceTableDouble)).ToString();
|
|
|
+ var pbcYaWweiTimeMaintenanceTable = TimeSpan.FromSeconds(Math.Round(pbcYaWweiTimeMaintenanceTableDouble)).ToString();
|
|
|
+ var baiChaoTimeMaintenanceTable = TimeSpan.FromSeconds(Math.Round(baiChaoTimeMaintenanceTableDouble)).ToString();
|
|
|
+
|
|
|
var firstYaWeiStopTime = DeviceTimeValue("1号YaWei折弯机", "停止标志位") - DevicMainTableTime("亚威一号折弯机").TotalSeconds;//1号YaWei折弯机等待时间
|
|
|
var sencondYaWeiStopTime = DeviceTimeValue("2号YaWei折弯机", "停止标志位") - DevicMainTableTime("亚威二号折弯机").TotalSeconds;//2号YaWei折弯机等待时间
|
|
|
var thirdYaWweiStopTime = DeviceTimeValue("3号YaWei折弯机", "停止标志位") - DevicMainTableTime("亚威三号折弯机").TotalSeconds; //3号YaWei折弯机等待时间
|