Ignore:
Timestamp:
Dec 7, 2021, 11:08:42 PM (3 years ago)
Author:
chronos
Message:
  • Added: Allow to switch Mail class into test mode.
  • Modified: Type checking related changes.
  • Modified: Replace global $Config references with $this->System->Config is possible.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Modules/Finance/Manage.php

    r912 r916  
    4949
    5050  /* Get first day and last day of given billing period. Periods are aligned with year start/end. */
    51   function GetBillingPeriod($Period)
     51  function GetBillingPeriod(int $Period): array
    5252  {
    5353    $Time = time();
     
    7373  }
    7474
    75   function ShowMonthlyPayment()
     75  function ShowMonthlyPayment(): string
    7676  {
    7777    if (!ModuleUser::Cast($this->System->GetModule('User'))->User->CheckPermission('Finance', 'Manage')) return 'Nemáte oprávnění';
     
    126126  }
    127127
    128   function InsertInvoice($Subject, $TimeCreation, $TimeDue, $Items,
    129     $Group, $PeriodFrom, $PeriodTo)
     128  function InsertInvoice(string $Subject, string $TimeCreation, string $TimeDue, array $Items,
     129    array $Group, float $PeriodFrom, float $PeriodTo): string
    130130  {
    131131    global $LastInsertTime;
     
    156156  }
    157157
    158   function ProduceInvoices()
     158  function ProduceInvoices(): string
    159159  {
    160160    $Output = '';
     
    224224  }
    225225
    226   function TableUpdateChanges($Table)
     226  function TableUpdateChanges(string $Table): void
    227227  {
    228228    $Time = time();
     
    256256  }
    257257
    258   function ProcessTableUpdates()
     258  function ProcessTableUpdates(): string
    259259  {
    260260    // Update customers
     
    277277  }
    278278
    279   function ProcessMonthlyPayment()
     279  function ProcessMonthlyPayment(): string
    280280  {
    281281    if (!ModuleUser::Cast($this->System->GetModule('User'))->User->CheckPermission('Finance', 'Manage')) return 'Nemáte oprávnění';
     
    344344  }
    345345
    346   function SendPaymentEmail($MemberId, $FileId = '')
     346  function SendPaymentEmail(string $MemberId, string $FileId = ''): string
    347347  {
    348348    global $Config;
     
    418418  }
    419419
    420   function GenerateInvoice($Where)
     420  function GenerateInvoice(string $Where): string
    421421  {
    422422    $DirectoryId = ModuleFinance::Cast($this->System->GetModule('Finance'))->Finance->DirectoryId;
     
    447447  }
    448448
    449   function GenerateOperation($Where)
     449  function GenerateOperation(string $Where): string
    450450  {
    451451    $DirectoryId = ModuleFinance::Cast($this->System->GetModule('Finance'))->Finance->DirectoryId;
     
    476476  }
    477477
    478   function GenerateBills()
     478  function GenerateBills(): string
    479479  {
    480480    $Output = '';
Note: See TracChangeset for help on using the changeset viewer.