增加聚合支付托管下单

This commit is contained in:
2024-04-01 17:07:53 +08:00
parent 899d816bc3
commit f8299b36aa
1291 changed files with 220566 additions and 169 deletions

View File

@@ -0,0 +1,42 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class BindRequest extends \Yeepay\Yop\Sdk\Model\BaseRequest
{
/**
* @var
*/
private $body;
/**
* Gets body
*
* @return
*/
public function getBody()
{
return $this->body;
}
/**
* Sets body
*
* @param $body
* @return BindRequest
*/
public function setBody($body)
{
$this->body = $body;
return $this;
}
public static function getOperationId()
{
return 'bind';
}
}

View File

@@ -0,0 +1,80 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Http\Headers;
use Yeepay\Yop\Sdk\Internal\DefaultRequest;
use Yeepay\Yop\Sdk\Internal\Request;
use Yeepay\Yop\Sdk\Model\Transform\RequestMarshaller;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
use Yeepay\Yop\Sdk\Utils\UUIDUtils;
class BindRequestMarshaller implements RequestMarshaller
{
/**
* @var BindRequestMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new BindRequestMarshaller();
}
/**
* @return BindRequestMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @var string
*/
private $serviceName = 'Offline';
/**
* @var string
*/
private $httpMethod = 'POST';
/**
* @var string
*/
private $resourcePath = '/rest/v1.0/offline/bind';
/**
* @var string
*/
private $contentType = 'application/json';
/**
* @param BindRequest $request
* @return Request
*/
public function marshal($request)
{
$internalRequest = new DefaultRequest($this->serviceName);
$internalRequest->setResourcePath($this->resourcePath);
$internalRequest->setHttpMethod($this->httpMethod);
if (!empty($request->getRequestConfig()) && !empty($request->getRequestConfig()->getCustomRequestHeaders())) {
foreach ($request->getRequestConfig()->getCustomRequestHeaders() as $name => $value) {
$internalRequest->addHeader($name, $value);
}
}
if (!isset($internalRequest->getHeaders()[Headers::YOP_REQUEST_ID])) {
$internalRequest->addHeader(Headers::YOP_REQUEST_ID, UUIDUtils::uuid());
}
$content = (string)$request->getBody();
$internalRequest->setContent($content);
$internalRequest->addHeader(Headers::CONTENT_LENGTH, strlen($content));
$internalRequest->addHeader(Headers::CONTENT_TYPE, $this->contentType);
return $internalRequest;
}
}
BindRequestMarshaller::__init();

View File

