> ## Documentation Index
> Fetch the complete documentation index at: https://foliant-help.iforiti.com/llms.txt
> Use this file to discover all available pages before exploring further.

# टेम्पलेट में लाइन आइटम

> Liquid में किसी ऑर्डर के लाइन आइटम पर लूप चलाएँ और उनके टाइटल, मात्रा, कीमत, SKU, इमेज, वज़न और प्रॉपर्टी प्रिंट करें।

ऑर्डर के आइटम `line_items` में होते हैं। इन्हें प्रिंट करने के लिए आप इस सूची पर लूप चलाएँ: `{% for line_item in line_items %}` और `{% endfor %}` के बीच का सब कुछ हर आइटम के लिए एक बार दोहराया जाता है, और `line_item` मौजूदा आइटम होता है। लाइन आइटम फ़ील्ड सिर्फ़ लूप के अंदर काम करते हैं।

## आइटम की एक साधारण टेबल

```liquid theme={null}
<table>
  {% for line_item in line_items %}
    <tr>
      <td>{{ line_item.title }}</td>
      <td>{{ line_item.sku }}</td>
      <td>{{ line_item.quantity }}</td>
      <td>{{ line_item.price | money }}</td>
      <td>{{ line_item.line_price | money }}</td>
    </tr>
  {% endfor %}
</table>
```

## लाइन आइटम फ़ील्ड

