Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions doc/release/RELEASE-NOTES.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ This project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html
### What's new
* [OSDEV-2084](https://opensupplyhub.atlassian.net/browse/OSDEV-2084) - Implemented front-end logic to display the "Beta Self Service Upload" button on the Upload Multiple Locations page when the `enable_dromo_uploading` feature flag is returned as true from the backend.
* [OSDEV-2082](https://opensupplyhub.atlassian.net/browse/OSDEV-2082) - Replaced `Resources` with `Pricing` in the platform header globally. Moved the `Resources` content under the `How it works` category for better organization.
* [OSDEV-2125](https://opensupplyhub.atlassian.net/browse/OSDEV-2125) - Changed the copy on the Dromo Self Service button. Included lead-in copy above the Dromo Self Service button stating.

### Release instructions
* Ensure that the following commands are included in the `post_deployment` command:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,15 +46,15 @@ describe('SelfServiceDromoUploader component', () => {
it('renders the upload button', () => {
const { getByText } = render(<SelfServiceDromoUploader fileInput={fileInput} updateFileName={updateFileName} />);

expect(getByText('Beta Self Service Upload')).toBeInTheDocument();
expect(getByText('SMART UPLOAD (BETA)')).toBeInTheDocument();
});

it('opens the uploader when button is clicked', () => {
const { getByText, getByTestId } = render(
<SelfServiceDromoUploader fileInput={fileInput} updateFileName={updateFileName} />
);

fireEvent.click(getByText('Beta Self Service Upload'));
fireEvent.click(getByText('SMART UPLOAD (BETA)'));

expect(getByTestId('dromo-uploader')).toHaveAttribute('data-open', 'true');
});
Expand All @@ -64,7 +64,7 @@ describe('SelfServiceDromoUploader component', () => {
<SelfServiceDromoUploader fileInput={fileInput} updateFileName={updateFileName} />
);

fireEvent.click(getByText('Beta Self Service Upload'));
fireEvent.click(getByText('SMART UPLOAD (BETA)'));
fireEvent.click(getByTestId('dromo-cancel-button'));

expect(getByTestId('dromo-uploader')).toHaveAttribute('data-open', 'false');
Expand All @@ -75,7 +75,7 @@ describe('SelfServiceDromoUploader component', () => {
<SelfServiceDromoUploader fileInput={fileInput} updateFileName={updateFileName} />
);

fireEvent.click(getByText('Beta Self Service Upload'));
fireEvent.click(getByText('SMART UPLOAD (BETA)'));
fireEvent.click(getByTestId('dromo-results-button'));

expect(processDromoResults).toHaveBeenCalledWith(
Expand Down
11 changes: 11 additions & 0 deletions src/react/src/components/ContributeForm.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,17 @@ const ContributeForm = ({
<div className="control-panel__group">
{formInputs}
<div className="form__field">
<FeatureFlag flag={ENABLE_DROMO_UPLOADING}>
<p
style={{
fontSize: '16px',
}}
>
<b>New!</b> Try our <b>smart upload</b> assistant (beta)
that checks your file for formatting issues and helps
fix errors before submission
</p>
</FeatureFlag>
<div style={contributeFormStyles.uploaderButtonWrapper}>
<MaterialButton
onClick={selectFile}
Expand Down
2 changes: 1 addition & 1 deletion src/react/src/components/SelfServiceDromoUploader.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ const SelfServiceDromoUploader = ({ fileInput, updateFileName }) => {
style={uploaderButtonStyle}
disableRipple
>
Beta Self Service Upload
SMART UPLOAD (BETA)
</MaterialButton>

<DromoUploader
Expand Down
2 changes: 1 addition & 1 deletion src/react/src/util/constants.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ export const InfoPaths = {

// Other
resources: 'resources',
pricing: 'open-supply-hub-pricing',
pricing: 'pricing',

// Footer
mediaHub: 'media-hub',
Expand Down