diff --git a/app/Export/CSV/ProductSalesExport.php b/app/Export/CSV/ProductSalesExport.php index 2504f17f36f9..1ff054da07ba 100644 --- a/app/Export/CSV/ProductSalesExport.php +++ b/app/Export/CSV/ProductSalesExport.php @@ -25,6 +25,7 @@ class ProductSalesExport extends BaseExport { public string $date_key = 'created_at'; + /** @var Collection<\App\Models\Product> $products*/ protected Collection $products; public Writer $csv; @@ -327,9 +328,9 @@ class ProductSalesExport extends BaseExport * getProduct * * @param string $product_key - * @return Product + * @return ?\App\Models\Product */ - private function getProduct(string $product_key): ?Product + private function getProduct(string $product_key): ?\App\Models\Product { return $this->products->firstWhere('product_key', $product_key); } diff --git a/app/Factory/BankIntegrationFactory.php b/app/Factory/BankIntegrationFactory.php index a69dc3813947..376321ff00d8 100644 --- a/app/Factory/BankIntegrationFactory.php +++ b/app/Factory/BankIntegrationFactory.php @@ -23,14 +23,13 @@ class BankIntegrationFactory $bank_integration->company_id = $company_id; $bank_integration->provider_name = ''; - $bank_integration->bank_account_id = ''; $bank_integration->bank_account_name = ''; $bank_integration->bank_account_number = ''; $bank_integration->bank_account_status = ''; $bank_integration->bank_account_type = ''; $bank_integration->balance = 0; $bank_integration->currency = ''; - $bank_integration->auto_sync = 1; + $bank_integration->auto_sync = true; return $bank_integration; } diff --git a/app/Factory/ClientFactory.php b/app/Factory/ClientFactory.php index e653c7f63355..7bb5bd13dbbb 100644 --- a/app/Factory/ClientFactory.php +++ b/app/Factory/ClientFactory.php @@ -29,7 +29,7 @@ class ClientFactory $client->balance = 0; $client->paid_to_date = 0; $client->country_id = null; - $client->is_deleted = 0; + $client->is_deleted = false; $client->client_hash = Str::random(40); $client->settings = ClientSettings::defaults(); $client->classification = ''; diff --git a/app/Factory/CloneQuoteToProjectFactory.php b/app/Factory/CloneQuoteToProjectFactory.php index e136b8d15104..f0fe7f0e4324 100644 --- a/app/Factory/CloneQuoteToProjectFactory.php +++ b/app/Factory/CloneQuoteToProjectFactory.php @@ -33,7 +33,7 @@ class CloneQuoteToProjectFactory $project->custom_value2 = ''; $project->custom_value3 = ''; $project->custom_value4 = ''; - $project->is_deleted = 0; + $project->is_deleted = false; return $project; } diff --git a/app/Factory/CompanyFactory.php b/app/Factory/CompanyFactory.php index 96c515ca3868..d9d11edad297 100644 --- a/app/Factory/CompanyFactory.php +++ b/app/Factory/CompanyFactory.php @@ -48,7 +48,7 @@ class CompanyFactory $company->markdown_email_enabled = true; $company->markdown_enabled = false; $company->tax_data = new TaxModel(); - $company->first_month_of_year = 1; + $company->first_month_of_year = '1'; $company->smtp_encryption = 'tls'; $company->smtp_host = ''; $company->smtp_local_domain = ''; diff --git a/app/Factory/VendorFactory.php b/app/Factory/VendorFactory.php index d569c0cfe4e9..560a75c1a89a 100644 --- a/app/Factory/VendorFactory.php +++ b/app/Factory/VendorFactory.php @@ -26,7 +26,7 @@ class VendorFactory $vendor->private_notes = ''; $vendor->public_notes = ''; $vendor->country_id = 4; - $vendor->is_deleted = 0; + $vendor->is_deleted = false; $vendor->vendor_hash = Str::random(40); // $vendor->classification = ''; diff --git a/app/Http/Controllers/AccountController.php b/app/Http/Controllers/AccountController.php index 12f53d7b7d38..fca1806e1632 100644 --- a/app/Http/Controllers/AccountController.php +++ b/app/Http/Controllers/AccountController.php @@ -61,7 +61,7 @@ class AccountController extends BaseController * Store a newly created resource in storage. * * @param CreateAccountRequest $request - * @return Response + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response * */ public function store(CreateAccountRequest $request) diff --git a/app/Http/Controllers/Auth/ForgotPasswordController.php b/app/Http/Controllers/Auth/ForgotPasswordController.php index 74effaffe029..47f8efd624a1 100644 --- a/app/Http/Controllers/Auth/ForgotPasswordController.php +++ b/app/Http/Controllers/Auth/ForgotPasswordController.php @@ -46,7 +46,7 @@ class ForgotPasswordController extends Controller /** * @param Request $request - * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\RedirectResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response|\Illuminate\Http\RedirectResponse * @throws \Illuminate\Validation\ValidationException */ public function sendResetLinkEmail(Request $request) diff --git a/app/Http/Controllers/Auth/LoginController.php b/app/Http/Controllers/Auth/LoginController.php index d3bc62acc412..aa27b98927cc 100644 --- a/app/Http/Controllers/Auth/LoginController.php +++ b/app/Http/Controllers/Auth/LoginController.php @@ -179,7 +179,7 @@ class LoginController extends BaseController * Refreshes the data feed with the current Company User. * * @param Request $request - * @return Response|JsonResponse + * @return \Illuminate\Http\Response|JsonResponse */ public function refresh(Request $request) { diff --git a/app/Http/Controllers/BankTransactionRuleController.php b/app/Http/Controllers/BankTransactionRuleController.php index 0b812943db55..517c5bfb034d 100644 --- a/app/Http/Controllers/BankTransactionRuleController.php +++ b/app/Http/Controllers/BankTransactionRuleController.php @@ -99,7 +99,7 @@ class BankTransactionRuleController extends BaseController * * @param ShowBankTransactionRuleRequest $request * @param BankTransactionRule $bank_transaction_rule - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response|\Illuminate\Http\Response * * * @OA\Get( @@ -154,7 +154,7 @@ class BankTransactionRuleController extends BaseController * * @param EditBankTransactionRuleRequest $request * @param BankTransactionRule $bank_transaction_rule - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response * * * @OA\Get( @@ -208,7 +208,7 @@ class BankTransactionRuleController extends BaseController * * @param UpdateBankTransactionRuleRequest $request * @param BankTransactionRule $bank_transaction_rule - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response * * * @@ -269,7 +269,7 @@ class BankTransactionRuleController extends BaseController * Show the form for creating a new resource. * * @param CreateBankTransactionRuleRequest $request - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response * * * @@ -317,7 +317,7 @@ class BankTransactionRuleController extends BaseController * Store a newly created resource in storage. * * @param StoreBankTransactionRuleRequest $request - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response * * * @@ -369,7 +369,7 @@ class BankTransactionRuleController extends BaseController * * @param DestroyBankTransactionRuleRequest $request * @param BankTransactionRule $bank_transaction_rule - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response * * * @throws \Exception diff --git a/app/Http/Controllers/ClientController.php b/app/Http/Controllers/ClientController.php index 8305c8782c9e..4fd0dd2dc428 100644 --- a/app/Http/Controllers/ClientController.php +++ b/app/Http/Controllers/ClientController.php @@ -305,7 +305,7 @@ class ClientController extends BaseController * * @param PurgeClientRequest $request * @param Client $client - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response * */ public function purge(PurgeClientRequest $request, Client $client) @@ -333,7 +333,7 @@ class ClientController extends BaseController * @param PurgeClientRequest $request * @param Client $client * @param string $mergeable_client - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response * */ @@ -365,7 +365,7 @@ class ClientController extends BaseController * * @param PurgeClientRequest $request * @param Client $client - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response */ public function updateTaxData(PurgeClientRequest $request, Client $client) { @@ -381,7 +381,7 @@ class ClientController extends BaseController * * @param ReactivateClientEmailRequest $request * @param string $bounce_id //could also be the invitationId - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response */ public function reactivateEmail(ReactivateClientEmailRequest $request, string $bounce_id) { diff --git a/app/Http/Controllers/ClientPortal/TempRouteController.php b/app/Http/Controllers/ClientPortal/TempRouteController.php index f85edb8ca8b5..7bb4b24704f1 100644 --- a/app/Http/Controllers/ClientPortal/TempRouteController.php +++ b/app/Http/Controllers/ClientPortal/TempRouteController.php @@ -13,14 +13,13 @@ namespace App\Http\Controllers\ClientPortal; use App\Http\Controllers\Controller; use Illuminate\Support\Facades\Cache; -use Illuminate\Support\Facades\Redirect; class TempRouteController extends Controller { /** * Logs a user into the client portal using their contact_key * @param string $hash The hash - * @return Redirect + * @return \Illuminate\View\View */ public function index(string $hash) { diff --git a/app/Http/Controllers/ConnectedAccountController.php b/app/Http/Controllers/ConnectedAccountController.php index 91f7c2d3fa92..532a5bd7a914 100644 --- a/app/Http/Controllers/ConnectedAccountController.php +++ b/app/Http/Controllers/ConnectedAccountController.php @@ -38,7 +38,7 @@ class ConnectedAccountController extends BaseController * Connect an OAuth account to a regular email/password combination account * * @param Request $request - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response * * * @OA\Post( diff --git a/app/Http/Controllers/Contact/LoginController.php b/app/Http/Controllers/Contact/LoginController.php index eb084aa250c7..1369ff0ef8d7 100644 --- a/app/Http/Controllers/Contact/LoginController.php +++ b/app/Http/Controllers/Contact/LoginController.php @@ -58,7 +58,7 @@ class LoginController extends BaseController * * @param Request $request The request * - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response * @throws \Illuminate\Validation\ValidationException */ public function apiLogin(Request $request) diff --git a/app/Http/Controllers/ImportController.php b/app/Http/Controllers/ImportController.php index a262c2459ab0..807340fa1e57 100644 --- a/app/Http/Controllers/ImportController.php +++ b/app/Http/Controllers/ImportController.php @@ -27,7 +27,7 @@ class ImportController extends Controller * * @param PreImportRequest $request * - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response * * @OA\Post( * path="/api/v1/preimport", diff --git a/app/Http/Controllers/MigrationController.php b/app/Http/Controllers/MigrationController.php index bb5cc463ba52..85fec16ab097 100644 --- a/app/Http/Controllers/MigrationController.php +++ b/app/Http/Controllers/MigrationController.php @@ -80,7 +80,7 @@ class MigrationController extends BaseController * ), * ) * @param Company $company - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response * @throws \Exception */ public function purgeCompany(Company $company) @@ -171,7 +171,7 @@ class MigrationController extends BaseController * ) * @param Request $request * @param Company $company - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response */ public function purgeCompanySaveSettings(Request $request, Company $company) { @@ -255,7 +255,7 @@ class MigrationController extends BaseController * ), * ) * @param Request $request - * @return \Illuminate\Http\JsonResponse|void + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response|void */ public function startMigration(Request $request) { diff --git a/app/Http/Controllers/QuoteController.php b/app/Http/Controllers/QuoteController.php index 1081676e387b..78656b078071 100644 --- a/app/Http/Controllers/QuoteController.php +++ b/app/Http/Controllers/QuoteController.php @@ -692,7 +692,7 @@ class QuoteController extends BaseController * @param ActionQuoteRequest $request * @param Quote $quote * @param $action - * @return \Illuminate\Http\JsonResponse|Response|mixed|\Symfony\Component\HttpFoundation\StreamedResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response|Response|mixed|\Symfony\Component\HttpFoundation\StreamedResponse */ public function action(ActionQuoteRequest $request, Quote $quote, $action) { diff --git a/app/Http/Controllers/Support/Messages/SendingController.php b/app/Http/Controllers/Support/Messages/SendingController.php index 139e73a971d1..ad8646527de4 100644 --- a/app/Http/Controllers/Support/Messages/SendingController.php +++ b/app/Http/Controllers/Support/Messages/SendingController.php @@ -60,7 +60,7 @@ class SendingController extends Controller * ), * ) * @param Request $request - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response */ public function __invoke(Request $request) { diff --git a/app/Http/Controllers/TwilioController.php b/app/Http/Controllers/TwilioController.php index 8efb09a7135d..126ce23ea0fe 100644 --- a/app/Http/Controllers/TwilioController.php +++ b/app/Http/Controllers/TwilioController.php @@ -34,7 +34,7 @@ class TwilioController extends BaseController /** * Display a listing of the resource. * - * @return \Illuminate\Http\JsonResponse; + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response; */ public function generate(GenerateSmsRequest $request) { @@ -94,7 +94,7 @@ class TwilioController extends BaseController /** * Show the form for creating a new resource. * - * @return \Illuminate\Http\JsonResponse; + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response; */ public function confirm(ConfirmSmsRequest $request) { @@ -143,7 +143,7 @@ class TwilioController extends BaseController /** * generate2faResetCode * - * @return \Illuminate\Http\JsonResponse; + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response; */ public function generate2faResetCode(Generate2faRequest $request) { @@ -193,7 +193,7 @@ class TwilioController extends BaseController * confirm2faResetCode * * @param Confirm2faRequest $request - * @return \Illuminate\Http\JsonResponse; + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response; */ public function confirm2faResetCode(Confirm2faRequest $request) { diff --git a/app/Http/Controllers/UserController.php b/app/Http/Controllers/UserController.php index ad9c9835dd8b..a6494f808536 100644 --- a/app/Http/Controllers/UserController.php +++ b/app/Http/Controllers/UserController.php @@ -191,7 +191,7 @@ class UserController extends BaseController * * @param DestroyUserRequest $request * @param User $user - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response * */ public function destroy(DestroyUserRequest $request, User $user) @@ -253,7 +253,7 @@ class UserController extends BaseController * * @param DetachCompanyUserRequest $request * @param User $user - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response */ public function detach(DetachCompanyUserRequest $request, User $user) { @@ -283,7 +283,7 @@ class UserController extends BaseController * * @param ReconfirmUserRequest $request * @param User $user - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response */ public function invite(ReconfirmUserRequest $request, User $user) { @@ -301,7 +301,7 @@ class UserController extends BaseController * * @param ReconfirmUserRequest $request * @param User $user - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response */ public function reconfirm(ReconfirmUserRequest $request, User $user) { diff --git a/app/Http/Controllers/WebCronController.php b/app/Http/Controllers/WebCronController.php index aeb92cc7fb69..4a7fe11d837a 100644 --- a/app/Http/Controllers/WebCronController.php +++ b/app/Http/Controllers/WebCronController.php @@ -23,7 +23,7 @@ class WebCronController extends Controller /** * Store a newly created resource in storage. * - * @return \Illuminate\Http\JsonResponse + * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\Response * * @OA\Get( * path="/webcron", diff --git a/app/Models/Account.php b/app/Models/Account.php index d329961fa064..c78d23549b2a 100644 --- a/app/Models/Account.php +++ b/app/Models/Account.php @@ -71,7 +71,7 @@ use Laracasts\Presenter\PresentableTrait; * @property string|null $account_sms_verification_number * @property bool $account_sms_verified * @property string|null $bank_integration_account_id - * @property int $is_trial + * @property bool $is_trial * @property-read int|null $bank_integrations_count * @property-read int|null $companies_count * @property-read int|null $company_users_count diff --git a/app/Models/BankIntegration.php b/app/Models/BankIntegration.php index 5e50fdccb9b5..f651c4228027 100644 --- a/app/Models/BankIntegration.php +++ b/app/Models/BankIntegration.php @@ -29,7 +29,7 @@ use Illuminate\Database\Eloquent\SoftDeletes; * @property string|null $bank_account_status * @property string|null $bank_account_type * @property float $balance - * @property int|null $currency + * @property string|null $currency * @property string $nickname * @property string $nordigen_account_id * @property string $nordigen_institution_id diff --git a/app/Models/BankTransaction.php b/app/Models/BankTransaction.php index 28ecc36298a6..77f2219f9067 100644 --- a/app/Models/BankTransaction.php +++ b/app/Models/BankTransaction.php @@ -24,7 +24,7 @@ use Illuminate\Database\Eloquent\SoftDeletes; * @property int $bank_integration_id * @property int $transaction_id * @property string $nordigen_transaction_id - * @property string $amount + * @property float $amount * @property string|null $currency_code * @property int|null $currency_id * @property string|null $account_type @@ -41,7 +41,7 @@ use Illuminate\Database\Eloquent\SoftDeletes; * @property int|null $expense_id * @property int|null $vendor_id * @property int $status_id - * @property int $is_deleted + * @property bool $is_deleted * @property int|null $created_at * @property int|null $updated_at * @property int|null $deleted_at diff --git a/app/Models/BankTransactionRule.php b/app/Models/BankTransactionRule.php index 40a444cc49eb..229d6fc08fba 100644 --- a/app/Models/BankTransactionRule.php +++ b/app/Models/BankTransactionRule.php @@ -27,7 +27,7 @@ use Illuminate\Database\Eloquent\SoftDeletes; * @property int|null $client_id * @property int|null $vendor_id * @property int|null $category_id - * @property int $is_deleted + * @property bool $is_deleted * @property int|null $created_at * @property int|null $updated_at * @property int|null $deleted_at diff --git a/app/Models/ClientGatewayToken.php b/app/Models/ClientGatewayToken.php index 5e74ef1b902c..f8e45a688b3f 100644 --- a/app/Models/ClientGatewayToken.php +++ b/app/Models/ClientGatewayToken.php @@ -25,12 +25,12 @@ use Illuminate\Database\Eloquent\SoftDeletes; * @property int $company_gateway_id * @property string|null $gateway_customer_reference * @property int $gateway_type_id - * @property int $is_default + * @property bool $is_default * @property object|null $meta * @property int|null $deleted_at * @property int|null $created_at * @property int|null $updated_at - * @property int $is_deleted + * @property bool $is_deleted * @property-read \App\Models\Client|null $client * @property-read \App\Models\Company $company * @property-read \App\Models\CompanyGateway|null $gateway diff --git a/app/Models/Company.php b/app/Models/Company.php index c1c34080a5c9..c20d096c2453 100644 --- a/app/Models/Company.php +++ b/app/Models/Company.php @@ -59,7 +59,7 @@ use Laracasts\Presenter\PresentableTrait; * @property string|null $portal_domain * @property int $enable_modules * @property object $custom_fields - * @property \App\DataMapper\CompanySettings $settings + * @property \App\DataMapper\CompanySettings|\stdClass $settings * @property string $slack_webhook_url * @property string $google_analytics_key * @property int|null $created_at diff --git a/app/Models/CompanyGateway.php b/app/Models/CompanyGateway.php index 44f3c606ea6e..9311699f31e3 100644 --- a/app/Models/CompanyGateway.php +++ b/app/Models/CompanyGateway.php @@ -53,7 +53,6 @@ use Illuminate\Database\Eloquent\SoftDeletes; * @property-read \App\Models\Gateway $gateway * @property-read mixed $hashed_id * @method getConfigField(string $field) - * @method static \Illuminate\Database\Eloquent\Builder|BaseModel company() * @method static \Illuminate\Database\Eloquent\Builder|CompanyGateway filter(\App\Filters\QueryFilters $filters) * @method static \Illuminate\Database\Eloquent\Builder|CompanyGateway newModelQuery() * @method static \Illuminate\Database\Eloquent\Builder|CompanyGateway newQuery() diff --git a/app/Models/Credit.php b/app/Models/Credit.php index b20000e8ff44..4c53fd62cbb8 100644 --- a/app/Models/Credit.php +++ b/app/Models/Credit.php @@ -46,7 +46,7 @@ use Laracasts\Presenter\PresentableTrait; * @property string|null $date * @property string|null $last_sent_date * @property string|null $due_date - * @property int $is_deleted + * @property bool $is_deleted * @property array|null $line_items * @property object|null $backup * @property string|null $footer @@ -60,7 +60,7 @@ use Laracasts\Presenter\PresentableTrait; * @property string|null $tax_name3 * @property float $tax_rate3 * @property string $total_taxes - * @property int $uses_inclusive_taxes + * @property bool $uses_inclusive_taxes * @property string|null $custom_value1 * @property string|null $custom_value2 * @property string|null $custom_value3 diff --git a/app/Models/Expense.php b/app/Models/Expense.php index eb9ee205ca6f..4b944aecb1c8 100644 --- a/app/Models/Expense.php +++ b/app/Models/Expense.php @@ -36,7 +36,7 @@ use Illuminate\Database\Eloquent\SoftDeletes; * @property bool $is_deleted * @property float $amount * @property float $foreign_amount - * @property string $exchange_rate + * @property float $exchange_rate * @property string|null $tax_name1 * @property float $tax_rate1 * @property string|null $tax_name2 @@ -60,8 +60,8 @@ use Illuminate\Database\Eloquent\SoftDeletes; * @property float $tax_amount1 * @property float $tax_amount2 * @property float $tax_amount3 - * @property int $uses_inclusive_taxes - * @property int $calculate_tax_by_amount + * @property bool $uses_inclusive_taxes + * @property bool $calculate_tax_by_amount * @property-read \App\Models\User|null $assigned_user * @property-read \App\Models\ExpenseCategory|null $category * @property-read \App\Models\Client|null $client diff --git a/app/Models/GroupSetting.php b/app/Models/GroupSetting.php index 18556b10e343..88d12d0f2745 100644 --- a/app/Models/GroupSetting.php +++ b/app/Models/GroupSetting.php @@ -28,7 +28,7 @@ use Illuminate\Database\Eloquent\SoftDeletes; * @property int|null $deleted_at * @property int|null $created_at * @property int|null $updated_at - * @property int $is_deleted + * @property bool $is_deleted * @property-read \Illuminate\Database\Eloquent\Collection $clients * @property-read int|null $clients_count * @property-read \App\Models\Company $company diff --git a/app/Models/PaymentTerm.php b/app/Models/PaymentTerm.php index 10a2102e2f50..c1bbcde291c5 100644 --- a/app/Models/PaymentTerm.php +++ b/app/Models/PaymentTerm.php @@ -21,7 +21,7 @@ use Illuminate\Database\Eloquent\SoftDeletes; * @property string|null $name * @property int|null $company_id * @property int|null $user_id - * @property int $is_deleted + * @property bool $is_deleted * @property int|null $created_at * @property int|null $updated_at * @property int|null $deleted_at diff --git a/app/Models/PurchaseOrder.php b/app/Models/PurchaseOrder.php index 63912a90ca91..d536310fd881 100644 --- a/app/Models/PurchaseOrder.php +++ b/app/Models/PurchaseOrder.php @@ -54,7 +54,7 @@ use Illuminate\Support\Carbon; * @property string|null $tax_name3 * @property float $tax_rate3 * @property float $total_taxes - * @property int $uses_inclusive_taxes + * @property bool $uses_inclusive_taxes * @property string|null $reminder1_sent * @property string|null $reminder2_sent * @property string|null $reminder3_sent diff --git a/app/Models/Quote.php b/app/Models/Quote.php index ada153dc18f7..283d55b3aeb2 100644 --- a/app/Models/Quote.php +++ b/app/Models/Quote.php @@ -48,20 +48,20 @@ use Laracasts\Presenter\PresentableTrait; * @property string|null|Carbon $due_date * @property string|null $next_send_date * @property bool $is_deleted - * @property object|null $line_items + * @property array|null $line_items * @property object|null $backup * @property string|null $footer * @property string|null $public_notes * @property string|null $private_notes * @property string|null $terms * @property string|null $tax_name1 - * @property string $tax_rate1 + * @property float $tax_rate1 * @property string|null $tax_name2 - * @property string $tax_rate2 + * @property float $tax_rate2 * @property string|null $tax_name3 - * @property string $tax_rate3 + * @property float $tax_rate3 * @property string $total_taxes - * @property int $uses_inclusive_taxes + * @property bool $uses_inclusive_taxes * @property string|null $custom_value1 * @property string|null $custom_value2 * @property string|null $custom_value3 @@ -87,7 +87,7 @@ use Laracasts\Presenter\PresentableTrait; * @property string|null $reminder2_sent * @property string|null $reminder3_sent * @property string|null $reminder_last_sent - * @property string $paid_to_date + * @property float $paid_to_date * @property int|null $subscription_id * @property \App\Models\User|null $assigned_user * @property \App\Models\Client $client diff --git a/app/Models/RecurringExpense.php b/app/Models/RecurringExpense.php index b8ba39ee7c55..2775ab500bfc 100644 --- a/app/Models/RecurringExpense.php +++ b/app/Models/RecurringExpense.php @@ -33,30 +33,30 @@ use Illuminate\Support\Carbon; * @property int|null $payment_type_id * @property int|null $recurring_expense_id * @property bool $is_deleted - * @property int $uses_inclusive_taxes + * @property bool $uses_inclusive_taxes * @property string|null $tax_name1 * @property string|null $tax_name2 * @property string|null $tax_name3 * @property string|null $date * @property string|null $payment_date - * @property int $should_be_invoiced - * @property int $invoice_documents + * @property bool $should_be_invoiced + * @property bool $invoice_documents * @property string|null $transaction_id * @property string|null $custom_value1 * @property string|null $custom_value2 * @property string|null $custom_value3 * @property string|null $custom_value4 * @property int|null $category_id - * @property int $calculate_tax_by_amount - * @property string|null $tax_amount1 - * @property string|null $tax_amount2 - * @property string|null $tax_amount3 - * @property string|null $tax_rate1 - * @property string|null $tax_rate2 - * @property string|null $tax_rate3 - * @property string|null $amount - * @property string|null $foreign_amount - * @property string $exchange_rate + * @property bool $calculate_tax_by_amount + * @property float|null $tax_amount1 + * @property float|null $tax_amount2 + * @property float|null $tax_amount3 + * @property float|null $tax_rate1 + * @property float|null $tax_rate2 + * @property float|null $tax_rate3 + * @property float|null $amount + * @property float|null $foreign_amount + * @property float|null $exchange_rate * @property int|null $assigned_user_id * @property string|null $number * @property int|null $invoice_currency_id diff --git a/app/Models/RecurringInvoice.php b/app/Models/RecurringInvoice.php index 975b0f638e65..097d53b302b4 100644 --- a/app/Models/RecurringInvoice.php +++ b/app/Models/RecurringInvoice.php @@ -40,7 +40,7 @@ use Laracasts\Presenter\PresentableTrait; * @property string|null $date * @property string|null $due_date * @property bool $is_deleted - * @property mixed $line_items + * @property array $line_items * @property object|null $backup * @property string|null $footer * @property string|null $public_notes @@ -72,17 +72,17 @@ use Laracasts\Presenter\PresentableTrait; * @property bool $auto_bill_enabled * @property int|null $design_id * @property bool $uses_inclusive_taxes - * @property string|null $custom_surcharge1 - * @property string|null $custom_surcharge2 - * @property string|null $custom_surcharge3 - * @property string|null $custom_surcharge4 + * @property float|null $custom_surcharge1 + * @property float|null $custom_surcharge2 + * @property float|null $custom_surcharge3 + * @property float|null $custom_surcharge4 * @property bool $custom_surcharge_tax1 * @property bool $custom_surcharge_tax2 * @property bool $custom_surcharge_tax3 * @property bool $custom_surcharge_tax4 * @property string|null $due_date_days * @property string|null $partial_due_date - * @property string $exchange_rate + * @property float $exchange_rate * @property float $paid_to_date * @property int|null $subscription_id * @property string|null $next_send_date_client diff --git a/app/Models/RecurringQuote.php b/app/Models/RecurringQuote.php index 1a554e6008e0..ef4c973d2644 100644 --- a/app/Models/RecurringQuote.php +++ b/app/Models/RecurringQuote.php @@ -34,31 +34,31 @@ use Laracasts\Presenter\PresentableTrait; * @property int|null $vendor_id * @property int $status_id * @property float $discount - * @property int $is_amount_discount + * @property bool $is_amount_discount * @property string|null $number * @property string|null $po_number * @property string|null $date * @property string|null $due_date - * @property int $is_deleted - * @property object|null $line_items + * @property bool $is_deleted + * @property array $line_items * @property object|null $backup * @property string|null $footer * @property string|null $public_notes * @property string|null $private_notes * @property string|null $terms * @property string|null $tax_name1 - * @property string $tax_rate1 + * @property float $tax_rate1 * @property string|null $tax_name2 - * @property string $tax_rate2 + * @property float $tax_rate2 * @property string|null $tax_name3 - * @property string $tax_rate3 - * @property string $total_taxes + * @property float $tax_rate3 + * @property float $total_taxes * @property string|null $custom_value1 * @property string|null $custom_value2 * @property string|null $custom_value3 * @property string|null $custom_value4 - * @property string $amount - * @property string $balance + * @property float $amount + * @property float $balance * @property string|null $last_viewed * @property int $frequency_id * @property int $design_id @@ -69,22 +69,22 @@ use Laracasts\Presenter\PresentableTrait; * @property int|null $updated_at * @property int|null $deleted_at * @property string $auto_bill - * @property int $auto_bill_enabled - * @property string $paid_to_date - * @property string|null $custom_surcharge1 - * @property string|null $custom_surcharge2 - * @property string|null $custom_surcharge3 - * @property string|null $custom_surcharge4 + * @property bool $auto_bill_enabled + * @property float $paid_to_date + * @property float|null $custom_surcharge1 + * @property float|null $custom_surcharge2 + * @property float|null $custom_surcharge3 + * @property float|null $custom_surcharge4 * @property int $custom_surcharge_tax1 * @property int $custom_surcharge_tax2 * @property int $custom_surcharge_tax3 * @property int $custom_surcharge_tax4 * @property string|null $due_date_days - * @property string $exchange_rate + * @property float $exchange_rate * @property float|null $partial * @property string|null $partial_due_date * @property int|null $subscription_id - * @property int $uses_inclusive_taxes + * @property bool $uses_inclusive_taxes * @property-read \Illuminate\Database\Eloquent\Collection $activities * @property-read int|null $activities_count * @property-read \App\Models\User|null $assigned_user diff --git a/app/Models/Subscription.php b/app/Models/Subscription.php index 5c963121afcd..bc0f759222c8 100644 --- a/app/Models/Subscription.php +++ b/app/Models/Subscription.php @@ -30,7 +30,7 @@ use Illuminate\Database\Eloquent\SoftDeletes; * @property string|null $auto_bill * @property string|null $promo_code * @property float $promo_discount - * @property int $is_amount_discount + * @property bool $is_amount_discount * @property int $allow_cancellation * @property int $per_seat_enabled * @property int $min_seats_limit diff --git a/app/Models/Task.php b/app/Models/Task.php index 6958f3964659..5875680fbec8 100644 --- a/app/Models/Task.php +++ b/app/Models/Task.php @@ -44,7 +44,7 @@ use Illuminate\Support\Carbon; * @property string|null $time_log * @property string|null $number * @property string $rate - * @property int $invoice_documents + * @property bool $invoice_documents * @property int $is_date_based * @property int|null $status_order * @property-read \App\Models\User|null $assigned_user diff --git a/app/Models/TaskStatus.php b/app/Models/TaskStatus.php index 170c5211ee34..23ca8e53d688 100644 --- a/app/Models/TaskStatus.php +++ b/app/Models/TaskStatus.php @@ -20,7 +20,7 @@ use Illuminate\Database\Eloquent\SoftDeletes; * @property string|null $name * @property int|null $company_id * @property int|null $user_id - * @property int $is_deleted + * @property bool $is_deleted * @property int|null $created_at * @property int|null $updated_at * @property int|null $deleted_at diff --git a/app/Models/Vendor.php b/app/Models/Vendor.php index 834f15a1ecb6..687eb966477f 100644 --- a/app/Models/Vendor.php +++ b/app/Models/Vendor.php @@ -37,7 +37,7 @@ use Laracasts\Presenter\PresentableTrait; * @property string|null $city * @property string|null $state * @property string|null $postal_code - * @property string|null $country_id + * @property int|null $country_id * @property string|null $phone * @property string|null $private_notes * @property string|null $website @@ -53,7 +53,7 @@ use Laracasts\Presenter\PresentableTrait; * @property string|null $vendor_hash * @property string|null $public_notes * @property string|null $id_number - * @property string|null $language_id + * @property int|null $language_id * @property int|null $last_login * @property-read \Illuminate\Database\Eloquent\Collection $activities * @property-read int|null $activities_count diff --git a/app/Models/Webhook.php b/app/Models/Webhook.php index 511abfbaca39..02eb4911f006 100644 --- a/app/Models/Webhook.php +++ b/app/Models/Webhook.php @@ -20,7 +20,7 @@ use Illuminate\Database\Eloquent\SoftDeletes; * @property int|null $company_id * @property int|null $user_id * @property int|null $event_id - * @property int $is_deleted + * @property bool $is_deleted * @property string $target_url * @property string $format * @property int|null $created_at diff --git a/phpstan.neon b/phpstan.neon index 5f666b05fb72..5c586c4bb520 100644 --- a/phpstan.neon +++ b/phpstan.neon @@ -3,7 +3,7 @@ includes: - ./vendor/spaze/phpstan-stripe/extension.neon - phpstan-baseline.neon parameters: - level: 2 + level: 3 paths: - app excludePaths: @@ -29,4 +29,5 @@ parameters: - '#makeHidden#' - '#Socialite#' - '#Access to protected property#' - - '#Call to undefined method .*#' \ No newline at end of file + - '#Call to undefined method .*#' + - '#Argument of an invalid type stdClass supplied for foreach, only iterables are supported.#' \ No newline at end of file