View Issue Details

IDProjectCategoryView StatusLast Update
0005786OXID ERP InterfaceOXID ERP Interface - subpublic2015-05-12 15:15
Reportermartinwegele Assigned To 
PriorityhighSeveritymajorReproducibilityalways
Status resolvedResolutionfixed 
Product Version2.12.0 
Fixed in Version2.14.1 
Summary0005786: Assigned attributes are not removed from product
DescriptionWhen using the SOAP method OXERPSetArticleAttributes all old assignments of attributes to the product that is being edited should be removed according to the documentation (7.82 on page 42).
Since module version 2.12.0 this does not work any more. OXERPSetArticleAttributes will only remove the most recently assigned attribute from the product. All other assigned attributes will stay.
So there is no possibility to get rid of old attribute assignments via the SOAP interface!
Steps To Reproduce

  1. Install the shop with demodata
  2. Install ERP module 2.12.0 or 2.13.0
  3. Make the OXERPLogin call
  4. Call OXERPGetArticleAttributes for the product Kite Core GTS (see below for example)
  5. You will get two OXERPType objects as a result (cp. demodata: https://github.com/OXID-eSales/oxideshop_ce/blob/v4.8.6/source/setup/sql/demodata.sql#L3894 and https://github.com/OXID-eSales/oxideshop_ce/blob/v4.8.6/source/setup/sql/demodata.sql#L3913
  6. Compare it in the database table oxobject2attribute:
    SELECT *
    FROM `oxobject2attribute`
    WHERE `OXOBJECTID` = 'b56369b1fc9d7b97f9c5fc343b349ece';
  7. Now add one new attribute assignment by calling OXERPSetArticleAttributes (see below for example).
  8. Repeat the OXERPGetArticleAttributes call.
  9. You will still get two results although there should only be one assigned attribute for this product now.
  10. Compare it in the database table oxobject2attribute:
    SELECT *
    FROM `oxobject2attribute`
    WHERE `OXOBJECTID` = 'b56369b1fc9d7b97f9c5fc343b349ece';

You can repeat this over and over again. OXERPSetArticleAttributes will only remove the most recent assignment from oxobject2attribute so the count of assigned attributes will stay two forever.
Additional Information
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:oxer="OXERPService">
   <soapenv:Header/>
   <soapenv:Body>
      <oxer:OXERPGetArticleAttributes>
         <oxer:sSessionID>insert session id from OXERPLogin call</oxer:sSessionID>         <oxer:sArticleID>b56369b1fc9d7b97f9c5fc343b349ece</oxer:sArticleID>     
      </oxer:OXERPGetArticleAttributes>
   </soapenv:Body>
</soapenv:Envelope>


<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:oxer="OXERPService">
   <soapenv:Header/>
   <soapenv:Body>
      <oxer:OXERPSetArticleAttributes>       
         <oxer:sSessionID>insert session id from OXERPLogin call</oxer:sSessionID>
         <oxer:sArticleID>b56369b1fc9d7b97f9c5fc343b349ece</oxer:sArticleID> 
          <oxer:aAttributes>
            <!--adding one attribute-->
            <oxer:OXERPType>             
               <oxer:aResult>
                  <oxer:ArrayOfString>
                     <oxer:string>OXID</oxer:string>
                     <oxer:string>8a142c3e9cd961518.80299776</oxer:string>
                  </oxer:ArrayOfString>
                    <oxer:ArrayOfString>
                     <oxer:string>OXVALUE</oxer:string>
                     <oxer:string>test</oxer:string>
                  </oxer:ArrayOfString>
               </oxer:aResult>
               <oxer:blResult>true</oxer:blResult>             
               <oxer:sMessage></oxer:sMessage>
            </oxer:OXERPType>
         </oxer:aAttributes>
      </oxer:OXERPSetArticleAttributes>
   </soapenv:Body>
</soapenv:Envelope>
TagsAttributes, Enterprise

Relationships

related to 0005123 resolvedLinas Kukulskis International language sets for oxobject2attribute grow with unreferenced entries 
related to 0004812 resolvedarturas.sevcenko Article attributes can't be saved to _set tables 
related to 0004756 resolvedarturas.sevcenko attribute methods are not working with _set1, set2 tables for many languages case 
related to 0006058 resolvedaurimas.gladutis MySQL error in OXERPSetArticleAttributes if table name contains certain characters 

Activities

winkelmann

2014-12-17 09:07

reporter   ~0010533

Hello, I just wanted to ask if there's already a fix for that prepared?