| वेरिएबल | यह क्या प्रिंट करता है |
| - | - |
| `line_item.title` | आइटम का टाइटल (प्रोडक्ट और वैरिएंट) |
| `line_item.name` | आइटम का नाम |
| `line_item.product_title` | प्रोडक्ट का टाइटल |
| `line_item.variant_title` | वैरिएंट का टाइटल, जैसे "Blue / Large" |
| `line_item.quantity` | ऑर्डर की गई मात्रा, रिफ़ंड किए गए आइटम समेत |
| `line_item.fulfillable_quantity` | कितने आइटम अभी फ़ुलफ़िल होने बाकी हैं |
| `line_item.refunded_quantity` | कितने आइटम रिफ़ंड हुए |
| `line_item.sku` | SKU |
| `line_item.vendor` | वेंडर |
| `line_item.price` | लाइन डिस्काउंट के बाद यूनिट कीमत (सेंट में) |
| `line_item.original_price` | डिस्काउंट से पहले यूनिट कीमत (सेंट में) |
| `line_item.line_price` | लाइन का कुल: यूनिट कीमत × मात्रा, लाइन डिस्काउंट के बाद (सेंट में) |
| `line_item.total_discount` | लाइन का डिस्काउंट (सेंट में) |
| `line_item.discount_per_item` | हर आइटम पर डिस्काउंट (सेंट में) |
| `line_item.total_tax` | लाइन का टैक्स (सेंट में) |
| `line_item.cost` | आइटम की लागत, परचेज़ ऑर्डर के लिए (सेंट में) |
| `line_item.tax_lines` | लाइन के टैक्स: `title`, `rate`, `price` के लिए लूप चलाएँ |
| `line_item.discount_allocations` | लाइन पर लागू डिस्काउंट: `amount` के लिए लूप चलाएँ |
| `line_item.properties` | लाइन आइटम प्रॉपर्टी। [ऑर्डर एट्रिब्यूट और लाइन आइटम प्रॉपर्टी](https://foliant-help.iforiti.com/hi/template-editor/liquid-custom-fields.md) देखें। |
| `line_item.hs_tariff_code` | HS टैरिफ़ कोड |
| `line_item.country_of_origin` | मूल देश |
| `line_item.weight` | एक आइटम का वज़न, उसकी अपनी इकाई में |
| `line_item.grams` | एक आइटम का वज़न, ग्राम में; `{{ line_item.grams \| weight_with_unit }}` इकाई जोड़ता है |
| `line_item.total_weight` | लाइन का वज़न (आइटम × मात्रा) |
| `line_item.image` | आइटम की इमेज; `{{ line_item.image \| img_url: 'thumb' \| img_tag }}` इसे प्रिंट करता है |
| `line_item.requires_shipping` | आइटम को शिपिंग की ज़रूरत है या नहीं |
| `line_item.gift_card` | आइटम गिफ़्ट कार्ड है या नहीं |
| `line_item.product` | प्रोडक्ट (`title`, `type`, `vendor`, `tags`, `handle`…) |
| `line_item.variant` | वैरिएंट (`title`, `sku`, `barcode`, `option1`, `inventory_quantity`…) |

## आम पैटर्न

प्रोडक्ट के नीचे वैरिएंट टाइटल प्रिंट करें, सिर्फ़ तब जब वह मौजूद हो:

```liquid theme={null}
{{ line_item.product_title }}
{% if line_item.variant_title != blank %}<br>{{ line_item.variant_title }}{% endif %}
```

पैकिंग स्लिप पर पूरी तरह रिफ़ंड हुए आइटम छोड़ दें:

```liquid theme={null}
{% for line_item in line_items %}
  {% if line_item.quantity > line_item.refunded_quantity %}
    {{ line_item.title }} × {{ line_item.quantity | minus: line_item.refunded_quantity }}
  {% endif %}
{% endfor %}
```

हर SKU का बारकोड दिखाएँ:

```liquid theme={null}
{{ line_item.sku | barcode }}
```

## हर शिपमेंट के लिए एक डॉक्यूमेंट

जब कोई टेम्पलेट हर शिपमेंट के लिए एक डॉक्यूमेंट प्रिंट करता है (टेम्पलेट के सेटिंग पेज पर **बँटे हुए शिपमेंट**), तो `document_fulfillment` वह शिपमेंट होता है जो प्रिंट हो रहा है। सिर्फ़ उसमें मौजूद आइटम की सूची बनाने के लिए:

```liquid theme={null}
{% if document_fulfillment %}
  {% assign line_items = document_fulfillment.line_items %}
{% endif %}
```

## ध्यान रखें

* कीमतें सेंट में होती हैं: इन्हें हमेशा money फ़िल्टर के साथ प्रिंट करें। [टेम्पलेट में पैसा और करेंसी](https://foliant-help.iforiti.com/hi/template-editor/liquid-money-and-currency.md) देखें।
* आइटम की इमेज उसी साइज़ में प्रिंट होती हैं जो आप `img_url` के साथ बताते हैं, जैसे `'thumb'`, `'small'`, `'medium'` या `'120x120'`।
* प्रोडक्ट और वैरिएंट के मेटाफ़ील्ड `line_item.product.metafields` और `line_item.variant.metafields` में होते हैं। [टेम्पलेट में मेटाफ़ील्ड](https://foliant-help.iforiti.com/hi/template-editor/metafields.md) देखें।
* लूप वेरिएबल का नाम आप खुद चुन सकते हैं, लेकिन `line_item` रेफ़रेंस और स्टार्टर टेम्पलेट से मेल खाता है।
* Bold Product Options और Infinite Options के ऑर्डर `line_item.options`, `line_item.option_addon`, `line_item.option_addons` और ऐड-ऑन सहित कीमतें जोड़ते हैं, ताकि आप कीमत वाले ऐड-ऑन उनके आइटम के नीचे प्रिंट कर सकें। देखें [उत्पाद विकल्प ऐप (Bold, Infinite Options)](https://foliant-help.iforiti.com/hi/templates/product-options-apps.md)।

## संबंधित लेख

* [ऑर्डर ऑब्जेक्ट और आम वेरिएबल](https://foliant-help.iforiti.com/hi/template-editor/liquid-order-variables.md)
* [टेम्पलेट में पैसा और करेंसी](https://foliant-help.iforiti.com/hi/template-editor/liquid-money-and-currency.md)
* [ऑर्डर एट्रिब्यूट और लाइन आइटम प्रॉपर्टी](https://foliant-help.iforiti.com/hi/template-editor/liquid-custom-fields.md)
* [टेम्पलेट में मेटाफ़ील्ड](https://foliant-help.iforiti.com/hi/template-editor/metafields.md)
* [उत्पाद विकल्प ऐप (Bold, Infinite Options)](https://foliant-help.iforiti.com/hi/templates/product-options-apps.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.