Skip to content

feat: add BudgetsGroups component#5924

Merged
leio10 merged 25 commits intofeat/complex-budgets-votingfrom
feat/budgets-groups-component
Apr 16, 2020
Merged

feat: add BudgetsGroups component#5924
leio10 merged 25 commits intofeat/complex-budgets-votingfrom
feat/budgets-groups-component

Conversation

@leio10
Copy link
Copy Markdown
Contributor

@leio10 leio10 commented Apr 3, 2020

🎩 What? Why?

Adds the BudgetsGroups component to allow grouping different Budgets components on a parent component.

To achieve this, this PR first modify the component model to allow having parent components. After this, it modifies the admin component and all the participatory spaces to make them hide the child components from components list (both in admin and front views). After this, the responsibility of showing the child components is delegated to the parent component.
Finally, this PR adds the new component to the Budgets module, using the namespace Decidim::Budgets::Groups to add all the related classes.

📌 Related Issues

📋 Subtasks

  • Add/modify seeds
  • Add tests

📷 Screenshots (optional)

  • Children budget components are shown inside the budgets group component (and not in the component list)
    imagen

  • Budget component admin page allows admin users to change its parent component (or to unset it)
    imagen

  • Budgets Group index page show links to the budgets components (this has to be improved with cards and highlighting budgets depending on the user scope)

Screenshot 2020-04-09 at 16 30 23

  • Budget components with a parent component don't appear on the component navigation bar and set the parent component as active
    Screenshot 2020-04-09 at 16 31 26
    imagen

@leio10 leio10 changed the title Feat/budgets groups component feat: add BudgetsGroups component Apr 3, 2020
@leio10 leio10 added project: PAM2020 Barcelona City Council contract status: WIP labels Apr 3, 2020
@leio10 leio10 mentioned this pull request Apr 3, 2020
3 tasks
@leio10 leio10 force-pushed the feat/budgets-groups-component branch from aeb3891 to 17d280b Compare April 4, 2020 16:57
@mrcasals mrcasals force-pushed the feat/budgets-groups-component branch from 68ff141 to c4e71da Compare April 6, 2020 06:53
@mrcasals
Copy link
Copy Markdown
Contributor

mrcasals commented Apr 7, 2020

@decidim/core I don't understand how Codecov calculates coverage. At commit 6f9f7ff I have these checks:

image

Checking the patch link, brings me to this page:

https://codecov.io/gh/decidim/decidim/compare/13508fa76d3e53aa9fb0b126e9c94adcfbcc985f...6f9f7ffcce4eb948c4954c796fc5643eacf35ffd

I visit the "Changes" tab:

https://codecov.io/gh/decidim/decidim/compare/13508fa76d3e53aa9fb0b126e9c94adcfbcc985f...6f9f7ffcce4eb948c4954c796fc5643eacf35ffd/changes

This page lists all the files that have changed coverage. The first file I get is one that has decreased coverage, but is not modified in our PR:

image

Other files appear as new, but they've been on the repo for a long time now:

image

Any idea what's going on and what should we do to get this PR green? Alternatively, can we ignore these checks?

@mrcasals mrcasals force-pushed the feat/budgets-groups-component branch 2 times, most recently from 613ba74 to 11e9647 Compare April 8, 2020 12:16
@mrcasals mrcasals self-assigned this Apr 8, 2020
@agustibr agustibr force-pushed the feat/complex-budgets-voting branch from 13508fa to 5004c1f Compare April 9, 2020 05:53
@agustibr agustibr force-pushed the feat/budgets-groups-component branch from e75dd0c to 0164355 Compare April 10, 2020 04:50
@leio10 leio10 force-pushed the feat/budgets-groups-component branch 6 times, most recently from 96f6ba9 to 17f58cb Compare April 15, 2020 17:06
@leio10 leio10 force-pushed the feat/budgets-groups-component branch from 17f58cb to c9cd7bc Compare April 16, 2020 10:18
@leio10 leio10 merged commit 6bc468e into feat/complex-budgets-voting Apr 16, 2020
@leio10 leio10 deleted the feat/budgets-groups-component branch April 16, 2020 11:12
leio10 added a commit that referenced this pull request Apr 16, 2020
* Add changelog entry

* feat: add parent/child relationship to components

* feat: add settings to define if a component can have parent or children

