Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Snitz Forums 2000 DEV-Group
 DEV Bug Reports (Closed)
 (v3.4.03) BUG+FIX: Delete all topics from a forum
 Forum Locked  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

Rasco
Advanced Member

Germany
3192 Posts

Posted - 20 November 2002 :  18:44:56  Show Profile  Send Rasco an ICQ Message
Going into the Admin Options --> Archive Forum Topics --> Delete all topics from a forum it should show a date with the last deletion time after having deleted all topics from it. Instead it still reads N/A.

German Snitz Forum

Edited by - Davio on 07 March 2003 10:19:52

Rasco
Advanced Member

Germany
3192 Posts

Posted - 07 February 2003 :  06:18:29  Show Profile  Send Rasco an ICQ Message
Bump, since we got on this again

German Snitz Forum
Go to Top of Page

davemaxwell
Access 2000 Support Moderator

USA
3020 Posts

Posted - 07 February 2003 :  07:42:08  Show Profile  Visit davemaxwell's Homepage  Send davemaxwell an AOL message  Send davemaxwell an ICQ Message  Send davemaxwell a Yahoo! Message
Are you talking about the default page that shows the last post date? If so, N/A would be correct because there are no posts in that forum, so there is no date to display. Archived or not doesn't matter.

Dave Maxwell
Barbershop Harmony Freak
Go to Top of Page

Rasco
Advanced Member

Germany
3192 Posts

Posted - 07 February 2003 :  11:35:27  Show Profile  Send Rasco an ICQ Message
No, that`s not the default page. It still shows N/A after deleting all topics from a forum.

German Snitz Forum
Go to Top of Page

Deleted
deleted

4116 Posts

Posted - 07 February 2003 :  13:04:32  Show Profile
As far as I understand, the F_L_DELETE field is supposed to keep the last deletion date. In admin_forums.asp this value is checked against "" (default field creation value) or null, and shows "N/A" if either one is true. The problem is it never gets updated, so it continues to show N/A...

If I'm not mistakin', in Sub subdoupdates() near line 832 adding the red line will do the job.


	strSql = "UPDATE " & strTablePrefix & "FORUM "
	strSql = strSql & " SET F_COUNT = " & intF_COUNT
	strSql = strSql & ",  F_TOPICS = " & intF_TOPICS
	strSql = strSql & ",  F_A_COUNT = " & intF_A_COUNT
	strSql = strSql & ",  F_A_TOPICS = " & intF_A_TOPICS
	strSql = strSql & ",  F_L_DELETE = " & datetostr(now()) 
	strSql = strSql & " WHERE FORUM_ID = " & rs("FORUM_ID")


Stop the WAR!
Go to Top of Page

Deleted
deleted

4116 Posts

Posted - 14 February 2003 :  13:10:39  Show Profile
The solution above is not correct as the sub subdoupdates is called from different places. I'm waiting for ideas...

Stop the WAR!
Go to Top of Page

Davio
Development Team Member

Jamaica
12217 Posts

Posted - 14 February 2003 :  23:29:20  Show Profile
Grrr, I just typed my entire post to this and it didn't get posted (my internet connection). Now I lost the contents of my post.

Anyways, the short version of this is, here is the code to update the deletion date.
After line 645, in admin_forums.asp (in the subdeletestuff() sub) add this bit of code:
'#### Update FORUM last delete posts date
strsql = "UPDATE " & strTablePrefix & "FORUM SET F_L_DELETE= '" & DateToStr(now()) & "'"
strsql = strsql & fIDSQL
my_conn.execute(strsql),,adCmdText + adExecuteNoRecords
Should look something like this after you add the code:
strsql = "DELETE FROM " & strTablePrefix & "TOPICS " & fIDSQL
my_conn.execute(strsql),,adCmdText + adExecuteNoRecords
strsql = "DELETE FROM " & strTablePrefix & "REPLY " & fIDSQL
my_conn.execute(strsql),,adCmdText + adExecuteNoRecords
	
'#### Update FORUM last delete posts date
strsql = "UPDATE " & strTablePrefix & "FORUM SET F_L_DELETE= '" & DateToStr(now()) & "'"
strsql = strsql & fIDSQL
my_conn.execute(strsql),,adCmdText + adExecuteNoRecords
	
Call subdoupdates()
This will show the date when the admin last deleted topics.

There is also a check against F_DELETE_SCHED to see if a deletion is overdue. But since we don't have any reminder page for deleting topics (like we do for archive reminder), the F_DELETE_SCHED field is not updated. So the check is useless.

My 2 possible suggestions:
1) Add a "Configure Delete Topics Reminder" option so admins can configure how many days they want to delete topics.
2) Forget #1 and remove the delete overdue check. The date will just be shown when they last deleted topics.

I don't think we need to do #1. How many admins delete topics from thier forums that they need a reminder? They can just look on the date and see how long ago they deleted topics. If we go with #1, we can just use a copy of the "Configure Archive Reminder" page and modify it.

Support Snitz Forums
Go to Top of Page

Deleted
deleted

4116 Posts

Posted - 15 February 2003 :  00:28:16  Show Profile
Thank you Davio I was trying to avoid another sql, but this is the correct way :) Implemented in v4b04 alpha 03...

I second you suggestion and also suggest to leave the overdue check as is as it does not harm as it is. The value of "overdue" (around lines 140) will be false anyways.

Stop the WAR!
Go to Top of Page

Davio
Development Team Member

Jamaica
12217 Posts

Posted - 15 February 2003 :  12:51:35  Show Profile
You're Welcome.

Fixed in 3.4.04.

Support Snitz Forums

Edited by - Davio on 07 March 2003 10:18:33
Go to Top of Page
  Previous Topic Topic Next Topic  
 Forum Locked  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.18 seconds. Powered By: Snitz Forums 2000 Version 3.4.07