charlottezweb Posted August 7, 2015 Share Posted August 7, 2015 Hopefully this is something simple I'm somehow overlooking. Right now in 6.0.1 for me, when a customer "adds funds" to their account, I don't see anywhere in their Client Area where they can see their balance. Am I missing something? I can see the invoice where they added funds and in the WHMCS admin area, I can see the credit balance but I'm not seeing anything obvious where the customer can view that balance. Can someone advise? Thanks! -Jason 0 Quote Link to comment Share on other sites More sharing options...
charlottezweb Posted August 8, 2015 Author Share Posted August 8, 2015 I found out from a customer that it shows up under the Notifications hover/popup but it seems it should have a more prominent posting somewhere. Has anyone found a way to accomplish this? 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted August 9, 2015 Share Posted August 9, 2015 where would you want to see it? 0 Quote Link to comment Share on other sites More sharing options...
charlottezweb Posted August 10, 2015 Author Share Posted August 10, 2015 where would you want to see it? At a minimum I'd expect to display it on the "add funds" page itself. Some sort of "current balance" line there should be standard. Ideally, I'd love to have some sort of "cube" on the Client Area homepage that has an overall account status: Invoice amounts due, add funds balance, possibly the affiliate earnings available, etc. Maybe this could replace that "Affiliate Program" section at the bottom right, for example. 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted August 11, 2015 Share Posted August 11, 2015 At a minimum I'd expect to display it on the "add funds" page itself. Some sort of "current balance" line there should be standard. you could do that simply by modifying the clientareaaddfunds.tpl template - I believe all the variables you need are available to that page. Ideally, I'd love to have some sort of "cube" on the Client Area homepage that has an overall account status: Invoice amounts due, add funds balance, possibly the affiliate earnings available, etc. Maybe this could replace that "Affiliate Program" section at the bottom right, for example. it would require an action hook to add, modify or remove the homepage panels. http://docs.whmcs.com/Working_With_Client_Area_Home_Page_Panels 0 Quote Link to comment Share on other sites More sharing options...
charlottezweb Posted August 18, 2015 Author Share Posted August 18, 2015 you could do that simply by modifying the clientareaaddfunds.tpl template - I believe all the variables you need are available to that page. That makes sense and I can add the line for that but am unclear on where I find the variable (eg {$minimumamount}) to display for that. I'm assuming I could use the credit balance value there maybe but I'm not having any luck finding a list of all these values. Thank you for your help! 0 Quote Link to comment Share on other sites More sharing options...
charlottezweb Posted August 18, 2015 Author Share Posted August 18, 2015 I found {$client_credit} in the email templates section and that's likely what I'd want to display but it won't load when added to clientareaaddfunds.tpl. Do I need to do something to that template page so that it knows what that variable means? 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted August 19, 2015 Share Posted August 19, 2015 each page is provided with a different set of variables - and sometimes they're called different names in different pages (and usually not the same as those used on the email templates!). the usual trick is to add {debug} to the end of the template and view the page again in the browser - it should then open a popup window with a list of variables/arrays available to that page. if you do that in clientareaaddfunds.tpl, you should find the variable you're looking for - which I think should be {$clientsstats.creditbalance} ...and remember to remove {debug} from the template! 0 Quote Link to comment Share on other sites More sharing options...
lee-wservices Posted August 19, 2015 Share Posted August 19, 2015 Just add this where you want the balance to show up {if $clientsstats.incredit} <div class="alert alert-success"> <p><strong>{$LANG.availcreditbal}:</strong> {$LANG.availcreditbaldesc|sprintf2:$clientsstats.creditbalance}</p> </div> {/if} 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted August 19, 2015 Share Posted August 19, 2015 there are two problems with that... firstly, a cosmetic one in that it's never a good idea to quote code in the forum - as for some reason, a space can often (and has in this case) get added to the code which would prevent it from working... {if $clientsstats.incredit} <div class="alert alert-success"> <p><strong>{$LANG.availcreditbal}:</strong> {$LANG.availcreditbaldesc|sprintf2:$clientsstats.creditbalance}</p> </div> {/if} the second problem is that I think the OP wants a balance to show regardless of its value - and in your code, it would only show if the client had a credit balance greater than 0. personally, i'd just add a new row to the existing table. <tr> <td class="textright"><strong>{$LANG.availcreditbal}</strong></td> <td>{$clientsstats.creditbalance}</td> </tr> with the option of using a Language Override to create a new text string if you are unhappy with using the existing "Available Credit Balance" text. 0 Quote Link to comment Share on other sites More sharing options...
charlottezweb Posted August 19, 2015 Author Share Posted August 19, 2015 Thank you! {$clientsstats.creditbalance} was exactly what I was looking for. Cheers, Jason 0 Quote Link to comment Share on other sites More sharing options...
Nigel Posted July 29, 2023 Share Posted July 29, 2023 hello is there anyone to help, i want the balance to show on the side bar on the client area how can I add that 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.