Revize 1808
Přidáno uživatelem Michal Kliment před téměř 12 roky(ů)
transfers.php | ||
---|---|---|
$last_datetime = $transfer_model->find_last_transfer_datetime_by_type(
|
||
Transfer_Model::DEDUCT_MEMBER_FEE
|
||
);
|
||
echo $last_datetime;
|
||
|
||
if ($last_datetime)
|
||
$max_date = date_parse($last_datetime);
|
||
... | ... | |
)->find();
|
||
// creation datetime of transfers
|
||
$creation_datetime = date('Y-m-d H:i:s');
|
||
|
||
// status message
|
||
$message = '';
|
||
|
||
try
|
||
{
|
||
$db = new Transfer_Model();
|
||
... | ... | |
if ($fee && $fee->id)
|
||
$default_fee = $fee->fee;
|
||
else
|
||
throw new Exception(__('Fatal error'), __('Fees have not been set!'));
|
||
{
|
||
$message = __('Error').': '.url_lang::lang('texts.Default fee for date %s have not been set!', $date);
|
||
throw new Exception($message);
|
||
}
|
||
// finds regular member fee for this member and this month
|
||
$fee = $fee_model->get_fee_by_member_date_type(
|
||
$account->member_id, $date, 'regular member fee'
|
||
... | ... | |
{
|
||
$db->transaction_rollback();
|
||
Log::add_exception($e);
|
||
status::error('Error - some fees have not been recounted.');
|
||
status::error($message);
|
||
}
|
||
url::redirect('transfers/show_by_account/' . $account_id);
|
||
}
|
Také k dispozici: Unified diff
Opravy:
- fixes #416 - Neosetreni absence vychozich poplatku