* feat(admin): add parent field to component form when allowed

* refactor(admin): enforce the use of participatory space context concern

* refactor(admin): unify the menu components list rendering

* feat(admin): hide child components from lists

* feat(front): hide child components from lists

* feat: add the budgets groups component to the budgets module

* feat: allow budget components to have a parent component

* feat(admin): allow budgets group admin to manage children components

* feat(front): show children components on budget group index page

* style: fix lint issues

* test: fix tests broken with refactor

* Fix CI config for consultations

* Fix CI config

A single asterisk only matches branch names *without* slashes.
Double asterisk will match any branch name including slashes.

* Fix liinter complaints

* Add missing method on consultations

* Fix conferences tests

* Add missing field on test double

* Don't make budgets groups engine load tasks

* Lint files

* Use correct consultations questions admin layout

* feat: budgets group view improvements

* Fix lint errors

Co-authored-by: Marc Riera Casals <mrc2407@gmail.com>
Co-authored-by: Agustí B.R <agusti@codegram.com>
leio10 added a commit that referenced this pull request Apr 16, 2020
* Add changelog entry

* feat: add parent/child relationship to components

* feat: add settings to define if a component can have parent or children

* feat(admin): add parent field to component form when allowed

* refactor(admin): enforce the use of participatory space context concern

* refactor(admin): unify the menu components list rendering

* feat(admin): hide child components from lists

* feat(front): hide child components from lists

* feat: add the budgets groups component to the budgets module

* feat: allow budget components to have a parent component

* feat(admin): allow budgets group admin to manage children components

* feat(front): show children components on budget group index page

* style: fix lint issues

* test: fix tests broken with refactor

* Fix CI config for consultations

* Fix CI config

A single asterisk only matches branch names *without* slashes.
Double asterisk will match any branch name including slashes.

* Fix liinter complaints

* Add missing method on consultations

* Fix conferences tests

* Add missing field on test double

* Don't make budgets groups engine load tasks

* Lint files

* Use correct consultations questions admin layout

* feat: budgets group view improvements

* Fix lint errors

Co-authored-by: Marc Riera Casals <mrc2407@gmail.com>
Co-authored-by: Agustí B.R <agusti@codegram.com>
leio10 added a commit that referenced this pull request Apr 21, 2020
* Add changelog entry

* feat: add parent/child relationship to components

* feat: add settings to define if a component can have parent or children

* feat(admin): add parent field to component form when allowed

* refactor(admin): enforce the use of participatory space context concern

* refactor(admin): unify the menu components list rendering

* feat(admin): hide child components from lists

* feat(front): hide child components from lists

* feat: add the budgets groups component to the budgets module

* feat: allow budget components to have a parent component

* feat(admin): allow budgets group admin to manage children components

* feat(front): show children components on budget group index page

* style: fix lint issues

* test: fix tests broken with refactor

* Fix CI config for consultations

* Fix CI config

A single asterisk only matches branch names *without* slashes.
Double asterisk will match any branch name including slashes.

* Fix liinter complaints

* Add missing method on consultations

* Fix conferences tests

* Add missing field on test double

* Don't make budgets groups engine load tasks

* Lint files

* Use correct consultations questions admin layout

* feat: budgets group view improvements

* Fix lint errors

Co-authored-by: Marc Riera Casals <mrc2407@gmail.com>
Co-authored-by: Agustí B.R <agusti@codegram.com>
leio10 added a commit that referenced this pull request Apr 24, 2020
* Add changelog entry

* feat: add parent/child relationship to components

* feat: add settings to define if a component can have parent or children

* feat(admin): add parent field to component form when allowed

* refactor(admin): enforce the use of participatory space context concern

* refactor(admin): unify the menu components list rendering

* feat(admin): hide child components from lists

* feat(front): hide child components from lists

* feat: add the budgets groups component to the budgets module

* feat: allow budget components to have a parent component

* feat(admin): allow budgets group admin to manage children components

* feat(front): show children components on budget group index page

* style: fix lint issues

* test: fix tests broken with refactor

* Fix CI config for consultations

* Fix CI config

A single asterisk only matches branch names *without* slashes.
Double asterisk will match any branch name including slashes.

* Fix liinter complaints

* Add missing method on consultations

* Fix conferences tests

* Add missing field on test double

* Don't make budgets groups engine load tasks

