How Can i add customer's phone number and email in my invoice of order printer

Solved
Syed_Musavir92
New Member
1 0 0

Hello, I am having trouble to add customer's phone number and email in my order printer invoice but im unable to add, i tried many ways like shipping_address.phone , customer.email but nothing is working.. any other way to both and priduct SKU in item details..? 

here is my code:


<img src="https://cdn.shopify.com/s/files/1/0578/5826/1177/files/kt_1395_5x-100.png?v=1625038532" width="220px" height="70px" style="float: left; margin: 10px;" >

<br><br><br>

<p style="float: right; text-align: right; margin-top: -50px;">
    {{ "now" | date: "%m/%d/%y" }}<br />
    Invoice for {{ order_name }}
  </p>
<br><br>
  <hr>
  
  {% if billing_address %}
  <h3 style="margin: 0 0 1em 0; ">Billing Details</h3>
  <div style="margin: 0 0 1em 0; padding: 1em; ">
    <div style="border: 1px solid black; padding: 3px; border-bottom: 0px;">
    <strong>{{ billing_address.name }}</strong><br>
    </div>
    <div style="border: 1px solid black ; padding: 3px; border-bottom: 0px;">
    <strong>{{ customer.phone }}</strong><br>
    </div>
   
    <div style="border: 1px solid black; padding: 3px; border-bottom: 0px;">
    <strong>{{ billing_address.company }} </strong><br>
    </div>
    <div style="border: 1px solid black; padding: 3px; border-bottom: 0px;">
        <strong>{{ billing_address | format_address }}   </strong><br>
        </div>
    <div style="border: 1px solid black; padding: 3px;  ">
    <strong   >{{  customer.email  }}</strong><br>
    </div>
</div>
  
{% endif %}




  
  <h3 style="margin: 0 0 1em 0;">Item Details</h3>
  
  <table class="table-tabular" style="margin: 0 0 1.5em 0;">
    <thead>
      <tr>
        <th>Quantity</th>
        <th>Item</th>
        {% if show_line_item_taxes %}
        <th>Taxes</th>
        {% endif %}
        <th>SKU</th>
        <th>Price</th>
      </tr>
    </thead>
    <tbody>
      {% for line_item in line_items %}
        <tr>
          <td>{{ line_item.quantity }} x</td>
          <td><b>{{ line_item.title }}</b></td>
          {% if show_line_item_taxes %}
          <td>
            {% for tax_line in line_item.tax_lines %}
              {{ tax_line.price | money }} {{ tax_line.title }}<br/>
            {% endfor %}
          </td>
        
          <td>{{ line.variant.sku }}</td>
        
         
              <s>{{ line_item.original_price | money }}</s>
            {% endif %}
            {{ line_item.price | money }}
          </td>
        </tr>
      {% endfor %}
    </tbody>
  </table>
  
  {% if transactions.size > 1 %}
    <h3 style="margin: 0 0 1em 0;">Transaction Details</h3>
    <table class="table-tabular" style="margin: 0 0 1.5em 0;">
      <thead>
        <tr>
          <th>Type</th>
          <th>Amount</th>
          <th>Kind</th>
          <th>Status</th>
        </tr>
      </thead>
      <tbody>
        {% for transaction in transactions %}
          <tr>
            <td>{{ transaction.gateway | payment_method }}</td>
            <td>{{ transaction.amount | money }}</td>
            <td>{{ transaction.kind }}</td>
            <td>{{ transaction.status }}</td>
          </tr>
        {% endfor %}
      </tbody>
    </table>
  {% endif %}
  
  <h3 style="margin: 0 0 1em 0;">Payment Details</h3>
  
  <table class="table-tabular" style="margin: 0 0 1.5em 0;">
    <tr>
      <td>Subtotal price:</td>
      <td>{{ subtotal_price | money }}</td>
    </tr>
    {% for discount in discounts %}
    <tr>
      <td>Includes discount "{{ discount.code }}"</td>
      <td>{{ discount.savings | money }}</td>
    </tr>
    {% endfor %}
   
    {% if shipping_address %}
      <tr>
        <td>Shipping:</td>
        <td>{{ shipping_price | money }}</td>
      </tr>
    {% endif %}
    <tr>
      <td><strong>Total price:</strong></td>
      <td><strong>{{ total_price | money }}</strong></td>
    </tr>
    
  </table>
  
  {% if note %}
    <h3 style="margin: 0 0 1em 0;">Note</h3>
    <p>{{ note }}</p>
  {% endif %}
  
  
  
  <p>If you have any questions, please send an email to <u>{{ shop.email }}</u></p>
 
0 Likes
Tira
Shopify Staff
Shopify Staff
1107 74 180

This is an accepted solution.

Hey, @Syed_Musavir92.

Tira here to help.

Thanks for these details and for providing the code you’re working with for your order printer template. I appreciate that you did your own research. This is helpful.

Although I’m not an expert at coding myself, I think you’re on the right track with this. If you’re editing the order printer template, then our design team might be able to help you with customizing your template, as this is an App made by Shopify. If you’re using a Basic plan or higher, you receive 60 minutes of complimentary design time for your store. Check out our Design Policy to learn more about receiving design support for your store.

I’ve asked our design team if this is a customization they can help you with and this is something we can look into for you.

It looks like we’ll need to access your account in order to resolve this issue. While we’re not able to provide account-specific support via the Shopify Community at this time, we’d be happy to continue assisting you through live chat, email, or callback. Please visit https://bit.ly/3cJkx8V and log in to your account to create a support request. Once you create a support request, please copy and paste the URL of this thread into your request so that you can have a summary available for the next agent to be aware of and so that we can help you with your order printer template.

Since this is the next step I've marked this reply as the solution for the benefit of others who may discover this topic. Thanks!

Tira | Social Care @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit the Shopify Help Center or the Shopify Blog

0 Likes