Jump to content

Orders deted that re-invoicing


netdg

Recommended Posts

Hello everyone'm experiencing a problem that occurs with every new job, when I installed WHMCS I ran the test as a customer to control the entire process, from order sending the invoice. After completing canceled orders, and then all the historical, the objects are deleted prior to re-invoice the first customer who places an order. I did a check in the database and table tblinvoiceitems contains many of these objects that do not correspond to any order, as I avoid this problem? Thanks for any replies.

Link to comment
Share on other sites

You might need to be a little more specific ...

 

Are you concerned that tblinvoiceitems contains invoice "lines" for items where there is no invoice (due to you _deleting_ it) ?

 

Fix depends on why you *deleted* invocies - if these were *testing* invoices and you wanted them removed form the DB - then in future first delete each line-item from the invoice, before deleting the invoices.

 

To "tidyup" you just do (a backup first)

delete from tblinvoiceitems where invoiceid not in (select id from tblinvoices)

Link to comment
Share on other sites

I reported this bug a while ago and they simply deleted my post. If you delete an invoice from the admin area, it deletes the invoice, but not the invoice items in the tables. This then causes all sorts of issues with clients getting overdue notices, suspended accounts etc. I have not had time to check if this has been fixed in v5 or not.

Link to comment
Share on other sites

I reported this bug a while ago and they simply deleted my post. If you delete an invoice from the admin area, it deletes the invoice, but not the invoice items in the tables. This then causes all sorts of issues with clients getting overdue notices, suspended accounts etc. I have not had time to check if this has been fixed in v5 or not.

Deleting an invoice does not lead to overdue notices (as there's no invoice to remind them about) or suspended accounts (thats *date* based from the hosting product)

 

The reason it leaves the "items" behind is to stop it re-attempting to invoice, and causes no harm to the correct operation of the system at all.

 

What _exactly_ are you trying to achieve by deleting the invoice ?

Link to comment
Share on other sites

The bug has not been eliminated, or because I installed version 5.2 and the problem still occurs. For myself, I had initially set the system so that the receipt of the invoice is sent to the customer, but for this problem I had to set the invoice only after the payment.

Link to comment
Share on other sites

Deleting an invoice does not lead to overdue notices (as there's no invoice to remind them about) or suspended accounts (thats *date* based from the hosting product)

 

The reason it leaves the "items" behind is to stop it re-attempting to invoice, and causes no harm to the correct operation of the system at all.

 

What _exactly_ are you trying to achieve by deleting the invoice ?

 

Well we have had client accounts suspended and overdue notices sent out for invoices that do not exist any more, but the invoice items do cause they were left behind after invoices had been deleted. After deleting the items, the suspensions and overdue notices stop. The idea of leaving invoice items behind is not in the best interest of a normalized db design and I really have to question why it is designed in that way.

Link to comment
Share on other sites

Well we have had client accounts suspended

 

Account suspension isn't related to invoices (at all) it's related to the dates on the tblhosting record

- if the account was suspended (irrespective of you removing) the invoice there are 2 possibilities:

1. you didnt change the dates

2. you have another copy of whmcs running

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated