selling_plan_checkout_charge オブジェクト
サブスクリプション販売プラン(定期購入)でチェックアウト時に顧客が支払う金額に関する情報を持つオブジェクト。金額が定価の割合か固定額かを value_type で区別し、value で具体値を取得できる。
仕様
72 行 / json{
"access": {
"global": false,
"parents": [
{
"object": "line_item",
"property": "selling_plan_allocation"
},
{
"object": "variant",
"property": "selling_plan_allocations"
},
{
"object": "selling_plan",
"property": "checkout_charge"
}
],
"template": []
},
"deprecated": false,
"deprecation_reason": "",
"description": "To learn about how to support selling plans in your theme, refer to [Purchase options](/themes/pricing-payments/purchase-options).",
"properties": [
{
"deprecated": false,
"deprecation_reason": "",
"description": "",
"examples": [],
"return_type": [
{
"type": "string",
"name": "percentage",
"description": "",
"array_value": ""
},
{
"type": "string",
"name": "price",
"description": "",
"array_value": ""
}
],
"summary": "The value type of the checkout charge.",
"name": "value_type"
},
{
"deprecated": false,
"deprecation_reason": "",
"description": "How this value is interpreted depends on the [value type](/docs/api/liquid/objects/selling_plan_checkout_charge#selling_plan_checkout_charge-value_type) of\nthe checkout charge. The following table outlines what the value represents for each value type:\n\n| Value type | Value |\n| --- | --- |\n| `percentage` | The percent amount of the original price that the customer needs to pay.<br><br>For example, if the value is 50, then the customer needs to pay 50% of the original price. |\n| `price` | The amount that the customer needs to pay in the currency's subunit. |\n\nFor currencies without subunits, such as JPY and KRW, tenths and hundredths of a unit are appended. For example, 1000 Japanese yen is output as 100000.\n\n> Tip:\n> Use [money filters](/docs/api/liquid/filters/money-filters) to output a formatted price.",
"examples": [],
"return_type": [
{
"type": "number",
"name": "",
"description": "",
"array_value": ""
}
],
"summary": "The value of the checkout charge.",
"name": "value"
}
],
"summary": "Information about how a specific [selling plan](/apps/subscriptions/selling-plans) affects the amount that a\ncustomer needs to pay for a line item at checkout.",
"name": "selling_plan_checkout_charge",
"examples": [],
"json_data": {
"path": "/products/health-potion?selling_plan=2595487809",
"handle": "product.selected_selling_plan.checkout_charge",
"data_from_file": ""
},
"return_type": []
}出典・ライセンス
- Repository:
- https://github.com/Shopify/theme-liquid-docs
- License:
- MIT
このコードは Shopify 著作の MIT ライセンスソースです。 原本の著作権は Shopify が保有します。日本語訳は ALSEL によるものです。
関連項目
content_for_header オブジェクト
Shopify が必要とするスクリプト(分析・チェックアウト・言語設定など)をすべて動的に出力するオブジェクト。theme.liquid の <head> タグ内に埋め込む必須要素。
metaobjects オブジェクト
ストア全体のメタオブジェクト定義にアクセスするグローバルオブジェクト。個別のメタオブジェクトはタイプとハンドルで参照でき、メタオブジェクト定義のエントリをループで反復処理できる。
additional_checkout_buttons オブジェクト
PayPal Express Checkout など、オフサイト決済に対応した外部決済プロバイダーがストアに設定されているかを真偽値で返す。`content_for_additional_checkout_buttons` と組み合わせて、該当するチェックアウトボタンを条件付きで表示する。
canonical_url オブジェクト
現在のページの正規 URL を取得するオブジェクト。Google などの検索エンジンに対してどのページ版が正規であるかを指定するために使用する。
content_for_index オブジェクト
ホームページに表示するセクションの内容を動的に返すオブジェクト。Liquid インデックステンプレートで必ず使用する。
content_for_additional_checkout_buttons オブジェクト
PayPal、Apple Pay、Google Pay など複数の決済プロバイダが有効になっているとき、その決済ボタンを HTML として出力するオブジェクト。`additional_checkout_buttons` で有無を判定したうえで、このオブジェクトで実際のボタンを表示する。