From 61070c9c6b665fdea79b3ccdfeafc3a6b50d262e Mon Sep 17 00:00:00 2001 From: Avi Ziv Date: Wed, 26 Jul 2017 17:37:57 +0300 Subject: [SDC] Full OnBoard health-check and NFoD support Change-Id: I606f8a52c7e6d2bd5558f824957d890e552c5423 Signed-off-by: Avi Ziv --- .../licenseAgreement/LicenseAgreementConstants.js | 2 +- .../licenseModel/licenseAgreement/LicenseAgreementEditor.js | 2 +- .../licenseAgreement/LicenseAgreementEditorReducer.js | 4 ++-- .../licenseAgreement/LicenseAgreementEditorView.jsx | 13 ++++++------- .../licenseAgreement/LicenseAgreementListEditorView.jsx | 2 +- 5 files changed, 11 insertions(+), 12 deletions(-) (limited to 'openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement') diff --git a/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementConstants.js b/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementConstants.js index 998d5f0e8d..40bef2c181 100644 --- a/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementConstants.js +++ b/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementConstants.js @@ -15,7 +15,7 @@ */ import keyMirror from 'nfvo-utils/KeyMirror.js'; import i18n from 'nfvo-utils/i18n/i18n.js'; -import InputOptions, {other as optionInputOther} from 'nfvo-components/input/inputOptions/InputOptions.jsx'; +import InputOptions, {other as optionInputOther} from 'nfvo-components/input/validation/InputOptions.jsx'; export const actionTypes = keyMirror({ LICENSE_AGREEMENT_LIST_LOADED: null, diff --git a/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementEditor.js b/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementEditor.js index aada8ddca1..7d70da6ea5 100644 --- a/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementEditor.js +++ b/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementEditor.js @@ -32,7 +32,7 @@ export const mapStateToProps = ({licenseModel: {licenseAgreement, featureGroup}} } for (let i = 0; i < list.length; i++) { - LANames[list[i].name] = list[i].id; + LANames[list[i].name.toLowerCase()] = list[i].id; } const {featureGroupsList = []} = featureGroup; diff --git a/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementEditorReducer.js b/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementEditorReducer.js index e02935c579..5be140550a 100644 --- a/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementEditorReducer.js +++ b/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementEditorReducer.js @@ -26,7 +26,7 @@ export default (state = {}, action) => { 'description' : { isValid: true, errorText: '', - validations: [{type: 'required', data: true}, {type: 'maxLength', data: 1000}], + validations: [{type: 'maxLength', data: 1000}], tabId: LicenseAgreementEnums.SELECTED_LICENSE_AGREEMENT_TAB.GENERAL }, 'requirementsAndConstrains' : { @@ -38,7 +38,7 @@ export default (state = {}, action) => { 'licenseTerm' : { isValid: true, errorText: '', - validations: [], + validations: [{type: 'required', data: true}], tabId: LicenseAgreementEnums.SELECTED_LICENSE_AGREEMENT_TAB.GENERAL }, 'name' : { diff --git a/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementEditorView.jsx b/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementEditorView.jsx index 42a33fd509..a15e5daa4e 100644 --- a/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementEditorView.jsx +++ b/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementEditorView.jsx @@ -19,7 +19,7 @@ import GridSection from 'nfvo-components/grid/GridSection.jsx'; import GridItem from 'nfvo-components/grid/GridItem.jsx'; import {TabsForm as Form} from 'nfvo-components/input/validation/Form.jsx'; import Tabs from 'nfvo-components/input/validation/Tabs.jsx'; -import Tab from 'react-bootstrap/lib/Tab.js'; +import Tab from 'sdc-ui/lib/react/Tab.js'; import Input from 'nfvo-components/input/validation/Input.jsx'; import DualListboxView from 'nfvo-components/input/dualListbox/DualListboxView.jsx'; import i18n from 'nfvo-utils/i18n/i18n.js'; @@ -96,7 +96,6 @@ const GeneralTabContent = ({data, genericFieldInfo, onDataChanged, validateName, overlayPos='bottom' data-test-id='create-la-description' name='license-agreement-description' - isRequired={true} type='textarea'/> @@ -145,10 +144,10 @@ class LicenseAgreementEditorView extends React.Component { isValid={this.props.isFormValid} formReady={this.props.formReady} onValidateForm={() => this.props.onValidateForm(LA_EDITOR_FORM) } - className='license-agreement-form'> - + className='license-model-form license-agreement-form'> +
@@ -157,7 +156,7 @@ class LicenseAgreementEditorView extends React.Component {
@@ -168,7 +167,7 @@ class LicenseAgreementEditorView extends React.Component { selectedValuesList={data.featureGroupsIds} availableList={featureGroupsList} onChange={ selectedValuesList => onDataChanged( { featureGroupsIds: selectedValuesList }, LA_EDITOR_FORM )}/> : -

{i18n('There is no available feature groups')}

} +

{i18n('There are no available feature groups')}

}
diff --git a/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementListEditorView.jsx b/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementListEditorView.jsx index 192d2ded99..6247723d72 100644 --- a/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementListEditorView.jsx +++ b/openecomp-ui/src/sdc-app/onboarding/licenseModel/licenseAgreement/LicenseAgreementListEditorView.jsx @@ -59,7 +59,7 @@ class LicenseAgreementListEditorView extends React.Component { isReadOnlyMode={isReadOnlyMode}> {this.filterList().map(licenseAgreement => this.renderLicenseAgreementListItem(licenseAgreement, isReadOnlyMode, version))} - + {`${isModalInEditMode ? i18n('Edit License Agreement') : i18n('Create New License Agreement')}`} -- cgit 1.2.3-korg