Payment entry needs to be created for Journal entry

For managing internal expenses in my organization, I’ve created a separate account in the Chart of Accounts. I plan to record these expenses using a Journal Entry. After creating the Journal Entry, a Payment Entry needs to be made for the expense.

How can I seamlessly handle this workflow in ERPNext, ensuring both the Journal Entry and Payment Entry are properly recorded?

You can automate the linking process between Journal Entries and Payment Entries using scripts. For example, upon submitting a Journal Entry, you can automatically generate a corresponding Payment Entry if needed.

My question is …why??

That could transalte to duplication of entries

I use a credit card for internal expenses, and I record these expenses using a Journal Entry. However, I am unsure about the correct way to record the payment of the credit card bill.

Should I record the payment in a Payment Entry or Journal Entry?

I noticed that in the Payment Entry, the Account Paid To field only shows accounts with the filters: Account Type = Bank or Cash, and Is Group = No.

Since my credit card is not a bank or cash account, I’m not sure if I should be using Payment Entry or Journal Entry for this transaction.

Can you clarify which doctype I should use for recording the payment of a credit card bill?

Thanks in advance!