* Lint files

* Use correct consultations questions admin layout

* feat: budgets group view improvements

* Fix lint errors

Co-authored-by: Marc Riera Casals <mrc2407@gmail.com>
Co-authored-by: Agustí B.R <agusti@codegram.com>
leio10 added a commit that referenced this pull request May 7, 2020
* Add changelog entry

* feat: add parent/child relationship to components

* feat: add settings to define if a component can have parent or children

* feat(admin): add parent field to component form when allowed

* refactor(admin): enforce the use of participatory space context concern

* refactor(admin): unify the menu components list rendering

* feat(admin): hide child components from lists

* feat(front): hide child components from lists

* feat: add the budgets groups component to the budgets module

* feat: allow budget components to have a parent component

* feat(admin): allow budgets group admin to manage children components

* feat(front): show children components on budget group index page

* style: fix lint issues

* test: fix tests broken with refactor

* Fix CI config for consultations

* Fix CI config

A single asterisk only matches branch names *without* slashes.
Double asterisk will match any branch name including slashes.

* Fix liinter complaints

* Add missing method on consultations

* Fix conferences tests

* Add missing field on test double

* Don't make budgets groups engine load tasks

* Lint files

* Use correct consultations questions admin layout

* feat: budgets group view improvements

* Fix lint errors

Co-authored-by: Marc Riera Casals <mrc2407@gmail.com>
Co-authored-by: Agustí B.R <agusti@codegram.com>
leio10 added a commit that referenced this pull request May 8, 2020
* Add changelog entry

* feat: add parent/child relationship to components

* feat: add settings to define if a component can have parent or children

* feat(admin): add parent field to component form when allowed

* refactor(admin): enforce the use of participatory space context concern

* refactor(admin): unify the menu components list rendering

* feat(admin): hide child components from lists

* feat(front): hide child components from lists

* feat: add the budgets groups component to the budgets module

* feat: allow budget components to have a parent component

* feat(admin): allow budgets group admin to manage children components

* feat(front): show children components on budget group index page

* style: fix lint issues

* test: fix tests broken with refactor

* Fix CI config for consultations

* Fix CI config

A single asterisk only matches branch names *without* slashes.
Double asterisk will match any branch name including slashes.

* Fix liinter complaints

* Add missing method on consultations

* Fix conferences tests

* Add missing field on test double

* Don't make budgets groups engine load tasks

* Lint files

* Use correct consultations questions admin layout

* feat: budgets group view improvements

* Fix lint errors

Co-authored-by: Marc Riera Casals <mrc2407@gmail.com>
Co-authored-by: Agustí B.R <agusti@codegram.com>
leio10 added a commit that referenced this pull request May 14, 2020
* Add changelog entry

* feat: add parent/child relationship to components

* feat: add settings to define if a component can have parent or children

* feat(admin): add parent field to component form when allowed

* refactor(admin): enforce the use of participatory space context concern

* refactor(admin): unify the menu components list rendering

* feat(admin): hide child components from lists

* feat(front): hide child components from lists

* feat: add the budgets groups component to the budgets module

* feat: allow budget components to have a parent component

* feat(admin): allow budgets group admin to manage children components

* feat(front): show children components on budget group index page

* style: fix lint issues

* test: fix tests broken with refactor

* Fix CI config for consultations

* Fix CI config

A single asterisk only matches branch names *without* slashes.
Double asterisk will match any branch name including slashes.

* Fix liinter complaints

* Add missing method on consultations

* Fix conferences tests

* Add missing field on test double

* Don't make budgets groups engine load tasks

* Lint files

* Use correct consultations questions admin layout

* feat: budgets group view improvements

* Fix lint errors

Co-authored-by: Marc Riera Casals <mrc2407@gmail.com>
Co-authored-by: Agustí B.R <agusti@codegram.com>
leio10 added a commit that referenced this pull request May 14, 2020
* Add changelog entry

* feat: add parent/child relationship to components

* feat: add settings to define if a component can have parent or children

* feat(admin): add parent field to component form when allowed

* refactor(admin): enforce the use of participatory space context concern

* refactor(admin): unify the menu components list rendering

* feat(admin): hide child components from lists

* feat(front): hide child components from lists

* feat: add the budgets groups component to the budgets module

* feat: allow budget components to have a parent component

