我发送的 SOAP 消息是这样的:
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="http://www.acumatica.com/typed/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<SOAP-ENV:Body>
<ns1:Export>
<ns1:commands>
<ns1:Command xsi:type="ns1:Field">
<ns1:FieldName>InventoryCD</ns1:FieldName>
<ns1:ObjectName>Item</ns1:ObjectName>
<ns1:Value>InventoryID</ns1:Value>
<ns1:Commit>true</ns1:Commit>
<ns1:LinkedCommand xsi:type="ns1:Action">
<ns1:FieldName>Cancel</ns1:FieldName>
<ns1:ObjectName>Item</ns1:ObjectName>
<ns1:LinkedCommand xsi:type="ns1:Key">
<ns1:FieldName>InventoryCD</ns1:FieldName>
<ns1:ObjectName>Item</ns1:ObjectName>
<ns1:Value>=[Item.InventoryCD]</ns1:Value>
</ns1:LinkedCommand>
</ns1:LinkedCommand>
</ns1:Command>
<ns1:Command xsi:type="ns1:Field">
<ns1:FieldName>Descr</ns1:FieldName>
<ns1:ObjectName>Item</ns1:ObjectName>
<ns1:Value>Description</ns1:Value>
</ns1:Command>
</ns1:commands>
<ns1:filters>
<ns1:Filter>
<ns1:Field>
<ns1:FieldName>Descr</ns1:FieldName>
<ns1:ObjectName>Item</ns1:ObjectName>
</ns1:Field>
<ns1:Condition>Contain</ns1:Condition>
<ns1:Value>TEST</ns1:Value>
<ns1:OpenBrackets>0</ns1:OpenBrackets>
<ns1:CloseBrackets>0</ns1:CloseBrackets>
<ns1:Operator>And</ns1:Operator>
</ns1:Filter>
</ns1:filters>
<ns1:topCount>5</ns1:topCount>
<ns1:includeHeaders>false</ns1:includeHeaders>
<ns1:breakOnError>false</ns1:breakOnError>
</ns1:Export>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
我用来发送此消息的 PHP 代码是这样的:
<?php
$context = new Screen("<URL>", array('trace' => TRUE));
$login = new Login();
$login->name = "<LOGINUSER>";
$login->password = "<LOGINPASS>";
$context->Login($login);
$IN202500 = $context->GetSchema(new GetSchema());
$clear = $context->Clear(new Clear());
$IN202500content = $IN202500->GetSchemaResult;
$field = new Field();
$field->FieldName = $IN202500content->StockItemSummary->Description->FieldName;
$field->ObjectName = $IN202500content->StockItemSummary->Description->ObjectName;
$filter = new Filter();
$filter->Field = $field;
$filter->Condition = FilterCondition::Contain;
$filter->Value = "TEST";
$filter->Operator = FilterOperator::_And;
$filter->OpenBrackets = 0;
$filter->CloseBrackets = 0;
$export = new Export();
$export->commands = array(
$IN202500content->StockItemSummary->InventoryID,
$IN202500content->StockItemSummary->Description
);
$export->topCount = 5;
$export->includeHeaders = false;
$export->breakOnError = false;
$export->filters = array(
$filter
);
$export_result = $context->Export($export);
?>
我收到的响应与未设置过滤器的结果相同。如何过滤描述子字符串的结果?