tusmanakhter / MigrantHub

MIT License
4 stars 3 forks source link

Categories UI #148

Closed iamlax closed 5 years ago

iamlax commented 5 years ago

Lots of merge conflicts in PR #143, because of renaming. So added the UI changes to a new branch off master.

Added a menu list similar to amazon/best buy to select the categories using the library 'rc-menu'. This should make it easier for a user to select a category. Also, added a button to hide and display the old category list on the main page, because there are too many categories and its taking too much space on the main page.

Demo Steps:

  1. Sign-in
  2. Hover over Service Page in Sidebar
  3. Hover over categories to view subcategories
  4. Select a category to be directed to all the services in that category
  5. Likewise on main select all categories to view all categories or the plus button to view and select other categories. Note: Also kept the old categories on the home page, but added a button to hide them. Since, the number of categories are very large. However, if the sidebar category format is preferred, then it can also be added to the main by replacing the ServiceCategoryMenu1 component with the ServiceCategoryMenu2 component in ServiceMain.

image

image

iamlax commented 5 years ago

@tusmanakhter

Can you show me the plus button crashing. I can't make it crash.

The data is not shown, because the script stores the category names differently than ServiceForm. i.e. ServiceForm stores 'Work Accidents' as 'WorkAccidents', but the script stores it as 'WORK ACCIDENTS'

miramarhaba commented 5 years ago

The UI for the services are there and are able to be used. Whenever I click the + button itself, the page crashes. But the links that appear when hovering the + button work. Also the buttons for the services in the side bar work but there is no data showing in the following page? My database is populated on my end using Alex's script, not sure if something changed or there's a problem on my end

I couldnt find any issues with clicking the plus button. Nothing happens until i actually select from one of the categories, which is expected.

iamlax commented 5 years ago

Feature works as intended. I also tested with my script just like Tusman. Services don't show because of the format of the category attribute in the database. We will need to manually change the Category column in the csv file that is used by the script that populates the database. Approving since feature works despite the fact.

I'll fix that before merging