uppsala-makerspace / umsme

Medlemsadministrationssystem
GNU General Public License v3.0
0 stars 0 forks source link

Automatically detect the meaning of a payment. #27

Open VauteerU opened 3 weeks ago

VauteerU commented 3 weeks ago

Currently a payment of 300 kr can have two meanings: a quarter payment for labb membership which requires existing ordinary membership, or ordinary family membership. umsme always interprets it as family membership payment which is wrong most of the times. It would be good if umsme can detect the meaning automatically by checking if an ordinary membership already exists. In that case the 300 kr payment would be a quarter of labb membership. However, the logical condition might be a bit more complicated to be reliable.

blikstad commented 6 days ago

I think there may be a bug in https://github.com/uppsala-makerspace/umsme/blob/a1f69cc61d461f649782a32a9bf1c9e8439b4e77/lib/rules.js#L16

should probably be return true;