Simple Machines Community Forum

Customizing SMF => Modifications and Packages => Topic started by: SusanTN on September 03, 2006, 08:48:16 PM

Title: Log Mod Account Edits
Post by: SusanTN on September 03, 2006, 08:48:16 PM
Link to Mod (http://mods.simplemachines.org/index.php?mod=445)
Rate this Mod (http://mods.simplemachines.org/index.php?action=review;sa=add;mod=445)

LogModAccountEdits will record in the Moderation Log any account edits made by a user to any other account but their own. Currently SMF does not log account edits in the Moderation Log. This Module adds this important audit trail to the Moderation Log and records which user was edited (with a link to their account page, Display Name, and User ID). It also displays what section was edited. See the attached screenshot for a better picture of the function of this mod.


Screen Shot


(http://www.compu.net/LogModAccountEdits.jpg) (http://mods.simplemachines.org/index.php?action=download;mod=445;id=18494;image)

Revisions


1.0 Initial version
1.1 all strings were moved to the Language files.
1.2 Fixed a bug where a new line was not properly added which was resulting in an error log entry.
1.3 Bug wasn't from a new line, it was from language text and language file being different.
1.4 New Zip file after reports the old one was unopenable
1.5 removed line feed which wasn't susposed to be there.
1.6  Fixed version numbering

Title: Re: Log Mod Account Edits
Post by: Skipdawg on September 05, 2006, 05:47:04 PM
I'l have to check this out latter, looks like a rather useful Mod.  ;)
Title: Re: Log Mod Account Edits
Post by: LostProphecy on September 07, 2006, 06:46:20 PM
as will i :)

tell me in the future is it at all possible to further define what they change?

i've had a past issue when two of my admins have fought and one has accussed everyone else that they tampered with their post count, so defining it further would be great :) or is that virtually impossible?
Title: Re: Log Mod Account Edits
Post by: SusanTN on September 07, 2006, 08:47:06 PM
Quote from: LostProphecy on September 07, 2006, 06:46:20 PM
as will i :)

tell me in the future is it at all possible to further define what they change?

i've had a past issue when two of my admins have fought and one has accussed everyone else that they tampered with their post count, so defining it further would be great :) or is that virtually impossible?

I don't think it is possible, if anyone thinks different send me a pm with a suggestion

For what you want edit profile.php and find the following lines.....
                // Change the number of posts.
                if (isset($_POST['posts']) && allowedTo('moderate_forum'))
                        $profile_vars['posts'] = $_POST['posts'] != '' ? (int) strtr($_POST['posts'], array(',' => '', '.' => '', ' ' => '')) : '\'\'';


Change it to

                // Change the number of posts.
                if (isset($_POST['posts']) && allowedTo('moderate_forum')) {
                        $profile_vars['posts'] = $_POST['posts'] != '' ? (int) strtr($_POST['posts'], array(',' => '', '.' => '', ' ' => '')) : '\'\'';
                if ($memID != $ID_MEMBER) logAction($txt['LogModAccountEdits_Action'], array($txt['LogModAccountEdits_Which'] => '<a href="' . $scripturl. '?action=profile;u='. $memID .';sa=account">' . $user_profile[$memID]['realName'] . '</a>', $txt['LogModAccountEdits_Username'] => $user_profile[$memID]['memberName'], $txt['LogModAccountEdits_UserID'] => $memID, $txt['LogModAccountEdits_What'] => $txt[$_REQUEST['sa']], 'Changed Post Count' => $_POST['posts'],));
}


If you want to record a staff member editing thier own post counts, just remove the if ($memID != $ID_MEMBER) and leave the rest.

This may result in duplicate LogModAccountEdits log entries for edits of other user's post counts

By default, my mod will not record a moderator or administrator who's editing their own account, just ones editing others. 
Title: Re: Log Mod Account Edits
Post by: mrselnombre on December 12, 2006, 11:56:39 AM
working for 1.1?
Title: Re: Log Mod Account Edits
Post by: SusanTN on December 13, 2006, 05:28:07 PM
updated yesterday... Just download the newest version
Title: Re: Log Mod Account Edits
Post by: buhaychat.com on January 15, 2007, 01:41:50 AM
Clean install into 1.1.1 ... great mod, thanks!
Title: Re: Log Mod Account Edits
Post by: SusanTN on January 15, 2007, 02:31:37 AM
You are welcome :)
Title: Re: Log Mod Account Edits
Post by: robotman321 on March 04, 2007, 08:01:39 PM
this doesnt seem to work for me on 1.1.2 any reason why?
Title: Re: Log Mod Account Edits
Post by: SusanTN on March 05, 2007, 10:17:24 PM
Nope none. I checked on my forum which is running 1.1.2 and I have....

