* use php-cs-fixer instead of phpcodesniffer * updated scrutinizer config * adjusted code yules to all files * updated CONTRIBUTING guidelines
This commit is contained in:
@@ -44,6 +44,7 @@ class ActivityStatistic
|
||||
public function setRecordAmount($recordAmount)
|
||||
{
|
||||
$this->recordAmount = (int) $recordAmount;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -64,6 +65,7 @@ class ActivityStatistic
|
||||
public function setRecordDuration($recordDuration)
|
||||
{
|
||||
$this->recordDuration = (int) $recordDuration;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -84,6 +86,7 @@ class ActivityStatistic
|
||||
public function setCount($count)
|
||||
{
|
||||
$this->count = (int) $count;
|
||||
|
||||
return $this;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -52,6 +52,7 @@ class CustomerStatistic
|
||||
public function setRecordAmount($recordAmount)
|
||||
{
|
||||
$this->recordAmount = (int) $recordAmount;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -72,6 +73,7 @@ class CustomerStatistic
|
||||
public function setRecordDuration($recordDuration)
|
||||
{
|
||||
$this->recordDuration = (int) $recordDuration;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -92,6 +94,7 @@ class CustomerStatistic
|
||||
public function setCount($count)
|
||||
{
|
||||
$this->count = (int) $count;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -110,6 +113,7 @@ class CustomerStatistic
|
||||
public function setActivityAmount($activityAmount)
|
||||
{
|
||||
$this->activityAmount = (int) $activityAmount;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -128,6 +132,7 @@ class CustomerStatistic
|
||||
public function setProjectAmount($projectAmount)
|
||||
{
|
||||
$this->projectAmount = (int) $projectAmount;
|
||||
|
||||
return $this;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,8 +13,6 @@ use App\Entity\Customer;
|
||||
use App\Entity\InvoiceTemplate;
|
||||
use App\Entity\Timesheet;
|
||||
use App\Invoice\CalculatorInterface;
|
||||
use App\Invoice\DateNumberGenerator;
|
||||
use App\Invoice\DefaultCalculator;
|
||||
use App\Invoice\NumberGeneratorInterface;
|
||||
use App\Repository\Query\InvoiceQuery;
|
||||
|
||||
@@ -23,7 +21,6 @@ use App\Repository\Query\InvoiceQuery;
|
||||
*/
|
||||
class InvoiceModel
|
||||
{
|
||||
|
||||
/**
|
||||
* @var Customer
|
||||
*/
|
||||
@@ -69,6 +66,7 @@ class InvoiceModel
|
||||
public function setQuery(InvoiceQuery $query)
|
||||
{
|
||||
$this->query = $query;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -89,6 +87,7 @@ class InvoiceModel
|
||||
public function setEntries(array $entries)
|
||||
{
|
||||
$this->entries = $entries;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -107,6 +106,7 @@ class InvoiceModel
|
||||
public function setTemplate($template)
|
||||
{
|
||||
$this->template = $template;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -125,6 +125,7 @@ class InvoiceModel
|
||||
public function setCustomer($customer)
|
||||
{
|
||||
$this->customer = $customer;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -133,7 +134,7 @@ class InvoiceModel
|
||||
*/
|
||||
public function getDueDate(): \DateTime
|
||||
{
|
||||
return new \DateTime('+'.$this->getTemplate()->getDueDays().' days');
|
||||
return new \DateTime('+' . $this->getTemplate()->getDueDays() . ' days');
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -152,6 +153,7 @@ class InvoiceModel
|
||||
{
|
||||
$this->generator = $generator;
|
||||
$this->generator->setModel($this);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -171,6 +173,7 @@ class InvoiceModel
|
||||
{
|
||||
$this->calculator = $calculator;
|
||||
$this->calculator->setModel($this);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
|
||||
@@ -48,6 +48,7 @@ class ProjectStatistic
|
||||
public function setRecordAmount($recordAmount)
|
||||
{
|
||||
$this->recordAmount = (int) $recordAmount;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -68,6 +69,7 @@ class ProjectStatistic
|
||||
public function setRecordDuration($recordDuration)
|
||||
{
|
||||
$this->recordDuration = (int) $recordDuration;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -88,6 +90,7 @@ class ProjectStatistic
|
||||
public function setCount($count)
|
||||
{
|
||||
$this->count = (int) $count;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -106,6 +109,7 @@ class ProjectStatistic
|
||||
public function setActivityAmount($activityAmount)
|
||||
{
|
||||
$this->activityAmount = (int) $activityAmount;
|
||||
|
||||
return $this;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -59,6 +59,7 @@ class Month
|
||||
public function setTotalDuration($totalDuration)
|
||||
{
|
||||
$this->totalDuration = $totalDuration;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -77,6 +78,7 @@ class Month
|
||||
public function setTotalRate($totalRate)
|
||||
{
|
||||
$this->totalRate = $totalRate;
|
||||
|
||||
return $this;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -46,7 +46,7 @@ class Year
|
||||
*/
|
||||
public function setMonth(Month $month)
|
||||
{
|
||||
$this->months[(int)$month->getMonth()] = $month;
|
||||
$this->months[(int) $month->getMonth()] = $month;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
namespace App\Model;
|
||||
|
||||
use \DateTime;
|
||||
use DateTime;
|
||||
|
||||
/**
|
||||
* Timesheet statistics for one user.
|
||||
|
||||
Reference in New Issue
Block a user