Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: improve copy/past text [DHIS2-15012] #63

Merged
merged 2 commits into from
Aug 28, 2023

Conversation

tomzemp
Copy link
Member

@tomzemp tomzemp commented Mar 28, 2023

See DHIS2-15012 for information about this ticket.

Changes the clipboard text from a simple CSV output

Report,Imported,Updated,Ignored
Okay,0,0,1
Problem,0,0,1

to more detailed text output (which includes conflicts where relevant):

Exchange: EXTERNAL CONFLICTS
Target URL: https://play.dhis2.org/2.38.2.1
Run date: 2023-03-21T09:48.000


SUMMARY

Imported: 0, Updated: 0, Ignored: 2


DETAILS

Report: Okay
Imported: 0, Updated: 0, Ignored: 1
Conflicts:
fbfJHSPpUQD: Data element not found or not accessible: `fbfJHSPpUQD`

Report: Problem
Imported: 0, Updated: 0, Ignored: 1
Conflicts:
cYeuwXTCPkU: Data element not found or not accessible: `cYeuwXTCPkU`

@tomzemp tomzemp requested review from a team as code owners March 28, 2023 13:30
@@ -21,15 +21,15 @@ import styles from './success-content.module.css'
const importTypeConfig = {
imported: {
style: 'success',
text: i18n.t('Imported'),
text: i18n.t('imported'),
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the change here is not related to the main purpose of the ticket, but I noticed incorrect translations when adding/checking translations for this ticket. Lowercasing the translation did not appear to work here, so instead the translation strings in lower-case form are added directly

@@ -25,15 +26,15 @@ const submitReducer = (state, action) => {
error: null,
loading: false,
called: true,
dataSubmitted: true,
dataSubmitted: moment().format(),
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dataSubmitted is changed from a boolean (has data been submitted) to a string (when the data was submitted, for use in the clipboard text)

@dhis2-bot
Copy link
Contributor

dhis2-bot commented Mar 28, 2023

🚀 Deployed on https://pr-63--dhis2-data-exchange.netlify.app

@dhis2-bot dhis2-bot temporarily deployed to netlify March 28, 2023 13:35 Inactive
Copy link

@kabaros kabaros left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Copy link

@geethaalwan geethaalwan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested successfully on 2.41 version

@dhis2-bot dhis2-bot temporarily deployed to netlify August 28, 2023 12:26 Inactive
@tomzemp tomzemp merged commit 00469ca into master Aug 28, 2023
11 checks passed
dhis2-bot added a commit that referenced this pull request Aug 28, 2023
# [100.1.0](v100.0.6...v100.1.0) (2023-08-28)

### Features

* improve copy/past text [DHIS2-15012] ([#63](#63)) ([00469ca](00469ca))
@dhis2-bot
Copy link
Contributor

🎉 This PR is included in version 100.1.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants