Read-Only when creating an invoice

If I input a product into an invoice with a price of 0.00 and save it as a draft, the invoice goes into “Read-Only” mode and I can’t edit it, or delete it when going back to it. I have version 1.2.0 and I set $config[‘enable_invoice_deletion’] = TRUE in the config.php.

Oh ok i’ll take a look.

BTW: the enable_invoice_deletion option only handles the deletion of invoices, not the read-only mode.

Oh and If I delete all the items in an invoice it gets thrown into Read-Only mode as well. I don’t know if that’s related.

Yes because the balance is zero then… Damn.

I confirm also.

So if I comment out the two lines (87 and 150) $this->db->set(‘is_read_only’, 1)’; in mdl_invoice_amouts.php would that break anything? It kind of fixes the problem for me. and it doesn’t look like anything else is affected by the change.

You can do that.

I have commented out the following but can’t still delete the read only invoice. You managed to delete it?
Btw. please allow deletion of ReadOnly invoices, they are hurting my eyes :laughing:

It’s probably because the invoice itself is still marked as read only in the table ip_invoices. I had to go in to MySQL and manually change the readonly column value from 1 to 0.

1 Like

It worked. Was to lazy to dig into the code and mysql :smiley: I reverted back those above commented out lines, gonna remember not to press OK before adding products in Invoice. Thanks :smiley:

After I enter payment of Invoice it is turned into a Read Only. And in that state I cannot create Reccuring Invoice. I think this should be reverted to old behaviour :smiley:

No this will not be reverted as exactly this behaviour is not law-confirm in many countries. Example: here in Germany it can be considered tax fraud if you change an invoice after you sent it.

There will be an option to turn of the read-only thing in one of the following versions.
If you don’t like this behavior feel free to downgrade to v1.1.2

Ok. Btw. how do you handle the following scenario:
You send 20 invoices to clients, all have increment numbers ie, Inovice 1-2015, Invoice 2-2015 etc. with duedate of 10 days. 18 are payed, and two are not. Invoces numbered 5-2015, 14-2015 are not payed. So, you can just ignore those two numbering and your tax inspection will not make any trouble because at the end of the year you will be missing the following numbers? In our country invoces must follow one after another with no skipping in numbering. And at the end of the year report is sent to Financial tax institution and it is suspucios if the invoices do not have exact incrementing numbers. If there are some that are missing because they never got paid by the client, it is suspicious…

If you have these laws in your country that invoices have to follow a strict numbering thats okay but we’ll not revert any of the changes because of this.

No problem, just saying. But an option to turn of read only option would be ok. Also, in our country only the final receipt is what it matters, quotes, estimates proforma invoices do not hold any legal point. It doesn’t matter what you do in the software, the banking payments must have justify in electronic version of receipts(invoices) and that is it.

1 Like

@Kovah, this behaviour seems like a bug from reading this thread, is that correct? If so, is it safe to expect a fix in the next version?

Read only (in any state of the invoice) should be a user option. Limiting the program will only cause some upset users with it. It’s ok by default not let delete, or ask many confirmations, but in the end, the end user should be free to do whatever they want, as probably is something necessary for the correct invoicing.

It’s like the famous discussion about rm -rf /

Let’s pretend end users are smart enough to handle this feature! :smile:

Its already a user option. Read-only can be disabled.

As far as I see (v 1.2.1) the option is only to let choose wich state of the invoice should be read only, but if you mark already “paid” in the invoice, it’s not possible to go back. I am missing something?


The point “Disable read-only”