Edited user account Yesterday at 07:19:15 PM ME Administrator XXX.XXX.XXX.XXX
Which: auser Users name: auser User ID: 2704 What: Account Related Settings 

I am running the same version which is available on the package manager... Could another module you installed have caused a conflict? What does the forum error log show any issues?
Title: Re: Log Mod Account Edits
Post by: wm on March 06, 2007, 01:23:30 PM
The package info file does not have 1.1.2 listed yet.

Thanks for making this available!

William
Title: Re: Log Mod Account Edits
Post by: husam on April 27, 2007, 02:35:46 AM
can you make this work with 1.1.2?

I get this error:

Install Actions
Installations actions for "LogModAccountEdits":
The package you are trying to download or install is either corrupt or not compatible with this version of SMF.
Title: Re: Log Mod Account Edits
Post by: Mindriot on April 27, 2007, 03:02:41 AM
Would love to see this work for 1.1.2 as well.
Title: Re: Log Mod Account Edits
Post by: wm on April 27, 2007, 02:55:20 PM
It does work for 1.1.2, I'm using it, it's just the header in the package file has not been updated.  If memory serves I downloaded the files and edited them to change the version.
Title: Re: Log Mod Account Edits
Post by: SusanTN on May 02, 2007, 05:50:28 PM
Sorry, it's fixed.  I thought I had uploaded version 1.9 a long time ago when I removed the version check. Well it's up now!
Title: Re: Log Mod Account Edits
Post by: kamili34 on July 01, 2007, 10:12:43 AM
This mod install correct but I can't see any changes why ? What goes wrong ?

I see standard options :/
Title: Re: Log Mod Account Edits
Post by: SusanTN on July 01, 2007, 10:44:26 PM
Edit a user's profile and check the moderation log. If you see a log entry then it's working.

