1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

B2C Commerce のその他 Salesforce 製品との接続 - Salesforce Order Management 後編

Last updated at Posted at 2023-03-30

※ これから記載する事項は、私が所属する会社とは切関係のない事柄です。

今回は「B2C Commerce のその他 Salesforce 製品との接続」シリーズとして B2C Commerce と Salesforce Platform 上に構築されている Salesforce Order Management (以下 SOM) との plugin_ordermanagement というカートリッジを利用した接続方法を紹介したいと思います。B2C Commerce から SOM のデータを送信する方法は前半にて紹介します。
※ ここでは接続に関してのみ取り扱いSOMの内容は取り扱いませんのでご了承ください。

Cross Cloud (11).jpg

プラグイン設定時の注文詳細画面
スクリーンショット 2023-03-30 17.03.37.png

接続内容とポイント

plugin_ordermanagement の GitHub (Account Manager アカウント必要)から抜粋しています。

  • ゲストユーザが注文を検索できる
  • 登録ユーザが注文履歴を確認できる
  • 注文のステータスを確認できる
  • 返品・キャンセルができる

接続方法

1. Salesforce Platform への権限設定

設定 > 権限セット に遷移し、「OMSelfServicePermissionsSet」の「有功化された注文の編集」を有効にする。

スクリーンショット 2023-03-29 14.55.31.png

2. Salesforce Platform と B2C Commerce の接続を行う

設定 > 注文管理 に遷移し、「B2C Commerce 接続」を有効にする。

スクリーンショット 2023-03-30 9.24.12.png

設定 > クラウドツークラウド接続を管理 に遷移し、「新しい接続」ボタンをクリックすると、下記の画像のような入力ボックスが表示されるので、クラウドまたはアプリケーションは「Commerce Cloud」を選択。リモートテナント URL は B2C Commerce の Business Manager の URL を入力し、「接続を要求」をクリックし、Business Manager の画面へ遷移するので「Allow(許可)」ボタンをクリックし、さらに「完了」ボタンをクリックする。

スクリーンショット 2023-03-29 14.32.10.png

3. B2C Commerce に plugin_ordermanagement カートリッジを設定する

実際の方法は plugin_ordermanagement の GitHub (Account Manager アカウント必要) みてください。ポイントとして下記の通りです。

  • カートリッジのアップロードと有効化。(参考 Qiita「Salesforce B2C CommerceのSFRA開発環境セットアップ&デプロイ方法」)
  • 商品オブジェクトへカスタム属性( nonRMAnonReturnOrderRMA )の追加
  • 設定(APIバージョンや注文ステータス名の変更など)は plugin_ordermanagement/cartridges/plugin_ordermanagement/cartridge/config/somPreferences.js で行える。

接続データとポイント

  • データに関しては固定のデータではなくカートリッジコード上の SOQL クエリから確認できます(
  • 目視の確認では下記のオブジェクトを取得していました。
    • OrderDeliveryMethod、CardPaymentMethod、FulfillmentOrder、Account、FulfillmentOrderShipments、Shipment、FulfillmentOrderLineItems、OrderSummary、OrderPaymentSummaries、OrderDeliveryGroupSummaries、OrderItemSummaries

リソース

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?