vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Beta Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=34)
-   -   Show Expiration Date in Subscription Manager List (https://vborg.vbsupport.ru/showthread.php?t=62237)

Amzadi 03-06-2004 10:00 PM

Show Expiration Date in Subscription Manager List
 
This will show you the expiration date right beside the start date on the Paid Subscription Manager list. See what it will look like in the attached jpg. Tested and working on VB3 RC4. I created this because I got sick and tired of clicking edit on each subscription to see the darn dates. You can also make a print out of the list now and see who has what and for how long. Feel free to PM me if you have any questions.

Time to Install: 1 minute
Changes to 1 PHP file only! No template or database modifications.

Step 1: FIND in AdminCP/Subscriptions.php
PHP Code:

print_table_header(construct_phrase($vbphrase['showing_subscriptions_x_to_y_of_z'], ($limitstart 1), iif($limitfinish $countusers['users'], $countusers['users'], $limitfinish), $countusers[users]), 5);
print_cells_row(array($vbphrase['title'], $vbphrase['username'], $vbphrase['start_date'], $vbphrase['status'], $vbphrase['controls']), 1); 

- Replace with
PHP Code:

print_table_header(construct_phrase($vbphrase['showing_subscriptions_x_to_y_of_z'], ($limitstart 1), iif($limitfinish $countusers['users'], $countusers['users'], $limitfinish), $countusers[users]), 6);
print_cells_row(array($vbphrase['title'], $vbphrase['username'], $vbphrase['start_date'], $vbphrase['expiry_date'], $vbphrase['status'], $vbphrase['controls']), 1); 

This extends the cells 1 column and adds the additional field.

Step 2: FIND in AdminCP/Subscriptions.php (same file a couple lines down)
PHP Code:

$cell[] = vbdate($vboptions['dateformat'], $user['regdate']); 

- Add the following below it
PHP Code:

$cell[] = vbdate($vboptions['dateformat'], $user['expirydate']); 

YOU'RE DONE!!!

Andreas 03-07-2004 04:11 AM

Nice one!

But you forgot one instruction:

Step 1a: FIND in admincp/subscriptions.php
PHP Code:

print_cells_row(array($vbphrase['title'], $vbphrase['username'], $vbphrase['start_date'], $vbphrase['status'], $vbphrase['controls']), 1); 

- Replace with
PHP Code:

print_cells_row(array($vbphrase['title'], $vbphrase['username'], $vbphrase['start_date'], $vbphrase['expiry_date'], $vbphrase['status'], $vbphrase['controls']), 1); 

[high]* Andreas clicks install[/high]

Amzadi 03-07-2004 04:32 AM

Duh! I was in such a hurry to get the format right, I forgot to add that line. Nice catch, I edited the original install script they way it should have read. :)

Boofo 03-07-2004 04:39 AM

Excellent little idea! Thank you, sir. ;)

gmarik 03-07-2004 09:33 AM

good one

Koutaru 03-07-2004 03:59 PM

Thanks for this ;) Installing..

UDPride 03-07-2006 05:04 AM

This doesnt seem to work in 3.5.x

I got a date of 1/1/1970 for an expiration date for my one subscription. Hmm.

I wish subscriptions had much better accounting tools than it does. Anyone?


All times are GMT. The time now is 09:53 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01062 seconds
  • Memory Usage 1,738KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (6)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (7)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete