/// <summary> /// 발령결과 ListView 업데이트 /// </summary> private void setTermStatusUpdate() { foreach (NCasListViewItem listViewItem in this.orderResultListView.Items) { if (listViewItem == null) { continue; } if (listViewItem.Name == string.Empty) { continue; } if (listViewItem.Tag is PBroadInfo) { PBroadInfo pBroadInfo = this.main.MmfMng.GetProvBroadInfoByIp(listViewItem.Name); listViewItem.ImageIndex = (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmStandby) ? 0 : //예비 (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmWatch) ? 1 : //경계 (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmAttack) ? 2 : //공습 (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmBiochemist) ? 3 : //화생방 (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmCancel) ? 4 : //해제 (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.DisasterWatch) ? 5 : //재난위험(사이렌) (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.DisasterBroadcast) ? 6 : 4; //재난경계(방송) listViewItem.SubItems[3].Text = (pBroadInfo.BroadOrderInfo.Mode == NCasDefineOrderMode.RealMode) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderMode2String(NCasDefineOrderMode.RealMode) : (pBroadInfo.BroadOrderInfo.Mode == NCasDefineOrderMode.TestMode) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderMode2String(NCasDefineOrderMode.TestMode) : string.Empty; listViewItem.SubItems[4].Text = (pBroadInfo.BroadOrderInfo.Source == NCasDefineOrderSource.CentCtrlRoom) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderSource2String(NCasDefineOrderSource.CentCtrlRoom) : (pBroadInfo.BroadOrderInfo.Source == NCasDefineOrderSource.CentCtrlRoom2) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderSource2String(NCasDefineOrderSource.CentCtrlRoom2) : (pBroadInfo.BroadOrderInfo.Source == NCasDefineOrderSource.CentCtrlRoom3) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderSource2String(NCasDefineOrderSource.CentCtrlRoom3) : (pBroadInfo.BroadOrderInfo.Source == NCasDefineOrderSource.DistCtrlRoom) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderSource2String(NCasDefineOrderSource.DistCtrlRoom) : (pBroadInfo.BroadOrderInfo.Source == NCasDefineOrderSource.ProvBroadSelf) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderSource2String(NCasDefineOrderSource.ProvBroadSelf) : (pBroadInfo.BroadOrderInfo.Source == NCasDefineOrderSource.ProvCtrlRoom) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderSource2String(NCasDefineOrderSource.ProvCtrlRoom) : (pBroadInfo.BroadOrderInfo.Source == NCasDefineOrderSource.ProvDistribution) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderSource2String(NCasDefineOrderSource.ProvDistribution) : (pBroadInfo.BroadOrderInfo.Source == NCasDefineOrderSource.ProvTermSelf) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderSource2String(NCasDefineOrderSource.ProvTermSelf) : string.Empty; listViewItem.SubItems[5].Text = (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmStandby) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.AlarmStandby) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmWatch) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.AlarmWatch) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmAttack) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.AlarmAttack) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmBiochemist) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.AlarmBiochemist) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmCancel) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.AlarmCancel) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmClose) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.AlarmClose) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.DisasterWatch) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.DisasterWatch) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.VoiceLineTest) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.VoiceLineTest) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.BroadPublicVoice) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.BroadPublicVoice) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.BroadMessage) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.BroadMessage) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.TermTts) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.TermTts) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.CenterTts) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.CenterTts) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmRecover) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.AlarmRecover) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.DisasterBoradRecover) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.DisasterBoradRecover) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.DisasterStandby) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.DisasterStandby) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.DisasterBroadcast) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.DisasterBroadcast) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.None) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.None) : string.Empty; listViewItem.SubItems[6].Text = (pBroadInfo.BroadOrderInfo.Media == NCasDefineOrderMedia.MediaAll) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderMedia2String(NCasDefineOrderMedia.MediaAll) : (pBroadInfo.BroadOrderInfo.Media == NCasDefineOrderMedia.MediaLine) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderMedia2String(NCasDefineOrderMedia.MediaLine) : (pBroadInfo.BroadOrderInfo.Media == NCasDefineOrderMedia.MediaSate) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderMedia2String(NCasDefineOrderMedia.MediaSate) : string.Empty; listViewItem.SubItems[7].Text = NCasUtilityMng.INCasCommUtility.MakeDateTimeFormatForCasSystem(pBroadInfo.BroadOrderInfo.OccurTimeToDateTime); if (pBroadInfo.BroadResponseInfo.BroadResponse == NCasDefineResponse.None) { listViewItem.SubItems[8].Text = string.Empty; } else { listViewItem.SubItems[8].Text = NCasUtilityMng.INCasCommUtility.MakeDateTimeFormatForCasSystem(pBroadInfo.BroadResponseInfo.RespTimeToDateTime); } if (pBroadInfo.BroadOrderInfo.OccurTime == pBroadInfo.BroadCaptionOrderInfo.OccurTime) { listViewItem.SubItems[9].Text = (pBroadInfo.BroadCaptionResultInfo.BroadResult == NCasDefineNormalStatus.Noraml) ? NCasUtilityMng.INCasCommUtility.NCasDefineNormalStatus2String(NCasDefineNormalStatus.Noraml) : NCasUtilityMng.INCasCommUtility.NCasDefineNormalStatus2String(NCasDefineNormalStatus.Abnormal); } else { listViewItem.SubItems[9].Text = string.Empty; } } else if (listViewItem.Tag is PDeptInfo) { PDeptInfo pBroadInfo = this.main.MmfMng.GetProvDeptInfoByIp(listViewItem.Name); listViewItem.ImageIndex = (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmStandby) ? 0 : //예비 (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmWatch) ? 1 : //경계 (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmAttack) ? 2 : //공습 (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmBiochemist) ? 3 : //화생방 (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmCancel) ? 4 : //해제 (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.DisasterWatch) ? 5 : //재난위험(사이렌) (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.DisasterBroadcast) ? 6 : 4; //재난경계(방송) listViewItem.SubItems[3].Text = (pBroadInfo.BroadOrderInfo.Mode == NCasDefineOrderMode.RealMode) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderMode2String(NCasDefineOrderMode.RealMode) : (pBroadInfo.BroadOrderInfo.Mode == NCasDefineOrderMode.TestMode) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderMode2String(NCasDefineOrderMode.TestMode) : string.Empty; listViewItem.SubItems[4].Text = (pBroadInfo.BroadOrderInfo.Source == NCasDefineOrderSource.CentCtrlRoom) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderSource2String(NCasDefineOrderSource.CentCtrlRoom) : (pBroadInfo.BroadOrderInfo.Source == NCasDefineOrderSource.CentCtrlRoom2) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderSource2String(NCasDefineOrderSource.CentCtrlRoom2) : (pBroadInfo.BroadOrderInfo.Source == NCasDefineOrderSource.CentCtrlRoom3) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderSource2String(NCasDefineOrderSource.CentCtrlRoom3) : (pBroadInfo.BroadOrderInfo.Source == NCasDefineOrderSource.DistCtrlRoom) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderSource2String(NCasDefineOrderSource.DistCtrlRoom) : (pBroadInfo.BroadOrderInfo.Source == NCasDefineOrderSource.ProvBroadSelf) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderSource2String(NCasDefineOrderSource.ProvBroadSelf) : (pBroadInfo.BroadOrderInfo.Source == NCasDefineOrderSource.ProvCtrlRoom) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderSource2String(NCasDefineOrderSource.ProvCtrlRoom) : (pBroadInfo.BroadOrderInfo.Source == NCasDefineOrderSource.ProvDistribution) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderSource2String(NCasDefineOrderSource.ProvDistribution) : (pBroadInfo.BroadOrderInfo.Source == NCasDefineOrderSource.ProvTermSelf) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderSource2String(NCasDefineOrderSource.ProvTermSelf) : string.Empty; listViewItem.SubItems[5].Text = (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmStandby) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.AlarmStandby) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmWatch) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.AlarmWatch) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmAttack) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.AlarmAttack) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmBiochemist) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.AlarmBiochemist) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmCancel) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.AlarmCancel) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmClose) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.AlarmClose) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.DisasterWatch) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.DisasterWatch) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.VoiceLineTest) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.VoiceLineTest) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.BroadPublicVoice) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.BroadPublicVoice) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.BroadMessage) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.BroadMessage) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.TermTts) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.TermTts) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.CenterTts) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.CenterTts) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.AlarmRecover) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.AlarmRecover) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.DisasterBoradRecover) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.DisasterBoradRecover) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.DisasterStandby) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.DisasterStandby) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.DisasterBroadcast) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.DisasterBroadcast) : (pBroadInfo.BroadOrderInfo.Kind == NCasDefineOrderKind.None) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderKind2String(NCasDefineOrderKind.None) : string.Empty; listViewItem.SubItems[6].Text = (pBroadInfo.BroadOrderInfo.Media == NCasDefineOrderMedia.MediaAll) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderMedia2String(NCasDefineOrderMedia.MediaAll) : (pBroadInfo.BroadOrderInfo.Media == NCasDefineOrderMedia.MediaLine) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderMedia2String(NCasDefineOrderMedia.MediaLine) : (pBroadInfo.BroadOrderInfo.Media == NCasDefineOrderMedia.MediaSate) ? NCasUtilityMng.INCasCommUtility.NCasDefineOrderMedia2String(NCasDefineOrderMedia.MediaSate) : string.Empty; listViewItem.SubItems[7].Text = NCasUtilityMng.INCasCommUtility.MakeDateTimeFormatForCasSystem(pBroadInfo.BroadOrderInfo.OccurTimeToDateTime); if (pBroadInfo.BroadResponseInfo.BroadResponse == NCasDefineResponse.None) { listViewItem.SubItems[8].Text = string.Empty; } else { listViewItem.SubItems[8].Text = NCasUtilityMng.INCasCommUtility.MakeDateTimeFormatForCasSystem(pBroadInfo.BroadResponseInfo.RespTimeToDateTime); } listViewItem.SubItems[9].Text = string.Empty; } } }
/// <summary> /// 방송단말 ListView 업데이트 /// </summary> private void setTermStatusUpdate() { foreach (NCasListViewItem listViewItem in this.termStatusListView.Items) { if (listViewItem == null) { continue; } if (listViewItem.Name == string.Empty) { continue; } if ((DevKind)listViewItem.Tag == DevKind.BroadDev) { PBroadInfo pBroadInfo = this.main.MmfMng.GetProvBroadInfoByIp(listViewItem.Name); if (pBroadInfo.DevStsInfo.Status == NCasDefineNormalStatus.Noraml) { listViewItem.ImageIndex = 1; } else { listViewItem.ImageIndex = 0; } listViewItem.SubItems[3].Text = (pBroadInfo.DevStsInfo.Status == NCasDefineNormalStatus.None) ? "없음" : (pBroadInfo.DevStsInfo.Status == NCasDefineNormalStatus.NoAnswer) ? "무응답" : (pBroadInfo.DevStsInfo.Status == NCasDefineNormalStatus.Abnormal) ? "이상" : "정상"; if ((pBroadInfo.DevStsInfo.Status == NCasDefineNormalStatus.Abnormal) || (pBroadInfo.DevStsInfo.Status == NCasDefineNormalStatus.NoAnswer)) { listViewItem.SubItems[4].Text = NCasUtilityMng.INCasCommUtility.MakeDateTimeFormatForCasSystem(pBroadInfo.DevStsInfo.OccurTimeToDateTime); } else if ((pBroadInfo.DevStsInfo.Status == NCasDefineNormalStatus.Noraml) || (pBroadInfo.DevStsInfo.Status == NCasDefineNormalStatus.None)) { listViewItem.SubItems[4].Text = string.Empty; } } else if ((DevKind)listViewItem.Tag == DevKind.DeptDev) { PDeptInfo pBroadInfo = this.main.MmfMng.GetProvDeptInfoByIp(listViewItem.Name); if (pBroadInfo.DevStsInfo.Status == NCasDefineNormalStatus.Noraml) { listViewItem.ImageIndex = 1; } else { listViewItem.ImageIndex = 0; } listViewItem.SubItems[3].Text = (pBroadInfo.DevStsInfo.Status == NCasDefineNormalStatus.None) ? "없음" : (pBroadInfo.DevStsInfo.Status == NCasDefineNormalStatus.NoAnswer) ? "무응답" : (pBroadInfo.DevStsInfo.Status == NCasDefineNormalStatus.Abnormal) ? "이상" : "정상"; if ((pBroadInfo.DevStsInfo.Status == NCasDefineNormalStatus.Abnormal) || (pBroadInfo.DevStsInfo.Status == NCasDefineNormalStatus.NoAnswer)) { listViewItem.SubItems[4].Text = NCasUtilityMng.INCasCommUtility.MakeDateTimeFormatForCasSystem(pBroadInfo.DevStsInfo.OccurTimeToDateTime); } else if ((pBroadInfo.DevStsInfo.Status == NCasDefineNormalStatus.Noraml) || (pBroadInfo.DevStsInfo.Status == NCasDefineNormalStatus.None)) { listViewItem.SubItems[4].Text = string.Empty; } } } }