@@ -0,0 +1,336 @@
<?php
/**
* BindRequestTerminalInfo
*
* PHP version 5
*
* @category Class
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* 线下业务
*
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: 1.0
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.13
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use \ArrayAccess;
use Yeepay\Yop\Sdk\Model\ModelInterface;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
/**
* BindRequestTerminalInfo Class Doc Comment
*
* @category Class
* @description 绑机信息列表
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class BindRequestTerminalInfo implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'BindRequestTerminalInfo';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'shopNo' => 'string',
'serialNo' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'shopNo' => null,
'serialNo' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'shopNo' => 'shopNo',
'serialNo' => 'serialNo'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'shopNo' => 'setShopNo',
'serialNo' => 'setSerialNo'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'shopNo' => 'getShopNo',
'serialNo' => 'getSerialNo'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['shopNo'] = isset($data['shopNo']) ? $data['shopNo'] : null;
$this->container['serialNo'] = isset($data['serialNo']) ? $data['serialNo'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['serialNo'] === null) {
$invalidProperties[] = "'serialNo' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return count($this->listInvalidProperties()) === 0;
}
/**
* Gets shopNo
*
* @return string
*/
public function getShopNo()
{
return $this->container['shopNo'];
}
/**
* Sets shopNo
*
* @param string $shopNo <pre>网点编号</pre>
*
* @return $this
*/
public function setShopNo($shopNo)
{
$this->container['shopNo'] = $shopNo;
return $this;
}
/**
* Gets serialNo
*
* @return string
*/
public function getSerialNo()
{
return $this->container['serialNo'];
}
/**
* Sets serialNo
*
* @param string $serialNo <p>终端序列号</p>
*
* @return $this
*/
public function setSerialNo($serialNo)
{
$this->container['serialNo'] = $serialNo;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@@ -0,0 +1,34 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class BindResponse extends \Yeepay\Yop\Sdk\Model\BaseResponse
{
/**
* @var YopBindTerminalResponseDto
*/
private $result;
function getResultClass()
{
return '\Yeepay\Yop\Sdk\Service\Offline\Model\YopBindTerminalResponseDto';
}
/**
* @param YopBindTerminalResponseDto $result
*/
function setResult($result)
{
$this->result = $result;
}
/**
* @return YopBindTerminalResponseDto
*/
function getResult()
{
return $this->result;
}
}

View File

@@ -0,0 +1,534 @@
<?php
/**
* BindResponseTerminalInfo
*
* PHP version 5
*
* @category Class
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* 线下业务
*
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: 1.0
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.13
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use \ArrayAccess;
use Yeepay\Yop\Sdk\Model\ModelInterface;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
/**
* BindResponseTerminalInfo Class Doc Comment
*
* @category Class
* @description 绑机响应参数中的终端信息
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class BindResponseTerminalInfo implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'BindResponseTerminalInfo';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'agentMerchantNo' => 'string',
'terminalNo' => 'string',
'shopName' => 'string',
'message' => 'string',
'shopNo' => 'string',
'merchantNo' => 'string',
'serialNo' => 'string',
'status' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'agentMerchantNo' => null,
'terminalNo' => null,
'shopName' => null,
'message' => null,
'shopNo' => null,
'merchantNo' => null,
'serialNo' => null,
'status' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'agentMerchantNo' => 'agentMerchantNo',
'terminalNo' => 'terminalNo',
'shopName' => 'shopName',
'message' => 'message',
'shopNo' => 'shopNo',
'merchantNo' => 'merchantNo',
'serialNo' => 'serialNo',
'status' => 'status'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'agentMerchantNo' => 'setAgentMerchantNo',
'terminalNo' => 'setTerminalNo',
'shopName' => 'setShopName',
'message' => 'setMessage',
'shopNo' => 'setShopNo',
'merchantNo' => 'setMerchantNo',
'serialNo' => 'setSerialNo',
'status' => 'setStatus'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'agentMerchantNo' => 'getAgentMerchantNo',
'terminalNo' => 'getTerminalNo',
'shopName' => 'getShopName',
'message' => 'getMessage',
'shopNo' => 'getShopNo',
'merchantNo' => 'getMerchantNo',
'serialNo' => 'getSerialNo',
'status' => 'getStatus'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['agentMerchantNo'] = isset($data['agentMerchantNo']) ? $data['agentMerchantNo'] : null;
$this->container['terminalNo'] = isset($data['terminalNo']) ? $data['terminalNo'] : null;
$this->container['shopName'] = isset($data['shopName']) ? $data['shopName'] : null;
$this->container['message'] = isset($data['message']) ? $data['message'] : null;
$this->container['shopNo'] = isset($data['shopNo']) ? $data['shopNo'] : null;
$this->container['merchantNo'] = isset($data['merchantNo']) ? $data['merchantNo'] : null;
$this->container['serialNo'] = isset($data['serialNo']) ? $data['serialNo'] : null;
$this->container['status'] = isset($data['status']) ? $data['status'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['agentMerchantNo'] === null) {
$invalidProperties[] = "'agentMerchantNo' can't be null";
}
if ($this->container['terminalNo'] === null) {
$invalidProperties[] = "'terminalNo' can't be null";
}
if ($this->container['shopName'] === null) {
$invalidProperties[] = "'shopName' can't be null";
}
if ($this->container['shopNo'] === null) {
$invalidProperties[] = "'shopNo' can't be null";
}
if ($this->container['merchantNo'] === null) {
$invalidProperties[] = "'merchantNo' can't be null";
}
if ($this->container['serialNo'] === null) {
$invalidProperties[] = "'serialNo' can't be null";
}
if ($this->container['status'] === null) {
$invalidProperties[] = "'status' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return count($this->listInvalidProperties()) === 0;
}
/**
* Gets agentMerchantNo
*
* @return string
*/
public function getAgentMerchantNo()
{
return $this->container['agentMerchantNo'];
}
/**
* Sets agentMerchantNo
*
* @param string $agentMerchantNo <div>采购商商编,指付款采购终端的商编</div>
*
* @return $this
*/
public function setAgentMerchantNo($agentMerchantNo)
{
$this->container['agentMerchantNo'] = $agentMerchantNo;
return $this;
}
/**
* Gets terminalNo
*
* @return string
*/
public function getTerminalNo()
{
return $this->container['terminalNo'];
}
/**
* Sets terminalNo
*
* @param string $terminalNo <pre>终端号</pre>
*
* @return $this
*/
public function setTerminalNo($terminalNo)
{
$this->container['terminalNo'] = $terminalNo;
return $this;
}
/**
* Gets shopName
*
* @return string
*/
public function getShopName()
{
return $this->container['shopName'];
}
/**
* Sets shopName
*
* @param string $shopName <pre>网点名称</pre>
*
* @return $this
*/
public function setShopName($shopName)
{
$this->container['shopName'] = $shopName;
return $this;
}
/**
* Gets message
*
* @return string
*/
public function getMessage()
{
return $this->container['message'];
}
/**
* Sets message
*
* @param string $message <pre>错误信息</pre>
*
* @return $this
*/
public function setMessage($message)
{
$this->container['message'] = $message;
return $this;
}
/**
* Gets shopNo
*
* @return string
*/
public function getShopNo()
{
return $this->container['shopNo'];
}
/**
* Sets shopNo
*
* @param string $shopNo <pre>网点编号</pre>
*
* @return $this
*/
public function setShopNo($shopNo)
{
$this->container['shopNo'] = $shopNo;
return $this;
}
/**
* Gets merchantNo
*
* @return string
*/
public function getMerchantNo()
{
return $this->container['merchantNo'];
}
/**
* Sets merchantNo
*
* @param string $merchantNo <pre>收单商编</pre>
*
* @return $this
*/
public function setMerchantNo($merchantNo)
{
$this->container['merchantNo'] = $merchantNo;
return $this;
}
/**
* Gets serialNo
*
* @return string
*/
public function getSerialNo()
{
return $this->container['serialNo'];
}
/**
* Sets serialNo
*
* @param string $serialNo <p>终端序列号</p>
*
* @return $this
*/
public function setSerialNo($serialNo)
{
$this->container['serialNo'] = $serialNo;
return $this;
}
/**
* Gets status
*
* @return string
*/
public function getStatus()
{
return $this->container['status'];
}
/**
* Sets status
*
* @param string $status <pre>绑定/解绑状态<br />SUCCESS成功<br />FAIL失败</pre> <p>&nbsp;</p>
*
* @return $this
*/
public function setStatus($status)
{
$this->container['status'] = $status;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@@ -0,0 +1,39 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Model\Transform\BaseResponseUnMarshaller;
class BindResponseUnMarshaller extends BaseResponseUnMarshaller
{
/**
* @var BindResponseUnMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new BindResponseUnMarshaller();
}
/**
* @return BindResponseUnMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @return BindResponse
*/
protected function getResponseInstance()
{
return new BindResponse();
}
}
BindResponseUnMarshaller::__init();

View File

@@ -0,0 +1,242 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class CreateShopRequest extends \Yeepay\Yop\Sdk\Model\BaseRequest
{
/**
* @var string
*/
private $address;
/**
* @var string
*/
private $province;
/**
* @var string
*/
private $city;
/**
* @var string
*/
private $district;
/**
* @var string
*/
private $mobile;
/**
* @var string
*/
private $shopName;
/**
* @var string
*/
private $parentMerchantNo;
/**
* @var string
*/
private $linkman;
/**
* @var string
*/
private $merchantNo;
/**
* Gets address
*
* @return string
*/
public function getAddress()
{
return $this->address;
}
/**
* Sets address
*
* @param string $address
* @return CreateShopRequest
*/
public function setAddress($address)
{
$this->address = $address;
return $this;
}
/**
* Gets province
*
* @return string
*/
public function getProvince()
{
return $this->province;
}
/**
* Sets province
*
* @param string $province
* @return CreateShopRequest
*/
public function setProvince($province)
{
$this->province = $province;
return $this;
}
/**
* Gets city
*
* @return string
*/
public function getCity()
{
return $this->city;
}
/**
* Sets city
*
* @param string $city
* @return CreateShopRequest
*/
public function setCity($city)
{
$this->city = $city;
return $this;
}
/**
* Gets district
*
* @return string
*/
public function getDistrict()
{
return $this->district;
}
/**
* Sets district
*
* @param string $district
* @return CreateShopRequest
*/
public function setDistrict($district)
{
$this->district = $district;
return $this;
}
/**
* Gets mobile
*
* @return string
*/
public function getMobile()
{
return $this->mobile;
}
/**
* Sets mobile
*
* @param string $mobile
* @return CreateShopRequest
*/
public function setMobile($mobile)
{
$this->mobile = $mobile;
return $this;
}
/**
* Gets shopName
*
* @return string
*/
public function getShopName()
{
return $this->shopName;
}
/**
* Sets shopName
*
* @param string $shopName
* @return CreateShopRequest
*/
public function setShopName($shopName)
{
$this->shopName = $shopName;
return $this;
}
/**
* Gets parentMerchantNo
*
* @return string
*/
public function getParentMerchantNo()
{
return $this->parentMerchantNo;
}
/**
* Sets parentMerchantNo
*
* @param string $parentMerchantNo
* @return CreateShopRequest
*/
public function setParentMerchantNo($parentMerchantNo)
{
$this->parentMerchantNo = $parentMerchantNo;
return $this;
}
/**
* Gets linkman
*
* @return string
*/
public function getLinkman()
{
return $this->linkman;
}
/**
* Sets linkman
*
* @param string $linkman
* @return CreateShopRequest
*/
public function setLinkman($linkman)
{
$this->linkman = $linkman;
return $this;
}
/**
* Gets merchantNo
*
* @return string
*/
public function getMerchantNo()
{
return $this->merchantNo;
}
/**
* Sets merchantNo
*
* @param string $merchantNo
* @return CreateShopRequest
*/
public function setMerchantNo($merchantNo)
{
$this->merchantNo = $merchantNo;
return $this;
}
public static function getOperationId()
{
return 'createShop';
}
}

View File

@@ -0,0 +1,104 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Http\Headers;
use Yeepay\Yop\Sdk\Internal\DefaultRequest;
use Yeepay\Yop\Sdk\Internal\Request;
use Yeepay\Yop\Sdk\Model\Transform\RequestMarshaller;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
use Yeepay\Yop\Sdk\Utils\UUIDUtils;
class CreateShopRequestMarshaller implements RequestMarshaller
{
/**
* @var CreateShopRequestMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new CreateShopRequestMarshaller();
}
/**
* @return CreateShopRequestMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @var string
*/
private $serviceName = 'Offline';
/**
* @var string
*/
private $httpMethod = 'POST';
/**
* @var string
*/
private $resourcePath = '/rest/v1.0/offline/create-shop';
/**
* @var string
*/
private $contentType = 'application/x-www-form-urlencoded';
/**
* @param CreateShopRequest $request
* @return Request
*/
public function marshal($request)
{
$internalRequest = new DefaultRequest($this->serviceName);
$internalRequest->setResourcePath($this->resourcePath);
$internalRequest->setHttpMethod($this->httpMethod);
if (!empty($request->getRequestConfig()) && !empty($request->getRequestConfig()->getCustomRequestHeaders())) {
foreach ($request->getRequestConfig()->getCustomRequestHeaders() as $name => $value) {
$internalRequest->addHeader($name, $value);
}
}
if (!isset($internalRequest->getHeaders()[Headers::YOP_REQUEST_ID])) {
$internalRequest->addHeader(Headers::YOP_REQUEST_ID, UUIDUtils::uuid());
}
if($request->getAddress() != null){
$internalRequest->addParameter('address', ObjectSerializer::sanitizeForSerialization($request->getAddress(), 'string'));
}
if($request->getProvince() != null){
$internalRequest->addParameter('province', ObjectSerializer::sanitizeForSerialization($request->getProvince(), 'string'));
}
if($request->getCity() != null){
$internalRequest->addParameter('city', ObjectSerializer::sanitizeForSerialization($request->getCity(), 'string'));
}
if($request->getDistrict() != null){
$internalRequest->addParameter('district', ObjectSerializer::sanitizeForSerialization($request->getDistrict(), 'string'));
}
if($request->getMobile() != null){
$internalRequest->addParameter('mobile', ObjectSerializer::sanitizeForSerialization($request->getMobile(), 'string'));
}
if($request->getShopName() != null){
$internalRequest->addParameter('shopName', ObjectSerializer::sanitizeForSerialization($request->getShopName(), 'string'));
}
if($request->getParentMerchantNo() != null){
$internalRequest->addParameter('parentMerchantNo', ObjectSerializer::sanitizeForSerialization($request->getParentMerchantNo(), 'string'));
}
if($request->getLinkman() != null){
$internalRequest->addParameter('linkman', ObjectSerializer::sanitizeForSerialization($request->getLinkman(), 'string'));
}
if($request->getMerchantNo() != null){
$internalRequest->addParameter('merchantNo', ObjectSerializer::sanitizeForSerialization($request->getMerchantNo(), 'string'));
}
$internalRequest->addHeader(Headers::CONTENT_TYPE, $this->contentType);
return $internalRequest;
}
}
CreateShopRequestMarshaller::__init();

View File

@@ -0,0 +1,34 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class CreateShopResponse extends \Yeepay\Yop\Sdk\Model\BaseResponse
{
/**
* @var YopCreateShopRspDTO
*/
private $result;
function getResultClass()
{
return '\Yeepay\Yop\Sdk\Service\Offline\Model\YopCreateShopRspDTO';
}
/**
* @param YopCreateShopRspDTO $result
*/
function setResult($result)
{
$this->result = $result;
}
/**
* @return YopCreateShopRspDTO
*/
function getResult()
{
return $this->result;
}
}

View File

@@ -0,0 +1,39 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Model\Transform\BaseResponseUnMarshaller;
class CreateShopResponseUnMarshaller extends BaseResponseUnMarshaller
{
/**
* @var CreateShopResponseUnMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new CreateShopResponseUnMarshaller();
}
/**
* @return CreateShopResponseUnMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @return CreateShopResponse
*/
protected function getResponseInstance()
{
return new CreateShopResponse();
}
}
CreateShopResponseUnMarshaller::__init();

View File

@@ -0,0 +1,142 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class GetShopRequest extends \Yeepay\Yop\Sdk\Model\BaseRequest
{
/**
* @var string
*/
private $parentMerchantNo;
/**
* @var string
*/
private $merchantNo;
/**
* @var string
*/
private $shopName;
/**
* @var string
*/
private $shopNo;
/**
* @var string
*/
private $status;
/**
* Gets parentMerchantNo
*
* @return string
*/
public function getParentMerchantNo()
{
return $this->parentMerchantNo;
}
/**
* Sets parentMerchantNo
*
* @param string $parentMerchantNo
* @return GetShopRequest
*/
public function setParentMerchantNo($parentMerchantNo)
{
$this->parentMerchantNo = $parentMerchantNo;
return $this;
}
/**
* Gets merchantNo
*
* @return string
*/
public function getMerchantNo()
{
return $this->merchantNo;
}
/**
* Sets merchantNo
*
* @param string $merchantNo
* @return GetShopRequest
*/
public function setMerchantNo($merchantNo)
{
$this->merchantNo = $merchantNo;
return $this;
}
/**
* Gets shopName
*
* @return string
*/
public function getShopName()
{
return $this->shopName;
}
/**
* Sets shopName
*
* @param string $shopName
* @return GetShopRequest
*/
public function setShopName($shopName)
{
$this->shopName = $shopName;
return $this;
}
/**
* Gets shopNo
*
* @return string
*/
public function getShopNo()
{
return $this->shopNo;
}
/**
* Sets shopNo
*
* @param string $shopNo
* @return GetShopRequest
*/
public function setShopNo($shopNo)
{
$this->shopNo = $shopNo;
return $this;
}
/**
* Gets status
*
* @return string
*/
public function getStatus()
{
return $this->status;
}
/**
* Sets status
*
* @param string $status
* @return GetShopRequest
*/
public function setStatus($status)
{
$this->status = $status;
return $this;
}
public static function getOperationId()
{
return 'getShop';
}
}

View File

@@ -0,0 +1,92 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Http\Headers;
use Yeepay\Yop\Sdk\Internal\DefaultRequest;
use Yeepay\Yop\Sdk\Internal\Request;
use Yeepay\Yop\Sdk\Model\Transform\RequestMarshaller;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
use Yeepay\Yop\Sdk\Utils\UUIDUtils;
class GetShopRequestMarshaller implements RequestMarshaller
{
/**
* @var GetShopRequestMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new GetShopRequestMarshaller();
}
/**
* @return GetShopRequestMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @var string
*/
private $serviceName = 'Offline';
/**
* @var string
*/
private $httpMethod = 'GET';
/**
* @var string
*/
private $resourcePath = '/rest/v1.0/offline/get-shop';
/**
* @var string
*/
private $contentType = 'application/x-www-form-urlencoded';
/**
* @param GetShopRequest $request
* @return Request
*/
public function marshal($request)
{
$internalRequest = new DefaultRequest($this->serviceName);
$internalRequest->setResourcePath($this->resourcePath);
$internalRequest->setHttpMethod($this->httpMethod);
if (!empty($request->getRequestConfig()) && !empty($request->getRequestConfig()->getCustomRequestHeaders())) {
foreach ($request->getRequestConfig()->getCustomRequestHeaders() as $name => $value) {
$internalRequest->addHeader($name, $value);
}
}
if (!isset($internalRequest->getHeaders()[Headers::YOP_REQUEST_ID])) {
$internalRequest->addHeader(Headers::YOP_REQUEST_ID, UUIDUtils::uuid());
}
if($request->getParentMerchantNo() != null){
$internalRequest->addParameter('parentMerchantNo', ObjectSerializer::sanitizeForSerialization($request->getParentMerchantNo(), 'string'));
}
if($request->getMerchantNo() != null){
$internalRequest->addParameter('merchantNo', ObjectSerializer::sanitizeForSerialization($request->getMerchantNo(), 'string'));
}
if($request->getShopName() != null){
$internalRequest->addParameter('shopName', ObjectSerializer::sanitizeForSerialization($request->getShopName(), 'string'));
}
if($request->getShopNo() != null){
$internalRequest->addParameter('shopNo', ObjectSerializer::sanitizeForSerialization($request->getShopNo(), 'string'));
}
if($request->getStatus() != null){
$internalRequest->addParameter('status', ObjectSerializer::sanitizeForSerialization($request->getStatus(), 'string'));
}
$internalRequest->addHeader(Headers::CONTENT_TYPE, $this->contentType);
return $internalRequest;
}
}
GetShopRequestMarshaller::__init();

View File

@@ -0,0 +1,34 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class GetShopResponse extends \Yeepay\Yop\Sdk\Model\BaseResponse
{
/**
* @var YopGetShopRspDTO
*/
private $result;
function getResultClass()
{
return '\Yeepay\Yop\Sdk\Service\Offline\Model\YopGetShopRspDTO';
}
/**
* @param YopGetShopRspDTO $result
*/
function setResult($result)
{
$this->result = $result;
}
/**
* @return YopGetShopRspDTO
*/
function getResult()
{
return $this->result;
}
}

View File

@@ -0,0 +1,39 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Model\Transform\BaseResponseUnMarshaller;
class GetShopResponseUnMarshaller extends BaseResponseUnMarshaller
{
/**
* @var GetShopResponseUnMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new GetShopResponseUnMarshaller();
}
/**
* @return GetShopResponseUnMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @return GetShopResponse
*/
protected function getResponseInstance()
{
return new GetShopResponse();
}
}
GetShopResponseUnMarshaller::__init();

View File

@@ -0,0 +1,768 @@
<?php
/**
* GetShopRspDTO
*
* PHP version 5
*
* @category Class
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* 线下业务
*
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: 1.0
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.13
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use \ArrayAccess;
use Yeepay\Yop\Sdk\Model\ModelInterface;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
/**
* GetShopRspDTO Class Doc Comment
*
* @category Class
* @description 网点信息
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class GetShopRspDTO implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'GetShopRspDTO';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'address' => 'string',
'districtName' => 'string',
'city' => 'string',
'mobile' => 'string',
'shopName' => 'string',
'updateTime' => '\DateTime',
'linkman' => 'string',
'province' => 'string',
'cityName' => 'string',
'createTime' => '\DateTime',
'district' => 'string',
'provinceName' => 'string',
'shopNo' => 'string',
'merchantNo' => 'string',
'status' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'address' => null,
'districtName' => null,
'city' => null,
'mobile' => null,
'shopName' => null,
'updateTime' => 'date-time',
'linkman' => null,
'province' => null,
'cityName' => null,
'createTime' => 'date-time',
'district' => null,
'provinceName' => null,
'shopNo' => null,
'merchantNo' => null,
'status' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'address' => 'address',
'districtName' => 'districtName',
'city' => 'city',
'mobile' => 'mobile',
'shopName' => 'shopName',
'updateTime' => 'updateTime',
'linkman' => 'linkman',
'province' => 'province',
'cityName' => 'cityName',
'createTime' => 'createTime',
'district' => 'district',
'provinceName' => 'provinceName',
'shopNo' => 'shopNo',
'merchantNo' => 'merchantNo',
'status' => 'status'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'address' => 'setAddress',
'districtName' => 'setDistrictName',
'city' => 'setCity',
'mobile' => 'setMobile',
'shopName' => 'setShopName',
'updateTime' => 'setUpdateTime',
'linkman' => 'setLinkman',
'province' => 'setProvince',
'cityName' => 'setCityName',
'createTime' => 'setCreateTime',
'district' => 'setDistrict',
'provinceName' => 'setProvinceName',
'shopNo' => 'setShopNo',
'merchantNo' => 'setMerchantNo',
'status' => 'setStatus'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'address' => 'getAddress',
'districtName' => 'getDistrictName',
'city' => 'getCity',
'mobile' => 'getMobile',
'shopName' => 'getShopName',
'updateTime' => 'getUpdateTime',
'linkman' => 'getLinkman',
'province' => 'getProvince',
'cityName' => 'getCityName',
'createTime' => 'getCreateTime',
'district' => 'getDistrict',
'provinceName' => 'getProvinceName',
'shopNo' => 'getShopNo',
'merchantNo' => 'getMerchantNo',
'status' => 'getStatus'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['address'] = isset($data['address']) ? $data['address'] : null;
$this->container['districtName'] = isset($data['districtName']) ? $data['districtName'] : null;
$this->container['city'] = isset($data['city']) ? $data['city'] : null;
$this->container['mobile'] = isset($data['mobile']) ? $data['mobile'] : null;
$this->container['shopName'] = isset($data['shopName']) ? $data['shopName'] : null;
$this->container['updateTime'] = isset($data['updateTime']) ? $data['updateTime'] : null;
$this->container['linkman'] = isset($data['linkman']) ? $data['linkman'] : null;
$this->container['province'] = isset($data['province']) ? $data['province'] : null;
$this->container['cityName'] = isset($data['cityName']) ? $data['cityName'] : null;
$this->container['createTime'] = isset($data['createTime']) ? $data['createTime'] : null;
$this->container['district'] = isset($data['district']) ? $data['district'] : null;
$this->container['provinceName'] = isset($data['provinceName']) ? $data['provinceName'] : null;
$this->container['shopNo'] = isset($data['shopNo']) ? $data['shopNo'] : null;
$this->container['merchantNo'] = isset($data['merchantNo']) ? $data['merchantNo'] : null;
$this->container['status'] = isset($data['status']) ? $data['status'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['address'] === null) {
$invalidProperties[] = "'address' can't be null";
}
if ($this->container['districtName'] === null) {
$invalidProperties[] = "'districtName' can't be null";
}
if ($this->container['city'] === null) {
$invalidProperties[] = "'city' can't be null";
}
if ($this->container['mobile'] === null) {
$invalidProperties[] = "'mobile' can't be null";
}
if ($this->container['shopName'] === null) {
$invalidProperties[] = "'shopName' can't be null";
}
if ($this->container['updateTime'] === null) {
$invalidProperties[] = "'updateTime' can't be null";
}
if ($this->container['linkman'] === null) {
$invalidProperties[] = "'linkman' can't be null";
}
if ($this->container['province'] === null) {
$invalidProperties[] = "'province' can't be null";
}
if ($this->container['cityName'] === null) {
$invalidProperties[] = "'cityName' can't be null";
}
if ($this->container['createTime'] === null) {
$invalidProperties[] = "'createTime' can't be null";
}
if ($this->container['district'] === null) {
$invalidProperties[] = "'district' can't be null";
}
if ($this->container['provinceName'] === null) {
$invalidProperties[] = "'provinceName' can't be null";
}
if ($this->container['shopNo'] === null) {
$invalidProperties[] = "'shopNo' can't be null";
}
if ($this->container['merchantNo'] === null) {
$invalidProperties[] = "'merchantNo' can't be null";
}
if ($this->container['status'] === null) {
$invalidProperties[] = "'status' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return count($this->listInvalidProperties()) === 0;
}
/**
* Gets address
*
* @return string
*/
public function getAddress()
{
return $this->container['address'];
}
/**
* Sets address
*
* @param string $address <pre>网点详细地址</pre>
*
* @return $this
*/
public function setAddress($address)
{
$this->container['address'] = $address;
return $this;
}
/**
* Gets districtName
*
* @return string
*/
public function getDistrictName()
{
return $this->container['districtName'];
}
/**
* Sets districtName
*
* @param string $districtName <pre>网点所在区</pre>
*
* @return $this
*/
public function setDistrictName($districtName)
{
$this->container['districtName'] = $districtName;
return $this;
}
/**
* Gets city
*
* @return string
*/
public function getCity()
{
return $this->container['city'];
}
/**
* Sets city
*
* @param string $city <pre>网点所在市编码</pre>
*
* @return $this
*/
public function setCity($city)
{
$this->container['city'] = $city;
return $this;
}
/**
* Gets mobile
*
* @return string
*/
public function getMobile()
{
return $this->container['mobile'];
}
/**
* Sets mobile
*
* @param string $mobile <pre>联系手机</pre>
*
* @return $this
*/
public function setMobile($mobile)
{
$this->container['mobile'] = $mobile;
return $this;
}
/**
* Gets shopName
*
* @return string
*/
public function getShopName()
{
return $this->container['shopName'];
}
/**
* Sets shopName
*
* @param string $shopName <pre>网点名称</pre>
*
* @return $this
*/
public function setShopName($shopName)
{
$this->container['shopName'] = $shopName;
return $this;
}
/**
* Gets updateTime
*
* @return \DateTime
*/
public function getUpdateTime()
{
return $this->container['updateTime'];
}
/**
* Sets updateTime
*
* @param \DateTime $updateTime <pre>最后修改时间</pre>
*
* @return $this
*/
public function setUpdateTime($updateTime)
{
$this->container['updateTime'] = $updateTime;
return $this;
}
/**
* Gets linkman
*
* @return string
*/
public function getLinkman()
{
return $this->container['linkman'];
}
/**
* Sets linkman
*
* @param string $linkman <pre>联系人</pre>
*
* @return $this
*/
public function setLinkman($linkman)
{
$this->container['linkman'] = $linkman;
return $this;
}
/**
* Gets province
*
* @return string
*/
public function getProvince()
{
return $this->container['province'];
}
/**
* Sets province
*
* @param string $province <pre>网点所在省编码</pre>
*
* @return $this
*/
public function setProvince($province)
{
$this->container['province'] = $province;
return $this;
}
/**
* Gets cityName
*
* @return string
*/
public function getCityName()
{
return $this->container['cityName'];
}
/**
* Sets cityName
*
* @param string $cityName <pre>网点所在市</pre>
*
* @return $this
*/
public function setCityName($cityName)
{
$this->container['cityName'] = $cityName;
return $this;
}
/**
* Gets createTime
*
* @return \DateTime
*/
public function getCreateTime()
{
return $this->container['createTime'];
}
/**
* Sets createTime
*
* @param \DateTime $createTime <pre>创建时间</pre>
*
* @return $this
*/
public function setCreateTime($createTime)
{
$this->container['createTime'] = $createTime;
return $this;
}
/**
* Gets district
*
* @return string
*/
public function getDistrict()
{
return $this->container['district'];
}
/**
* Sets district
*
* @param string $district <pre>网点所在区编码</pre>
*
* @return $this
*/
public function setDistrict($district)
{
$this->container['district'] = $district;
return $this;
}
/**
* Gets provinceName
*
* @return string
*/
public function getProvinceName()
{
return $this->container['provinceName'];
}
/**
* Sets provinceName
*
* @param string $provinceName <pre>网点所在省</pre>
*
* @return $this
*/
public function setProvinceName($provinceName)
{
$this->container['provinceName'] = $provinceName;
return $this;
}
/**
* Gets shopNo
*
* @return string
*/
public function getShopNo()
{
return $this->container['shopNo'];
}
/**
* Sets shopNo
*
* @param string $shopNo <pre>网点编号</pre>
*
* @return $this
*/
public function setShopNo($shopNo)
{
$this->container['shopNo'] = $shopNo;
return $this;
}
/**
* Gets merchantNo
*
* @return string
*/
public function getMerchantNo()
{
return $this->container['merchantNo'];
}
/**
* Sets merchantNo
*
* @param string $merchantNo <p>收单商编</p>
*
* @return $this
*/
public function setMerchantNo($merchantNo)
{
$this->container['merchantNo'] = $merchantNo;
return $this;
}
/**
* Gets status
*
* @return string
*/
public function getStatus()
{
return $this->container['status'];
}
/**
* Sets status
*
* @param string $status <pre>网点状态<br />枚举值:<br /><em style=\"font-family: Verdana, Arial, Helvetica, sans-serif;\">PERMIT<em>活跃 <br /></em></em><em style=\"font-family: Verdana, Arial, Helvetica, sans-serif;\">FORBID<em>关闭</em></em></pre>
*
* @return $this
*/
public function setStatus($status)
{
$this->container['status'] = $status;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@@ -0,0 +1,117 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class OperateShopRequest extends \Yeepay\Yop\Sdk\Model\BaseRequest
{
/**
* @var string
*/
private $operateType;
/**
* @var string
*/
private $parentMerchantNo;
/**
* @var string
*/
private $shopNo;
/**
* @var string
*/
private $merchantNo;
/**
* Gets operateType
*
* @return string
*/
public function getOperateType()
{
return $this->operateType;
}
/**
* Sets operateType
*
* @param string $operateType
* @return OperateShopRequest
*/
public function setOperateType($operateType)
{
$this->operateType = $operateType;
return $this;
}
/**
* Gets parentMerchantNo
*
* @return string
*/
public function getParentMerchantNo()
{
return $this->parentMerchantNo;
}
/**
* Sets parentMerchantNo
*
* @param string $parentMerchantNo
* @return OperateShopRequest
*/
public function setParentMerchantNo($parentMerchantNo)
{
$this->parentMerchantNo = $parentMerchantNo;
return $this;
}
/**
* Gets shopNo
*
* @return string
*/
public function getShopNo()
{
return $this->shopNo;
}
/**
* Sets shopNo
*
* @param string $shopNo
* @return OperateShopRequest
*/
public function setShopNo($shopNo)
{
$this->shopNo = $shopNo;
return $this;
}
/**
* Gets merchantNo
*
* @return string
*/
public function getMerchantNo()
{
return $this->merchantNo;
}
/**
* Sets merchantNo
*
* @param string $merchantNo
* @return OperateShopRequest
*/
public function setMerchantNo($merchantNo)
{
$this->merchantNo = $merchantNo;
return $this;
}
public static function getOperationId()
{
return 'operateShop';
}
}

View File

@@ -0,0 +1,89 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Http\Headers;
use Yeepay\Yop\Sdk\Internal\DefaultRequest;
use Yeepay\Yop\Sdk\Internal\Request;
use Yeepay\Yop\Sdk\Model\Transform\RequestMarshaller;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
use Yeepay\Yop\Sdk\Utils\UUIDUtils;
class OperateShopRequestMarshaller implements RequestMarshaller
{
/**
* @var OperateShopRequestMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new OperateShopRequestMarshaller();
}
/**
* @return OperateShopRequestMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @var string
*/
private $serviceName = 'Offline';
/**
* @var string
*/
private $httpMethod = 'POST';
/**
* @var string
*/
private $resourcePath = '/rest/v1.0/offline/operate-shop';
/**
* @var string
*/
private $contentType = 'application/x-www-form-urlencoded';
/**
* @param OperateShopRequest $request
* @return Request
*/
public function marshal($request)
{
$internalRequest = new DefaultRequest($this->serviceName);
$internalRequest->setResourcePath($this->resourcePath);
$internalRequest->setHttpMethod($this->httpMethod);
if (!empty($request->getRequestConfig()) && !empty($request->getRequestConfig()->getCustomRequestHeaders())) {
foreach ($request->getRequestConfig()->getCustomRequestHeaders() as $name => $value) {
$internalRequest->addHeader($name, $value);
}
}
if (!isset($internalRequest->getHeaders()[Headers::YOP_REQUEST_ID])) {
$internalRequest->addHeader(Headers::YOP_REQUEST_ID, UUIDUtils::uuid());
}
if($request->getOperateType() != null){
$internalRequest->addParameter('operateType', ObjectSerializer::sanitizeForSerialization($request->getOperateType(), 'string'));
}
if($request->getParentMerchantNo() != null){
$internalRequest->addParameter('parentMerchantNo', ObjectSerializer::sanitizeForSerialization($request->getParentMerchantNo(), 'string'));
}
if($request->getShopNo() != null){
$internalRequest->addParameter('shopNo', ObjectSerializer::sanitizeForSerialization($request->getShopNo(), 'string'));
}
if($request->getMerchantNo() != null){
$internalRequest->addParameter('merchantNo', ObjectSerializer::sanitizeForSerialization($request->getMerchantNo(), 'string'));
}
$internalRequest->addHeader(Headers::CONTENT_TYPE, $this->contentType);
return $internalRequest;
}
}
OperateShopRequestMarshaller::__init();

View File

@@ -0,0 +1,34 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class OperateShopResponse extends \Yeepay\Yop\Sdk\Model\BaseResponse
{
/**
* @var YopBaseRspDTO
*/
private $result;
function getResultClass()
{
return '\Yeepay\Yop\Sdk\Service\Offline\Model\YopBaseRspDTO';
}
/**
* @param YopBaseRspDTO $result
*/
function setResult($result)
{
$this->result = $result;
}
/**
* @return YopBaseRspDTO
*/
function getResult()
{
return $this->result;
}
}

View File

@@ -0,0 +1,39 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Model\Transform\BaseResponseUnMarshaller;
class OperateShopResponseUnMarshaller extends BaseResponseUnMarshaller
{
/**
* @var OperateShopResponseUnMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new OperateShopResponseUnMarshaller();
}
/**
* @return OperateShopResponseUnMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @return OperateShopResponse
*/
protected function getResponseInstance()
{
return new OperateShopResponse();
}
}
OperateShopResponseUnMarshaller::__init();

View File

@@ -0,0 +1,117 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class QueryAgentListRequest extends \Yeepay\Yop\Sdk\Model\BaseRequest
{
/**
* @var string
*/
private $agentMerchantNo;
/**
* @var string
*/
private $parentMerchantNo;
/**
* @var string
*/
private $terminalNo;
/**
* @var string
*/
private $serialNo;
/**
* Gets agentMerchantNo
*
* @return string
*/
public function getAgentMerchantNo()
{
return $this->agentMerchantNo;
}
/**
* Sets agentMerchantNo
*
* @param string $agentMerchantNo
* @return QueryAgentListRequest
*/
public function setAgentMerchantNo($agentMerchantNo)
{
$this->agentMerchantNo = $agentMerchantNo;
return $this;
}
/**
* Gets parentMerchantNo
*
* @return string
*/
public function getParentMerchantNo()
{
return $this->parentMerchantNo;
}
/**
* Sets parentMerchantNo
*
* @param string $parentMerchantNo
* @return QueryAgentListRequest
*/
public function setParentMerchantNo($parentMerchantNo)
{
$this->parentMerchantNo = $parentMerchantNo;
return $this;
}
/**
* Gets terminalNo
*
* @return string
*/
public function getTerminalNo()
{
return $this->terminalNo;
}
/**
* Sets terminalNo
*
* @param string $terminalNo
* @return QueryAgentListRequest
*/
public function setTerminalNo($terminalNo)
{
$this->terminalNo = $terminalNo;
return $this;
}
/**
* Gets serialNo
*
* @return string
*/
public function getSerialNo()
{
return $this->serialNo;
}
/**
* Sets serialNo
*
* @param string $serialNo
* @return QueryAgentListRequest
*/
public function setSerialNo($serialNo)
{
$this->serialNo = $serialNo;
return $this;
}
public static function getOperationId()
{
return 'queryAgentList';
}
}

View File

@@ -0,0 +1,89 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Http\Headers;
use Yeepay\Yop\Sdk\Internal\DefaultRequest;
use Yeepay\Yop\Sdk\Internal\Request;
use Yeepay\Yop\Sdk\Model\Transform\RequestMarshaller;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
use Yeepay\Yop\Sdk\Utils\UUIDUtils;
class QueryAgentListRequestMarshaller implements RequestMarshaller
{
/**
* @var QueryAgentListRequestMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new QueryAgentListRequestMarshaller();
}
/**
* @return QueryAgentListRequestMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @var string
*/
private $serviceName = 'Offline';
/**
* @var string
*/
private $httpMethod = 'GET';
/**
* @var string
*/
private $resourcePath = '/rest/v1.0/offline/query-agent-list';
/**
* @var string
*/
private $contentType = 'application/x-www-form-urlencoded';
/**
* @param QueryAgentListRequest $request
* @return Request
*/
public function marshal($request)
{
$internalRequest = new DefaultRequest($this->serviceName);
$internalRequest->setResourcePath($this->resourcePath);
$internalRequest->setHttpMethod($this->httpMethod);
if (!empty($request->getRequestConfig()) && !empty($request->getRequestConfig()->getCustomRequestHeaders())) {
foreach ($request->getRequestConfig()->getCustomRequestHeaders() as $name => $value) {
$internalRequest->addHeader($name, $value);
}
}
if (!isset($internalRequest->getHeaders()[Headers::YOP_REQUEST_ID])) {
$internalRequest->addHeader(Headers::YOP_REQUEST_ID, UUIDUtils::uuid());
}
if($request->getAgentMerchantNo() != null){
$internalRequest->addParameter('agentMerchantNo', ObjectSerializer::sanitizeForSerialization($request->getAgentMerchantNo(), 'string'));
}
if($request->getParentMerchantNo() != null){
$internalRequest->addParameter('parentMerchantNo', ObjectSerializer::sanitizeForSerialization($request->getParentMerchantNo(), 'string'));
}
if($request->getTerminalNo() != null){
$internalRequest->addParameter('terminalNo', ObjectSerializer::sanitizeForSerialization($request->getTerminalNo(), 'string'));
}
if($request->getSerialNo() != null){
$internalRequest->addParameter('serialNo', ObjectSerializer::sanitizeForSerialization($request->getSerialNo(), 'string'));
}
$internalRequest->addHeader(Headers::CONTENT_TYPE, $this->contentType);
return $internalRequest;
}
}
QueryAgentListRequestMarshaller::__init();

View File

@@ -0,0 +1,34 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class QueryAgentListResponse extends \Yeepay\Yop\Sdk\Model\BaseResponse
{
/**
* @var YopQueryAgentRspDto
*/
private $result;
function getResultClass()
{
return '\Yeepay\Yop\Sdk\Service\Offline\Model\YopQueryAgentRspDto';
}
/**
* @param YopQueryAgentRspDto $result
*/
function setResult($result)
{
$this->result = $result;
}
/**
* @return YopQueryAgentRspDto
*/
function getResult()
{
return $this->result;
}
}

View File

@@ -0,0 +1,39 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Model\Transform\BaseResponseUnMarshaller;
class QueryAgentListResponseUnMarshaller extends BaseResponseUnMarshaller
{
/**
* @var QueryAgentListResponseUnMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new QueryAgentListResponseUnMarshaller();
}
/**
* @return QueryAgentListResponseUnMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @return QueryAgentListResponse
*/
protected function getResponseInstance()
{
return new QueryAgentListResponse();
}
}
QueryAgentListResponseUnMarshaller::__init();

View File

@@ -0,0 +1,67 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class QueryOrderInfoRequest extends \Yeepay\Yop\Sdk\Model\BaseRequest
{
/**
* @var string
*/
private $orderId;
/**
* @var string
*/
private $merchantNo;
/**
* Gets orderId
*
* @return string
*/
public function getOrderId()
{
return $this->orderId;
}
/**
* Sets orderId
*
* @param string $orderId
* @return QueryOrderInfoRequest
*/
public function setOrderId($orderId)
{
$this->orderId = $orderId;
return $this;
}
/**
* Gets merchantNo
*
* @return string
*/
public function getMerchantNo()
{
return $this->merchantNo;
}
/**
* Sets merchantNo
*
* @param string $merchantNo
* @return QueryOrderInfoRequest
*/
public function setMerchantNo($merchantNo)
{
$this->merchantNo = $merchantNo;
return $this;
}
public static function getOperationId()
{
return 'queryOrderInfo';
}
}

View File

@@ -0,0 +1,83 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Http\Headers;
use Yeepay\Yop\Sdk\Internal\DefaultRequest;
use Yeepay\Yop\Sdk\Internal\Request;
use Yeepay\Yop\Sdk\Model\Transform\RequestMarshaller;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
use Yeepay\Yop\Sdk\Utils\UUIDUtils;
class QueryOrderInfoRequestMarshaller implements RequestMarshaller
{
/**
* @var QueryOrderInfoRequestMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new QueryOrderInfoRequestMarshaller();
}
/**
* @return QueryOrderInfoRequestMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @var string
*/
private $serviceName = 'Offline';
/**
* @var string
*/
private $httpMethod = 'POST';
/**
* @var string
*/
private $resourcePath = '/rest/v1.0/offline/query-order-info';
/**
* @var string
*/
private $contentType = 'application/x-www-form-urlencoded';
/**
* @param QueryOrderInfoRequest $request
* @return Request
*/
public function marshal($request)
{
$internalRequest = new DefaultRequest($this->serviceName);
$internalRequest->setResourcePath($this->resourcePath);
$internalRequest->setHttpMethod($this->httpMethod);
if (!empty($request->getRequestConfig()) && !empty($request->getRequestConfig()->getCustomRequestHeaders())) {
foreach ($request->getRequestConfig()->getCustomRequestHeaders() as $name => $value) {
$internalRequest->addHeader($name, $value);
}
}
if (!isset($internalRequest->getHeaders()[Headers::YOP_REQUEST_ID])) {
$internalRequest->addHeader(Headers::YOP_REQUEST_ID, UUIDUtils::uuid());
}
if($request->getOrderId() != null){
$internalRequest->addParameter('orderId', ObjectSerializer::sanitizeForSerialization($request->getOrderId(), 'string'));
}
if($request->getMerchantNo() != null){
$internalRequest->addParameter('merchantNo', ObjectSerializer::sanitizeForSerialization($request->getMerchantNo(), 'string'));
}
$internalRequest->addHeader(Headers::CONTENT_TYPE, $this->contentType);
return $internalRequest;
}
}
QueryOrderInfoRequestMarshaller::__init();

View File

@@ -0,0 +1,34 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class QueryOrderInfoResponse extends \Yeepay\Yop\Sdk\Model\BaseResponse
{
/**
* @var YopQueryOrderInfoRespDTO
*/
private $result;
function getResultClass()
{
return '\Yeepay\Yop\Sdk\Service\Offline\Model\YopQueryOrderInfoRespDTO';
}
/**
* @param YopQueryOrderInfoRespDTO $result
*/
function setResult($result)
{
$this->result = $result;
}
/**
* @return YopQueryOrderInfoRespDTO
*/
function getResult()
{
return $this->result;
}
}

View File

@@ -0,0 +1,39 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Model\Transform\BaseResponseUnMarshaller;
class QueryOrderInfoResponseUnMarshaller extends BaseResponseUnMarshaller
{
/**
* @var QueryOrderInfoResponseUnMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new QueryOrderInfoResponseUnMarshaller();
}
/**
* @return QueryOrderInfoResponseUnMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @return QueryOrderInfoResponse
*/
protected function getResponseInstance()
{
return new QueryOrderInfoResponse();
}
}
QueryOrderInfoResponseUnMarshaller::__init();

View File

@@ -0,0 +1,67 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class QueryPosTrxInfoRequest extends \Yeepay\Yop\Sdk\Model\BaseRequest
{
/**
* @var string
*/
private $orderId;
/**
* @var string
*/
private $merchantNo;
/**
* Gets orderId
*
* @return string
*/
public function getOrderId()
{
return $this->orderId;
}
/**
* Sets orderId
*
* @param string $orderId
* @return QueryPosTrxInfoRequest
*/
public function setOrderId($orderId)
{
$this->orderId = $orderId;
return $this;
}
/**
* Gets merchantNo
*
* @return string
*/
public function getMerchantNo()
{
return $this->merchantNo;
}
/**
* Sets merchantNo
*
* @param string $merchantNo
* @return QueryPosTrxInfoRequest
*/
public function setMerchantNo($merchantNo)
{
$this->merchantNo = $merchantNo;
return $this;
}
public static function getOperationId()
{
return 'queryPosTrxInfo';
}
}

View File

@@ -0,0 +1,83 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Http\Headers;
use Yeepay\Yop\Sdk\Internal\DefaultRequest;
use Yeepay\Yop\Sdk\Internal\Request;
use Yeepay\Yop\Sdk\Model\Transform\RequestMarshaller;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
use Yeepay\Yop\Sdk\Utils\UUIDUtils;
class QueryPosTrxInfoRequestMarshaller implements RequestMarshaller
{
/**
* @var QueryPosTrxInfoRequestMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new QueryPosTrxInfoRequestMarshaller();
}
/**
* @return QueryPosTrxInfoRequestMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @var string
*/
private $serviceName = 'Offline';
/**
* @var string
*/
private $httpMethod = 'POST';
/**
* @var string
*/
private $resourcePath = '/rest/v1.0/offline/query-order-info';
/**
* @var string
*/
private $contentType = 'application/x-www-form-urlencoded';
/**
* @param QueryPosTrxInfoRequest $request
* @return Request
*/
public function marshal($request)
{
$internalRequest = new DefaultRequest($this->serviceName);
$internalRequest->setResourcePath($this->resourcePath);
$internalRequest->setHttpMethod($this->httpMethod);
if (!empty($request->getRequestConfig()) && !empty($request->getRequestConfig()->getCustomRequestHeaders())) {
foreach ($request->getRequestConfig()->getCustomRequestHeaders() as $name => $value) {
$internalRequest->addHeader($name, $value);
}
}
if (!isset($internalRequest->getHeaders()[Headers::YOP_REQUEST_ID])) {
$internalRequest->addHeader(Headers::YOP_REQUEST_ID, UUIDUtils::uuid());
}
if($request->getOrderId() != null){
$internalRequest->addParameter('orderId', ObjectSerializer::sanitizeForSerialization($request->getOrderId(), 'string'));
}
if($request->getMerchantNo() != null){
$internalRequest->addParameter('merchantNo', ObjectSerializer::sanitizeForSerialization($request->getMerchantNo(), 'string'));
}
$internalRequest->addHeader(Headers::CONTENT_TYPE, $this->contentType);
return $internalRequest;
}
}
QueryPosTrxInfoRequestMarshaller::__init();

View File

@@ -0,0 +1,34 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class QueryPosTrxInfoResponse extends \Yeepay\Yop\Sdk\Model\BaseResponse
{
/**
* @var YopQueryOrderInfoRespDTO
*/
private $result;
function getResultClass()
{
return '\Yeepay\Yop\Sdk\Service\Offline\Model\YopQueryOrderInfoRespDTO';
}
/**
* @param YopQueryOrderInfoRespDTO $result
*/
function setResult($result)
{
$this->result = $result;
}
/**
* @return YopQueryOrderInfoRespDTO
*/
function getResult()
{
return $this->result;
}
}

View File

@@ -0,0 +1,39 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Model\Transform\BaseResponseUnMarshaller;
class QueryPosTrxInfoResponseUnMarshaller extends BaseResponseUnMarshaller
{
/**
* @var QueryPosTrxInfoResponseUnMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new QueryPosTrxInfoResponseUnMarshaller();
}
/**
* @return QueryPosTrxInfoResponseUnMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @return QueryPosTrxInfoResponse
*/
protected function getResponseInstance()
{
return new QueryPosTrxInfoResponse();
}
}
QueryPosTrxInfoResponseUnMarshaller::__init();

View File

@@ -0,0 +1,92 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class QueryShopBindListRequest extends \Yeepay\Yop\Sdk\Model\BaseRequest
{
/**
* @var string
*/
private $parentMerchantNo;
/**
* @var string
*/
private $shopNo;
/**
* @var string
*/
private $merchantNo;
/**
* Gets parentMerchantNo
*
* @return string
*/
public function getParentMerchantNo()
{
return $this->parentMerchantNo;
}
/**
* Sets parentMerchantNo
*
* @param string $parentMerchantNo
* @return QueryShopBindListRequest
*/
public function setParentMerchantNo($parentMerchantNo)
{
$this->parentMerchantNo = $parentMerchantNo;
return $this;
}
/**
* Gets shopNo
*
* @return string
*/
public function getShopNo()
{
return $this->shopNo;
}
/**
* Sets shopNo
*
* @param string $shopNo
* @return QueryShopBindListRequest
*/
public function setShopNo($shopNo)
{
$this->shopNo = $shopNo;
return $this;
}
/**
* Gets merchantNo
*
* @return string
*/
public function getMerchantNo()
{
return $this->merchantNo;
}
/**
* Sets merchantNo
*
* @param string $merchantNo
* @return QueryShopBindListRequest
*/
public function setMerchantNo($merchantNo)
{
$this->merchantNo = $merchantNo;
return $this;
}
public static function getOperationId()
{
return 'queryShopBindList';
}
}

View File

@@ -0,0 +1,86 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Http\Headers;
use Yeepay\Yop\Sdk\Internal\DefaultRequest;
use Yeepay\Yop\Sdk\Internal\Request;
use Yeepay\Yop\Sdk\Model\Transform\RequestMarshaller;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
use Yeepay\Yop\Sdk\Utils\UUIDUtils;
class QueryShopBindListRequestMarshaller implements RequestMarshaller
{
/**
* @var QueryShopBindListRequestMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new QueryShopBindListRequestMarshaller();
}
/**
* @return QueryShopBindListRequestMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @var string
*/
private $serviceName = 'Offline';
/**
* @var string
*/
private $httpMethod = 'GET';
/**
* @var string
*/
private $resourcePath = '/rest/v1.0/offline/query-shop-bind-list';
/**
* @var string
*/
private $contentType = 'application/x-www-form-urlencoded';
/**
* @param QueryShopBindListRequest $request
* @return Request
*/
public function marshal($request)
{
$internalRequest = new DefaultRequest($this->serviceName);
$internalRequest->setResourcePath($this->resourcePath);
$internalRequest->setHttpMethod($this->httpMethod);
if (!empty($request->getRequestConfig()) && !empty($request->getRequestConfig()->getCustomRequestHeaders())) {
foreach ($request->getRequestConfig()->getCustomRequestHeaders() as $name => $value) {
$internalRequest->addHeader($name, $value);
}
}
if (!isset($internalRequest->getHeaders()[Headers::YOP_REQUEST_ID])) {
$internalRequest->addHeader(Headers::YOP_REQUEST_ID, UUIDUtils::uuid());
}
if($request->getParentMerchantNo() != null){
$internalRequest->addParameter('parentMerchantNo', ObjectSerializer::sanitizeForSerialization($request->getParentMerchantNo(), 'string'));
}
if($request->getShopNo() != null){
$internalRequest->addParameter('shopNo', ObjectSerializer::sanitizeForSerialization($request->getShopNo(), 'string'));
}
if($request->getMerchantNo() != null){
$internalRequest->addParameter('merchantNo', ObjectSerializer::sanitizeForSerialization($request->getMerchantNo(), 'string'));
}
$internalRequest->addHeader(Headers::CONTENT_TYPE, $this->contentType);
return $internalRequest;
}
}
QueryShopBindListRequestMarshaller::__init();

View File

@@ -0,0 +1,34 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class QueryShopBindListResponse extends \Yeepay\Yop\Sdk\Model\BaseResponse
{
/**
* @var YopQueryShopBindRspDto
*/
private $result;
function getResultClass()
{
return '\Yeepay\Yop\Sdk\Service\Offline\Model\YopQueryShopBindRspDto';
}
/**
* @param YopQueryShopBindRspDto $result
*/
function setResult($result)
{
$this->result = $result;
}
/**
* @return YopQueryShopBindRspDto
*/
function getResult()
{
return $this->result;
}
}

View File

@@ -0,0 +1,39 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Model\Transform\BaseResponseUnMarshaller;
class QueryShopBindListResponseUnMarshaller extends BaseResponseUnMarshaller
{
/**
* @var QueryShopBindListResponseUnMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new QueryShopBindListResponseUnMarshaller();
}
/**
* @return QueryShopBindListResponseUnMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @return QueryShopBindListResponse
*/
protected function getResponseInstance()
{
return new QueryShopBindListResponse();
}
}
QueryShopBindListResponseUnMarshaller::__init();

View File

@@ -0,0 +1,42 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class UnbindRequest extends \Yeepay\Yop\Sdk\Model\BaseRequest
{
/**
* @var
*/
private $body;
/**
* Gets body
*
* @return
*/
public function getBody()
{
return $this->body;
}
/**
* Sets body
*
* @param $body
* @return UnbindRequest
*/
public function setBody($body)
{
$this->body = $body;
return $this;
}
public static function getOperationId()
{
return 'unbind';
}
}

View File

@@ -0,0 +1,80 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Http\Headers;
use Yeepay\Yop\Sdk\Internal\DefaultRequest;
use Yeepay\Yop\Sdk\Internal\Request;
use Yeepay\Yop\Sdk\Model\Transform\RequestMarshaller;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
use Yeepay\Yop\Sdk\Utils\UUIDUtils;
class UnbindRequestMarshaller implements RequestMarshaller
{
/**
* @var UnbindRequestMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new UnbindRequestMarshaller();
}
/**
* @return UnbindRequestMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @var string
*/
private $serviceName = 'Offline';
/**
* @var string
*/
private $httpMethod = 'POST';
/**
* @var string
*/
private $resourcePath = '/rest/v1.0/offline/unbind';
/**
* @var string
*/
private $contentType = 'application/json';
/**
* @param UnbindRequest $request
* @return Request
*/
public function marshal($request)
{
$internalRequest = new DefaultRequest($this->serviceName);
$internalRequest->setResourcePath($this->resourcePath);
$internalRequest->setHttpMethod($this->httpMethod);
if (!empty($request->getRequestConfig()) && !empty($request->getRequestConfig()->getCustomRequestHeaders())) {
foreach ($request->getRequestConfig()->getCustomRequestHeaders() as $name => $value) {
$internalRequest->addHeader($name, $value);
}
}
if (!isset($internalRequest->getHeaders()[Headers::YOP_REQUEST_ID])) {
$internalRequest->addHeader(Headers::YOP_REQUEST_ID, UUIDUtils::uuid());
}
$content = (string)$request->getBody();
$internalRequest->setContent($content);
$internalRequest->addHeader(Headers::CONTENT_LENGTH, strlen($content));
$internalRequest->addHeader(Headers::CONTENT_TYPE, $this->contentType);
return $internalRequest;
}
}
UnbindRequestMarshaller::__init();

View File

@@ -0,0 +1,34 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class UnbindResponse extends \Yeepay\Yop\Sdk\Model\BaseResponse
{
/**
* @var YopUnBindTerminalResponseDto
*/
private $result;
function getResultClass()
{
return '\Yeepay\Yop\Sdk\Service\Offline\Model\YopUnBindTerminalResponseDto';
}
/**
* @param YopUnBindTerminalResponseDto $result
*/
function setResult($result)
{
$this->result = $result;
}
/**
* @return YopUnBindTerminalResponseDto
*/
function getResult()
{
return $this->result;
}
}

View File

@@ -0,0 +1,39 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Model\Transform\BaseResponseUnMarshaller;
class UnbindResponseUnMarshaller extends BaseResponseUnMarshaller
{
/**
* @var UnbindResponseUnMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new UnbindResponseUnMarshaller();
}
/**
* @return UnbindResponseUnMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @return UnbindResponse
*/
protected function getResponseInstance()
{
return new UnbindResponse();
}
}
UnbindResponseUnMarshaller::__init();

View File

@@ -0,0 +1,167 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class UpdateShopRequest extends \Yeepay\Yop\Sdk\Model\BaseRequest
{
/**
* @var string
*/
private $address;
/**
* @var string
*/
private $mobile;
/**
* @var string
*/
private $parentMerchantNo;
/**
* @var string
*/
private $shopNo;
/**
* @var string
*/
private $linkman;
/**
* @var string
*/
private $merchantNo;
/**
* Gets address
*
* @return string
*/
public function getAddress()
{
return $this->address;
}
/**
* Sets address
*
* @param string $address
* @return UpdateShopRequest
*/
public function setAddress($address)
{
$this->address = $address;
return $this;
}
/**
* Gets mobile
*
* @return string
*/
public function getMobile()
{
return $this->mobile;
}
/**
* Sets mobile
*
* @param string $mobile
* @return UpdateShopRequest
*/
public function setMobile($mobile)
{
$this->mobile = $mobile;
return $this;
}
/**
* Gets parentMerchantNo
*
* @return string
*/
public function getParentMerchantNo()
{
return $this->parentMerchantNo;
}
/**
* Sets parentMerchantNo
*
* @param string $parentMerchantNo
* @return UpdateShopRequest
*/
public function setParentMerchantNo($parentMerchantNo)
{
$this->parentMerchantNo = $parentMerchantNo;
return $this;
}
/**
* Gets shopNo
*
* @return string
*/
public function getShopNo()
{
return $this->shopNo;
}
/**
* Sets shopNo
*
* @param string $shopNo
* @return UpdateShopRequest
*/
public function setShopNo($shopNo)
{
$this->shopNo = $shopNo;
return $this;
}
/**
* Gets linkman
*
* @return string
*/
public function getLinkman()
{
return $this->linkman;
}
/**
* Sets linkman
*
* @param string $linkman
* @return UpdateShopRequest
*/
public function setLinkman($linkman)
{
$this->linkman = $linkman;
return $this;
}
/**
* Gets merchantNo
*
* @return string
*/
public function getMerchantNo()
{
return $this->merchantNo;
}
/**
* Sets merchantNo
*
* @param string $merchantNo
* @return UpdateShopRequest
*/
public function setMerchantNo($merchantNo)
{
$this->merchantNo = $merchantNo;
return $this;
}
public static function getOperationId()
{
return 'updateShop';
}
}

View File

@@ -0,0 +1,95 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Http\Headers;
use Yeepay\Yop\Sdk\Internal\DefaultRequest;
use Yeepay\Yop\Sdk\Internal\Request;
use Yeepay\Yop\Sdk\Model\Transform\RequestMarshaller;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
use Yeepay\Yop\Sdk\Utils\UUIDUtils;
class UpdateShopRequestMarshaller implements RequestMarshaller
{
/**
* @var UpdateShopRequestMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new UpdateShopRequestMarshaller();
}
/**
* @return UpdateShopRequestMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @var string
*/
private $serviceName = 'Offline';
/**
* @var string
*/
private $httpMethod = 'POST';
/**
* @var string
*/
private $resourcePath = '/rest/v1.0/offline/update-shop';
/**
* @var string
*/
private $contentType = 'application/x-www-form-urlencoded';
/**
* @param UpdateShopRequest $request
* @return Request
*/
public function marshal($request)
{
$internalRequest = new DefaultRequest($this->serviceName);
$internalRequest->setResourcePath($this->resourcePath);
$internalRequest->setHttpMethod($this->httpMethod);
if (!empty($request->getRequestConfig()) && !empty($request->getRequestConfig()->getCustomRequestHeaders())) {
foreach ($request->getRequestConfig()->getCustomRequestHeaders() as $name => $value) {
$internalRequest->addHeader($name, $value);
}
}
if (!isset($internalRequest->getHeaders()[Headers::YOP_REQUEST_ID])) {
$internalRequest->addHeader(Headers::YOP_REQUEST_ID, UUIDUtils::uuid());
}
if($request->getAddress() != null){
$internalRequest->addParameter('address', ObjectSerializer::sanitizeForSerialization($request->getAddress(), 'string'));
}
if($request->getMobile() != null){
$internalRequest->addParameter('mobile', ObjectSerializer::sanitizeForSerialization($request->getMobile(), 'string'));
}
if($request->getParentMerchantNo() != null){
$internalRequest->addParameter('parentMerchantNo', ObjectSerializer::sanitizeForSerialization($request->getParentMerchantNo(), 'string'));
}
if($request->getShopNo() != null){
$internalRequest->addParameter('shopNo', ObjectSerializer::sanitizeForSerialization($request->getShopNo(), 'string'));
}
if($request->getLinkman() != null){
$internalRequest->addParameter('linkman', ObjectSerializer::sanitizeForSerialization($request->getLinkman(), 'string'));
}
if($request->getMerchantNo() != null){
$internalRequest->addParameter('merchantNo', ObjectSerializer::sanitizeForSerialization($request->getMerchantNo(), 'string'));
}
$internalRequest->addHeader(Headers::CONTENT_TYPE, $this->contentType);
return $internalRequest;
}
}
UpdateShopRequestMarshaller::__init();

View File

@@ -0,0 +1,34 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
class UpdateShopResponse extends \Yeepay\Yop\Sdk\Model\BaseResponse
{
/**
* @var YopBaseRspDTO
*/
private $result;
function getResultClass()
{
return '\Yeepay\Yop\Sdk\Service\Offline\Model\YopBaseRspDTO';
}
/**
* @param YopBaseRspDTO $result
*/
function setResult($result)
{
$this->result = $result;
}
/**
* @return YopBaseRspDTO
*/
function getResult()
{
return $this->result;
}
}

View File

@@ -0,0 +1,39 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use Yeepay\Yop\Sdk\Model\Transform\BaseResponseUnMarshaller;
class UpdateShopResponseUnMarshaller extends BaseResponseUnMarshaller
{
/**
* @var UpdateShopResponseUnMarshaller
*/
private static $instance;
public static function __init()
{
self::$instance = new UpdateShopResponseUnMarshaller();
}
/**
* @return UpdateShopResponseUnMarshaller
*/
public static function getInstance()
{
return self::$instance;
}
/**
* @return UpdateShopResponse
*/
protected function getResponseInstance()
{
return new UpdateShopResponse();
}
}
UpdateShopResponseUnMarshaller::__init();

View File

@@ -0,0 +1,372 @@
<?php
/**
* YopBaseRspDTO
*
* PHP version 5
*
* @category Class
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* 线下业务
*
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: 1.0
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.13
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use \ArrayAccess;
use Yeepay\Yop\Sdk\Model\ModelInterface;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
/**
* YopBaseRspDTO Class Doc Comment
*
* @category Class
* @description yop基类
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class YopBaseRspDTO implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'YopBaseRspDTO';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'retCode' => 'string',
'retMsg' => 'string',
'timestamp' => '\DateTime'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'retCode' => null,
'retMsg' => null,
'timestamp' => 'date-time'
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'retCode' => 'retCode',
'retMsg' => 'retMsg',
'timestamp' => 'timestamp'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'retCode' => 'setRetCode',
'retMsg' => 'setRetMsg',
'timestamp' => 'setTimestamp'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'retCode' => 'getRetCode',
'retMsg' => 'getRetMsg',
'timestamp' => 'getTimestamp'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['retCode'] = isset($data['retCode']) ? $data['retCode'] : null;
$this->container['retMsg'] = isset($data['retMsg']) ? $data['retMsg'] : null;
$this->container['timestamp'] = isset($data['timestamp']) ? $data['timestamp'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['retCode'] === null) {
$invalidProperties[] = "'retCode' can't be null";
}
if ($this->container['retMsg'] === null) {
$invalidProperties[] = "'retMsg' can't be null";
}
if ($this->container['timestamp'] === null) {
$invalidProperties[] = "'timestamp' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return count($this->listInvalidProperties()) === 0;
}
/**
* Gets retCode
*
* @return string
*/
public function getRetCode()
{
return $this->container['retCode'];
}
/**
* Sets retCode
*
* @param string $retCode <p>返回码</p>
*
* @return $this
*/
public function setRetCode($retCode)
{
$this->container['retCode'] = $retCode;
return $this;
}
/**
* Gets retMsg
*
* @return string
*/
public function getRetMsg()
{
return $this->container['retMsg'];
}
/**
* Sets retMsg
*
* @param string $retMsg <p>返回信息</p>
*
* @return $this
*/
public function setRetMsg($retMsg)
{
$this->container['retMsg'] = $retMsg;
return $this;
}
/**
* Gets timestamp
*
* @return \DateTime
*/
public function getTimestamp()
{
return $this->container['timestamp'];
}
/**
* Sets timestamp
*
* @param \DateTime $timestamp <p>时间戳</p>
*
* @return $this
*/
public function setTimestamp($timestamp)
{
$this->container['timestamp'] = $timestamp;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@@ -0,0 +1,369 @@
<?php
/**
* YopBindTerminalRequestDto
*
* PHP version 5
*
* @category Class
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* 线下业务
*
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: 1.0
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.13
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use \ArrayAccess;
use Yeepay\Yop\Sdk\Model\ModelInterface;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
/**
* YopBindTerminalRequestDto Class Doc Comment
*
* @category Class
* @description yop绑机请求参数
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class YopBindTerminalRequestDto implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'YopBindTerminalRequestDto';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'parentMerchantNo' => 'string',
'terminalInfo' => '\Yeepay\Yop\Sdk\Service\Offline\Model\BindRequestTerminalInfo[]',
'merchantNo' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'parentMerchantNo' => null,
'terminalInfo' => null,
'merchantNo' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'parentMerchantNo' => 'parentMerchantNo',
'terminalInfo' => 'terminalInfo',
'merchantNo' => 'merchantNo'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'parentMerchantNo' => 'setParentMerchantNo',
'terminalInfo' => 'setTerminalInfo',
'merchantNo' => 'setMerchantNo'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'parentMerchantNo' => 'getParentMerchantNo',
'terminalInfo' => 'getTerminalInfo',
'merchantNo' => 'getMerchantNo'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['parentMerchantNo'] = isset($data['parentMerchantNo']) ? $data['parentMerchantNo'] : null;
$this->container['terminalInfo'] = isset($data['terminalInfo']) ? $data['terminalInfo'] : null;
$this->container['merchantNo'] = isset($data['merchantNo']) ? $data['merchantNo'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['terminalInfo'] === null) {
$invalidProperties[] = "'terminalInfo' can't be null";
}
if ($this->container['merchantNo'] === null) {
$invalidProperties[] = "'merchantNo' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return count($this->listInvalidProperties()) === 0;
}
/**
* Gets parentMerchantNo
*
* @return string
*/
public function getParentMerchantNo()
{
return $this->container['parentMerchantNo'];
}
/**
* Sets parentMerchantNo
*
* @param string $parentMerchantNo <div>发起方商户编号。*标准商户收付款方案中此参数与收款商户编号一致;*平台商户收付款方案中此参数为平台商商户编号;*服务商解决方案中,①标准商户收款时,该参数为标准商户商编 ②平台商收款或平台商入驻商户收款时,该参数为平台商商编</div>
*
* @return $this
*/
public function setParentMerchantNo($parentMerchantNo)
{
$this->container['parentMerchantNo'] = $parentMerchantNo;
return $this;
}
/**
* Gets terminalInfo
*
* @return \Yeepay\Yop\Sdk\Service\Offline\Model\BindRequestTerminalInfo[]
*/
public function getTerminalInfo()
{
return $this->container['terminalInfo'];
}
/**
* Sets terminalInfo
*
* @param \Yeepay\Yop\Sdk\Service\Offline\Model\BindRequestTerminalInfo[] $terminalInfo <pre>终端绑机信息列表</pre>
*
* @return $this
*/
public function setTerminalInfo($terminalInfo)
{
$this->container['terminalInfo'] = $terminalInfo;
return $this;
}
/**
* Gets merchantNo
*
* @return string
*/
public function getMerchantNo()
{
return $this->container['merchantNo'];
}
/**
* Sets merchantNo
*
* @param string $merchantNo <pre>收单商编</pre>
*
* @return $this
*/
public function setMerchantNo($merchantNo)
{
$this->container['merchantNo'] = $merchantNo;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@@ -0,0 +1,372 @@
<?php
/**
* YopBindTerminalResponseDto
*
* PHP version 5
*
* @category Class
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* 线下业务
*
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: 1.0
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.13
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use \ArrayAccess;
use Yeepay\Yop\Sdk\Model\ModelInterface;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
/**
* YopBindTerminalResponseDto Class Doc Comment
*
* @category Class
* @description yop绑机响应参数
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class YopBindTerminalResponseDto implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'YopBindTerminalResponseDto';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'bindResponseTerminalInfoList' => '\Yeepay\Yop\Sdk\Service\Offline\Model\BindResponseTerminalInfo[]',
'retCode' => 'string',
'retMsg' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'bindResponseTerminalInfoList' => null,
'retCode' => null,
'retMsg' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'bindResponseTerminalInfoList' => 'bindResponseTerminalInfoList',
'retCode' => 'retCode',
'retMsg' => 'retMsg'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'bindResponseTerminalInfoList' => 'setBindResponseTerminalInfoList',
'retCode' => 'setRetCode',
'retMsg' => 'setRetMsg'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'bindResponseTerminalInfoList' => 'getBindResponseTerminalInfoList',
'retCode' => 'getRetCode',
'retMsg' => 'getRetMsg'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['bindResponseTerminalInfoList'] = isset($data['bindResponseTerminalInfoList']) ? $data['bindResponseTerminalInfoList'] : null;
$this->container['retCode'] = isset($data['retCode']) ? $data['retCode'] : null;
$this->container['retMsg'] = isset($data['retMsg']) ? $data['retMsg'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['bindResponseTerminalInfoList'] === null) {
$invalidProperties[] = "'bindResponseTerminalInfoList' can't be null";
}
if ($this->container['retCode'] === null) {
$invalidProperties[] = "'retCode' can't be null";
}
if ($this->container['retMsg'] === null) {
$invalidProperties[] = "'retMsg' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return count($this->listInvalidProperties()) === 0;
}
/**
* Gets bindResponseTerminalInfoList
*
* @return \Yeepay\Yop\Sdk\Service\Offline\Model\BindResponseTerminalInfo[]
*/
public function getBindResponseTerminalInfoList()
{
return $this->container['bindResponseTerminalInfoList'];
}
/**
* Sets bindResponseTerminalInfoList
*
* @param \Yeepay\Yop\Sdk\Service\Offline\Model\BindResponseTerminalInfo[] $bindResponseTerminalInfoList <pre>终端绑机信息列表</pre>
*
* @return $this
*/
public function setBindResponseTerminalInfoList($bindResponseTerminalInfoList)
{
$this->container['bindResponseTerminalInfoList'] = $bindResponseTerminalInfoList;
return $this;
}
/**
* Gets retCode
*
* @return string
*/
public function getRetCode()
{
return $this->container['retCode'];
}
/**
* Sets retCode
*
* @param string $retCode <p>返回码</p>
*
* @return $this
*/
public function setRetCode($retCode)
{
$this->container['retCode'] = $retCode;
return $this;
}
/**
* Gets retMsg
*
* @return string
*/
public function getRetMsg()
{
return $this->container['retMsg'];
}
/**
* Sets retMsg
*
* @param string $retMsg <p>返回信息</p>
*
* @return $this
*/
public function setRetMsg($retMsg)
{
$this->container['retMsg'] = $retMsg;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@@ -0,0 +1,372 @@
<?php
/**
* YopCreateShopRspDTO
*
* PHP version 5
*
* @category Class
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* 线下业务
*
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: 1.0
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.13
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use \ArrayAccess;
use Yeepay\Yop\Sdk\Model\ModelInterface;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
/**
* YopCreateShopRspDTO Class Doc Comment
*
* @category Class
* @description 创建网点返回信息
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class YopCreateShopRspDTO implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'YopCreateShopRspDTO';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'retCode' => 'string',
'retMsg' => 'string',
'shopNo' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'retCode' => null,
'retMsg' => null,
'shopNo' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'retCode' => 'retCode',
'retMsg' => 'retMsg',
'shopNo' => 'shopNo'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'retCode' => 'setRetCode',
'retMsg' => 'setRetMsg',
'shopNo' => 'setShopNo'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'retCode' => 'getRetCode',
'retMsg' => 'getRetMsg',
'shopNo' => 'getShopNo'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['retCode'] = isset($data['retCode']) ? $data['retCode'] : null;
$this->container['retMsg'] = isset($data['retMsg']) ? $data['retMsg'] : null;
$this->container['shopNo'] = isset($data['shopNo']) ? $data['shopNo'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['retCode'] === null) {
$invalidProperties[] = "'retCode' can't be null";
}
if ($this->container['retMsg'] === null) {
$invalidProperties[] = "'retMsg' can't be null";
}
if ($this->container['shopNo'] === null) {
$invalidProperties[] = "'shopNo' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return count($this->listInvalidProperties()) === 0;
}
/**
* Gets retCode
*
* @return string
*/
public function getRetCode()
{
return $this->container['retCode'];
}
/**
* Sets retCode
*
* @param string $retCode <p>返回码</p>
*
* @return $this
*/
public function setRetCode($retCode)
{
$this->container['retCode'] = $retCode;
return $this;
}
/**
* Gets retMsg
*
* @return string
*/
public function getRetMsg()
{
return $this->container['retMsg'];
}
/**
* Sets retMsg
*
* @param string $retMsg <p>返回信息</p>
*
* @return $this
*/
public function setRetMsg($retMsg)
{
$this->container['retMsg'] = $retMsg;
return $this;
}
/**
* Gets shopNo
*
* @return string
*/
public function getShopNo()
{
return $this->container['shopNo'];
}
/**
* Sets shopNo
*
* @param string $shopNo <pre>网点编号</pre>
*
* @return $this
*/
public function setShopNo($shopNo)
{
$this->container['shopNo'] = $shopNo;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@@ -0,0 +1,372 @@
<?php
/**
* YopGetShopRspDTO
*
* PHP version 5
*
* @category Class
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* 线下业务
*
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: 1.0
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.13
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use \ArrayAccess;
use Yeepay\Yop\Sdk\Model\ModelInterface;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
/**
* YopGetShopRspDTO Class Doc Comment
*
* @category Class
* @description 网点信息
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class YopGetShopRspDTO implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'YopGetShopRspDTO';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'retCode' => 'string',
'retMsg' => 'string',
'shopInfos' => '\Yeepay\Yop\Sdk\Service\Offline\Model\GetShopRspDTO[]'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'retCode' => null,
'retMsg' => null,
'shopInfos' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'retCode' => 'retCode',
'retMsg' => 'retMsg',
'shopInfos' => 'shopInfos'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'retCode' => 'setRetCode',
'retMsg' => 'setRetMsg',
'shopInfos' => 'setShopInfos'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'retCode' => 'getRetCode',
'retMsg' => 'getRetMsg',
'shopInfos' => 'getShopInfos'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['retCode'] = isset($data['retCode']) ? $data['retCode'] : null;
$this->container['retMsg'] = isset($data['retMsg']) ? $data['retMsg'] : null;
$this->container['shopInfos'] = isset($data['shopInfos']) ? $data['shopInfos'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['retCode'] === null) {
$invalidProperties[] = "'retCode' can't be null";
}
if ($this->container['retMsg'] === null) {
$invalidProperties[] = "'retMsg' can't be null";
}
if ($this->container['shopInfos'] === null) {
$invalidProperties[] = "'shopInfos' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return count($this->listInvalidProperties()) === 0;
}
/**
* Gets retCode
*
* @return string
*/
public function getRetCode()
{
return $this->container['retCode'];
}
/**
* Sets retCode
*
* @param string $retCode <p>返回码</p>
*
* @return $this
*/
public function setRetCode($retCode)
{
$this->container['retCode'] = $retCode;
return $this;
}
/**
* Gets retMsg
*
* @return string
*/
public function getRetMsg()
{
return $this->container['retMsg'];
}
/**
* Sets retMsg
*
* @param string $retMsg <p>返回信息</p>
*
* @return $this
*/
public function setRetMsg($retMsg)
{
$this->container['retMsg'] = $retMsg;
return $this;
}
/**
* Gets shopInfos
*
* @return \Yeepay\Yop\Sdk\Service\Offline\Model\GetShopRspDTO[]
*/
public function getShopInfos()
{
return $this->container['shopInfos'];
}
/**
* Sets shopInfos
*
* @param \Yeepay\Yop\Sdk\Service\Offline\Model\GetShopRspDTO[] $shopInfos <p>网点信息</p>
*
* @return $this
*/
public function setShopInfos($shopInfos)
{
$this->container['shopInfos'] = $shopInfos;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@@ -0,0 +1,405 @@
<?php
/**
* YopQueryAgentResponse
*
* PHP version 5
*
* @category Class
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* 线下业务
*
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: 1.0
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.13
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use \ArrayAccess;
use Yeepay\Yop\Sdk\Model\ModelInterface;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
/**
* YopQueryAgentResponse Class Doc Comment
*
* @category Class
* @description 代理商信息
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class YopQueryAgentResponse implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'YopQueryAgentResponse';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'agentMerchantNo' => 'string',
'terminalNo' => 'string',
'merchantNo' => 'string',
'serialNo' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'agentMerchantNo' => null,
'terminalNo' => null,
'merchantNo' => null,
'serialNo' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'agentMerchantNo' => 'agentMerchantNo',
'terminalNo' => 'terminalNo',
'merchantNo' => 'merchantNo',
'serialNo' => 'serialNo'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'agentMerchantNo' => 'setAgentMerchantNo',
'terminalNo' => 'setTerminalNo',
'merchantNo' => 'setMerchantNo',
'serialNo' => 'setSerialNo'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'agentMerchantNo' => 'getAgentMerchantNo',
'terminalNo' => 'getTerminalNo',
'merchantNo' => 'getMerchantNo',
'serialNo' => 'getSerialNo'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['agentMerchantNo'] = isset($data['agentMerchantNo']) ? $data['agentMerchantNo'] : null;
$this->container['terminalNo'] = isset($data['terminalNo']) ? $data['terminalNo'] : null;
$this->container['merchantNo'] = isset($data['merchantNo']) ? $data['merchantNo'] : null;
$this->container['serialNo'] = isset($data['serialNo']) ? $data['serialNo'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['agentMerchantNo'] === null) {
$invalidProperties[] = "'agentMerchantNo' can't be null";
}
if ($this->container['terminalNo'] === null) {
$invalidProperties[] = "'terminalNo' can't be null";
}
if ($this->container['merchantNo'] === null) {
$invalidProperties[] = "'merchantNo' can't be null";
}
if ($this->container['serialNo'] === null) {
$invalidProperties[] = "'serialNo' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return count($this->listInvalidProperties()) === 0;
}
/**
* Gets agentMerchantNo
*
* @return string
*/
public function getAgentMerchantNo()
{
return $this->container['agentMerchantNo'];
}
/**
* Sets agentMerchantNo
*
* @param string $agentMerchantNo <div>终端所属代理商商编,指付款采购终端的商编</div>
*
* @return $this
*/
public function setAgentMerchantNo($agentMerchantNo)
{
$this->container['agentMerchantNo'] = $agentMerchantNo;
return $this;
}
/**
* Gets terminalNo
*
* @return string
*/
public function getTerminalNo()
{
return $this->container['terminalNo'];
}
/**
* Sets terminalNo
*
* @param string $terminalNo <pre>终端号</pre>
*
* @return $this
*/
public function setTerminalNo($terminalNo)
{
$this->container['terminalNo'] = $terminalNo;
return $this;
}
/**
* Gets merchantNo
*
* @return string
*/
public function getMerchantNo()
{
return $this->container['merchantNo'];
}
/**
* Sets merchantNo
*
* @param string $merchantNo <pre>终端所属收单商编</pre>
*
* @return $this
*/
public function setMerchantNo($merchantNo)
{
$this->container['merchantNo'] = $merchantNo;
return $this;
}
/**
* Gets serialNo
*
* @return string
*/
public function getSerialNo()
{
return $this->container['serialNo'];
}
/**
* Sets serialNo
*
* @param string $serialNo <p>终端序列号</p>
*
* @return $this
*/
public function setSerialNo($serialNo)
{
$this->container['serialNo'] = $serialNo;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@@ -0,0 +1,372 @@
<?php
/**
* YopQueryAgentRspDto
*
* PHP version 5
*
* @category Class
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* 线下业务
*
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: 1.0
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.13
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use \ArrayAccess;
use Yeepay\Yop\Sdk\Model\ModelInterface;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
/**
* YopQueryAgentRspDto Class Doc Comment
*
* @category Class
* @description 查询代理关系
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class YopQueryAgentRspDto implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'YopQueryAgentRspDto';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'yopQueryAgentResponses' => '\Yeepay\Yop\Sdk\Service\Offline\Model\YopQueryAgentResponse[]',
'retCode' => 'string',
'retMsg' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'yopQueryAgentResponses' => null,
'retCode' => null,
'retMsg' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'yopQueryAgentResponses' => 'yopQueryAgentResponses',
'retCode' => 'retCode',
'retMsg' => 'retMsg'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'yopQueryAgentResponses' => 'setYopQueryAgentResponses',
'retCode' => 'setRetCode',
'retMsg' => 'setRetMsg'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'yopQueryAgentResponses' => 'getYopQueryAgentResponses',
'retCode' => 'getRetCode',
'retMsg' => 'getRetMsg'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['yopQueryAgentResponses'] = isset($data['yopQueryAgentResponses']) ? $data['yopQueryAgentResponses'] : null;
$this->container['retCode'] = isset($data['retCode']) ? $data['retCode'] : null;
$this->container['retMsg'] = isset($data['retMsg']) ? $data['retMsg'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['yopQueryAgentResponses'] === null) {
$invalidProperties[] = "'yopQueryAgentResponses' can't be null";
}
if ($this->container['retCode'] === null) {
$invalidProperties[] = "'retCode' can't be null";
}
if ($this->container['retMsg'] === null) {
$invalidProperties[] = "'retMsg' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return count($this->listInvalidProperties()) === 0;
}
/**
* Gets yopQueryAgentResponses
*
* @return \Yeepay\Yop\Sdk\Service\Offline\Model\YopQueryAgentResponse[]
*/
public function getYopQueryAgentResponses()
{
return $this->container['yopQueryAgentResponses'];
}
/**
* Sets yopQueryAgentResponses
*
* @param \Yeepay\Yop\Sdk\Service\Offline\Model\YopQueryAgentResponse[] $yopQueryAgentResponses <p>代理商信息</p>
*
* @return $this
*/
public function setYopQueryAgentResponses($yopQueryAgentResponses)
{
$this->container['yopQueryAgentResponses'] = $yopQueryAgentResponses;
return $this;
}
/**
* Gets retCode
*
* @return string
*/
public function getRetCode()
{
return $this->container['retCode'];
}
/**
* Sets retCode
*
* @param string $retCode <p>返回码</p>
*
* @return $this
*/
public function setRetCode($retCode)
{
$this->container['retCode'] = $retCode;
return $this;
}
/**
* Gets retMsg
*
* @return string
*/
public function getRetMsg()
{
return $this->container['retMsg'];
}
/**
* Sets retMsg
*
* @param string $retMsg <p>返回信息</p>
*
* @return $this
*/
public function setRetMsg($retMsg)
{
$this->container['retMsg'] = $retMsg;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@@ -0,0 +1,723 @@
<?php
/**
* YopQueryOrderInfoRespDTO
*
* PHP version 5
*
* @category Class
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* 线下业务
*
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: 1.0
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.13
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use \ArrayAccess;
use Yeepay\Yop\Sdk\Model\ModelInterface;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
/**
* YopQueryOrderInfoRespDTO Class Doc Comment
*
* @category Class
* @description 查询POS交易信息响应模型
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class YopQueryOrderInfoRespDTO implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'YopQueryOrderInfoRespDTO';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'terminalNo' => 'string',
'orderId' => 'string',
'bankCardNo' => 'string',
'paySuccessDate' => '\DateTime',
'payWay' => 'string',
'uniqueOrderNo' => 'string',
'purchaseUrl' => 'string',
'bankId' => 'string',
'posRequestNo' => 'string',
'orderAmount' => 'float',
'merchantNo' => 'string',
'status' => 'string',
'businessOrderNo' => 'string',
'retCode' => 'string',
'retMsg' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'terminalNo' => null,
'orderId' => null,
'bankCardNo' => null,
'paySuccessDate' => 'date-time',
'payWay' => null,
'uniqueOrderNo' => null,
'purchaseUrl' => null,
'bankId' => null,
'posRequestNo' => null,
'orderAmount' => null,
'merchantNo' => null,
'status' => null,
'businessOrderNo' => null,
'retCode' => null,
'retMsg' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'terminalNo' => 'terminalNo',
'orderId' => 'orderId',
'bankCardNo' => 'bankCardNo',
'paySuccessDate' => 'paySuccessDate',
'payWay' => 'payWay',
'uniqueOrderNo' => 'uniqueOrderNo',
'purchaseUrl' => 'purchaseUrl',
'bankId' => 'bankId',
'posRequestNo' => 'posRequestNo',
'orderAmount' => 'orderAmount',
'merchantNo' => 'merchantNo',
'status' => 'status',
'businessOrderNo' => 'businessOrderNo',
'retCode' => 'retCode',
'retMsg' => 'retMsg'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'terminalNo' => 'setTerminalNo',
'orderId' => 'setOrderId',
'bankCardNo' => 'setBankCardNo',
'paySuccessDate' => 'setPaySuccessDate',
'payWay' => 'setPayWay',
'uniqueOrderNo' => 'setUniqueOrderNo',
'purchaseUrl' => 'setPurchaseUrl',
'bankId' => 'setBankId',
'posRequestNo' => 'setPosRequestNo',
'orderAmount' => 'setOrderAmount',
'merchantNo' => 'setMerchantNo',
'status' => 'setStatus',
'businessOrderNo' => 'setBusinessOrderNo',
'retCode' => 'setRetCode',
'retMsg' => 'setRetMsg'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'terminalNo' => 'getTerminalNo',
'orderId' => 'getOrderId',
'bankCardNo' => 'getBankCardNo',
'paySuccessDate' => 'getPaySuccessDate',
'payWay' => 'getPayWay',
'uniqueOrderNo' => 'getUniqueOrderNo',
'purchaseUrl' => 'getPurchaseUrl',
'bankId' => 'getBankId',
'posRequestNo' => 'getPosRequestNo',
'orderAmount' => 'getOrderAmount',
'merchantNo' => 'getMerchantNo',
'status' => 'getStatus',
'businessOrderNo' => 'getBusinessOrderNo',
'retCode' => 'getRetCode',
'retMsg' => 'getRetMsg'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['terminalNo'] = isset($data['terminalNo']) ? $data['terminalNo'] : null;
$this->container['orderId'] = isset($data['orderId']) ? $data['orderId'] : null;
$this->container['bankCardNo'] = isset($data['bankCardNo']) ? $data['bankCardNo'] : null;
$this->container['paySuccessDate'] = isset($data['paySuccessDate']) ? $data['paySuccessDate'] : null;
$this->container['payWay'] = isset($data['payWay']) ? $data['payWay'] : null;
$this->container['uniqueOrderNo'] = isset($data['uniqueOrderNo']) ? $data['uniqueOrderNo'] : null;
$this->container['purchaseUrl'] = isset($data['purchaseUrl']) ? $data['purchaseUrl'] : null;
$this->container['bankId'] = isset($data['bankId']) ? $data['bankId'] : null;
$this->container['posRequestNo'] = isset($data['posRequestNo']) ? $data['posRequestNo'] : null;
$this->container['orderAmount'] = isset($data['orderAmount']) ? $data['orderAmount'] : null;
$this->container['merchantNo'] = isset($data['merchantNo']) ? $data['merchantNo'] : null;
$this->container['status'] = isset($data['status']) ? $data['status'] : null;
$this->container['businessOrderNo'] = isset($data['businessOrderNo']) ? $data['businessOrderNo'] : null;
$this->container['retCode'] = isset($data['retCode']) ? $data['retCode'] : null;
$this->container['retMsg'] = isset($data['retMsg']) ? $data['retMsg'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return count($this->listInvalidProperties()) === 0;
}
/**
* Gets terminalNo
*
* @return string
*/
public function getTerminalNo()
{
return $this->container['terminalNo'];
}
/**
* Sets terminalNo
*
* @param string $terminalNo <p>终端号</p>
*
* @return $this
*/
public function setTerminalNo($terminalNo)
{
$this->container['terminalNo'] = $terminalNo;
return $this;
}
/**
* Gets orderId
*
* @return string
*/
public function getOrderId()
{
return $this->container['orderId'];
}
/**
* Sets orderId
*
* @param string $orderId <p>商户订单号</p>
*
* @return $this
*/
public function setOrderId($orderId)
{
$this->container['orderId'] = $orderId;
return $this;
}
/**
* Gets bankCardNo
*
* @return string
*/
public function getBankCardNo()
{
return $this->container['bankCardNo'];
}
/**
* Sets bankCardNo
*
* @param string $bankCardNo <div data-page-id=\"TKcSdEsC1oFw1qx9zQ5czAf1nyc\" data-docx-has-block-data=\"false\"> <div class=\"ace-line ace-line old-record-id-Y3Usd3jbwoCimRxEMzecGfJFnsc\"> <div data-page-id=\"TKcSdEsC1oFw1qx9zQ5czAf1nyc\" data-docx-has-block-data=\"false\"> <div class=\"ace-line ace-line old-record-id-XN8PdTDwEoH7uAxMu2zcfpsPnrc\">银行卡号,掩码</div> </div> </div> </div>
*
* @return $this
*/
public function setBankCardNo($bankCardNo)
{
$this->container['bankCardNo'] = $bankCardNo;
return $this;
}
/**
* Gets paySuccessDate
*
* @return \DateTime
*/
public function getPaySuccessDate()
{
return $this->container['paySuccessDate'];
}
/**
* Sets paySuccessDate
*
* @param \DateTime $paySuccessDate <div data-page-id=\"TKcSdEsC1oFw1qx9zQ5czAf1nyc\" data-docx-has-block-data=\"false\"> <div class=\"ace-line ace-line old-record-id-TvRXdKvhAoz0ckxkXH2ca84vnCh\">支付成功时间</div> </div>
*
* @return $this
*/
public function setPaySuccessDate($paySuccessDate)
{
$this->container['paySuccessDate'] = $paySuccessDate;
return $this;
}
/**
* Gets payWay
*
* @return string
*/
public function getPayWay()
{
return $this->container['payWay'];
}
/**
* Sets payWay
*
* @param string $payWay <div data-page-id=\"TKcSdEsC1oFw1qx9zQ5czAf1nyc\" data-docx-has-block-data=\"false\"> <div class=\"ace-line ace-line old-record-id-A7NhddEdgoRaghx3YUTcmMW6nVe\">支付方式</div> </div>
*
* @return $this
*/
public function setPayWay($payWay)
{
$this->container['payWay'] = $payWay;
return $this;
}
/**
* Gets uniqueOrderNo
*
* @return string
*/
public function getUniqueOrderNo()
{
return $this->container['uniqueOrderNo'];
}
/**
* Sets uniqueOrderNo
*
* @param string $uniqueOrderNo <div data-page-id=\"TKcSdEsC1oFw1qx9zQ5czAf1nyc\" data-docx-has-block-data=\"false\"> <div class=\"ace-line ace-line old-record-id-DygMdmuckoZqHexbep5cjvVLnUA\">支付唯一流水号</div> </div>
*
* @return $this
*/
public function setUniqueOrderNo($uniqueOrderNo)
{
$this->container['uniqueOrderNo'] = $uniqueOrderNo;
return $this;
}
/**
* Gets purchaseUrl
*
* @return string
*/
public function getPurchaseUrl()
{
return $this->container['purchaseUrl'];
}
/**
* Sets purchaseUrl
*
* @param string $purchaseUrl <div data-page-id=\"TKcSdEsC1oFw1qx9zQ5czAf1nyc\" data-docx-has-block-data=\"false\"> <div class=\"ace-line ace-line old-record-id-NIWHd1rnOo4kcsx9EZDcWTtwnzh\">签购单地址</div> </div>
*
* @return $this
*/
public function setPurchaseUrl($purchaseUrl)
{
$this->container['purchaseUrl'] = $purchaseUrl;
return $this;
}
/**
* Gets bankId
*
* @return string
*/
public function getBankId()
{
return $this->container['bankId'];
}
/**
* Sets bankId
*
* @param string $bankId <div data-page-id=\"TKcSdEsC1oFw1qx9zQ5czAf1nyc\" data-docx-has-block-data=\"false\"> <div class=\"ace-line ace-line old-record-id-Y3Usd3jbwoCimRxEMzecGfJFnsc\">发卡行编码</div> </div>
*
* @return $this
*/
public function setBankId($bankId)
{
$this->container['bankId'] = $bankId;
return $this;
}
/**
* Gets posRequestNo
*
* @return string
*/
public function getPosRequestNo()
{
return $this->container['posRequestNo'];
}
/**
* Sets posRequestNo
*
* @param string $posRequestNo <div data-page-id=\"TKcSdEsC1oFw1qx9zQ5czAf1nyc\" data-docx-has-block-data=\"false\"> <div class=\"ace-line ace-line old-record-id-FzGIdfsgOoJB3Zx6Oafc8acnn6U\">终端流水号</div> </div>
*
* @return $this
*/
public function setPosRequestNo($posRequestNo)
{
$this->container['posRequestNo'] = $posRequestNo;
return $this;
}
/**
* Gets orderAmount
*
* @return float
*/
public function getOrderAmount()
{
return $this->container['orderAmount'];
}
/**
* Sets orderAmount
*
* @param float $orderAmount <div data-page-id=\"TKcSdEsC1oFw1qx9zQ5czAf1nyc\" data-docx-has-block-data=\"false\"> <div class=\"ace-line ace-line old-record-id-XbRLdUm26oHM2FxTOMhcUFfynTb\">订单金额(元)</div> </div>
*
* @return $this
*/
public function setOrderAmount($orderAmount)
{
$this->container['orderAmount'] = $orderAmount;
return $this;
}
/**
* Gets merchantNo
*
* @return string
*/
public function getMerchantNo()
{
return $this->container['merchantNo'];
}
/**
* Sets merchantNo
*
* @param string $merchantNo <p>收单商编</p>
*
* @return $this
*/
public function setMerchantNo($merchantNo)
{
$this->container['merchantNo'] = $merchantNo;
return $this;
}
/**
* Gets status
*
* @return string
*/
public function getStatus()
{
return $this->container['status'];
}
/**
* Sets status
*
* @param string $status <p>订单状态</p>
*
* @return $this
*/
public function setStatus($status)
{
$this->container['status'] = $status;
return $this;
}
/**
* Gets businessOrderNo
*
* @return string
*/
public function getBusinessOrderNo()
{
return $this->container['businessOrderNo'];
}
/**
* Sets businessOrderNo
*
* @param string $businessOrderNo <p>商户业务单号</p>
*
* @return $this
*/
public function setBusinessOrderNo($businessOrderNo)
{
$this->container['businessOrderNo'] = $businessOrderNo;
return $this;
}
/**
* Gets retCode
*
* @return string
*/
public function getRetCode()
{
return $this->container['retCode'];
}
/**
* Sets retCode
*
* @param string $retCode <p>返回码</p>
*
* @return $this
*/
public function setRetCode($retCode)
{
$this->container['retCode'] = $retCode;
return $this;
}
/**
* Gets retMsg
*
* @return string
*/
public function getRetMsg()
{
return $this->container['retMsg'];
}
/**
* Sets retMsg
*
* @param string $retMsg <p>返回信息</p>
*
* @return $this
*/
public function setRetMsg($retMsg)
{
$this->container['retMsg'] = $retMsg;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@@ -0,0 +1,471 @@
<?php
/**
* YopQueryShopBindResponse
*
* PHP version 5
*
* @category Class
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* 线下业务
*
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: 1.0
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.13
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use \ArrayAccess;
use Yeepay\Yop\Sdk\Model\ModelInterface;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
/**
* YopQueryShopBindResponse Class Doc Comment
*
* @category Class
* @description yop查询绑机返回参数
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class YopQueryShopBindResponse implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'YopQueryShopBindResponse';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'agentMerchantNo' => 'string',
'terminalNo' => 'string',
'shopName' => 'string',
'shopNo' => 'string',
'merchantNo' => 'string',
'serialNo' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'agentMerchantNo' => null,
'terminalNo' => null,
'shopName' => null,
'shopNo' => null,
'merchantNo' => null,
'serialNo' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'agentMerchantNo' => 'agentMerchantNo',
'terminalNo' => 'terminalNo',
'shopName' => 'shopName',
'shopNo' => 'shopNo',
'merchantNo' => 'merchantNo',
'serialNo' => 'serialNo'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'agentMerchantNo' => 'setAgentMerchantNo',
'terminalNo' => 'setTerminalNo',
'shopName' => 'setShopName',
'shopNo' => 'setShopNo',
'merchantNo' => 'setMerchantNo',
'serialNo' => 'setSerialNo'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'agentMerchantNo' => 'getAgentMerchantNo',
'terminalNo' => 'getTerminalNo',
'shopName' => 'getShopName',
'shopNo' => 'getShopNo',
'merchantNo' => 'getMerchantNo',
'serialNo' => 'getSerialNo'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['agentMerchantNo'] = isset($data['agentMerchantNo']) ? $data['agentMerchantNo'] : null;
$this->container['terminalNo'] = isset($data['terminalNo']) ? $data['terminalNo'] : null;
$this->container['shopName'] = isset($data['shopName']) ? $data['shopName'] : null;
$this->container['shopNo'] = isset($data['shopNo']) ? $data['shopNo'] : null;
$this->container['merchantNo'] = isset($data['merchantNo']) ? $data['merchantNo'] : null;
$this->container['serialNo'] = isset($data['serialNo']) ? $data['serialNo'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['agentMerchantNo'] === null) {
$invalidProperties[] = "'agentMerchantNo' can't be null";
}
if ($this->container['terminalNo'] === null) {
$invalidProperties[] = "'terminalNo' can't be null";
}
if ($this->container['shopName'] === null) {
$invalidProperties[] = "'shopName' can't be null";
}
if ($this->container['shopNo'] === null) {
$invalidProperties[] = "'shopNo' can't be null";
}
if ($this->container['merchantNo'] === null) {
$invalidProperties[] = "'merchantNo' can't be null";
}
if ($this->container['serialNo'] === null) {
$invalidProperties[] = "'serialNo' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return count($this->listInvalidProperties()) === 0;
}
/**
* Gets agentMerchantNo
*
* @return string
*/
public function getAgentMerchantNo()
{
return $this->container['agentMerchantNo'];
}
/**
* Sets agentMerchantNo
*
* @param string $agentMerchantNo <div>终端采购商商编,指付款采购终端的商编</div>
*
* @return $this
*/
public function setAgentMerchantNo($agentMerchantNo)
{
$this->container['agentMerchantNo'] = $agentMerchantNo;
return $this;
}
/**
* Gets terminalNo
*
* @return string
*/
public function getTerminalNo()
{
return $this->container['terminalNo'];
}
/**
* Sets terminalNo
*
* @param string $terminalNo <pre>终端号</pre>
*
* @return $this
*/
public function setTerminalNo($terminalNo)
{
$this->container['terminalNo'] = $terminalNo;
return $this;
}
/**
* Gets shopName
*
* @return string
*/
public function getShopName()
{
return $this->container['shopName'];
}
/**
* Sets shopName
*
* @param string $shopName <pre>网点名称</pre>
*
* @return $this
*/
public function setShopName($shopName)
{
$this->container['shopName'] = $shopName;
return $this;
}
/**
* Gets shopNo
*
* @return string
*/
public function getShopNo()
{
return $this->container['shopNo'];
}
/**
* Sets shopNo
*
* @param string $shopNo <pre>网点编号</pre>
*
* @return $this
*/
public function setShopNo($shopNo)
{
$this->container['shopNo'] = $shopNo;
return $this;
}
/**
* Gets merchantNo
*
* @return string
*/
public function getMerchantNo()
{
return $this->container['merchantNo'];
}
/**
* Sets merchantNo
*
* @param string $merchantNo <pre>终端所属收单商编</pre>
*
* @return $this
*/
public function setMerchantNo($merchantNo)
{
$this->container['merchantNo'] = $merchantNo;
return $this;
}
/**
* Gets serialNo
*
* @return string
*/
public function getSerialNo()
{
return $this->container['serialNo'];
}
/**
* Sets serialNo
*
* @param string $serialNo <p>终端序列号</p>
*
* @return $this
*/
public function setSerialNo($serialNo)
{
$this->container['serialNo'] = $serialNo;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@@ -0,0 +1,369 @@
<?php
/**
* YopQueryShopBindRspDto
*
* PHP version 5
*
* @category Class
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* 线下业务
*
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: 1.0
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.13
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use \ArrayAccess;
use Yeepay\Yop\Sdk\Model\ModelInterface;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
/**
* YopQueryShopBindRspDto Class Doc Comment
*
* @category Class
* @description 所属绑机信息
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class YopQueryShopBindRspDto implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'YopQueryShopBindRspDto';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'bindResponses' => '\Yeepay\Yop\Sdk\Service\Offline\Model\YopQueryShopBindResponse[]',
'retCode' => 'string',
'retMsg' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'bindResponses' => null,
'retCode' => null,
'retMsg' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'bindResponses' => 'bindResponses',
'retCode' => 'retCode',
'retMsg' => 'retMsg'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'bindResponses' => 'setBindResponses',
'retCode' => 'setRetCode',
'retMsg' => 'setRetMsg'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'bindResponses' => 'getBindResponses',
'retCode' => 'getRetCode',
'retMsg' => 'getRetMsg'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['bindResponses'] = isset($data['bindResponses']) ? $data['bindResponses'] : null;
$this->container['retCode'] = isset($data['retCode']) ? $data['retCode'] : null;
$this->container['retMsg'] = isset($data['retMsg']) ? $data['retMsg'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['bindResponses'] === null) {
$invalidProperties[] = "'bindResponses' can't be null";
}
if ($this->container['retCode'] === null) {
$invalidProperties[] = "'retCode' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return count($this->listInvalidProperties()) === 0;
}
/**
* Gets bindResponses
*
* @return \Yeepay\Yop\Sdk\Service\Offline\Model\YopQueryShopBindResponse[]
*/
public function getBindResponses()
{
return $this->container['bindResponses'];
}
/**
* Sets bindResponses
*
* @param \Yeepay\Yop\Sdk\Service\Offline\Model\YopQueryShopBindResponse[] $bindResponses <p>绑机信息</p>
*
* @return $this
*/
public function setBindResponses($bindResponses)
{
$this->container['bindResponses'] = $bindResponses;
return $this;
}
/**
* Gets retCode
*
* @return string
*/
public function getRetCode()
{
return $this->container['retCode'];
}
/**
* Sets retCode
*
* @param string $retCode <p>返回码</p>
*
* @return $this
*/
public function setRetCode($retCode)
{
$this->container['retCode'] = $retCode;
return $this;
}
/**
* Gets retMsg
*
* @return string
*/
public function getRetMsg()
{
return $this->container['retMsg'];
}
/**
* Sets retMsg
*
* @param string $retMsg <p>返回信息</p>
*
* @return $this
*/
public function setRetMsg($retMsg)
{
$this->container['retMsg'] = $retMsg;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@@ -0,0 +1,372 @@
<?php
/**
* YopUnBindTerminalRequestDto
*
* PHP version 5
*
* @category Class
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* 线下业务
*
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: 1.0
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.13
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use \ArrayAccess;
use Yeepay\Yop\Sdk\Model\ModelInterface;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
/**
* YopUnBindTerminalRequestDto Class Doc Comment
*
* @category Class
* @description yop解绑终端请求参数
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class YopUnBindTerminalRequestDto implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'YopUnBindTerminalRequestDto';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'terminalNo' => 'string[]',
'parentMerchantNo' => 'string',
'merchantNo' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'terminalNo' => 'string',
'parentMerchantNo' => null,
'merchantNo' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'terminalNo' => 'terminalNo',
'parentMerchantNo' => 'parentMerchantNo',
'merchantNo' => 'merchantNo'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'terminalNo' => 'setTerminalNo',
'parentMerchantNo' => 'setParentMerchantNo',
'merchantNo' => 'setMerchantNo'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'terminalNo' => 'getTerminalNo',
'parentMerchantNo' => 'getParentMerchantNo',
'merchantNo' => 'getMerchantNo'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['terminalNo'] = isset($data['terminalNo']) ? $data['terminalNo'] : null;
$this->container['parentMerchantNo'] = isset($data['parentMerchantNo']) ? $data['parentMerchantNo'] : null;
$this->container['merchantNo'] = isset($data['merchantNo']) ? $data['merchantNo'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['terminalNo'] === null) {
$invalidProperties[] = "'terminalNo' can't be null";
}
if ($this->container['parentMerchantNo'] === null) {
$invalidProperties[] = "'parentMerchantNo' can't be null";
}
if ($this->container['merchantNo'] === null) {
$invalidProperties[] = "'merchantNo' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return count($this->listInvalidProperties()) === 0;
}
/**
* Gets terminalNo
*
* @return string[]
*/
public function getTerminalNo()
{
return $this->container['terminalNo'];
}
/**
* Sets terminalNo
*
* @param string[] $terminalNo <pre>解绑终端列表</pre>
*
* @return $this
*/
public function setTerminalNo($terminalNo)
{
$this->container['terminalNo'] = $terminalNo;
return $this;
}
/**
* Gets parentMerchantNo
*
* @return string
*/
public function getParentMerchantNo()
{
return $this->container['parentMerchantNo'];
}
/**
* Sets parentMerchantNo
*
* @param string $parentMerchantNo <div>发起方商户编号。*标准商户收付款方案中此参数与收款商户编号一致;*平台商户收付款方案中此参数为平台商商户编号;*服务商解决方案中,①标准商户收款时,该参数为标准商户商编 ②平台商收款或平台商入驻商户收款时,该参数为平台商商编</div>
*
* @return $this
*/
public function setParentMerchantNo($parentMerchantNo)
{
$this->container['parentMerchantNo'] = $parentMerchantNo;
return $this;
}
/**
* Gets merchantNo
*
* @return string
*/
public function getMerchantNo()
{
return $this->container['merchantNo'];
}
/**
* Sets merchantNo
*
* @param string $merchantNo <pre>收单商编</pre>
*
* @return $this
*/
public function setMerchantNo($merchantNo)
{
$this->container['merchantNo'] = $merchantNo;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@@ -0,0 +1,372 @@
<?php
/**
* YopUnBindTerminalResponseDto
*
* PHP version 5
*
* @category Class
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
/**
* 线下业务
*
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: 1.0
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.13
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
namespace Yeepay\Yop\Sdk\Service\Offline\Model;
use \ArrayAccess;
use Yeepay\Yop\Sdk\Model\ModelInterface;
use Yeepay\Yop\Sdk\Utils\ObjectSerializer;
/**
* YopUnBindTerminalResponseDto Class Doc Comment
*
* @category Class
* @description yop解绑响应参数
* @package Yeepay\Yop\Sdk\
* @author Swagger Codegen team
* @link https://github.com/swagger-api/swagger-codegen
*/
class YopUnBindTerminalResponseDto implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;
/**
* The original name of the model.
*
* @var string
*/
protected static $swaggerModelName = 'YopUnBindTerminalResponseDto';
/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerTypes = [
'bindResponseTerminalInfoList' => '\Yeepay\Yop\Sdk\Service\Offline\Model\BindResponseTerminalInfo[]',
'retCode' => 'string',
'retMsg' => 'string'
];
/**
* Array of property to format mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $swaggerFormats = [
'bindResponseTerminalInfoList' => null,
'retCode' => null,
'retMsg' => null
];
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerTypes()
{
return self::$swaggerTypes;
}
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function swaggerFormats()
{
return self::$swaggerFormats;
}
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @var string[]
*/
protected static $attributeMap = [
'bindResponseTerminalInfoList' => 'bindResponseTerminalInfoList',
'retCode' => 'retCode',
'retMsg' => 'retMsg'
];
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @var string[]
*/
protected static $setters = [
'bindResponseTerminalInfoList' => 'setBindResponseTerminalInfoList',
'retCode' => 'setRetCode',
'retMsg' => 'setRetMsg'
];
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @var string[]
*/
protected static $getters = [
'bindResponseTerminalInfoList' => 'getBindResponseTerminalInfoList',
'retCode' => 'getRetCode',
'retMsg' => 'getRetMsg'
];
/**
* Array of attributes where the key is the local name,
* and the value is the original name
*
* @return array
*/
public static function attributeMap()
{
return self::$attributeMap;
}
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters()
{
return self::$setters;
}
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters()
{
return self::$getters;
}
/**
* The original name of the model.
*
* @return string
*/
public function getModelName()
{
return self::$swaggerModelName;
}
/**
* Associative array for storing property values
*
* @var mixed[]
*/
protected $container = [];
/**
* Constructor
*
* @param mixed[] $data Associated array of property values
* initializing the model
*/
public function __construct(array $data = null)
{
$this->container['bindResponseTerminalInfoList'] = isset($data['bindResponseTerminalInfoList']) ? $data['bindResponseTerminalInfoList'] : null;
$this->container['retCode'] = isset($data['retCode']) ? $data['retCode'] : null;
$this->container['retMsg'] = isset($data['retMsg']) ? $data['retMsg'] : null;
}
/**
* Show all the invalid properties with reasons.
*
* @return array invalid properties with reasons
*/
public function listInvalidProperties()
{
$invalidProperties = [];
if ($this->container['bindResponseTerminalInfoList'] === null) {
$invalidProperties[] = "'bindResponseTerminalInfoList' can't be null";
}
if ($this->container['retCode'] === null) {
$invalidProperties[] = "'retCode' can't be null";
}
if ($this->container['retMsg'] === null) {
$invalidProperties[] = "'retMsg' can't be null";
}
return $invalidProperties;
}
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool True if all properties are valid
*/
public function valid()
{
return count($this->listInvalidProperties()) === 0;
}
/**
* Gets bindResponseTerminalInfoList
*
* @return \Yeepay\Yop\Sdk\Service\Offline\Model\BindResponseTerminalInfo[]
*/
public function getBindResponseTerminalInfoList()
{
return $this->container['bindResponseTerminalInfoList'];
}
/**
* Sets bindResponseTerminalInfoList
*
* @param \Yeepay\Yop\Sdk\Service\Offline\Model\BindResponseTerminalInfo[] $bindResponseTerminalInfoList <pre>终端绑机信息列表</pre>
*
* @return $this
*/
public function setBindResponseTerminalInfoList($bindResponseTerminalInfoList)
{
$this->container['bindResponseTerminalInfoList'] = $bindResponseTerminalInfoList;
return $this;
}
/**
* Gets retCode
*
* @return string
*/
public function getRetCode()
{
return $this->container['retCode'];
}
/**
* Sets retCode
*
* @param string $retCode <p>返回码</p>
*
* @return $this
*/
public function setRetCode($retCode)
{
$this->container['retCode'] = $retCode;
return $this;
}
/**
* Gets retMsg
*
* @return string
*/
public function getRetMsg()
{
return $this->container['retMsg'];
}
/**
* Sets retMsg
*
* @param string $retMsg <p>返回信息</p>
*
* @return $this
*/
public function setRetMsg($retMsg)
{
$this->container['retMsg'] = $retMsg;
return $this;
}
/**
* Returns true if offset exists. False otherwise.
*
* @param integer $offset Offset
*
* @return boolean
*/
public function offsetExists($offset)
{
return isset($this->container[$offset]);
}
/**
* Gets offset.
*
* @param integer $offset Offset
*
* @return mixed
*/
public function offsetGet($offset)
{
return isset($this->container[$offset]) ? $this->container[$offset] : null;
}
/**
* Sets value based on offset.
*
* @param integer $offset Offset
* @param mixed $value Value to be set
*
* @return void
*/
public function offsetSet($offset, $value)
{
if (is_null($offset)) {
$this->container[] = $value;
} else {
$this->container[$offset] = $value;
}
}
/**
* Unsets offset.
*
* @param integer $offset Offset
*
* @return void
*/
public function offsetUnset($offset)
{
unset($this->container[$offset]);
}
/**
* Gets the string presentation of the object
*
* @return string
*/
public function __toString()
{
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
return json_encode(
ObjectSerializer::sanitizeForSerialization($this),
JSON_PRETTY_PRINT
);
}
return json_encode(ObjectSerializer::sanitizeForSerialization($this));
}
}

View File

@@ -0,0 +1,190 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline;
use Yeepay\Yop\Sdk\Client\ClientExecutionParams;
use Yeepay\Yop\Sdk\Client\ClientHandler;
use Yeepay\Yop\Sdk\Client\ClientParams;
use Yeepay\Yop\Sdk\Exception\YopClientException;
use Yeepay\Yop\Sdk\Service\Offline\Model as Model;
class OfflineClient
{
/**
* @var ClientHandler
*/
private $clientHandler;
/**
* OfflineClient constructor.
* @param ClientParams $clientParams
*/
function __construct(ClientParams $clientParams)
{
$this->clientHandler = new ClientHandler($clientParams);
}
/**
* @param Model\BindRequest $request
* @return Model\BindResponse
* @throws YopClientException
*/
public function bind(Model\BindRequest $request)
{
if ($request == null) {
throw new YopClientException("request is required.");
}
$clientExecutionParams = new ClientExecutionParams($request, Model\BindRequestMarshaller::getInstance(),
Model\BindResponseUnMarshaller::getInstance());
return $this->clientHandler->execute($clientExecutionParams);
}
/**
* @param Model\CreateShopRequest $request
* @return Model\CreateShopResponse
* @throws YopClientException
*/
public function createShop(Model\CreateShopRequest $request)
{
if ($request == null) {
throw new YopClientException("request is required.");
}
$clientExecutionParams = new ClientExecutionParams($request, Model\CreateShopRequestMarshaller::getInstance(),
Model\CreateShopResponseUnMarshaller::getInstance());
return $this->clientHandler->execute($clientExecutionParams);
}
/**
* @param Model\GetShopRequest $request
* @return Model\GetShopResponse
* @throws YopClientException
*/
public function getShop(Model\GetShopRequest $request)
{
if ($request == null) {
throw new YopClientException("request is required.");
}
if ($request->getParentMerchantNo() == null) {
throw new YopClientException("request.parentMerchantNo is required.");
}
if ($request->getMerchantNo() == null) {
throw new YopClientException("request.merchantNo is required.");
}
$clientExecutionParams = new ClientExecutionParams($request, Model\GetShopRequestMarshaller::getInstance(),
Model\GetShopResponseUnMarshaller::getInstance());
return $this->clientHandler->execute($clientExecutionParams);
}
/**
* @param Model\OperateShopRequest $request
* @return Model\OperateShopResponse
* @throws YopClientException
*/
public function operateShop(Model\OperateShopRequest $request)
{
if ($request == null) {
throw new YopClientException("request is required.");
}
$clientExecutionParams = new ClientExecutionParams($request, Model\OperateShopRequestMarshaller::getInstance(),
Model\OperateShopResponseUnMarshaller::getInstance());
return $this->clientHandler->execute($clientExecutionParams);
}
/**
* @param Model\QueryAgentListRequest $request
* @return Model\QueryAgentListResponse
* @throws YopClientException
*/
public function queryAgentList(Model\QueryAgentListRequest $request)
{
if ($request == null) {
throw new YopClientException("request is required.");
}
if ($request->getAgentMerchantNo() == null) {
throw new YopClientException("request.agentMerchantNo is required.");
}
if ($request->getParentMerchantNo() == null) {
throw new YopClientException("request.parentMerchantNo is required.");
}
$clientExecutionParams = new ClientExecutionParams($request, Model\QueryAgentListRequestMarshaller::getInstance(),
Model\QueryAgentListResponseUnMarshaller::getInstance());
return $this->clientHandler->execute($clientExecutionParams);
}
/**
* @param Model\QueryOrderInfoRequest $request
* @return Model\QueryOrderInfoResponse
* @throws YopClientException
*/
public function queryOrderInfo(Model\QueryOrderInfoRequest $request)
{
if ($request == null) {
throw new YopClientException("request is required.");
}
$clientExecutionParams = new ClientExecutionParams($request, Model\QueryOrderInfoRequestMarshaller::getInstance(),
Model\QueryOrderInfoResponseUnMarshaller::getInstance());
return $this->clientHandler->execute($clientExecutionParams);
}
/**
* @param Model\QueryPosTrxInfoRequest $request
* @return Model\QueryPosTrxInfoResponse
* @throws YopClientException
*/
public function queryPosTrxInfo(Model\QueryPosTrxInfoRequest $request)
{
if ($request == null) {
throw new YopClientException("request is required.");
}
$clientExecutionParams = new ClientExecutionParams($request, Model\QueryPosTrxInfoRequestMarshaller::getInstance(),
Model\QueryPosTrxInfoResponseUnMarshaller::getInstance());
return $this->clientHandler->execute($clientExecutionParams);
}
/**
* @param Model\QueryShopBindListRequest $request
* @return Model\QueryShopBindListResponse
* @throws YopClientException
*/
public function queryShopBindList(Model\QueryShopBindListRequest $request)
{
if ($request == null) {
throw new YopClientException("request is required.");
}
if ($request->getParentMerchantNo() == null) {
throw new YopClientException("request.parentMerchantNo is required.");
}
if ($request->getShopNo() == null) {
throw new YopClientException("request.shopNo is required.");
}
if ($request->getMerchantNo() == null) {
throw new YopClientException("request.merchantNo is required.");
}
$clientExecutionParams = new ClientExecutionParams($request, Model\QueryShopBindListRequestMarshaller::getInstance(),
Model\QueryShopBindListResponseUnMarshaller::getInstance());
return $this->clientHandler->execute($clientExecutionParams);
}
/**
* @param Model\UnbindRequest $request
* @return Model\UnbindResponse
* @throws YopClientException
*/
public function unbind(Model\UnbindRequest $request)
{
if ($request == null) {
throw new YopClientException("request is required.");
}
$clientExecutionParams = new ClientExecutionParams($request, Model\UnbindRequestMarshaller::getInstance(),
Model\UnbindResponseUnMarshaller::getInstance());
return $this->clientHandler->execute($clientExecutionParams);
}
/**
* @param Model\UpdateShopRequest $request
* @return Model\UpdateShopResponse
* @throws YopClientException
*/
public function updateShop(Model\UpdateShopRequest $request)
{
if ($request == null) {
throw new YopClientException("request is required.");
}
$clientExecutionParams = new ClientExecutionParams($request, Model\UpdateShopRequestMarshaller::getInstance(),
Model\UpdateShopResponseUnMarshaller::getInstance());
return $this->clientHandler->execute($clientExecutionParams);
}
}

View File

@@ -0,0 +1,77 @@
<?php
namespace Yeepay\Yop\Sdk\Service\Offline;
use Yeepay\Yop\Sdk\Auth\AuthorityReqRegistryImpl;
use Yeepay\Yop\Sdk\Auth\AuthorizationReqRegistry;
use Yeepay\Yop\Sdk\Auth\AuthorizationReqSupport;
use Yeepay\Yop\Sdk\Client\ClientParams;
use Yeepay\Yop\Sdk\Client\Support\ClientParamsSupport;
use Yeepay\Yop\Sdk\Config\AppSdkConfig;
use Yeepay\Yop\Sdk\Config\AppSdkConfigProvider;
use Yeepay\Yop\Sdk\Config\DefaultAppSdkConfigProvider;
use Yeepay\Yop\Sdk\Exception\YopClientException;
class OfflineClientBuilder
{
/**
* @var AuthorizationReqRegistry
*/
private static $authorizationReqRegistry;
public static function __init()
{
self::$authorizationReqRegistry = new AuthorityReqRegistryImpl();
self::$authorizationReqRegistry->register('bind', AuthorizationReqSupport::getAuthorizationReq('YOP-RSA2048-SHA256'));
self::$authorizationReqRegistry->register('createShop', AuthorizationReqSupport::getAuthorizationReq('YOP-RSA2048-SHA256'));
self::$authorizationReqRegistry->register('getShop', AuthorizationReqSupport::getAuthorizationReq('YOP-RSA2048-SHA256'));
self::$authorizationReqRegistry->register('operateShop', AuthorizationReqSupport::getAuthorizationReq('YOP-RSA2048-SHA256'));
self::$authorizationReqRegistry->register('queryAgentList', AuthorizationReqSupport::getAuthorizationReq('YOP-RSA2048-SHA256'));
self::$authorizationReqRegistry->register('queryOrderInfo', AuthorizationReqSupport::getAuthorizationReq('YOP-RSA2048-SHA256'));
self::$authorizationReqRegistry->register('queryPosTrxInfo', AuthorizationReqSupport::getAuthorizationReq('YOP-RSA2048-SHA256'));
self::$authorizationReqRegistry->register('queryShopBindList', AuthorizationReqSupport::getAuthorizationReq('YOP-RSA2048-SHA256'));
self::$authorizationReqRegistry->register('unbind', AuthorizationReqSupport::getAuthorizationReq('YOP-RSA2048-SHA256'));
self::$authorizationReqRegistry->register('updateShop', AuthorizationReqSupport::getAuthorizationReq('YOP-RSA2048-SHA256'));
}
/**
* @var ClientParams
*/
private $clientParams;
/**
* OfflineClientBuilder constructor.
* @param ClientParams $clientParams
*/
public function __construct(ClientParams $clientParams)
{
$this->clientParams = $clientParams;
}
public function build()
{
return new OfflineClient($this->clientParams);
}
/**
* @param $config AppSdkConfig|array|AppSdkConfigProvider
* @return OfflineClientBuilder
* @throws YopClientException
*/
public static function builder($config)
{
$appSdkConfigProvider = null;
if ($config instanceof AppSdkConfigProvider) {
$appSdkConfigProvider = $config;
} else {
$appSdkConfigProvider = new DefaultAppSdkConfigProvider($config);
}
$clientParams = ClientParamsSupport::generateClientParams($appSdkConfigProvider);
$clientParams->setAuthorizationReqRegistry(self::$authorizationReqRegistry);
return new OfflineClientBuilder($clientParams);
}
}
OfflineClientBuilder::__init();