我正在使用1个第三方API将订单导入到我的购物软件中,并且正在使用以下方法。
$client_shopware->post('orders', ["customerId" => $customer_id,
"paymentId" => $paymentId,
"dispatchId" => $dispatchId,
"partnerId" => "",
"shopId" => $shopId,
"invoiceAmount" => 0,
"invoiceAmountNet" => 0,
"invoiceShipping" => 0,
"invoiceShippingNet" => 0,
"orderTime" => $order_time,
"net" => $TotalOrderAmount,
"taxFree" => 0,
"languageIso" => "1",
"currency" => "EUR",
"currencyFactor" => 1,
"referer" => "Channel advisor",
"remoteAddress" => "155.155.155.155",
"details" => $JsonArray,
"documents" => $documents,
"billing" => $billing,
"shipping" => $shipping,
"paymentStatusId" => $paymentStatusId,
"orderStatusId" => $orderStatusId,
]);
但是我担心的是,在创建订单后,我想为该订单更新“自由文本字段”的值。那么有人可以帮我吗?
答案 0 :(得分:0)
我在支持论坛上发布了关于同一主题的问题,得到如下答复:
(defn uk-drop []
(let [the-drop (atom nil)]
(reagent/create-class
:component-did-mount (fn [this]
(reset! the-drop (.dropdown js/UIkit "#my-id")))
:reagent-render
(fn []
[:div
[:div#my-id {:data-uk-dropdown true} "Some content"]
[:button {:on-click #(.show @the-drop)} "Open"]
[:button {:on-click #(.hide @the-drop)} "Close"]]))))
您需要一个键属性,该属性是一个包含属性数据的数组。 所以我以下面的方式使用了它,并且有效。
'attribute' => ['attribute1' => 'some value']