|
@@ -31,10 +31,31 @@ class RefundService extends BaseService {
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
- * @return OrderInfo
|
|
|
*/
|
|
|
public function getOrderInfo($field=null)
|
|
|
{
|
|
|
return is_null($field)?$this->orderInfo:$this->orderInfo[$field];
|
|
|
}
|
|
|
+
|
|
|
+ /**
|
|
|
+ * @return int
|
|
|
+ */
|
|
|
+ public function getNum()
|
|
|
+ {
|
|
|
+ if($this->num>$this->getOrderInfo('num')){
|
|
|
+ return $this->getOrderInfo('num');
|
|
|
+ }
|
|
|
+ return $this->num;
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * @return int
|
|
|
+ */
|
|
|
+ public function getNumInstall(): int
|
|
|
+ {
|
|
|
+ if($this->num_install>$this->getOrderInfo('num_install')){
|
|
|
+ return $this->getOrderInfo('num');
|
|
|
+ }
|
|
|
+ return $this->num_install;
|
|
|
+ }
|
|
|
}
|