Skip to content

feat: Add tracks and rooms filters on sessions page #4879

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

Merged
merged 10 commits into from
Aug 27, 2020
Merged

feat: Add tracks and rooms filters on sessions page #4879

merged 10 commits into from
Aug 27, 2020

Conversation

maze-runnar
Copy link
Contributor

@maze-runnar maze-runnar commented Aug 26, 2020

Fixes #4852

image

Checklist

  • I have read the Contribution & Best practices Guide.
  • My branch is up-to-date with the Upstream development branch.
  • The acceptance, integration, unit tests and linter pass locally with my changes
  • I have added tests that prove my fix is effective or that my feature works
  • I have added necessary documentation (if appropriate)

@vercel
Copy link

vercel bot commented Aug 26, 2020

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/eventyay/open-event-frontend/oish4hinp
✅ Preview: https://open-event-frontend-git-fork-maze-runnar-patch-3.eventyay.vercel.app

@maze-runnar
Copy link
Contributor Author

maze-runnar commented Aug 26, 2020

@iamareebjamal this code in routes/sessions.js is not working for filtering -

if(params.track) {
      filterOptions.push({
            name : 'track.name',
            op : 'eq',
            val : params.track
      })
    }

@maze-runnar
Copy link
Contributor Author

Screenshot from 2020-08-26 09-21-39

@codecov
Copy link

codecov bot commented Aug 26, 2020

Codecov Report

Merging #4879 into development will decrease coverage by 0.01%.
The diff coverage is 0.00%.

Impacted file tree graph

@@               Coverage Diff               @@
##           development    #4879      +/-   ##
===============================================
- Coverage        23.19%   23.17%   -0.02%     
===============================================
  Files              481      481              
  Lines             5092     5096       +4     
  Branches            18       18              
===============================================
  Hits              1181     1181              
- Misses            3907     3911       +4     
  Partials             4        4              
Impacted Files Coverage Δ
app/routes/public/sessions.js 0.00% <0.00%> (ø)
app/components/forms/wizard/basic-details-step.js 24.39% <0.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update eb00a40...83ab8e9. Read the comment docs.

@iamareebjamal
Copy link
Member

Checking

@iamareebjamal
Copy link
Member

Filter for track should look like this:

[{"name":"track", "op":"has","val": {"name": "name", "op":"eq", "val":"Business & Sustainability"}}]

@iamareebjamal
Copy link
Member

So,

if (params.track) {
  filterOptions.push({
    name : 'track',
    op : 'has',
    val : {
      name: 'name',
      op: 'eq',
      val: params.track
    }
  })
}

@vercel vercel bot temporarily deployed to Preview August 26, 2020 05:45 Inactive
@maze-runnar maze-runnar marked this pull request as ready for review August 26, 2020 05:46
@maze-runnar
Copy link
Contributor Author

ezgif com-optimize

@mariobehling
Copy link
Member

Please also use the colors in the sidebar for the tracks, if possible.

@mariobehling
Copy link
Member

mariobehling commented Aug 26, 2020

I see whenever we change a filter or date the page goes up to the top of the page. How can we go to the top of the event page heading instead, e.g. here the heading "Sessions"?

@iamareebjamal
Copy link
Member

@maze-runnar Please make the UI as close to the generator UI, with colors for tracks. Also, the chosen track/room should be highlighted and a minus sign should be shown beside Tracks and Rooms heading if any filter is selected so that the filter can be removed. Like clicking on All removes the date filter

@iamareebjamal
Copy link
Member

@mariobehling A page reload is done when a filter is applied. To control the scroll of the page, we'll have to reimplement a lot of things in the route, so I'll create a separate issue to handle this in future

@maze-runnar
Copy link
Contributor Author

maze-runnar commented Aug 26, 2020

@iamareebjamal is it ok?
Screenshot from 2020-08-26 14-04-27

@vercel vercel bot temporarily deployed to Preview August 26, 2020 08:46 Inactive
@iamareebjamal
Copy link
Member

Color the circle, not the text. And the minus sign should be single (not against every track) and on the right of the text Tracks and Rooms

@maze-runnar
Copy link
Contributor Author

@iamareebjamal please review -
Screenshot from 2020-08-26 18-52-00

@mariobehling
Copy link
Member

  • Do we need the minus sign? What for? I think no need.
  • Please reduce size of Tracks and Rooms heading. On the website generator it is heading 4.
  • Please move the side bar filters a) below the event links and b) above the twitter box.

@maze-runnar
Copy link
Contributor Author

@iamareebjamal please take a look at requirements by @mariobehling. And please tell me final changes I have to make

@mariobehling
Copy link
Member

mariobehling commented Aug 26, 2020

@maze-runnar I think we are all aligned in understanding that we want to make it as similar as possible to the website generator. The question is just how far can we get in this iteration. Would be great, if you make the last changes mentioned by both of us and then we can also try and see how it works on the live site.

@maze-runnar
Copy link
Contributor Author

maze-runnar commented Aug 26, 2020

  • Do we need the minus sign? What for? I think no need.

To clear the room filters

  • Please reduce size of Tracks and Rooms heading. On the website generator it is heading 4.
  • Please move the side bar filters a) below the event links and b) above the twitter box.

@mariobehling
Copy link
Member

Please change filter text font from blue to standard dark color. I think it is black or dark gray.

@iamareebjamal iamareebjamal changed the title Adding tracks and rooms and make them into filters feat: Add tracks and rooms filters on sessions page Aug 26, 2020
@auto-label auto-label bot added the feature label Aug 26, 2020
@iamareebjamal
Copy link
Member

I'm polishing it @maze-runnar, please take up the grouping issue

@iamareebjamal
Copy link
Member

@mariobehling I tried a lot to implement clear filters without the minus icon but it doesn't work for some reason. Going for this for now, will revisit another time

@iamareebjamal iamareebjamal merged commit 569b948 into fossasia:development Aug 27, 2020
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.

Scheduler/Sessions/Tracks Page: Add Overview of tracks and rooms and make them into filters
3 participants