Skip to content

Commit

Permalink
Merge pull request #401 from intuit/v6.0.1
Browse files Browse the repository at this point in the history
Release: Support for minor version 59 and adding showrows for report service
  • Loading branch information
abisalehalliprasan authored May 7, 2021
2 parents 73c395d + 918c276 commit a4139a9
Show file tree
Hide file tree
Showing 12 changed files with 16,156 additions and 15,935 deletions.
4 changes: 2 additions & 2 deletions src/Core/CoreConstants.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
class CoreConstants
{
//Set the default minor version
const DEFAULT_SDK_MINOR_VERSION = "57";
const DEFAULT_SDK_MINOR_VERSION = "59";
const DEFAULT_LOGGINGLOCATION = "/tmp/IdsLogs";

const PHP_CLASS_PREFIX = 'IPP';
Expand Down Expand Up @@ -297,7 +297,7 @@ class CoreConstants
* The Request source header value.
* @var string REQUESTSOURCEHEADER
*/
const USERAGENT = "V3PHPSDK6.0.0";
const USERAGENT = "V3PHPSDK6.0.1";

public static function getType($string, $return=1)
{
Expand Down
13 changes: 13 additions & 0 deletions src/Data/IPPCustomer.php
Original file line number Diff line number Diff line change
Expand Up @@ -593,6 +593,19 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
* @var string
*/
public $ClientEntityId;
/**
* @Definition
Product: QBO
Description: Originating source of
the Customer. Valid values are defined in SourceTypeEnum
* @xmlType element
* @xmlNamespace http://schema.intuit.com/finance/v3
* @xmlMinOccurs 0
* @xmlName Source
* @var string
*/
public $Source;


} // end class IPPCustomer
24 changes: 24 additions & 0 deletions src/Data/IPPInvoice.php
Original file line number Diff line number Diff line change
Expand Up @@ -295,6 +295,30 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
* @var string
*/
public $InvoiceLinkExpiryDate;
/**
* @Definition
Product: QBO
Description: Indicates whether the Recurring Invoice eligible for auto payment.
* @xmlType element
* @xmlNamespace http://schema.intuit.com/finance/v3
* @xmlMinOccurs 0
* @xmlName AutoPayEligible
* @var boolean
*/
public $AutoPayEligible;
/**
* @Definition
Product: QBO
Description: Indicates whether the Non-Recurring Invoice eligible for scheduled payment.
* @xmlType element
* @xmlNamespace http://schema.intuit.com/finance/v3
* @xmlMinOccurs 0
* @xmlName SchedulePayEligible
* @var boolean
*/
public $SchedulePayEligible;


} // end class IPPInvoice
13 changes: 13 additions & 0 deletions src/Data/IPPItem.php
Original file line number Diff line number Diff line change
Expand Up @@ -819,6 +819,19 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
* @var com\intuit\schema\finance\v3\IPPReferenceType
*/
public $ClassRef;
/**
* @Definition
Product: QBO
Description: Originating source of
the Item. Valid values are defined in SourceTypeEnum
* @xmlType element
* @xmlNamespace http://schema.intuit.com/finance/v3
* @xmlMinOccurs 0
* @xmlName Source
* @var string
*/
public $Source;


} // end class IPPItem
4 changes: 2 additions & 2 deletions src/Data/IPPRecurringInfo.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
*/
public $Name;
/**
* @Definition
* @Definition
Product: QBO
Description: The Recur Type which can be Automated, Reminded, UnScheduled or Manual.
Expand All @@ -64,7 +64,7 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
*/
public $RecurType;
/**
* @Definition
* @Definition
Product: QBO
Description: Indicates whether the Recurring Schedule is enabled.
Expand Down
22 changes: 11 additions & 11 deletions src/Data/IPPRecurringScheduleInfo.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
*/
public $IntervalType;
/**
* @Definition
* @Definition
Product: QBO
Description: The Interval based on the Interval Type
Expand All @@ -64,7 +64,7 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
*/
public $NumInterval;
/**
* @Definition
* @Definition
Product: QBO
Description: The Day of the Month
Expand All @@ -76,7 +76,7 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
*/
public $DayOfMonth;
/**
* @Definition
* @Definition
Product: QBO
Description: The Day of the Week
Expand All @@ -100,7 +100,7 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
*/
public $WeekOfMonth;
/**
* @Definition
* @Definition
Product: QBO
Description: The Month of the Year
Expand All @@ -112,7 +112,7 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
*/
public $MonthOfYear;
/**
* @Definition
* @Definition
Product: QBO
Description: The days before StartDate for a Reminded RecurType
Expand All @@ -124,7 +124,7 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
*/
public $RemindDays;
/**
* @Definition
* @Definition
Product: QBO
Description: The Days before the Scheduled Date
Expand All @@ -136,7 +136,7 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
*/
public $DaysBefore;
/**
* @Definition
* @Definition
Product: QBO
Description: The Max number of Recurring Occurrences
Expand All @@ -148,7 +148,7 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
*/
public $MaxOccurrences;
/**
* @Definition
* @Definition
Product: QBO
Description: The Start Date for the Recurring Schedule
Expand All @@ -160,7 +160,7 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
*/
public $StartDate;
/**
* @Definition
* @Definition
Product: QBO
Description: The End Date for the Recurring Schedule
Expand All @@ -172,7 +172,7 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
*/
public $EndDate;
/**
* @Definition
* @Definition
Product: QBO
Description: The Date when the next Transaction will created. (Read Only)
Expand All @@ -184,7 +184,7 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
*/
public $NextDate;
/**
* @Definition
* @Definition
Product: QBO
Description: The Date when the last Transaction was created.(Read Only)
Expand Down
48 changes: 48 additions & 0 deletions src/Data/IPPSourceTypeEnum.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
<?php
namespace QuickBooksOnline\API\Data;

/**
* @xmlNamespace http://schema.intuit.com/finance/v3
* @xmlType string
* @xmlName IPPSourceTypeEnum
* @var IPPSourceTypeEnum
* @xmlDefinition
Product: QBO
Description: Enumeration of external sources that create the entites in QBO
*/
class IPPSourceTypeEnum
{

/**
* Initializes this object, optionally with pre-defined property values
*
* Initializes this object and it's property members, using the dictionary
* of key/value pairs passed as an optional argument.
*
* @param dictionary $keyValInitializers key/value pairs to be populated into object's properties
* @param boolean $verbose specifies whether object should echo warnings
*/
public function __construct($keyValInitializers=array(), $verbose=FALSE)
{
foreach($keyValInitializers as $initPropName => $initPropVal)
{
if (property_exists('IPPSourceTypeEnum',$initPropName) || property_exists('QuickBooksOnline\API\Data\IPPSourceTypeEnum',$initPropName))
{
$this->{$initPropName} = $initPropVal;
}
else
{
if ($verbose)
echo "Property does not exist ($initPropName) in class (".get_class($this).")";
}
}
}

/**
* @xmlType value
* @var string
*/
public $value;

} // end class IPPSourceTypeEnum
13 changes: 13 additions & 0 deletions src/Data/IPPVendor.php
Original file line number Diff line number Diff line change
Expand Up @@ -455,6 +455,19 @@ public function __construct($keyValInitializers=array(), $verbose=FALSE)
* @var com\intuit\schema\finance\v3\IPPVendorBankAccountDetail
*/
public $VendorPaymentBankDetail;
/**
* @Definition
Product: QBO
Description: Originating source of
the Vendor. Valid values are defined in SourceTypeEnum
* @xmlType element
* @xmlNamespace http://schema.intuit.com/finance/v3
* @xmlMinOccurs 0
* @xmlName Source
* @var string
*/
public $Source;


} // end class IPPVendor
40 changes: 32 additions & 8 deletions src/ReportService/ReportService.php
Original file line number Diff line number Diff line change
Expand Up @@ -98,31 +98,32 @@ class ReportService
private $subcol_pct_inc = null;
private $subcol_pct_exp = null;
private $adjusted_gain_loss = null;
private $showrows = null;