* feat(admin): allow budgets group admin to manage children components

* feat(front): show children components on budget group index page

* style: fix lint issues

* test: fix tests broken with refactor

* Fix CI config for consultations

* Fix CI config

A single asterisk only matches branch names *without* slashes.
Double asterisk will match any branch name including slashes.

* Fix liinter complaints

* Add missing method on consultations

* Fix conferences tests

* Add missing field on test double

* Don't make budgets groups engine load tasks

* Lint files

* Use correct consultations questions admin layout

* feat: budgets group view improvements

* Fix lint errors

Co-authored-by: Marc Riera Casals <mrc2407@gmail.com>
Co-authored-by: Agustí B.R <agusti@codegram.com>
leio10 added a commit that referenced this pull request May 23, 2020
* Add changelog entry

* feat: add parent/child relationship to components

* feat: add settings to define if a component can have parent or children

* feat(admin): add parent field to component form when allowed

* refactor(admin): enforce the use of participatory space context concern

* refactor(admin): unify the menu components list rendering

* feat(admin): hide child components from lists

* feat(front): hide child components from lists

* feat: add the budgets groups component to the budgets module

* feat: allow budget components to have a parent component

* feat(admin): allow budgets group admin to manage children components

* feat(front): show children components on budget group index page

* style: fix lint issues

* test: fix tests broken with refactor

* Fix CI config for consultations

* Fix CI config

A single asterisk only matches branch names *without* slashes.
Double asterisk will match any branch name including slashes.

* Fix liinter complaints

* Add missing method on consultations

* Fix conferences tests

* Add missing field on test double

* Don't make budgets groups engine load tasks

* Lint files

* Use correct consultations questions admin layout

* feat: budgets group view improvements

* Fix lint errors

Co-authored-by: Marc Riera Casals <mrc2407@gmail.com>
Co-authored-by: Agustí B.R <agusti@codegram.com>
leio10 added a commit that referenced this pull request May 25, 2020
* Add changelog entry

* feat: add parent/child relationship to components

* feat: add settings to define if a component can have parent or children

* feat(admin): add parent field to component form when allowed

* refactor(admin): enforce the use of participatory space context concern

* refactor(admin): unify the menu components list rendering

* feat(admin): hide child components from lists

* feat(front): hide child components from lists

* feat: add the budgets groups component to the budgets module

* feat: allow budget components to have a parent component

* feat(admin): allow budgets group admin to manage children components

* feat(front): show children components on budget group index page

* style: fix lint issues

* test: fix tests broken with refactor

* Fix CI config for consultations

* Fix CI config

A single asterisk only matches branch names *without* slashes.
Double asterisk will match any branch name including slashes.

* Fix liinter complaints

* Add missing method on consultations

* Fix conferences tests

* Add missing field on test double

* Don't make budgets groups engine load tasks

* Lint files

* Use correct consultations questions admin layout

* feat: budgets group view improvements

* Fix lint errors

Co-authored-by: Marc Riera Casals <mrc2407@gmail.com>
Co-authored-by: Agustí B.R <agusti@codegram.com>
leio10 added a commit that referenced this pull request May 25, 2020
* Add changelog entry

* feat: add parent/child relationship to components

* feat: add settings to define if a component can have parent or children

* feat(admin): add parent field to component form when allowed

* refactor(admin): enforce the use of participatory space context concern

* refactor(admin): unify the menu components list rendering

* feat(admin): hide child components from lists

* feat(front): hide child components from lists

* feat: add the budgets groups component to the budgets module

* feat: allow budget components to have a parent component

* feat(admin): allow budgets group admin to manage children components

* feat(front): show children components on budget group index page

* style: fix lint issues

* test: fix tests broken with refactor

* Fix CI config for consultations

* Fix CI config

A single asterisk only matches branch names *without* slashes.
Double asterisk will match any branch name including slashes.

* Fix liinter complaints

* Add missing method on consultations

* Fix conferences tests

* Add missing field on test double

* Don't make budgets groups engine load tasks

* Lint files

* Use correct consultations questions admin layout

* feat: budgets group view improvements

* Fix lint errors

Co-authored-by: Marc Riera Casals <mrc2407@gmail.com>
Co-authored-by: Agustí B.R <agusti@codegram.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

project: PAM2020 Barcelona City Council contract

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants