How can I add the order number to an invoice ?

  • Posts: 88
  • Thank you received: 0
7 years 11 months ago #257284

-- HikaShop version -- : 3.6.4
-- HikaMarket version -- : 1.7.2

Hello,

I would like to add the related order number to a given invoice :



Thanks in advance for your help an advise,
Best regards
Stéphane

Attachments:

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
7 years 11 months ago #257285

Hi,

Knowing that you have access to the Order object (element), you have the order invoice number (order_invoice_number) but you have also access to the order number (order_number).
Afterwards, you'll need to write a small part of PHP to display the information where you want to put it.

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: 88
  • Thank you received: 0
7 years 11 months ago #257319

Thanks Jerome,

Could I suggest to add it as a standard ?
I cannot remember, here in France/Europe, getting an invoice where the order number is not added... (ie. Amazon)

I would need it just below the invoice number.
simply as the invoice number like :

Numéro de Commande : xxx-x--xx

My PHP skills are really limited could you please provide me the php I should enter below the invoice number ? like :

<br/>
	<?php echo JText::_('INVOICE') . ': ' . @$this->element->order_invoice_number; ?>
<br/>
        <?php  Your code.............?>
				</div>

Thanks in advance for your help and advise,
Best regards,
Stéphane

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
7 years 11 months ago #257345

Hi,

HikaMarket is using the same invoice template (and rules) than the HikaShop one.
If HikaShop do not display it ; I cannot make it as a standard in HikaMarket.

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: 88
  • Thank you received: 0
7 years 11 months ago #257389

Hi Jerome,

I do understand this point, maybe I posted this question in the wrong forum section...
but could you please provide the PHP code so that I could insert it, or maybe transfer this question to the relevant forum section ?

Thanks in advance for your help and advise,
Best regards
Stéphane

Last edit: 7 years 11 months ago by steph3838.

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
7 years 11 months ago #257391

Hi,

Please understand that customization is not part of our support.
I recommend you to just read few articles to learn the basics of PHP or find someone who will be able to help you.
What you want to do is just a display, an "echo" and I already gave you the indication of where the information where.
Providing you the code to paste won't help you at the end and is not the goal of our support.

Thank you for your understanding.

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: 88
  • Thank you received: 0
7 years 11 months ago #257409

Hi Jerome,

I agree totally with you, but just think about one thing :

  1. I've payed for your software
  2. We spend about a day and a half writing both some really polite messages that do not help anybody
  3. I am sure that the piece of code that I need will take you about a sec to write (who knows better the code than you ?)

Knowing all that where is the gain for each of us ??
I am sorry, but I do not ask you to write a special extension or something that would take you a whole week to do, just a little line of code which will take you less time than all the nice messages you wrote me...

I know also that if you start this way where's the limit between litle code and special dev ?

But in my opinion, what I am asking is not something strange, because as said, it is part of any invoice out of there, and the little line of code which is missing, in Hikashop or Hikamarket (damn, I do not care), is nothing to write especially for you.

Sorry to be disappointed, but is this little case I do not feel being a customer who paid about 200 € for both software Hikashop and Hikamarket !
Best regards
Stéphane

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
7 years 11 months ago #257417

Hi,

The support philosophy is based on that proverb:

if you give a man a fish you feed him for a day, while if you teach him to fish you feed him for life


You quote a part of the view code
<?php echo JText::_('INVOICE') . ': ' . @$this->element->order_invoice_number; ?>
And you're asking the code to display the order number.
I wrote you :

Knowing that you have access to the Order object (element), you have the order invoice number (order_invoice_number) but you have also access to the order number (order_number).

Which explain that you have the order_invoice_number and you want to display the order_number.

So we basically replace the two names and we change the translation "invoice" into "order_number".
<?php echo JText::_('ORDER_NUMBER') . ': ' . @$this->element->order_number; ?>

It does not require high programming skill, it is a strict basic replacement or something you already have.
It is a simple display (echo) of a translation and a value.

If you were asking some complexe code, like how to load the vendors link to an order, details about the multivendor internal structure or a lot of things ; I would gave you an answer.. Like I answered you even in my first message where I gave you the solution.
I gave you the instruction to tell you "how to fish" and you're right now telling me "no I want a fish".

So you now have the code to paste. But I don't think it is the right way to help you right now, to help you to understand and use HikaMarket (or HikaShop in that case due the fact that the view is the HikaShop view, so it is not really related to HIkaMarket so is not in the right section of the forum).

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: 88
  • Thank you received: 0
7 years 11 months ago #257457

Dear Jerome,

I have been a Teacher for about 30+ years around the world for different Air Conditioning Companies.
Teaching in a right way would have been giving the solution (you do not know what time schedule I do have) and explaining how the change was easy to made and why.

Both of us wouldn't have lost about 2 days.
I could, once I had time for it, spend time in learning how you've made the changes.

A more positive way to gain the same result.
The best Teacher is a person who is able to put it self at the same level then his students.

My knowledge level in PHP is quite like zero, I've said it in my post, learning just what

->
means in PHP would take me about a day to get it... Do you think you've helped me in your fist answer ?

Just think, I am Now 55 years old, got a new Job (took me about 3 years to get one) since a month I am building a shop for my Boss (the first time I am doing that with Hikashop), My Boss want the shop ready for production by Christmas. I have enough to do with all the rest. Taking about 2 days to get a line of PHP, is too much time for me actually. But in January, I will have time to spend in learning and getting more independent in PHP.
Should I explain my life each time I need real support ? I think that you, once you put yourself in my own position, would also say no; isn't it ?

As said, try perhaps to be more positive (you do not know in which position the people might be and they are not here to explain you all their life) give the answer and teach the people how you've got this answer. Doing so you will gain time, they will gain time, and they will scherich you being such an avenant teacher.
Some of them will never take time to learn, and just take profit from your help. But in your opinion, how many people like that are in our business ? 10%, maybe more, 20% ? That means that 80% or the people you've helped are now scheriching you and telling all the other people around them (maybe future customers for you) how great Hikashop support people are (open source designer, open minded people).

What do you think about this approach ? Doesn't it look more positive, with for those who want to learn, the same result ?
Best regards
Stéphane

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

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
7 years 11 months ago #257479

Hi,

We provide user support with HikaShop not developer support.
You say

Sorry to be disappointed, but is this little case I do not feel being a customer who paid about 200 € for both software Hikashop and Hikamarket !

but such developer support is usually billed thousands of euros by software companies.

You got your answer and we get what you're saying but I hope you can also understand our point of view. Let's close the debate here.

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

Moderators: Obsidev
Time to create page: 0.084 seconds
Powered by Kunena Forum