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

Add support for swimlanes (#162) #164

Merged
merged 2 commits into from
Dec 28, 2023

Conversation

psybers
Copy link
Contributor

@psybers psybers commented Dec 24, 2023

Description

Adds support for swimlanes. This adds two new models: SwimLane and SwimLanes. It updates the API client to support client.swimlanes.list() and adds a project.swimlanes attribute. You can add new swimlanes via project.add_swimlane('name').

References

Fixes #162

Checklist

  • I have read the contribution guide
  • Code lint checked via inv lint
  • changes file included (see docs)
  • Usage documentation added in case of new features
  • Tests added

Copy link

codecov bot commented Dec 25, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (e175d86) 96.51% compared to head (ddb862f) 96.57%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #164      +/-   ##
==========================================
+ Coverage   96.51%   96.57%   +0.05%     
==========================================
  Files           8        8              
  Lines         918      933      +15     
  Branches       69       69              
==========================================
+ Hits          886      901      +15     
  Misses         19       19              
  Partials       13       13              
Flag Coverage Δ
unittests 96.57% <100.00%> (+0.05%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@coveralls
Copy link

coveralls commented Dec 25, 2023

Coverage Status

coverage: 97.964% (+0.03%) from 97.93%
when pulling ddb862f on psybers:feature/162-add-swimlanes
into e175d86 on nephila:master.

@yakky yakky changed the title feature/162 - Add support for swimlanes (#162) Add support for swimlanes (#162) Dec 28, 2023
@yakky
Copy link
Member

yakky commented Dec 28, 2023

awesome @psybers thanks a lot

@yakky yakky merged commit 09bd026 into nephila:master Dec 28, 2023
18 checks passed
@psybers
Copy link
Contributor Author

psybers commented Dec 28, 2023

Wait, I think I forgot one thing: setting the default swimlane on a project.

@protoroto
Copy link
Member

@psybers I'm not very familiar with swimlanes, so I don't really understand the problems of not setting the default swimlane on a project. Will you open another pr to address this, or should we release a new version without it?

@psybers
Copy link
Contributor Author

psybers commented Dec 29, 2023

I think it is a super small change. There just needs to be one method in Project to set the default swimlane. The API calls /projects/# with a PATCH and sets a single value, default_swimlane. This was the hack I put in to get it working on my side (without this PR):

def set_default_swimlane(self, id, **attrs):
    attrs.update({"default_swimlane": id})
    response = self.requester.patch("/projects/" + str(self.id), payload=attrs)
    return response.json()

I can get another PR in later today.

@psybers
Copy link
Contributor Author

psybers commented Dec 29, 2023

I added PR #167 (referencing issue #166) to fix this issue.

@protoroto Note that it is not a huge problem, if you release without this additional PR they can still read/write/update swimlanes, they just can't set the default. I'm not sure what Taiga does with no default set, but I suspect the UI would just default to the 'first' (based on order) when adding a new user story.

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

Successfully merging this pull request may close these issues.

Add support for swimlanes
4 participants