Map deprecation_motivaton to motivation both ways. (#2466)
This commit is contained in:
Родитель
2bb1b3ba23
Коммит
ecbb80b436
|
@ -5,6 +5,7 @@ import './chromedash-form-table';
|
|||
import './chromedash-form-field';
|
||||
import {formatFeatureForEdit, STAGE_FORMS, IMPL_STATUS_FORMS} from './form-definition';
|
||||
import {IMPLEMENTATION_STATUS} from './form-field-enums';
|
||||
import {ALL_FIELDS} from './form-field-specs';
|
||||
import {SHARED_STYLES} from '../sass/shared-css.js';
|
||||
import {FORM_STYLES} from '../sass/forms-css.js';
|
||||
|
||||
|
@ -200,16 +201,22 @@ export class ChromedashGuideStagePage extends LitElement {
|
|||
`;
|
||||
}
|
||||
|
||||
renderOneField(formattedFeature, field) {
|
||||
const featureJSONKey = ALL_FIELDS[field].name || field;
|
||||
return html`
|
||||
<chromedash-form-field
|
||||
name=${field}
|
||||
value=${formattedFeature[featureJSONKey]}>
|
||||
</chromedash-form-field>
|
||||
`;
|
||||
}
|
||||
|
||||
renderFeatureFormSection(formattedFeature) {
|
||||
const alreadyOnThisStage = this.stageId === this.feature.intent_stage_int;
|
||||
return html`
|
||||
<section class="stage_form">
|
||||
${this.featureFormFields.map((field) => html`
|
||||
<chromedash-form-field
|
||||
name=${field}
|
||||
value=${formattedFeature[field]}>
|
||||
</chromedash-form-field>
|
||||
`)}
|
||||
${this.featureFormFields.map((field) => this.renderOneField(
|
||||
formattedFeature, field))}
|
||||
<chromedash-form-field
|
||||
name="set_stage"
|
||||
value=${alreadyOnThisStage}
|
||||
|
|
|
@ -311,7 +311,7 @@ const PAS_PREPARETOSHIP = [
|
|||
'launch_bug_url', 'intent_to_ship_url', 'comments',
|
||||
];
|
||||
|
||||
const DEPRECATION_IMPLEMENT = ['motivation', 'spec_link', 'comments'];
|
||||
const DEPRECATION_IMPLEMENT = ['deprecation_motivation', 'spec_link', 'comments'];
|
||||
|
||||
// Note: Even though this is similar to another form, it is likely to change.
|
||||
// const DEPRECATION_PREPARETOSHIP = [
|
||||
|
|
Загрузка…
Ссылка в новой задаче