blob: ffa63087c4366241a0f0620ee24d6c2f9dbae561 [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8" ?>
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
<services xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/services.xsd">
<description>Product Component Services</description>
<vendor>OFBiz</vendor>
<version>1.0</version>
<!-- Product Price Services -->
<service name="calculateProductPrice" engine="java"
location="org.apache.ofbiz.product.price.PriceServices" invoke="calculateProductPrice" auth="false" use-transaction="false">
<description>Calculate a Product's Price from ProductPriceRules</description>
<attribute name="product" type="org.apache.ofbiz.entity.GenericValue" mode="IN" optional="false"/>
<attribute name="prodCatalogId" type="String" mode="IN" optional="true"/>
<attribute name="webSiteId" type="String" mode="IN" optional="true"/>
<attribute name="partyId" type="String" mode="IN" optional="true"/>
<attribute name="productStoreId" type="String" mode="IN" optional="true"/>
<attribute name="productStoreGroupId" type="String" mode="IN" optional="true"/>
<attribute name="agreementId" type="String" mode="IN" optional="true"/>
<attribute name="quantity" type="BigDecimal" mode="IN" optional="true"/>
<attribute name="amount" type="BigDecimal" mode="IN" optional="true"/>
<attribute name="currencyUomId" type="String" mode="IN" optional="true"/>
<attribute name="currencyUomIdTo" type="String" mode="IN" optional="true"/>
<attribute name="productPricePurposeId" type="String" mode="IN" optional="true"><!-- defaults to PURCHASE --></attribute>
<attribute name="termUomId" type="String" mode="IN" optional="true"><!-- if specified ProductPrice records will be filtered by this, ensures for purposes like recurring prices that only the recurring term desired is taken into consideration --></attribute>
<attribute name="autoUserLogin" type="org.apache.ofbiz.entity.GenericValue" mode="IN" optional="true"/>
<attribute name="checkIncludeVat" type="String" mode="IN" optional="true"><!-- can be Y or N, defaults to N --></attribute>
<attribute name="findAllQuantityPrices" type="String" mode="IN" optional="true"><!-- can be Y or N, defaults to N; see the allQuantityPrices attribute for more details --></attribute>
<attribute name="surveyResponseId" type="String" mode="IN" optional="true"/>
<attribute name="customAttributes" type="Map" mode="IN" optional="true"/>
<attribute name="basePrice" type="BigDecimal" mode="OUT" optional="false"><!-- will only be different from price if there is a display price adjustment, for example: checkIncludeVat=Y and a VAT amount was found --></attribute>
<attribute name="price" type="BigDecimal" mode="OUT" optional="false"/>
<attribute name="listPrice" type="BigDecimal" mode="OUT" optional="true"/>
<attribute name="defaultPrice" type="BigDecimal" mode="OUT" optional="true"/>
<attribute name="competitivePrice" type="BigDecimal" mode="OUT" optional="true"/>
<attribute name="averageCost" type="BigDecimal" mode="OUT" optional="true"/>
<attribute name="promoPrice" type="BigDecimal" mode="OUT" optional="true"/>
<attribute name="specialPromoPrice" type="BigDecimal" mode="OUT" optional="true"><!-- used for the Product [Special Promo] Type ProductPromo Action --></attribute>
<attribute name="isSale" type="Boolean" mode="OUT" optional="false"/>
<attribute name="validPriceFound" type="Boolean" mode="OUT" optional="false"/>
<attribute name="currencyUsed" type="String" mode="OUT" optional="false"/>
<attribute name="orderItemPriceInfos" type="java.util.List" mode="OUT" optional="false"/>
<attribute name="allQuantityPrices" type="java.util.List" mode="OUT" optional="true">
<!-- Populated when findAllQuantityPrices is Y;
is a List of Map where each Map has all other return attributes normally created for a price calculation;
each Map in the List will also contain a field called "quantityProductPriceRule" with the GenericValue object representing the ProductPriceRule with the quantity condition that the List entry is based on
-->
</attribute>
<attribute name="optimizeForLargeRuleSet" type="String" mode="IN" optional="true"/>
</service>
<service name="createProductPriceRule" default-entity-name="ProductPriceRule" engine="entity-auto" invoke="create" auth="true">
<description>Create a ProductPriceRule</description>
<permission-service service-name="productPriceGenericPermission" main-action="CREATE"/>
<auto-attributes include="pk" mode="OUT" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
<override name="ruleName" optional="false"/>
</service>
<service name="updateProductPriceRule" default-entity-name="ProductPriceRule" engine="entity-auto" invoke="update" auth="true">
<description>Update a ProductPriceRule</description>
<permission-service service-name="productPriceGenericPermission" main-action="UPDATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
</service>
<service name="deleteProductPriceRule" default-entity-name="ProductPriceRule" engine="entity-auto" invoke="delete" auth="true">
<description>Delete a ProductPriceRule</description>
<permission-service service-name="productPriceGenericPermission" main-action="DELETE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
</service>
<service name="createProductPriceCond" default-entity-name="ProductPriceCond" engine="simple"
location="component://product/minilang/product/price/PriceServices.xml" invoke="createProductPriceCond" auth="true">
<description>Create a ProductPriceCond</description>
<permission-service service-name="productPriceGenericPermission" main-action="CREATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
<attribute name="condValueInput" type="String" mode="IN" optional="true"></attribute>
<override name="productPriceCondSeqId" mode="OUT"/>
</service>
<service name="updateProductPriceCond" default-entity-name="ProductPriceCond" engine="simple"
location="component://product/minilang/product/price/PriceServices.xml" invoke="updateProductPriceCond" auth="true">
<description>Update a ProductPriceCond</description>
<permission-service service-name="productPriceGenericPermission" main-action="UPDATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
<attribute name="condValueInput" type="String" mode="IN" optional="true"></attribute>
</service>
<service name="deleteProductPriceCond" default-entity-name="ProductPriceCond" engine="entity-auto" invoke="delete" auth="true">
<description>Delete a ProductPriceCond</description>
<permission-service service-name="productPriceGenericPermission" main-action="DELETE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
</service>
<service name="createProductPriceAction" default-entity-name="ProductPriceAction" engine="entity-auto" invoke="create" auth="true">
<description>Create a ProductPriceAction</description>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
<override name="productPriceActionSeqId" mode="OUT"/>
</service>
<service name="updateProductPriceAction" default-entity-name="ProductPriceAction" engine="entity-auto" invoke="update" auth="true">
<description>Update a ProductPriceAction</description>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
</service>
<service name="deleteProductPriceAction" default-entity-name="ProductPriceAction" engine="entity-auto" invoke="delete" auth="true">
<description>Delete a ProductPriceAction</description>
<auto-attributes include="pk" mode="IN" optional="false"/>
</service>
<!-- Product Promotion Services -->
<service name="createProductPromo" default-entity-name="ProductPromo" engine="entity-auto" invoke="create" auth="true">
<description>Create a ProductPromo</description>
<permission-service service-name="productPriceGenericPermission" main-action="CREATE"/>
<auto-attributes include="pk" mode="OUT" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
<override name="promoName" optional="false"/>
<override name="promoText" allow-html="any"/>
<override name="userEntered" default-value="Y"/>
</service>
<service name="updateProductPromo" default-entity-name="ProductPromo" engine="entity-auto" invoke="update" auth="true">
<description>Update a ProductPromo</description>
<permission-service service-name="productPriceGenericPermission" main-action="UPDATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
<override name="promoText" allow-html="any"/>
<override name="userEntered" default-value="Y"/>
</service>
<service name="deleteProductPromo" default-entity-name="ProductPromo" engine="entity-auto" invoke="delete" auth="true">
<!-- TODO: if a force remove flag is passed, remove related info first, maybe just rules, store assocs, etc -->
<description>Delete a ProductPromo</description>
<permission-service service-name="productPriceGenericPermission" main-action="DELETE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
</service>
<service name="createProductPromoAction" default-entity-name="ProductPromoAction" engine="entity-auto" invoke="create" auth="true">
<description>Create a ProductPromo</description>
<permission-service service-name="productPriceGenericPermission" main-action="CREATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
<override name="productPromoActionSeqId" mode="OUT"/>
<override name="productPromoActionEnumId" optional="false"/>
</service>
<service name="updateProductPromoAction" default-entity-name="ProductPromoAction" engine="entity-auto" invoke="update" auth="true">
<description>Update a ProductPromo</description>
<permission-service service-name="productPriceGenericPermission" main-action="UPDATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
</service>
<service name="deleteProductPromoAction" default-entity-name="ProductPromoAction" engine="entity-auto" invoke="delete" auth="true">
<description>Delete a ProductPromo</description>
<permission-service service-name="productPriceGenericPermission" main-action="DELETE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
</service>
<service name="createProductPromoCategory" default-entity-name="ProductPromoCategory" engine="entity-auto" invoke="create" auth="true">
<description>Create a ProductPromoCategory</description>
<permission-service service-name="productPriceGenericPermission" main-action="CREATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
</service>
<service name="updateProductPromoCategory" default-entity-name="ProductPromoCategory" engine="entity-auto" invoke="update" auth="true">
<description>Update a ProductPromoCategory</description>
<permission-service service-name="productPriceGenericPermission" main-action="UPDATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
</service>
<service name="deleteProductPromoCategory" default-entity-name="ProductPromoCategory" engine="entity-auto" invoke="delete" auth="true">
<description>Delete a ProductPromoCategory</description>
<permission-service service-name="productPriceGenericPermission" main-action="DELETE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
</service>
<service name="createProductPromoCode" default-entity-name="ProductPromoCode" engine="entity-auto" invoke="create" auth="true">
<description>Create a ProductPromoCode</description>
<permission-service service-name="productPriceGenericPermission" main-action="CREATE"/>
<auto-attributes include="pk" mode="INOUT" optional="true"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
</service>
<service name="updateProductPromoCode" default-entity-name="ProductPromoCode" engine="entity-auto" invoke="update" auth="true">
<description>Update a ProductPromoCode</description>
<permission-service service-name="productPriceGenericPermission" main-action="UPDATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
</service>
<service name="deleteProductPromoCode" default-entity-name="ProductPromoCode" engine="entity-auto" invoke="delete" auth="true">
<description>Delete a ProductPromoCode</description>
<permission-service service-name="productPriceGenericPermission" main-action="DELETE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
</service>
<service name="createBulkProductPromoCode" engine="java"
location="org.apache.ofbiz.product.promo.PromoServices" invoke="importPromoCodesFromFile" auth="true">
<description>Creates several ProductPromoCode from an uploaded list of promo codes (one code per line)</description>
<implements service="uploadFileInterface"/>
<auto-attributes mode="IN" entity-name="ProductPromoCode" include="nonpk" optional="true"/>
</service>
<service name="createProductPromoCodeEmail" default-entity-name="ProductPromoCodeEmail" engine="entity-auto" invoke="create" auth="true">
<description>Create a ProductPromoCodeEmail</description>
<permission-service service-name="productPriceGenericPermission" main-action="CREATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
</service>
<service name="deleteProductPromoCodeEmail" default-entity-name="ProductPromoCodeEmail" engine="entity-auto" invoke="delete" auth="true">
<description>Delete a ProductPromoCodeEmail</description>
<permission-service service-name="productPriceGenericPermission" main-action="DELETE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
</service>
<service name="createBulkProductPromoCodeEmail" engine="java"
location="org.apache.ofbiz.product.promo.PromoServices" invoke="importPromoCodeEmailsFromFile" auth="true">
<description>Create several ProductPromoCodeEmail from an uploaded list of emails (one address per line)</description>
<implements service="uploadFileInterface"/>
<attribute name="productPromoCodeId" type="String" mode="IN" optional="false"/>
</service>
<service name="createProductPromoCodeParty" default-entity-name="ProductPromoCodeParty" engine="entity-auto" invoke="create" auth="true">
<description>Create a ProductPromoCodeParty</description>
<permission-service service-name="productPriceGenericPermission" main-action="CREATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
</service>
<service name="deleteProductPromoCodeParty" default-entity-name="ProductPromoCodeParty" engine="entity-auto" invoke="delete" auth="true">
<description>Delete a ProductPromoCodeParty</description>
<permission-service service-name="productPriceGenericPermission" main-action="DELETE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
</service>
<service name="createProductPromoCodeSet" default-entity-name="ProductPromoCode" engine="java"
location="org.apache.ofbiz.product.promo.PromoServices" invoke="createProductPromoCodeSet" auth="true">
<description>Create a Product Promo Code Set</description>
<auto-attributes include="nonpk" mode="IN" optional="true">
<exclude field-name="createdDate"/>
<exclude field-name="createdByUserLogin"/>
<exclude field-name="lastModifiedDate"/>
<exclude field-name="lastModifiedByUserLogin"/>
</auto-attributes>
<attribute name="quantity" type="Long" mode="IN" optional="false"/>
<attribute name="codeLength" type="Integer" mode="IN" optional="true" default-value="8"/>
<attribute name="promoCodeLayout" type="String" mode="IN" optional="true" default-value="sequence"/>
</service>
<service name="createProductPromoCond" default-entity-name="ProductPromoCond" engine="simple"
location="component://product/minilang/product/promo/PromoServices.xml" invoke="createProductPromoCond" auth="true">
<description>Create a ProductPromo</description>
<permission-service service-name="productPriceGenericPermission" main-action="CREATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
<attribute name="carrierShipmentMethod" type="String" mode="IN" optional="true"/>
<override name="productPromoCondSeqId" mode="OUT"/>
</service>
<service name="updateProductPromoCond" default-entity-name="ProductPromoCond" engine="simple"
location="component://product/minilang/product/promo/PromoServices.xml" invoke="updateProductPromoCond" auth="true">
<description>Update a ProductPromo</description>
<permission-service service-name="productPriceGenericPermission" main-action="UPDATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
<attribute name="carrierShipmentMethod" type="String" mode="IN" optional="true"/>
</service>
<service name="deleteProductPromoCond" default-entity-name="ProductPromoCond" engine="entity-auto" invoke="delete" auth="true">
<description>Delete a ProductPromo</description>
<permission-service service-name="productPriceGenericPermission" main-action="DELETE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
</service>
<service name="createProductPromoProduct" default-entity-name="ProductPromoProduct" engine="entity-auto" invoke="create" auth="true">
<description>Create a ProductPromoProduct</description>
<permission-service service-name="productPriceGenericPermission" main-action="CREATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
</service>
<service name="updateProductPromoProduct" default-entity-name="ProductPromoProduct" engine="entity-auto" invoke="update" auth="true">
<description>Update a ProductPromoProduct</description>
<permission-service service-name="productPriceGenericPermission" main-action="UPDATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
</service>
<service name="deleteProductPromoProduct" default-entity-name="ProductPromoProduct" engine="entity-auto" invoke="delete" auth="true">
<description>Delete a ProductPromoProduct</description>
<permission-service service-name="productPriceGenericPermission" main-action="DELETE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
</service>
<service name="createProductPromoRule" default-entity-name="ProductPromoRule" engine="entity-auto" invoke="create" auth="true">
<description>Create a ProductPromo</description>
<permission-service service-name="productPriceGenericPermission" main-action="CREATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="false"/>
<override name="productPromoRuleId" mode="OUT"/>
</service>
<service name="updateProductPromoRule" default-entity-name="ProductPromoRule" engine="entity-auto" invoke="update" auth="true">
<description>Update a ProductPromo</description>
<permission-service service-name="productPriceGenericPermission" main-action="UPDATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="false"/>
</service>
<service name="deleteProductPromoRule" default-entity-name="ProductPromoRule" engine="entity-auto" invoke="delete" auth="true">
<description>Delete a ProductPromo</description>
<permission-service service-name="productPriceGenericPermission" main-action="DELETE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
</service>
<service name="calculatePurchasePrice" engine="java"
location="org.apache.ofbiz.product.price.PriceServices" invoke="calculatePurchasePrice" auth="false" use-transaction="false">
<description>Calculate a Product's Purchase Price</description>
<attribute name="product" type="org.apache.ofbiz.entity.GenericValue" mode="IN" optional="false"/>
<attribute name="currencyUomId" type="String" mode="IN" optional="false"/>
<attribute name="partyId" type="String" mode="IN" optional="true"/>
<attribute name="quantity" type="BigDecimal" mode="IN" optional="true"/>
<attribute name="amount" type="BigDecimal" mode="IN" optional="true"/>
<attribute name="price" type="BigDecimal" mode="OUT" optional="false"/>
<attribute name="validPriceFound" type="Boolean" mode="OUT" optional="false"/>
<attribute name="orderItemPriceInfos" type="java.util.List" mode="OUT" optional="false"/>
</service>
<service name="getAssociatedPriceRulesConds" engine="simple" auth="false"
location="component://product/minilang/product/price/PriceServices.xml" invoke="getAssociatedPriceRulesConds">
<description>Set the Value options for selected Price Rule Condition Input</description>
<attribute name="inputParamEnumId" mode="IN" type="String"/>
<attribute name="productPriceRulesCondValues" mode="OUT" type="java.util.List" optional="true"/><!-- optional="true" because of quantity or other kind of fiels needing an input -->
</service>
<!-- ProductPriceActionType services -->
<service name="createProductPriceActionType" default-entity-name="ProductPriceActionType" engine="entity-auto" invoke="create" auth="true">
<description>Create a ProductPriceActionType</description>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
<auto-attributes include="pk" mode="INOUT" optional="true"/>
</service>
<service name="updateProductPriceActionType" default-entity-name="ProductPriceActionType" engine="entity-auto" invoke="update" auth="true">
<description>Update a ProductPriceActionType</description>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
</service>
<service name="deleteProductPriceActionType" default-entity-name="ProductPriceActionType" engine="entity-auto" invoke="delete" auth="true">
<description>Delete a ProductPriceActionType</description>
<auto-attributes include="pk" mode="IN" optional="false"/>
</service>
<!-- ProductPriceAutoNotice services -->
<service name="createProductPriceAutoNotice" default-entity-name="ProductPriceAutoNotice" engine="entity-auto" invoke="create" auth="true">
<description>Create a ProductPriceAutoNotice</description>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
<auto-attributes include="pk" mode="INOUT" optional="true"/>
</service>
<service name="updateProductPriceAutoNotice" default-entity-name="ProductPriceAutoNotice" engine="entity-auto" invoke="update" auth="true">
<description>Update a ProductPriceAutoNotice</description>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
</service>
<service name="deleteProductPriceAutoNotice" default-entity-name="ProductPriceAutoNotice" engine="entity-auto" invoke="delete" auth="true">
<description>Delete a ProductPriceAutoNotice</description>
<auto-attributes include="pk" mode="IN" optional="false"/>
</service>
</services>