ewngs / szamlazz.js

Node.js client for Szamlazz.hu
MIT License
38 stars 34 forks source link

Feature Request: Add Cash On Delivery (COD) Payment Method #63

Closed dev-el-op closed 3 months ago

dev-el-op commented 8 months ago

Hello,

I am currently utilizing your code in my project. I am writing to suggest a potential enhancement that could broaden the utility of your billing system. In my use case, and possibly for other users as well, there's a need for a Cash On Delivery (COD) payment option. This feature would be incredibly beneficial for businesses that deal with direct customer deliveries where online transactions might not always be feasible.

ert78gb commented 7 months ago

PR is more than welcome. Please don't forget the test :)

ert78gb commented 3 months ago

Based on the szamlazz.hu documentation the PaymentMethod is an extendable field.

When you create an new invoice just create a new PaymentMethod like

const invoice = new Invoice({
  ...
  paymentMethod: new PaymentMethod('my method', 'comment of my method'),
  ...
})
mondalaci commented 3 months ago

Seems like the required feature is already available, so I'm closing this issue. Feel free to follow up, nevertheless.