Changeset 204 for trunk/finance/user_state.php
- Timestamp:
- May 1, 2009, 12:13:50 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/finance/user_state.php
r179 r204 38 38 $DbResult = $this->Database->query('SELECT * FROM Member LEFT JOIN MemberPayment ON MemberPayment.Member=Member.Id WHERE Member.Subject='.$Subject['Id']); 39 39 $Member = $DbResult->fetch_assoc(); 40 $TarifName = $Finance->Tarif y[$Member['InternetTariffCurrentMonth']]['name'];41 $TarifPrice = $Finance->Tarif y[$Member['InternetTariffCurrentMonth']]['price'];40 $TarifName = $Finance->Tariffs[$Member['InternetTariffCurrentMonth']]['Name']; 41 $TarifPrice = $Finance->Tariffs[$Member['InternetTariffCurrentMonth']]['Price']; 42 42 $Output = '<table width="100%" border="0" cellspacing="0" cellpadding="3"><tr><td valign="top">'; 43 43 … … 68 68 $Output .= 'Variabilní symbol pro platby: <strong>'.$Subject['Id'].'</strong><br><br>'; 69 69 70 $Total = 0;70 $Total = 0; 71 71 $Output .= 'Rozpis měsíčního poplatku:<br><table class="WideTable">'. 72 72 '<tr><th>Část</th><th>Cena [Kč]</th></tr>'. 73 73 '<tr><td>Internet - tarif '.$TarifName.'</td><td>'.$TarifPrice.'</td></tr>'; 74 $Total += $TarifPrice; 75 if($Member['MonthlyPlus'] != 0) 76 $Output .= '<tr><td>Příjem za spotřebu</td><td>'.(-$Member['MonthlyPlus']) .'</td></tr>'; 77 $Total += -$Member['MonthlyPlus']; 74 $Total += $TarifPrice; 75 if($Member['Hire'] != 0) 76 { 77 $Output .= '<tr><td>Nájem</td><td>'.(-$Member['Hire']).'</td></tr>'; 78 $Total -= $Member['Hire']; 79 } 80 if($Member['MonthlyPlus'] != 0) 81 { 82 $Output .= '<tr><td>Příjem za spotřebu</td><td>'.(-$Member['MonthlyPlus']).'</td></tr>'; 83 $Total -= $Member['MonthlyPlus']; 84 } 78 85 $Output .= '<tr><td><strong>Celkem</strong></td><td><strong>'.$Total.'</strong></td></tr></table>'; 79 86 //echo('Tarif pro příští měsíc: '.$Tarify[$Row2['inet_tarif_next']]['name'].'<br><br>'); … … 82 89 if($Member['MonthlyPlus'] != 0) 83 90 { 84 91 $Output .= 'Měsíční příjem za spotřebu zařízení umístěných u uživatele:<br>'; 85 92 $Output .= '<table class="WideTable"><tr><th>Název zařízení</th><th>Spotřeba [W]</th><th>Příjem [Kč]</th></tr>'; 86 93 $DbResult = $this->Database->query('SELECT * FROM network_devices WHERE user='.$Member['Id'].' AND used=1');
Note:
See TracChangeset
for help on using the changeset viewer.