hopfenspace / MateBot

Micro service providing an API for MateBot clients

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

History CSV Export is unclear / misses some data

M4GNV5 opened this issue · comments

There is no information which entry is negative/positive. I.e. in the picture above the pay should have a different sign than the /drinks .

Replacing user ids by actual user names, or at least the exports user id by me would also help understanding the log.

commented

We first designed the CSV export to be a kind of backup that could be restored. However, I see the point. It's almost impossible for the user to tell who those user IDs refer. Which format do you prefer? I would assume the following to be a good tradeoff:

id sender receiver amount cumulative reason
1 Hopfenspace me 11176 +11176 data migration
21 me Hopfenspace 100 -100 consume: drink

This includes two things:

  1. The user IDs will be replaced by the user's name (not the username, though). I will see if I use me or the user's name in this special case.
  2. I will add a new row for the cumulative amount, so that you can use sum(<row>) to get your current balance (e.g. it includes the sign for positive/negative). It will always be abs(cumulative)=amount.

Any further suggestions?

cant we leave out the amount then?
Maybe we should discuss wether the sender/receiver fields should contain names of other users except Hopfenspace and me.

commented

What do you want in the sender/receiver fields then? The user's names except for the community user and yourself? What's the advantage here?

commented

After using some testing data and implementing the two points, the new CSV output would look like this one here (sample data from my perspective):

image

As you can see, I didn't replace Crsi with me which looks better in my opinion.

Note that I also changed the data format in the registered field. Previously, the column contained UNIX timestamps. But as they are hard to read for humans as well, I replaced them with their ISO-formatted representation.

Do you have any other recommendations before I close the issue?