code4romania / monitorizare-vot-ong

NGO dashboard for viewing answers submitted by certified observers
https://votemonitor.org
Mozilla Public License 2.0
16 stars 44 forks source link

[Counties] Add reordering options in counties list #221

Open aniri opened 4 years ago

aniri commented 4 years ago

Depends on https://github.com/code4romania/monitorizare-vot-ong/issues/215

Add the option for setting a county as first in the list.

Add the possibility of reordering the counties by drag and dropping the items from the counties table.

Please suggest backend endpoints if needed.

UI available here: https://www.figma.com/file/61NHR7fwmV1Dsv4Pb6F8T7/code4ro_mv_user-management_2018.04.21-(Copy)?node-id=754%3A0

Botosio commented 3 years ago

Assign to me and I can take a look

Botosio commented 3 years ago

Can you add hacktoberfest to the label also?

Botosio commented 3 years ago

@aniri do you want every time someone drags and drops to send an update to the backend? Do we need a save button?

I'm guessing every time they drag and drop we will save it.

Botosio commented 3 years ago

@aniri what happens if you filter the list and they change the order?

Right now I disabled the drag and drop if the filter is on.

If you filter, the index doesn't match the original order. However, the move to first when the filter is on should be able to work.

Botosio commented 3 years ago

@aniri do you have this icon? image

aniri commented 3 years ago

hey @Botosio

I'm guessing every time they drag and drop we will save it. Yep, sounds good!

Also good idea with disabling the drag and drop when the filter is on!

Here's the icon :D double up

Thank you!

Botosio commented 3 years ago

Should there be a post without the ID for new Counties?

image

aniri commented 3 years ago

yes, it should be a post without id for adding a county and a put with id for editing one.

I'll add a backend issue to adjust these ;) thanks!

Botosio commented 3 years ago

@aniri sounds good. I made the global change in this next pr to change the word "Country" to "County".... I might have been the culprit in that.

Botosio commented 3 years ago

@aniri we need a delete also, for county

aniri commented 3 years ago

@Botosio thanks for the suggestion! I added a backend issue for all the mentioned changes :D

aniri commented 2 years ago

depends on https://github.com/code4romania/monitorizare-vot/issues/388