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

Fix ajax filtering for the map markers on proposals #39

Open
wants to merge 3 commits into
base: release/0.26-stable
Choose a base branch
from

Conversation

antopalidi
Copy link
Member

video-1.mov

@antopalidi antopalidi requested a review from microstudi October 19, 2022 07:57
@paarals
Copy link

paarals commented Oct 19, 2022

related to #39

Copy link

@microstudi microstudi left a comment

Choose a reason for hiding this comment

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

Thanks @antopalidi, this is great!

In order to be super-duper excellent we should add a test to this.

I think we can add a case in the file decidim-proposals/spec/systemindex_proposals_spec.rb to check that the markerData has the corresponding filtered content.

it would be something like

context "when there are filters" do
  it "has proposals in markerData" do
    visit_component
    expect(page.body).to have_content("here some content that should appear in the json")
  end

  it "has no proposals in markerData on filtering" do
    visit_component
    uncheck "Accepted"
    expect(page.body).to have_content("here some content that should appear in the json")
  end
end

Copy link

@microstudi microstudi left a comment

Choose a reason for hiding this comment

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

good!

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

Successfully merging this pull request may close these issues.

Update the map when changing filter options in proposals
3 participants