From c99be54299ddb4a61453509f7cca2c2057119c27 Mon Sep 17 00:00:00 2001 From: n313893254 Date: Thu, 15 Aug 2019 14:56:53 +0800 Subject: [PATCH] Fix can't select existing secret in the catalog ui https://github.com/rancher/rancher/issues/22092 --- .../addon/components/input-answer-row/component.js | 4 ++++ .../addon/components/input-answer-row/template.hbs | 9 +++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/lib/shared/addon/components/input-answer-row/component.js b/lib/shared/addon/components/input-answer-row/component.js index 8d756a425..9115c69e0 100644 --- a/lib/shared/addon/components/input-answer-row/component.js +++ b/lib/shared/addon/components/input-answer-row/component.js @@ -1,5 +1,6 @@ import Component from '@ember/component'; import layout from './template'; +import { computed, get } from '@ember/object'; export default Component.extend({ question: null, @@ -10,4 +11,7 @@ export default Component.extend({ tagName: 'div', + namespace: computed('namespaceId', function() { + return { id: get(this, 'namespaceId'), } + }), }); diff --git a/lib/shared/addon/components/input-answer-row/template.hbs b/lib/shared/addon/components/input-answer-row/template.hbs index 2622e7d18..00a9a9a49 100644 --- a/lib/shared/addon/components/input-answer-row/template.hbs +++ b/lib/shared/addon/components/input-answer-row/template.hbs @@ -11,6 +11,7 @@ field=question value=answer namespaceId=namespaceId + namespace=namespace }} {{else}} {{input @@ -18,7 +19,11 @@ value=question.answer class="form-control" }} -

{{t 'inputAnswers.unknownType'}} {{question.type}}

+

+ {{t 'inputAnswers.unknownType'}} {{question.type}} +

{{/if}} -

{{question.description}}

\ No newline at end of file +

+ {{question.description}} +

\ No newline at end of file