首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >自定义输出wsdl nusoap

自定义输出wsdl nusoap
EN

Stack Overflow用户
提问于 2015-08-07 20:06:22
回答 1查看 633关注 0票数 0

我使用NuSoap/PHP,并希望进行自定义输出

我希望我的输出是这样的:

代码语言:javascript
运行
复制
            <xsd:element name="crearCentro">
            <xsd:complexType>
                <xsd:sequence>
                    <xsd:element maxOccurs="1" minOccurs="1" ref="entsal:DATOS_IDENTIFICATIVOS"/>
                </xsd:sequence>
            </xsd:complexType>
        </xsd:element>
        <xsd:element name="crearCentroResponse">
            <xsd:complexType>
                <xsd:sequence>
                    <xsd:element maxOccurs="1" minOccurs="1" ref="salida:RESPUESTA_DATOS_CENTRO"/>
                </xsd:sequence>
            </xsd:complexType>
        </xsd:element>

我明白了:

代码语言:javascript
运行
复制
<xsd:complexType name="crearCentro"/>
<xsd:element name="crearCentro" type="tns:crearCentro"/>

我有这个,我不知道我该怎么做:

代码语言:javascript
运行
复制
$server->wsdl->addElement(array('name' => 'crearCentro','type'=>'crearCentro' ));
$server->wsdl->addComplexType(
'crearCentro',
'sequence',
'struct',
'all');

谢谢!

EN

回答 1

Stack Overflow用户

发布于 2018-07-05 03:40:13

代码语言:javascript
运行
复制
$servicio->wsdl->addComplexType('Item', 
                                'complexType', 
                                'array', 
                                'sequence', 
                                '',
                                array('Placa' => array('name' => 'Placa','type' => 'xs:string'),
                                'cantidadItem' => array('name' => 'cantidadItem','type' => 'xs:decimal'),
                                'codigoProducto' => array('name' => 'codigoProducto','type' => 'xs:int'),
                                'descripcionItem' => array('name' => 'descripcionItem','type' => 'xs:string'),
                                'descuentoItem' => array('name' => 'descuentoItem','type' => 'xs:decimal'),
                                'igvItem' => array('name' => 'igvItem','type' => 'xs:decimal'),
                                'importe' => array('name' => 'importe','type' => 'xs:decimal'),
                                'monto' => array('name' => 'monto','type' => 'xs:decimal'),
                                'numeroItem' => array('name' => 'numeroItem','type' => 'xs:long'),
                                'precioUnitario' => array('name' => 'precioUnitario','type' => 'xs:decimal'),
                                'tipoOperacion' => array('name' => 'tipoOperacion','type' => 'xs:int'),
                                'unidadItem' => array('name' => 'unidadItem','type' => 'xs:string'),
                                'valor' => array('name' => 'valor','type' => 'xs:decimal'),
                                'valorUnitario' => array('name' => 'valorUnitario','type' => 'xs:decimal')
                                  )
);
票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/31877345

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档