Resource icon

[bd] Banking 1.0.4

No permission to download
I'v already read the options page, and even just re-read them. There is no where that mentions the change of the "money" or the bank image.
Sorry, I was wrong. The 0.9.9.1 version doesn't have the text in the options page yet. Here is a screenshot FYI:

Screen Shot 2013-01-13 at 2.26.34 AM.webp
 
Alright then. Any idea when this next update will be available? Right now the last thing I see is the Show System Transactions.
 
Would you perhaps consider phrasing the $? We might want to change currencies, for examnple to virtual currency, and having that option would make a world of difference for us :)
 
Just thought I'd share how I get my a list of richest members
I've limited this query to 50 users but you can extend or decrease this by editing the LIMIT 50 to LIMIT *insert number here*

I set this up in
library/OXY/Bank/index.php
You can change that route any way you'd like. Thes OXY directory don't exist for anyone unless they've installed one of my add-ons.
You may add this your own directory or create a new one.

I followed jake's php in page here:
http://xenforo.com/community/thread...ent-db-and-display-them-in-a-page-node.42311/

and then customized the query.
PHP:
<?php
 
class OXY_Bank_index
{
    public static function banklb(XenForo_ControllerPublic_Abstract $controller, XenForo_ControllerResponse_Abstract &$response)
    {
$mydb = XenForo_Application::get('db');
 
    $myrows = $mydb->fetchAll("
            SELECT *
            FROM xf_user
            WHERE bdbank_money > 1
            ORDER BY bdbank_money DESC
            LIMIT 50
");
 
 
 
        $response->params['myrows'] = $myrows;
 
    }
}

Then I went to the page node and for callback I used
OXY_Bank_index :: banklb

and used
Code:
<xen:foreach loop="$myrows" value="$myrow" i="$i" count="$count">
    {$i}. {$myrow.username} - {$myrow.bdbank_money}<br>
</xen:foreach><br>

$i does the ranking/counting
$myrow.username grabs the username
$myrow.bdbank_money grabs the amount of money they have
 
Use a query?

I haven't installed the add-on, so I cannot verify which tables to hit, but it probably uses the user table for storage of the amounts, so the query would be something like:

Code:
UPDATE xf_user
SET bankBalance = 0;
How exactly do I do this? Do I have to go into the server just to reset everyone's amounts to zero? What if I have an ADMIN that I want to do this task who does not have access to my server? Is there a better way that an ADMIN can perform this function of resetting everyones monies to zero please? Thanks!
 
How exactly do I do this? Do I have to go into the server just to reset everyone's amounts to zero? What if I have an ADMIN that I want to do this task who does not have access to my server? Is there a better way that an ADMIN can perform this function of resetting everyones monies to zero please? Thanks!

I usually use MySQL Workbench or phpMyAdmin to run queries.

I would be *very* careful about allowing anyone who is not proficient in SQL to run queries directly on your database, as one wrong (or malicious) move could wipe your database.

An alternative would be asking the developer to add some capabilities in the admin CP to reset particular or all accounts.
 
I usually use MySQL Workbench or phpMyAdmin to run queries.

I would be *very* careful about allowing anyone who is not proficient in SQL to run queries directly on your database, as one wrong (or malicious) move could wipe your database.

An alternative would be asking the developer to add some capabilities in the admin CP to reset particular or all accounts.
Yes, actually that's what I was asking when I said 'is there a better way...'. Don't plan on anyone ever getting inside of my server ;-)
 
Top Bottom