Custom Invoice number with pdf plugin

  • Posts: 79
  • Thank you received: 2
10 years 2 weeks ago #179041

-- HikaShop version -- : 2.3.4
-- Joomla version -- : 2.5.18

Hi,
I have a problem with the pdf plugin which attaches the invoice in pdf to the order email.
In the configuration i setup a custom invoice and order number as follows:

order number: W0{date format="my"}-{id size="5"}
invoice number: WI0{date format="my"}-{order_id size="5"}

Now in the emails it will show the right format. Also on the website under orders it will show the right format.
on front end if customer wants to print the invoice it will show like it shows on the attachement.
Also the pdf attachement will show the same thing.
Its like it processes the first tag, but skips the second one.




Any help would be appreciated.
Thanks,
Roger

ps. i did a quick test with invoice number: WI0{date format="my"}-{order_id} but then it will not show the 5 digit number just the 2 digit number.

Attachments:
Last edit: 10 years 2 weeks ago by rkuiper.

Please Log in or Create an account to join the conversation.

  • Posts: 26159
  • Thank you received: 4028
  • MODERATOR
10 years 2 weeks ago #179084

Hi,

I check the code of the "attach invoice" plugin and I don't see any code which generate the invoice number ; it just read it from the database.
So I don't understand how you can have a right invoice number in the emails and have a wrong one in the invoice pdf.
When did you download the PDF invoice plugin ?

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 79
  • Thank you received: 2
10 years 2 weeks ago #179104

Hi Jerome,
I got the plugin on october 21st, 2014.
I am not for sure why its not showing it with the 5 digits in the PDF.
In Hikashop Configuration i setup the order and invoice code like i showed below.
When i opened the PDF it showed it like it shows in the attach picture in previous post.
I did how ever do a test where in the configuration i put WI0{date format="my"}-{order_id} instead of {order_id size="5"} for the invoice code. This will generate the invoice PDF correctly but will only show the invoice number like 24 instead of 00024.

Roger

Please Log in or Create an account to join the conversation.

  • Posts: 82906
  • Thank you received: 13378
  • MODERATOR
10 years 2 weeks ago #179169

Hi,

the size parameter for the order_id field is not yet supported but will be in next version.
In the mean time you need to modify the code of HikaShop to be able to do that:
www.hikashop.com/forum/orders-management...e-number-format.html

Please Log in or Create an account to join the conversation.

  • Posts: 79
  • Thank you received: 2
10 years 2 weeks ago #179322

Hi Nicolas,

That worked perfectly.
thank you for the quick response :)

Please Log in or Create an account to join the conversation.

Time to create page: 0.073 seconds
Powered by Kunena Forum