|
@@ -326,21 +326,21 @@ func HandleAMI(event map[string]string) {
|
|
|
priority.OCCAnswer = 0
|
|
priority.OCCAnswer = 0
|
|
|
priority.PADOccStart = 0
|
|
priority.PADOccStart = 0
|
|
|
|
|
|
|
|
- /*//clean confbridge
|
|
|
|
|
|
|
+ //clean confbridge
|
|
|
taskTmp, _ := priority.RegistryTask.Get("PAD-OCC")
|
|
taskTmp, _ := priority.RegistryTask.Get("PAD-OCC")
|
|
|
|
|
+ priority.RegistryTask.StopAndUnregister("PAD-OCC")
|
|
|
ConfbridgeKick(taskTmp.ConfbridgeID, "all")
|
|
ConfbridgeKick(taskTmp.ConfbridgeID, "all")
|
|
|
|
|
|
|
|
- //check resume
|
|
|
|
|
- priority.RegistryTask.StopAndUnregister("PAD-OCC")
|
|
|
|
|
- taskName, task, ok := priority.RegistryTask.HighestPriorityRunningTask1()
|
|
|
|
|
- if ok {
|
|
|
|
|
- if taskName == "EMG" {
|
|
|
|
|
- EMGConfbridgeReinvite(task.ConfbridgeID)
|
|
|
|
|
- } else if taskName == "CPA" {
|
|
|
|
|
- CPAConfbridgeReinvite(task.ConfbridgeID)
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
- */
|
|
|
|
|
|
|
+ //check resume
|
|
|
|
|
+ taskName, task, ok := priority.RegistryTask.HighestPriorityRunningTask1()
|
|
|
|
|
+ if ok {
|
|
|
|
|
+ if taskName == "EMG" {
|
|
|
|
|
+ EMGConfbridgeReinvite(task.ConfbridgeID)
|
|
|
|
|
+ } else if taskName == "CPA" {
|
|
|
|
|
+ CPAConfbridgeReinvite(task.ConfbridgeID)
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
//break
|
|
//break
|
|
|
} else { //OCC queue is not empty
|
|
} else { //OCC queue is not empty
|
|
|
|
|
|
|
@@ -353,62 +353,77 @@ func HandleAMI(event map[string]string) {
|
|
|
|
|
|
|
|
//time.Sleep(time.Millisecond * 100) //wait io idle
|
|
//time.Sleep(time.Millisecond * 100) //wait io idle
|
|
|
//lfshook.NewLogger().Infof("====Start OCC-PAD===next==%+v", res)
|
|
//lfshook.NewLogger().Infof("====Start OCC-PAD===next==%+v", res)
|
|
|
- if active.ActivedCab == "1" && ExtenStatus("1411") == "Idle" { //check active and OCC status
|
|
|
|
|
- time.Sleep(time.Second)
|
|
|
|
|
- PADChan := ""
|
|
|
|
|
-
|
|
|
|
|
- if res.Entrys != nil {
|
|
|
|
|
- for _, chanEntry := range res.Entrys {
|
|
|
|
|
- lfshook.NewLogger().Infof("PAD answered by OCC1 pos:%s chan:%s", chanEntry.Position, chanEntry.Channel)
|
|
|
|
|
-
|
|
|
|
|
- if chanEntry.Position == "1" {
|
|
|
|
|
- PADChan = chanEntry.Channel
|
|
|
|
|
- utils.LoggerDebug.Printf("PAD-OCC , Get the first PAD(%s) in the queue !", PADChan)
|
|
|
|
|
- break
|
|
|
|
|
|
|
+ if active.TrainDevide == 0 { //列车没有断开
|
|
|
|
|
+ if (active.ActivedCab == "1" && ExtenStatus("1411") == "Idle") || (active.ActivedCab == "" && active.ActivedCabDelay == "1" && ExtenStatus("1411") == "Idle") { //check active and OCC status
|
|
|
|
|
+ time.Sleep(time.Second)
|
|
|
|
|
+ PADChan := ""
|
|
|
|
|
+
|
|
|
|
|
+ if res.Entrys != nil {
|
|
|
|
|
+ for _, chanEntry := range res.Entrys {
|
|
|
|
|
+ lfshook.NewLogger().Infof("PAD answered by OCC1 pos:%s chan:%s", chanEntry.Position, chanEntry.Channel)
|
|
|
|
|
+
|
|
|
|
|
+ if chanEntry.Position == "1" {
|
|
|
|
|
+ PADChan = chanEntry.Channel
|
|
|
|
|
+ utils.LoggerDebug.Printf("PAD-OCC , Get the first PAD(%s) in the queue !", PADChan)
|
|
|
|
|
+ break
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
- }
|
|
|
|
|
|
|
|
|
|
- if PADChan != "" {
|
|
|
|
|
- Ext := strings.Split(strings.Split(res.Entrys[0].Channel, "/")[1], "-")[0]
|
|
|
|
|
- alstatus.AlarmStatus(Ext, "connect")
|
|
|
|
|
|
|
+ if PADChan != "" {
|
|
|
|
|
+ Ext := strings.Split(strings.Split(res.Entrys[0].Channel, "/")[1], "-")[0]
|
|
|
|
|
+ alstatus.AlarmStatus(Ext, "connect")
|
|
|
|
|
|
|
|
- utils.LoggerDebug.Printf("PAD goto OCC1 , redirect %s to OCC1 !", PADChan)
|
|
|
|
|
- go RedirectInQueue(PADChan, "1411", "pad-page-occ-icp", Ext) //PAD Page(OCC+ICPs)
|
|
|
|
|
|
|
+ utils.LoggerDebug.Printf("PAD goto OCC1 , redirect %s to OCC1 !", PADChan)
|
|
|
|
|
+ go RedirectInQueue(PADChan, "1411", "pad-page-occ-icp", Ext) //PAD Page(OCC+ICPs)
|
|
|
|
|
|
|
|
- go Dial("0401", "0512", "pad-rule-pacus-occ", "ano1", "ano1", "1") // PACUs dial OCC1
|
|
|
|
|
- } else {
|
|
|
|
|
- lfshook.NewLogger().Infof("OCC-QueueStatus PADCchan NULL")
|
|
|
|
|
- utils.LoggerDebug.Printf("PAD-OCC , OCC Queue Status PADCchan return NULL .")
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
- break
|
|
|
|
|
- } else if active.ActivedCab == "8" && ExtenStatus("1481") == "Idle" {
|
|
|
|
|
- time.Sleep(time.Second)
|
|
|
|
|
- PADChan := ""
|
|
|
|
|
-
|
|
|
|
|
- if res.Entrys != nil {
|
|
|
|
|
- for _, chanEntry := range res.Entrys {
|
|
|
|
|
- lfshook.NewLogger().Infof("PAD answered by OCC1 pos:%s chan:%s", chanEntry.Position, chanEntry.Channel)
|
|
|
|
|
- if chanEntry.Position == "1" {
|
|
|
|
|
- PADChan = chanEntry.Channel
|
|
|
|
|
- utils.LoggerDebug.Printf("PAD-OCC , Get the first PAD(%s) in the queue !", PADChan)
|
|
|
|
|
- break
|
|
|
|
|
|
|
+ go Dial("0401", "0512", "pad-rule-pacus-occ", "ano1", "ano1", "1") // PACUs dial OCC1
|
|
|
|
|
+ } else {
|
|
|
|
|
+ lfshook.NewLogger().Infof("OCC-QueueStatus PADCchan NULL")
|
|
|
|
|
+ utils.LoggerDebug.Printf("PAD-OCC , OCC Queue Status PADCchan return NULL .")
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
+ break
|
|
|
|
|
+ } else if (active.ActivedCab == "8" && ExtenStatus("1481") == "Idle") || (active.ActivedCab == "" && active.ActivedCabDelay == "8" && ExtenStatus("1481") == "Idle") {
|
|
|
|
|
+ time.Sleep(time.Second)
|
|
|
|
|
+ PADChan := ""
|
|
|
|
|
+
|
|
|
|
|
+ if res.Entrys != nil {
|
|
|
|
|
+ for _, chanEntry := range res.Entrys {
|
|
|
|
|
+ lfshook.NewLogger().Infof("PAD answered by OCC1 pos:%s chan:%s", chanEntry.Position, chanEntry.Channel)
|
|
|
|
|
+ if chanEntry.Position == "1" {
|
|
|
|
|
+ PADChan = chanEntry.Channel
|
|
|
|
|
+ utils.LoggerDebug.Printf("PAD-OCC , Get the first PAD(%s) in the queue !", PADChan)
|
|
|
|
|
+ break
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
|
|
|
- if PADChan != "" {
|
|
|
|
|
- Ext := strings.Split(strings.Split(res.Entrys[0].Channel, "/")[1], "-")[0]
|
|
|
|
|
- alstatus.AlarmStatus(Ext, "connect")
|
|
|
|
|
|
|
+ if PADChan != "" {
|
|
|
|
|
+ Ext := strings.Split(strings.Split(res.Entrys[0].Channel, "/")[1], "-")[0]
|
|
|
|
|
+ alstatus.AlarmStatus(Ext, "connect")
|
|
|
|
|
|
|
|
- utils.LoggerDebug.Printf("PAD goto OCC8 , redirect %s to OCC8 !", PADChan)
|
|
|
|
|
- go RedirectInQueue(PADChan, "1481", "pad-page-occ-icp", Ext) //PAD Page(OCC+ICPs)
|
|
|
|
|
|
|
+ utils.LoggerDebug.Printf("PAD goto OCC8 , redirect %s to OCC8 !", PADChan)
|
|
|
|
|
+ go RedirectInQueue(PADChan, "1481", "pad-page-occ-icp", Ext) //PAD Page(OCC+ICPs)
|
|
|
|
|
|
|
|
- go Dial("0401", "0512", "pad-rule-pacus-occ", "ano8", "ano8", "8") // PACUs dial OCC1
|
|
|
|
|
- } else {
|
|
|
|
|
- lfshook.NewLogger().Infof("OCC QueueStatus PADCchan NULL")
|
|
|
|
|
|
|
+ go Dial("0401", "0512", "pad-rule-pacus-occ", "ano8", "ano8", "8") // PACUs dial OCC1
|
|
|
|
|
+ } else {
|
|
|
|
|
+ lfshook.NewLogger().Infof("OCC QueueStatus PADCchan NULL")
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
|
|
+ break
|
|
|
|
|
+ }
|
|
|
|
|
+ } else { //列车断开模式下
|
|
|
|
|
+ if active.ActivedCab == "1" && ExtenStatus("1411") == "Idle" { //check active and OCC status
|
|
|
|
|
+
|
|
|
|
|
+ alstatus.AlarmStatus(event["CallerIDNum"], "connect")
|
|
|
|
|
+ go RedirectInQueue(event["Channel"], "1411", "pad-page-occ-icp", event["CallerIDNum"]) //PAD Page(OCC+ICPs)
|
|
|
|
|
+ go Dial("0401", "0512", "pad-rule-pacus-occ", "ano1", "ano1", "1") // PACUs dial OCC1
|
|
|
|
|
+
|
|
|
|
|
+ } else if active.ActivedCab == "8" && ExtenStatus("1481") == "Idle" {
|
|
|
|
|
+
|
|
|
|
|
+ alstatus.AlarmStatus(event["CallerIDNum"], "connect")
|
|
|
|
|
+ go RedirectInQueue(event["Channel"], "1481", "pad-page-occ-icp", event["CallerIDNum"]) //PAD Page(OCC+ICPs)
|
|
|
|
|
+ go Dial("0401", "0512", "pad-rule-pacus-occ", "ano8", "ano8", "8") // PACUs dial OCC8
|
|
|
}
|
|
}
|
|
|
- break
|
|
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -417,9 +432,9 @@ func HandleAMI(event map[string]string) {
|
|
|
|
|
|
|
|
number := strings.Split(strings.Split(event["Channel"], "-")[0], "/")[1]
|
|
number := strings.Split(strings.Split(event["Channel"], "-")[0], "/")[1]
|
|
|
|
|
|
|
|
- //lfshook.NewLogger().Infof("===hangup PAD =======================%s", number)
|
|
|
|
|
|
|
+ lfshook.NewLogger().Infof("===hangup PAD ===NUM:%s=================listAllTask:%+v===", number, priority.RegistryTask.ListAll())
|
|
|
|
|
|
|
|
- if utils.IsPAIU(number) {
|
|
|
|
|
|
|
+ if utils.IsPAIU(number) { //pad and io hangup
|
|
|
|
|
|
|
|
//clean confbridge & clean task info
|
|
//clean confbridge & clean task info
|
|
|
//PAD-ICP
|
|
//PAD-ICP
|
|
@@ -443,6 +458,7 @@ func HandleAMI(event map[string]string) {
|
|
|
priority.RegistryTask.StopAndUnregister("PAD-OCC")
|
|
priority.RegistryTask.StopAndUnregister("PAD-OCC")
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
+ lfshook.NewLogger().Infof("===hangup PAD ===NUM:%s========2222=========listAllTask:%+v===", number, priority.RegistryTask.ListAll())
|
|
|
//Check PAD END
|
|
//Check PAD END
|
|
|
res, _ := QueueStatus("0300", "") // check ICP queue ,if empty PAD end
|
|
res, _ := QueueStatus("0300", "") // check ICP queue ,if empty PAD end
|
|
|
res1, _ := QueueStatus("0301", "") // check OCC queue ,if empty PAD end
|
|
res1, _ := QueueStatus("0301", "") // check OCC queue ,if empty PAD end
|
|
@@ -538,9 +554,9 @@ func HandleAMI(event map[string]string) {
|
|
|
//lfshook.NewLogger().Logger.Infof("=========Start PAD timer !=============")
|
|
//lfshook.NewLogger().Logger.Infof("=========Start PAD timer !=============")
|
|
|
if active.QueueTimer != nil {
|
|
if active.QueueTimer != nil {
|
|
|
if active.QueueTimer.Stop() {
|
|
if active.QueueTimer.Stop() {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
} else {
|
|
} else {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
//lfshook.NewLogger().Logger.Infof("=========Start PAD timer !======%d=======", active.PADTimeout)
|
|
//lfshook.NewLogger().Logger.Infof("=========Start PAD timer !======%d=======", active.PADTimeout)
|
|
@@ -548,9 +564,9 @@ func HandleAMI(event map[string]string) {
|
|
|
active.QueueTimer = time.AfterFunc(time.Duration(active.PADTimeout)*time.Second, func() { // check the PAD 30s timeout
|
|
active.QueueTimer = time.AfterFunc(time.Duration(active.PADTimeout)*time.Second, func() { // check the PAD 30s timeout
|
|
|
//active.QueueTimer = time.AfterFunc(30*time.Second, func() { // check the PAD 30s timeout
|
|
//active.QueueTimer = time.AfterFunc(30*time.Second, func() { // check the PAD 30s timeout
|
|
|
//if both not active , return
|
|
//if both not active , return
|
|
|
- if active.ActivedCab == "" {
|
|
|
|
|
- return
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ //if active.ActivedCab == "" {
|
|
|
|
|
+ // return
|
|
|
|
|
+ //}
|
|
|
|
|
|
|
|
res, err := QueueStatus("0301", "") // check OCC queue , if empty OCC-PAD start
|
|
res, err := QueueStatus("0301", "") // check OCC queue , if empty OCC-PAD start
|
|
|
if err != nil {
|
|
if err != nil {
|
|
@@ -609,20 +625,20 @@ func HandleAMI(event map[string]string) {
|
|
|
|
|
|
|
|
time.Sleep(time.Millisecond * 300)
|
|
time.Sleep(time.Millisecond * 300)
|
|
|
|
|
|
|
|
- //if active.TrainDevide == 0 { //列车没有断开
|
|
|
|
|
- if active.ActivedCab == "1" && ExtenStatus("1411") == "Idle" { //check active and OCC status
|
|
|
|
|
- utils.LoggerDebug.Printf("PAD %s goto OCC1 .", event["CallerIDNum"])
|
|
|
|
|
- alstatus.AlarmStatus(event["CallerIDNum"], "connect")
|
|
|
|
|
- go RedirectInQueue(event["Channel"], "1411", "pad-page-occ-icp", event["CallerIDNum"]) //PAD Page(OCC+ICPs)
|
|
|
|
|
- go Dial("0401", "0512", "pad-rule-pacus-occ", "ano1", "ano1", "1") // PACUs dial OCC1
|
|
|
|
|
-
|
|
|
|
|
- } else if active.ActivedCab == "8" && ExtenStatus("1481") == "Idle" {
|
|
|
|
|
- utils.LoggerDebug.Printf("PAD %s goto OCC8 .", event["CallerIDNum"])
|
|
|
|
|
- alstatus.AlarmStatus(event["CallerIDNum"], "connect")
|
|
|
|
|
- go RedirectInQueue(event["Channel"], "1481", "pad-page-occ-icp", event["CallerIDNum"]) //PAD Page(OCC+ICPs)
|
|
|
|
|
- go Dial("0401", "0512", "pad-rule-pacus-occ", "ano8", "ano8", "8") // PACUs dial OCC8
|
|
|
|
|
- }
|
|
|
|
|
- /*} else { //列车断开模式下
|
|
|
|
|
|
|
+ if active.TrainDevide == 0 { //列车没有断开
|
|
|
|
|
+ if (active.ActivedCab == "1" && ExtenStatus("1411") == "Idle") || (active.ActivedCab == "" && active.ActivedCabDelay == "1" && ExtenStatus("1411") == "Idle") { //check active and OCC status
|
|
|
|
|
+ utils.LoggerDebug.Printf("PAD %s goto OCC1 .", event["CallerIDNum"])
|
|
|
|
|
+ alstatus.AlarmStatus(event["CallerIDNum"], "connect")
|
|
|
|
|
+ go RedirectInQueue(event["Channel"], "1411", "pad-page-occ-icp", event["CallerIDNum"]) //PAD Page(OCC+ICPs)
|
|
|
|
|
+ go Dial("0401", "0512", "pad-rule-pacus-occ", "ano1", "ano1", "1") // PACUs dial OCC1
|
|
|
|
|
+
|
|
|
|
|
+ } else if (active.ActivedCab == "8" && ExtenStatus("1481") == "Idle") || (active.ActivedCab == "" && active.ActivedCabDelay == "8" && ExtenStatus("1481") == "Idle") {
|
|
|
|
|
+ utils.LoggerDebug.Printf("PAD %s goto OCC8 .", event["CallerIDNum"])
|
|
|
|
|
+ alstatus.AlarmStatus(event["CallerIDNum"], "connect")
|
|
|
|
|
+ go RedirectInQueue(event["Channel"], "1481", "pad-page-occ-icp", event["CallerIDNum"]) //PAD Page(OCC+ICPs)
|
|
|
|
|
+ go Dial("0401", "0512", "pad-rule-pacus-occ", "ano8", "ano8", "8") // PACUs dial OCC8
|
|
|
|
|
+ }
|
|
|
|
|
+ } else { //列车断开模式下
|
|
|
if active.ActivedCab == "1" && ExtenStatus("1411") == "Idle" { //check active and OCC status
|
|
if active.ActivedCab == "1" && ExtenStatus("1411") == "Idle" { //check active and OCC status
|
|
|
|
|
|
|
|
alstatus.AlarmStatus(event["CallerIDNum"], "connect")
|
|
alstatus.AlarmStatus(event["CallerIDNum"], "connect")
|
|
@@ -635,7 +651,8 @@ func HandleAMI(event map[string]string) {
|
|
|
go RedirectInQueue(event["Channel"], "1481", "pad-page-occ-icp", event["CallerIDNum"]) //PAD Page(OCC+ICPs)
|
|
go RedirectInQueue(event["Channel"], "1481", "pad-page-occ-icp", event["CallerIDNum"]) //PAD Page(OCC+ICPs)
|
|
|
go Dial("0401", "0512", "pad-rule-pacus-occ", "ano8", "ano8", "8") // PACUs dial OCC8
|
|
go Dial("0401", "0512", "pad-rule-pacus-occ", "ano8", "ano8", "8") // PACUs dial OCC8
|
|
|
}
|
|
}
|
|
|
- }*/
|
|
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
} else {
|
|
} else {
|
|
|
lfshook.NewLogger().Infof("====PAD-OCC Priority false===")
|
|
lfshook.NewLogger().Infof("====PAD-OCC Priority false===")
|
|
|
}
|
|
}
|
|
@@ -673,9 +690,9 @@ func HandleAMI(event map[string]string) {
|
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.EMG.Priority {
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.EMG.Priority {
|
|
|
if active.QueueTimer != nil {
|
|
if active.QueueTimer != nil {
|
|
|
if active.QueueTimer.Stop() {
|
|
if active.QueueTimer.Stop() {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
} else {
|
|
} else {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -704,9 +721,9 @@ func HandleAMI(event map[string]string) {
|
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.SPC.Priority {
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.SPC.Priority {
|
|
|
if active.QueueTimer != nil {
|
|
if active.QueueTimer != nil {
|
|
|
if active.QueueTimer.Stop() {
|
|
if active.QueueTimer.Stop() {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
} else {
|
|
} else {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -735,9 +752,9 @@ func HandleAMI(event map[string]string) {
|
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.DCS.Priority {
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.DCS.Priority {
|
|
|
if active.QueueTimer != nil {
|
|
if active.QueueTimer != nil {
|
|
|
if active.QueueTimer.Stop() {
|
|
if active.QueueTimer.Stop() {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
} else {
|
|
} else {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -767,9 +784,9 @@ func HandleAMI(event map[string]string) {
|
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.STN.Priority {
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.STN.Priority {
|
|
|
if active.QueueTimer != nil {
|
|
if active.QueueTimer != nil {
|
|
|
if active.QueueTimer.Stop() {
|
|
if active.QueueTimer.Stop() {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
} else {
|
|
} else {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -799,9 +816,9 @@ func HandleAMI(event map[string]string) {
|
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.CHK.Priority {
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.CHK.Priority {
|
|
|
if active.QueueTimer != nil {
|
|
if active.QueueTimer != nil {
|
|
|
if active.QueueTimer.Stop() {
|
|
if active.QueueTimer.Stop() {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
} else {
|
|
} else {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -829,9 +846,9 @@ func HandleAMI(event map[string]string) {
|
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.VOL.Priority {
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.VOL.Priority {
|
|
|
if active.QueueTimer != nil {
|
|
if active.QueueTimer != nil {
|
|
|
if active.QueueTimer.Stop() {
|
|
if active.QueueTimer.Stop() {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
} else {
|
|
} else {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -869,9 +886,9 @@ func HandleAMI(event map[string]string) {
|
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.PA.Priority {
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.PA.Priority {
|
|
|
if active.QueueTimer != nil {
|
|
if active.QueueTimer != nil {
|
|
|
if active.QueueTimer.Stop() {
|
|
if active.QueueTimer.Stop() {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
} else {
|
|
} else {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -901,9 +918,9 @@ func HandleAMI(event map[string]string) {
|
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.CPA.Priority {
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.CPA.Priority {
|
|
|
if active.QueueTimer != nil {
|
|
if active.QueueTimer != nil {
|
|
|
if active.QueueTimer.Stop() {
|
|
if active.QueueTimer.Stop() {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
} else {
|
|
} else {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -1189,9 +1206,9 @@ func HandleAMI(event map[string]string) {
|
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.C2C.Priority {
|
|
if priority.AllTasks.PADOCC.Priority > priority.AllTasks.C2C.Priority {
|
|
|
if active.QueueTimer != nil {
|
|
if active.QueueTimer != nil {
|
|
|
if active.QueueTimer.Stop() {
|
|
if active.QueueTimer.Stop() {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer true !============")
|
|
|
} else {
|
|
} else {
|
|
|
- lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
|
|
|
|
+ //lfshook.NewLogger().Logger.Infof("=========Release PAD timer false ! ============")
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|