Changeset - 8dc6894ce7e8
[Not reviewed]
0 3 0
Brett Smith - 4 years ago 2020-06-08 20:38:42
brettcsmith@brettcsmith.org
accrual: Outgoing report uses first rt-id as primary ticket number.

This makes it consistent with the reporting and our general rule
that the first link is primary.
3 files changed with 8 insertions and 3 deletions:
0 comments (0 inline, 0 general)
conservancy_beancount/reports/accrual.py
Show inline comments
...
 
@@ -510,3 +510,8 @@ class OutgoingReport(BaseReport):
 
    def _primary_rt_id(self, posts: AccrualPostings) -> rtutil.TicketAttachmentIds:
 
        rt_ids = posts.all_meta_links('rt-id')
 
        rt_ids: Set[str] = set()
 
        for post in posts:
 
            try:
 
                rt_ids.add(post.meta.get_links('rt-id')[0])
 
            except (IndexError, TypeError):
 
                pass
 
        rt_ids_count = len(rt_ids)
setup.py
Show inline comments
...
 
@@ -7,3 +7,3 @@ setup(
 
    description="Plugin, library, and reports for reading Conservancy's books",
 
    version='1.1.3',
 
    version='1.1.4',
 
    author='Software Freedom Conservancy',
tests/books/accruals.beancount
Show inline comments
...
 
@@ -110,3 +110,3 @@
 
2010-06-18 * "EuroGov" "European legal fees"
 
  rt-id: "rt:520"
 
  rt-id: "rt:520 rt:525"
 
  invoice: "rt:520/5200"
0 comments (0 inline, 0 general)