使用 UI-Router in AngularJS 将状态重定向到抽象状态的子级抛出内部通信错误
Redirect a state to an abstract state's child with UI-Router in AngularJS throws Intercom error
我正在将一个状态重构为一个抽象状态,其中包含一个包含许多嵌套视图的子级。
我需要保留 oldState,我的目标是将任何对 oldState 的引用重定向到 'app.newState.home'。
我在下面使用的当前实现(使用 redirectTo,)在重定向到不同抽象状态的子状态方面起作用。但是 - 我从细分分析中得到这个错误:
https://api-iam.intercom.io/ping/events 422 (Unprocessable Entity)
[{"code":"422","message":"Cannot have more than 120 active event names"}]}
.state('app.oldState', {
url: '/oldState',
redirectTo: 'app.newState.home',
})
.state('app.newState', {
url: '/oldState',
// abstract: true,
templateUrl: helper.basepath('anotherTemplate'),
resolve: helper.resolveFor('datatables','easypiechart','ngDialog','angularFileUpload', 'filestyle', 'taginput'),
})
.state('app.newState.home', {
url: '',
views: {
'firstView':{
templateUrl: helper.basepath('templateOne'),
controller: 'ControllerOne'
},
'secondView':{
templateUrl: helper.basepath('templateTwo'),
controller: 'ControllerOne'
},
'thirdView':{
templateUrl: helper.basepath('templateThree'),
controller: 'ControllerOne'
},
'fourthView':{
templateUrl: helper.basepath('templateFour'),
controller: 'ControllerTwo'
},
}
})
为什么会抛出这个错误,我该如何正确解决这个问题???
Intercom 允许最多 120 个事件名称。这记录在这里
https://docs.intercom.com/the-intercom-platform/track-events-in-intercom
header"Is there a limit on the number of event types I can send?".
下
文档还解释了如何 "archive" 事件,这可能会解决这种情况,直到再次达到极限。
我正在将一个状态重构为一个抽象状态,其中包含一个包含许多嵌套视图的子级。
我需要保留 oldState,我的目标是将任何对 oldState 的引用重定向到 'app.newState.home'。
我在下面使用的当前实现(使用 redirectTo,
https://api-iam.intercom.io/ping/events 422 (Unprocessable Entity)
[{"code":"422","message":"Cannot have more than 120 active event names"}]}
.state('app.oldState', {
url: '/oldState',
redirectTo: 'app.newState.home',
})
.state('app.newState', {
url: '/oldState',
// abstract: true,
templateUrl: helper.basepath('anotherTemplate'),
resolve: helper.resolveFor('datatables','easypiechart','ngDialog','angularFileUpload', 'filestyle', 'taginput'),
})
.state('app.newState.home', {
url: '',
views: {
'firstView':{
templateUrl: helper.basepath('templateOne'),
controller: 'ControllerOne'
},
'secondView':{
templateUrl: helper.basepath('templateTwo'),
controller: 'ControllerOne'
},
'thirdView':{
templateUrl: helper.basepath('templateThree'),
controller: 'ControllerOne'
},
'fourthView':{
templateUrl: helper.basepath('templateFour'),
controller: 'ControllerTwo'
},
}
})
为什么会抛出这个错误,我该如何正确解决这个问题???
Intercom 允许最多 120 个事件名称。这记录在这里 https://docs.intercom.com/the-intercom-platform/track-events-in-intercom header"Is there a limit on the number of event types I can send?".
下文档还解释了如何 "archive" 事件,这可能会解决这种情况,直到再次达到极限。