diff --git a/public/include/pages/admin/earnings.inc.php b/public/include/pages/admin/earnings.inc.php new file mode 100644 index 00000000..c4fe7015 --- /dev/null +++ b/public/include/pages/admin/earnings.inc.php @@ -0,0 +1,21 @@ +isAuthenticated()) { + if (!$smarty->isCached('master.tpl', $smarty_cache_key)) { + $iLimit = 30; + $debug->append('No cached version available, fetching from backend', 3); + if (!$setting->getValue('disable_transactionsummary')) { + $aTransactionSummary = $transaction->getTransactionSummary($_SESSION['USERDATA']['id']); + $aTransactionSummaryByTime = $transaction->getTransactionTypebyTime($_SESSION['USERDATA']['id']); + $smarty->assign('SUMMARY', $aTransactionSummary); + $smarty->assign('BYTIME', $aTransactionSummaryByTime); + } + } else { + $debug->append('Using cached page', 3); + } +} + +$smarty->assign('CONTENT', 'default.tpl'); +?> diff --git a/public/include/pages/admin/userdetails.inc.php b/public/include/pages/admin/userdetails.inc.php new file mode 100644 index 00000000..4bac75f4 --- /dev/null +++ b/public/include/pages/admin/userdetails.inc.php @@ -0,0 +1,24 @@ +isAuthenticated() || !$user->isAdmin($_SESSION['USERDATA']['id'])) { + header("HTTP/1.1 404 Page not found"); + die("404 Page not found"); +} + +if (!$smarty->isCached('master.tpl', $smarty_cache_key)) { + $debug->append('No cached version available, fetching from backend', 3); + if (isset($_REQUEST['id']) && !empty($_REQUEST['id'])) { + $aTransactionSummary = $transaction->getTransactionSummary($_REQUEST['id']); + $aTransactionSummaryByTime = $transaction->getTransactionTypebyTime($_REQUEST['id']); + $smarty->assign('USERNAME', $user->getUsername($_REQUEST['id'])); + $smarty->assign('SUMMARY', $aTransactionSummary); + $smarty->assign('BYTIME', $aTransactionSummaryByTime); + } +} else { + $debug->append('Using cached page', 3); +} + +$smarty->assign('CONTENT', 'default.tpl'); +?> diff --git a/public/templates/bootstrap/admin/user/default.tpl b/public/templates/bootstrap/admin/user/default.tpl index 8853efc5..987724ba 100644 --- a/public/templates/bootstrap/admin/user/default.tpl +++ b/public/templates/bootstrap/admin/user/default.tpl @@ -110,7 +110,7 @@ {section name=user loop=$USERS|default}
| {$type} | + {/foreach} +
|---|
| {$total|number_format:"8"} | + {/foreach} +
| + | Credit | +Bonus | +Debit AP | +Debit MP | +Donation | + {if $GLOBAL.fees > 0} +Fee | + {/if} +TXFee | +
|---|---|---|---|---|---|---|---|
| Last Hour + | {$BYTIME.1HourCredit|number_format:"8"} | +{$BYTIME.1HourBonus|number_format:"8"} | +{$BYTIME.1HourDebitAP|number_format:"8"} | +{$BYTIME.1HourDebitMP|number_format:"8"} | +{$BYTIME.1HourDonation|number_format:"8"} | + {if $GLOBAL.fees|default:"0" > 0} +{$BYTIME.1HourFee|number_format:"8"} | + {/if} +{$BYTIME.1HourTXFee|number_format:"8"} | +
| Last Day + | {$BYTIME.24HourCredit|number_format:"8"} | +{$BYTIME.24HourBonus|number_format:"8"} | +{$BYTIME.24HourDebitAP|number_format:"8"} | +{$BYTIME.24HourDebitMP|number_format:"8"} | +{$BYTIME.24HourDonation|number_format:"8"} | + {if $GLOBAL.fees|default:"0" > 0} +{$BYTIME.24HourFee|number_format:"8"} | + {/if} +{$BYTIME.24HourTXFee|number_format:"8"} | +
| Last Week + | {$BYTIME.1WeekCredit|number_format:"8"} | +{$BYTIME.1WeekBonus|number_format:"8"} | +{$BYTIME.1WeekDebitAP|number_format:"8"} | +{$BYTIME.1WeekDebitMP|number_format:"8"} | +{$BYTIME.1WeekDonation|number_format:"8"} | + {if $GLOBAL.fees|default:"0" > 0} +{$BYTIME.1WeekFee|number_format:"8"} | + {/if} +{$BYTIME.1WeekTXFee|number_format:"8"} | +
| Last Month + | {$BYTIME.1MonthCredit|number_format:"8"} | +{$BYTIME.1MonthBonus|number_format:"8"} | +{$BYTIME.1MonthDebitAP|number_format:"8"} | +{$BYTIME.1MonthDebitMP|number_format:"8"} | +{$BYTIME.1MonthDonation|number_format:"8"} | + {if $GLOBAL.fees|default:"0" > 0} +{$BYTIME.1MonthFee|number_format:"8"} | + {/if} +{$BYTIME.1MonthTXFee|number_format:"8"} | +
| Last Year + | {$BYTIME.1YearCredit|number_format:"8"} | +{$BYTIME.1YearBonus|number_format:"8"} | +{$BYTIME.1YearDebitAP|number_format:"8"} | +{$BYTIME.1YearDebitMP|number_format:"8"} | +{$BYTIME.1YearDonation|number_format:"8"} | + {if $GLOBAL.fees|default:"0" > 0} +{$BYTIME.1YearFee|number_format:"8"} | + {/if} +{$BYTIME.1YearTXFee|number_format:"8"} | +