View previous topic :: View next topic |
Author |
Message |
CompuFreak
Joined: 31 Mar 2009 Posts: 2 Location: Jamestown, NY
|
Posted: Tue Mar 31, 2009 6:58 pm Post subject: Daily Time Limits |
|
|
I see several posts about giving users a daily allotment of data transfer, but I'm wondering if the same idea is possible with time? We would like to have a "free user" class that is allowed 1 hour of time each day without manually giving each free user 60 minutes under "when airtime credit is used up" each day. The users can purchase more time after that, or come back after midnight and have another free hour the next day. Is there anyway to reset the time limit daily similar to resetting the data transfer counter? |
|
Back to top |
|
|
alan Forum facilitator
Joined: 26 Sep 2003 Posts: 4435
|
Posted: Wed Apr 01, 2009 4:31 am Post subject: |
|
|
Yes. You need to write a simple SQL statement to reset the field "timeleft" to 60 at midnight. Refer to chapter 5 of firstspot_guide.pdf for the definition for the user table fsusr.
Also, please refer to http://patronsoft.com/forum/viewtopic.php?t=1514 for a guideline in manipulating datasource. _________________ ~ Patronsoft Limited ~ |
|
Back to top |
|
|
CompuFreak
Joined: 31 Mar 2009 Posts: 2 Location: Jamestown, NY
|
Posted: Wed Apr 01, 2009 10:10 pm Post subject: |
|
|
OK that makes sense. Is there any way to do this by plan though, so that certain users in a "free" plan get their airtime reset to 60 each day, but other users in various other paying plans are not affected? I do not see anywhere in that table where plan is referred to. |
|
Back to top |
|
|
alan Forum facilitator
Joined: 26 Sep 2003 Posts: 4435
|
Posted: Thu Apr 02, 2009 8:29 am Post subject: |
|
|
No. Plan is really a template of user attributes that is used when one creates users through the Configuration Manager. The user is not linked to the Plan after the creation. _________________ ~ Patronsoft Limited ~ |
|
Back to top |
|
|
capitantrip
Joined: 30 Jul 2009 Posts: 2 Location: Milano, ITALY
|
Posted: Thu Jul 30, 2009 9:11 am Post subject: |
|
|
Please could you post the SQL query for resetting the TIMELEFT filed with MSQRY32.EXE? this is very important for a deployment we have to do but i can't manage it by myself
Thank You |
|
Back to top |
|
|
chrisli Forum facilitator
Joined: 23 Nov 2006 Posts: 22
|
Posted: Thu Jul 30, 2009 9:36 am Post subject: |
|
|
please use
update fsusr set timeleft = 60 where reserved1 is NULL; _________________ ~ Patronsoft Limited ~ |
|
Back to top |
|
|
capitantrip
Joined: 30 Jul 2009 Posts: 2 Location: Milano, ITALY
|
Posted: Thu Jul 30, 2009 8:33 pm Post subject: |
|
|
Thank you, i got i!!! |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
Powered by phpBB © 2001, 2005 phpBB Group
| |