public function getAdjustedGainLoss(){
return $this->adjusted_gain_loss;
return $this->adjusted_gain_loss;
}

public function setAdjustedGainLoss($adjustedGainLoss){
return $this->adjusted_gain_loss = $adjustedGainLoss;
return $this->adjusted_gain_loss = $adjustedGainLoss;
}

public function getPercentIncome(){
return $this->subcol_pct_inc;
return $this->subcol_pct_inc;
}

public function getPercentExpense(){
return $this->subcol_pct_exp;
return $this->subcol_pct_exp;
}

public function setPercentIncome($percentIncome){
$this->subcol_pct_inc = $percentIncome;
return $this;
$this->subcol_pct_inc = $percentIncome;
return $this;
}

public function setPercentExpense($percentExpense){
$this->subcol_pct_exp = $percentExpense;
return $this;
$this->subcol_pct_exp = $percentExpense;
return $this;
}
/**
* @return null
Expand Down Expand Up @@ -960,6 +961,25 @@ public function setDocNum($doc_num)
return $this;
}

/**
* @return null
*/
public function getShowRows()
{
return $this->showrows;
}

/**
* @param null $showrows
*
* @return $this
*/
public function setShowRows($showrows)
{
$this->showrows = $showrows;
return $this;
}

/**
* Returns serializer for response objects
* @return IEntitySerializer
Expand Down Expand Up @@ -1193,6 +1213,10 @@ private function getReportQueryParameters()
array_push($uriParameterList, ["adjusted_gain_loss", $this->getAdjustedGainLoss()]);
}

if (!is_null($this->showrows)) {
array_push($uriParameterList, ["showrows", $this->getShowRows()]);
}


foreach ($uriParameterList as $uriParameter) {
if (strlen($uriParameterString) > 0) {
Expand Down
Loading

0 comments on commit a4139a9

Please sign in to comment.