mirror of https://github.com/rancher/ui.git
Merge pull request #1763 from vimniky/dev
Update alert targetEvent type
This commit is contained in:
commit
2e07cc61d8
|
|
@ -40,10 +40,10 @@ export default Component.extend({
|
||||||
|
|
||||||
setEventType(t) {
|
setEventType(t) {
|
||||||
if (t === 'warningEvent') {
|
if (t === 'warningEvent') {
|
||||||
set(this, 'model.targetEvent.type', 'Warning');
|
set(this, 'model.targetEvent.eventType', 'Warning');
|
||||||
}
|
}
|
||||||
if (t === 'normalEvent') {
|
if (t === 'normalEvent') {
|
||||||
set(this, 'model.targetEvent.type', 'Normal');
|
set(this, 'model.targetEvent.eventType', 'Normal');
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
targetTypeChanged: function() {
|
targetTypeChanged: function() {
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,7 @@ export default Route.extend({
|
||||||
return gs.find('clusterAlert', alertId).then(alert => {
|
return gs.find('clusterAlert', alertId).then(alert => {
|
||||||
const t = alert.get('targetType');
|
const t = alert.get('targetType');
|
||||||
if (t === 'event') {
|
if (t === 'event') {
|
||||||
const et = alert.get('targetEvent.type');
|
const et = alert.get('targetEvent.eventType');
|
||||||
if (et === 'Normal') {
|
if (et === 'Normal') {
|
||||||
alert.set('_targetType', 'normalEvent');
|
alert.set('_targetType', 'normalEvent');
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue