Commit 5b6a3b62 by xmy

Merge remote-tracking branch 'origin/master'

parents 59354456 3932dc40
......@@ -22,14 +22,13 @@ interface BargainInterface
{
/**
* 获取砍价商品的 商品信息
* @param int $bargain_id
* @return mixed
*/
public function getgoodsinfo(
int $bargain_id
public function getGoodsInfo(
int $stordId,int $bargain_id
);
}
\ No newline at end of file
......@@ -33,4 +33,14 @@ interface CommissionInterface
*/
public function addBalanceCommission($storeId, $buyerId, $money);
/**
* 增加累计现金额
*
* @param $storeId
* @param $buyerId
* @param $money
* @return bool
*/
public function addTotalCommission($storeId, $buyerId, $money);
}
\ No newline at end of file
......@@ -28,7 +28,7 @@ use Swoft\Redis\Redis;
*/
class User
{
private $id;
private $id=2;
private $nickname;
......@@ -36,7 +36,7 @@ class User
private $headImg;
private $token;
private $token="3333E";
private $cmId;
......
......@@ -9,7 +9,7 @@ namespace Hdll\Services\Common\Exception;
class ExceptionParseData
{
public static function parseData(\Exception $e)
public static function parseData(\Throwable $e)
{
if ( is_callable([$e,'getResponse']) ) {
$response = $e->getResponse();
......@@ -19,6 +19,7 @@ class ExceptionParseData
$msg = isset($data['0'])?$data['0']:'';
$data = json_decode($msg,true);
$data = empty($data)?$response:$data;
} else {
$data['msg'] = $e->getMessage();
$data['code'] = 500;
......
......@@ -12,6 +12,7 @@ namespace Hdll\Services\Common\Pool\Config;
use Swoft\Bean\Annotation\Bean;
use Swoft\Pool\PoolProperties;
use Swoft\Bean\Annotation\Value;
/**
* @Bean()
......@@ -19,7 +20,6 @@ use Swoft\Pool\PoolProperties;
*/
class BargainPoolConfig extends PoolProperties
{
protected $name = 'bargain';
/**
......@@ -73,7 +73,7 @@ class BargainPoolConfig extends PoolProperties
* '127.0.0.1:88'
* ]
* </pre>
*
* @Value(name="", env="${RPC_BARGAIN_URI}")
* @var array
*/
protected $uri = [
......
......@@ -12,6 +12,7 @@ namespace Hdll\Services\Common\Pool\Config;
use Swoft\Bean\Annotation\Bean;
use Swoft\Pool\PoolProperties;
use Swoft\Bean\Annotation\Value;
/**
* the config of service user
......@@ -74,13 +75,10 @@ class ReservationPoolConfig extends PoolProperties
* '127.0.0.1:88'
* ]
* </pre>
*
* @Value(name="", env="${RPC_RESERVATION_URI}")
* @var array
*/
protected $uri = [
'192.168.3.23:8095',
'192.168.3.23:8095',
];
protected $uri = ['172.21.0.11:8099','172.16.255.6:8099'];
/**
* whether to user provider(consul/etcd/zookeeper)
......
......@@ -12,6 +12,7 @@ namespace Hdll\Services\Common\Pool\Config;
use Swoft\Bean\Annotation\Bean;
use Swoft\Pool\PoolProperties;
use Swoft\Bean\Annotation\Value;
/**
* the config of service user
......@@ -74,13 +75,10 @@ class SchedulePoolConfig extends PoolProperties
* '127.0.0.1:88'
* ]
* </pre>
*
* @Value(name="", env="${RPC_SCHEDULE_URI}")
* @var array
*/
protected $uri = [
'192.168.3.23:8096',
'192.168.3.23:8096',
];
protected $uri = ['172.21.0.23:8099','172.16.255.197:8099'];
/**
* whether to user provider(consul/etcd/zookeeper)
......
......@@ -78,7 +78,8 @@ class SellerPoolConfig extends PoolProperties
* @var array
*/
protected $uri = [
'192.168.3.39:8099',
'172.21.0.10:8099',
'172.16.255.196:8099',
];
/**
......
......@@ -12,6 +12,7 @@ namespace Hdll\Services\Common\Pool\Config;
use Swoft\Bean\Annotation\Bean;
use Swoft\Pool\PoolProperties;
use Swoft\Bean\Annotation\Value;
/**
* the config of service user
......@@ -74,12 +75,10 @@ class StorePoolConfig extends PoolProperties
* '127.0.0.1:88'
* ]
* </pre>
*
* @Value(name="", env="${RPC_STORE_URI}")
* @var array
*/
protected $uri = [
'192.168.3.23:8098',
];
protected $uri = ['172.21.0.44:8099','172.16.255.190:8099'];
/**
* whether to user provider(consul/etcd/zookeeper)
......
<?php
/**
* This file is part of Swoft.
*
* @link https://swoft.org
* @document https://doc.swoft.org
* @contact group@swoft.org
* @license https://github.com/swoft-cloud/swoft/blob/master/LICENSE
*/
namespace Hdll\Services\Common\Pool\Config;
use Swoft\Bean\Annotation\Bean;
use Swoft\Pool\PoolProperties;
use Swoft\Bean\Annotation\Value;
/**
* @Bean()
* the config of service bargain
*/
class TimeLimitBuyPoolConfig extends PoolProperties
{
protected $name = 'bargain';
/**
* Minimum active number of connections
*
* @var int
*/
protected $minActive = 5;
/**
* the maximum number of active connections
*
* @var int
*/
protected $maxActive = 50;
/**
* the maximum number of wait connections
*
* @var int
*/
protected $maxWait = 100;
/**
* Maximum waiting time
*
* @var int
*/
protected $maxWaitTime = 3;
/**
* Maximum idle time
*
* @var int
*/
protected $maxIdleTime = 60;
/**
* the time of connect timeout
*
* @var int
*/
protected $timeout = 5;
/**
* the addresses of connection
*
* <pre>
* [
* '127.0.0.1:88',
* '127.0.0.1:88'
* ]
* </pre>
* @Value(name="", env="${RPC_BARGAIN_URI}")
* @var array
*/
protected $uri = [
'172.21.0.34:8099',
'172.16.255.241:8099',
];
/**
* whether to user provider(consul/etcd/zookeeper)
*
* @var bool
*/
protected $useProvider = false;
/**
* the default balancer is random balancer
*
* @var string
*/
protected $balancer = '';
/**
* the default provider is consul provider
*
* @var string
*/
protected $provider = '';
}
<?php
/**
* This file is part of Swoft.
*
* @link https://swoft.org
* @document https://doc.swoft.org
* @contact group@swoft.org
* @license https://github.com/swoft-cloud/swoft/blob/master/LICENSE
*/
namespace Hdll\Services\Common\Pool\Config;
use Swoft\Bean\Annotation\Bean;
use Swoft\Pool\PoolProperties;
/**
* the config of service WithdrawCash
*
* @Bean()
*/
class WithdrawCashPoolConfig extends PoolProperties
{
protected $name = 'withdrawCash';
/**
* Minimum active number of connections
*
* @var int
*/
protected $minActive = 5;
/**
* the maximum number of active connections
*
* @var int
*/
protected $maxActive = 50;
/**
* the maximum number of wait connections
*
* @var int
*/
protected $maxWait = 100;
/**
* Maximum waiting time
*
* @var int
*/
protected $maxWaitTime = 3;
/**
* Maximum idle time
*
* @var int
*/
protected $maxIdleTime = 60;
/**
* the time of connect timeout
*
* @var int
*/
protected $timeout = 5;
/**
* the addresses of connection
*
* <pre>
* [
* '127.0.0.1:88',
* '127.0.0.1:88'
* ]
* </pre>
*
* @var array
*/
protected $uri = [
'192.168.3.12:8002',
];
/**
* whether to user provider(consul/etcd/zookeeper)
*
* @var bool
*/
protected $useProvider = false;
/**
* the default balancer is random balancer
*
* @var string
*/
protected $balancer = '';
/**
* the default provider is consul provider
*
* @var string
*/
protected $provider = '';
}
......@@ -39,16 +39,13 @@ interface LimitTimeBuyInterface
int $selected_num,
int $order_type,
int $goods_id,
string $reservation_time = '');
string $reservation_time );
/**
* 获取限时购商品的 商品信息
* @param int $limit_id
* @return mixed
*/
public function getLimitgoods(
int $limit_id
);
}
\ No newline at end of file
public function getLimitGoods(
int $sellerId,int $limitId
);}
\ No newline at end of file
......@@ -26,7 +26,7 @@ class OrderEnum
const TYPE_GOODS = 0; //商品订单
const TYPE_CUT_PRICE = 1; //砍价订单
const TYPE_LIMIT = 2; //限时购订单
const TYPE_COLLECTION = 3; //限时购订单
const TYPE_COLLECTION = 3; //拼团
//对账状态
const BALANCE_STATE_FALSE = 0; //未对账
......
<?php
/**
* 买家佣金提现接口
*
* @link https://swoft.org
* @document https://doc.swoft.org
* @contact group@swoft.org
* @license https://github.com/swoft-cloud/swoft/blob/master/LICENSE
*/
namespace Hdll\Services\WithdrawCash\Lib;
use Swoft\Core\ResultInterface;
/**
* The interface of BuyerCnDrawInterface service
*
* @method ResultInterface deferPaySuccess(int $storeId,int $id,string $wxOrderSn,int $fee)
* @method ResultInterface deferPayFailed(int $storeId,int $id,string $message)
*/
interface BuyerCnDrawInterface{
/**
* 支付成功接口
*
* @param integer $storeId 店铺ID
* @param integer $id 提现记录ID
* @param string $wxOrderSn 微信支付订单号
* @param integer $fee 手续费
* @return void
*/
public function paySuccess(int $storeId,int $id,string $wxOrderSn,int $fee);
/**
* 支付失败接口
*
* @param integer $storeId 店铺ID
* @param integer $id 提现记录ID
* @param string $message 失败信息
* @return void
*/
public function payFailed(int $storeId,int $id,string $message);
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment