IFRCGo / go-frontend

MIT License
21 stars 5 forks source link

[Display] Featured Operations card - display dash instead of zero #970

Closed nanometrenat closed 4 years ago

nanometrenat commented 4 years ago

Issue

Currently a zero is shown if there is no data for an item in the Featured Operations card on Go homepage - e.g. if there are no deployed ERUs or no Targeted Population then zeros are shown.

image

On the Operation page, cards are hidden if there is no data - but in the Featured Operations section of homepage all 4 elements are always shown.

Suggest replacing zero with a dash (if element is not being hidden).

Related feature

This also relates to the conversation around which figures are most important in epi/health emergencies.

Impact

This is a display issue only, but causes concern to mgmt.

nanometrenat commented 4 years ago

The double-dash (--) is shown for a very short moment while the page is loading! Then is replaced with a zero.

GergiH commented 4 years ago

@nanometrenat I could make the Deployments to be dashes instead of 0 if there are no data, but the Population seem to be a required field for Appeals anyway (so they have 0 as default). image

Can there be any instances where an Emergency doesn't have any Appeals attached to it? Because in that case we can say that there is no data thus use the dashes.

nanometrenat commented 4 years ago

Thank you

It is very common that an emergency does not have an appeal.

Re Targeted Population, it doesn't really make sense to show zero (even if it is a required field), so may need to put a special condition in to show dashes if zero. @munu I would appreciate your thoughts on whether this is a good idea from your point of view


From: Horvath Gergely notifications@github.com Sent: Friday, 28 February 2020, 14:40 To: IFRCGo/go-frontend Cc: Natalie GYLES; Mention Subject: Re: [IFRCGo/go-frontend] [Display] Featured Operations card - display dash instead of zero (#970)

@nanometrenathttps://github.com/nanometrenat I could make the Deployments to be dashes instead of 0 if there are no data, but the Population seem to be a required field for Appeals anyway (so they have 0 as default). [image]https://user-images.githubusercontent.com/30079559/75553052-f0549e80-5a37-11ea-9012-535e3d1c5022.png

Are there any instances where an Emergency doesn't have any Appeals attached to it? Because in that case we can say that there is no data thus use the dashes.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/IFRCGo/go-frontend/issues/970?email_source=notifications&email_token=AIARI2GR44XGTNKM65AMFJTRFEH3TA5CNFSM4KS5QI7KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOENIRPNY#issuecomment-592517047, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AIARI2DAVHEO45NAEIABJ6LRFEH3TANCNFSM4KS5QI7A.

nanometrenat commented 4 years ago

Hi,

Yes it would be better to have those dashes to reflect that the information is missing. If there is an operation then you have the targeted population. Especially for the example below. It would send a wrong message that we looking for 76,946 to assist 0 people. Something must have gone wrong to have 0 on that card.

Regards,

Mununuri Musori Information Management, Planning and Reporting Disaster & Crisis

Federation Intenationale des Societes de la Croix-Rouge et du Croissant Rouge Chemin des Crets, 17 | Petit-Saconnex 1209 Geneve | Suisse Tel. Tel. +41 22 730 4350 | Mob. +41 (0)79 2173339 Email mununuri.musori@ifrc.orgmailto:mununuri.musori@ifrc.org | Skype mununuri.musori

From: Natalie GYLES Natalie.GYLES@ifrc.org Sent: 28 February 2020 14:48 To: IFRCGo/go-frontend reply@reply.github.com; IFRCGo/go-frontend go-frontend@noreply.github.com Cc: Mention mention@noreply.github.com; Mununuri Musori Mununuri.Musori@ifrc.org Subject: Re: [IFRCGo/go-frontend] [Display] Featured Operations card - display dash instead of zero (#970)

Thank you

It is very common that an emergency does not have an appeal.

Re Targeted Population, it doesn't really make sense to show zero (even if it is a required field), so may need to put a special condition in to show dashes if zero. @munu I would appreciate your thoughts on whether this is a good idea from your point of view


From: Horvath Gergely notifications@github.com<mailto:notifications@github.com> Sent: Friday, 28 February 2020, 14:40 To: IFRCGo/go-frontend Cc: Natalie GYLES; Mention Subject: Re: [IFRCGo/go-frontend] [Display] Featured Operations card - display dash instead of zero (#970)

@nanometrenathttps://github.com/nanometrenat I could make the Deployments to be dashes instead of 0 if there are no data, but the Population seem to be a required field for Appeals anyway (so they have 0 as default). [image]https://user-images.githubusercontent.com/30079559/75553052-f0549e80-5a37-11ea-9012-535e3d1c5022.png

Are there any instances where an Emergency doesn't have any Appeals attached to it? Because in that case we can say that there is no data thus use the dashes.

- You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/IFRCGo/go-frontend/issues/970?email_source=notifications&email_token=AIARI2GR44XGTNKM65AMFJTRFEH3TA5CNFSM4KS5QI7KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOENIRPNY#issuecomment-592517047, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AIARI2DAVHEO45NAEIABJ6LRFEH3TANCNFSM4KS5QI7A.

GergiH commented 4 years ago

@nanometrenat @mmusori This is how it would look if there are 0 population/funding and no deployments (keep in mind these all are random test data, and the cards' height look off only because my browser window was small so it couldn't fit 'CHF' into one line with the number).

image

nanometrenat commented 4 years ago

Thanks @mmusori the current case where we've correctly made an appeal with an unspecified targetted population is COVID-19

nanometrenat commented 4 years ago

Hi @GregoryHorvath I have confirmed with @mmusori that for the Targeted Population we should put in an extra piece of logic to show -- when the figure is zero. I know that zero != null, however in this specific case we should treat it as though it is.

An operation would only be highlighted if it has an Appeal. The Appeal would normally have a non-zero figure in Targeted Population, but if it is a coordination appeal (like this) then it may be zero.

Thanks a lot