Web services Prestashop-向购物车添加凭证(购物车规则),以便通过web服务处理订单

Web services Prestashop-向购物车添加凭证(购物车规则),以便通过web服务处理订单,web-services,prestashop,cart,cart-rules,Web Services,Prestashop,Cart,Cart Rules,我的移动应用程序是一个移动商务应用程序,它作为后端与PrestaShop进行通信。所以我使用的是PrestashopWeb服务。 我想向我的客户提供添加我想要与他们沟通的凭证代码的可能性。 因此,我在购物车页面中添加了一个字段,用户在其中输入凭证代码(购物车规则)。当代码与凭证关联时,将检索该代码并显示折扣。 但是如何通过Web服务将与凭证代码关联的购物车规则附加到购物车?cart web服务概要不会显示任何cart_规则字段,如下所示: <prestashop xmlns:xlink="

我的移动应用程序是一个移动商务应用程序,它作为后端与PrestaShop进行通信。所以我使用的是PrestashopWeb服务。 我想向我的客户提供添加我想要与他们沟通的凭证代码的可能性。 因此,我在购物车页面中添加了一个字段,用户在其中输入凭证代码(购物车规则)。当代码与凭证关联时,将检索该代码并显示折扣。 但是如何通过Web服务将与凭证代码关联的购物车规则附加到购物车?cart web服务概要不会显示任何cart_规则字段,如下所示:

<prestashop xmlns:xlink="http://www.w3.org/1999/xlink">
  <cart>
  <id_address_delivery format="isUnsignedId"/>
  <id_address_invoice format="isUnsignedId"/>
  <id_currency required="true" format="isUnsignedId"/>
  <id_customer format="isUnsignedId"/>
  <id_guest format="isUnsignedId"/>
  <id_lang required="true" format="isUnsignedId"/>
  <id_shop_group format="isUnsignedId"/>
  <id_shop format="isUnsignedId"/>
  <id_carrier format="isUnsignedId"/>
  <recyclable format="isBool"/>
  <gift format="isBool"/>
  <gift_message format="isMessage"/>
  <mobile_theme format="isBool"/>
  <delivery_option/>
  <secure_key maxSize="32"/>
  <allow_seperated_package format="isBool"/>
  <date_add format="isDate"/>
  <date_upd format="isDate"/>
  <associations>
     <cart_rows nodeType="cart_row" virtualEntity="true">
        <cart_row>
            <id_product xlink:href="https://affleloustore.bertekgroup.fr/api/products/" required="true"/>
            <id_product_attribute xlink:href="https://affleloustore.bertekgroup.fr/api/combinations/" required="true"/>
            <id_address_delivery xlink:href="https://affleloustore.bertekgroup.fr/api/addresses/" required="true"/>
            <quantity required="true"/>
            <qte_detail/>
        </cart_row>
     </cart_rows>
  </associations>
  </cart>
</prestashop>

提前谢谢

与特定购物车相关的购物车规则(凭证)保存在一个单独的表中
ps\u Cart\u Cart\u rule
。此表在Prestashop Core中没有ObjectModel类;它完全由Cart类管理。因此,您无法访问carts凭单

如果您的应用程序连接到单个商店,您可以考虑使用扩展的Prestashop API实现一个类来直接管理该实体

祝你好运。

与特定购物车相关的购物车规则(凭证)保存在一个单独的表中
ps\u Cart\u Cart\u rule
。此表在Prestashop Core中没有ObjectModel类;它完全由Cart类管理。因此,您无法访问carts凭单

如果您的应用程序连接到单个商店,您可以考虑使用扩展的Prestashop API实现一个类来直接管理该实体


祝你好运。

谢谢,但我不需要访问与购物车关联的购物车规则。我想知道如何通过webservice将购物车规则与购物车关联。谢谢,但我不需要访问与购物车关联的购物车规则。我想知道如何通过webservice将购物车规则与购物车关联。