- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
- 23
func (incident Incident) DeleteResponsibleMicroservices(microservices []string) {
var teamsDelete []string
responsibleMss := incident.GetResponsibleMicroservices()
for _, microservice := range microservices {
ResponsibleMssLoop:
for _, responsibleMs := range responsibleMss {
if microservice == responsibleMs.MicroserviceId {
service.GetInstanceDB().Delete(responsibleMs)
if team, ok := GetTeamByMs(microservice); ok != false {
for _, ms := range incident.GetResponsibleMicroservices() {
if teamFind, ok := GetTeamByMs(ms.MicroserviceId); ok != false && teamFind == team {
continue ResponsibleMssLoop
}
}
teamsDelete = append(teamsDelete, team)
}
}
}
}
if len(teamsDelete) > 0 {
incident.DeleteResponsibles(teamsDelete)
}
}
OBEH 09.10.2018 16:57 # −1
guest8 09.10.2018 17:03 # −999
guest8 09.10.2018 21:15 # −999
guest8 09.10.2018 21:41 # −999
guest8 09.10.2018 21:42 # −999
DOKTOPuHXO 09.10.2018 22:11 # 0
Стертор - великий мистификатор. Такой бы талант - да в достойное русло.
DOKTOPuHXO 09.10.2018 22:12 # 0