(http://www.compu.net/LogModAccountEdits.jpg)
Title: Re: Log Mod Account Edits
Post by: kamili34 on July 02, 2007, 12:51:32 AM
Yes it works how stupid i was.  :P
thakns for good mod

Regarts kamili34
Title: Re: Log Mod Account Edits
Post by: gregma on August 30, 2007, 01:22:12 PM
Version 1.9 on SMF version 1.1.3.  I'm getting the following errors:

Apply Filter: Only show the error messages of this URL  http://nwcdl.com/forum/index.php?action=modlog

Apply Filter: Only show the errors with the same message
8: Undefined index: modlog_ac_edited_account

File: /home/nwcdl/public_html/forum/Sources/Modlog.php
Line: 144

Ideas?
Title: Re: Log Mod Account Edits
Post by: bbbmmm on November 06, 2007, 08:29:26 AM
This is for only administrators right? Can I allow moderators to see this?
Title: Re: Log Mod Account Edits
Post by: Dragooon on November 06, 2007, 08:32:39 AM
Anyone who is allowed to see Moderation log can see this as it modifies it if I am correct.
Title: Re: Log Mod Account Edits
Post by: dumblonde on January 10, 2008, 01:48:22 PM
does this mod work with 1.1.4?  :D
Title: Re: Log Mod Account Edits
Post by: SusanTN on March 18, 2008, 03:13:48 AM
Quote from: bbbmmm on November 06, 2007, 08:29:26 AMThis is for only administrators right? Can I allow moderators to see this?

If they have the ability to "Administrate forum and database" they can see the moderator log.

This permission allows a user to:
change forum, database and theme settings
manage packages
use the forum and database maintenance tools
view the error and mod logs
Use this permission with caution, as it is very powerful.

I would probably leave that to people you really really really trust in my case administrator's only...
Title: Re: Log Mod Account Edits
Post by: SusanTN on March 18, 2008, 03:16:49 AM
Quote from: gregma on August 30, 2007, 01:22:12 PM
Version 1.9 on SMF version 1.1.3.  I'm getting the following errors:

Apply Filter: Only show the error messages of this URL  http://nwcdl.com/forum/index.php?action=modlog

Apply Filter: Only show the errors with the same message
8: Undefined index: modlog_ac_edited_account

Your In your themedir/language/Admin.english.php should have the following entries for Modlog. The Referenced index is missing from that file for some reason...


$txt['modlog_view'] = 'Moderation Log';
$txt['modlog_date'] = 'Date';
$txt['modlog_member'] = 'Member';
$txt['modlog_position'] = 'Position';
$txt['modlog_action'] = 'Action';
$txt['modlog_ip'] = 'IP';
$txt['modlog_search_result'] = 'Search Results';
$txt['modlog_total_entries'] = 'Total Entries';
$txt['modlog_ac_banned'] = 'Banned';
$txt['modlog_ac_edited_account'] = 'Edited User Account';
$txt['modlog_ac_locked'] = 'Locked';
$txt['modlog_ac_stickied'] = 'Stickied';
$txt['modlog_ac_deleted'] = 'Deleted';
$txt['modlog_ac_deleted_member'] = 'Deleted Member';
$txt['modlog_ac_removed'] = 'Removed';
$txt['modlog_ac_modified'] = 'Modified';
$txt['modlog_ac_merged'] = 'Merged';
$txt['modlog_ac_split'] = 'Split';
$txt['modlog_ac_moved'] = 'Moved';
$txt['modlog_ac_profile'] = 'Profile Edit';
$txt['modlog_ac_pruned'] = 'Pruned Board';
$txt['modlog_ac_news'] = 'Edited News';
$txt['modlog_enter_comment'] = 'Enter Moderation Comment';
$txt['modlog_moderation_log'] = 'Moderation Log';
$txt['modlog_moderation_log_desc'] = 'Below is a list of all the moderation actions that have been carried out by moderators of the forum.<br /><b>Please no$
$txt['modlog_no_entries_found'] = 'No entries found';
$txt['modlog_remove'] = 'Remove';
$txt['modlog_removeall'] = 'Remove All';
$txt['modlog_go'] = 'Go';
$txt['modlog_add'] = 'Add';
$txt['modlog_search'] = 'Quick Search';
$txt['modlog_by'] = 'By';


Title: Re: Log Mod Account Edits
Post by: SusanTN on March 18, 2008, 03:18:58 AM
Quote from: dumblonde on January 10, 2008, 01:48:22 PM
does this mod work with 1.1.4?  :D

Yep I removed version checking as the modlog isn't likely to change if it does I will update the mod.
Title: Re: Log Mod Account Edits
Post by: Godsongz on May 22, 2008, 04:26:45 PM
Could I ask (if it's not too difficult) that account approvals be added to this?  For sites (like mine) that are set to require administrator approval for new accounts (don't ask why) it would be awesome to be able to keep track of which of my admins and global mods approve which users.

Parenthetical remarks (however relevant) are (usually) unnecessary.
Title: Re: Log Mod Account Edits
Post by: bros on May 26, 2008, 09:07:34 PM
Does this work with SMF 2 Beta 3.1?
Title: Re: Log Mod Account Edits
Post by: SusanTN on July 09, 2008, 11:08:29 PM
Not sure havn't updated to 2 beta yet.
Title: Re: Log Mod Account Edits
Post by: gamerhookup on August 14, 2008, 10:04:26 AM
Hi there.

New to this mod.. Got it installed in 3 of the 4 sites I have. This one site it will not show up in the Admin section. But it works when you enter the page manaully. Just no link in the admin section.

So I started over, and just installed the mod. But it does not show up in the theme. I am using a custom theme.

There are no files in this theme package to update, so I just did the defaults.

Am I missing something?

And when I have just switched to the smf core theme, it still does not show up. Again, I went thru and made sure all the lines were there where they were suppose to be. Nothing shows up in the admin section.

Puzzled!
Title: Re: Log Mod Account Edits
Post by: gamerhookup on August 19, 2008, 06:10:27 PM
k, well since no one rpelied, never mind....

For some odd reason after I installed a few other mods.. It showed up in the list..  I have no clue... But all is working and in order..,
Title: Re: Log Mod Account Edits
Post by: bros on August 26, 2008, 01:07:24 PM
I hope this gets updated for 2.0 soon...
Title: Re: Log Mod Account Edits
Post by: SusanTN on September 22, 2008, 03:25:20 AM
Quote from: bros on August 26, 2008, 01:07:24 PM
I hope this gets updated for 2.0 soon...

I won't update for 2.0 until it's general release sorry :(
Title: Re: Log Mod Account Edits
Post by: SusanTN on September 22, 2008, 03:30:39 AM
Quote from: Godsongz on May 22, 2008, 04:26:45 PM
Could I ask (if it's not too difficult) that account approvals be added to this?  For sites (like mine) that are set to require administrator approval for new accounts (don't ask why) it would be awesome to be able to keep track of which of my admins and global mods approve which users.

Parenthetical remarks (however relevant) are (usually) unnecessary.

Looking at adding your request to the mod.
Title: Re: Log Mod Account Edits
Post by: bros on October 02, 2008, 12:13:10 PM
Okay. Won't work for SMF 2.0 Beta 4.

1.   Execute Modification   ./Sources/Modlog.php   Test failed
   2.   Execute Modification   ./Sources/Profile.php   Test successful
   3.   Execute Modification   ./Themes/default/languages/Admin.english.php   Test failed
   4.   Execute Modification   ./Themes/default/languages/Modifications.english.php   Test successful

Attached ModLog.php and Admin.english.php
Title: Re: Log Mod Account Edits
Post by: Fittichklopfer on November 13, 2008, 06:09:10 AM
Quote from: bros on October 02, 2008, 12:13:10 PM
Okay. Won't work for SMF 2.0 Beta 4.

1.   Execute Modification   ./Sources/Modlog.php   Test failed
   2.   Execute Modification   ./Sources/Profile.php   Test successful
   3.   Execute Modification   ./Themes/default/languages/Admin.english.php   Test failed
   4.   Execute Modification   ./Themes/default/languages/Modifications.english.php   Test successful

Attached ModLog.php and Admin.english.php

same prob here
Title: Re: Log Mod Account Edits
Post by: bros on December 15, 2008, 12:19:14 AM
Any chance of making it work on 2.0?
Title: Re: Log Mod Account Edits
Post by: protonxl on December 19, 2008, 08:54:18 AM
I have installed it on 1.1.7  just fine, no errors.
however, i do not see where the link to tab is.

hmm ?
where do you check the moderation log tab?
Title: Re: Log Mod Account Edits
Post by: perplexed on May 29, 2009, 07:59:34 AM
Does anyone know if 2.0 provides any more data than 1.1 series and if you still need this mod for 2.0 (when it is available)?

Title: Re: Log Mod Account Edits
Post by: bros on July 31, 2009, 09:41:14 PM
Quote from: quiteperplexed on May 29, 2009, 07:59:34 AM
Does anyone know if 2.0 provides any more data than 1.1 series and if you still need this mod for 2.0 (when it is available)?



I would like this mod for SMF 2
Title: Re: Log Mod Account Edits
Post by: bros on March 31, 2010, 10:25:04 PM
Wondering if you are still working on the mod.
Title: Re: Log Mod Account Edits
Post by: SusanTN on August 08, 2010, 10:15:39 PM
I will check into it now that I have installed Beta 3
Title: Re: Log Mod Account Edits
Post by: SusanTN on August 09, 2010, 03:00:21 AM
It's not needed check into the admin log.